QWaylandPointer Class
QWaylandPointer 클래스는 포인터 장치를 나타냅니다. 더 보기...
Header: | #include <QWaylandPointer> |
CMake: | find_package(Qt6 REQUIRED COMPONENTS WaylandCompositor) target_link_libraries(mytarget PRIVATE Qt6::WaylandCompositor) |
qmake: | QT += waylandcompositor |
상속합니다: | QWaylandObject |
공용 함수
QWaylandPointer(QWaylandSeat *seat, QObject *parent = nullptr) | |
QWaylandCompositor * | compositor() const |
QPointF | currentLocalPosition() const |
QPointF | currentSpacePosition() const |
wl_resource * | focusResource() const |
bool | isButtonPressed() const |
QWaylandView * | mouseFocus() const |
QWaylandOutput * | output() const |
QWaylandSeat * | seat() const |
virtual void | sendMouseMoveEvent(QWaylandView *view, const QPointF &localPos, const QPointF &outputSpacePos) |
virtual uint | sendMousePressEvent(Qt::MouseButton button) |
virtual uint | sendMouseReleaseEvent(Qt::MouseButton button) |
virtual void | sendMouseWheelEvent(Qt::Orientation orientation, int delta) |
void | setOutput(QWaylandOutput *output) |
시그널
void | buttonPressedChanged() |
자세한 설명
이 클래스는 QWaylandSeat 에서 포인터 장치에 대한 액세스를 제공합니다. 이는 웨이랜드 인터페이스 wl_pointer에 해당합니다.
멤버 함수 문서
QWaylandPointer::QWaylandPointer(QWaylandSeat *seat, QObject *parent = nullptr)
주어진 seat 와 주어진 parent 에 대한 QWaylandPointer를 구축합니다.
QWaylandCompositor *QWaylandPointer::compositor() const
이 QWaylandPointer 에 대한 컴포지터를 반환합니다.
QPointF QWaylandPointer::currentLocalPosition() const
QWaylandPointer 의 현재 로컬 위치를 표면 좌표로 반환합니다.
QPointF QWaylandPointer::currentSpacePosition() const
QWaylandPointer 의 현재 출력 공간 위치를 반환합니다.
wl_resource *QWaylandPointer::focusResource() const
이 QWaylandPointer 에 대한 웨이랜드 리소스를 반환합니다.
이 API는 클라이언트당 포인터 리소스가 많을 수 있으므로 실제로는 의미가 없습니다. 호환성상의 이유로 여기에 있습니다.
bool QWaylandPointer::isButtonPressed() const
현재 누르고 있는 버튼이 있으면 참을 반환합니다. 그렇지 않으면 false를 반환합니다.
참고: isButtonPressed 프로퍼티에 대한 겟터 함수.
QWaylandView *QWaylandPointer::mouseFocus() const
현재 마우스 포커스가 유지되고 있는 뷰를 반환합니다.
QWaylandOutput *QWaylandPointer::output() const
이 QWaylandPointer 에 대한 출력을 반환합니다.
setOutput()도 참조하세요 .
QWaylandSeat *QWaylandPointer::seat() const
이 QWaylandPointer 에 대한 입력 장치를 반환합니다.
[virtual]
void QWaylandPointer::sendMouseMoveEvent(QWaylandView *view, const QPointF &localPos, const QPointF &outputSpacePos)
현재 마우스 포커스를 view 로 설정하고 표면 좌표의 로컬 위치 localPos 와 출력 공간 위치 outputSpacePos 로 마우스 이동 이벤트를 전송합니다 .
[virtual]
uint QWaylandPointer::sendMousePressEvent(Qt::MouseButton button)
button 에 대한 마우스 누르기 이벤트를 현재 마우스 포커스가 유지되고 있는 뷰로 보냅니다.
프레스 이벤트의 일련 번호를 반환합니다.
[virtual]
uint QWaylandPointer::sendMouseReleaseEvent(Qt::MouseButton button)
button 에 대한 마우스 릴리스 이벤트를 현재 마우스 포커스가 유지되고 있는 뷰로 보냅니다.
릴리스 이벤트의 일련 번호를 반환합니다.
[virtual]
void QWaylandPointer::sendMouseWheelEvent(Qt::Orientation orientation, int delta)
현재 마우스 포커스가 유지되고 있는 뷰에 지정된 orientation 및 delta 으로 마우스 휠 이벤트를 보냅니다.
void QWaylandPointer::setOutput(QWaylandOutput *output)
이 QWaylandPointer 에 대한 출력을 output 으로 설정합니다.
output()도 참조하세요 .
© 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.