Skip to content

Commit ddbdb83

Browse files
Added documentation for DockAreaHideDisabledButtons flag
1 parent 85626c9 commit ddbdb83

File tree

5 files changed

+18
-3
lines changed

5 files changed

+18
-3
lines changed
Loading
Loading

doc/user-guide.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
- [`AlwaysShowTabs`](#alwaysshowtabs)
1919
- [`DockAreaHasUndockButton`](#dockareahasundockbutton)
2020
- [`DockAreaHasTabsMenuButton`](#dockareahastabsmenubutton)
21+
- [`DockAreaHideDisabledButtons`](#dockareahidedisabledbuttons)
2122

2223
## Configuration Flags
2324

@@ -227,3 +228,17 @@ in the dock area title bar. On the left side, the tabs menu button flag
227228
is cleared.
228229

229230
![DockAreaHasTabsMenuButton false true](cfg_flag_DockAreaHasTabsMenuButton_false_true.png)
231+
232+
### `DockAreaHideDisabledButtons`
233+
234+
If certain flags of a dock widget are disabled, like `DockWidgetClosable` or
235+
`DockWidgetFloatable`, then the corresponding dock area buttons like close
236+
button or detach button are disabled (greyed out). This is the default
237+
setting.
238+
239+
![DockAreaHideDisabledButtons false](cfg_flag_DockAreaHideDisabledButtons_false.png)
240+
241+
If the flag is set, disabled dock area buttons will not appear on the toolbar at
242+
all - they are hidden.
243+
244+
![DockAreaHideDisabledButtons true](cfg_flag_DockAreaHideDisabledButtons_true.png)

src/DockManager.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -155,7 +155,7 @@ class ADS_EXPORT CDockManager : public CDockContainerWidget
155155
AlwaysShowTabs = 0x2000,///< If this option is enabled, the tab of a dock widget is always displayed - even if it is the only visible dock widget in a floating widget.
156156
DockAreaHasUndockButton = 0x4000, //!< If the flag is set each dock area has an undock button
157157
DockAreaHasTabsMenuButton = 0x8000, //!< If the flag is set each dock area has a tabs menu button
158-
DockAreaHideDisabledButtons = 0x10000, //!< If the flag is set disabled dock area buttons will not appear on the tollbar at all (enabling them will bring them back)
158+
DockAreaHideDisabledButtons = 0x10000, //!< If the flag is set disabled dock area buttons will not appear on the toolbar at all (enabling them will bring them back)
159159
DockAreaDynamicTabsMenuButtonVisibility = 0x20000, //!< If the flag is set dock area will disable a tabs menu button when there is only one tab in the area
160160
FloatingContainerHasWidgetTitle = 0x40000, //!< If set, the Floating Widget window title reflects the title of the current dock widget otherwise it displays application name as window title
161161
FloatingContainerHasWidgetIcon = 0x80000, //!< If set, the Floating Widget icon reflects the icon of the current dock widget otherwise it displays application icon

src/DockWidget.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -147,8 +147,8 @@ private slots:
147147

148148
enum DockWidgetFeature
149149
{
150-
DockWidgetClosable = 0x01,
151-
DockWidgetMovable = 0x02,///< this feature is not properly implemented yet and is ignored
150+
DockWidgetClosable = 0x01,///< dock widget has a close button
151+
DockWidgetMovable = 0x02,///< dock widget is movable and can be moved to a new position in the current dock container
152152
DockWidgetFloatable = 0x04,
153153
DockWidgetDeleteOnClose = 0x08, ///< deletes the dock widget when it is closed
154154
CustomCloseHandling = 0x10,

0 commit comments

Comments
 (0)