Tab Control - 단일 항목과 헤더를 표시하는 컨트롤을 앞에서 살펴본 ContentControl상속 받아서 구현된 단일 항목을 표시하는 컨트롤과 헤더의 조합 컨트롤 의미 - 단일 항목과 헤더를 표시하는 컨트롤은 TabItem 컨트롤이 있으며, TabControl의 자식 Item으로 사용 |
Tab Control.Xaml <UserControl x:Class="TabExample.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" mc:Ignorable="d" d:DesignWidth="640" d:DesignHeight="480"> <Grid Width="200" Height="300" xmlns:controls="clr- <controls:TabControl> <!-- TabItem 추가및 헤더 설정 --> <controls:TabItem Header="텍¨ª스ö¨¬트¡¢ç 탭C" > <!-- TabItem 콘텐츠 설정 --> <controls:TabItem.Content> <ScrollViewer HorizontalScrollBarVisibility="Auto" <TextBlock Width="400" TextWrapping="Wrap" Text="jQuery UI provides abstractions for low-level interaction and animation, advanced effects and high-level, themeable widgets, built on top of the jQuery JavaScript Library, that you can use to build highly interactive web applications." /> </ScrollViewer> </controls:TabItem.Content> </controls:TabItem> <!-- TabItem 추가 --> <controls:TabItem> <!-- TabItem 헤더 설정 --> <controls:TabItem.Header> <StackPanel Orientation="Horizontal"> <Image Source="star.png" Width="20" Height="20"/> <TextBlock Margin="2" Text="이미지 탭" /> </StackPanel> </controls:TabItem.Header> <!-- TabItem 콘텐츠 설정 --> <controls:TabItem.Content> <ScrollViewer HorizontalScrollBarVisibility="Auto" VerticalScrollBarVisibility="Auto"> <Image Source="star.png"/> </ScrollViewer> </controls:TabItem.Content> </controls:TabItem> </controls:TabControl> </Grid> </UserControl> |
'.Net Project > SilverLight 3.0' 카테고리의 다른 글
54장 바인딩 컨트롤(Grid.Resource) (0) | 2009.12.03 |
---|---|
53장 Calendar 컨트롤 (0) | 2009.12.02 |
51장 Slider 컨트롤 (0) | 2009.12.02 |
50장 ProgressBar 컨트롤 (0) | 2009.12.02 |
49장 ListBox 컨트롤 (0) | 2009.12.02 |