Sublime Forum

Change color of just one file

#1

I feel like this might be ground I’ve already queried about here, but my memory’s iffy, and I can’t find what I’m looking for.

FWIW I work in markdown writing prose, not code.

In a project full of markdown files, is it possible to change a color element (say background color) for specific individual files? i.e., say my usual color scheme is amber text on black, but for whatever reason, I want to change the background color of the single file example-file.md to blue instead of black. Thanks for any help/reminders.

0 Likes

#2

Not directly, but a plugin can be used to do that.

What you’d need is basically a second version of your color scheme that has the colors that you want, and then a plugin which, on file load, notices that the filename is “special” and applies a different color scheme to it.

There is an example of that demonstrated here:

1 Like

#3

Thanks, friend. Always appreciate your help. I’ll give this a shot.

0 Likes