Qt 3 Support Members for QWidgetThe following class members are part of the Qt 3 support layer. They are provided to help you port old code to Qt 4. We advise against using them in new code. Public Types
Public Functions
Public Slots
Static Public Members
Member Type Documentation
|
Constant | Value |
---|---|
QWidget::WidgetOrigin | 0 |
QWidget::ParentOrigin | 1 |
QWidget::WindowOrigin | 2 |
QWidget::AncestorOrigin | 3 |
This is an overloaded function.
Returns the color role used for painting the widget's background.
Use QPalette(backgroundRole(()) instead.
See also setBackgroundMode().
Always returns QPoint().
Always returns WindowOrigin.
See also setBackgroundOrigin().
Use windowTitle() instead.
See also setCaption().
Use the childAt() overload that doesn't have an includeThis parameter.
For example, if you have code like
return widget->childAt(x, y, true);
you can rewrite it as
QWidget *child = widget->childAt(x, y, true); if (child) return child; if (widget->rect().contains(x, y)) return widget;
Use the single point argument overload instead.
Closes the widget.
Use the no-argument overload instead.
Use QColorGroup(palette()) instead.
Use ensurePolished() instead.
Drawing may only take place in a QPaintEvent. Overload paintEvent() to do your drawing and call update() to schedule a replaint whenever necessary. See also QPainter.
Drawing may only take place in a QPaintEvent. Overload paintEvent() to do your drawing and call update() to schedule a replaint whenever necessary. See also QPainter.
Drawing may only take place in a QPaintEvent. Overload paintEvent() to do your erasing and call update() to schedule a replaint whenever necessary. See also QPainter.
Drawing may only take place in a QPaintEvent. Overload paintEvent() to do your erasing and call update() to schedule a replaint whenever necessary. See also QPainter.
Drawing may only take place in a QPaintEvent. Overload paintEvent() to do your erasing and call update() to schedule a replaint whenever necessary. See also QPainter.
This is an overloaded function.
Clear the given region, rgn.
Drawing may only take place in a QPaintEvent. Overload paintEvent() to do your erasing and call update() to schedule a replaint whenever necessary. See also QPainter.
Use testAttribute(Qt::WA_UnderMouse) instead.
Return's the widget's icon.
Use windowIcon() instead.
See also setIcon().
Use windowIconText() instead.
See also setIconText().
Use showMinimized() instead.
Use windowType() == Qt::Desktop instead.
Use windowType() == Qt::Dialog instead.
Use testAttribute(Qt::WA_InputMethodEnabled) instead.
Use windowType() == Qt::Popup instead.
Use !isHidden() instead (notice the exclamation mark), or use isVisible() to check whether the widget is visible.
Use the updatesEnabled property instead.
Use isVisible() instead.
Use testAttribute(Qt::WA_SetCursor) instead.
Use testAttribute(Qt::WA_SetFont) instead.
Use testAttribute(Qt::WA_SetPalette) instead.
Use the no-argument overload instead.
Use ensurePolished() instead.
Use setParent() to change the parent or the widget's widget flags; use move() to move the widget, and use show() to show the widget.
The boolean parameter b is ignored. Use the no-argument overload instead.
The boolean parameter b is ignored. Use the four-argument overload instead.
The boolean parameter b is ignored. Use the single rect-argument overload instead.
The boolean parameter b is ignored. Use the single region-argument overload instead.
Use setParent() to change the parent or the widget's widget flags; use move() to move the widget, and use show() to show the widget.
Use setParent() to change the parent; use move() to move the widget, and use show() to show the widget.
Use activateWindow() instead.
See also isActiveWindow().
Use the palette instead.
For example, if you have code like
widget->setBackgroundColor(color);
you can rewrite it as
QPalette palette; palette.setColor(widget->backgroundRole(), color); widget->setPalette(palette);
Sets the color role used for painting the widget's background to background mode widgetBackground. The paletteBackground mode parameter is ignored.
See also backgroundMode().
See also backgroundOrigin().
Use the palette instead.
For example, if you have code like
widget->setBackgroundPixmap(pixmap);
you can rewrite it as
QPalette palette; palette.setBrush(widget->backgroundRole(), QBrush(pixmap)); widget->setPalette(palette);
Use setWindowTitle() instead.
See also caption().
Use the palette instead.
For example, if you have code like
widget->setEraseColor(color);
you can rewrite it as
QPalette palette; palette.setColor(widget->backgroundRole(), color); widget->setPalette(palette);
Use the palette instead.
For example, if you have code like
widget->setErasePixmap(pixmap);
you can rewrite it as
QPalette palette; palette.setBrush(widget->backgroundRole(), QBrush(pixmap)); widget->setPalette(palette);
Use the single-argument overload instead.
Use setWindowIcon() instead.
See also icon().
Use setWindowIconText() instead.
See also iconText().
Use setAttribute(Qt::WA_InputMethodEnabled, enabled) instead.
See also isInputMethodEnabled().
Use setAttribute(Qt::WA_KeyCompression, b) instead.
Use the single-argument overload instead.
Use the palette directly.
For example, if you have code like
widget->setPaletteBackgroundColor(color);
you can rewrite it as
QPalette palette; palette.setColor(widget->backgroundRole(), color); widget->setPalette(palette);
Use the palette directly.
For example, if you have code like
widget->setPaletteBackgroundPixmap(pixmap);
you can rewrite it as
QPalette palette; palette.setBrush(widget->backgroundRole(), QBrush(pixmap)); widget->setPalette(palette);
Use the palette directly.
For example, if you have code like
widget->setPaletteForegroundColor(color);
you can rewrite it as
QPalette palette; palette.setColor(widget->foregroundRole(), color); widget->setPalette(palette);
Use setVisible(shown) instead.
See also isShown().
Use the sizePolicy property and heightForWidth() function instead.
This is an overloaded function.
Sets the widget's GUI style to style using the QStyleFactory.
Use setFont(QFont()) instead.
Use setPalette(QPalette()) instead.
Use visibleRegion() instead.
The widget mapper is no longer part of the public API.
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.8 | |
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