eric4.E4Gui.E4TabWidget

Module implementing a TabWidget class substituting QTabWidget.

Classes

E4TabWidget Class implementing a TabWidget class substituting QTabWidget.

Functions

None


E4TabWidget

Class implementing a TabWidget class substituting QTabWidget.

It provides slots to show the previous and next tab and give them the input focus and it allows to have a context menu for the tabs.

Signals

customTabContextMenuRequested(const QPoint & point, int index)
emitted when a context menu for a tab is requested

Derived from

QTabWidget

Methods

__handleTabCustomContextMenuRequested Private slot to handle the context menu request for the tabbar.
moveTab Public method to move a tab to a new index.
nextTab Public slot used to show the next tab.
prevTab Public slot used to show the previous tab.
selectTab Public method to get the index of a tab given a position.
setTabContextMenuPolicy Public method to set the context menu policy of the tab.

E4TabWidget.__handleTabCustomContextMenuRequested

__handleTabCustomContextMenuRequested(point)

Private slot to handle the context menu request for the tabbar.

point
point the context menu was requested (QPoint)

E4TabWidget.moveTab

moveTab(curIndex, newIndex)

Public method to move a tab to a new index.

curIndex
index of tab to be moved (integer)
newIndex
index the tab should be moved to (integer)

E4TabWidget.nextTab

nextTab()

Public slot used to show the next tab.

E4TabWidget.prevTab

prevTab()

Public slot used to show the previous tab.

E4TabWidget.selectTab

selectTab(pos)

Public method to get the index of a tab given a position.

pos
position determining the tab index (QPoint)
Returns:
index of the tab (integer)

E4TabWidget.setTabContextMenuPolicy

setTabContextMenuPolicy(policy)

Public method to set the context menu policy of the tab.

policy
context menu policy to set (Qt.ContextMenuPolicy)
Up