Merge pull request #158 from irihitech/numeric
Additional Fix of Numeric Height fix
This commit is contained in:
commit
6cafdd6e1c
@ -27,5 +27,15 @@
|
|||||||
Maximum="100"
|
Maximum="100"
|
||||||
Minimum="0"
|
Minimum="0"
|
||||||
ShowButtonSpinner="False" />
|
ShowButtonSpinner="False" />
|
||||||
|
<NumericUpDown
|
||||||
|
Width="200"
|
||||||
|
Classes="Large"
|
||||||
|
Maximum="100"
|
||||||
|
Minimum="0" />
|
||||||
|
<NumericUpDown
|
||||||
|
Width="200"
|
||||||
|
Classes="Small"
|
||||||
|
Maximum="100"
|
||||||
|
Minimum="0" />
|
||||||
</StackPanel>
|
</StackPanel>
|
||||||
</UserControl>
|
</UserControl>
|
||||||
|
@ -5,6 +5,7 @@
|
|||||||
<!-- Add Resources Here -->
|
<!-- Add Resources Here -->
|
||||||
<ControlTheme x:Key="{x:Type NumericUpDown}" TargetType="NumericUpDown">
|
<ControlTheme x:Key="{x:Type NumericUpDown}" TargetType="NumericUpDown">
|
||||||
<Setter Property="NumericUpDown.VerticalContentAlignment" Value="Center" />
|
<Setter Property="NumericUpDown.VerticalContentAlignment" Value="Center" />
|
||||||
|
<Setter Property="NumericUpDown.MinHeight" Value="{DynamicResource NumericUpDownWrapperDefaultHeight}" />
|
||||||
<Setter Property="NumericUpDown.CornerRadius" Value="{DynamicResource NumericUpDownCornerRadius}" />
|
<Setter Property="NumericUpDown.CornerRadius" Value="{DynamicResource NumericUpDownCornerRadius}" />
|
||||||
<Setter Property="NumericUpDown.Template">
|
<Setter Property="NumericUpDown.Template">
|
||||||
<ControlTemplate TargetType="NumericUpDown">
|
<ControlTemplate TargetType="NumericUpDown">
|
||||||
@ -36,6 +37,13 @@
|
|||||||
</ButtonSpinner>
|
</ButtonSpinner>
|
||||||
</ControlTemplate>
|
</ControlTemplate>
|
||||||
</Setter>
|
</Setter>
|
||||||
|
|
||||||
|
<Style Selector="^.Large">
|
||||||
|
<Setter Property="MinHeight" Value="{DynamicResource NumericUpDownWrapperLargeHeight}" />
|
||||||
|
</Style>
|
||||||
|
<Style Selector="^.Small">
|
||||||
|
<Setter Property="MinHeight" Value="{DynamicResource NumericUpDownWrapperSmallHeight}" />
|
||||||
|
</Style>
|
||||||
</ControlTheme>
|
</ControlTheme>
|
||||||
|
|
||||||
</ResourceDictionary>
|
</ResourceDictionary>
|
||||||
|
@ -1,4 +1,7 @@
|
|||||||
<ResourceDictionary xmlns="https://github.com/avaloniaui" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
<ResourceDictionary xmlns="https://github.com/avaloniaui" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
||||||
<!-- Add Resources Here -->
|
<!-- Add Resources Here -->
|
||||||
<CornerRadius x:Key="NumericUpDownCornerRadius">3</CornerRadius>
|
<CornerRadius x:Key="NumericUpDownCornerRadius">3</CornerRadius>
|
||||||
|
<x:Double x:Key="NumericUpDownWrapperDefaultHeight">32</x:Double>
|
||||||
|
<x:Double x:Key="NumericUpDownWrapperSmallHeight">24</x:Double>
|
||||||
|
<x:Double x:Key="NumericUpDownWrapperLargeHeight">40</x:Double>
|
||||||
</ResourceDictionary>
|
</ResourceDictionary>
|
||||||
|
@ -1,4 +1,7 @@
|
|||||||
<ResourceDictionary xmlns="https://github.com/avaloniaui" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
<ResourceDictionary xmlns="https://github.com/avaloniaui" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
|
||||||
<!-- Add Resources Here -->
|
<!-- Add Resources Here -->
|
||||||
<CornerRadius x:Key="NumericUpDownCornerRadius">3</CornerRadius>
|
<CornerRadius x:Key="NumericUpDownCornerRadius">3</CornerRadius>
|
||||||
|
<x:Double x:Key="NumericUpDownWrapperDefaultHeight">32</x:Double>
|
||||||
|
<x:Double x:Key="NumericUpDownWrapperSmallHeight">24</x:Double>
|
||||||
|
<x:Double x:Key="NumericUpDownWrapperLargeHeight">40</x:Double>
|
||||||
</ResourceDictionary>
|
</ResourceDictionary>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user