KDDockWidgets API Documentation
1.5
source
src
MainWindowMDI.cpp
Go to the documentation of this file.
1
/*
2
This file is part of KDDockWidgets.
3
4
SPDX-FileCopyrightText: 2019-2022 Klarälvdalens Datakonsult AB, a KDAB Group company <info@kdab.com>
5
Author: SĂ©rgio Martins <sergio.martins@kdab.com>
6
7
SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only
8
9
Contact KDAB at <info@kdab.com> for commercial licensing options.
10
*/
11
12
#include "
MainWindowMDI.h
"
13
#include "private/MDILayoutWidget_p.h"
14
15
using namespace
KDDockWidgets
;
16
17
MainWindowMDI::MainWindowMDI
(
const
QString
&uniqueName,
WidgetType
*parent,
Qt::WindowFlags
flags)
18
:
MDIMainWindowBase
(uniqueName,
MainWindowOption_MDI
, parent, flags)
19
{
20
}
21
22
MainWindowMDI::~MainWindowMDI
()
23
{
24
}
25
26
void
MainWindowMDI::addDockWidget
(
DockWidgetBase
*dockWidget,
QPoint
localPos,
InitialOption
addingOption)
27
{
28
auto
layout
=
static_cast<
MDILayoutWidget *
>
(this->
layoutWidget
());
29
layout
->addDockWidget(dockWidget, localPos, addingOption);
30
}
31
32
void
MainWindowMDI::addDockWidget
(
DockWidgetBase
*dockWidget,
QPointF
localPos,
InitialOption
addingOption)
33
{
34
MainWindowMDI::addDockWidget
(dockWidget, localPos.
toPoint
(), addingOption);
35
}
KDDockWidgets::InitialOption
Struct describing the preferred dock widget size and visibility when adding it to a layout.
Definition:
KDDockWidgets.h:105
KDDockWidgets::MainWindowBase::layoutWidget
LayoutWidget * layoutWidget() const
Definition:
MainWindowBase.cpp:200
QWidget::layout
QLayout * layout() const const
QWidget
QPointF
KDDockWidgets::MainWindowMDI::addDockWidget
void addDockWidget(DockWidgetBase *dockWidget, QPoint localPos, InitialOption addingOption={})
Docks dockWidget The widget will be placed at the specified position.
Definition:
MainWindowMDI.cpp:26
Qt::WindowFlags
typedef WindowFlags
KDDockWidgets::MainWindowOption_MDI
@ MainWindowOption_MDI
Makes the MainWindow always have a central frame, for tabbing documents
Definition:
KDDockWidgets.h:58
QString
KDDockWidgets::MainWindow
The QMainwindow sub-class that the application should use to be able to dock KDDockWidget::DockWidget...
Definition:
MainWindow.h:33
KDDockWidgets::DockWidgetBase
The DockWidget base-class. DockWidget and DockWidgetBase are only split in two so we can share some c...
Definition:
DockWidgetBase.h:61
QPointF::toPoint
QPoint toPoint() const const
KDDockWidgets::MainWindowMDI::~MainWindowMDI
~MainWindowMDI() override
Destructor.
Definition:
MainWindowMDI.cpp:22
KDDockWidgets
Definition:
Config.cpp:36
KDDockWidgets::MainWindowMDI::MainWindowMDI
MainWindowMDI(const QString &uniqueName, WidgetType *parent=nullptr, Qt::WindowFlags flags=Qt::WindowFlags())
Constructor. See base class documentation.
Definition:
MainWindowMDI.cpp:17
MainWindowMDI.h
MainWindow sub-class which uses MDI as a layout.
QPoint
© 2019-2022 Klarälvdalens Datakonsult AB (KDAB)
"The Qt, C++ and OpenGL Experts"
https://www.kdab.com/
KDDockWidgets
Advanced Dock Widget Framework for Qt
https://www.kdab.com/development-resources/qt-tools/kddockwidgets/
Generated on Mon Mar 7 2022 02:01:20 for KDDockWidgets API Documentation by doxygen 1.8.20