• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • tdeio/tdeio
 

tdeio/tdeio

  • TDEIO
  • PreviewJob
Signals | Public Member Functions | Static Public Member Functions | Protected Slots | Protected Member Functions | List of all members
TDEIO::PreviewJob Class Reference

#include <previewjob.h>

Inheritance diagram for TDEIO::PreviewJob:
TDEIO::Job

Signals

void gotPreview (const KFileItem *item, const TQPixmap &preview)
 
void failed (const KFileItem *item)
 
- Signals inherited from TDEIO::Job
void result (TDEIO::Job *job)
 
void canceled (TDEIO::Job *job)
 
void infoMessage (TDEIO::Job *job, const TQString &msg)
 
void warning (TDEIO::Job *job, const TQString &msg)
 
void connected (TDEIO::Job *job)
 
void percent (TDEIO::Job *job, unsigned long percent)
 
void totalSize (TDEIO::Job *job, TDEIO::filesize_t size)
 
void processedSize (TDEIO::Job *job, TDEIO::filesize_t size)
 
void speed (TDEIO::Job *job, unsigned long speed)
 

Public Member Functions

 PreviewJob (const KFileItemList &items, int width, int height, int iconSize, int iconAlpha, bool scale, bool save, const TQStringList *enabledPlugins, bool deleteItems=false)
 
void removeItem (const KFileItem *item)
 
void setIgnoreMaximumSize (bool ignoreSize=true)
 
virtual void kill (bool quietly=true)
 
- Public Member Functions inherited from TDEIO::Job
int error () const
 
int progressId () const
 
const TQString & errorText () const
 
TQString errorString () const
 
TQStringList detailedErrorStrings (const KURL *reqUrl=0L, int method=-1) const
 
void showErrorDialog (TQWidget *parent=0L)
 
void setAutoErrorHandlingEnabled (bool enable, TQWidget *parentWidget=0)
 
bool isAutoErrorHandlingEnabled () const
 
void setAutoWarningHandlingEnabled (bool enable)
 
bool isAutoWarningHandlingEnabled () const
 
void setInteractive (bool enable)
 
bool isInteractive () const
 
void setWindow (TQWidget *window)
 
TQWidget * window () const
 
void updateUserTimestamp (unsigned long time)
 
void setParentJob (Job *parentJob)
 
Job * parentJob () const
 
void setMetaData (const TDEIO::MetaData &metaData)
 
void addMetaData (const TQString &key, const TQString &value)
 
void addMetaData (const TQMap< TQString, TQString > &values)
 
void mergeMetaData (const TQMap< TQString, TQString > &values)
 
MetaData outgoingMetaData () const
 
MetaData metaData () const
 
TQString queryMetaData (const TQString &key)
 
TDEIO::filesize_t getProcessedSize ()
 

Static Public Member Functions

static TQStringList availablePlugins ()
 
static TQStringList supportedMimeTypes ()
 

Protected Slots

virtual void slotResult (TDEIO::Job *job)
 
- Protected Slots inherited from TDEIO::Job
virtual void slotResult (TDEIO::Job *job)
 
void slotSpeed (TDEIO::Job *job, unsigned long speed)
 
void slotInfoMessage (TDEIO::Job *job, const TQString &msg)
 
void slotSpeedTimeout ()
 

Protected Member Functions

void getOrCreateThumbnail ()
 
bool statResultThumbnail ()
 
void createThumbnail (TQString)
 
virtual void virtual_hook (int id, void *data)
 
- Protected Member Functions inherited from TDEIO::Job
 Job (bool showProgressInfo)
 
virtual void addSubjob (Job *job, bool inheritMetaData=true)
 
virtual void removeSubjob (Job *job)
 
void removeSubjob (Job *job, bool mergeMetaData, bool emitResultIfLast)
 
void emitPercent (TDEIO::filesize_t processedSize, TDEIO::filesize_t totalSize)
 
void emitSpeed (unsigned long speed)
 
void emitResult ()
 
void setProcessedSize (TDEIO::filesize_t size)
 
unsigned long userTimestamp () const
 
int & extraFlags ()
 

Additional Inherited Members

- Protected Types inherited from TDEIO::Job
enum  { EF_TransferJobAsync = (1 << 0), EF_TransferJobNeedData = (1 << 1), EF_TransferJobDataSent = (1 << 2), EF_ListJobUnrestricted = (1 << 3) }
 
