How to set the Autodesk Inventor TabItem style?

Viewed 23

I would like to apply a simple style to my tabItems , this style is similar to Autodesk Inventor Style for the tabItems .

For that reason , I'm searching for a method to create this style, how can I achieve this? ( Ignoring the color of File tabItem because it's not needed for now)

enter image description here

Below what I've tried:

<Style TargetType="{x:Type TabItemStyle}" x:Key="TabControlStyle1">
    <Setter Property="Template">
        <Setter.Value>
            <ControlTemplate TargetType="{x:Type TabItem}">
                <Grid>
                    <Border Name="Border" Background="Transparent" BorderBrush="Transparent"  BorderThickness="0" CornerRadius="0" >

                        <ContentPresenter x:Name="ContentSite" VerticalAlignment="Top"  HorizontalAlignment="Center" ContentSource="Header" Margin="5"/>

                    </Border>
                </Grid>

                <ControlTemplate.Triggers>
                    <Trigger Property="IsSelected" Value="True">
                        <Setter Property="Foreground" Value="Black"/>
                        <!--<Setter TargetName="Border" Property="Background">
                            <Setter.Value>
                                <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                                    <GradientStop Color="#FFF9F7FD" Offset="0.432" />
                                    <GradientStop Color="#FFECF7FD" Offset="0.433" />
                                </LinearGradientBrush>
                            </Setter.Value>
                        </Setter>-->
                        <!--<Setter TargetName="ContentSite" Property="Margin" Value="9,12,9,9" />-->
                    </Trigger>

                    <Trigger Property="IsSelected" Value="True">
                        <Setter TargetName="Border" Property="Background" Value="Transparent" />
                    </Trigger>
                    <Trigger Property="IsSelected" Value="False">
                        <Setter TargetName="Border" Property="Background" Value="LightGray"  />
                    </Trigger>
                </ControlTemplate.Triggers>
            </ControlTemplate>
        </Setter.Value>
    </Setter>
</Style>

Tab Item :

    <TabControl x:Name="TabsUserControl" >
        <TabItem x:Name="AboutMe" Style="{StaticResource TabItemStyle}" >
            <TabItem.Header>
                <TextBlock Text="About"/>
            </TabItem.Header>
            <TabItem.ToolTip>
                <StackPanel>
                    <Image x:Name="AboutMeImage">
                    </Image>
                </StackPanel>
            </TabItem.ToolTip>
            <TabItem.Content>
                <Grid>
                </Grid>
            </TabItem.Content>
        </TabItem>

enter image description here

Update :

What is cleared for me now , it's another control called Ribbon Tab , I would like to know how can I apply this style to TabItem

     <ribbon:DockPanel>
        <ribbon:Ribbon DockPanel.Dock="Top" SelectedIndex="0" >
            <ribbon:Ribbon.ApplicationMenu>
                <RibbonApplicationMenu Visibility="Collapsed">
                    <RibbonApplicationMenu.AuxiliaryPaneContent>
                        <RibbonGallery>
                            
                        </RibbonGallery>
                    </RibbonApplicationMenu.AuxiliaryPaneContent>
                </RibbonApplicationMenu>
            </ribbon:Ribbon.ApplicationMenu>
            <ribbon:RibbonTab Header="Tab 1" >
            </ribbon:RibbonTab>
            <ribbon:RibbonTab Header="Tab 2">
            </ribbon:RibbonTab>
        </ribbon:Ribbon>
        
    </ribbon:DockPanel>

enter image description here

0 Answers
Related