Skip to content

Commit f63eefc

Browse files
committed
ux: use Slider instead of NumericUpDown for SubjectGuideLength in preferences window
Signed-off-by: leo <[email protected]>
1 parent d4edb41 commit f63eefc

File tree

1 file changed

+14
-8
lines changed

1 file changed

+14
-8
lines changed

src/Views/Preferences.axaml

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -98,14 +98,20 @@
9898
Text="{DynamicResource Text.Preferences.General.SubjectGuideLength}"
9999
HorizontalAlignment="Right"
100100
Margin="0,0,16,0"/>
101-
<NumericUpDown Grid.Row="3" Grid.Column="1"
102-
Minimum="50" Maximum="1000" Increment="1"
103-
Height="28"
104-
Padding="4"
105-
ShowButtonSpinner="False"
106-
BorderThickness="1" BorderBrush="{DynamicResource Brush.Border1}"
107-
CornerRadius="3"
108-
Value="{Binding SubjectGuideLength, Mode=TwoWay}"/>
101+
<Grid Grid.Row="3" Grid.Column="1" ColumnDefinitions="*,64">
102+
<Slider Grid.Column="0"
103+
Minimum="50" Maximum="200"
104+
TickPlacement="BottomRight" TickFrequency="10"
105+
IsSnapToTickEnabled="True"
106+
VerticalAlignment="Center"
107+
Foreground="{DynamicResource Brush.Border1}"
108+
Value="{Binding SubjectGuideLength, Mode=TwoWay}"/>
109+
110+
<TextBlock Grid.Column="1"
111+
HorizontalAlignment="Right" VerticalAlignment="Center"
112+
Foreground="{DynamicResource Brush.FG1}"
113+
Text="{Binding SubjectGuideLength, Mode=OneWay}"/>
114+
</Grid>
109115

110116
<TextBlock Grid.Row="4" Grid.Column="0"
111117
Text="{DynamicResource Text.Preferences.General.MaxHistoryCommits}"

0 commit comments

Comments
 (0)