• Skip to content
  • Skip to link menu
KDE 4.2 API Reference
  • KDE API Reference
  • kdelibs
  • Sitemap
  • Contact Us
 

KDEUI

KIconCache Class Reference

Icon cache for KDE. More...

#include <kiconcache.h>

Inheritance diagram for KIconCache:

Inheritance graph
[legend]

List of all members.


Public Member Functions

int defaultIconSize (KIconLoader::Group group) const
virtual bool find (const QString &key, QPixmap &pix)
bool find (const QString &key, QPixmap &pix, QString *path)
virtual void insert (const QString &key, const QPixmap &pix)
void insert (const QString &key, const QPixmap &pix, const QString &path)
 KIconCache ()
void setThemeInfo (const QList< KIconTheme * > &themes)
virtual ~KIconCache ()

Static Public Member Functions

static void deleteCache ()

Protected Member Functions

QSet< QString > existingIconThemeDirs (const QStringList &themeNames) const
virtual bool loadCustomData (QDataStream &stream)
virtual bool loadCustomIndexHeader (QDataStream &stream)
unsigned int mostRecentMTime (const QSet< QString > &dirNames) const
virtual bool writeCustomData (QDataStream &stream)
virtual void writeCustomIndexHeader (QDataStream &stream)

Detailed Description

Icon cache for KDE.

Note that this is the KDE-wide cache for storing icons and should only be used by KIconLoader. If you want to cache your own pixmaps you should look at KPixmapCache instead.

Definition at line 44 of file kiconcache.h.


Constructor & Destructor Documentation

KIconCache::KIconCache (  )  [explicit]

Constucts the icon cache object.

Definition at line 103 of file kiconcache.cpp.

KIconCache::~KIconCache (  )  [virtual]

Definition at line 111 of file kiconcache.cpp.


Member Function Documentation

int KIconCache::defaultIconSize ( KIconLoader::Group  group  )  const

The default size of current theme for a certain icon group.

Parameters:
group The icon group. See KIconLoader::Group.
Returns:
The default size in pixels for the given icon group.

Definition at line 228 of file kiconcache.cpp.

void KIconCache::deleteCache (  )  [static]

Deletes the icon cache.

Definition at line 116 of file kiconcache.cpp.

QSet< QString > KIconCache::existingIconThemeDirs ( const QStringList &  themeNames  )  const [protected]

Definition at line 189 of file kiconcache.cpp.

bool KIconCache::find ( const QString &  key,
QPixmap &  pix 
) [virtual]

Tries to load pixmap with the specified key from cache.

Returns:
true when pixmap was found and loaded from cache, false otherwise

Reimplemented from KPixmapCache.

Definition at line 289 of file kiconcache.cpp.

bool KIconCache::find ( const QString &  key,
QPixmap &  pix,
QString *  path 
)

Definition at line 269 of file kiconcache.cpp.

void KIconCache::insert ( const QString &  key,
const QPixmap &  pix 
) [virtual]

Insert specified pixmap into the cache.

If the cache already contains pixmap with the specified key then it is overwritten.

Reimplemented from KPixmapCache.

Definition at line 295 of file kiconcache.cpp.

void KIconCache::insert ( const QString &  key,
const QPixmap &  pix,
const QString &  path 
)

Definition at line 282 of file kiconcache.cpp.

bool KIconCache::loadCustomData ( QDataStream &  stream  )  [protected, virtual]

Can be used by subclasses to write custom data into the stream.

Reimplemented from KPixmapCache.

Definition at line 301 of file kiconcache.cpp.

bool KIconCache::loadCustomIndexHeader ( QDataStream &  stream  )  [protected, virtual]

Can be used by subclasses to write custom data into cache's header.

Reimplemented from KPixmapCache.

Definition at line 121 of file kiconcache.cpp.

unsigned int KIconCache::mostRecentMTime ( const QSet< QString > &  dirNames  )  const [protected]

Definition at line 215 of file kiconcache.cpp.

void KIconCache::setThemeInfo ( const QList< KIconTheme * > &  themes  ) 

Definition at line 238 of file kiconcache.cpp.

bool KIconCache::writeCustomData ( QDataStream &  stream  )  [protected, virtual]

Can be used by subclasses to load custom data from the stream.

Reimplemented from KPixmapCache.

Definition at line 312 of file kiconcache.cpp.

void KIconCache::writeCustomIndexHeader ( QDataStream &  stream  )  [protected, virtual]

Can be used by subclasses to load custom data from cache's header.

Reimplemented from KPixmapCache.

Definition at line 167 of file kiconcache.cpp.


The documentation for this class was generated from the following files:
  • kiconcache.h
  • kiconcache.cpp

KDEUI

Skip menu "KDEUI"
  • Main Page
  • Modules
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdelibs

Skip menu "kdelibs"
  • DNSSD
  • Interfaces
  •   KHexEdit
  •   KMediaPlayer
  •   KSpeech
  •   KTextEditor
  • Kate
  • kconf_update
  • KDE3Support
  •   KUnitTest
  • KDECore
  • KDED
  • KDEsu
  • KDEUI
  • KDocTools
  • KFile
  • KHTML
  • KImgIO
  • KInit
  • kio
  • KIOSlave
  • KJS
  •   KJS-API
  •   WTF
  • kjsembed
  • KNewStuff
  • KParts
  • Kross
  • KUtils
  • Nepomuk
  • Plasma
  • Solid
  • Sonnet
  • ThreadWeaver
Generated for kdelibs by doxygen 1.5.7
This website is maintained by Adriaan de Groot and Allen Winter.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. | Legal