<UserControl x:Class="Ink_Canvas.Controls.LabeledToggleSwitch"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:ui="http://schemas.inkore.net/lib/ui/wpf/modern"
             xmlns:ikw="http://schemas.inkore.net/lib/ui/wpf">
    <ikw:SimpleStackPanel Spacing="4">
        <ikw:SimpleStackPanel Orientation="Horizontal" HorizontalAlignment="Left">
            <TextBlock Text="{Binding Label, RelativeSource={RelativeSource AncestorType=UserControl}}" 
                       VerticalAlignment="Center" 
                       Foreground="#fafafa" 
                       FontSize="14" 
                       Margin="0,0,16,0"/>
            <ui:ToggleSwitch x:Name="ToggleSwitch"
                              IsOn="{Binding IsOn, RelativeSource={RelativeSource AncestorType=UserControl}, Mode=TwoWay}"
                              FontWeight="Bold"
                              Toggled="ToggleSwitch_Toggled"/>
        </ikw:SimpleStackPanel>
        <TextBlock x:Name="HintTextBlock" 
                   Text="{Binding Hint, RelativeSource={RelativeSource AncestorType=UserControl}}"
                   TextWrapping="Wrap" 
                   Foreground="#a1a1aa" 
                   Visibility="Collapsed"/>
    </ikw:SimpleStackPanel>
</UserControl>
