diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-05-29 00:55:34 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-05-29 00:55:34 +0000 |
commit | c4189d200e71c7ef82e9a6e34935ad225154d658 (patch) | |
tree | f7f29a1159e0402472ff2ab22617a8113f66263c /kbarcode/batchprinter.h | |
parent | 2f888b1578e65ec1bc514996eb509fcaf34462d6 (diff) | |
download | kbarcode-c4189d200e71c7ef82e9a6e34935ad225154d658.tar.gz kbarcode-c4189d200e71c7ef82e9a6e34935ad225154d658.zip |
TQt4 port kbarcode
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/kbarcode@1233956 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kbarcode/batchprinter.h')
-rw-r--r-- | kbarcode/batchprinter.h | 78 |
1 files changed, 39 insertions, 39 deletions
diff --git a/kbarcode/batchprinter.h b/kbarcode/batchprinter.h index c189183..ed06a9e 100644 --- a/kbarcode/batchprinter.h +++ b/kbarcode/batchprinter.h @@ -20,8 +20,8 @@ #include "measurements.h" -#include <qmap.h> -#include <qvaluelist.h> +#include <tqmap.h> +#include <tqvaluelist.h> namespace KABC { class AddresseeList; @@ -31,13 +31,13 @@ class Definition; class Label; class KPrinter; class Measurements; -class QBuffer; -class QPainter; -class QProgressDialog; -class QWidget; -class QPaintDevice; +class TQBuffer; +class TQPainter; +class TQProgressDialog; +class TQWidget; +class TQPaintDevice; -typedef QValueList< QMap<QString,QString> > TVariableList; +typedef TQValueList< TQMap<TQString,TQString> > TVariableList; /** This class is responsible for batch printing of articles. It is also responsible for creating images of all articles. @@ -51,29 +51,29 @@ class BatchPrinter struct data { int number; - QString article_no; - QString group; + TQString article_no; + TQString group; }; /** Use this constructor if you want to print to * a printer. */ - BatchPrinter( KPrinter* p, QWidget* _parent ); + BatchPrinter( KPrinter* p, TQWidget* _parent ); /** This constructor is used in image gernaration mode. * @p path is the path to an existing directory where * the images are saved. */ - BatchPrinter( const QString & path, QWidget* p ); + BatchPrinter( const TQString & path, TQWidget* p ); /** Use this constructor to print to a barcode printer @p path * with format @p format */ - BatchPrinter( const QString & path, int format, QWidget* _parent ); + BatchPrinter( const TQString & path, int format, TQWidget* _parent ); ~BatchPrinter(); - inline void setBuffer( QBuffer* b ) { buffer = b; } - void setCustomer( const QString & s ) { m_customer = s; } + inline void setBuffer( TQBuffer* b ) { buffer = b; } + void setCustomer( const TQString & s ) { m_customer = s; } /** Specify the label on which is printed first on the page. * The first label on the page (top/left) has the index 1, @@ -86,7 +86,7 @@ class BatchPrinter /** set the sql data for the batchprinter * @p list will be deleted by the batchprinter */ - void setData( QValueList<data>* list ); + void setData( TQValueList<data>* list ); /** set the variable data for the batchprinter * @p list will be deleted by the batchprinter @@ -99,10 +99,10 @@ class BatchPrinter void setData( KABC::AddresseeList* list ); inline void setImageFilename( const EImageFileName e ) { m_image_filename = e; } - inline void setImageCustomFilename( const QString & name ) { m_image_custom_filename = name; }; - inline void setImageFormat( const QString & f ) { m_image_format = f; } - inline void setSerial( const QString & s, unsigned int inc ) { m_serial = s; m_increment = inc; } - inline void setName( const QString & s ) { m_name = s; } + inline void setImageCustomFilename( const TQString & name ) { m_image_custom_filename = name; }; + inline void setImageFormat( const TQString & f ) { m_image_format = f; } + inline void setSerial( const TQString & s, unsigned int inc ) { m_serial = s; m_increment = inc; } + inline void setName( const TQString & s ) { m_name = s; } inline void setDefinition( Definition* d ) { def = d; } inline void setLabels( int l ) { m_labels = l; } inline void setEvents( bool b ) { m_events = b; } @@ -126,7 +126,7 @@ class BatchPrinter * current label does not fit anymore on the current pageh */ void checkForNewPage( Label* label ); - /** draw a border around the current label using QPainter @p painter + /** draw a border around the current label using TQPainter @p painter */ void drawBorders(); /** start a "new line" on the printer, @@ -134,38 +134,38 @@ class BatchPrinter * on the page. */ void changeLine(); - void proccessEvents( int lb, QString value = QString::null, Label* label = 0 ); - void printXLabel( int lb, Label* label, const QString & value ); + void proccessEvents( int lb, TQString value = TQString(), Label* label = 0 ); + void printXLabel( int lb, Label* label, const TQString & value ); void moveLabels(); /** print the labels using data from the m_data structure */ - void startPrintData( QProgressDialog* progress ); + void startPrintData( TQProgressDialog* progress ); /** print the labels using data from the m_vardata or m_addrdata structure */ - void startPrintVarData( QProgressDialog* progress ); + void startPrintVarData( TQProgressDialog* progress ); /** Create and return a progressdialog */ - QProgressDialog* createProgressDialog( const QString & caption ); - bool checkProgressDialog( QProgressDialog* progress ); + TQProgressDialog* createProgressDialog( const TQString & caption ); + bool checkProgressDialog( TQProgressDialog* progress ); Definition* def; Measurements m_measure; - QValueList<data>* m_data; + TQValueList<data>* m_data; TVariableList* m_vardata; KABC::AddresseeList* m_addrdata; - QString m_serial; - QString m_name; - QString m_customer; + TQString m_serial; + TQString m_name; + TQString m_customer; /** Path for image output * or device for bcp output */ - QString m_path; + TQString m_path; /** defines the image format to be used */ - QString m_image_format; + TQString m_image_format; unsigned int m_cur_data_count; @@ -179,7 +179,7 @@ class BatchPrinter /** prefix for custom filenames if m_image_filename = E_CUSTOM */ - QString m_image_custom_filename; + TQString m_image_custom_filename; /** enable/disable events */ @@ -199,14 +199,14 @@ class BatchPrinter int c_h; int c_w; - QPaintDevice* m_paintDevice; + TQPaintDevice* m_paintDevice; - QBuffer* buffer; + TQBuffer* buffer; KPrinter* printer; - QPainter* painter; - /** parent for dialogs + TQPainter* painter; + /** tqparent for dialogs */ - QWidget* parent; + TQWidget* tqparent; }; #endif |