Skip to content

Commit 07f5a4b

Browse files
committed
feat: add margins to separate TextBoxes and Buttons in creation & editing windows
1 parent ad5d864 commit 07f5a4b

3 files changed

Lines changed: 11 additions & 4 deletions

File tree

Desktop/App.xaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@
1111
Source="pack://application:,,,/PresentationFramework.Fluent;component/Themes/Fluent.xaml" />
1212
</ResourceDictionary.MergedDictionaries>
1313
<Thickness x:Key="DefaultMargin">20</Thickness>
14+
<Thickness x:Key="SmallMarginAtTop">0,10,0,0</Thickness>
15+
<Thickness x:Key="BigMarginAtTop">0,40,0,0</Thickness>
1416
<sys:Double x:Key="DescriptionTextBoxHeight">75</sys:Double>
1517
</ResourceDictionary>
1618
</Application.Resources>

Desktop/Tasks/TaskCreation.xaml

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,14 @@
2121
</Grid.RowDefinitions>
2222
<Label Content="_Name:" Target="{Binding ElementName=Name}" />
2323
<TextBox Grid.Row="1" Name="Name" />
24-
<Label Grid.Row="2" Content="_Description:" Target="{Binding ElementName=Description}" />
24+
<Label Grid.Row="2" Content="_Description:" Target="{Binding ElementName=Description}"
25+
Margin="{StaticResource SmallMarginAtTop}" />
2526
<TextBox Grid.Row="3" Name="Description" Height="{StaticResource DescriptionTextBoxHeight}"
2627
AcceptsReturn="True" TextWrapping="Wrap"
2728
VerticalAlignment="Stretch" />
28-
<Button AutomationProperties.AutomationId="SaveTask" Grid.Row="4" Content="Add" HorizontalAlignment="Right"
29+
<Button AutomationProperties.AutomationId="SaveTask" Grid.Row="4" Content="Add"
30+
Margin="{StaticResource BigMarginAtTop}"
31+
HorizontalAlignment="Right"
2932
IsDefault="True"
3033
Command="{Binding SaveTask}">
3134
<Button.CommandParameter>

Desktop/Tasks/TaskEditing.xaml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,11 +10,13 @@
1010
<StackPanel>
1111
<Label Content="_Name:" Target="{Binding ElementName=Name}" />
1212
<TextBox Name="Name" />
13-
<Label Content="_Description:" Target="{Binding ElementName=Description}" />
13+
<Label Content="_Description:" Margin="{StaticResource SmallMarginAtTop}"
14+
Target="{Binding ElementName=Description}" />
1415
<TextBox Name="Description" Height="{StaticResource DescriptionTextBoxHeight}" AcceptsReturn="True"
1516
TextWrapping="Wrap"
1617
VerticalAlignment="Stretch" />
17-
<Button IsDefault="True" Content="Save" HorizontalAlignment="Right" Click="SaveTask" />
18+
<Button IsDefault="True" Content="Save" Margin="{StaticResource BigMarginAtTop}"
19+
HorizontalAlignment="Right" Click="SaveTask" />
1820
</StackPanel>
1921
</Grid>
2022
</Window>

0 commit comments

Comments
 (0)