Icon Themes¶
- xdg.IconTheme.getIconPath(iconname, size=None, theme=None, extensions=['png', 'svg', 'xpm'])[source]¶
Get the path to a specified icon.
- size :
Icon size in pixels. Defaults to
xdg.Config.icon_size
.- theme :
Icon theme name. Defaults to
xdg.Config.icon_theme
. If the icon isn’t found in the specified theme, it will be looked up in the basic ‘hicolor’ theme.- extensions :
List of preferred file extensions.
Example:
>>> getIconPath("inkscape", 32) '/usr/share/icons/hicolor/32x32/apps/inkscape.png'
- xdg.IconTheme.getIconData(path)[source]¶
Retrieve the data from the .icon file corresponding to the given file. If there is no .icon file, it returns None.
Example:
getIconData("/usr/share/icons/Tango/scalable/places/folder.svg")