Sublime Forum

[Resolved] How to change text color in selected row?

#1

Hello, I noticed that I have a different coloured texts on selected row. (Screenshot: https://ctrlv.cz/Uy9d)

So I had idea, that I change all colors. When I looked in settings, I found that I have same setting for all used scopes in row 3. Problem is that one is background colour and other is foreground colour. I tried <key>selectionForeground<key> in this scope, but that is not work.

Is possible set different foreground colours for selected row and selected text only? Is possible to have coloured background and when row is selected, change foreground colour?

Sorry for my bad english and nooby question, I hope u understeand. Thank you for your time.

0 Likes

#2

In the tmTheme file for your color scheme, the lineHighlight key controls the background color of the line where the caret is when there is no selection.

You could make this partially transparent, if that would help, but you can’t affect the foreground colors of text on that line.

Example:

<key>lineHighlight</key>
<string>#3E3D32A0</string>
1 Like

#3

Clever solution, if I can’t affect the foreground colors of text on that line… Thank you for your time. That was as well helpful.

My last question: How I can mark topic as resolved?

1 Like

#4

The standard procedure on this forum seems to be to edit your question title, to put [Solved] at the front :slightly_smiling:

1 Like