kdecore Library API Documentation

KIcon Class Reference

One icon as found by KIconTheme. More...

#include <kicontheme.h>

List of all members.

Public Types

enum  Context {
  Any, Action, Application, Device,
  FileSystem, MimeType
}
enum  Type { Fixed, Scalable, Threshold }
enum  MatchType { MatchExact, MatchBest }
enum  Group
enum  StdSizes { SizeSmall = 16, SizeMedium = 32, SizeLarge = 48, SizeHuge = 64 }
enum  States { DefaultState, ActiveState, DisabledState, LastState }
enum  Overlays {
  LockOverlay = 0x100, ZipOverlay = 0x200, LinkOverlay = 0x400, HiddenOverlay = 0x800,
  ShareOverlay = 0x1000
}

Public Methods

bool isValid () const

Public Attributes

int size
Context context
Type type
int threshold
QString path


Detailed Description

One icon as found by KIconTheme.

Also serves as a namespace containing icon related constants.

See also:
KIconEffect , KIconTheme , KIconLoader

Definition at line 36 of file kicontheme.h.


Member Enumeration Documentation

enum KIcon::Context
 

Defines the context of the icon.

Enumeration values:
Any  Some icon with unknown purpose.
Action  An action icon (e.g. 'save', 'print').
Application  An icon that represents an application.
Device  An icon that represents a device.
FileSystem  An icon that represents a file system.
MimeType  An icon that represents a mime type (or file type).

Definition at line 49 of file kicontheme.h.

Referenced by KIconTheme::queryIcons(), KIconLoader::queryIcons(), KIconTheme::queryIconsByContext(), and KIconLoader::queryIconsByContext().

enum KIcon::Type
 

The type of the icon.

Enumeration values:
Fixed  Fixed-size icon.
Scalable  Scalable-size icon.
Threshold  A threshold icon.

Definition at line 61 of file kicontheme.h.

enum KIcon::MatchType
 

The type of a match.

Enumeration values:
MatchExact  Only try to find an exact match.
MatchBest  Take the best match if there is no exact match.

Definition at line 70 of file kicontheme.h.

Referenced by KIconTheme::iconPath().

enum KIcon::Group
 

The group an an icon.

Definition at line 81 of file kicontheme.h.

Referenced by KIconLoader::alphaBlending(), KIconLoader::currentSize(), KIconTheme::defaultSize(), KIconLoader::IconSize(), KIconLoader::loadAnimated(), KIconLoader::loadIcon(), KIconLoader::loadIconSet(), KIconLoader::loadMovie(), KIconLoader::moviePath(), and KIconTheme::querySizes().

enum KIcon::StdSizes
 

These are the standard sizes for icons.

Enumeration values:
SizeSmall  small icons for menu entries
SizeMedium  medium sized icons for the desktop
SizeLarge  large sized icons for the panel
SizeHuge  huge sized icons for iconviews

Definition at line 87 of file kicontheme.h.

enum KIcon::States
 

Defines the possible states of an icon.

Enumeration values:
DefaultState  The default state.
ActiveState  Icon is active.
DisabledState  Icon is disabled.
LastState  Last state (last constant).

Definition at line 101 of file kicontheme.h.

enum KIcon::Overlays
 

This defines an overlay, a semi-transparent image that is projected onto the icon.

They are used to show that the file represented by the icon is, for example, locked, zipped or hidden.

Enumeration values:
LockOverlay  a file is locked
ZipOverlay  a file is zipped
LinkOverlay  a fileis a link
HiddenOverlay  a file is hidden
ShareOverlay  a file is shared

Definition at line 112 of file kicontheme.h.


Member Function Documentation

bool KIcon::isValid   const [inline]
 

Return true if this icon is valid, false otherwise.

Definition at line 44 of file kicontheme.h.

References size.

Referenced by KIconLoader::iconPath(), KIconLoader::loadAnimated(), KIconLoader::loadIcon(), and KIconLoader::moviePath().


Member Data Documentation

int KIcon::size
 

The size in pixels of the icon.

Definition at line 124 of file kicontheme.h.

Referenced by KIconTheme::iconPath(), and isValid().

Context KIcon::context
 

The context of the icon.

Definition at line 129 of file kicontheme.h.

Referenced by KIconTheme::iconPath(), and KIconLoader::loadIcon().

Type KIcon::type
 

The type of the icon: Fixed, Scalable or Threshold.

Definition at line 134 of file kicontheme.h.

Referenced by KIconTheme::iconPath(), and KIconLoader::loadIcon().

int KIcon::threshold
 

The threshold in case type == Threshold.

Definition at line 139 of file kicontheme.h.

Referenced by KIconTheme::iconPath(), and KIconLoader::loadIcon().

QString KIcon::path
 

The full path of the icon.

Definition at line 144 of file kicontheme.h.

Referenced by KIconTheme::iconPath(), KIconLoader::iconPath(), KIconLoader::loadAnimated(), KIconLoader::loadIcon(), and KIconLoader::moviePath().


The documentation for this class was generated from the following file:
KDE Logo
This file is part of the documentation for kdecore Library Version 3.2.2.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Thu Apr 22 14:23:07 2004 by doxygen 1.2.18 written by Dimitri van Heesch, © 1997-2003