PointerDevice QML Type
QPointingDevice 에 해당하는 QML . 더 보기...
Import Statement: | import QtQuick |
In C++: | QPointingDevice |
속성
- buttonCount : int
- deviceType : enumeration
- maximumPoints : int
- pointerType : enumeration
- uniqueId : pointingDeviceUniqueId
신호
- grabChanged(QtObject grabber, enumeration transition, PointerEvent event, eventPoint point)
상세 설명
PointerDevice는 QPointingDevice 클래스의 QML 이름입니다. QPointingDevice 와 동일한 프로퍼티와 열거형을 가지고 있습니다.
속성 문서
buttonCount : int |
이 속성은 감지할 수 있는 온디바이스 버튼의 최대 개수를 알려줍니다.
deviceType : enumeration |
이 속성은 PointerEvent 을 생성한 디바이스 유형을 알려줍니다.
유효한 값은 다음과 같습니다:
Constant | 설명 |
---|---|
PointerDevice.Unknown | 장치를 식별할 수 없습니다. |
PointerDevice.Mouse | 마우스. |
PointerDevice.TouchScreen | 터치스크린. |
PointerDevice.TouchPad | 터치패드 또는 트랙패드. |
PointerDevice.Stylus | 그래픽 태블릿의 스타일러스. |
PointerDevice.Airbrush | 그래픽 태블릿의 에어브러시. |
PointerDevice.Puck | 그래픽 태블릿의 십자선이 있는 디지타이저. |
QInputDevice::DeviceType 및 PointerDeviceHandler::acceptedDevices 을참조하세요 .
maximumPoints : int |
이 속성은 감지할 수 있는 최대 동시 터치 포인트(손가락) 수를 알려줍니다.
pointerType : enumeration |
이 속성은 PointerDevice 와 상호 작용하는 대상을 알려줍니다.
이 속성과 deviceType 사이에는 약간의 중복성이 있습니다. 예를 들어 터치스크린을 사용하는 경우 deviceType
는 TouchScreen
이고 pointerType
는 Finger
입니다. 그러나 그래픽 태블릿에서는 스타일러스의 양쪽 끝을 모두 사용할 수 있는 경우가 많으므로 프로그램에서 이를 구분해야 합니다. PointerDeviceHandler::acceptedDevices 와 PointerDeviceHandler::acceptedPointerTypes 을 함께 사용하여 특정 처리기가 반응해야 하는 이벤트의 하위 집합을 필터링할 수 있습니다.
유효한 값은 다음과 같습니다:
상수 | 설명 |
---|---|
PointerDevice.Unknown | 장치를 식별할 수 없습니다. |
PointerDevice.Generic | 마우스 또는 마우스를 에뮬레이트하는 장치입니다. |
PointerDevice.Finger | 터치스크린의 손가락. |
PointerDevice.Pen | 그래픽 태블릿의 스타일러스. |
PointerDevice.Eraser | 그래픽 태블릿의 지우개. |
PointerDevice.Cursor | 그래픽 태블릿의 십자선이 있는 디지타이저. |
QPointingDevice::PointerType 및 PointerDeviceHandler::acceptedPointerTypes 을참조하세요 .
uniqueId : pointingDeviceUniqueId |
이 속성은 사용 가능한 경우 장치에 대한 고유 ID를 제공할 수 있습니다. 예를 들어 그래픽 태블릿 스타일러스 장치에는 고유 일련 번호가 있을 수 있습니다.
eventPoint 및 QEventPoint::uniqueId()도 참조하세요 .
신호 문서
grabChanged(QtObject grabber, enumeration transition, PointerEvent event, eventPoint point) |
이 신호는 event 를 전달하는 동안 grabber 객체가 point 의 독점 또는 패시브 그랩을 얻거나 잃을 때 발생합니다. transition 는 Item 또는 입력 핸들러일 수 있는 grabber
객체의 관점에서 어떤 일이 발생했는지 알려줍니다.
유효한 transition 값은 다음과 같습니다:
Constant | 설명 |
---|---|
PointerDevice.GrabExclusive | grabber 은 point 을 처리하는 일차적인 책임을 맡았습니다. |
PointerDevice.UngrabExclusive | grabber 이 이전의 독점적인 그래브를 포기했습니다. |
PointerDevice.CancelGrabExclusive | grabber 의 독점 그랩이 인수되었거나 취소되었습니다. |
PointerDevice.GrabPassive | grabber 이 point 을 모니터링하기 위해 패시브 그랩을 획득했습니다. |
PointerDevice.UngrabPassive | grabber 이 이전 패시브 그랩을 포기했습니다. |
PointerDevice.CancelGrabPassive | 이전 패시브 그랩이 비정상적으로 종료되었습니다. |
참고: 한 개체에서 다른 개체로 그랩이 전환되면 한 개체가 그랩을 잃었음을 알리는 신호와 다른 그래버가 있음을 알리는 신호가 두 번 발생합니다. 다른 경우에는 그래브가 없는 상태로 전환하거나 전환할 때 하나의 신호만 방출됩니다.
참고: 해당 핸들러는 onGrabChanged
입니다.
QPointerEvent::setExclusiveGrabber(), QPointerEvent::addPassiveGrabber(), QPointerEvent::removePassiveGrabber() 및 PointerHandler::grabChanged()도 참조하세요 .
© 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.