Reputation: 69
I want to disable the option of reordering tabs using the dragablz tabs. How can I do it?
As you can see in the attached code, I have removed the TabablzControl.InterTabController, and it helped me with the problem of dragging tabs out of a window into a new one. But I also need to prevent changing their order, and I have no clue how to do that.
<Grid Margin="0,0,2,0">
<dragablz:TabablzControl Margin="8" TabStripPlacement="Left" AllowDrop="False" >
<!--if you want to allow dragging tabs out of the window into a new window (loke googke Chrome) then uncomment next lines.-->
<!--<dragablz:TabablzControl.InterTabController>
<dragablz:InterTabController/>
</dragablz:TabablzControl.InterTabController>-->
<TabItem Header="Tab No. 1" IsSelected="True">
<TextBlock>Hello World</TextBlock>
</TabItem>
<TabItem Header="Tab No. 2">
<TextBlock>We Have Tearable Tabs!</TextBlock>
</TabItem>
</dragablz:TabablzControl>
</Grid>
Upvotes: 1
Views: 867
Reputation: 69
Ok, I have figured it out. In the second line add an attribute FixedHeaderCount. This attribute gets as value the number of tabs that you want to be fixed. So If you have 3 tabs, and you want them all to be fixed the second line should look like that:
<dragablz:TabablzControl Margin="8" TabStripPlacement="Left" AllowDrop="False" FixedHeaderCount="3">
Upvotes: 1