<!-- Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT License. See LICENSE in the project root for license information. -->
<ResourceDictionary
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:local="clr-namespace:ModernWpf.Controls"
    xmlns:primitives="clr-namespace:ModernWpf.Controls.Primitives">

    <Style x:Key="DefaultProgressBarStyle" TargetType="ProgressBar">
        <Setter Property="OverridesDefaultStyle" Value="True" />
        <Setter Property="Foreground" Value="{DynamicResource ProgressBarForeground}" />
        <Setter Property="Background" Value="{DynamicResource ProgressBarBackground}" />
        <Setter Property="BorderThickness" Value="{DynamicResource ProgressBarBorderThemeThickness}" />
        <Setter Property="BorderBrush" Value="{DynamicResource ProgressBarBorderBrush}" />
        <Setter Property="MinHeight" Value="{DynamicResource ProgressBarThemeMinHeight}" />
        <Setter Property="IsTabStop" Value="False" />
        <Setter Property="VerticalAlignment" Value="Center" />
        <Setter Property="primitives:ControlHelper.CornerRadius" Value="{DynamicResource ControlCornerRadius}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="ProgressBar">
                    <local:ProgressBar
                        Foreground="{TemplateBinding Foreground}"
                        Background="{TemplateBinding Background}"
                        BorderThickness="{TemplateBinding BorderThickness}"
                        BorderBrush="{TemplateBinding BorderBrush}"
                        MinHeight="{TemplateBinding MinHeight}"
                        IsTabStop="{TemplateBinding IsTabStop}"
                        VerticalAlignment="{TemplateBinding VerticalAlignment}"
                        CornerRadius="{TemplateBinding primitives:ControlHelper.CornerRadius}"
                        Minimum="{TemplateBinding Minimum}"
                        Maximum="{TemplateBinding Maximum}"
                        Value="{TemplateBinding Value}"
                        IsIndeterminate="{TemplateBinding IsIndeterminate}" />
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <Style TargetType="ProgressBar" BasedOn="{StaticResource DefaultProgressBarStyle}" />

</ResourceDictionary>