Silverlight4入门之样式与模板(十)

Silverlight4入门之样式与模板(十),第1张

概述  <UserControl x:Class="SbSCh3_4.MainPage" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:d="http://schem  
<UserControl x:Class="SbSCh3_4.MainPage"    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"    xmlns:d="http://schemas.microsoft.com/Expression/blend/2008"    xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"    mc:Ignorable="d"    d:DesignHeight="338" d:DesignWIDth="400">    <UserControl.Resources>        <Style x:Key="Picturebutton" targettype="button">            <Setter Property="Template">                <Setter.Value>                    <ControlTemplate targettype="button">                        <button Height="150" WIDth="257">                            <button.Content>                                <StackPanel Height="141" HorizontalAlignment="left" name="stackPanel1" VerticalAlignment="top" WIDth="204">                                    <Image Height="103" name="image1" Stretch="Fill" WIDth="200" Source="/SbSCh3_4;component/quan_zhi_xian.jpg" />                                    <TextBlock Height="23" name="textBlock1" Text="Fancy Books" TextAlignment="Center" FontFamily="Georgia" FontSize="12" />                                </StackPanel>                            </button.Content>                        </button>                    </ControlTemplate>                </Setter.Value>            </Setter>        </Style>    </UserControl.Resources>    <GrID x:name="LayoutRoot" Background="White" Height="341">        <button Style="{StaticResource Picturebutton}" margin="-10,-91,10,91" />        <button Style="{StaticResource Picturebutton}" margin="-13,70,13,-70" />    </GrID></UserControl>
总结

以上是内存溢出为你收集整理的Silverlight4入门样式模板(十)全部内容,希望文章能够帮你解决Silverlight4入门之样式与模板(十)所遇到的程序开发问题。

如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。

欢迎分享,转载请注明来源:内存溢出

原文地址: http://outofmemory.cn/web/1072795.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2022-05-26
下一篇 2022-05-26

发表评论

登录后才能评论

评论列表(0条)

保存