CheckBoxPage.xaml 1.3 KB

12345678910111213141516171819202122232425262728
  1. <UserControl xmlns="https://github.com/avaloniaui"
  2. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
  3. <StackPanel Orientation="Vertical" Gap="4">
  4. <TextBlock Classes="h1">CheckBox</TextBlock>
  5. <TextBlock Classes="h2">A check box control</TextBlock>
  6. <StackPanel Orientation="Horizontal"
  7. Margin="0,16,0,0"
  8. HorizontalAlignment="Center"
  9. Gap="16">
  10. <StackPanel Orientation="Vertical"
  11. Gap="16">
  12. <CheckBox>Unchecked</CheckBox>
  13. <CheckBox IsChecked="True">Checked</CheckBox>
  14. <CheckBox IsChecked="{x:Null}">Indeterminate</CheckBox>
  15. <CheckBox IsChecked="True" IsEnabled="False">Disabled</CheckBox>
  16. </StackPanel>
  17. <StackPanel Orientation="Vertical"
  18. HorizontalAlignment="Center"
  19. Gap="16">
  20. <CheckBox IsChecked="False" IsThreeState="True">Three State: Unchecked</CheckBox>
  21. <CheckBox IsChecked="True" IsThreeState="True">Three State: Checked</CheckBox>
  22. <CheckBox IsChecked="{x:Null}" IsThreeState="True">Three State: Indeterminate</CheckBox>
  23. <CheckBox IsChecked="{x:Null}" IsThreeState="True" IsEnabled="False">Three State: Disabled</CheckBox>
  24. </StackPanel>
  25. </StackPanel>
  26. </StackPanel>
  27. </UserControl>