KDDockWidgets API Documentation 2.1
|
#include <Stack.h>
Public Member Functions | |
Stack (Group *, StackOptions) | |
virtual | ~Stack () override |
void | addDockWidget (DockWidget *) |
appends a dock widget into this TabWidget | |
bool | buttonHidesIfDisabled (TitleBarButtonType) const |
bool | contains (DockWidget *dw) const |
Returns whether dockwidget dw is contained in this tab widget Equivalent to indexOf(dw) != -1. | |
Group * | group () const |
getter for the group | |
bool | insertDockWidget (DockWidget *dockwidget, int index) |
inserts dockwidget into the TabWidget, at index | |
bool | isMDI () const override |
bool | isPositionDraggable (Point p) const override |
bool | isWindow () const override |
std::unique_ptr< WindowBeingDragged > | makeWindow () override |
int | numDockWidgets () const |
returns the number of dock widgets in this TabWidget | |
bool | onMouseDoubleClick (Point localPos) |
StackOptions | options () const |
void | setDocumentMode (bool) |
Enables document mode. Default is false. | |
void | setHideDisabledButtons (TitleBarButtonTypes) |
void | setTabBarAutoHide (bool) |
DockWidget * | singleDockWidget () const override final |
Core::TabBar * | tabBar () const |
Returns the tab bar. | |
bool | tabBarAutoHide () const |
Public Member Functions inherited from KDDockWidgets::Core::Controller | |
Controller (ViewType type, View *) | |
virtual | ~Controller () |
bool | close () |
void | destroyLater () |
Controller::Private * | dptr () const |
Rect | geometry () const |
int | height () const |
bool | inDtor () const |
bool | is (ViewType) const |
Returns whether this controller is of the specified type. | |
bool | isFixedHeight () const |
bool | isFixedWidth () const |
bool | isVisible () const |
Point | mapToGlobal (Point) const |
Point | pos () const |
Rect | rect () const |
void | setParentView (View *parent) |
void | setVisible (bool) |
void | show () const |
Size | size () const |
ViewType | type () const |
Returns the type of this controller. | |
View * | view () const |
Returns the view associated with this controller, if any. | |
int | width () const |
std::shared_ptr< View > | window () const |
int | x () const |
int | y () const |
Additional Inherited Members | |
Protected Member Functions inherited from KDDockWidgets::Core::Controller | |
virtual void | setParentView_impl (View *parent) |
Protected Attributes inherited from KDDockWidgets::Core::Controller | |
bool | m_inDtor = false |
Definition at line 34 of file core/Stack.h.
|
explicit |
Definition at line 30 of file core/Stack.cpp.
References KDDockWidgets::Core::View::init(), QtQuick::TabBar, and KDDockWidgets::Core::Controller::view().
|
overridevirtual |
Definition at line 44 of file core/Stack.cpp.
void Stack::addDockWidget | ( | DockWidget * | dock | ) |
appends a dock widget into this TabWidget
Definition at line 63 of file core/Stack.cpp.
References insertDockWidget(), and numDockWidgets().
Referenced by KDDockWidgetsBindings_wrappersNS::KDDWBindingsCore::Stack_wrapper::addDockWidget(), and c_KDDockWidgets__Core__Stack__addDockWidget_DockWidget().
bool Stack::buttonHidesIfDisabled | ( | TitleBarButtonType | type | ) | const |
Definition at line 228 of file core/Stack.cpp.
References KDDockWidgets::Core::Controller::type().
bool Stack::contains | ( | DockWidget * | dw | ) | const |
Returns whether dockwidget dw
is contained in this tab widget Equivalent to indexOf(dw) != -1.
Definition at line 103 of file core/Stack.cpp.
Referenced by c_KDDockWidgets__Core__Stack__contains_DockWidget(), and insertDockWidget().
Group * Stack::group | ( | ) | const |
getter for the group
Definition at line 108 of file core/Stack.cpp.
Referenced by c_KDDockWidgets__Core__Stack__group(), KDDockWidgets::Core::TabBar::group(), KDDockWidgets::QtWidgets::Stack::mousePressEvent(), and onMouseDoubleClick().
bool Stack::insertDockWidget | ( | DockWidget * | dockwidget, |
int | index | ||
) |
inserts dockwidget
into the TabWidget, at index
dockwidget | the dockwidget to insert |
index | The index to where to put it |
Definition at line 68 of file core/Stack.cpp.
References contains(), KDDockWidgets::Core::DockWidget::d, KDDockWidgets::Core::DockWidget::icon(), numDockWidgets(), KDDockWidgets::TabBar, and KDDockWidgets::Core::DockWidget::title().
Referenced by addDockWidget(), c_KDDockWidgets__Core__Stack__insertDockWidget_DockWidget_int(), and KDDockWidgets::Core::GroupViewInterface::insertDockWidget().
|
override |
Definition at line 158 of file core/Stack.cpp.
|
override |
Definition at line 55 of file core/Stack.cpp.
References KDDockWidgets::Core::Controller::view().
|
override |
Definition at line 138 of file core/Stack.cpp.
References KDDockWidgets::Core::Controller::view().
|
override |
Definition at line 113 of file core/Stack.cpp.
References KDDockWidgets::Core::View::mapToGlobal(), KDDockWidgets::SuggestedGeometryHint_GeometryIsFromDocked, and KDDockWidgets::Core::Controller::view().
Referenced by onMouseDoubleClick().
int Stack::numDockWidgets | ( | ) | const |
returns the number of dock widgets in this TabWidget
Definition at line 210 of file core/Stack.cpp.
Referenced by addDockWidget(), c_KDDockWidgets__Core__Stack__numDockWidgets(), KDDockWidgets::Core::Group::dockWidgetCount(), and insertDockWidget().
bool Stack::onMouseDoubleClick | ( | Point | localPos | ) |
Definition at line 163 of file core/Stack.cpp.
References KDDockWidgets::Config::Flag_HideTitleBarWhenTabsVisible, KDDockWidgets::Core::Group::floatingWindow(), group(), KDDockWidgets::Core::Group::isCentralGroup(), KDDockWidgets::Core::Group::isInMainWindow(), makeWindow(), KDDockWidgets::Config::self(), and tabBar().
Referenced by c_KDDockWidgets__Core__Stack__onMouseDoubleClick_Point(), and KDDockWidgets::QtWidgets::Stack::mouseDoubleClickEvent().
StackOptions Stack::options | ( | ) | const |
Definition at line 50 of file core/Stack.cpp.
void Stack::setDocumentMode | ( | bool | is | ) |
Enables document mode. Default is false.
Definition at line 215 of file core/Stack.cpp.
References KDDockWidgets::Core::Controller::is(), setDocumentMode(), and KDDockWidgets::Core::Controller::view().
Referenced by c_KDDockWidgets__Core__Stack__setDocumentMode_bool(), KDDockWidgetsBindings_wrappersNS::KDDWBindingsCore::Stack_wrapper::setDocumentMode(), and setDocumentMode().
void Stack::setHideDisabledButtons | ( | TitleBarButtonTypes | types | ) |
The specified buttons, if disabled, will be hidden as well for example, with non-closable dock widgets we disable the close button this allows to hide it as well. Only relevant with Flag_ShowButtonsOnTabBarIfTitleBarHidden
Definition at line 220 of file core/Stack.cpp.
void Stack::setTabBarAutoHide | ( | bool | is | ) |
Sets whether the tab bar should be hidden when there's only 1 tab shown Default is true. See Config::Flag_AlwaysShowTabs to change this behaviour
Definition at line 191 of file core/Stack.cpp.
References KDDockWidgets::Core::Controller::is().
Referenced by KDDockWidgets::Core::Group::Group(), c_KDDockWidgets__Core__Stack__setTabBarAutoHide_bool(), and KDDockWidgetsBindings_wrappersNS::KDDWBindingsCore::Stack_wrapper::setTabBarAutoHide().
|
finaloverride |
Definition at line 148 of file core/Stack.cpp.
Referenced by c_KDDockWidgets__Core__Stack__singleDockWidget().
Core::TabBar * Stack::tabBar | ( | ) | const |
Returns the tab bar.
Definition at line 205 of file core/Stack.cpp.
Referenced by c_KDDockWidgets__Core__Stack__tabBar(), KDDockWidgets::QtWidgets::Stack::init(), onMouseDoubleClick(), KDDockWidgets::Core::Group::tabBar(), KDDockWidgets::Core::TitleBar::tabBar(), and KDDockWidgets::QtWidgets::Stack::tabBar().
bool Stack::tabBarAutoHide | ( | ) | const |
Definition at line 200 of file core/Stack.cpp.
Referenced by c_KDDockWidgets__Core__Stack__tabBarAutoHide(), and KDDockWidgets::QtQuick::TabBar::tabBarAutoHide().