<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:hc="clr-namespace:HandyControl.Controls">

    <!--  用于包裹一个区域  -->
    <Style x:Key="BorderRegion" TargetType="Border">
        <Setter Property="CornerRadius" Value="{StaticResource DefaultCornerRadius}" />
        <Setter Property="Padding" Value="10" />
        <Setter Property="Background" Value="{DynamicResource RegionBrush}" />
        <Setter Property="BorderThickness" Value="1" />
        <Setter Property="BorderBrush" Value="{DynamicResource BorderBrush}" />
    </Style>

    <Style x:Key="BorderTipBaseStyle" TargetType="Border">
        <Setter Property="CornerRadius" Value="{StaticResource DefaultCornerRadius}" />
        <Setter Property="Padding" Value="10" />
        <Setter Property="BorderThickness" Value="5,0,0,0" />
    </Style>

    <Style
        x:Key="BorderTipPrimary"
        TargetType="Border"
        BasedOn="{StaticResource BorderTipBaseStyle}">
        <Setter Property="Background" Value="{DynamicResource LightPrimaryBrush}" />
        <Setter Property="BorderBrush" Value="{DynamicResource PrimaryBrush}" />
    </Style>

    <Style
        x:Key="BorderTipDanger"
        TargetType="Border"
        BasedOn="{StaticResource BorderTipBaseStyle}">
        <Setter Property="Background" Value="{DynamicResource LightDangerBrush}" />
        <Setter Property="BorderBrush" Value="{DynamicResource DangerBrush}" />
    </Style>

    <Style
        x:Key="BorderTipWarning"
        TargetType="Border"
        BasedOn="{StaticResource BorderTipBaseStyle}">
        <Setter Property="Background" Value="{DynamicResource LightWarningBrush}" />
        <Setter Property="BorderBrush" Value="{DynamicResource WarningBrush}" />
    </Style>

    <Style
        x:Key="BorderTipInfo"
        TargetType="Border"
        BasedOn="{StaticResource BorderTipBaseStyle}">
        <Setter Property="Background" Value="{DynamicResource LightInfoBrush}" />
        <Setter Property="BorderBrush" Value="{DynamicResource InfoBrush}" />
    </Style>

    <Style
        x:Key="BorderTipSuccess"
        TargetType="Border"
        BasedOn="{StaticResource BorderTipBaseStyle}">
        <Setter Property="Background" Value="{DynamicResource LightSuccessBrush}" />
        <Setter Property="BorderBrush" Value="{DynamicResource SuccessBrush}" />
    </Style>

    <Style x:Key="BorderVerticallySplitter" TargetType="Border">
        <Setter Property="Width" Value="1" />
        <Setter Property="HorizontalAlignment" Value="Left" />
        <Setter Property="Background" Value="{DynamicResource ThirdlyTextBrush}" />
    </Style>

    <Style x:Key="BorderHorizontallySplitter" TargetType="Border">
        <Setter Property="Height" Value="1" />
        <Setter Property="VerticalAlignment" Value="Top" />
        <Setter Property="Background" Value="{DynamicResource ThirdlyTextBrush}" />
    </Style>

    <Style x:Key="BorderCircular" TargetType="Border">
        <Setter Property="hc:BorderElement.Circular" Value="True" />
    </Style>

    <Style x:Key="BorderClip" TargetType="Border">
        <Setter Property="Clip">
            <Setter.Value>
                <MultiBinding Converter="{StaticResource BorderClipConverter}">
                    <Binding Path="ActualWidth" RelativeSource="{RelativeSource Self}" />
                    <Binding Path="ActualHeight" RelativeSource="{RelativeSource Self}" />
                    <Binding Path="CornerRadius" RelativeSource="{RelativeSource Self}" />
                </MultiBinding>
            </Setter.Value>
        </Setter>
    </Style>

    <Style
        x:Key="BorderCircularClip"
        TargetType="Border"
        BasedOn="{StaticResource BorderCircular}">
        <Setter Property="Clip">
            <Setter.Value>
                <MultiBinding Converter="{StaticResource BorderCircularClipConverter}">
                    <Binding Path="ActualWidth" RelativeSource="{RelativeSource Self}" />
                    <Binding Path="ActualHeight" RelativeSource="{RelativeSource Self}" />
                    <Binding Path="CornerRadius" RelativeSource="{RelativeSource Self}" />
                </MultiBinding>
            </Setter.Value>
        </Setter>
    </Style>

</ResourceDictionary>
