commit
503af76f0c
@ -11,7 +11,7 @@ Avalonia Theme inspired by Semi Design
|
||||
|
||||
## Installation
|
||||
```bash
|
||||
dotnet add package Semi.Avalonia --version 0.1.0-preview7
|
||||
dotnet add package Semi.Avalonia --version 0.1.0-preview8
|
||||
```
|
||||
Include Semi Design Styles in application:
|
||||
|
||||
@ -25,8 +25,8 @@ That's all.
|
||||
|
||||
DataGrid and ColorPicker are distributed in separated packages. Please install if you need.
|
||||
```bash
|
||||
dotnet add package Semi.Avalonia.ColorPicker --version 0.1.0-preview7
|
||||
dotnet add package Semi.Avalonia.DataGrid --version 0.1.0-preview7
|
||||
dotnet add package Semi.Avalonia.ColorPicker --version 0.1.0-preview8
|
||||
dotnet add package Semi.Avalonia.DataGrid --version 0.1.0-preview8
|
||||
```
|
||||
```xaml
|
||||
<Application.Styles>
|
||||
@ -48,6 +48,7 @@ https://github.com/irihitech/Semi.Avalonia/releases
|
||||
| 0.1.0-preview5.x | 11.0-preview5 |
|
||||
| 0.1.0-preview6.x | 11.0-preview6 |
|
||||
| 0.1.0-preview7.x | 11.0-preview7 |
|
||||
| 0.1.0-preview8.x | 11.0-preview8 |
|
||||
|
||||
**NOTE**
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
<Project>
|
||||
<PropertyGroup>
|
||||
<Nullable>enable</Nullable>
|
||||
<AvaloniaVersion>11.0.0-preview7</AvaloniaVersion>
|
||||
<AvaloniaVersion>11.0.0-preview8</AvaloniaVersion>
|
||||
</PropertyGroup>
|
||||
</Project>
|
||||
|
@ -23,11 +23,10 @@
|
||||
<DataGrid.Columns>
|
||||
<DataGridTemplateColumn Width="70" Header="Color">
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<DataTemplate DataType="viewModels:ColorItemViewModel">
|
||||
<controls:ColorItemControl
|
||||
Width="40"
|
||||
Height="20"
|
||||
x:DataType="viewModels:ColorItemViewModel"
|
||||
Background="{Binding Brush}"
|
||||
CornerRadius="3" />
|
||||
</DataTemplate>
|
||||
@ -35,11 +34,10 @@
|
||||
</DataGridTemplateColumn>
|
||||
<DataGridTemplateColumn Width="*" Header="ResourceKey">
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<DataTemplate DataType="viewModels:ColorItemViewModel">
|
||||
<SelectableTextBlock
|
||||
Margin="12,0,12,0"
|
||||
VerticalAlignment="Center"
|
||||
x:DataType="viewModels:ColorItemViewModel"
|
||||
Text="{Binding ResourceKey}" />
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
@ -47,28 +45,26 @@
|
||||
<DataGridTextColumn
|
||||
Width="*"
|
||||
x:DataType="viewModels:ColorItemViewModel"
|
||||
Binding="{Binding ColorDisplayName}"
|
||||
Binding="{ReflectionBinding ColorDisplayName}"
|
||||
CanUserSort="False"
|
||||
Header="Name" />
|
||||
<DataGridTemplateColumn Width="100" Header="Hex">
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<DataTemplate DataType="viewModels:ColorItemViewModel">
|
||||
<SelectableTextBlock
|
||||
Margin="12,0,12,0"
|
||||
VerticalAlignment="Center"
|
||||
x:DataType="viewModels:ColorItemViewModel"
|
||||
Text="{Binding Hex}" />
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<DataGridTemplateColumn Width="80" Header="Opacity">
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<DataTemplate DataType="viewModels:ColorItemViewModel">
|
||||
<SelectableTextBlock
|
||||
Margin="12,0,12,0"
|
||||
HorizontalAlignment="Right"
|
||||
VerticalAlignment="Center"
|
||||
x:DataType="viewModels:ColorItemViewModel"
|
||||
Text="{Binding Brush.Opacity}" />
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
@ -81,11 +77,10 @@
|
||||
<DataGrid.Columns>
|
||||
<DataGridTemplateColumn Width="70" Header="Color">
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<DataTemplate DataType="viewModels:ColorItemViewModel">
|
||||
<controls:ColorItemControl
|
||||
Width="40"
|
||||
Height="20"
|
||||
x:DataType="viewModels:ColorItemViewModel"
|
||||
Background="{Binding Brush}"
|
||||
CornerRadius="3" />
|
||||
</DataTemplate>
|
||||
@ -93,11 +88,10 @@
|
||||
</DataGridTemplateColumn>
|
||||
<DataGridTemplateColumn Width="*" Header="ResourceKey">
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<DataTemplate DataType="viewModels:ColorItemViewModel">
|
||||
<SelectableTextBlock
|
||||
Margin="12,0,12,0"
|
||||
VerticalAlignment="Center"
|
||||
x:DataType="viewModels:ColorItemViewModel"
|
||||
Text="{Binding ResourceKey}" />
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
@ -105,28 +99,26 @@
|
||||
<DataGridTextColumn
|
||||
Width="*"
|
||||
x:DataType="viewModels:ColorItemViewModel"
|
||||
Binding="{Binding ColorDisplayName}"
|
||||
Binding="{ReflectionBinding ColorDisplayName}"
|
||||
CanUserSort="False"
|
||||
Header="Name" />
|
||||
<DataGridTemplateColumn Width="100" Header="Hex">
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<DataTemplate DataType="viewModels:ColorItemViewModel">
|
||||
<SelectableTextBlock
|
||||
Margin="12,0,12,0"
|
||||
VerticalAlignment="Center"
|
||||
x:DataType="viewModels:ColorItemViewModel"
|
||||
Text="{Binding Hex}" />
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
</DataGridTemplateColumn>
|
||||
<DataGridTemplateColumn Width="80" Header="Opacity">
|
||||
<DataGridTemplateColumn.CellTemplate>
|
||||
<DataTemplate>
|
||||
<DataTemplate DataType="viewModels:ColorItemViewModel">
|
||||
<SelectableTextBlock
|
||||
Margin="12,0,12,0"
|
||||
HorizontalAlignment="Right"
|
||||
VerticalAlignment="Center"
|
||||
x:DataType="viewModels:ColorItemViewModel"
|
||||
Text="{Binding Brush.Opacity}" />
|
||||
</DataTemplate>
|
||||
</DataGridTemplateColumn.CellTemplate>
|
||||
|
@ -3,11 +3,11 @@
|
||||
<TargetFrameworks>net6.0;netstandard2.0</TargetFrameworks>
|
||||
<Nullable>enable</Nullable>
|
||||
<LangVersion>10</LangVersion>
|
||||
<Version>0.1.0-preview7</Version>
|
||||
<Version>0.1.0-preview8</Version>
|
||||
<Authors>IRIHI Technology</Authors>
|
||||
<Description>Avalonia Theme inspired by Semi Design. </Description>
|
||||
<PackageProjectUrl>https://github.com/irihitech/Semi.Avalonia</PackageProjectUrl>
|
||||
<AvaloniaVersion>11.0.0-preview7</AvaloniaVersion>
|
||||
<AvaloniaVersion>11.0.0-preview8</AvaloniaVersion>
|
||||
<PackageLicenseExpression>MIT</PackageLicenseExpression>
|
||||
</PropertyGroup>
|
||||
</Project>
|
@ -167,7 +167,7 @@
|
||||
Orientation="Vertical">
|
||||
<primitives:ColorSlider.IsVisible>
|
||||
<MultiBinding Converter="{x:Static BoolConverters.And}">
|
||||
<Binding Path="IsAlphaVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="IsAlphaVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
</MultiBinding>
|
||||
</primitives:ColorSlider.IsVisible>
|
||||
</primitives:ColorSlider>
|
||||
@ -323,6 +323,7 @@
|
||||
Margin="0,0,12,0"
|
||||
VerticalAlignment="Center"
|
||||
AllowSpin="True"
|
||||
Classes="Small"
|
||||
IsVisible="{TemplateBinding IsComponentTextInputVisible}"
|
||||
Maximum="{Binding Maximum, ElementName=Component1Slider}"
|
||||
Minimum="{Binding Minimum, ElementName=Component1Slider}"
|
||||
@ -353,6 +354,7 @@
|
||||
Margin="0,0,12,0"
|
||||
VerticalAlignment="Center"
|
||||
AllowSpin="True"
|
||||
Classes="Small"
|
||||
IsVisible="{TemplateBinding IsComponentTextInputVisible}"
|
||||
Maximum="{Binding Maximum, ElementName=Component2Slider}"
|
||||
Minimum="{Binding Minimum, ElementName=Component2Slider}"
|
||||
@ -383,6 +385,7 @@
|
||||
Margin="0,0,12,0"
|
||||
VerticalAlignment="Center"
|
||||
AllowSpin="True"
|
||||
Classes="Small"
|
||||
IsVisible="{TemplateBinding IsComponentTextInputVisible}"
|
||||
Maximum="{Binding Maximum, ElementName=Component3Slider}"
|
||||
Minimum="{Binding Minimum, ElementName=Component3Slider}"
|
||||
@ -413,6 +416,7 @@
|
||||
Margin="0,0,12,0"
|
||||
VerticalAlignment="Center"
|
||||
AllowSpin="True"
|
||||
Classes="Small"
|
||||
IsEnabled="{TemplateBinding IsAlphaEnabled}"
|
||||
Maximum="{Binding Maximum, ElementName=AlphaComponentSlider}"
|
||||
Minimum="{Binding Minimum, ElementName=AlphaComponentSlider}"
|
||||
@ -421,8 +425,8 @@
|
||||
Value="{Binding Value, ElementName=AlphaComponentSlider}">
|
||||
<NumericUpDown.IsVisible>
|
||||
<MultiBinding Converter="{x:Static BoolConverters.And}">
|
||||
<Binding Path="IsAlphaVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<Binding Path="IsComponentTextInputVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="IsAlphaVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="IsComponentTextInputVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
</MultiBinding>
|
||||
</NumericUpDown.IsVisible>
|
||||
</NumericUpDown>
|
||||
@ -443,8 +447,8 @@
|
||||
TickFrequency="1">
|
||||
<primitives:ColorSlider.IsVisible>
|
||||
<MultiBinding Converter="{x:Static BoolConverters.And}">
|
||||
<Binding Path="IsAlphaVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<Binding Path="IsComponentSliderVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="IsAlphaVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="IsComponentSliderVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
</MultiBinding>
|
||||
</primitives:ColorSlider.IsVisible>
|
||||
</primitives:ColorSlider>
|
||||
|
@ -259,7 +259,7 @@
|
||||
Orientation="Vertical">
|
||||
<primitives:ColorSlider.IsVisible>
|
||||
<MultiBinding Converter="{x:Static BoolConverters.And}">
|
||||
<Binding Path="IsAlphaVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="IsAlphaVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
</MultiBinding>
|
||||
</primitives:ColorSlider.IsVisible>
|
||||
</primitives:ColorSlider>
|
||||
@ -387,6 +387,7 @@
|
||||
Margin="0,0,12,0"
|
||||
VerticalAlignment="Center"
|
||||
AllowSpin="True"
|
||||
Classes="Small"
|
||||
IsVisible="{TemplateBinding IsComponentTextInputVisible}"
|
||||
Maximum="{Binding Maximum, ElementName=Component1Slider}"
|
||||
Minimum="{Binding Minimum, ElementName=Component1Slider}"
|
||||
@ -417,6 +418,7 @@
|
||||
Margin="0,0,12,0"
|
||||
VerticalAlignment="Center"
|
||||
AllowSpin="True"
|
||||
Classes="Small"
|
||||
IsVisible="{TemplateBinding IsComponentTextInputVisible}"
|
||||
Maximum="{Binding Maximum, ElementName=Component2Slider}"
|
||||
Minimum="{Binding Minimum, ElementName=Component2Slider}"
|
||||
@ -447,6 +449,7 @@
|
||||
Margin="0,0,12,0"
|
||||
VerticalAlignment="Center"
|
||||
AllowSpin="True"
|
||||
Classes="Small"
|
||||
IsVisible="{TemplateBinding IsComponentTextInputVisible}"
|
||||
Maximum="{Binding Maximum, ElementName=Component3Slider}"
|
||||
Minimum="{Binding Minimum, ElementName=Component3Slider}"
|
||||
@ -477,6 +480,7 @@
|
||||
Margin="0,0,12,0"
|
||||
VerticalAlignment="Center"
|
||||
AllowSpin="True"
|
||||
Classes="Small"
|
||||
IsEnabled="{TemplateBinding IsAlphaEnabled}"
|
||||
Maximum="{Binding Maximum, ElementName=AlphaComponentSlider}"
|
||||
Minimum="{Binding Minimum, ElementName=AlphaComponentSlider}"
|
||||
@ -485,8 +489,8 @@
|
||||
Value="{Binding Value, ElementName=AlphaComponentSlider}">
|
||||
<NumericUpDown.IsVisible>
|
||||
<MultiBinding Converter="{x:Static BoolConverters.And}">
|
||||
<Binding Path="IsAlphaVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<Binding Path="IsComponentTextInputVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="IsAlphaVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="IsComponentTextInputVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
</MultiBinding>
|
||||
</NumericUpDown.IsVisible>
|
||||
</NumericUpDown>
|
||||
@ -507,8 +511,8 @@
|
||||
TickFrequency="1">
|
||||
<primitives:ColorSlider.IsVisible>
|
||||
<MultiBinding Converter="{x:Static BoolConverters.And}">
|
||||
<Binding Path="IsAlphaVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<Binding Path="IsComponentSliderVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="IsAlphaVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="IsComponentSliderVisible" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
</MultiBinding>
|
||||
</primitives:ColorSlider.IsVisible>
|
||||
</primitives:ColorSlider>
|
||||
|
@ -4,7 +4,7 @@
|
||||
|
||||
<PropertyGroup>
|
||||
<Title>Semi.Avalonia.ColorPicker</Title>
|
||||
<PackageReleaseNotes>Update to Avalonia 11.0.0-preview7</PackageReleaseNotes>
|
||||
<PackageReleaseNotes>Update to Avalonia 11.0.0-preview8</PackageReleaseNotes>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
@ -4,7 +4,7 @@
|
||||
|
||||
<PropertyGroup>
|
||||
<Title>Semi.Avalonia.DataGrid</Title>
|
||||
<PackageReleaseNotes>Update to Avalonia 11.0.0-preview7</PackageReleaseNotes>
|
||||
<PackageReleaseNotes>Update to Avalonia 11.0.0-preview8</PackageReleaseNotes>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
@ -141,7 +141,8 @@
|
||||
HorizontalAlignment="Center"
|
||||
VerticalAlignment="Center"
|
||||
ItemContainerTheme="{DynamicResource CarouselIndicatorDotListBoxItem}"
|
||||
ItemsSource="{TemplateBinding ItemsSource,
|
||||
ItemsSource="{TemplateBinding ItemCount,
|
||||
Mode=OneWay,
|
||||
Converter={StaticResource ItemsConverter}}"
|
||||
SelectedIndex="{Binding SelectedIndex, RelativeSource={RelativeSource TemplatedParent}, Mode=TwoWay}">
|
||||
<ListBox.ItemsPanel>
|
||||
|
@ -27,10 +27,10 @@
|
||||
RenderTransform="{x:Null}">
|
||||
<RepeatButton.IsVisible>
|
||||
<MultiBinding Converter="{x:Static converters:MenuScrollingVisibilityConverter.Instance}" ConverterParameter="0">
|
||||
<Binding Path="VerticalScrollBarVisibility" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<Binding Path="Offset.Y" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<Binding Path="Extent.Height" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<Binding Path="Viewport.Height" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="VerticalScrollBarVisibility" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="Offset.Y" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="Extent.Height" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="Viewport.Height" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
</MultiBinding>
|
||||
</RepeatButton.IsVisible>
|
||||
<PathIcon
|
||||
@ -50,10 +50,10 @@
|
||||
RenderTransform="{x:Null}">
|
||||
<RepeatButton.IsVisible>
|
||||
<MultiBinding Converter="{x:Static converters:MenuScrollingVisibilityConverter.Instance}" ConverterParameter="100">
|
||||
<Binding Path="VerticalScrollBarVisibility" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<Binding Path="Offset.Y" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<Binding Path="Extent.Height" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<Binding Path="Viewport.Height" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="VerticalScrollBarVisibility" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="Offset.Y" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="Extent.Height" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="Viewport.Height" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
</MultiBinding>
|
||||
</RepeatButton.IsVisible>
|
||||
<PathIcon
|
||||
|
@ -158,7 +158,7 @@
|
||||
<TextBlock.Text>
|
||||
<MultiBinding Converter="{StaticResource StringFormatConverter}">
|
||||
<TemplateBinding Property="ProgressTextFormat" />
|
||||
<Binding Path="Value" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="Value" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<TemplateBinding Property="Percentage" />
|
||||
<TemplateBinding Property="Minimum" />
|
||||
<TemplateBinding Property="Maximum" />
|
||||
@ -211,13 +211,13 @@
|
||||
<Style.Animations>
|
||||
<Animation IterationCount="Infinite" Duration="0:0:2">
|
||||
<KeyFrame KeySpline="0.4,0,0.6,1" KeyTime="0:0:0">
|
||||
<Setter Property="TranslateTransform.X" Value="{Binding $parent[ProgressBar].TemplateProperties.ContainerAnimationStartPosition}" />
|
||||
<Setter Property="TranslateTransform.X" Value="{Binding $parent[ProgressBar].TemplateSettings.ContainerAnimationStartPosition}" />
|
||||
</KeyFrame>
|
||||
<KeyFrame KeySpline="0.4,0,0.6,1" KeyTime="0:0:1.5">
|
||||
<Setter Property="TranslateTransform.X" Value="{Binding $parent[ProgressBar].TemplateProperties.ContainerAnimationEndPosition}" />
|
||||
<Setter Property="TranslateTransform.X" Value="{Binding $parent[ProgressBar].TemplateSettings.ContainerAnimationEndPosition}" />
|
||||
</KeyFrame>
|
||||
<KeyFrame KeySpline="0.4,0,0.6,1" KeyTime="0:0:2">
|
||||
<Setter Property="TranslateTransform.X" Value="{Binding $parent[ProgressBar].TemplateProperties.ContainerAnimationEndPosition}" />
|
||||
<Setter Property="TranslateTransform.X" Value="{Binding $parent[ProgressBar].TemplateSettings.ContainerAnimationEndPosition}" />
|
||||
</KeyFrame>
|
||||
</Animation>
|
||||
</Style.Animations>
|
||||
@ -226,13 +226,13 @@
|
||||
<Style.Animations>
|
||||
<Animation IterationCount="Infinite" Duration="0:0:2">
|
||||
<KeyFrame KeySpline="0.4,0,0.6,1" KeyTime="0:0:0">
|
||||
<Setter Property="TranslateTransform.X" Value="{Binding $parent[ProgressBar].TemplateProperties.Container2AnimationStartPosition}" />
|
||||
<Setter Property="TranslateTransform.X" Value="{Binding $parent[ProgressBar].TemplateSettings.Container2AnimationStartPosition}" />
|
||||
</KeyFrame>
|
||||
<KeyFrame KeySpline="0.4,0,0.6,1" KeyTime="0:0:0.75">
|
||||
<Setter Property="TranslateTransform.X" Value="{Binding $parent[ProgressBar].TemplateProperties.Container2AnimationStartPosition}" />
|
||||
<Setter Property="TranslateTransform.X" Value="{Binding $parent[ProgressBar].TemplateSettings.Container2AnimationStartPosition}" />
|
||||
</KeyFrame>
|
||||
<KeyFrame KeySpline="0.4,0,0.6,1" KeyTime="0:0:2">
|
||||
<Setter Property="TranslateTransform.X" Value="{Binding $parent[ProgressBar].TemplateProperties.Container2AnimationEndPosition}" />
|
||||
<Setter Property="TranslateTransform.X" Value="{Binding $parent[ProgressBar].TemplateSettings.Container2AnimationEndPosition}" />
|
||||
</KeyFrame>
|
||||
</Animation>
|
||||
</Style.Animations>
|
||||
@ -241,13 +241,13 @@
|
||||
<Style.Animations>
|
||||
<Animation IterationCount="Infinite" Duration="0:0:2">
|
||||
<KeyFrame KeySpline="0.4,0,0.6,1" KeyTime="0:0:0">
|
||||
<Setter Property="TranslateTransform.Y" Value="{Binding $parent[ProgressBar].TemplateProperties.ContainerAnimationStartPosition}" />
|
||||
<Setter Property="TranslateTransform.Y" Value="{Binding $parent[ProgressBar].TemplateSettings.ContainerAnimationStartPosition}" />
|
||||
</KeyFrame>
|
||||
<KeyFrame KeySpline="0.4,0,0.6,1" KeyTime="0:0:1.5">
|
||||
<Setter Property="TranslateTransform.Y" Value="{Binding $parent[ProgressBar].TemplateProperties.ContainerAnimationEndPosition}" />
|
||||
<Setter Property="TranslateTransform.Y" Value="{Binding $parent[ProgressBar].TemplateSettings.ContainerAnimationEndPosition}" />
|
||||
</KeyFrame>
|
||||
<KeyFrame KeySpline="0.4,0,0.6,1" KeyTime="0:0:2">
|
||||
<Setter Property="TranslateTransform.Y" Value="{Binding $parent[ProgressBar].TemplateProperties.ContainerAnimationEndPosition}" />
|
||||
<Setter Property="TranslateTransform.Y" Value="{Binding $parent[ProgressBar].TemplateSettings.ContainerAnimationEndPosition}" />
|
||||
</KeyFrame>
|
||||
</Animation>
|
||||
</Style.Animations>
|
||||
@ -256,28 +256,28 @@
|
||||
<Style.Animations>
|
||||
<Animation IterationCount="Infinite" Duration="0:0:2">
|
||||
<KeyFrame KeySpline="0.4,0,0.6,1" KeyTime="0:0:0">
|
||||
<Setter Property="TranslateTransform.Y" Value="{Binding $parent[ProgressBar].TemplateProperties.Container2AnimationStartPosition}" />
|
||||
<Setter Property="TranslateTransform.Y" Value="{Binding $parent[ProgressBar].TemplateSettings.Container2AnimationStartPosition}" />
|
||||
</KeyFrame>
|
||||
<KeyFrame KeySpline="0.4,0,0.6,1" KeyTime="0:0:0.75">
|
||||
<Setter Property="TranslateTransform.Y" Value="{Binding $parent[ProgressBar].TemplateProperties.Container2AnimationStartPosition}" />
|
||||
<Setter Property="TranslateTransform.Y" Value="{Binding $parent[ProgressBar].TemplateSettings.Container2AnimationStartPosition}" />
|
||||
</KeyFrame>
|
||||
<KeyFrame KeySpline="0.4,0,0.6,1" KeyTime="0:0:2">
|
||||
<Setter Property="TranslateTransform.Y" Value="{Binding $parent[ProgressBar].TemplateProperties.Container2AnimationEndPosition}" />
|
||||
<Setter Property="TranslateTransform.Y" Value="{Binding $parent[ProgressBar].TemplateSettings.Container2AnimationEndPosition}" />
|
||||
</KeyFrame>
|
||||
</Animation>
|
||||
</Style.Animations>
|
||||
</Style>
|
||||
<Style Selector="^:horizontal /template/ Border#IndeterminateProgressBarIndicator">
|
||||
<Setter Property="Width" Value="{Binding $parent[ProgressBar].TemplateProperties.ContainerWidth}" />
|
||||
<Setter Property="Width" Value="{Binding $parent[ProgressBar].TemplateSettings.ContainerWidth}" />
|
||||
</Style>
|
||||
<Style Selector="^:horizontal /template/ Border#IndeterminateProgressBarIndicator2">
|
||||
<Setter Property="Width" Value="{Binding $parent[ProgressBar].TemplateProperties.Container2Width}" />
|
||||
<Setter Property="Width" Value="{Binding $parent[ProgressBar].TemplateSettings.Container2Width}" />
|
||||
</Style>
|
||||
<Style Selector="^:vertical /template/ Border#IndeterminateProgressBarIndicator">
|
||||
<Setter Property="Height" Value="{Binding $parent[ProgressBar].TemplateProperties.ContainerWidth}" />
|
||||
<Setter Property="Height" Value="{Binding $parent[ProgressBar].TemplateSettings.ContainerWidth}" />
|
||||
</Style>
|
||||
<Style Selector="^:vertical /template/ Border#IndeterminateProgressBarIndicator2">
|
||||
<Setter Property="Height" Value="{Binding $parent[ProgressBar].TemplateProperties.Container2Width}" />
|
||||
<Setter Property="Height" Value="{Binding $parent[ProgressBar].TemplateSettings.Container2Width}" />
|
||||
</Style>
|
||||
<Style Selector="^.Left">
|
||||
<Style Selector="^:horizontal /template/ LayoutTransformControl#PART_LayoutTransformControl">
|
||||
|
@ -303,10 +303,10 @@
|
||||
DockPanel.Dock="Top">
|
||||
<RepeatButton.IsVisible>
|
||||
<MultiBinding Converter="{x:Static converters:MenuScrollingVisibilityConverter.Instance}" ConverterParameter="0">
|
||||
<Binding Path="VerticalScrollBarVisibility" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<Binding Path="Offset.Y" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<Binding Path="Extent.Height" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<Binding Path="Viewport.Height" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="VerticalScrollBarVisibility" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="Offset.Y" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="Extent.Height" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="Viewport.Height" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
</MultiBinding>
|
||||
</RepeatButton.IsVisible>
|
||||
<Path Data="M 0 4 L 8 4 L 4 0 Z" />
|
||||
@ -318,10 +318,10 @@
|
||||
DockPanel.Dock="Bottom">
|
||||
<RepeatButton.IsVisible>
|
||||
<MultiBinding Converter="{x:Static converters:MenuScrollingVisibilityConverter.Instance}" ConverterParameter="100">
|
||||
<Binding Path="VerticalScrollBarVisibility" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<Binding Path="Offset.Y" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<Binding Path="Extent.Height" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<Binding Path="Viewport.Height" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="VerticalScrollBarVisibility" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="Offset.Y" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="Extent.Height" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
<ReflectionBinding Path="Viewport.Height" RelativeSource="{RelativeSource TemplatedParent}" />
|
||||
</MultiBinding>
|
||||
</RepeatButton.IsVisible>
|
||||
<Path Data="M 0 0 L 4 4 L 8 0 Z" />
|
||||
|
@ -302,42 +302,51 @@
|
||||
BorderBrush="{TemplateBinding BorderBrush}"
|
||||
BorderThickness="{TemplateBinding BorderThickness}"
|
||||
CornerRadius="{TemplateBinding CornerRadius}">
|
||||
<ScrollViewer
|
||||
Margin="{TemplateBinding Padding}"
|
||||
AllowAutoHide="{TemplateBinding (ScrollViewer.AllowAutoHide)}"
|
||||
HorizontalScrollBarVisibility="{TemplateBinding (ScrollViewer.HorizontalScrollBarVisibility)}"
|
||||
IsScrollChainingEnabled="{TemplateBinding (ScrollViewer.IsScrollChainingEnabled)}"
|
||||
VerticalScrollBarVisibility="{TemplateBinding (ScrollViewer.VerticalScrollBarVisibility)}">
|
||||
<Panel>
|
||||
<TextBlock
|
||||
Name="PART_Watermark"
|
||||
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
|
||||
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
|
||||
IsVisible="{TemplateBinding Text,
|
||||
Converter={x:Static StringConverters.IsNullOrEmpty}}"
|
||||
Opacity="0.5"
|
||||
Text="{TemplateBinding Watermark}"
|
||||
TextAlignment="{TemplateBinding TextAlignment}"
|
||||
TextWrapping="{TemplateBinding TextWrapping}" />
|
||||
<TextPresenter
|
||||
Name="PART_TextPresenter"
|
||||
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
|
||||
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
|
||||
CaretBrush="{TemplateBinding CaretBrush}"
|
||||
CaretIndex="{TemplateBinding CaretIndex}"
|
||||
LineHeight="{TemplateBinding LineHeight}"
|
||||
PasswordChar="{TemplateBinding PasswordChar}"
|
||||
RevealPassword="{TemplateBinding RevealPassword}"
|
||||
SelectionBrush="{TemplateBinding SelectionBrush}"
|
||||
SelectionEnd="{TemplateBinding SelectionEnd}"
|
||||
SelectionForegroundBrush="{TemplateBinding SelectionForegroundBrush}"
|
||||
SelectionStart="{TemplateBinding SelectionStart}"
|
||||
Text="{TemplateBinding Text,
|
||||
Mode=TwoWay}"
|
||||
TextAlignment="{TemplateBinding TextAlignment}"
|
||||
TextWrapping="{TemplateBinding TextWrapping}" />
|
||||
</Panel>
|
||||
</ScrollViewer>
|
||||
<Grid Margin="{TemplateBinding Padding}" ColumnDefinitions="Auto, *">
|
||||
<ContentPresenter
|
||||
Grid.Column="0"
|
||||
Padding="{DynamicResource TextBoxInnerLeftContentPadding}"
|
||||
VerticalAlignment="Center"
|
||||
Content="{TemplateBinding InnerLeftContent}"
|
||||
Foreground="{DynamicResource TextBoxInnerForeground}"
|
||||
IsVisible="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=InnerLeftContent, Converter={x:Static ObjectConverters.IsNotNull}}" />
|
||||
<ScrollViewer
|
||||
Grid.Column="1"
|
||||
AllowAutoHide="{TemplateBinding (ScrollViewer.AllowAutoHide)}"
|
||||
HorizontalScrollBarVisibility="{TemplateBinding (ScrollViewer.HorizontalScrollBarVisibility)}"
|
||||
IsScrollChainingEnabled="{TemplateBinding (ScrollViewer.IsScrollChainingEnabled)}"
|
||||
VerticalScrollBarVisibility="{TemplateBinding (ScrollViewer.VerticalScrollBarVisibility)}">
|
||||
<Panel>
|
||||
<TextBlock
|
||||
Name="PART_Watermark"
|
||||
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
|
||||
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
|
||||
IsVisible="{TemplateBinding Text,
|
||||
Converter={x:Static StringConverters.IsNullOrEmpty}}"
|
||||
Opacity="0.5"
|
||||
Text="{TemplateBinding Watermark}"
|
||||
TextAlignment="{TemplateBinding TextAlignment}"
|
||||
TextWrapping="{TemplateBinding TextWrapping}" />
|
||||
<TextPresenter
|
||||
Name="PART_TextPresenter"
|
||||
HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
|
||||
VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
|
||||
CaretBrush="{TemplateBinding CaretBrush}"
|
||||
CaretIndex="{TemplateBinding CaretIndex}"
|
||||
LineHeight="{TemplateBinding LineHeight}"
|
||||
PasswordChar="{TemplateBinding PasswordChar}"
|
||||
RevealPassword="{TemplateBinding RevealPassword}"
|
||||
SelectionBrush="{TemplateBinding SelectionBrush}"
|
||||
SelectionEnd="{TemplateBinding SelectionEnd}"
|
||||
SelectionForegroundBrush="{TemplateBinding SelectionForegroundBrush}"
|
||||
SelectionStart="{TemplateBinding SelectionStart}"
|
||||
Text="{TemplateBinding Text,
|
||||
Mode=TwoWay}"
|
||||
TextAlignment="{TemplateBinding TextAlignment}"
|
||||
TextWrapping="{TemplateBinding TextWrapping}" />
|
||||
</Panel>
|
||||
</ScrollViewer>
|
||||
</Grid>
|
||||
</Border>
|
||||
</DataValidationErrors>
|
||||
</ControlTemplate>
|
||||
|
@ -12,9 +12,9 @@ public class ItemToObjectConverter: IValueConverter
|
||||
{
|
||||
public object Convert(object? value, Type targetType, object? parameter, CultureInfo culture)
|
||||
{
|
||||
if (value is ItemCollection list)
|
||||
if (value is int i)
|
||||
{
|
||||
return list.Select(a => new object());
|
||||
return Enumerable.Repeat(new object(), i).ToList();
|
||||
}
|
||||
return new List<object>();
|
||||
}
|
||||
|
@ -4,7 +4,7 @@
|
||||
|
||||
<PropertyGroup>
|
||||
<Title>Semi.Avalonia</Title>
|
||||
<PackageReleaseNotes>Update to Avalonia 11.0.0-preview7</PackageReleaseNotes>
|
||||
<PackageReleaseNotes>Update to Avalonia 11.0.0-preview8</PackageReleaseNotes>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
Loading…
x
Reference in New Issue
Block a user