QTabWidget Class Reference |
Constant | Value | Description |
---|---|---|
QTabWidget::North | 0 | The tabs are drawn above the pages. |
QTabWidget::South | 1 | The tabs are drawn below the pages. |
QTabWidget::West | 2 | The tabs are drawn to the left of the pages. |
QTabWidget::East | 3 | The tabs are drawn to the right of the pages. |
This enum type defines the shape of the tabs:
Constant | Value | Description |
---|---|---|
QTabWidget::Rounded | 0 | rounded look (normal) |
QTabWidget::Triangular | 1 | triangular look |
This property holds the number of tabs in the tab bar.
Access functions:
This property holds the index position of the current tab page.
Access functions:
This property holds the position of the tabs in this tab widget.
Possible values for this property are QTabWidget::North and QTabWidget::South.
Access functions:
See also TabPosition.
This property holds the shape of the tabs in this tab widget.
Possible values for this property are QTabWidget::Rounded (default) or QTabWidget::Triangular.
Access functions:
See also TabShape.
Constructs a tabbed widget with parent parent.
Destroys the tabbed widget.
Adds another tab and page to the tab view.
The new page is child; the tab's label is label.
If the tab's label contains an ampersand, the letter following the ampersand is used as a shortcut for the tab, e.g. if the label is "Bro&wse" then Alt+W becomes a shortcut which will move the focus to this tab.
See also insertTab().
This is an overloaded member function, provided for convenience. It behaves essentially like the above function.
Adds another tab and page to the tab view.
This function is the same as addTab(), but with an additional icon.
Returns the widget shown in the corner of the tab widget or 0.
See also setCornerWidget().
This signal is emitted whenever the current page index changes. The parameter is the new current page index position.
See also currentWidget() and currentIndex.
Returns a pointer to the page currently being displayed by the tab dialog. The tab dialog does its best to make sure that this value is never 0 (but if you try hard enough, it can be).
See also currentIndex() and setCurrentWidget().
Returns the index position of the page occupied by the widget w, or -1 if the widget cannot be found.
Inserts another tab and page to the tab view.
The new page is w; the tab's label is label. Note the difference between the widget name (which you supply to widget constructors and to setTabEnabled(), for example) and the tab label. The name is internal to the program and invariant, whereas the label is shown on-screen and may vary according to language and other factors.
If the tab's label contains an ampersand, the letter following the ampersand is used as a shortcut for the tab, e.g. if the label is "Bro&wse" then Alt+W becomes a shortcut which will move the focus to this tab.
If index is out of range, the tab is simply appended. Otherwise it is inserted at the specified position.
If you call insertTab() after show(), the screen will flicker and the user may be confused.
See also addTab().
This is an overloaded member function, provided for convenience. It behaves essentially like the above function.
Inserts another tab and page to the tab view.
This function is the same as insertTab(), but with an additional icon.
Returns true if the the page at position index is enabled; otherwise returns false.
See also setTabEnabled() and QWidget::isEnabled().
Paints the tab widget's tab bar in response to the paint event.
Reimplemented from QWidget.
Removes the page at position index from this stack of widgets. Does not delete the page widget.
Sets widget w to be the shown in the specified corner of the tab widget.
Only the horizontal element of the corner will be used.
See also cornerWidget() and setTabPosition().
Makeswidget the current widget. The widget must be a page in this tab widget.
See also addTab(), setCurrentIndex(), and currentWidget().
Replaces the dialog's QTabBar heading with the tab bar tb. Note that this must be called before any tabs have been added, or the behavior is undefined.
See also tabBar().
If enable is true, the page at position index is enabled; otherwise the page at position index is disabled. The page's tab is redrawn appropriately.
QTabWidget uses QWidget::setEnabled() internally, rather than keeping a separate flag.
Note that even a disabled tab/page may be visible. If the page is visible already, QTabWidget will not hide it; if all the pages are disabled, QTabWidget will show one of them.
See also isTabEnabled() and QWidget::setEnabled().
Sets the icon for the tab at position index.
See also tabIcon().
Defines a new label for the page at position index's tab.
See also tabText().
Sets the tab tool tip for the page at position index to tip.
See also tabToolTip().
Returns the current QTabBar.
See also setTabBar().
Returns the label text for the tab on the page at position index.
See also setTabIcon().
This virtual handler is called after a new tab was added or inserted at position index.
See also tabRemoved().
This virtual handler is called after a tab was removed from position index.
See also tabInserted().
Returns the label text for the tab on the page at position index.
See also setTabText().
Returns the tab tool tip for the page at position index or an empty string if no tool tip has been set.
See also setTabToolTip().
Returns the tab page at index position index or 0 if the index is out of range.
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.0 | |
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