QWaylandOutput Class
QWaylandOutput 클래스는 컴포저가 관리하는 표시 가능한 영역을 나타냅니다. 더 보기...
Header: | #include <QWaylandOutput> |
CMake: | find_package(Qt6 REQUIRED COMPONENTS WaylandCompositor) target_link_libraries(mytarget PRIVATE Qt6::WaylandCompositor) |
qmake: | QT += waylandcompositor |
QML에서: | WaylandOutput |
상속합니다: | QWaylandObject |
공용 유형
enum | Subpixel { SubpixelUnknown, SubpixelNone, SubpixelHorizontalRgb, SubpixelHorizontalBgr, SubpixelVerticalRgb, SubpixelVerticalBgr } |
enum | Transform { TransformNormal, Transform90, Transform180, Transform270, TransformFlipped, …, TransformFlipped270 } |
속성
|
|
공공 기능
QWaylandOutput(QWaylandCompositor *compositor, QWindow *window) | |
virtual | ~QWaylandOutput() override |
void | addMode(const QWaylandOutputMode &mode, bool preferred = false) |
QRect | availableGeometry() const |
QWaylandCompositor * | compositor() const |
QWaylandOutputMode | currentMode() const |
void | frameStarted() |
QRect | geometry() const |
QString | manufacturer() const |
QString | model() const |
QList<QWaylandOutputMode> | modes() const |
QSize | physicalSize() const |
QPoint | position() const |
int | scaleFactor() const |
void | sendFrameCallbacks() |
void | setAvailableGeometry(const QRect &availableGeometry) |
void | setCurrentMode(const QWaylandOutputMode &mode) |
void | setManufacturer(const QString &manufacturer) |
void | setModel(const QString &model) |
void | setPhysicalSize(const QSize &size) |
void | setPosition(const QPoint &pt) |
void | setScaleFactor(int scale) |
void | setSizeFollowsWindow(bool follow) |
void | setSubpixel(const QWaylandOutput::Subpixel &subpixel) |
void | setTransform(const QWaylandOutput::Transform &transform) |
void | setWindow(QWindow *window) |
bool | sizeFollowsWindow() const |
QWaylandOutput::Subpixel | subpixel() const |
QWaylandOutput::Transform | transform() const |
virtual void | update() |
QWindow * | window() const |
신호
void | availableGeometryChanged() |
void | compositorChanged() |
void | geometryChanged() |
void | manufacturerChanged() |
void | modelChanged() |
void | physicalSizeChanged() |
void | positionChanged() |
void | scaleFactorChanged() |
void | sizeFollowsWindowChanged() |
void | subpixelChanged() |
void | transformChanged() |
void | windowChanged() |
정적 공용 멤버
QWaylandOutput * | fromResource(wl_resource *resource) |
상세 설명
QWaylandOutput은 컴포저의 지오메트리 범위 내에서 직사각형 영역을 관리하여 클라이언트 콘텐츠를 표시하는 데 사용합니다. 예를 들어 WaylandCompositor 에서 관리하는 화면이 될 수 있습니다.
이 클래스는 Wayland 프로토콜의 wl_output
인터페이스에 해당합니다.
멤버 유형 문서
enum QWaylandOutput::Subpixel
이 열거형 유형은 QWaylandOutput 의 서브픽셀 배열을 지정하는 데 사용됩니다.
Constant | 값 | 설명 |
---|---|---|
QWaylandOutput::SubpixelUnknown | 0 | 서브픽셀 배열이 설정되지 않았습니다. |
QWaylandOutput::SubpixelNone | 1 | 서브픽셀이 없습니다. |
QWaylandOutput::SubpixelHorizontalRgb | 2 | 하위 픽셀이 빨강, 녹색, 파랑 순서로 수평으로 배열됩니다. |
QWaylandOutput::SubpixelHorizontalBgr | 3 | 하위 픽셀이 파란색, 녹색, 빨간색 순서로 수평으로 배열됩니다. |
QWaylandOutput::SubpixelVerticalRgb | 4 | 서브픽셀은 빨강, 녹색, 파랑 순으로 세로로 배열됩니다. |
QWaylandOutput::SubpixelVerticalBgr | 5 | 하위 픽셀은 파란색, 녹색, 빨간색 순서로 수직으로 배열됩니다. |
QWaylandOutput::subpixel 를참조하세요 .
enum QWaylandOutput::Transform
* * 이 열거형 유형은 QWaylandOutput 의 방향을 지정하는 데 사용됩니다.
Constant | 값 | 설명 |
---|---|---|
QWaylandOutput::TransformNormal | 0 | 방향은 정상입니다. * |
QWaylandOutput::Transform90 | 1 | 방향이 90도 회전됩니다. * |
QWaylandOutput::Transform180 | 2 | 방향이 180도 회전됩니다. * |
QWaylandOutput::Transform270 | 3 | 방향이 270도 회전됩니다. * |
QWaylandOutput::TransformFlipped | 4 | 방향이 미러링됩니다. * |
QWaylandOutput::TransformFlipped90 | 5 | 방향이 미러링되고 90도 회전됩니다. * |
QWaylandOutput::TransformFlipped180 | 6 | 방향이 미러링되고 180도 회전됩니다. * |
QWaylandOutput::TransformFlipped270 | 7 | 방향이 미러링되고 270도 회전됩니다. * * |
QWaylandOutput::transform 를참조하세요 .
속성 문서
availableGeometry : QRect
이 속성은 콘텐츠를 표시하는 데 사용할 수 있는 QWaylandOutput 의 지오메트리를 보유합니다. 사용 가능한 지오메트리는 출력 좌표 공간에 있으며 0,0부터 시작하고 기본적으로 출력 크기만큼 큽니다.
함수에 액세스합니다:
QRect | availableGeometry() const |
void | setAvailableGeometry(const QRect &availableGeometry) |
알림 신호:
void | availableGeometryChanged() |
QWaylandOutput::currentMode 및 QWaylandOutput::geometry 을참조하세요 .
[read-only]
geometry : const QRect
이 프로퍼티는 QWaylandOutput 의 지오메트리를 보유합니다.
액세스 함수입니다:
QRect | geometry() const |
알림 신호:
void | geometryChanged() |
QWaylandOutput::currentMode 를참조하세요 .
manufacturer : QString
이 속성에는 이 QWaylandOutput 의 제조업체에 대한 텍스트 설명이 포함되어 있습니다.
액세스 함수:
QString | manufacturer() const |
void | setManufacturer(const QString &manufacturer) |
알림 신호:
void | manufacturerChanged() |
model : QString
이 속성에는 이 모델에 대한 텍스트 설명이 들어 있습니다 QWaylandOutput.
액세스 함수:
QString | model() const |
void | setModel(const QString &model) |
알림 신호:
void | modelChanged() |
physicalSize : QSize
이 속성은 QWaylandOutput 의 물리적 크기(밀리미터)를 보유합니다.
액세스 함수:
QSize | physicalSize() const |
void | setPhysicalSize(const QSize &size) |
알림 신호:
void | physicalSizeChanged() |
QWaylandOutput::geometry 및 QWaylandOutput::currentMode 을참조하세요 .
position : QPoint
이 프로퍼티는 컴포저의 좌표계에서 이 QWaylandOutput 의 위치를 유지합니다.
함수에 액세스합니다:
QPoint | position() const |
void | setPosition(const QPoint &pt) |
알림 신호:
void | positionChanged() |
scaleFactor : int
이 속성은 표면 버퍼가 표시되기 전에 QWaylandCompositor 의 크기를 조정하는 계수를 보유합니다. 이는 스케일링되지 않은 콘텐츠가 너무 작아 실용적이지 않은 고밀도 출력 장치에서 사용됩니다. 클라이언트는 출력 장치에 적합한 고해상도 콘텐츠를 제공하려는 경우 버퍼의 배율을 출력에 맞게 설정할 수 있습니다.
기본값은 1(스케일링 없음)입니다.
기능에 액세스합니다:
int | scaleFactor() const |
void | setScaleFactor(int scale) |
알림 신호:
void | scaleFactorChanged() |
sizeFollowsWindow : bool
이 속성은 QWaylandOutput 의 크기가 해당 창의 크기와 일치하는지 여부를 제어합니다.
이 속성이 true이면 이전에 추가된 모든 모드가 창 크기 및 화면 새로 고침 빈도와 일치하는 모드로 바뀝니다.
기본값은 거짓입니다.
기능 액세스:
bool | sizeFollowsWindow() const |
void | setSizeFollowsWindow(bool follow) |
알림 신호:
void | sizeFollowsWindowChanged() |
subpixel : QWaylandOutput::Subpixel
이 프로퍼티는 이 QWaylandOutput 의 서브픽셀 배열을 보유합니다. 기본값은 QWaylandOutput::SubpixelUnknown 입니다.
액세스 함수:
QWaylandOutput::Subpixel | subpixel() const |
void | setSubpixel(const QWaylandOutput::Subpixel &subpixel) |
알림 신호:
void | subpixelChanged() |
transform : QWaylandOutput::Transform
이 프로퍼티는 QWaylandOutput 의 방향을 보정하기 위해 QWaylandCompositor 이 서페이스에 적용하는 변환을 보유합니다.
기본값은 QWaylandOutput::TransformNormal 입니다.
함수에 액세스합니다:
QWaylandOutput::Transform | transform() const |
void | setTransform(const QWaylandOutput::Transform &transform) |
알림 신호:
void | transformChanged() |
window : QWindow*
이 속성은 QWaylandOutput 에 대한 QWindow 을 보유합니다.
액세스 함수:
QWindow * | window() const |
void | setWindow(QWindow *window) |
알림 신호:
void | windowChanged() |
멤버 함수 문서
QWaylandOutput::QWaylandOutput(QWaylandCompositor *compositor, QWindow *window)
compositor 에서 지정된 window 으로 QWaylandOutput을 구성합니다. compositor 에서 create() 함수를 호출한 후 QWaylandOutput을 구성해야 합니다.
나중에 이벤트에 대한 반응으로 QWaylandOutput 객체가 초기화됩니다. 이 시점에서 compositor 에 대한 출력으로 추가됩니다. 이 compositor 에 대해 생성된 첫 번째 QWaylandOutput 객체인 경우 default output 이 됩니다.
[override virtual noexcept]
QWaylandOutput::~QWaylandOutput()
QWaylandOutput 를 파괴합니다.
void QWaylandOutput::addMode(const QWaylandOutputMode &mode, bool preferred = false)
preferred 이 true
인 경우 출력에 mode 모드를 추가하고 기본 설정으로 표시합니다. 기본 설정 모드는 하나만 사용할 수 있다는 점에 유의하세요.
QWaylandCompositor *QWaylandOutput::compositor() const
이 컴포짓을 반환합니다 QWaylandOutput.
참고: 프로퍼티 컴포지터용 겟터 함수입니다.
QWaylandOutputMode QWaylandOutput::currentMode() const
출력의 크기를 픽셀 단위로, 재생률을 mHz 단위로 반환합니다. 현재 모드가 설정되어 있지 않으면 유효하지 않은 모드를 반환합니다.
setCurrentMode(), QWaylandOutput::modes, QWaylandOutputMode 를참조하세요 .
void QWaylandOutput::frameStarted()
QWaylandOutput 에 프레임이 시작되었음을 알립니다.
[static]
QWaylandOutput *QWaylandOutput::fromResource(wl_resource *resource)
resource 에 해당하는 QWaylandOutput 을 반환합니다.
QList<QWaylandOutputMode> QWaylandOutput::modes() const
모드 목록을 반환합니다.
void QWaylandOutput::sendFrameCallbacks()
보류 중인 프레임 콜백을 보냅니다.
void QWaylandOutput::setCurrentMode(const QWaylandOutputMode &mode)
현재 모드를 설정합니다. mode 모드를 이전에 추가했어야 합니다.
currentMode(), QWaylandOutput::modes, QWaylandOutputMode도 참조하세요 .
[virtual]
void QWaylandOutput::update()
QWaylandOutput 의 window 로 전달되도록 QEvent::UpdateRequest 을 예약합니다.
QWindow::requestUpdate()도 참조하세요 .
© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.