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

    上一话题

    QGraphicsSceneHoverEvent

    下一话题

    QCloseEvent

    QGraphicsSceneContextMenuEvent

    概要

    函数

    详细描述

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

    Constructs a graphics scene context menu event of the specified type .

    PySide.QtGui.QGraphicsSceneContextMenuEvent. Reason

    This enum describes the reason why the context event was sent.

    常量 描述
    QGraphicsSceneContextMenuEvent.Mouse The mouse caused the event to be sent. On most platforms, this means the right mouse button was clicked.
    QGraphicsSceneContextMenuEvent.Keyboard The keyboard caused this event to be sent. On Windows and Mac OS X, this means the menu button was pressed.
    QGraphicsSceneContextMenuEvent.Other The event was sent by some other means (i.e. not by the mouse or keyboard).
    PySide.QtGui.QGraphicsSceneContextMenuEvent. modifiers ( )
    返回类型: PySide.QtCore.Qt.KeyboardModifiers

    Returns the keyboard modifiers in use when the context menu was requested.

    PySide.QtGui.QGraphicsSceneContextMenuEvent. pos ( )
    返回类型: PySide.QtCore.QPointF

    Returns the position of the mouse cursor in item coordinates at the moment the context menu was requested.

    PySide.QtGui.QGraphicsSceneContextMenuEvent. reason ( )
    返回类型: PySide.QtGui.QGraphicsSceneContextMenuEvent.Reason

    Returns the reason for the context menu event.

    另请参阅

    QGraphicsSceneContextMenuEvent.Reason

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

    Returns the position of the mouse cursor in scene coordinates at the moment the the context menu was requested.

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

    Returns the position of the mouse cursor in screen coordinates at the moment the the context menu was requested.

    PySide.QtGui.QGraphicsSceneContextMenuEvent. setModifiers ( modifiers )
    参数: modifiers PySide.QtCore.Qt.KeyboardModifiers
    PySide.QtGui.QGraphicsSceneContextMenuEvent. setPos ( pos )
    参数: pos PySide.QtCore.QPointF

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

    PySide.QtGui.QGraphicsSceneContextMenuEvent. setReason ( reason )
    参数: reason PySide.QtGui.QGraphicsSceneContextMenuEvent.Reason

    Sets the reason for the context menu event to reason .

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

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

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

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