I have a few questions regarding a QtQuick wayland compositor that
supports a rotated display.
The use case is less of a desktop compositor and more of an embedded
application.
As currently implemented, we have a qml Item that rotates child
elements, including connected clients surfaces, according to some
configured screen orientation.
However, a client would not be able to determine the screen orientation
properly using QScreen. For example, a client might do something like this:
| auto screen = this->screen();||
|| auto size = screen->mapBetween(screen->orientation(),
screen->nativeOrientation(), screen->geometry());||
|| setFixedSize(size.width(), size.height());|
Diving into QScreen, QWaylandScreen, and QWaylandOutput, QScreen
orientation is decided from wl_output transform in conjunction with
wl_output geometry.
It seems like the only way to influence the output's geometry is QML is
through sizeFollowsWindow, where the output mode and geometry follows
the window since addMode is not usable from QML and geometry is a
readonly property. availableGeometry does not seem to have any effect.
However, our root window that displays our output should match the eglfs
geometry and as such wouldn't change to match a portrait orientation.
I see two options now, but maybe I am missing a more elegant way:
1. nest Windows such that the root window matches eglfs and then a child
window is rotated within that to match the logical geometry thats
supüposed to be visible to clients
2. write c++ code to add modes manually to our WaylandOutput and set the
correct mode while having sizeFollowsWindow=false
best regards
Florian Hänel
--
Florian Hänel
Geschäftsführer
echtzeit.solutions GmbH
Handelsregistergericht München HRB 231056
Ust-ID DE310379807
_______________________________________________
Interest mailing list
Interest@qt-project.org
https://lists.qt-project.org/listinfo/interest