Q3Frame Class Reference
|
Q3Frame ( QWidget * parent, const char * name = 0, Qt::WindowFlags f = 0 ) | |
~Q3Frame () | |
QRect | contentsRect () const |
int | frameWidth () const |
int | margin () const |
void | setMargin ( int ) |
virtual void | drawContents ( QPainter * painter ) |
virtual void | drawFrame ( QPainter * p ) |
virtual void | frameChanged () |
virtual void | paintEvent ( QPaintEvent * event ) |
virtual void | resizeEvent ( QResizeEvent * event ) |
This property holds the frame's contents rectangle (including the margins).
Access functions:
QRect | contentsRect () const |
This property holds the width of the margin.
The margin is the distance between the innermost pixel of the frame and the outermost pixel of contentsRect(). It is included in frameWidth().
The margin is filled according to backgroundMode().
The default value is 0.
Access functions:
int | margin () const |
void | setMargin ( int ) |
See also lineWidth() and frameWidth().
Creates a new frame with the given parent, object name, and with widget flags f.
Destructs the frame.
Virtual function that draws the contents of the frame on the given painter.
The QPainter is already open when you get it, and you must leave it open. Painter transformations are switched off on entry. If you transform the painter, remember to take the frame into account and reset transformation before returning.
This function is reimplemented by subclasses that draw something inside the frame. It should only draw inside contentsRect(). The default function does nothing.
See also contentsRect() and QPainter::setClipRect().
Draws the frame using the painter p and the current frame attributes and color group. The rectangle inside the frame is not affected.
This function is virtual, but in general you do not need to reimplement it. If you do, note that the QPainter is already open and must remain open.
See also frameRect(), contentsRect(), drawContents(), frameStyle(), and setPalette().
Virtual function that is called when the frame style, line width or mid-line width changes.
This function can be reimplemented by subclasses that need to know when the frame attributes change.
Returns the width of the frame (including the margin).
Reimplemented from QWidget::paintEvent().
Paints the frame (or part of the frame) that's necessary, depending on the event.
Reimplemented from QWidget::resizeEvent().
This just calls frameChanged(); it does not make use of the event itself.
Cette page est une traduction d'une page de la documentation de Qt, écrite par Nokia Corporation and/or its subsidiary(-ies). Les éventuels problèmes résultant d'une mauvaise traduction ne sont pas imputables à Nokia. | Qt 4.6 | |
Copyright © 2012 Developpez LLC. Tous droits réservés Developpez LLC. Aucune reproduction, même partielle, ne peut être faite de ce site et de l'ensemble de son contenu : textes, documents et images sans l'autorisation expresse de Developpez LLC. Sinon, vous encourez selon la loi jusqu'à 3 ans de prison et jusqu'à 300 000 E de dommages et intérêts. Cette page est déposée à la SACD. | ||
Vous avez déniché une erreur ? Un bug ? Une redirection cassée ? Ou tout autre problème, quel qu'il soit ? Ou bien vous désirez participer à ce projet de traduction ? N'hésitez pas à nous contacter ou par MP ! |
Copyright © 2000-2012 - www.developpez.com