Merge pull request #41 from ghost1372/LabelDemo

add Label Demo
This commit is contained in:
NaBian authored and GitHub committed 2019-02-14 11:15:15 +08:00
commit 52656563b7
10 files changed
+60 -1

No files matched your search

+2
View File
@@ -134,6 +134,8 @@
public static readonly string ToolBarDemoCtl = nameof(ToolBarDemoCtl);
public static readonly string LabelDemoCtl = nameof(LabelDemoCtl);
public static readonly string CommonWindow = nameof(CommonWindow);
public static readonly string CustomNonClientAreaWindow = nameof(CustomNonClientAreaWindow);
+2 -1
View File
@@ -72,7 +72,8 @@ var styleList = new List<string>
"GroupBoxDemoCtl",
"ListViewDemoCtl",
"RichTextBoxDemoCtl",
"ToolBarDemoCtl"
"ToolBarDemoCtl",
"LabelDemoCtl"
};
var windowList = new List<string>
{
+8
View File
@@ -262,6 +262,9 @@
<Compile Include="UserControl\Styles\GroupBoxDemoCtl.xaml.cs">
<DependentUpon>GroupBoxDemoCtl.xaml</DependentUpon>
</Compile>
<Compile Include="UserControl\Styles\LabelDemoCtl.xaml.cs">
<DependentUpon>LabelDemoCtl.xaml</DependentUpon>
</Compile>
<Compile Include="UserControl\Styles\ListViewDemoCtl.xaml.cs">
<DependentUpon>ListViewDemoCtl.xaml</DependentUpon>
</Compile>
@@ -601,6 +604,10 @@
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="UserControl\Styles\LabelDemoCtl.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="UserControl\Styles\ListViewDemoCtl.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
@@ -739,6 +746,7 @@
<Generator>TextTemplatingFileGenerator</Generator>
<LastGenOutput>MessageToken.cs</LastGenOutput>
</Content>
<Resource Include="Resources\Img\LeftMainContent\Label_16x.png" />
<Resource Include="Resources\Img\Chat\chat_back1.jpg" />
<Resource Include="Resources\Img\Chat\chat_back2.jpg" />
<Resource Include="Resources\Img\LeftMainContent\Bubble_16xLG.png" />
+9
View File
@@ -564,6 +564,15 @@ namespace HandyControlDemo.Properties.Langs {
}
}
/// <summary>
/// 查找类似 标签 的本地化字符串。
/// </summary>
public static string Label {
get {
return ResourceManager.GetString("Label", resourceCulture);
}
}
/// <summary>
/// 查找类似 列表框 的本地化字符串。
/// </summary>
@@ -495,4 +495,7 @@
<data name="Second" xml:space="preserve">
<value>Sec</value>
</data>
<data name="Label" xml:space="preserve">
<value>Label</value>
</data>
</root>
@@ -495,4 +495,7 @@
<data name="Second" xml:space="preserve">
<value>秒</value>
</data>
<data name="Label" xml:space="preserve">
<value>标签</value>
</data>
</root>
Binary file not shown.

After

Width:  |  Height:  |  Size: 247 B

@@ -159,6 +159,12 @@
<Image Source="../../Resources/Img/LeftMainContent/BorderElement_16x.png"/>
</controls:EdgeElement.LeftContent>
</ListBoxItem>
<ListBoxItem Tag="{x:Static data:MessageToken.LabelDemoCtl}" Content="{x:Static langs:Lang.Label}">
<controls:EdgeElement.LeftContent>
<Image Source="../../Resources/Img/LeftMainContent/Label_16x.png"/>
</controls:EdgeElement.LeftContent>
</ListBoxItem>
</ListBox>
</Grid>
</TabItem>
@@ -0,0 +1,17 @@
<UserControl x:Class="HandyControlDemo.UserControl.LabelDemoCtl"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:controls="clr-namespace:HandyControl.Controls;assembly=HandyControl"
xmlns:langs="clr-namespace:HandyControlDemo.Properties.Langs"
Background="{DynamicResource RegionBrush}">
<controls:TransitioningContentControl>
<StackPanel Margin="32">
<Label HorizontalAlignment="Left" Margin="5" Content="{Binding Source={x:Static langs:Lang.Title},Converter={StaticResource StringRepeatConverter},ConverterParameter=10}"/>
<Label HorizontalAlignment="Left" Margin="5" Content="{Binding Source={x:Static langs:Lang.Title},Converter={StaticResource StringRepeatConverter},ConverterParameter=10}" Style="{StaticResource LabelDanger}"/>
<Label HorizontalAlignment="Left" Margin="5" Content="{Binding Source={x:Static langs:Lang.Title},Converter={StaticResource StringRepeatConverter},ConverterParameter=10}" Style="{StaticResource LabelInfo}"/>
<Label HorizontalAlignment="Left" Margin="5" Content="{Binding Source={x:Static langs:Lang.Title},Converter={StaticResource StringRepeatConverter},ConverterParameter=10}" Style="{StaticResource LabelPrimary}"/>
<Label HorizontalAlignment="Left" Margin="5" Content="{Binding Source={x:Static langs:Lang.Title},Converter={StaticResource StringRepeatConverter},ConverterParameter=10}" Style="{StaticResource LabelSuccess}"/>
<Label HorizontalAlignment="Left" Margin="5" Content="{Binding Source={x:Static langs:Lang.Title},Converter={StaticResource StringRepeatConverter},ConverterParameter=10}" Style="{StaticResource LabelWarning}"/>
</StackPanel>
</controls:TransitioningContentControl>
</UserControl>
@@ -0,0 +1,10 @@
namespace HandyControlDemo.UserControl
{
public partial class LabelDemoCtl
{
public LabelDemoCtl()
{
InitializeComponent();
}
}
}