summaryrefslogtreecommitdiffstats
path: root/kipi-plugins/printwizard/tphoto.h
blob: 84888b2eda312fa2808b41f5489b25d9f6ec80c2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
/***************************************************************************
                          tphoto.h  -  description
                             -------------------
    begin                : Thu Sep 12 2002
    copyright            : (C) 2002 by Todd Shoemaker
                         : (C) 2007 Angelo Naselli
    email                : jtshoe11@yahoo.com
***************************************************************************/

/***************************************************************************
 *                                                                         *
 *   This program is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU General Public License as published by  *
 *   the Free Software Foundation; either version 2 of the License, or     *
 *   (at your option) any later version.                                   *
 *                                                                         *
 ***************************************************************************/

#ifndef TPHOTO_H
#define TPHOTO_H

// TQt includes.

#include <tqstring.h>
#include <tqptrlist.h>
#include <tqrect.h>
#include <tqiconview.h>

// KDE includes.

#include <kurl.h>
#include <libkexiv2/kexiv2.h>

class TQImage;
class TQPixmap;

class KPrinter;

namespace KIPIPrintWizardPlugin
{

class TPhoto 
{
  public:
    TPhoto(int thumbnailSize);
    ~TPhoto();

    KURL filename; // full path

    TQPixmap & thumbnail();
    TQImage    loadPhoto();

    int m_thumbnailSize;

    int width();
    int height();

    TQRect cropRegion;
    int copies;
    int rotation;
    KExiv2Iface::KExiv2 *exiv2Iface();

  private:
    TQPixmap *m_thumbnail;
    void loadCache();
    TQSize & size();
    TQSize * m_size;
    KExiv2Iface::KExiv2 *m_exiv2Iface;
};

}  // NameSpace KIPIPrintWizardPlugin

#endif // TPHOTO_H