PythonQt.QtGui.QTabBar · declarations 001
Back to PythonQt.QtGui.QTabBar
ButtonPosition
instance-attribute
ButtonPosition: type
int([x]) -> integer int(x, base=10) -> integer
Convert a number or string to an integer, or return 0 if no arguments are given. If x is a number, return x.int(). For floating point numbers, this truncates towards zero.
If x is not a number or if base is given, then x must be a string, bytes, or bytearray instance representing an integer literal in the given base. The literal can be preceded by '+' or '-' and be surrounded by whitespace. The base defaults to 10. Valid bases are 0 and 2-36. Base 0 means to interpret the base from the string as an integer literal.
int('0b100', base=0) 4
LeftSide
instance-attribute
LeftSide: Any
RightSide
instance-attribute
RightSide: Any
RoundedEast
instance-attribute
RoundedEast: Any
RoundedNorth
instance-attribute
RoundedNorth: Any
RoundedSouth
instance-attribute
RoundedSouth: Any
RoundedWest
instance-attribute
RoundedWest: Any
SelectLeftTab
instance-attribute
SelectLeftTab: Any
SelectPreviousTab
instance-attribute
SelectPreviousTab: Any
SelectRightTab
instance-attribute
SelectRightTab: Any
TriangularEast
instance-attribute
TriangularEast: Any
TriangularNorth
instance-attribute
TriangularNorth: Any
TriangularSouth
instance-attribute
TriangularSouth: Any
TriangularWest
instance-attribute
TriangularWest: Any
addTab
addTab(icon: Any, text: str) -> int
X.addTab(icon, text) -> int
Supplemental documentation: Qt 5 reference:
int QTabBar::addTab(const QString \&text)
Adds a new tab with text text. Returns the new tab's index.
int QTabBar::addTab(const QIcon \&icon, const QString \&text)
This is an overloaded function.
Adds a new tab with icon icon and text text. Returns the new tab's index.
Upstream PySide2 reference signatures (binding differences may apply):
addTab(self, icon: PySide2.QtGui.QIcon, text: str) -> int
addTab(self, text: str) -> int
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#addTab
autoHide
instance-attribute
autoHide: bool
Qt 5 reference:
autoHide : bool
If true, the tab bar is automatically hidden when it contains less than 2 tabs.
By default, this property is false.
This property was introduced in Qt 5.4.
Access functions:
| bool | autoHide() const |
|---|---|
| void | setAutoHide(bool hide) |
See also QWidget::visible.
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#autoHide
changeCurrentOnDrag
instance-attribute
changeCurrentOnDrag: bool
Qt 5 reference:
changeCurrentOnDrag : bool
If true, then the current tab is automatically changed when dragging over the tabbar.
Note: You should also set acceptDrops property to true to make this feature work.
By default, this property is false.
This property was introduced in Qt 5.4.
Access functions:
| bool | changeCurrentOnDrag() const |
|---|---|
| void | setChangeCurrentOnDrag(bool change) |
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#changeCurrentOnDrag
changeEvent
changeEvent(arg__1: Any) -> None
X.changeEvent(arg__1)
Supplemental documentation: Qt 5 reference:
[override virtual protected] void QTabBar::changeEvent(QEvent *event)
Reimplements: QWidget::changeEvent(QEvent *event).
Upstream PySide2 reference signatures (binding differences may apply):
changeEvent(self, arg__1: PySide2.QtCore.QEvent) -> None
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#changeEvent
count
instance-attribute
count: int
Qt 5 reference:
count : const int
This property holds the number of tabs in the tab bar
Access functions:
| int | count() const |
|---|---|
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#count
currentChanged
currentChanged(*args: Any, **kwargs: Any) -> Any
Native PythonQt.QtGui.QTabBar.currentChanged; argument details are not documented.
Supplemental documentation: Qt 5 reference:
[signal] void QTabBar::currentChanged(int index)
This signal is emitted when the tab bar's current tab changes. The new current has the given index, or -1 if there isn't a new one (for example, if there are no tab in the QTabBar)
Note: Notifier signal for property currentIndex.
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#currentChanged
currentIndex
instance-attribute
currentIndex: int
Qt 5 reference:
currentIndex : int
This property holds the index of the tab bar's visible tab
The current index is -1 if there is no current tab.
Access functions:
| int | currentIndex() const |
|---|---|
| void | setCurrentIndex(int index) |
Notifier signal:
| void | currentChanged(int index) |
|---|---|
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#currentIndex
customContextMenuRequested
customContextMenuRequested(*args: Any, **kwargs: Any) -> Any
Native PythonQt.QtGui.QTabBar.customContextMenuRequested; argument details are not documented.
destroyed
destroyed(*args: Any, **kwargs: Any) -> Any
Native PythonQt.QtGui.QTabBar.destroyed; argument details are not documented.
documentMode
instance-attribute
documentMode: bool
Qt 5 reference:
documentMode : bool
This property holds whether or not the tab bar is rendered in a mode suitable for the main window.
This property is used as a hint for styles to draw the tabs in a different way then they would normally look in a tab widget. On macOS this will look similar to the tabs in Safari or Sierra's Terminal.app.
This property was introduced in Qt 4.5.
Access functions:
| bool | documentMode() const |
|---|---|
| void | setDocumentMode(bool set) |
See also QTabWidget::documentMode.
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#documentMode
drawBase
instance-attribute
drawBase: bool
Qt 5 reference:
drawBase : bool
defines whether or not tab bar should draw its base.
If true then QTabBar draws a base in relation to the styles overlab. Otherwise only the tabs are drawn.
Access functions:
| bool | drawBase() const |
|---|---|
| void | setDrawBase(bool drawTheBase) |
See also QStyle::pixelMetric(), QStyle::PM_TabBarBaseOverlap, and QStyleOptionTabBarBase.
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#drawBase
elideMode
instance-attribute
elideMode: Any
Qt 5 reference:
elideMode : Qt::TextElideMode
how to elide text in the tab bar
This property controls how items are elided when there is not enough space to show them for a given tab bar size.
By default the value is style-dependent.
This property was introduced in Qt 4.2.
Access functions:
| Qt::TextElideMode | elideMode() const |
|---|---|
| void | setElideMode(Qt::TextElideMode mode) |
See also QTabWidget::elideMode, usesScrollButtons, and QStyle::SH_TabBar_ElideMode.
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#elideMode
event
event(arg__1: Any) -> bool
X.event(arg__1) -> bool
Supplemental documentation: Qt 5 reference:
[override virtual protected] bool QTabBar::event(QEvent *event)
Reimplements: QWidget::event(QEvent *event).
Upstream PySide2 reference signatures (binding differences may apply):
event(self, arg__1: PySide2.QtCore.QEvent) -> bool
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#event
expanding
instance-attribute
expanding: bool
Qt 5 reference:
expanding : bool
When expanding is true QTabBar will expand the tabs to use the empty space.
By default the value is true.
This property was introduced in Qt 4.5.
Access functions:
| bool | expanding() const |
|---|---|
| void | setExpanding(bool enabled) |
See also QTabWidget::documentMode.
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#expanding
hideEvent
hideEvent(arg__1: Any) -> None
X.hideEvent(arg__1)
Supplemental documentation: Qt 5 reference:
[override virtual protected] void QTabBar::hideEvent(QHideEvent *)
Reimplements: QWidget::hideEvent(QHideEvent *event).
Upstream PySide2 reference signatures (binding differences may apply):
hideEvent(self, arg__1: PySide2.QtGui.QHideEvent) -> None
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#hideEvent
iconSize
instance-attribute
iconSize: QSize
Qt 5 reference:
iconSize : QSize
This property holds the size for icons in the tab bar
The default value is style-dependent. iconSize is a maximum size; icons that are
smaller are not scaled up.
This property was introduced in Qt 4.1.
Access functions:
| QSize | iconSize() const |
|---|---|
| void | setIconSize(const QSize \&size) |
See also QTabWidget::iconSize.
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#iconSize
initStyleOption
initStyleOption(option: Any, tabIndex: int) -> None
X.initStyleOption(option, tabIndex)
Supplemental documentation: Qt 5 reference:
[protected] void QTabBar::initStyleOption(QStyleOptionTab *option, int tabIndex) const
Initialize option with the values from the tab at tabIndex. This method is useful for subclasses when they need a QStyleOptionTab, but don't want to fill in all the information themselves.
See also QStyleOption::initFrom() and QTabWidget::initStyleOption().
Upstream PySide2 reference signatures (binding differences may apply):
initStyleOption(self, option: PySide2.QtWidgets.QStyleOptionTab, tabIndex: int) -> None
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#initStyleOption
insertTab
insertTab(index: int, icon: Any, text: str) -> int
X.insertTab(index, icon, text) -> int
Supplemental documentation: Qt 5 reference:
int QTabBar::insertTab(int index, const QString \&text)
Inserts a new tab with text text at position index. If index is out of range, the new tab is appened. Returns the new tab's index.
int QTabBar::insertTab(int index, const QIcon \&icon, const QString \&text)
This is an overloaded function.
Inserts a new tab with icon icon and text text at position index. If index is out of range, the new tab is appended. Returns the new tab's index.
If the QTabBar was empty before this function is called, the inserted tab becomes the current tab.
Inserting a new tab at an index less than or equal to the current index will increment the current index, but keep the current tab.
Upstream PySide2 reference signatures (binding differences may apply):
insertTab(self, index: int, icon: PySide2.QtGui.QIcon, text: str) -> int
insertTab(self, index: int, text: str) -> int
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#insertTab
isMovable
isMovable() -> bool
X.isMovable() -> bool
Upstream PySide2 reference signatures (binding differences may apply):
isMovable(self) -> bool
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#isMovable
isTabEnabled
isTabEnabled(index: int) -> bool
X.isTabEnabled(index) -> bool
Supplemental documentation: Qt 5 reference:
bool QTabBar::isTabEnabled(int index) const
Returns true if the tab at position index is enabled; otherwise returns false.
Upstream PySide2 reference signatures (binding differences may apply):
isTabEnabled(self, index: int) -> bool
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#isTabEnabled
keyPressEvent
keyPressEvent(arg__1: Any) -> None
X.keyPressEvent(arg__1)
Supplemental documentation: Qt 5 reference:
[override virtual protected] void QTabBar::keyPressEvent(QKeyEvent *event)
Reimplements: QWidget::keyPressEvent(QKeyEvent *event).
Upstream PySide2 reference signatures (binding differences may apply):
keyPressEvent(self, arg__1: PySide2.QtGui.QKeyEvent) -> None
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#keyPressEvent
minimumSizeHint
instance-attribute
minimumSizeHint: QSize
Qt 5 reference:
[override virtual] QSize QTabBar::minimumSizeHint() const
Reimplements an access function for property: QWidget::minimumSizeHint.
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#minimumSizeHint
minimumTabSizeHint
minimumTabSizeHint(index: int) -> Any
X.minimumTabSizeHint(index) -> PythonQt.QtCore.QSize
Supplemental documentation: Qt 5 reference:
[virtual protected] QSize QTabBar::minimumTabSizeHint(int index) const
Returns the minimum tab size hint for the tab at position index.
This function was introduced in Qt 5.0.
Upstream PySide2 reference signatures (binding differences may apply):
minimumTabSizeHint(self, index: int) -> PySide2.QtCore.QSize
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#minimumTabSizeHint
mouseMoveEvent
mouseMoveEvent(arg__1: Any) -> None
X.mouseMoveEvent(arg__1)
Supplemental documentation: Qt 5 reference:
[override virtual protected] void QTabBar::mouseMoveEvent(QMouseEvent *event)
Reimplements: QWidget::mouseMoveEvent(QMouseEvent *event).
Upstream PySide2 reference signatures (binding differences may apply):
mouseMoveEvent(self, arg__1: PySide2.QtGui.QMouseEvent) -> None
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#mouseMoveEvent
mousePressEvent
mousePressEvent(arg__1: Any) -> None
X.mousePressEvent(arg__1)
Supplemental documentation: Qt 5 reference:
[override virtual protected] void QTabBar::mousePressEvent(QMouseEvent *event)
Reimplements: QWidget::mousePressEvent(QMouseEvent *event).
Upstream PySide2 reference signatures (binding differences may apply):
mousePressEvent(self, arg__1: PySide2.QtGui.QMouseEvent) -> None
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#mousePressEvent
mouseReleaseEvent
mouseReleaseEvent(arg__1: Any) -> None
X.mouseReleaseEvent(arg__1)
Supplemental documentation: Qt 5 reference:
[override virtual protected] void QTabBar::mouseReleaseEvent(QMouseEvent *event)
Reimplements: QWidget::mouseReleaseEvent(QMouseEvent *event).
Upstream PySide2 reference signatures (binding differences may apply):
mouseReleaseEvent(self, arg__1: PySide2.QtGui.QMouseEvent) -> None
Source: https://doc.qt.io/archives/qt-5.15/qtabbar.html#mouseReleaseEvent