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

tdeio/tdeio

  • tdeio
  • tdeio
previewjob.h
1 // -*- c++ -*-
2 // vim: ts=4 sw=4 et
3 /* This file is part of the KDE libraries
4  Copyright (C) 2000 David Faure <faure@kde.org>
5  2000 Carsten Pfeiffer <pfeiffer@kde.org>
6  2001 Malte Starostik <malte.starostik@t-online.de>
7 
8  This library is free software; you can redistribute it and/or
9  modify it under the terms of the GNU Library General Public
10  License as published by the Free Software Foundation; either
11  version 2 of the License, or (at your option) any later version.
12 
13  This library is distributed in the hope that it will be useful,
14  but WITHOUT ANY WARRANTY; without even the implied warranty of
15  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16  Library General Public License for more details.
17 
18  You should have received a copy of the GNU Library General Public License
19  along with this library; see the file COPYING.LIB. If not, write to
20  the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
21  Boston, MA 02110-1301, USA.
22 */
23 
24 #ifndef __tdeio_previewjob_h__
25 #define __tdeio_previewjob_h__
26 
27 #include <tdefileitem.h>
28 #include <tdeio/job.h>
29 
30 class TQPixmap;
31 
32 namespace TDEIO {
37  class TDEIO_EXPORT PreviewJob : public TDEIO::Job
38  {
39  Q_OBJECT
40  public:
57  PreviewJob( const KFileItemList &items, int width, int height,
58  int iconSize, int iconAlpha, bool scale, bool save,
59  const TQStringList *enabledPlugins, bool deleteItems = false );
60  virtual ~PreviewJob();
61 
68  void removeItem( const KFileItem *item );
69 
76  void setIgnoreMaximumSize(bool ignoreSize = true);
77 
84  static TQStringList availablePlugins();
85 
91  static TQStringList supportedMimeTypes();
92 
96  virtual void kill( bool quietly = true );
97 
98  signals:
105  void gotPreview( const KFileItem *item, const TQPixmap &preview );
112  void failed( const KFileItem *item );
113 
114  protected:
115  void getOrCreateThumbnail();
116  bool statResultThumbnail();
117  void createThumbnail( TQString );
118 
119  protected slots:
120  virtual void slotResult( TDEIO::Job *job );
121 
122  private slots:
123  void startPreview();
124  void slotThumbData(TDEIO::Job *, const TQByteArray &);
125 
126  private:
127  void determineNextFile();
128  void emitPreview(const TQImage &thumb);
129  void emitFailed(const KFileItem *item = 0);
130 
131  protected:
132  virtual void virtual_hook( int id, void* data );
133  private:
134  struct PreviewJobPrivate *d;
135  };
136 
157  TDEIO_EXPORT PreviewJob *filePreview( const KFileItemList &items, int width, int height = 0, int iconSize = 0, int iconAlpha = 70, bool scale = true, bool save = true, const TQStringList *enabledPlugins = 0 );
158 
179  TDEIO_EXPORT PreviewJob *filePreview( const KURL::List &items, int width, int height = 0, int iconSize = 0, int iconAlpha = 70, bool scale = true, bool save = true, const TQStringList *enabledPlugins = 0 );
180 }
181 
182 #endif

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
  • tdeabc
  • tdecmshell
  • tdecore
  • tdefx
  • tdehtml
  • tdeinit
  • tdeio
  •   bookmarks
  •   httpfilter
  •   kpasswdserver
  •   kssl
  •   tdefile
  •   tdeio
  •   tdeioexec
  • tdeioslave
  •   http
  • tdemdi
  •   tdemdi
  • tdenewstuff
  • tdeparts
  • tdeprint
  • tderandr
  • tderesources
  • tdespell2
  • tdesu
  • tdeui
  • tdeunittest
  • tdeutils
  • tdewallet
Generated for tdeio/tdeio by doxygen 1.8.1.2
This website is maintained by Timothy Pearson.