csharpc-sharpdotnetxamlavaloniauicross-platformcross-platform-xamlavaloniaguimulti-platformuser-interfacedotnetcore
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
44 lines
1.9 KiB
44 lines
1.9 KiB
<Styles xmlns="https://github.com/perspex">
|
|
<Style Selector="RadioButton">
|
|
<Setter Property="BorderBrush" Value="{StyleResource ThemeBorderMidBrush}"/>
|
|
<Setter Property="BorderThickness" Value="{StyleResource ThemeBorderThickness}"/>
|
|
<Setter Property="Template">
|
|
<ControlTemplate>
|
|
<Grid ColumnDefinitions="Auto,*">
|
|
<Ellipse Name="border"
|
|
Stroke="{TemplateBinding BorderBrush}"
|
|
StrokeThickness="{TemplateBinding BorderThickness}"
|
|
Width="18"
|
|
Height="18"
|
|
VerticalAlignment="Center"/>
|
|
<Ellipse Name="checkMark"
|
|
Fill="{StyleResource HighlightBrush}"
|
|
Width="10"
|
|
Height="10"
|
|
Stretch="Uniform"
|
|
UseLayoutRounding="False"
|
|
HorizontalAlignment="Center"
|
|
VerticalAlignment="Center"/>
|
|
<ContentPresenter Name="PART_ContentPresenter"
|
|
Content="{TemplateBinding Content}"
|
|
DataContext="{TemplateBinding Content}"
|
|
Margin="4,0,0,0"
|
|
VerticalAlignment="Center"
|
|
Grid.Column="1"/>
|
|
</Grid>
|
|
</ControlTemplate>
|
|
</Setter>
|
|
</Style>
|
|
<Style Selector="RadioButton:pointerover /template/ Ellipse#border">
|
|
<Setter Property="Stroke" Value="{StyleResource ThemeBorderDarkBrush}"/>
|
|
</Style>
|
|
<Style Selector="RadioButton /template/ Ellipse#checkMark">
|
|
<Setter Property="IsVisible" Value="False"/>
|
|
</Style>
|
|
<Style Selector="RadioButton:checked /template/ Ellipse#checkMark">
|
|
<Setter Property="IsVisible" Value="True"/>
|
|
</Style>
|
|
<Style Selector="RadioButton:disabled /template/ Ellipse#border">
|
|
<Setter Property="Opacity" Value="{StyleResource ThemeDisabledOpacity}"/>
|
|
</Style>
|
|
</Styles>
|