How to build vertical tab sets in WPF?

Gulshan picture Gulshan · Oct 17, 2010 · Viewed 35.9k times · Source

How to build vertical tab sets in WPF? The tabs will stack up in top-to-bottom just like the "Properties" of a project shown in visual studio.

Answer

ChrisF picture ChrisF · Oct 17, 2010

Have you tried the TabControl.TabStripPlacement Property?

The following example creates a tab control that positions the tabs on the left side.

<TabControl TabStripPlacement="Left" Margin="0, 0, 0, 10">
  <TabItem Name="fontweight" Header="FontWeight">
    <TabItem.Content>
      <TextBlock TextWrapping="WrapWithOverflow">
        FontWeight property information goes here.
      </TextBlock>
    </TabItem.Content>
  </TabItem>

  <TabItem Name="fontsize" Header="FontSize">
    <TabItem.Content>
      <TextBlock TextWrapping="WrapWithOverflow">
        FontSize property information goes here.
      </TextBlock>
    </TabItem.Content>
  </TabItem>
</TabControl>