- Protected Attributes inherited from TDEIO::Job
TQPtrList< Job > subjobs
 
int m_error
 
TQString m_errorText
 
unsigned long m_percent
 
int m_progressId
 
TQTimer * m_speedTimer
 
TQGuardedPtr< TQWidget > m_window
 
MetaData m_outgoingMetaData
 
MetaData m_incomingMetaData
 

Detailed Description

TDEIO Job to get a thumbnail picture.

This class catches a preview (thumbnail) for files.

Definition at line 35 of file previewjob.h.

Constructor & Destructor Documentation

PreviewJob::PreviewJob ( const KFileItemList &  items,
int  width,
int  height,
int  iconSize,
int  iconAlpha,
bool  scale,
bool  save,
const TQStringList *  enabledPlugins,
bool  deleteItems = false 
)

Creates a new PreviewJob.

Parameters
itemsa list of files to create previews for
widththe desired width
heightthe desired height, 0 to use the width
iconSizethe size of the mimetype icon to overlay over the preview or zero to not overlay an icon. This has no effect if the preview plugin that will be used doesn't use icon overlays.
iconAlphatransparency to use for the icon overlay
scaleif the image is to be scaled to the requested size or returned in its original size
saveif the image should be cached for later use
enabledPluginsif non-zero, this points to a list containing the names of the plugins that may be used.
deleteItemstrue to delete the items when done

Definition at line 116 of file previewjob.cpp.

Member Function Documentation

TQStringList PreviewJob::availablePlugins ( )
static

Returns a list of all available preview plugins.

The list contains the basenames of the plugins' .desktop files (no path, no .desktop).

Returns
the list of plugins

Definition at line 549 of file previewjob.cpp.

void TDEIO::PreviewJob::failed ( const KFileItem *  item)
signal

Emitted when a thumbnail for item could not be created, either because a ThumbCreator for its MIME type does not exist, or because something went wrong.

Parameters
itemthe file that failed
void TDEIO::PreviewJob::gotPreview ( const KFileItem *  item,
const TQPixmap &  preview 
)
signal

Emitted when a thumbnail picture for item has been successfully retrieved.

Parameters
itemthe file of the preview
previewthe preview image
void PreviewJob::kill ( bool  quietly = true)
virtual

Reimplemented for internal reasons.

Reimplemented from TDEIO::Job.

Definition at line 568 of file previewjob.cpp.

void PreviewJob::removeItem ( const KFileItem *  item)

Removes an item from preview processing.

Use this if you passed an item to filePreview and want to delete it now.

Parameters
itemthe item that should be removed from the preview queue

Definition at line 261 of file previewjob.cpp.

void PreviewJob::setIgnoreMaximumSize ( bool  ignoreSize = true)

If ignoreSize is true, then the preview is always generated regardless of the settings.

Since
KDE 3.4

Definition at line 278 of file previewjob.cpp.

TQStringList PreviewJob::supportedMimeTypes ( )
static

Returns a list of all supported MIME types.

The list can contain entries like text/ * (without the space).

Returns
the list of mime types

Definition at line 559 of file previewjob.cpp.


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

tdeio/tdeio

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

tdeio/tdeio

Skip menu "tdeio/tdeio"
  • arts
  • dcop
  • dnssd
  • interfaces
  •   kspeech
  •     interface
  •     library
  •   tdetexteditor
  • kate
  • kded
  • kdoctools
  • kimgio
  • kjs
  • libtdemid
  • libtdescreensaver
  •     tdecore
  • tdeabc
  • tdecmshell
  • tdecore
  • tdefx
  • tdehtml
  • tdeinit
  • tdeio
  •   bookmarks
  •   httpfilter
  •   kpasswdserver
  •   kssl
  • tdeioslave
  •   http
  •   tdefile
  •   tdeio
  •   tdeioexec
  • tdemdi
  •   tdemdi
  • tdenewstuff
  • tdeparts
  • tdeprint
  • tderandr
  • tderesources
  • tdespell2
  • tdesu
  • tdeui
  • tdeunittest
  • tdeutils
  • tdewallet
Generated for tdeio/tdeio by doxygen 1.8.8
This website is maintained by Timothy Pearson.