Files
cefsharp/CefSharp.Wpf.Example/StandardTabControlWindow.xaml
T

30 lines
1.3 KiB
XML

<Window
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
x:Class="CefSharp.Wpf.Example.StandardTabControlWindow"
xmlns:cefSharp="clr-namespace:CefSharp.Wpf;assembly=CefSharp.Wpf"
Title="TabControl Test Window" Height="594" Width="651">
<Grid>
<TabControl ItemsSource="{Binding Tabs}">
<TabControl.Resources>
<Style TargetType="{x:Type TabItem}">
<Setter Property="HeaderTemplate">
<Setter.Value>
<DataTemplate DataType="{x:Type cefSharp:ChromiumWebBrowser}">
<TextBlock Text="Browser" />
</DataTemplate>
</Setter.Value>
</Setter>
<Setter Property="ContentTemplate">
<Setter.Value>
<DataTemplate DataType="cefSharp:ChromiumWebBrowser">
<ContentPresenter Content="{Binding}" />
</DataTemplate>
</Setter.Value>
</Setter>
</Style>
</TabControl.Resources>
</TabControl>
</Grid>
</Window>