Styles.axaml 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  1. <Window xmlns="https://github.com/avaloniaui"
  2. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  3. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  4. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  5. mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
  6. x:Class="AvaloniaApplication2.MainWindow"
  7. Title="AvaloniaApplication2">
  8. <Window.Styles>
  9. <Style Selector="Button">
  10. <Setter Property="Background" Value="#007ACC"/>
  11. <Setter Property="Foreground" Value="White"/>
  12. <Setter Property="BorderBrush" Value="#005B99"/>
  13. <Setter Property="BorderThickness" Value="1"/>
  14. <Setter Property="CornerRadius" Value="5"/>
  15. <Setter Property="Padding" Value="10,5"/>
  16. <Setter Property="FontSize" Value="16"/>
  17. <Setter Property="FontWeight" Value="Bold"/>
  18. <Setter Property="Margin" Value="5"/>
  19. <Setter Property="HorizontalAlignment" Value="Center"/>
  20. <Setter Property="VerticalAlignment" Value="Center"/>
  21. </Style>
  22. <Style Selector="TextBlock">
  23. <Setter Property="FontSize" Value="16"/>
  24. <Setter Property="Foreground" Value="#333"/>
  25. <Setter Property="Margin" Value="5"/>
  26. </Style>
  27. <Style Selector="DatePicker">
  28. <Setter Property="BorderBrush" Value="#007ACC"/>
  29. <Setter Property="BorderThickness" Value="1"/>
  30. <Setter Property="CornerRadius" Value="5"/>
  31. <Setter Property="Padding" Value="5"/>
  32. <Setter Property="FontSize" Value="16"/>
  33. </Style>
  34. <Style Selector="RadioButton">
  35. <Setter Property="Foreground" Value="#333"/>
  36. <Setter Property="FontSize" Value="16"/>
  37. <Setter Property="Margin" Value="5"/>
  38. </Style>
  39. <Style Selector="Image">
  40. <Setter Property="Width" Value="200"/>
  41. <Setter Property="Height" Value="200"/>
  42. <Setter Property="Margin" Value="10"/>
  43. <Setter Property="HorizontalAlignment" Value="Center"/>
  44. <Setter Property="VerticalAlignment" Value="Center"/>
  45. </Style>
  46. <Style Selector="StackPanel">
  47. <Setter Property="Margin" Value="10"/>
  48. <Setter Property="HorizontalAlignment" Value="Center"/>
  49. <Setter Property="VerticalAlignment" Value="Center"/>
  50. </Style>
  51. </Window.Styles>
  52. </Window>