LeechCraft  %{LEECHCRAFT_VERSION}
Modular cross-platform feature rich live environment.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
IIconThemeManager Class Referenceabstract

#include "iiconthememanager.h"

Public Member Functions

virtual QIcon GetIcon (const QString &on, const QString &off=QString())=0
 Returns the current theme's icon for the given on and off states. More...
 
virtual void UpdateIconset (const QList< QAction * > &actions)=0
 Updates the icons of the given actions. More...
 
virtual void ManageWidget (QWidget *widget)=0
 Watches the given widget recursively and its child actions. More...
 
virtual void RegisterChangeHandler (const std::function< void()> &function)=0
 Registers the theme change handler. More...
 

Protected Member Functions

virtual ~IIconThemeManager ()
 

Detailed Description

Definition at line 39 of file iiconthememanager.h.

Constructor & Destructor Documentation

virtual IIconThemeManager::~IIconThemeManager ( )
inlineprotectedvirtual

Definition at line 42 of file iiconthememanager.h.

Member Function Documentation

virtual QIcon IIconThemeManager::GetIcon ( const QString &  on,
const QString &  off = QString() 
)
pure virtual

Returns the current theme's icon for the given on and off states.

Parameters
[in]onThe name of the icon in the "on" state.
[in]offThe name of the icon in the "off" state, if any.
Returns
The QIcon object created from image files which could be obtained via GetIconPath().
See also
GetIconPath
virtual void IIconThemeManager::ManageWidget ( QWidget *  widget)
pure virtual

Watches the given widget recursively and its child actions.

This function merely installs the event filter on the given widget to watch for new actions or action changes.

Parameters
[in]widgetThe widget to manage.
virtual void IIconThemeManager::RegisterChangeHandler ( const std::function< void()> &  function)
pure virtual

Registers the theme change handler.

The given function will be invoked after each icon theme change.

Parameters
[in]functionThe function to invoke after theme change.
virtual void IIconThemeManager::UpdateIconset ( const QList< QAction * > &  actions)
pure virtual

Updates the icons of the given actions.

This function sets or updates the icons of actions according to the current iconset. This function also registers the actions so that they are automatically updated when the iconset changes.

Parameters
[in]actionsThe list of actions to update.

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