Phosphor
Qt6 / Wayland library suite for window-management tools
Loading...
Searching...
No Matches
PhosphorZones::LayoutComputeService Class Reference

#include <PhosphorZones/LayoutComputeService.h>

Inheritance diagram for PhosphorZones::LayoutComputeService:
[legend]

Signals

void requestCompute (const PhosphorZones::LayoutSnapshot &snapshot, uint64_t generation)
void geometriesComputedForGeneration (const QString &screenId, const QUuid &layoutId, PhosphorZones::Layout *layout, uint64_t generation)

Public Member Functions

 LayoutComputeService (QObject *parent=nullptr)
 ~LayoutComputeService () override
void setLayoutManager (LayoutRegistry *manager)
bool requestRecalculate (Layout *layout, const QString &screenId, const QRectF &screenGeometry, qreal screenScale=0.0)
 screenScale is the output's logical scale, an input for a layout whose fixed geometry counts device pixels; zero keeps the layout's last one.
uint64_t currentGeneration (const QString &screenId) const

Static Public Member Functions

static void recalculateSync (Layout *layout, const QRectF &screenGeometry, qreal screenScale=0.0)
 Recalculate layout in place, on the calling (GUI) thread.

Constructor & Destructor Documentation

◆ LayoutComputeService()

PhosphorZones::LayoutComputeService::LayoutComputeService ( QObject * parent = nullptr)
explicit

◆ ~LayoutComputeService()

PhosphorZones::LayoutComputeService::~LayoutComputeService ( )
override

Member Function Documentation

◆ currentGeneration()

uint64_t PhosphorZones::LayoutComputeService::currentGeneration ( const QString & screenId) const

◆ geometriesComputedForGeneration

void PhosphorZones::LayoutComputeService::geometriesComputedForGeneration ( const QString & screenId,
const QUuid & layoutId,
PhosphorZones::Layout * layout,
uint64_t generation )
signal

◆ recalculateSync()

void PhosphorZones::LayoutComputeService::recalculateSync ( Layout * layout,
const QRectF & screenGeometry,
qreal screenScale = 0.0 )
static

Recalculate layout in place, on the calling (GUI) thread.

Refuses an invalid screenGeometry, as requestRecalculate does: an empty rect would stamp a frame with no size and collapse every zone onto a point.

◆ requestCompute

void PhosphorZones::LayoutComputeService::requestCompute ( const PhosphorZones::LayoutSnapshot & snapshot,
uint64_t generation )
signal

◆ requestRecalculate()

bool PhosphorZones::LayoutComputeService::requestRecalculate ( Layout * layout,
const QString & screenId,
const QRectF & screenGeometry,
qreal screenScale = 0.0 )

screenScale is the output's logical scale, an input for a layout whose fixed geometry counts device pixels; zero keeps the layout's last one.

◆ setLayoutManager()

void PhosphorZones::LayoutComputeService::setLayoutManager ( LayoutRegistry * manager)

The documentation for this class was generated from the following file: