-
-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Convert .tmTheme to new .sublime-color-scheme format #20
Convert .tmTheme to new .sublime-color-scheme format #20
Conversation
Adds a new file, Nord.sublime-color-scheme, with (mostly) the same colour declarations as the original .tmTheme file. The file was modified from a file generated by a built-in tool to convert .tmTheme files (command palette -> "Convert Color Scheme"); the tool also helps generate variables for common colours used in the original .tmTheme file. * Changes sublimelinter.gutter-mark from lime to nord14 (Aurora green) This was to fix colour parsing for variables by the auto-convert tool in ST3, as it can only parse colours as hex codes * Replaces hard-coded hex values with variables The variables mostly follow the Nord colours; however, there's one colour, #616e88, that doesn't follow any of the greys; it's labelled 'lightgrey' * Adds new declarations for gutter diff lines The three new declarations are at the end of the globals block * Change the path in Nord.skins
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @kaine119 👋, thanks for your contribution 👍
LGTM 🚀
Sorry for the delay, there are 400+ tickets in the queue and the transition of the Nord port projects and documentations to the new and shiny website are currently processed with the highest priority in order to simplify the maintainability and overall quality of Nord.
I'd like to merge your PR in order to finally deploy the initial release version 0.1.0 to the package control registry. I've also created #22 so I've changed the target branch of this PR to the story branch in order to commit more optimizations and changes for the new JSON color scheme format.
40df2dc
into
nordtheme:feature/gh-22-transition-json-color-scheme-format
As of Sublime Text 3 build 3149, a new JSON based color scheme format `.sublime-color-scheme` was introduced for easier editing, customization and addition of new features. The documentation for the new format is available at the main "Color Schemes" documentation (1). Nord will migrate to the new format (JSON) from the now deprecated/legacy `.tmTheme` format (XML). All versions greater or equal to 3.1 build 3120 come with a builtin tool to convert legacy themes to the new format through the command palette only when the files is opened in the editor**: „Convert Color Scheme“ The foloowing additional changes and additions for features that have been introduced withg the new JSON color scheme format are included: - Added all Nord colors as variables to the `variables` object that are exposed through Sublime Text's internal CSS color scheme API to reuse them with the CSS `var()` function for the defined scope rules. - Added additional syntax-specific variables to the `variables` object to ensure a uniform color usage for scopes with the same context as well as reducing code duplication and possible transmission errors. - Added the new Git gutter diff keys `line_diff_added`, `line_diff_modified` and `line_diff_deleted` to the `globals` object to ensure they match Nord's style. (@kaine119) The now officially deprecated `.tmTheme` color scheme format file (2) has been removed and is not supported by the Nord theme package anymore. References: (1) https://www.sublimetext.com/docs/3/color_schemes.html (2) https://www.sublimetext.com/docs/3/color_schemes_tmtheme.html Co-authored-by: Kai En <[email protected]> Merged with GH-20 GH-22
As of Sublime Text 3 build 3149, a new JSON based color scheme format `.sublime-color-scheme` (1) was introduced for easier editing, customization and addition of new features. The documentation for the new format is available at the main "Color Schemes" documentation (1). Nord has been migrated to the new format (JSON) from the now deprecated/legacy `.tmTheme` format (XML) (2). All versions greater or equal to 3.1 build 3120 come with a builtin tool to convert legacy themes to the new format through the command palette only when the files is opened in the editor**: „Convert Color Scheme“ The following additional changes and additions for features that have been introduced with the new JSON color scheme format are included: - Added all Nord colors as variables to the `variables` object that are exposed through Sublime Text's internal CSS color scheme API to reuse them with the CSS `var()` function for the defined scope rules. - Added additional syntax-specific variables to the `variables` object to ensure a uniform color usage for scopes with the same context as well as reducing code duplication and possible transmission errors. - Added the new Git gutter diff keys `line_diff_added`, `line_diff_modified` and `line_diff_deleted` to the `globals` object to ensure they match Nord's style. (@kaine119) The now officially deprecated `.tmTheme` color scheme format file (2) has been removed and is not supported by the Nord theme package anymore. References: (1) https://www.sublimetext.com/docs/3/color_schemes.html (2) https://www.sublimetext.com/docs/3/color_schemes_tmtheme.html Co-authored-by: Kai En <[email protected]> Includes GH-20 Resolves GH-22
ST 3.1 (build 3120) introduced a new colour scheme format,
.sublime-color-scheme
, deprecating.tmTheme
s in the process. New features, like diff markers, aren't supported by legacy.tmTheme
files anymore.ST3 includes a tool to convert tmTheme files to the new format (command palette > "Convert Color Scheme"); the new file here is modified from what was generated by the tool.
Diffs:
This was to fix colour parsing for variables by the auto-convert tool in ST3, as it can only parse colours as hex codes
The variables mostly follow the Nord colours; however, there's one colour, #616e88, that doesn't follow any of the greys; it's labelled 'lightgrey'
The three new declarations are at the end of the globals block