SilverLight:布局(3)StackPanel 对象
ylbtech-SilverLight-Layout: 布局(3)StackPanel 对象 |
- A, Nesting Layout Containers(内嵌布局容器)
- B, StackPanel(队列面板)对象
- C, StackPanel(队列面板)对象 Orientation="Horizontal"
- D, StackPanel(队列面板)对象之 Alignment
- E, StackPanel(队列面板)对象之 Margins
1.A, Nesting Layout Containers(内嵌布局容器)返回顶部 |

<Grid ShowGridLines="True" Background="SteelBlue" HorizontalAlignment="Center" VerticalAlignment="Center">
<Grid.RowDefinitions>
<RowDefinition Height="*"></RowDefinition>
<RowDefinition Height="Auto"></RowDefinition>
</Grid.RowDefinitions>
<TextBlock Margin="10" Grid.Row="0" Foreground="White"
Text="This a simply test of the nested containers."></TextBlock>
<StackPanel Grid.Row="1" HorizontalAlignment="Right" Orientation="Horizontal">
<Button Margin="10,10,2,10" Padding="3" Content="Ok"></Button>
<Button Margin="2,10,10,10" Padding="3" Content="Cancel"></Button>
</StackPanel>
</Grid>
3, ShowGridLines, Background, HorizontalAlignment, VerticalAlignment
,Grid.RowDefinitions, RowDefinition
,Grid.Row
,Orientation
,<StackPanel/>[队列面板 对象]
1.B, StackPanel(队列面板)对象返回顶部 |

<Grid x:Name="LayoutRoot" Background="White">
<StackPanel Background="White">
<TextBox Text="A Button Stack"/>
<Button Content="Button A"/>
<Button Content="Button B"/>
<Button Content="Button C"/>
<Button Content="Button D"/>
</StackPanel>
</Grid>
3,<StackPanel/>
1.C, StackPanel(队列面板)对象 Orientation="Horizontal"返回顶部 |

<Grid x:Name="LayoutRoot" Background="White">
<StackPanel Orientation="Horizontal" Background="White">
<TextBox Text="A Button Stack"/>
<Button Content="Button A"/>
<Button Content="Button B"/>
<Button Content="Button C"/>
<Button Content="Button D"/>
</StackPanel>
</Grid>
3, Orientation
1.D, StackPanel(队列面板)对象之 Alignment返回顶部 |

<Grid x:Name="LayoutRoot" Background="White">
<StackPanel Background="White">
<TextBox Text="A Button Stack"/>
<Button HorizontalAlignment="Left" Content="Button A"/>
<Button HorizontalAlignment="Right" Content="Button B"/>
<Button Content="Button C"/>
<Button Content="Button D"/>
</StackPanel>
</Grid>
3, HorizontalAlignment[水平对齐方式]
1.E, StackPanel(队列面板)对象之 Margins返回顶部 |

