Thanks again @deathaxe - much appreciate it!
Theme development question
I need to be able to export the current theme, in order to place the various elements within the folder (theme container) correct? For some reason I canāt export using package resource viewer and I canāt understand why.
If youāre on the most recent dev build, there is a weird interaction between it and PackageResourceViewer; it doesnāt generate any obvious errors anywhere, but when it opens a resource itās always empty. Iāve been meaning to investigate that (Iām not the developer of that package, but I do use it a lot) but I havenāt had the time lately.
Thanks @OdatNurd. I think Iām going to downgrade to latest stable for time being so I can get this thing cleaned up and shipped out - Iāll throw it up on github shortly so others can help with development.
You can view individual resource files with View Package File
, but you canāt make any edits to them if theyāre coming from a sublime-package
file because those files are read only. The exception there is if you have an override on a file, since in that case the override is already unpacked and in the Packages
folder.
PackageResourceViewer opens all resources in a way that you can edit them and save, and if the resource is from a sublime-package
file, it will automatically create the override for you (i.e. create an appropriate folder structure in Packages
and saves the file there).
To do that with View Package File
you need to Save As
the file, create the folder structure yourself, and then close and reopen the file (because Sublime opens it read only).
Also PRV lets you extract the entire contents of a sublime-package
in one shot to your packages folder, although generally speaking thatās not a good idea (that command should really confirm with you first or something) because doing so essentially creates overrides for an entire package at once, which makes future updates to the sublime-package
file invisible.
It has been possible to change all three colors the entire time, we just werenāt using the line_diff_added
or line_diff_deleted
colors before 3189.
@wbond nice to know, but in Scheme or Theme? How can I change the color if is in theme?
The color options go in your color scheme. So for example, if you use the default Monokai as your default color scheme, youād put this into a Monokai.sublime-color-scheme
file in your User
folder:
{
"globals":
{
"line_diff_added": "var(yellow2)",
"line_diff_modified": "var(blue)",
"line_diff_deleted ": "var(red)",
}
}
That makes added lines green (paradoxically, given the variable used), deletes red, and modifications blue. If you donāt have those options, the closest colors to green, yellow and red in your color scheme are used in their place.
Here Iām specifically overriding the modification color to be blue because I prefer that to yellow (and in Monokai, the green and yellow are too similar looking for my eyes to distinguish at the side of the diff bar).
Dev build 3186
Thanks @OdatNurd.
Very good. How do you know these changes if they were not yet available in the documentation? I apologize for my ignorance.
There tends to be a bit of discussion after each build on the Discord server.
The documentation will hopefully be coming soon.
Iām trying to add these new settings to my color schemes, but it doesnāt seem to have any effect. The circles next to the files in the tree are still blue. I should do it like this right?
{
"globals": {
"line_diff_added": "#00ff00"
}
}
Any ideas?
The side bar icons are part of the theme, whereas the line_diff_*
settings in the color scheme affects the diff markers drawn in the gutter. The next dev build will include updated docs about the new theme and color scheme features relative to Git.
OK, thanks, that makes sense. I will wait for the updated docs for the theme settings then!
BTW: I think the diff lines are a nice addition because they donāt interfere with linting error markers anymore
Not sure if this has been asked (lazy, drinking wine while I do a little coding). Is there a plugin that provides a side bar of some sort (note the screenshot is from Atom, but Iām currently hacking on sublime text, because itās just better).
Thanks in advance for any assistance. Very much appreciate!
Sublime has a file-related side bar, though youāve probably already discovered that. It can be toggled away via the View > Side Bar > Show Side Bar
menu entry or associated key binding. It can display the contents of folders that youāve opened as well as the names of opened files (if you want it to), but it will remain hidden if it has nothing to display. So if you donāt open a folder and also donāt turn on open file display (or you do but there are no open files, it wonāt display).
Itās not possible to add the additional side bar thatās along the left side of the window, however. Thereās not any API for extending the user interface in that way (including controlling whatās in the side bar in general other than files and folders).
Themes can control the visual display of the existing elements, but they canāt really add new ones.
Thank you sir. Appreciate you taking the time to respond and answer my question. Giving this a thinkā¦