kaddressbook Library API Documentation

mikesstyle.h

00001 /* 00002 This file is part of KAddressBook. 00003 Copyright (c) 1996-2002 Mirko Boehm <mirko@kde.org> 00004 2002 Mike Pilone <mpilone@slac.com> 00005 00006 This program is free software; you can redistribute it and/or modify 00007 it under the terms of the GNU General Public License as published by 00008 the Free Software Foundation; either version 2 of the License, or 00009 (at your option) any later version. 00010 00011 This program is distributed in the hope that it will be useful, 00012 but WITHOUT ANY WARRANTY; without even the implied warranty of 00013 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00014 GNU General Public License for more details. 00015 00016 You should have received a copy of the GNU General Public License 00017 along with this program; if not, write to the Free Software 00018 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 00019 00020 As a special exception, permission is given to link this program 00021 with any edition of Qt, and distribute the resulting executable, 00022 without including the source code for Qt in the source distribution. 00023 */ 00024 00025 #ifndef MIKESSTYLE_H 00026 #define MIKESSTYLE_H 00027 00028 #include <qfont.h> 00029 00030 #include "printstyle.h" 00031 00032 namespace KABPrinting { 00033 00034 class PrintProgress; 00035 00036 class MikesStyle : public PrintStyle 00037 { 00038 Q_OBJECT 00039 public: 00040 MikesStyle(PrintingWizard* parent, const char* name); 00041 ~MikesStyle(); 00042 void print(KABC::Addressee::List&, PrintProgress*); 00043 protected: 00044 void doPaint(QPainter &painter, const KABC::Addressee &a, 00045 int maxHeight, 00046 const QFont& font, const QFont& bFont); 00047 int calcHeight(const KABC::Addressee &a, 00048 const QFont& font, const QFont& bFont); 00049 void paintTagLine(QPainter &p, const QFont& font); 00050 QString trimString(const QString &text, int width, 00051 QFontMetrics &fm); 00052 }; 00053 00054 class MikesStyleFactory : public PrintStyleFactory 00055 { 00056 public: 00057 MikesStyleFactory(PrintingWizard* parent_, 00058 const char* name_=0); 00059 PrintStyle *create(); 00060 QString description(); 00061 }; 00062 00063 } 00064 00065 #endif
KDE Logo
This file is part of the documentation for kaddressbook Library Version 3.3.0.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Fri Oct 1 15:19:05 2004 by doxygen 1.3.7 written by Dimitri van Heesch, © 1997-2003