QGraphicsSceneWheelEvent Class

QGraphicsSceneWheelEvent クラスは、グラフィックスビューフレームワークのホイールイベントを提供します。詳細...

ヘッダー #include <QGraphicsSceneWheelEvent>
CMake: find_package(Qt6 REQUIRED COMPONENTS Widgets)
target_link_libraries(mytarget PRIVATE Qt6::Widgets)
qmake: QT += widgets
継承: QGraphicsSceneEvent

パブリック関数

virtual ~QGraphicsSceneWheelEvent()
Qt::MouseButtons buttons() const
int delta() const
(since 6.2) bool isInverted() const
Qt::KeyboardModifiers modifiers() const
Qt::Orientation orientation() const
(since 6.2) Qt::ScrollPhase phase() const
(since 6.2) QPoint pixelDelta() const
QPointF pos() const
QPointF scenePos() const
QPoint screenPos() const

詳細説明

QWheelEvent QGraphicsView QWheelEvent::globalPos() をアイテム、シーン、スクリーン座標 (pos(),scenePos(),screenPos()) に変換します。

QGraphicsSceneMouseEventQGraphicsSceneContextMenuEventQGraphicsSceneHoverEventQWheelEventも参照

メンバ関数ドキュメント

[virtual noexcept] QGraphicsSceneWheelEvent::~QGraphicsSceneWheelEvent()

QGraphicsSceneWheelEvent を破壊する。

Qt::MouseButtons QGraphicsSceneWheelEvent::buttons() const

ホイールイベントが発生したときに押されたマウスボタンを返します。

modifiers()も参照してください

int QGraphicsSceneWheelEvent::delta() const

ホイールを回転させた距離を8分の1度単位で返します。正の値は、ホイールがユーザーから遠ざかる方向に回転したことを示し、負の値は、ホイールがユーザーに向かって逆方向に回転したことを示します。

ほとんどのマウスタイプは15度単位で動作し、その場合デルタ値は120の倍数(== 15 * 8)になります。

[since 6.2] bool QGraphicsSceneWheelEvent::isInverted() const

イベントと共に配信されたデルタ値が反転しているかどうかを返します。

この関数は Qt 6.2 で導入されました。

Qt::KeyboardModifiers QGraphicsSceneWheelEvent::modifiers() const

ホイールイベントが発生したときにアクティブだったキーボード修飾子を返す。

buttons()も参照してください

Qt::Orientation QGraphicsSceneWheelEvent::orientation() const

ホイールの向きを返します。

[since 6.2] Qt::ScrollPhase QGraphicsSceneWheelEvent::phase() const

このホイールイベントのスクロールフェーズを返します。

この関数は Qt 6.2 で導入されました。

QWheelEvent::phaseも参照してください

[since 6.2] QPoint QGraphicsSceneWheelEvent::pixelDelta() const

画面上のスクロール距離をピクセル単位で返します。この値は、macOS などの高解像度ピクセルベースの差分値をサポートするプラットフォームで提供されます。この値は、画面上のコンテンツをスクロールするために直接使用する必要があります。

この関数は Qt 6.2 で導入されました。

QWheelEvent::pixelDeltaも参照して ください。

QPointF QGraphicsSceneWheelEvent::pos() const

ホイールイベントが発生したときのカーソルの位置をアイテム座標で返す。

scenePos() およびscreenPos()も参照してください

QPointF QGraphicsSceneWheelEvent::scenePos() const

ホイールイベントが発生したときのカーソルの位置をシーン座標で返す。

pos() およびscreenPos()も参照してください

QPoint QGraphicsSceneWheelEvent::screenPos() const

ホイールイベントが発生したときのカーソルの位置をスクリーン座標で返す。

pos() およびscenePos()も参照

© 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.