ldifvcardcreator.h
1/*
2 This file is part of KAddressBook.
3 Copyright (C) 2003 Helge Deller <deller@kde.org>
4
5 This library is free software; you can redistribute it and/or
6 modify it under the terms of the GNU Library General Public
7 License as published by the Free Software Foundation; either
8 version 2 of the License, or (at your option) any later version.
9
10 This library is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 Library General Public License for more details.
14
15 You should have received a copy of the GNU Library General Public License
16 along with this library; see the file COPYING.LIB. If not, write to
17 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18 Boston, MA 02110-1301, USA.
19*/
20
21#ifndef VCARD_LDIFCREATOR_H
22#define VCARD_LDIFCREATOR_H
23
24#include <tqpixmap.h>
25#include <tdeio/thumbcreator.h>
26#include <tdeabc/vcardparser.h> // for KABC_VCARD_ENCODING_FIX define
27
28class KPixmapSplitter;
29
30class VCard_LDIFCreator : public ThumbCreator
31{
32 public:
33 VCard_LDIFCreator();
34 virtual ~VCard_LDIFCreator();
35 virtual bool create(const TQString &path, int width, int height, TQImage &img);
36 virtual Flags flags() const;
37
38 private:
39 KPixmapSplitter *mSplitter;
40 TQPixmap mPixmap;
41
42 TQString name;
43 TQString text;
44 bool readContents( const TQString &path );
45 int xborder, yborder;
46 TQSize pixmapSize;
47 bool createImageSmall();
48 bool createImageBig();
49};
50
51#endif