Browse Source

Don't UseLayoutRounding on ScrollBar.

Its default size of 18 with a thumb size of 8 can't be laid out to device pixels with a scaling of 1.5x. Previously, the thumb had more space on the right than the left, with this change it had more space on the left than the right. For some reason though it was more noticably offset with the space on the left. We may need to change the default sizes for `ScrollBar`.
pull/3960/head
Steven Kirk 6 years ago
parent
commit
119d92732f
  1. 6
      src/Avalonia.Themes.Default/ScrollBar.xaml

6
src/Avalonia.Themes.Default/ScrollBar.xaml

@ -3,7 +3,8 @@
<Setter Property="Cursor" Value="Arrow" />
<Setter Property="Template">
<ControlTemplate>
<Border Background="{DynamicResource ThemeControlMidBrush}">
<Border Background="{DynamicResource ThemeControlMidBrush}"
UseLayoutRounding="False">
<Grid RowDefinitions="Auto,*,Auto">
<RepeatButton Name="PART_LineUpButton" HorizontalAlignment="Center"
Classes="repeat"
@ -49,7 +50,8 @@
<Setter Property="Height" Value="{DynamicResource ScrollBarThickness}" />
<Setter Property="Template">
<ControlTemplate>
<Border Background="{DynamicResource ThemeControlMidBrush}">
<Border Background="{DynamicResource ThemeControlMidBrush}"
UseLayoutRounding="False">
<Grid ColumnDefinitions="Auto,*,Auto">
<RepeatButton Name="PART_LineUpButton" VerticalAlignment="Center"
Classes="repeat"

Loading…
Cancel
Save