WaylandSeat QML Type
키보드, 마우스 및 터치 입력에 대한 액세스를 제공합니다. 자세히...
Import Statement: | import QtWayland.Compositor |
In C++: | QWaylandSeat |
신호
- void cursorSurfaceRequest(QWaylandSurface surface, int hotspotX, int hotspotY)
- void keyboardFocusChanged(QWaylandSurface newFocus, QWaylandSurface oldFocus)
방법
- void sendKeyEvent(int qtKey, bool pressed)
- void sendTouchCancelEvent(WaylandClient client)
- void sendTouchFrameEvent(WaylandClient client)
- void sendTouchPointMoved(WaylandSurface surface, int id, point position)
- uint sendTouchPointPressed(WaylandSurface surface, int id, point position)
- void sendTouchPointReleased(WaylandSurface surface, int id, point position)
- void sendUnicodeKeyPressEvent(uint unicode)
(since 6.7)
- void sendUnicodeKeyReleaseEvent(uint unicode)
(since 6.7)
자세한 설명
WaylandSeat 유형은 다양한 유형의 사용자 입력에 대한 액세스를 제공하며 키보드 포커스와 마우스 포인터를 유지합니다. Wayland 프로토콜의 wl_seat 인터페이스에 해당합니다.
신호 문서
이 신호는 클라이언트가 특정 surface 을 마우스 커서로 요청했을 때 발생합니다. 예를 들어 사용자가 특정 표면 위로 마우스를 가져갔을 때 커서가 크기 조정 화살표로 변경되기를 원할 때 발생합니다.
hotspotX 및 hotspotY 모두 클릭이 발생해야 하는 포인터 서페이스의 왼쪽 상단에서 오프셋됩니다. 예를 들어, 요청된 커서 서페이스가 화살표인 경우 매개변수는 해당 서페이스에서 화살표의 끝이 있는 위치를 나타냅니다.
참고: 해당 핸들러는 onCursorSurfaceRequest
입니다.
void keyboardFocusChanged(QWaylandSurface newFocus, QWaylandSurface oldFocus) |
이 신호는 setKeyboardFocus()가 호출되거나 WaylandQuickItem 에 포커스가 있고 사용자가 키를 누르기 시작할 때 발생합니다.
newFocus 는 키보드 포커스를 받은 서페이스, nullptr
는 포커스가 없는 서페이스, oldFocus 는 키보드 포커스를 잃은 서페이스, nullptr
는 포커스가 있는 서페이스가 있는 경우 발생합니다.
참고: 해당 핸들러는 onKeyboardFocusChanged
입니다.
메서드 문서
키의 키 누르기( pressed 가 true
인 경우) 또는 놓기( pressed 가 false
인 경우) 이벤트를 키보드 장치에 qtKey 로 보냅니다.
void sendTouchCancelEvent(WaylandClient client) |
취소 이벤트를 client 의 터치 장치로 보냅니다.
void sendTouchFrameEvent(WaylandClient client) |
일련의 터치 업, 다운 및 모션 이벤트의 끝을 나타내는 프레임 이벤트를 client 의 터치 장치로 보냅니다.
void sendTouchPointMoved(WaylandSurface surface, int id, point position) |
surface 의 터치 포인트 id 에 대한 터치 이동 이벤트를 위치 position 로 전송합니다.
참고: 터치 이벤트 전송이 끝나면 터치 프레임 이벤트를 전송해야 합니다.
경고: 이 API는 터치 ID가 충돌할 수 있으므로 WaylandQuickItem::touchEventsEnabled 을 사용하여 터치 이벤트를 전달하는 것과 함께 사용해서는 안 됩니다.
터치 모션 이벤트의 시리얼을 반환합니다.
uint sendTouchPointPressed(WaylandSurface surface, int id, point position) |
surface 의 터치 포인트 id 에 대한 터치 눌림 이벤트를 위치 position 로 전송합니다.
참고: 터치 이벤트 전송이 끝나면 터치 프레임 이벤트를 전송해야 합니다.
경고: 이 API는 터치 ID가 충돌할 수 있으므로 WaylandQuickItem::touchEventsEnabled 을 사용하여 터치 이벤트를 전달하는 것과 함께 사용해서는 안 됩니다.
터치 다운 이벤트의 시리얼을 반환합니다.
void sendTouchPointReleased(WaylandSurface surface, int id, point position) |
surface 의 터치 포인트 id 에 대한 터치 해제 이벤트를 위치 position 로 전송합니다.
참고: 터치 이벤트 전송이 끝나면 터치 프레임 이벤트를 전송해야 합니다.
경고: 이 API는 터치 ID가 충돌할 수 있으므로 WaylandQuickItem::touchEventsEnabled 을 사용하여 터치 이벤트를 전달하는 것과 함께 사용해서는 안 됩니다.
터치 이벤트의 시리얼을 반환합니다.
|
텍스트 입력 프로토콜을 통해 UCS4 unicode 의 키 누르기 이벤트를 전송합니다.
참고: 클라이언트가 컴포저가 지원하는 텍스트 입력 프로토콜을 지원하지 않는 경우 이 함수는 제대로 작동하지 않습니다.
이 메서드는 Qt 6.7에 도입되었습니다.
|
텍스트 입력 프로토콜을 통해 UCS4 unicode 의 키 릴리스 이벤트를 전송합니다.
참고: 클라이언트가 컴포저가 지원하는 텍스트 입력 프로토콜을 지원하지 않는 경우 이 함수는 제대로 작동하지 않습니다.
이 메서드는 Qt 6.7에 도입되었습니다.
© 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.