Silverlight(6) - 2.0控件之ScrollViewer, Slider, StackPanel, TabControl, TextBlock, TextBox, ToggleButton
2008-11-14 11:50:44 来源:WEB开发网4、TabControl.xaml
<UserControl x:Class="Silverlight20.Control.TabControl"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:basics="clr-namespace:System.Windows.Controls;assembly=System.Windows.Controls">
<StackPanel HorizontalAlignment="Left">
<!--
SelectedIndex - 被选中的 TabItem 索引
SelectedItem - 被选中的 TabItem 对象
-->
<basics:TabControl Width="400" Height="400" SelectedIndex="1">
<basics:TabItem Header="Tab1">
<TextBlock Text="Tab1 Content" />
</basics:TabItem>
<!--
TabItem.Header - TabItem 的标题
TabItem.Content - TabItem 的内容
-->
<basics:TabItem>
<basics:TabItem.Header>
<TextBlock Text="Tab2"/>
</basics:TabItem.Header>
<basics:TabItem.Content>
<TextBlock Text="Tab2 Content" />
</basics:TabItem.Content>
</basics:TabItem>
<basics:TabItem>
<basics:TabItem.Header>
<Image Source="/Silverlight20;component/Images/Logo.jpg" Height="20" />
</basics:TabItem.Header>
<TextBlock Text="Tab3 Content"></TextBlock>
</basics:TabItem>
<basics:TabItem>
<basics:TabItem.Header>
<Grid Width="100">
<Image Source="/Silverlight20;component/Images/Logo.jpg" Height="20" HorizontalAlignment="Center" />
<TextBlock Text="Tab4" HorizontalAlignment="Center" />
</Grid>
</basics:TabItem.Header>
<TextBlock Text="Tab4 Content"></TextBlock>
</basics:TabItem>
</basics:TabControl>
</StackPanel>
</UserControl>
Tags:Silverlight 控件 ScrollViewer
编辑录入:爽爽 [复制链接] [打 印]- ››silverlight全屏显示图片
- ››控件一:Gallery 之无限循环的问题
- ››控件一:Gallery 之基础用法
- ››Silverlight MVVM 模式(一) 切近实战
- ››Silverlight for Windows Phone 7开发系列(1):...
- ››Silverlight for Windows Phone 7开发系列(2):...
- ››Silverlight for Windows Phone 7开发系列(3):...
- ››Silverlight for Windows Phone 7开发系列(4):...
- ››Silverlight for Symbian
- ››Silverlight3系列(四)数据绑定 Data Binding 1
- ››silverlight2 游戏 1 你能坚持多少秒
- ››Silverlight开发实践--PicZoomShow
- 中查找“Silverlight(6) - 2.0控件之ScrollViewer, Slider, StackPanel, TabControl, TextBlock, TextBox, ToggleButton”更多相关内容
- 中查找“Silverlight(6) - 2.0控件之ScrollViewer, Slider, StackPanel, TabControl, TextBlock, TextBox, ToggleButton”更多相关内容
- 上一篇:Silverlight(7) - 2.0图形之Ellipse, Line, Path, Polygon, Polyline, Rectangle
- 下一篇:Silverlight(5) - 2.0控件之ListBox, MediaElement, MultiScaleImage, PasswordBox, ProgressBar, RadioButton
更多精彩
赞助商链接