KDDockWidgets API Documentation 2.1
Loading...
Searching...
No Matches
flutter/ViewFactory.cpp
Go to the documentation of this file.
1/*
2 This file is part of KDDockWidgets.
3
4 SPDX-FileCopyrightText: 2019 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 "ViewFactory.h"
13#include "Config.h"
14
15#include "ClassicIndicatorsWindow.h"
16#include "core/Utils_p.h"
17#include "core/Logging_p.h"
18#include "Action.h"
19
20#include "kddockwidgets/core/TabBar.h"
21#include "kddockwidgets/core/Stack.h"
22#include "kddockwidgets/core/FloatingWindow.h"
23#include "kddockwidgets/core/indicators/ClassicDropIndicatorOverlay.h"
24#include "kddockwidgets/core/indicators/NullDropIndicatorOverlay.h"
25#include "kddockwidgets/core/indicators/SegmentedDropIndicatorOverlay.h"
26#include "kddockwidgets/core/MainWindow.h"
27
29
30
31// clazy:excludeall=ctor-missing-parent-argument
32
33using namespace KDDockWidgets;
34using namespace KDDockWidgets::flutter;
35
39
40Core::View *ViewFactory::createDockWidget(const QString &, DockWidgetOptions, LayoutSaverOptions,
41 Qt::WindowFlags) const
42{
43 return {};
44}
45
46
48{
49 assert(false);
50 return {};
51}
52
57
62
64{
65 return {};
66}
67
72
78
80{
81 return nullptr;
82}
83
88
89// iconForButtonType impl is the same for QtQuick and QtWidgets
91{
92 return {};
93}
94
99
104
111
114{
115 // We need a little indirection here, since our bindings don't support multiple inheritance
116 // In dart View factory can't return something of type ClassicIndicatorWindowViewInterface when only having IndicatorWindow
117 // But in C++ we can, so get it from flutter and cast it here
118 return createClassicIndicatorWindow_flutter(controller, parent);
119}
120
123{
124 KDDW_WARN("ViewFactory::createClassicIndicatorWindow_flutter: Implemented in dart");
125 return nullptr;
126}
127
129{
130 return new Flutter::Action(dw, debugName);
131}
Application-wide config to tune certain behaviours of the framework.
The window that will hold the classic indicators This is a window so it can be over the window that i...
The DockWidget base-class. DockWidget and Core::DockWidget are only split in two so we can share some...
The MDILayout class implements a layout suitable for MDI style docking. Where dock widgets are free t...
The MainWindow base-class. MainWindow and MainWindowBase are only split in two so we can share some c...
Icon iconForButtonType(TitleBarButtonType type, double dpr) const override
Returns the icon to be used with the specified type.
Core::View * createTabBar(Core::TabBar *tabBar, Core::View *parent=nullptr) const override
Called by the framework to create a TabBar view Override to provide your own TabBar sub-class.
Core::ClassicIndicatorWindowViewInterface * createClassicIndicatorWindow(Core::ClassicDropIndicatorOverlay *, Core::View *parent=0) const override
Creates the window that will show the actual drop indicators. They need a higher z-order,...
Core::View * createSeparator(Core::Separator *, Core::View *parent=nullptr) const override
Called by the framework to create a Separator view Override to provide your own Separator sub-class....
Core::View * createStack(Core::Stack *, Core::View *parent) const override
Called by the framework to create a Stack view Override to provide your own Stack sub-class.
~ViewFactory() override
Destructor. Don't delete ViewFactory directly, it's owned by the framework.
KDDockWidgets::Core::Action * createAction(Core::DockWidget *, const char *debugName) const override
Creates a QAction if QtWidgets, or an equivalent fallback if QtQuick/Flutter Not needed to be overrid...
Core::View * createDropArea(Core::DropArea *, Core::View *parent) const override
Called by the framework to create a DropArea view.
Core::View * createTitleBar(Core::TitleBar *, Core::View *parent) const override
Called by the framework to create a TitleBar view Override to provide your own TitleBar sub-class....
Core::View * createSideBar(Core::SideBar *, Core::View *parent) const override
Called by the framework to create a SideBar view.
Core::View * createSegmentedDropIndicatorOverlayView(Core::SegmentedDropIndicatorOverlay *controller, Core::View *parent) const override
Creates the view that will parent the segmented drop indicators.
Core::View * createGroup(Core::Group *, Core::View *parent=nullptr) const override
Called by the framework to create a Frame view Override to provide your own Frame sub-class....
Core::View * createRubberBand(Core::View *parent) const override
Called by the framework to create a RubberBand view to show as drop zone.
virtual flutter::IndicatorWindow * createClassicIndicatorWindow_flutter(Core::ClassicDropIndicatorOverlay *, Core::View *parent=0) const
Core::View * createFloatingWindow(Core::FloatingWindow *, Core::MainWindow *parent=nullptr, Qt::WindowFlags windowFlags={}) const override
Called by the framework to create a FloatingWindow view Override to provide your own FloatingWindow s...
Core::View * createMDILayout(Core::MDILayout *, Core::View *parent) const override
Called by the framework to create a MDI Layout view.
Core::View * createDockWidget(const QString &uniqueName, DockWidgetOptions={}, LayoutSaverOptions={}, Qt::WindowFlags={}) const override
Creates a dock widget. This is only used by MainWindow's persistent widget feature....
Class to abstract QAction, so code still works with QtQuick and Flutter.
TitleBarButtonType
describes a type of button you can have in the title bar
typedef WindowFlags
A factory class for allowing the user to customize some internal widgets.

© 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 by doxygen 1.9.8