Browse Source

Add colors for line prefixes in IL/Asm and text markers

pull/2906/head
Lucas Trzesniewski 2 years ago
parent
commit
0253b1ab68
  1. 4
      ILSpy/TextView/Asm-Mode.xshd
  2. 4
      ILSpy/TextView/ILAsm-Mode.xshd
  3. 2
      ILSpy/Themes/Theme.Dark.xaml
  4. 5
      ILSpy/Themes/Theme.RSharpDark.xaml
  5. 5
      ILSpy/Themes/Theme.RSharpLight.xaml
  6. 5
      ILSpy/Themes/Theme.VSCodeDarkPlus.xaml
  7. 5
      ILSpy/Themes/Theme.VSCodeLightPlus.xaml

4
ILSpy/TextView/Asm-Mode.xshd

@ -8,6 +8,7 @@ @@ -8,6 +8,7 @@
<Color name="Registers" foreground="#8080FF" background="#EEEEEE" exampleText="nop" />
<Color name="Directives" foreground="Blue" fontWeight="bold" exampleText=".class" />
<Color name="Directive Operands" foreground="DarkBlue" fontWeight="bold" exampleText=".class" />
<Color name="Address and Bytes" exampleText="00000000003DEB40 56" />
<RuleSet ignoreCase="false">
<Keywords color="Instructions">
@ -1189,6 +1190,9 @@ @@ -1189,6 +1190,9 @@
<Span color="Comment" ruleSet="CommentMarkerSet">
<Begin>;</Begin>
</Span>
<Rule color="Address and Bytes">
^ \s* [0-9A-F]+ \s+ [0-9A-F]+
</Rule>
<Rule color="NumberLiteral">
\b(0[xXhH])?[0-9a-fA-F_`]+[h]? # hex number
|

4
ILSpy/TextView/ILAsm-Mode.xshd

@ -5,6 +5,7 @@ @@ -5,6 +5,7 @@
<Color name="Keywords" foreground="Blue" fontWeight="bold" exampleText="true" />
<Color name="Directives" foreground="Green" fontWeight="bold" exampleText=".class" />
<Color name="Security" foreground="Red" exampleText="request" />
<Color name="Label" exampleText="IL_0000:" />
<RuleSet ignoreCase="false">
<Keywords color="Instructions">
@ -516,6 +517,9 @@ @@ -516,6 +517,9 @@
<Begin>"</Begin>
<End>"</End>
</Span>
<Rule color="Label">
^ \s* \w+ :
</Rule>
</RuleSet>
<RuleSet name="CommentMarkerSet" ignoreCase="false">
<Keywords foreground="#FFFF0000" fontWeight="bold">

2
ILSpy/Themes/Theme.Dark.xaml

@ -80,7 +80,7 @@ @@ -80,7 +80,7 @@
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Instructions" Foreground="#FFD69D85" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Math Instructions" Foreground="#FFD69D85" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Extended Instructions" Foreground="#FF559CD6" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Registers" Foreground="#8080FF" Background="#EEEEEE" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Registers" Foreground="#8080FF" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Directives" Foreground="#FFD69D85" FontWeight="Bold" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Directive Operands" Foreground="#FFb5cea8" FontWeight="Bold" />

5
ILSpy/Themes/Theme.RSharpDark.xaml

@ -10,6 +10,9 @@ @@ -10,6 +10,9 @@
<SolidColorBrush x:Key="{x:Static themes:ResourceKeys.TextBackgroundColor}" Color="#1E1E1E" />
<SolidColorBrush x:Key="{x:Static themes:ResourceKeys.TextForegroundColor}" Color="#DCDCDC" />
<Color x:Key="{x:Static themes:ResourceKeys.TextMarkerBackgroundColor}">#623916</Color>
<Color x:Key="{x:Static themes:ResourceKeys.TextMarkerDefinitionBackgroundColor}">#483D8B</Color>
<!-- ILAsm -->
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Comment" Foreground="#57A64A" />
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.String" Foreground="#D69D85" />
@ -17,6 +20,7 @@ @@ -17,6 +20,7 @@
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Keywords" Foreground="#569CD6" />
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Directives" Foreground="#ADD8E6" />
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Security" Foreground="#569CD6" />
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Label" Foreground="#696969" />
<!-- Asm -->
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Comment" Foreground="#57A64A" />
@ -28,6 +32,7 @@ @@ -28,6 +32,7 @@
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Registers" Foreground="#9CDCFE" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Directives" Foreground="#569CD6" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Directive Operands" Foreground="#9CDCFE" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Address and Bytes" Foreground="#696969" />
<!-- CSharp -->
<themes:SyntaxColor x:Key="SyntaxColor.C#.Comment" Foreground="#57A64A" />

5
ILSpy/Themes/Theme.RSharpLight.xaml

@ -10,6 +10,9 @@ @@ -10,6 +10,9 @@
<SolidColorBrush x:Key="{x:Static themes:ResourceKeys.TextBackgroundColor}" Color="White" />
<SolidColorBrush x:Key="{x:Static themes:ResourceKeys.TextForegroundColor}" Color="Black" />
<Color x:Key="{x:Static themes:ResourceKeys.TextMarkerBackgroundColor}">#F6B94D</Color>
<Color x:Key="{x:Static themes:ResourceKeys.TextMarkerDefinitionBackgroundColor}">#87CEFA</Color>
<!-- ILAsm -->
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Comment" Foreground="#007F00" />
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.String" Foreground="#A31515" />
@ -17,6 +20,7 @@ @@ -17,6 +20,7 @@
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Keywords" Foreground="#0000FF" />
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Directives" Foreground="#00008B" />
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Security" Foreground="#0000FF" />
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Label" Foreground="#398A8A" />
<!-- Asm -->
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Comment" Foreground="#007F00" />
@ -28,6 +32,7 @@ @@ -28,6 +32,7 @@
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Registers" Foreground="#1F377F" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Directives" Foreground="#0000FF" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Directive Operands" Foreground="#1F377F" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Address and Bytes" Foreground="#398A8A" />
<!-- CSharp -->
<themes:SyntaxColor x:Key="SyntaxColor.C#.Comment" Foreground="#007F00" />

5
ILSpy/Themes/Theme.VSCodeDarkPlus.xaml

@ -15,6 +15,9 @@ @@ -15,6 +15,9 @@
<SolidColorBrush x:Key="{x:Static themes:ResourceKeys.TextBackgroundColor}" Color="#1E1E1E" />
<SolidColorBrush x:Key="{x:Static themes:ResourceKeys.TextForegroundColor}" Color="#D4D4D4" />
<Color x:Key="{x:Static themes:ResourceKeys.TextMarkerBackgroundColor}">#264F78</Color>
<Color x:Key="{x:Static themes:ResourceKeys.TextMarkerDefinitionBackgroundColor}">#343A40</Color>
<!-- ILAsm -->
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Comment" Foreground="#6A9955" />
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.String" Foreground="#ce9178" />
@ -22,6 +25,7 @@ @@ -22,6 +25,7 @@
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Keywords" Foreground="#569cd6" />
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Directives" Foreground="#DCDCAA" />
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Security" Foreground="#569cd6" />
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Label" Foreground="#6A9955" />
<!-- Asm -->
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Comment" Foreground="#6A9955" />
@ -33,6 +37,7 @@ @@ -33,6 +37,7 @@
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Registers" Foreground="#DCDCAA" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Directives" Foreground="#569cd6" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Directive Operands" Foreground="#DCDCAA" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Address and Bytes" Foreground="#ce9178" />
<!-- CSharp -->
<themes:SyntaxColor x:Key="SyntaxColor.C#.Comment" Foreground="#6A9955" />

5
ILSpy/Themes/Theme.VSCodeLightPlus.xaml

@ -15,6 +15,9 @@ @@ -15,6 +15,9 @@
<SolidColorBrush x:Key="{x:Static themes:ResourceKeys.TextBackgroundColor}" Color="White" />
<SolidColorBrush x:Key="{x:Static themes:ResourceKeys.TextForegroundColor}" Color="Black" />
<Color x:Key="{x:Static themes:ResourceKeys.TextMarkerBackgroundColor}">#ADD6FF</Color>
<Color x:Key="{x:Static themes:ResourceKeys.TextMarkerDefinitionBackgroundColor}">#D6EAFF</Color>
<!-- ILAsm -->
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Comment" Foreground="#008000" />
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.String" Foreground="#a31515" />
@ -22,6 +25,7 @@ @@ -22,6 +25,7 @@
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Keywords" Foreground="#0000ff" />
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Directives" Foreground="#795E26" />
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Security" Foreground="#0000ff" />
<themes:SyntaxColor x:Key="SyntaxColor.ILAsm.Label" Foreground="#0451a5" />
<!-- Asm -->
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Comment" Foreground="#008000" />
@ -33,6 +37,7 @@ @@ -33,6 +37,7 @@
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Registers" Foreground="#795E26" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Directives" Foreground="#0000ff" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Directive Operands" Foreground="#795E26" />
<themes:SyntaxColor x:Key="SyntaxColor.Asm.Address and Bytes" Foreground="#0451a5" />
<!-- CSharp -->
<themes:SyntaxColor x:Key="SyntaxColor.C#.Comment" Foreground="#008000" />

Loading…
Cancel
Save