<Grid x:Name="LayoutRoot" Background="White">
<StackPanel Background="White">
<TextBox Text="A Button Stack" HorizontalAlignment="Center"/>
<Button HorizontalAlignment="Left" Content="Button A" Margin="5"/>
<Button HorizontalAlignment="Right" Content="Button B" Margin="0,0,0,10"/>
<Button Content="Button C"/>
<Button Content="Button D"/>
</StackPanel>
</Grid>
3, Margin[外间距]
1.F,返回顶部 |
![]() |
作者:ylbtech 出处:http://ylbtech.cnblogs.com/ 本文版权归作者和博客园共有,欢迎转载,但未经作者同意必须保留此段声明,且在文章页面明显位置给出原文连接,否则保留追究法律责任的权利。 |
SilverLight:布局(3)StackPanel 对象的更多相关文章
- silverlight Canvas、StackPanel、Grid三者之间的关系
学习 silverlight 首先Canvas.StackPanel.Grid 博客园里看到jailu的这篇文章整理得很好 贴下来: Silverlight提供了非常灵活的布局管理系统,让程序员和 ...
- WPF之旅(三)- 布局之StackPanel
说到WPF的界面布局,相信很多朋友都写过Html代码.在WPF中,大多数程序都使用类似Web的(flow)流布局.在使用流布局模型时,各种控件可以按特定的要求来排列,在窗口内容发生变化时,比如窗口大小 ...
- WPF 界面布局DockPanel stackPanel WrapPanel 元素内容以及位置控制
1 DockPanel 1) 默认充满整个窗口. 2) 最后一个出现的部分,默认充满剩余空间. 3) 非最后一个出现的部分,根据其中内容,进行分配空间s 2 StackPanel 实现居左,居右,居中 ...
- WPF教程二:布局之StackPanel面板
应用程序界面设计中,合理的元素布局至关重要,它可以方便用户使用,并将信息清晰合理地展现给用户.WPF提供了一套功能强大的工具-面板(Panel),来控制用户界面的布局.你可以使用这些面板控件来排布元素 ...
- c# 布局(stackpanel)
<Grid> <StackPanel> <Button Content="asas"> </Button> <Button C ...
- 12.Quick QML-QML 布局(Row、Column、Grid、Flow和嵌套布局) 、Repeater对象
1.Row布局 Row中的item可以不需要使用anchors布局,就能通过行的形式进行布局. 并且item可以使用Positioner附加属性来访问有关其在Row中的位置及其他信息. 示例如下所示, ...
- [Swift通天遁地]六、智能布局-(2)视图对象的尺寸和位置相对约束
★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★★➤微信公众号:山青咏芝(shanqingyongzhi)➤博客园地址:山青咏芝(https://www.cnblogs. ...
- silverlight中鼠标放在对象的提示事件
1.xaml 中实现 <Rectangle x:Name="toolTip" Grid.Column="0" Grid.Row="1" ...
- Silverlight项目笔记1:UI控件与布局、MVVM、数据绑定、await/async、Linq查询、WCF RIA Services、序列化、委托与事件
最近从技术支持转到开发岗,做Silverlight部分的开发,用的Prism+MVVM,框架由同事搭好,目前做的主要是功能实现,用到了一些东西,侧重于如何使用,总结如下 1.UI控件与布局 常用的主要 ...
随机推荐
- LA 7056 Colorful Toy Polya定理
题意: 平面上给出一个\(N\)个点\(M\)条边的无向图,要用\(C\)种颜色去给每个顶点染色. 如果一种染色方案可以旋转得到另一种染色方案,那么说明这两种染色方案是等价的. 求所有染色方案数 \( ...
- MyCAT+MySQL 搭建高可用企业级数据库集群——第3章 MyCat核心配置讲解
3-1 章节综述 3-2 常用配置文件间的关系 3-3 server.xml配置详解 3-4 log4j2.xml配置文件 3-5 rule.xml 3-6 常用分片算法(上) 3-7 常用分片算法( ...
- codeM预赛
[编程|1000分] 音乐研究 时间限制:1秒空间限制:32768K 题目描述 美团外卖的品牌代言人袋鼠先生最近正在进行音乐研究.他有两段音频,每段音频是一个表示音高的序列.现在袋鼠先生想要在第二段音 ...
- TOJ1196: RSA Signing
题不在多,大概是多了也可能就是菜逼 1196: RSA Signing Time Limit(Common/Java):3000MS/30000MS Memory Limit:65536KBy ...
- 2018 ACM 国际大学生程序设计竞赛上海大都会赛重现赛 F Color it
链接:https://www.nowcoder.com/acm/contest/163/F 来源:牛客网 2018 ACM 国际大学生程序设计竞赛上海大都会赛重现赛 F Color it 时间限制:C ...
- hibernate缓存详解
hibernate中提供了两级缓存,一级缓存是Session级别的缓存,它属于事务范围的缓存,该级缓存由hibernate管理,应用程序无需干预:二级缓存是SessionFactory级别的缓存,该级 ...
- 【Luogu】P3358最长k可重区间集问题(费用流)
题目链接 这题费用瘤,数据貌似还是错的. 把线段抽象抽象拆成两个点,入点表示左端,出点表示右端,连上容量为1费用-长度的边. 不相交线段随便连下,源点向拆出的原点S'连费用为0容量k,然后跑费用流. ...
- docker (centOS 7) 使用笔记1
1. docker配置 初次在安装完docker后,初始化配置 copy默认的docker.service后,重启服务,会在/etc/systemd/system/multi-user.target. ...
- setsockopt等高级使用
参考: setsockopt函数使用http://hi.baidu.com/yelangdefendou/item/74161d0f384abd3c4ac4a316http://blog.csdn.n ...
- bzoj3997[TJOI2015]组合数学(求最长反链的dp)
组合数学 给出一个网格图,其中某些格子有财宝,每次从左上角出发,只能向下或右走.问至少走多少次才能将财宝捡完.此对此问题变形,假设每个格子中有好多财宝,而每一次经过一个格子至多只能捡走一块财宝,至少走 ...