|
Krita Source Code Documentation
|
#include <KisRootSurfaceInfoProxy.h>
Inheritance diagram for KisRootSurfaceInfoProxy:Signals | |
| void | sigRootSurfaceProfileChanged (const KoColorProfile *profile) const |
Public Member Functions | |
| QString | colorManagementReport () const |
| std::optional< KisSurfaceColorimetry::SurfaceDescription > | currentSurfaceDescription () const |
| bool | isReady () const |
| KisRootSurfaceInfoProxy (QWidget *watched, QObject *parent=nullptr) | |
| QString | osPreferredColorSpaceReport () const |
| const KoColorProfile * | rootSurfaceProfile () const |
| ~KisRootSurfaceInfoProxy () | |
Public Member Functions inherited from KisRootSurfaceTrackerBase | |
| KisRootSurfaceTrackerBase (QWidget *watched, QObject *parent=nullptr) | |
| QWidget * | trackedWidget () const |
| ~KisRootSurfaceTrackerBase () | |
Private Member Functions | |
| void | connectToNativeWindow (QWindow *nativeWindow) override |
| void | disconnectFromNativeWindow () override |
| void | tryUpdateRootSurfaceProfile () |
Private Attributes | |
| const KoColorProfile * | m_rootSurfaceProfile {nullptr} |
| QMetaObject::Connection | m_surfaceManagerConnection |
| QPointer< KisSRGBSurfaceColorSpaceManager > | m_topLevelSurfaceManager |
Additional Inherited Members | |
Protected Member Functions inherited from KisRootSurfaceTrackerBase | |
| void | initialize () |
KisRootSurfaceInfoProxy is a special proxy object for the surface color management information of the widget.
When created, the proxy does the following:
1) Finds the top-level widget that watched belongs to. (is watched changed its parent in the meantime, e.g. during construction, then the proxy will handle that as well)
2) Finds the QWindow that this toplevel widget is painted on (if platform window is not created yet, subscribes to QPlatformSurfaceEvent to attach when platform window is finally created)
3) Finds KisSRGBSurfaceColorSpaceManager object attached to this window. This object is usually attached with an event filter in KisApplication to all windows not having a special property (if the manager is not yet attached, tracks its addition by filtering QChildEvent)
4) Finally, connects to the manager and forwards its sigDisplayConfigChanged() to local sigRootSurfaceProfileChanged()
Definition at line 43 of file KisRootSurfaceInfoProxy.h.
| KisRootSurfaceInfoProxy::KisRootSurfaceInfoProxy | ( | QWidget * | watched, |
| QObject * | parent = nullptr ) |
Definition at line 19 of file KisRootSurfaceInfoProxy.cpp.
References KisRootSurfaceTrackerBase::initialize(), KoColorSpaceRegistry::instance(), KisPlatformPluginInterfaceFactory::instance(), KIS_SAFE_ASSERT_RECOVER_RETURN, m_rootSurfaceProfile, and KoColorSpaceRegistry::p709SRGBProfile().
| KisRootSurfaceInfoProxy::~KisRootSurfaceInfoProxy | ( | ) |
Definition at line 28 of file KisRootSurfaceInfoProxy.cpp.
| QString KisRootSurfaceInfoProxy::colorManagementReport | ( | ) | const |
Definition at line 42 of file KisRootSurfaceInfoProxy.cpp.
References m_topLevelSurfaceManager.
|
overrideprivatevirtual |
Implements KisRootSurfaceTrackerBase.
Definition at line 60 of file KisRootSurfaceInfoProxy.cpp.
References KIS_SAFE_ASSERT_RECOVER_RETURN, m_surfaceManagerConnection, m_topLevelSurfaceManager, KisCanvasSurfaceColorSpaceManager::sigDisplayConfigChanged(), and tryUpdateRootSurfaceProfile().
| std::optional< KisSurfaceColorimetry::SurfaceDescription > KisRootSurfaceInfoProxy::currentSurfaceDescription | ( | ) | const |
Definition at line 54 of file KisRootSurfaceInfoProxy.cpp.
References m_topLevelSurfaceManager.
|
overrideprivatevirtual |
Implements KisRootSurfaceTrackerBase.
Definition at line 79 of file KisRootSurfaceInfoProxy.cpp.
References m_surfaceManagerConnection, m_topLevelSurfaceManager, and tryUpdateRootSurfaceProfile().
| bool KisRootSurfaceInfoProxy::isReady | ( | ) | const |
Definition at line 37 of file KisRootSurfaceInfoProxy.cpp.
References m_topLevelSurfaceManager.
| QString KisRootSurfaceInfoProxy::osPreferredColorSpaceReport | ( | ) | const |
Definition at line 48 of file KisRootSurfaceInfoProxy.cpp.
References m_topLevelSurfaceManager.
| const KoColorProfile * KisRootSurfaceInfoProxy::rootSurfaceProfile | ( | ) | const |
Definition at line 32 of file KisRootSurfaceInfoProxy.cpp.
References m_rootSurfaceProfile.
|
signal |
|
private |
Definition at line 88 of file KisRootSurfaceInfoProxy.cpp.
References KoColorSpaceRegistry::instance(), KIS_SAFE_ASSERT_RECOVER_RETURN, m_rootSurfaceProfile, m_topLevelSurfaceManager, KoColorSpaceRegistry::p709SRGBProfile(), and sigRootSurfaceProfileChanged().
|
private |
Definition at line 70 of file KisRootSurfaceInfoProxy.h.
|
private |
Definition at line 68 of file KisRootSurfaceInfoProxy.h.
|
private |
Definition at line 67 of file KisRootSurfaceInfoProxy.h.