|
16 | 16 | mc:Ignorable="d"> |
17 | 17 | <UserControl.Resources> |
18 | 18 | <Style x:Key="ExplorerTabItem" TargetType="{x:Type TabItem}"> |
| 19 | + <Setter Property="MinWidth" Value="120" /> |
19 | 20 | <Setter Property="Template"> |
20 | 21 | <Setter.Value> |
21 | 22 | <ControlTemplate TargetType="{x:Type TabItem}"> |
22 | | - |
23 | 23 | <Border |
24 | 24 | x:Name="LayoutRoot" |
25 | | - Margin="0 0 0 0" |
| 25 | + Margin="0" |
26 | 26 | Padding="{TemplateBinding Padding}" |
27 | 27 | SnapsToDevicePixels="True"> |
28 | 28 | <Grid> |
| 29 | + <Grid.ColumnDefinitions> |
| 30 | + <ColumnDefinition Width="Auto" /> |
| 31 | + <ColumnDefinition Width="*" /> |
| 32 | + </Grid.ColumnDefinitions> |
| 33 | + |
29 | 34 | <Border |
30 | 35 | x:Name="TabSeparator" |
31 | 36 | Width="0" |
32 | | - Margin="{DynamicResource TabViewItemSeparatorMargin}" |
| 37 | + Margin="0" |
33 | 38 | HorizontalAlignment="Right" |
34 | 39 | BorderBrush="{DynamicResource TabViewItemSeparator}" |
35 | 40 | BorderThickness="1" /> |
| 41 | + |
36 | 42 | <Border |
37 | 43 | x:Name="TabContainer" |
38 | 44 | Grid.Column="1" |
39 | | - Padding="{DynamicResource TabViewItemHeaderPadding}" |
40 | | - Background="{DynamicResource TabViewItemHeaderBackground}" |
| 45 | + Padding="10,5" |
| 46 | + Background="{DynamicResource Color06B}" |
41 | 47 | BorderBrush="{TemplateBinding BorderBrush}" |
42 | 48 | BorderThickness="{TemplateBinding BorderThickness}"> |
43 | | - <Grid> |
44 | | - <Grid.ColumnDefinitions> |
45 | | - <ColumnDefinition Width="Auto" /> |
46 | | - <ColumnDefinition Width="*" /> |
47 | | - <ColumnDefinition Width="Auto" /> |
48 | | - </Grid.ColumnDefinitions> |
49 | | - <ContentPresenter |
50 | | - x:Name="ContentPresenter" |
51 | | - Grid.Column="1" |
52 | | - HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" |
53 | | - VerticalAlignment="{TemplateBinding VerticalContentAlignment}" |
54 | | - ContentSource="Header" |
55 | | - Focusable="False" |
56 | | - RecognizesAccessKey="True" |
57 | | - SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" |
58 | | - TextElement.FontSize="{DynamicResource TabViewItemHeaderFontSize}" |
59 | | - TextElement.FontWeight="{TemplateBinding FontWeight}" |
60 | | - TextElement.Foreground="{DynamicResource Color05B}" /> |
61 | | - </Grid> |
| 49 | + <ContentPresenter |
| 50 | + x:Name="ContentPresenter" |
| 51 | + HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}" |
| 52 | + VerticalAlignment="{TemplateBinding VerticalContentAlignment}" |
| 53 | + ContentSource="Header" |
| 54 | + Focusable="False" |
| 55 | + RecognizesAccessKey="True" |
| 56 | + SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}" |
| 57 | + TextElement.FontSize="{TemplateBinding FontSize}" |
| 58 | + TextElement.FontWeight="{TemplateBinding FontWeight}" |
| 59 | + TextElement.Foreground="{DynamicResource Color08B}" /> |
62 | 60 | </Border> |
63 | 61 | </Grid> |
64 | 62 | </Border> |
65 | 63 |
|
66 | 64 | <ControlTemplate.Triggers> |
67 | | - <!-- PointerOver --> |
| 65 | + <!-- Default --> |
68 | 66 | <Trigger Property="IsMouseOver" Value="False"> |
69 | 67 | <Setter TargetName="TabContainer" Property="Background" Value="{DynamicResource Color06B}" /> |
70 | 68 | <Setter TargetName="ContentPresenter" Property="TextElement.Foreground" Value="{DynamicResource Color08B}" /> |
|
73 | 71 | <Trigger Property="IsMouseOver" Value="True"> |
74 | 72 | <Setter TargetName="TabContainer" Property="Background" Value="{DynamicResource Color06B}" /> |
75 | 73 | <Setter TargetName="ContentPresenter" Property="TextElement.Foreground" Value="{DynamicResource TabViewItemHeaderForegroundPointerOver}" /> |
76 | | - |
77 | 74 | </Trigger> |
78 | 75 | <!-- Selected --> |
79 | 76 | <Trigger Property="IsSelected" Value="True"> |
80 | 77 | <Setter TargetName="TabContainer" Property="Background" Value="{DynamicResource Color00B}" /> |
81 | 78 | <Setter TargetName="ContentPresenter" Property="TextElement.Foreground" Value="{DynamicResource Color05B}" /> |
82 | | - |
83 | 79 | <Setter Property="Panel.ZIndex" Value="1" /> |
84 | 80 | <Setter TargetName="ContentPresenter" Property="TextElement.FontWeight" Value="SemiBold" /> |
85 | 81 | </Trigger> |
|
91 | 87 | </MultiTrigger.Conditions> |
92 | 88 | <Setter TargetName="TabContainer" Property="Background" Value="{DynamicResource Color00B}" /> |
93 | 89 | <Setter TargetName="ContentPresenter" Property="TextElement.Foreground" Value="{DynamicResource Color05B}" /> |
94 | | - |
95 | 90 | <Setter Property="Panel.ZIndex" Value="1" /> |
96 | 91 | <Setter TargetName="ContentPresenter" Property="TextElement.FontWeight" Value="SemiBold" /> |
97 | 92 | </MultiTrigger> |
|
175 | 170 | BorderThickness="0" |
176 | 171 | SelectedIndex="0" |
177 | 172 | TabStripPlacement="Top"> |
| 173 | + <TabControl.ItemsPanel> |
| 174 | + <ItemsPanelTemplate> |
| 175 | + <WrapPanel IsItemsHost="True" Orientation="Horizontal"/> |
| 176 | + </ItemsPanelTemplate> |
| 177 | + </TabControl.ItemsPanel> |
178 | 178 | <TabItem |
179 | 179 | Width="Auto" |
180 | 180 | Header="{DynamicResource plugin_explorer_generalsetting_header}" |
|
0 commit comments