mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-06-04 18:44:59 +00:00
feature: supports custom fonts (#30)
This commit is contained in:
parent
0e49ad181a
commit
83aa373079
14 changed files with 181 additions and 15 deletions
|
@ -1,5 +1,7 @@
|
|||
<Styles xmlns="https://github.com/avaloniaui"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:vm="using:SourceGit.ViewModels"
|
||||
xmlns:c="using:SourceGit.Converters"
|
||||
xmlns:ae="using:AvaloniaEdit"
|
||||
xmlns:aes="using:AvaloniaEdit.Search">
|
||||
<Design.PreviewWith>
|
||||
|
@ -13,6 +15,10 @@
|
|||
</Style.Resources>
|
||||
</Style>
|
||||
|
||||
<Style Selector="ContentPresenter">
|
||||
<Setter Property="FontFamily" Value="{Binding Source={x:Static vm:Preference.Instance}, Path=DefaultFont, Converter={x:Static c:StringConverters.ToFontFamily}}"/>
|
||||
</Style>
|
||||
|
||||
<Style Selector="Path">
|
||||
<Setter Property="Fill" Value="{DynamicResource Brush.FG1}"/>
|
||||
<Setter Property="Stretch" Value="Uniform"/>
|
||||
|
@ -64,7 +70,7 @@
|
|||
<Setter Property="FontStyle" Value="Italic"/>
|
||||
</Style>
|
||||
<Style Selector="TextBlock.monospace">
|
||||
<Setter Property="FontFamily" Value="fonts:SourceGit#JetBrains Mono"/>
|
||||
<Setter Property="FontFamily" Value="{Binding Source={x:Static vm:Preference.Instance}, Path=MonospaceFont, Converter={x:Static c:StringConverters.ToFontFamily}}"/>
|
||||
</Style>
|
||||
<Style Selector="TextBlock.group_header_label">
|
||||
<Setter Property="Foreground" Value="{DynamicResource Brush.FG2}"/>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue