summaryrefslogtreecommitdiffabout
path: root/pwmanager/pwmanager/printtext.h
Unidiff
Diffstat (limited to 'pwmanager/pwmanager/printtext.h') (more/less context) (show whitespace changes)
-rw-r--r--pwmanager/pwmanager/printtext.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/pwmanager/pwmanager/printtext.h b/pwmanager/pwmanager/printtext.h
index 82e31b0..71bc2e0 100644
--- a/pwmanager/pwmanager/printtext.h
+++ b/pwmanager/pwmanager/printtext.h
@@ -1,68 +1,68 @@
1/*************************************************************************** 1/***************************************************************************
2 * * 2 * *
3 * copyright (C) 2003 by Michael Buesch * 3 * copyright (C) 2003 by Michael Buesch *
4 * email: mbuesch@freenet.de * 4 * email: mbuesch@freenet.de *
5 * * 5 * *
6 * This program is free software; you can redistribute it and/or modify * 6 * This program is free software; you can redistribute it and/or modify *
7 * it under the terms of the GNU General Public License version 2 * 7 * it under the terms of the GNU General Public License version 2 *
8 * as published by the Free Software Foundation. * 8 * as published by the Free Software Foundation. *
9 * * 9 * *
10 ***************************************************************************/ 10 ***************************************************************************/
11 11
12#ifndef PRINTTEXT_H 12#ifndef PRINTTEXT_H
13#define PRINTTEXT_H 13#define PRINTTEXT_H
14 14
15#include <kprinter.h> 15#include <kprinter.h>
16 16
17#include <qpainter.h> 17#include <qpainter.h>
18#include <qpaintdevicemetrics.h> 18#include <q3paintdevicemetrics.h>
19#include <qrect.h> 19#include <qrect.h>
20#include <qpoint.h> 20#include <qpoint.h>
21 21
22/** prints text "raw" to a printer */ 22/** prints text "raw" to a printer */
23class PrintText : public KPrinter 23class PrintText : public KPrinter
24{ 24{
25public: 25public:
26 PrintText(); 26 PrintText();
27 ~PrintText(); 27 ~PrintText();
28 28
29 /** begin printing. Call this before drawing to the device! */ 29 /** begin printing. Call this before drawing to the device! */
30 void beginPrint(); 30 void beginPrint();
31 /** prints a line */ 31 /** prints a line */
32 void printLine(QString t); 32 void printLine(QString t);
33 /** returns a pointer to the paint object */ 33 /** returns a pointer to the paint object */
34 QPainter* getPaint() 34 QPainter* getPaint()
35 { return paint; } 35 { return paint; }
36 /** sets the header-text */ 36 /** sets the header-text */
37 void setHeader(const QString &left, const QString &middle); 37 void setHeader(const QString &left, const QString &middle);
38 /** returns the header-text */ 38 /** returns the header-text */
39 void getHeader(QString *left, QString *middle); 39 void getHeader(QString *left, QString *middle);
40 40
41protected: 41protected:
42 /** painter object */ 42 /** painter object */
43 QPainter *paint; 43 QPainter *paint;
44 /** metrics */ 44 /** metrics */
45 QPaintDeviceMetrics *metrics; 45 Q3PaintDeviceMetrics *metrics;
46 /** left field of header */ 46 /** left field of header */
47 QString headerLeft; 47 QString headerLeft;
48 /** middle field of header */ 48 /** middle field of header */
49 QString headerMiddle; 49 QString headerMiddle;
50 /** right field of header */ 50 /** right field of header */
51 QString headerRight; 51 QString headerRight;
52 /** current Y-Position */ 52 /** current Y-Position */
53 int curYPos; 53 int curYPos;
54 /** text-body rectangle */ 54 /** text-body rectangle */
55 QRect body; 55 QRect body;
56 /** line-spacing */ 56 /** line-spacing */
57 int ls; 57 int ls;
58 /** top-left point for beginning printing */ 58 /** top-left point for beginning printing */
59 QPoint topLeft; 59 QPoint topLeft;
60 /** current page number */ 60 /** current page number */
61 int page; 61 int page;
62 62
63protected: 63protected:
64 /** prints the header on the page */ 64 /** prints the header on the page */
65 void printHeader(); 65 void printHeader();
66}; 66};
67 67
68#endif 68#endif