Fabcoin Core  0.16.2
P2P Digital Currency
Public Slots | Public Member Functions | Private Member Functions | Private Attributes | List of all members
TabBarInfo Class Reference

The TabBarInfo class Class for informations about tabs. More...

#include <tabbarinfo.h>

Inheritance diagram for TabBarInfo:
[legend]
Collaboration diagram for TabBarInfo:
[legend]

Public Slots

void on_currentChanged (int index)
 on_currentChanged Slot for changing the tab bar index More...
 
void on_closeButtonClick ()
 on_closeButtonClick Slot for close button click More...
 

Public Member Functions

 TabBarInfo (QStackedWidget *parent)
 TabBarInfo Constructor. More...
 
bool addTab (int index, const QString &name)
 addTab Add new tab More...
 
void removeTab (int index)
 removeTab Removing tab More...
 
void setTabVisible (int index, bool visible)
 setTabVisible Set tab visible More...
 
void attach (QTabBar *tabBar, QIcon *iconCloseTab)
 attach Attack the tab bar More...
 
void detach ()
 detach Detach the tab bar More...
 
void setCurrent (int index)
 setCurrent Set current index More...
 
void clear ()
 clear Remove all tabs except the first one which is not closable More...
 

Private Member Functions

void update ()
 update Update the GUI More...
 

Private Attributes

int m_current
 
QMap< int, QString > m_mapName
 
QMap< int, bool > m_mapVisible
 
QMap< int, int > m_mapTabInfo
 
QStackedWidget * m_stack
 
QTabBar * m_tabBar
 
bool m_attached
 
QIcon * m_iconCloseTab
 

Detailed Description

The TabBarInfo class Class for informations about tabs.

Useful in case of custom tab widgets, like having tab control inside the title.

Definition at line 13 of file tabbarinfo.h.

Constructor & Destructor Documentation

TabBarInfo::TabBarInfo ( QStackedWidget *  parent)
explicit

TabBarInfo Constructor.

Parameters
parentParent stack

Definition at line 5 of file tabbarinfo.cpp.

Member Function Documentation

bool TabBarInfo::addTab ( int  index,
const QString &  name 
)

addTab Add new tab

Parameters
indexStack index
nameTab name
Returns
Success of the operation

Definition at line 14 of file tabbarinfo.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void TabBarInfo::attach ( QTabBar *  tabBar,
QIcon *  iconCloseTab 
)

attach Attack the tab bar

Parameters
tabBarTab bar control
iconCloseTabClose tab icon

Definition at line 68 of file tabbarinfo.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void TabBarInfo::clear ( )

clear Remove all tabs except the first one which is not closable

Definition at line 101 of file tabbarinfo.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void TabBarInfo::detach ( )

detach Detach the tab bar

Definition at line 80 of file tabbarinfo.cpp.

Here is the caller graph for this function:

void TabBarInfo::on_closeButtonClick ( )
slot

on_closeButtonClick Slot for close button click

Definition at line 134 of file tabbarinfo.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void TabBarInfo::on_currentChanged ( int  index)
slot

on_currentChanged Slot for changing the tab bar index

Parameters
indexTab bar index

Definition at line 121 of file tabbarinfo.cpp.

Here is the caller graph for this function:

void TabBarInfo::removeTab ( int  index)

removeTab Removing tab

Parameters
indexIndex of the tab

Definition at line 26 of file tabbarinfo.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void TabBarInfo::setCurrent ( int  index)

setCurrent Set current index

Parameters
indexStack index

Definition at line 95 of file tabbarinfo.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void TabBarInfo::setTabVisible ( int  index,
bool  visible 
)

setTabVisible Set tab visible

Parameters
indexStack index
visibletrue: visible, false: not visible

Definition at line 59 of file tabbarinfo.cpp.

Here is the call graph for this function:

void TabBarInfo::update ( )
private

update Update the GUI

Definition at line 157 of file tabbarinfo.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

Member Data Documentation

bool TabBarInfo::m_attached
private

Definition at line 92 of file tabbarinfo.h.

int TabBarInfo::m_current
private

Definition at line 86 of file tabbarinfo.h.

QIcon* TabBarInfo::m_iconCloseTab
private

Definition at line 93 of file tabbarinfo.h.

QMap<int, QString> TabBarInfo::m_mapName
private

Definition at line 87 of file tabbarinfo.h.

QMap<int, int> TabBarInfo::m_mapTabInfo
private

Definition at line 89 of file tabbarinfo.h.

QMap<int, bool> TabBarInfo::m_mapVisible
private

Definition at line 88 of file tabbarinfo.h.

QStackedWidget* TabBarInfo::m_stack
private

Definition at line 90 of file tabbarinfo.h.

QTabBar* TabBarInfo::m_tabBar
private

Definition at line 91 of file tabbarinfo.h.


The documentation for this class was generated from the following files: