• PySide 模块
  • PySide.QtGui
  • 内容表

    上一话题

    QGraphicsSceneDragDropEvent

    下一话题

    QGraphicsSceneHoverEvent

    QGraphicsSceneHelpEvent

    概要

    函数

    详细描述

    PySide.QtGui.QGraphicsSceneHelpEvent class provides events when a tooltip is requested.

    PySide.QtGui.QGraphicsView 接收 PySide.QtCore.QEvent of type QEvent.ToolTip , it creates a PySide.QtGui.QGraphicsSceneHelpEvent , which is forwarded to the scene. You can set a tooltip on a PySide.QtGui.QGraphicsItem with PySide.QtGui.QGraphicsItem.setToolTip() ; by default PySide.QtGui.QGraphicsScene displays the tooltip of the PySide.QtGui.QGraphicsItem with the highest z-value (i.e, the top-most item) under the mouse position.

    PySide.QtGui.QGraphicsView does not forward events when "What's This" and status tip help is requested. If you need this, you can reimplement QGraphicsView.viewportEvent() and forward PySide.QtGui.QStatusTipEvent events and QEvents of type QEvent.WhatsThis to the scene.

    class PySide.QtGui. QGraphicsSceneHelpEvent ( [ type=None ] )
    参数: type PySide.QtCore.QEvent.Type

    Constructs a graphics scene help event of the specified type .

    PySide.QtGui.QGraphicsSceneHelpEvent. scenePos ( )
    返回类型: PySide.QtCore.QPointF

    Returns the position of the mouse cursor in scene coordinates at the moment the help event was sent.

    PySide.QtGui.QGraphicsSceneHelpEvent. screenPos ( )
    返回类型: PySide.QtCore.QPoint

    Returns the position of the mouse cursor in screen coordinates at the moment the help event was sent.

    PySide.QtGui.QGraphicsSceneHelpEvent. setScenePos ( pos )
    参数: pos PySide.QtCore.QPointF

    Sets the position associated with the context menu to the given point in scene coordinates.

    PySide.QtGui.QGraphicsSceneHelpEvent. setScreenPos ( pos )
    参数: pos PySide.QtCore.QPoint

    Sets the position associated with the context menu to the given point in screen coordinates.