KMimeSourceFactory class Reference (kdecore Library)

| # kdecore Library API Documentation
Overview | Class Hierarchy | Classes | Classes (annotated) | Members | Source Files

# KMimeSourceFactory Class Reference

An extension to QMimeSourceFactory that uses KIconLoader to find images. More...

`#include <kmimesourcefactory.h>`

Inheritance diagram for KMimeSourceFactory:

[legend]
Collaboration diagram for KMimeSourceFactory:

[legend]
List of all members.

## Public Member Functions
| KMimeSourceFactory (KIconLoader *loader=KGlobal::iconLoader())
| Constructor.
virtual | ~KMimeSourceFactory ()
| Destructor.
virtual QString | makeAbsolute (const QString &abs_or_rel_name, const QString &context) const
| This function is maps an absolute or relative name for a resource to the absolute one.
## Protected Member Functions
virtual void | virtual_hook (int id, void *data)

## Detailed Description

An extension to QMimeSourceFactory that uses KIconLoader to find images.

Normally you don't have to instantiate this class at all, KApplication does that for you automagically and sets QMimeSourceFactory::setDefaultFactory.

Version:
  Id
    kmimesourcefactory.h,v 1.6 2002/03/03 21:20:26 lunakl Exp

Author:
  Peter Putzer <putzer@kde.org>

Definition at line 39 of file kmimesourcefactory.h.

## Constructor & Destructor Documentation

KMimeSourceFactory::KMimeSourceFactory | ( | KIconLoader * | loader = KGlobal::iconLoader() | ) |

  | Constructor. Parameters:
  loader | is the iconloader used to find images.
Definition at line 37 of file kmimesourcefactory.cpp.

KMimeSourceFactory::~KMimeSourceFactory | ( |  | ) | `[virtual]`

| Destructor. Definition at line 43 of file kmimesourcefactory.cpp.

## Member Function Documentation

QString KMimeSourceFactory::makeAbsolute | ( | const QString & | abs_or_rel_name,
|  | const QString & | context
| ) | const`[virtual]`

| This function is maps an absolute or relative name for a resource to the absolute one. To load an icon, prepend the `category` name before the `icon` name, in the style of |. Example:
     "<img src=\"user|ksysv_start\"/>", "<img src="|trash\">", ...

Parameters:

  abs_or_rel_name | is the absolute or relative pathname.
  context | is the path of the context object for the queried resource. Almost always empty.

Reimplemented from QMimeSourceFactory.

Definition at line 48 of file kmimesourcefactory.cpp.

References QString::find(), QString::isEmpty(), QString::left(), QString::length(), QMimeSourceFactory::makeAbsolute(), and QString::right().

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

- kmimesourcefactory.h
- kmimesourcefactory.cpp

This file is part of the documentation for kdelibs Version 3.1.5.
Documentation copyright © 1996-2002 the KDE developers.
Generated on Wed Jan 28 12:49:59 2004 by doxygen 1.3.4 written by Dimitri van Heesch, © 1997-2001