文章详情

  • 游戏榜单
  • 软件榜单
关闭导航
热搜榜
热门下载
热门标签
php爱好者> php文档>使用 window theme

使用 window theme

时间:2011-05-18  来源:zip's

.Net 提供了几种现成的 theme 可供使用

Classic

<Window.Resources>
<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="/PresentationFramework.Classic;component/themes/Classic.xaml"/>
</ResourceDictionary.MergedDictionaries>
</ResourceDictionary>
</Window.Resources>

<StackPanel>
<StackPanel.Resources>
<Style TargetType="{x:Type Button}" BasedOn="{StaticResource {x:Type Button}}">
<Setter Property="Width" Value="76"/>
<Setter Property="Height" Value="Auto"/>
</Style>
<Style TargetType="{x:Type RepeatButton}" BasedOn="{StaticResource {x:Type RepeatButton}}">
<Setter Property="Width" Value="12"/>
<Setter Property="Margin" Value="1,0,0,0"/>
</Style>
</StackPanel.Resources>
<StackPanel Orientation="Horizontal">
<RepeatButton Content="&lt;"/>
<RepeatButton Content=">"/>
</StackPanel>
<Button Content="Click Me"/>
<RadioButton Content="Check Me"/>
<ComboBox>
<ComboBoxItem Content="ABC"/>
<ComboBoxItem Content="123"/>
<ComboBoxItem Content="*%#"/>
</ComboBox>
</StackPanel>

Aero

<Window.Resources>
<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="/PresentationFramework.Aero;component/themes/Aero.NormalColor.xaml"/>
</ResourceDictionary.MergedDictionaries>
</ResourceDictionary>
</Window.Resources>

Luna

<Window.Resources>
<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
<!--<ResourceDictionary Source="/PresentationFramework.Luna;component/themes/Luna.NormalColor.xaml"/>-->
<!--<ResourceDictionary Source="/PresentationFramework.Luna;component/themes/Luna.Metallic.xaml"/>-->
<ResourceDictionary Source="/PresentationFramework.Luna;component/themes/Luna.HomeStead.xaml"/>
</ResourceDictionary.MergedDictionaries>
</ResourceDictionary>
</Window.Resources>

Royale

<Window.Resources>
<ResourceDictionary>
<ResourceDictionary.MergedDictionaries>
<ResourceDictionary Source="/PresentationFramework.Royale;component/themes/Royale.NormalColor.xaml"/>
</ResourceDictionary.MergedDictionaries>
</ResourceDictionary>
</Window.Resources>

Reference Reading: MSDN, .NET3.5

to be continued ...

相关阅读 更多 +
排行榜 更多 +
翌日波奇狗的历险记手机版下载

翌日波奇狗的历险记手机版下载

休闲益智 下载
怪兽远征安卓版下载

怪兽远征安卓版下载

角色扮演 下载
谷歌卫星地图免费版下载

谷歌卫星地图免费版下载

生活实用 下载