This commit is contained in:
NaBian committed 2022-10-04 23:42:18 +08:00
1 parent a7aba69403
commit 5e364ff1e7
5 files changed
+210 -334

No files matched your search

@@ -1,81 +1,74 @@
<UserControl x:Class="HandyControlDemo.UserControl.ToolBarDemoCtl"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:hc="https://handyorg.github.io/handycontrol"
xmlns:langs="clr-namespace:HandyControlDemo.Properties.Langs"
xmlns:ex="clr-namespace:HandyControlDemo.Tools.Extension"
DataContext="{Binding InputElementDemo,Source={StaticResource Locator}}"
Background="{DynamicResource RegionBrush}">
<UserControl x:Class="HandyControlDemo.UserControl.ToolBarDemoCtl" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:hc="https://handyorg.github.io/handycontrol" xmlns:langs="clr-namespace:HandyControlDemo.Properties.Langs" xmlns:ex="clr-namespace:HandyControlDemo.Tools.Extension" DataContext="{Binding InputElementDemo,Source={StaticResource Locator}}" Background="{DynamicResource RegionBrush}">
<hc:TransitioningContentControl>
<StackPanel Margin="32">
<ToolBarTray VerticalAlignment="Center">
<ToolBar Padding="6" Header="{ex:Lang Key={x:Static langs:LangKeys.Title}}">
<CheckBox IsChecked="True" Margin="10,0,0,0"/>
<Separator Margin="10,0,0,0"/>
<RadioButton Margin="10,0,0,0"/>
<ToolBar Margin="0,0,4,4" Header="{ex:Lang Key={x:Static langs:LangKeys.Title}}">
<CheckBox IsChecked="True" Margin="10,0,0,0" />
<Separator Margin="10,0,0,0" />
<RadioButton Margin="10,0,0,0" />
<StackPanel Orientation="Horizontal">
<RadioButton IsChecked="True" Margin="10,0,0,0"/>
<RadioButton Margin="10,0,0,0"/>
<RadioButton IsChecked="True" Margin="10,0,0,0" />
<RadioButton Margin="10,0,0,0" />
</StackPanel>
<Button Content="{ex:Lang Key={x:Static langs:LangKeys.Button}}" Margin="10,0,0,0"/>
<Button Content="{ex:Lang Key={x:Static langs:LangKeys.Button}}" Margin="10,0,0,0" Style="{StaticResource ButtonPrimary}"/>
<Button Content="{ex:Lang Key={x:Static langs:LangKeys.Button}}" Margin="10,0,0,0" />
<Button Content="{ex:Lang Key={x:Static langs:LangKeys.Button}}" Margin="10,0,0,0" Style="{StaticResource ButtonPrimary}" />
</ToolBar>
<ToolBar Band="1" Padding="6">
<ComboBox Margin="10,0,0,0" ItemsSource="{Binding DataList}" SelectedIndex="0" Width="230"/>
<TextBox Text="{ex:Lang Key={x:Static langs:LangKeys.Text},Converter={StaticResource StringRepeatConverter},ConverterParameter=4,Mode=OneWay}" Margin="10,0,0,0" Width="230"/>
<ToolBar Margin="0,0,4,4" Band="1">
<ComboBox Margin="10,0,0,0" ItemsSource="{Binding DataList}" SelectedIndex="0" Width="230" />
<TextBox Text="{ex:Lang Key={x:Static langs:LangKeys.Text},Converter={StaticResource StringRepeatConverter},ConverterParameter=4,Mode=OneWay}" Margin="10,0,0,0" Width="230" />
</ToolBar>
<ToolBar Band="0" Padding="6">
<ToolBar Margin="0,0,4,4" Band="0">
<Menu Background="Transparent" VerticalAlignment="Center">
<MenuItem Header="{ex:Lang Key={x:Static langs:LangKeys.Repository}}">
<MenuItem Header="GitHub">
<MenuItem.Icon>
<Path Data="{StaticResource GithubGeometry}" Fill="{DynamicResource PrimaryTextBrush}"/>
<Path Data="{StaticResource GithubGeometry}" Fill="{DynamicResource PrimaryTextBrush}" />
</MenuItem.Icon>
</MenuItem>
<MenuItem Header="NuGet">
<MenuItem.Icon>
<Path Data="{StaticResource NugetGeometry}" Fill="#224880"/>
<Path Data="{StaticResource NugetGeometry}" Fill="#224880" />
</MenuItem.Icon>
</MenuItem>
</MenuItem>
<MenuItem Header="{ex:Lang Key={x:Static langs:LangKeys.About}}">
<MenuItem Header="{ex:Lang Key={x:Static langs:LangKeys.Email}}">
<MenuItem.Icon>
<Path Data="{StaticResource EmailGeometry}" Fill="{DynamicResource PrimaryBrush}"/>
<Path Data="{StaticResource EmailGeometry}" Fill="{DynamicResource PrimaryBrush}" />
</MenuItem.Icon>
</MenuItem>
<MenuItem Header="{ex:Lang Key={x:Static langs:LangKeys.Blog}}">
<MenuItem.Icon>
<Path Data="{StaticResource CnblogsGeometry}" Fill="{DynamicResource PrimaryTextBrush}"/>
<Path Data="{StaticResource CnblogsGeometry}" Fill="{DynamicResource PrimaryTextBrush}" />
</MenuItem.Icon>
</MenuItem>
</MenuItem>
<MenuItem Header="{ex:Lang Key={x:Static langs:LangKeys.Contributors}}"/>
<MenuItem Header="{ex:Lang Key={x:Static langs:LangKeys.Contributors}}" />
</Menu>
</ToolBar>
</ToolBarTray>
<ToolBarTray Orientation="Vertical" Margin="0,16,0,0">
<ToolBar Padding="6" Header="{ex:Lang Key={x:Static langs:LangKeys.Title}}">
<CheckBox IsChecked="True" Margin="0,10,0,0" HorizontalAlignment="Center"/>
<Separator Margin="0,10,0,0"/>
<RadioButton Margin="0,10,0,0"/>
<ToolBar Margin="0,0,4,4" Header="{ex:Lang Key={x:Static langs:LangKeys.Title}}">
<CheckBox IsChecked="True" Margin="0,10,0,0" HorizontalAlignment="Center" />
<Separator Margin="0,10,0,0" />
<RadioButton Margin="0,10,0,0" />
<StackPanel>
<RadioButton IsChecked="True" Margin="0,10,0,0"/>
<RadioButton Margin="0,10,0,0"/>
<RadioButton IsChecked="True" Margin="0,10,0,0" />
<RadioButton Margin="0,10,0,0" />
</StackPanel>
<Button Content="{ex:Lang Key={x:Static langs:LangKeys.Button}}" Margin="0,10,0,0"/>
<Button Content="{ex:Lang Key={x:Static langs:LangKeys.Button}}" Margin="0,10,0,0" Style="{StaticResource ButtonPrimary}"/>
<Button Content="{ex:Lang Key={x:Static langs:LangKeys.Button}}" Margin="0,10,0,0" />
<Button Content="{ex:Lang Key={x:Static langs:LangKeys.Button}}" Margin="0,10,0,0" Style="{StaticResource ButtonPrimary}" />
</ToolBar>
<ToolBar Band="1" Padding="6" Header="{ex:Lang Key={x:Static langs:LangKeys.Title}}">
<CheckBox IsChecked="True" Margin="0,10,0,0" HorizontalAlignment="Center"/>
<Separator Margin="0,10,0,0"/>
<RadioButton Margin="0,10,0,0"/>
<ToolBar Margin="0,0,4,4" Band="1" Header="{ex:Lang Key={x:Static langs:LangKeys.Title}}">
<CheckBox IsChecked="True" Margin="0,10,0,0" HorizontalAlignment="Center" />
<Separator Margin="0,10,0,0" />
<RadioButton Margin="0,10,0,0" />
<StackPanel>
<RadioButton IsChecked="True" Margin="0,10,0,0"/>
<RadioButton Margin="0,10,0,0"/>
<RadioButton IsChecked="True" Margin="0,10,0,0" />
<RadioButton Margin="0,10,0,0" />
</StackPanel>
<Button Content="{ex:Lang Key={x:Static langs:LangKeys.Button}}" Margin="0,10,0,0"/>
<Button Content="{ex:Lang Key={x:Static langs:LangKeys.Button}}" Margin="0,10,0,0" Style="{StaticResource ButtonPrimary}"/>
<Button Content="{ex:Lang Key={x:Static langs:LangKeys.Button}}" Margin="0,10,0,0" />
<Button Content="{ex:Lang Key={x:Static langs:LangKeys.Button}}" Margin="0,10,0,0" Style="{StaticResource ButtonPrimary}" />
</ToolBar>
</ToolBarTray>
</StackPanel>