DockWidgetFactoryBase

Search for usage in LXR

DockWidgetFactoryBase Class Reference

#include <DockWidgetFactoryBase.h>

Inherits KoDockFactoryBase.

Public Member Functions

 DockWidgetFactoryBase (const QString &_id, DockPosition _dockPosition)
 
DockPosition defaultDockPosition () const override
 
QString id () const override
 

Detailed Description

The DockWidgetFactoryBase class is the base class for plugins that want to add a dock widget to every window.

You do not need to implement this class yourself, but create a DockWidget implementation and then add the DockWidgetFactory to the Krita instance like this:

class HelloDocker(DockWidget):
def __init__(self):
super().__init__()
label = QLabel("Hello", self)
self.setWidget(label)
self.label = label
def canvasChanged(self, canvas):
self.label.setText("Hellodocker: canvas changed");
Application.addDockWidgetFactory(DockWidgetFactory("hello", DockWidgetFactoryBase.DockRight, HelloDocker))

Definition at line 36 of file DockWidgetFactoryBase.h.


The documentation for this class was generated from the following files:
QString label(StandardShortcut id)
This file is part of the KDE documentation.
Documentation copyright © 1996-2022 The KDE developers.
Generated on Fri Aug 12 2022 03:57:18 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.