Skip to content

Commit cd3c9c8

Browse files
authored
fix css for sequentview syntaxhighlightning (#3645)
2 parents a0fd768 + 05f4c93 commit cd3c9c8

File tree

1 file changed

+21
-19
lines changed

1 file changed

+21
-19
lines changed

key.ui/src/main/java/de/uka/ilkd/key/gui/nodeviews/HTMLSyntaxHighlighter.java

Lines changed: 21 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -169,39 +169,41 @@ public class HTMLSyntaxHighlighter {
169169

170170

171171
static {
172-
light.addRule("""
173-
.prop_logic_highlight { color: #%6X; font-weight: bold; }
174-
.dynamic_logic_highlight { color: #%6X; font-weight: bold; }
175-
.java_highlight { color: #%6X; font-weight: bold; }
176-
.progvar_highlight { color: #%6X; }
177-
.comment_highlight { color: #%6X; }
178-
.jml_highlight { color: #%6X; }
179-
.sequent_arrow_highlight { color: #%6X; font-size: 1.7em }
172+
final var lightString = """
173+
.prop_logic_highlight { color: #%06X; font-weight: bold; }
174+
.dynamic_logic_highlight { color: #%06X; font-weight: bold; }
175+
.java_highlight { color: #%06X; font-weight: bold; }
176+
.progvar_highlight { color: #%06X; }
177+
.comment_highlight { color: #%06X; }
178+
.jml_highlight { color: #%06X; }
179+
.sequent_arrow_highlight { color: #%06X; font-size: 1.7em }
180180
""".formatted(
181181
PROP_LOGIC_COLOR.getLightValue().getRGB() & 0xFFFFFF,
182182
DYN_LOGIC_COLOR.getLightValue().getRGB() & 0xFFFFFF,
183183
JAVA_COLOR.getLightValue().getRGB() & 0xFFFFFF,
184184
PROG_VAR_COLOR.getLightValue().getRGB() & 0xFFFFFF,
185185
COMMENT_COLOR.getLightValue().getRGB() & 0xFFFFFF,
186186
JML_COLOR.getLightValue().getRGB() & 0xFFFFFF,
187-
SEQUENT_ARROW_COLOR.getLightValue().getRGB() & 0xFFFFFF));
188-
189-
dark.addRule("""
190-
.prop_logic_highlight { color: %6X; font-weight: bold; }
191-
.dynamic_logic_highlight { color: %6X; font-weight: bold; }
192-
.java_highlight { color: %6X; font-weight: bold; }
193-
.progvar_highlight { color: %6X; }
194-
.comment_highlight { color: %6X; }
195-
.jml_highlight { color: %6X; }
196-
.sequent_arrow_highlight { color: %6X; font-size: 1.7em }
187+
SEQUENT_ARROW_COLOR.getLightValue().getRGB() & 0xFFFFFF);
188+
light.addRule(lightString);
189+
190+
final var darkString = """
191+
.prop_logic_highlight { color: #%06X; font-weight: bold; }
192+
.dynamic_logic_highlight { color: #%06X; font-weight: bold; }
193+
.java_highlight { color: #%06X; font-weight: bold; }
194+
.progvar_highlight { color: #%06X; }
195+
.comment_highlight { color: #%06X; }
196+
.jml_highlight { color: #%06X; }
197+
.sequent_arrow_highlight { color: #%06X; font-size: 1.7em }
197198
""".formatted(
198199
PROP_LOGIC_COLOR.getDarkValue().getRGB() & 0xFFFFFF,
199200
DYN_LOGIC_COLOR.getDarkValue().getRGB() & 0xFFFFFF,
200201
JAVA_COLOR.getDarkValue().getRGB() & 0xFFFFFF,
201202
PROG_VAR_COLOR.getDarkValue().getRGB() & 0xFFFFFF,
202203
COMMENT_COLOR.getDarkValue().getRGB() & 0xFFFFFF,
203204
JML_COLOR.getDarkValue().getRGB() & 0xFFFFFF,
204-
SEQUENT_ARROW_COLOR.getDarkValue().getRGB() & 0xFFFFFF));
205+
SEQUENT_ARROW_COLOR.getDarkValue().getRGB() & 0xFFFFFF);
206+
dark.addRule(darkString);
205207
}
206208

207209

0 commit comments

Comments
 (0)