completed the branch

This commit is contained in:
NaBian committed 2019-08-03 22:58:54 +08:00
1 parent fc3fd6b533
commit f642f0e181
6 files changed
+64 -42

No files matched your search

@@ -2,19 +2,30 @@
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:controls="clr-namespace:HandyControl.Controls">
<Style x:Key="RunningBlockBaseStyle" TargetType="controls:RunningBlock">
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="BaseStyle.xaml"/>
<ResourceDictionary Source="../../Basic/Sizes.xaml"/>
</ResourceDictionary.MergedDictionaries>
<Style x:Key="RunningBlockBaseStyle" BasedOn="{StaticResource BaseStyle}" TargetType="controls:RunningBlock">
<Setter Property="controls:BorderElement.CornerRadius" Value="{StaticResource DefaultCornerRadius}"/>
<Setter Property="BorderBrush" Value="{DynamicResource BorderBrush}"/>
<Setter Property="BorderThickness" Value="1"/>
<Setter Property="Padding" Value="0,10"/>
<Setter Property="Template">
<Setter.Value>
<ControlTemplate TargetType="controls:RunningBlock">
<controls:SimplePanel ClipToBounds="True">
<ContentPresenter x:Name="PART_ContentElement" RenderTransformOrigin="0.5,0.5">
<ContentPresenter.RenderTransform>
<TransformGroup>
<TranslateTransform X="0"/>
</TransformGroup>
</ContentPresenter.RenderTransform>
</ContentPresenter>
</controls:SimplePanel>
<Border CornerRadius="{Binding Path=(controls:BorderElement.CornerRadius),RelativeSource={RelativeSource TemplatedParent}}" Padding="{TemplateBinding Padding}" BorderThickness="{TemplateBinding BorderThickness}" BorderBrush="{TemplateBinding BorderBrush}" Background="{TemplateBinding Background}" ClipToBounds="True">
<controls:SimplePanel HorizontalAlignment="Left" x:Name="PART_Panel">
<ContentPresenter x:Name="PART_ContentElement" RenderTransformOrigin="0.5,0.5" HorizontalAlignment="Left">
<ContentPresenter.RenderTransform>
<TransformGroup>
<TranslateTransform X="0"/>
</TransformGroup>
</ContentPresenter.RenderTransform>
</ContentPresenter>
</controls:SimplePanel>
</Border>
</ControlTemplate>
</Setter.Value>
</Setter>