Make all HighlightStyle properties optional
Previously, some of those properties such the font weight, style and color would be mandatory: when the theme didn't specify them, Zed would use a default value during deserialization. This meant that those default properties would unconditionally override the base text style, causing a rendering bug when combining syntax highlights with diagnostic styles. This commit fixes that by making `HighlightStyle`s more additive: each property can be set independently and only the properties that theme specifies get overridden in the base text style.
This commit is contained in:
@@ -284,11 +284,7 @@ impl ProjectSymbolsView {
|
||||
&settings.theme.selector.item
|
||||
};
|
||||
let symbol = &self.symbols[string_match.candidate_id];
|
||||
let syntax_runs = styled_runs_for_code_label(
|
||||
&symbol.label,
|
||||
style.label.text.color,
|
||||
&settings.theme.editor.syntax,
|
||||
);
|
||||
let syntax_runs = styled_runs_for_code_label(&symbol.label, &settings.theme.editor.syntax);
|
||||
|
||||
let mut path = symbol.path.to_string_lossy();
|
||||
if show_worktree_root_name {
|
||||
|
||||
Reference in New Issue
Block a user