KIconCache

KDE 4.5 PyKDE API Reference

- KDE's Python API

# KIconCache Class Reference

`from PyKDE4.kdeui import *`

Inherits: KPixmapCache

## 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 KImageCache or KSharedDataCache instead.

Internal:

## Methods
| __init__ (self)
int | defaultIconSize (self, KIconLoader.Group group)
QSet | existingIconThemeDirs (self, QStringList themeNames)
bool | find (self, QString key, QPixmap pix, QString path)
bool | find (self, QString key, QPixmap pix)
| insert (self, QString key, QPixmap pix, QString path)
| insert (self, QString key, QPixmap pix)
bool | loadCustomData (self, QDataStream stream)
bool | loadCustomIndexHeader (self, QDataStream stream)
long | mostRecentMTime (self, QSet dirNames)
| setThemeInfo (self, [KIconTheme] themes)
bool | writeCustomData (self, QDataStream stream)
| writeCustomIndexHeader (self, QDataStream stream)
## Static Methods
| deleteCache ()

## Method Documentation

__init__ | ( |  | self ) |

Constucts the icon cache object.

int defaultIconSize | ( | self, |
|  | KIconLoader.Group | group
| ) |  |  |

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.

QSet existingIconThemeDirs | ( | self, |
|  | QStringList | themeNames
| ) |  |  |

bool find | ( | self, |
|  | QString | key,
|  | QPixmap | pix,
|  | QString | path
| ) |  |  |

bool find | ( | self, |
|  | QString | key,
|  | QPixmap | pix
| ) |  |  |

insert | ( | self, |
|  | QString | key,
|  | QPixmap | pix,
|  | QString | path
| ) |  |  |

insert | ( | self, |
|  | QString | key,
|  | QPixmap | pix
| ) |  |  |

bool loadCustomData | ( | self, |
|  | QDataStream | stream
| ) |  |  |

bool loadCustomIndexHeader | ( | self, |
|  | QDataStream | stream
| ) |  |  |

long mostRecentMTime | ( | self, |
|  | QSet | dirNames
| ) |  |  |

setThemeInfo | ( | self, |
|  | [KIconTheme] | themes
| ) |  |  |

bool writeCustomData | ( | self, |
|  | QDataStream | stream
| ) |  |  |

writeCustomIndexHeader | ( | self, |
|  | QDataStream | stream
| ) |  |  |

## Static Method Documentation

deleteCache | ( |  | ) |

Deletes the icon cache.