Support setting custom background color for syntax highlighting (#12400)

Release Notes:

- Added support for `background_color` in `syntax` map in `theme.json`.

This adds support for setting a `background_color` for styles inside the
`syntax` map for themes defined in `theme.json`. The field is optional
so there should be no backwards compatibility issues.

It is worth noting that the current behaviour for selecting text is that
the background colours will mix/blend (I'm not sure the correct term
here). Changing this behaviour, or making it configurable, looks to be a
far more complex issue and I'm not sure I know how to do it.
This commit is contained in:
Danielle Maywood
2024-05-28 19:25:09 -04:00
committed by GitHub
parent fcb4abf18b
commit 7969a10643
3 changed files with 16 additions and 1 deletions
@@ -241,6 +241,7 @@ impl VsCodeThemeConverter {
let highlight_style = HighlightStyleContent {
color: token_color.settings.foreground.clone(),
background_color: token_color.settings.background.clone(),
font_style: token_color
.settings
.font_style