- Adjust Badge layout

- Fix glyph margin in win11light
This commit is contained in:
DB p 2025-04-12 00:56:07 +09:00
parent 8aff3c9f2a
commit c66cbae78b
2 changed files with 7 additions and 12 deletions

View file

@ -102,8 +102,6 @@
<Grid>
<Image
x:Name="ImageIcon"
HorizontalAlignment="Center"
VerticalAlignment="Center"
IsHitTestVisible="False"
RenderOptions.BitmapScalingMode="Fant"
Source="{Binding Image, TargetNullValue={x:Null}}"
@ -131,24 +129,21 @@
<TextBlock
x:Name="GlyphIcon"
HorizontalAlignment="Center"
VerticalAlignment="Center"
FontFamily="{Binding Glyph.FontFamily}"
Style="{DynamicResource ItemGlyph}"
Text="{Binding Glyph.Glyph}"
Visibility="{Binding ShowGlyph}" />
<Image
x:Name="BadgeIcon"
Width="16"
Height="16"
Margin="0 2 4 0"
HorizontalAlignment="Right"
VerticalAlignment="Bottom"
RenderOptions.BitmapScalingMode="Fant"
Width="{Binding ElementName=ImageIcon, Path=ActualWidth}"
Height="{Binding ElementName=ImageIcon, Path=ActualHeight}"
RenderOptions.BitmapScalingMode="HighQuality"
Source="{Binding BadgeImage, TargetNullValue={x:Null}}"
Visibility="{Binding ShowBadge}" />
</Grid>
</Border>
</Grid>
<Grid

View file

@ -38,7 +38,7 @@
BasedOn="{StaticResource BaseGlyphStyle}"
TargetType="{x:Type TextBlock}">
<Setter Property="Foreground" Value="{DynamicResource Color05B}" />
<Setter Property="Margin" Value="-4 0 0 0" />
<Setter Property="Margin" Value="0 0 0 0" />
</Style>
<Style
x:Key="QueryBoxStyle"
@ -180,7 +180,7 @@
<Setter Property="Foreground" Value="{DynamicResource Color05B}" />
<Setter Property="VerticalAlignment" Value="Center" />
<Setter Property="HorizontalAlignment" Value="Center" />
<Setter Property="Margin" Value="-4 0 0 0" />
<Setter Property="Margin" Value="0 0 0 0" />
<Setter Property="Width" Value="25" />
<Setter Property="Height" Value="25" />
<Setter Property="FontSize" Value="25" />