42 #ifndef QGRAPHICSWIDGET_H
43 #define QGRAPHICSWIDGET_H
60 class QGraphicsWidgetPrivate;
65 #if !defined(QT_NO_GRAPHICSVIEW) || (QT_EDITION & QT_MODULE_GRAPHICSVIEW) != QT_MODULE_GRAPHICSVIEW
67 class QGraphicsWidgetPrivate;
82 Q_PROPERTY(
Qt::WindowFlags windowFlags READ windowFlags WRITE setWindowFlags)
85 Q_PROPERTY(
bool autoFillBackground READ autoFillBackground WRITE setAutoFillBackground)
86 Q_PROPERTY(QGraphicsLayout* layout READ layout WRITE setLayout NOTIFY layoutChanged)
90 QGraphicsLayout *layout() const;
91 void setLayout(QGraphicsLayout *layout);
96 void unsetLayoutDirection();
98 QStyle *style() const;
99 void setStyle(QStyle *style);
102 void setFont(const QFont &font);
105 void setPalette(const
QPalette &palette);
107 bool autoFillBackground() const;
108 void setAutoFillBackground(
bool enabled);
118 void setContentsMargins(qreal
left, qreal top, qreal
right, qreal bottom);
121 void setWindowFrameMargins(qreal
left, qreal top, qreal
right, qreal bottom);
122 void getWindowFrameMargins(qreal *
left, qreal *top, qreal *
right, qreal *bottom)
const;
123 void unsetWindowFrameMargins();
124 QRectF windowFrameGeometry()
const;
125 QRectF windowFrameRect()
const;
128 Qt::WindowFlags windowFlags()
const;
130 void setWindowFlags(Qt::WindowFlags wFlags);
131 bool isActiveWindow()
const;
132 void setWindowTitle(
const QString &title);
141 #ifndef QT_NO_SHORTCUT
143 void releaseShortcut(
int id);
144 void setShortcutEnabled(
int id,
bool enabled =
true);
145 void setShortcutAutoRepeat(
int id,
bool enabled =
true);
150 void addAction(
QAction *action);
154 void removeAction(
QAction *action);
172 void dumpFocusChain();
176 #ifdef Q_NO_USING_KEYWORD
183 void geometryChanged();
184 void layoutChanged();
190 virtual void initStyleOption(QStyleOption *option)
const;
201 virtual bool windowFrameEvent(
QEvent *e);
207 virtual void changeEvent(
QEvent *event);
212 virtual bool focusNextPrevChild(
bool next);
217 virtual void moveEvent(QGraphicsSceneMoveEvent *event);
218 virtual void polishEvent();
221 virtual void resizeEvent(QGraphicsSceneResizeEvent *event);
228 virtual void grabMouseEvent(
QEvent *event);
229 virtual void ungrabMouseEvent(
QEvent *event);
230 virtual void grabKeyboardEvent(
QEvent *event);
231 virtual void ungrabKeyboardEvent(
QEvent *event);
240 friend class QGraphicsScenePrivate;
243 friend class QGraphicsItemPrivate;
244 friend class QGraphicsLayout;
virtual void focusInEvent(QFocusEvent *event)
GLuint GLuint GLsizei GLenum type
virtual QSizeF sizeHint(Qt::SizeHint which, const QSizeF &constraint=QSizeF()) const =0
virtual void hoverMoveEvent(QGraphicsSceneHoverEvent *event)
virtual QRectF boundingRect() const =0
virtual void hoverLeaveEvent(QGraphicsSceneHoverEvent *event)
virtual void updateGeometry()
#define Q_PRIVATE_SLOT(d, signature)
virtual void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget=0)=0
virtual QVariant itemChange(GraphicsItemChange change, const QVariant &value)
virtual void getContentsMargins(qreal *left, qreal *top, qreal *right, qreal *bottom) const
Q_CORE_EXPORT QTextStream & right(QTextStream &s)
virtual QPainterPath shape() const
const QObjectList & children() const
#define QT_BEGIN_NAMESPACE
virtual bool sceneEvent(QEvent *event)
GLsizei GLsizei GLenum GLenum const GLvoid * data
GLsizei const GLfloat * value
virtual bool event(QEvent *)
int int int int int int h
virtual void setGeometry(const QRectF &rect)
virtual void focusOutEvent(QFocusEvent *event)
GLXFBConfig int attribute
GLubyte GLubyte GLubyte GLubyte w
friend class QGraphicsWidget
Q_CORE_EXPORT QTextStream & left(QTextStream &s)