![]() |
Songbook-Client
0.7
This application is a manager of customguitar songbooks
|
CTabWidget is a widget representing a tab in the mainwindow. More...
#include <tab-widget.hh>
Public Types | |
| enum | SelectionBehavior { SelectCurrent, SelectNew } |
Public Slots | |
| void | closeTab () |
| void | closeTab (int index) |
| void | prev () |
| void | next () |
| void | changeTabText (const QString &text) |
Public Member Functions | |
| CTabWidget (QWidget *parent=0) | |
| Constructor. | |
| virtual | ~CTabWidget () |
| Destructor. | |
| int | addTab (QWidget *widget) |
| int | addTab (QWidget *widget, const QString &label) |
| SelectionBehavior | selectionBehaviorOnAdd () const |
| void | setSelectionBehaviorOnAdd (SelectionBehavior behavior) |
Protected Member Functions | |
| void | updateTabBarVisibility () |
Properties | |
| SelectionBehavior | selectionBehaviorOnAdd |
CTabWidget is a widget representing a tab in the mainwindow.
Note that a tab-widget is a generic widget that is a plain container but from the application point of view, two kinds of tabs should be distinguished :
| int CTabWidget::addTab | ( | QWidget * | widget | ) |
Add a new tab with widget as his parent and returns the new tab position in the bar. The tab's label is the title of the parent widget's window.
| int CTabWidget::addTab | ( | QWidget * | widget, |
| const QString & | label | ||
| ) |
Add a new tab with a title label and widget as its parent.
|
slot |
Change the tab label.
| text | the new label |
|
slot |
Close the current tab.
|
slot |
Close the tab at a given index.
| index | a tab index |
|
slot |
The current tab becomes the previous tab on the left.
|
slot |
The current tab becomes the next tab on the right.
| SelectionBehavior CTabWidget::selectionBehaviorOnAdd | ( | ) | const |
Returns the selection behavior to apply when a new tab is added.
| void CTabWidget::setSelectionBehaviorOnAdd | ( | CTabWidget::SelectionBehavior | behavior | ) |
Sets the selection behavior to apply when a new tab is added. This defines if the focus should be set on the tab or kept on current tab.
|
protected |
Hide or display the tab bar. The tab bar is hidden when there is only the library tab to be displayed (no song-editor tabs).
1.8.1.1