Version: 8.3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
QtxWorkstackTabBar Class Reference

Workstack tab bar widget. More...

#include <QtxWorkstack.h>

Inheritance diagram for QtxWorkstackTabBar:
Inheritance graph

Signals

void dragActiveTab ()
 Emitted when dragging operation is started. More...
 
void contextMenuRequested (QPoint)
 Emitted when context popup menu is requested. More...
 

Public Member Functions

 QtxWorkstackTabBar (QWidget *=0)
 Constructor. More...
 
virtual ~QtxWorkstackTabBar ()
 Destructor. More...
 
bool isActive () const
 Check if the tab bar is active. More...
 
void setActive (const bool)
 Set tab bar active/inactive. More...
 
int tabId (const int) const
 Get tab page identifier. More...
 
int indexOf (const int) const
 Get tab page index by specified identifier. More...
 
void setTabId (const int, const int)
 Set tab page identifier. More...
 
void updateActiveState ()
 Update tab bar according to the 'active' state. More...
 

Protected Member Functions

virtual void changeEvent (QEvent *)
 Process widget change state events (style, palette, enable state changing, etc). More...
 
virtual void mouseMoveEvent (QMouseEvent *)
 Customize mouse move event handler. More...
 
virtual void mousePressEvent (QMouseEvent *)
 Customize mouse press event handler. More...
 
virtual void mouseReleaseEvent (QMouseEvent *)
 Customize mouse release event handler. More...
 
virtual void contextMenuEvent (QContextMenuEvent *)
 Customize context menu event handler. More...
 

Private Slots

void onCurrentChanged (int)
 Called when current tab page is changed. More...
 

Private Attributes

int myId
 current tab page index More...
 
bool myActive
 "active" status More...
 

Detailed Description

Constructor & Destructor Documentation

QtxWorkstackTabBar::QtxWorkstackTabBar ( QWidget parent = 0)
Parameters
parentparent widget

References onCurrentChanged().

QtxWorkstackTabBar::~QtxWorkstackTabBar ( )
virtual

Member Function Documentation

void QtxWorkstackTabBar::changeEvent ( QEvent )
protectedvirtual
Parameters
echange event (not used)

References updateActiveState().

void QtxWorkstackTabBar::contextMenuEvent ( QContextMenuEvent *  e)
protectedvirtual
Parameters
econtext menu event

References contextMenuRequested().

void QtxWorkstackTabBar::contextMenuRequested ( QPoint  p)
signal
Parameters
ppoint popup menu to be shown at
void QtxWorkstackTabBar::dragActiveTab ( )
signal
int QtxWorkstackTabBar::indexOf ( const int  id) const
Parameters
idtab page ID
Returns
tab page index or -1 if not found

References tabId().

bool QtxWorkstackTabBar::isActive ( ) const
Returns
true if tab bar is active

References myActive.

void QtxWorkstackTabBar::mouseMoveEvent ( QMouseEvent *  e)
protectedvirtual
Parameters
emouse event

References dragActiveTab(), indexOf(), and myId.

void QtxWorkstackTabBar::mousePressEvent ( QMouseEvent *  e)
protectedvirtual
Parameters
emouse event

References myId, and tabId().

void QtxWorkstackTabBar::mouseReleaseEvent ( QMouseEvent *  e)
protectedvirtual
Parameters
emouse event

References contextMenuRequested(), and myId.

void QtxWorkstackTabBar::onCurrentChanged ( int  )
privateslot
Parameters
idxtab page index (not used)

References updateActiveState().

void QtxWorkstackTabBar::setActive ( const bool  on)
Parameters
onnew active state

References myActive, and updateActiveState().

void QtxWorkstackTabBar::setTabId ( const int  index,
const int  id 
)
Parameters
indextab page index
idtab page ID
int QtxWorkstackTabBar::tabId ( const int  index) const
Parameters
indextab page index
Returns
tab page ID or -1 if index is out of range
void QtxWorkstackTabBar::updateActiveState ( )

References isActive().

Member Data Documentation

bool QtxWorkstackTabBar::myActive
private
int QtxWorkstackTabBar::myId
private

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