mirror of
https://github.com/githubuser0xFFFF/Qt-Advanced-Docking-System.git
synced 2024-11-15 13:15:43 +08:00
Implemented support for Opaque / Non Opaque auto hide container resizing
This commit is contained in:
parent
f22d62a85b
commit
f5ac29c19e
@ -616,7 +616,7 @@ CMainWindow::CMainWindow(QWidget *parent) :
|
|||||||
|
|
||||||
// uncomment the following line if you want to use opaque undocking and
|
// uncomment the following line if you want to use opaque undocking and
|
||||||
// opaque splitter resizing
|
// opaque splitter resizing
|
||||||
// CDockManager::setConfigFlags(CDockManager::DefaultOpaqueConfig);
|
//CDockManager::setConfigFlags(CDockManager::DefaultOpaqueConfig);
|
||||||
|
|
||||||
// uncomment the following line if you want a fixed tab width that does
|
// uncomment the following line if you want a fixed tab width that does
|
||||||
// not change if the visibility of the close button changes
|
// not change if the visibility of the close button changes
|
||||||
|
@ -94,6 +94,10 @@ int resizeHandleLayoutPosition(CDockWidgetSideTab::SideTabBarArea Area)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Private data of CAutoHideDockContainer - pimpl
|
||||||
|
*/
|
||||||
struct AutoHideDockContainerPrivate
|
struct AutoHideDockContainerPrivate
|
||||||
{
|
{
|
||||||
CAutoHideDockContainer* _this;
|
CAutoHideDockContainer* _this;
|
||||||
@ -126,6 +130,9 @@ struct AutoHideDockContainerPrivate
|
|||||||
return LeftDockWidgetArea;
|
return LeftDockWidgetArea;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Update the resize limit of the resize handle
|
||||||
|
*/
|
||||||
void updateResizeHandleSizeLimitMax()
|
void updateResizeHandleSizeLimitMax()
|
||||||
{
|
{
|
||||||
auto Rect = _this->parentContainer()->contentRect();
|
auto Rect = _this->parentContainer()->contentRect();
|
||||||
@ -182,6 +189,8 @@ CAutoHideDockContainer::CAutoHideDockContainer(CDockManager* DockManager, CDockW
|
|||||||
d->Layout->addWidget(d->DockArea);
|
d->Layout->addWidget(d->DockArea);
|
||||||
d->ResizeHandle = new CResizeHandle(edgeFromSideTabBarArea(area), this);
|
d->ResizeHandle = new CResizeHandle(edgeFromSideTabBarArea(area), this);
|
||||||
d->ResizeHandle->setMinResizeSize(64);
|
d->ResizeHandle->setMinResizeSize(64);
|
||||||
|
bool OpaqueResize = CDockManager::testConfigFlag(CDockManager::OpaqueSplitterResize);
|
||||||
|
d->ResizeHandle->setOpaqueResize(OpaqueResize);
|
||||||
d->Layout->insertWidget(resizeHandleLayoutPosition(area), d->ResizeHandle);
|
d->Layout->insertWidget(resizeHandleLayoutPosition(area), d->ResizeHandle);
|
||||||
d->Size = d->DockArea->size();
|
d->Size = d->DockArea->size();
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user