Hi,
We are using Infragistics DockManager v10.1. Inside the dockMgr we have a DocumentContentHost, inside which we have a SplitPane, then a TabGroupPane, and then several ContentPanes. We are setting the AllowClose property of the ContentPane as true and the CloseButtonVisibility property as Hidden. We want to be able to close the contentpane using the close menu item in the contentpane's header's right click context menu and hence we have set the AllowClose to true, and this works fine. However, we don't want the 'X' close button on the top right corner of the contenpane and that is why we have set the CloseButtonVisibility to Hidden. But inspite of this, the 'X' close button still shows up. Any advise is greatly appreciated.
Thanks,
Abhinav.
Hi Abhinav,
The CloseButtonVisibility property controls the behavior in the Content pane's header presenter which is not the same as the Close button in the DocumentContentHost. In order to hide the documents' close button you could use a style like the following:
<Style x:Key="{x:Static igDock:TabGroupPane.DocumentCloseButtonStyleKey}" TargetType="{x:Type Button}"> <Setter Property="Visibility" Value="Collapsed" /></Style>
This way the "X" button will not be visible but you'll still have the "Close" menu option.
Hope this helps.
We use XamDockManager to create a DocumentContentHost to host SplitPanes and TabGroupPane. is there a way to show the close button (x) only on individual tabs and not on the far right corner of the DocumentContentHost?
Regards,
Harman
The approach that Galina mentions in this thread can be used to hide the close button within the TabGroupPane in the DocumentContentHost. If you want to show a close button within a tab then you can follow the approach I described in this other thread.