Public Member Functions | Private Attributes

XAP_Toolbar_Factory Class Reference

#include <xap_Toolbar_Layouts.h>

List of all members.

Public Member Functions

 XAP_Toolbar_Factory (XAP_App *pApp)
 ~XAP_Toolbar_Factory (void)
EV_Toolbar_LayoutCreateToolbarLayout (const char *szName)
EV_Toolbar_LayoutDuplicateToolbarLayout (const char *szName)
void restoreToolbarLayout (EV_Toolbar_Layout *pTB)
bool addIconBefore (const char *szName, XAP_Toolbar_Id newId, XAP_Toolbar_Id beforeId)
bool addIconAfter (const char *szName, XAP_Toolbar_Id newId, XAP_Toolbar_Id afterId)
bool addIconAtEnd (const char *szName, XAP_Toolbar_Id newId)
bool removeIcon (const char *szName, XAP_Toolbar_Id nukeId)
bool saveToolbarsInCurrentScheme (void)
bool restoreToolbarsFromCurrentScheme (void)
const UT_GenericVector
< UT_UTF8String * > & 
getToolbarNames (void)
UT_uint32 countToolbars (void) const
const gchar * prefKeyForToolbar (UT_uint32 t) const

Private Attributes

UT_GenericVector
< XAP_Toolbar_Factory_vec * > 
m_vecTT
XAP_Appm_pApp
UT_GenericVector< UT_UTF8String * > m_tbNames

Constructor & Destructor Documentation

XAP_Toolbar_Factory::XAP_Toolbar_Factory ( XAP_App pApp  ) 
XAP_Toolbar_Factory::~XAP_Toolbar_Factory ( void   ) 

Member Function Documentation

bool XAP_Toolbar_Factory::addIconAfter ( const char *  szName,
XAP_Toolbar_Id  newId,
XAP_Toolbar_Id  afterId 
)
bool XAP_Toolbar_Factory::addIconAtEnd ( const char *  szName,
XAP_Toolbar_Id  newId 
)
bool XAP_Toolbar_Factory::addIconBefore ( const char *  szName,
XAP_Toolbar_Id  newId,
XAP_Toolbar_Id  beforeId 
)
UT_uint32 XAP_Toolbar_Factory::countToolbars ( void   )  const

Returns the number of toolbars in the factory.

References UT_GenericVector< T >::getItemCount(), and m_vecTT.

Referenced by AP_Dialog_Options::_populateWindowData(), and AP_Dialog_Options::_storeWindowData().

EV_Toolbar_Layout * XAP_Toolbar_Factory::CreateToolbarLayout ( const char *  szName  ) 
EV_Toolbar_Layout * XAP_Toolbar_Factory::DuplicateToolbarLayout ( const char *  szName  ) 

References CreateToolbarLayout().

const UT_GenericVector< UT_UTF8String * > & XAP_Toolbar_Factory::getToolbarNames ( void   ) 
const gchar * XAP_Toolbar_Factory::prefKeyForToolbar ( UT_uint32  t  )  const
bool XAP_Toolbar_Factory::removeIcon ( const char *  szName,
XAP_Toolbar_Id  nukeId 
)
void XAP_Toolbar_Factory::restoreToolbarLayout ( EV_Toolbar_Layout pTB  ) 
bool XAP_Toolbar_Factory::restoreToolbarsFromCurrentScheme ( void   ) 

This method restores the toolbar layouts from the current preference scheme. There are 3 generic keys. The Number of entries ((Base Key for Nr entries)+(TB name)) The ith ID ((Base Key for id)+(TB name)+(i)) The ith Flag ((Base Key for flag)+(TB name)+(i))

References XAP_Toolbar_Factory_vec::add_lt(), UT_GenericVector< T >::addItem(), UT_String::c_str(), UT_GenericVector< T >::clear(), gchar, EV_Toolbar_ActionSet::getAction(), XAP_Prefs::getCurrentScheme(), XAP_App::getPrefs(), XAP_App::getToolbarActionSet(), XAP_PrefsScheme::getValue(), XAP_Toolbar_Factory_lt::m_flags, XAP_Toolbar_Factory_lt::m_id, XAP_Toolbar_Factory_tt::m_name, m_pApp, m_vecTT, UT_DEBUGMSG, UT_return_val_if_fail, and UT_VECTOR_PURGEALL.

bool XAP_Toolbar_Factory::saveToolbarsInCurrentScheme ( void   ) 

This method saves the current toolbar layouts in the current preference scheme. There are 3 generic keys. The Number of entries ((Base Key for Nr entries)+(TB name)) The ith ID ((Base Key for id)+(TB name)+(i)) The ith Flag ((Base Key for flag)+(TB name)+(i))

References UT_String::c_str(), gchar, XAP_Prefs::getCurrentScheme(), UT_GenericVector< T >::getItemCount(), XAP_Toolbar_Factory_vec::getNrEntries(), XAP_Toolbar_Factory_vec::getNth_lt(), UT_GenericVector< T >::getNthItem(), XAP_App::getPrefs(), XAP_Toolbar_Factory_vec::getToolbarName(), XAP_Toolbar_Factory_lt::m_flags, XAP_Toolbar_Factory_lt::m_id, m_pApp, m_vecTT, XAP_PrefsScheme::setValue(), and UT_DEBUGMSG.


Member Data Documentation


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