From e69e8b1d09fb579316595b4e6a850e717358a8b1 Mon Sep 17 00:00:00 2001 From: tpearson Date: Sun, 19 Jun 2011 19:03:33 +0000 Subject: TQt4 port kdegraphics This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdegraphics@1237557 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kooka/CHANGES | 2 +- kooka/dwmenuaction.cpp | 8 ++++---- kooka/dwmenuaction.h | 9 ++++---- kooka/formathelp.h | 4 ++-- kooka/imageselectline.cpp | 8 ++++---- kooka/imageselectline.h | 9 ++++---- kooka/img_saver.cpp | 42 +++++++++++++++++++------------------- kooka/img_saver.h | 14 +++++++------ kooka/imgnamecombo.cpp | 16 +++++++-------- kooka/imgnamecombo.h | 5 +++-- kooka/imgprintdialog.cpp | 24 +++++++++++----------- kooka/imgprintdialog.h | 7 ++++--- kooka/kadmosocr.cpp | 10 ++++----- kooka/kadmosocr.h | 7 ++++--- kooka/kocrbase.cpp | 20 +++++++++--------- kooka/kocrbase.h | 7 ++++--- kooka/kocrgocr.cpp | 10 ++++----- kooka/kocrgocr.h | 5 +++-- kooka/kocrkadmos.cpp | 20 +++++++++--------- kooka/kocrkadmos.h | 7 ++++--- kooka/kocrocrad.cpp | 22 ++++++++++---------- kooka/kocrocrad.h | 9 ++++---- kooka/kooka.cpp | 52 +++++++++++++++++++++++------------------------ kooka/kooka.h | 7 ++++--- kooka/kookaimage.cpp | 20 +++++++++--------- kooka/kookaimage.h | 16 +++++++-------- kooka/kookaimagemeta.cpp | 4 ++-- kooka/kookaimagemeta.h | 4 ++-- kooka/kookapref.cpp | 34 +++++++++++++++---------------- kooka/kookapref.h | 5 +++-- kooka/kookaprint.cpp | 18 ++++++++-------- kooka/kookaprint.h | 7 ++++--- kooka/kookarc | 30 +++++++++++++-------------- kooka/kookaview.cpp | 52 +++++++++++++++++++++++------------------------ kooka/kookaview.h | 9 ++++---- kooka/ksaneocr.cpp | 40 ++++++++++++++++++------------------ kooka/ksaneocr.h | 11 +++++----- kooka/main.cpp | 8 ++++---- kooka/ocrresedit.cpp | 16 +++++++-------- kooka/ocrresedit.h | 9 ++++---- kooka/ocrword.cpp | 10 ++++----- kooka/ocrword.h | 6 +++--- kooka/resource.h | 6 +++--- kooka/scanpackager.cpp | 42 +++++++++++++++++++------------------- kooka/scanpackager.h | 9 ++++---- kooka/thumbview.cpp | 16 +++++++-------- kooka/thumbview.h | 7 ++++--- kooka/thumbviewitem.cpp | 8 ++++---- kooka/thumbviewitem.h | 6 +++--- 49 files changed, 368 insertions(+), 349 deletions(-) (limited to 'kooka') diff --git a/kooka/CHANGES b/kooka/CHANGES index 0b384de6..550637d7 100644 --- a/kooka/CHANGES +++ b/kooka/CHANGES @@ -20,7 +20,7 @@ scanned with about 150 dpi. via mime mechanism of KDE (KRun). OCR-Parameter get stored via KConfig. OCR may be performed on the entire image or the selection. -* Reworked the save assistant: New layout and fully KDE2-Compliant. +* Reworked the save assistant: New tqlayout and fully KDE2-Compliant. Still no new Image format help texts. * Reworked the startup dialog: Allows to select the scan device from a diff --git a/kooka/dwmenuaction.cpp b/kooka/dwmenuaction.cpp index 920fb433..d77c8d16 100644 --- a/kooka/dwmenuaction.cpp +++ b/kooka/dwmenuaction.cpp @@ -22,8 +22,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -32,9 +32,9 @@ //------------------------------------- dwMenuAction::dwMenuAction( const TQString& text, const KShortcut& cut, - KDockWidget *dw,TQObject* parent, + KDockWidget *dw,TQObject* tqparent, KDockMainWindow *mw, const char* name ) - :KToggleAction(text,cut,parent,name),m_dw(dw),m_mw(mw) + :KToggleAction(text,cut,tqparent,name),m_dw(dw),m_mw(mw) { connect(this,TQT_SIGNAL(toggled(bool)),this,TQT_SLOT(slotToggled(bool))); connect(m_dw->dockManager(),TQT_SIGNAL(change()),this,TQT_SLOT(anDWChanged())); diff --git a/kooka/dwmenuaction.h b/kooka/dwmenuaction.h index e260a094..d6cac229 100644 --- a/kooka/dwmenuaction.h +++ b/kooka/dwmenuaction.h @@ -22,8 +22,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -35,7 +35,7 @@ /** * This class is just a helper class since the KDockWidget classes do not yet - * export KActions but only a QPopup-Pointer, which is quite useless in case + * export KActions but only a TQPopup-Pointer, which is quite useless in case * you have a xml-file driven gui. * This class provides Actions for show and hide parts of the GUI (dockwidgets) * Maybe that classes can be removed as soon the DockWidget know Actions @@ -43,10 +43,11 @@ class dwMenuAction:public KToggleAction { Q_OBJECT + TQ_OBJECT public: dwMenuAction( const TQString& text, const KShortcut& cut = KShortcut(), - KDockWidget *dw=0, TQObject* parent = 0, + KDockWidget *dw=0, TQObject* tqparent = 0, KDockMainWindow * mw=0, const char* name = 0 ); virtual ~dwMenuAction(); diff --git a/kooka/formathelp.h b/kooka/formathelp.h index 7887a240..9e754bdb 100644 --- a/kooka/formathelp.h +++ b/kooka/formathelp.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ diff --git a/kooka/imageselectline.cpp b/kooka/imageselectline.cpp index 4145cc30..99ba935e 100644 --- a/kooka/imageselectline.cpp +++ b/kooka/imageselectline.cpp @@ -21,8 +21,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ #include @@ -47,8 +47,8 @@ * together in a row. The button opens a file selector box to pick a file. */ -ImageSelectLine::ImageSelectLine( TQWidget *parent, const TQString& text ) - : TQHBox( parent ) +ImageSelectLine::ImageSelectLine( TQWidget *tqparent, const TQString& text ) + : TQHBox( tqparent ) { setSpacing( 5 ); (void) new TQLabel( text, this ); diff --git a/kooka/imageselectline.h b/kooka/imageselectline.h index 92cfec17..a9672edf 100644 --- a/kooka/imageselectline.h +++ b/kooka/imageselectline.h @@ -21,8 +21,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -40,11 +40,12 @@ class KURLComboBox; class TQPushButton; class TQStringList; -class ImageSelectLine:public QHBox +class ImageSelectLine:public TQHBox { Q_OBJECT + TQ_OBJECT public: - ImageSelectLine( TQWidget *parent, const TQString& text ); + ImageSelectLine( TQWidget *tqparent, const TQString& text ); KURL selectedURL() const; void setURL( const KURL& ); diff --git a/kooka/img_saver.cpp b/kooka/img_saver.cpp index b8c789fc..01a19461 100644 --- a/kooka/img_saver.cpp +++ b/kooka/img_saver.cpp @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -58,8 +58,8 @@ #include "previewer.h" #include "kookaimage.h" -FormatDialog::FormatDialog( TQWidget *parent, const TQString&, const char *name ) - :KDialogBase( parent, name, true, +FormatDialog::FormatDialog( TQWidget *tqparent, const TQString&, const char *name ) + :KDialogBase( tqparent, name, true, /* Tabbed,*/ i18n( "Kooka Save Assistant" ), Ok|Cancel, Ok ) @@ -116,7 +116,7 @@ FormatDialog::FormatDialog( TQWidget *parent, const TQString&, const char *name Q_CHECK_PTR(l_help); l_help->setFrameStyle( TQFrame::Panel|TQFrame::Sunken ); l_help->setText( i18n("-No format selected-" )); - l_help->setAlignment( AlignVCenter | AlignHCenter ); + l_help->tqsetAlignment( AlignVCenter | AlignHCenter ); l_help->setMinimumWidth(230); // Insert Selbox for subformat @@ -176,7 +176,7 @@ void FormatDialog::check_subformat( const TQString & format ) void FormatDialog::setSelectedFormat( TQString fo ) { - TQListBoxItem *item = lb_format->findItem( fo ); + TQListBoxItem *item = lb_format->tqfindItem( fo ); if( item ) { @@ -208,18 +208,18 @@ TQCString FormatDialog::getSubFormat( ) const #include "formathelp.h" void FormatDialog::buildHelp( void ) { - format_help.insert( TQString::fromLatin1("BMP"), HELP_BMP ); - format_help.insert( TQString::fromLatin1("PNM"), HELP_PNM ); - format_help.insert( TQString::fromLatin1("JPEG"), HELP_JPG ); - format_help.insert( TQString::fromLatin1("JPG"), HELP_JPG ); - format_help.insert( TQString::fromLatin1("EPS"), HELP_EPS ); + format_help.insert( TQString::tqfromLatin1("BMP"), HELP_BMP ); + format_help.insert( TQString::tqfromLatin1("PNM"), HELP_PNM ); + format_help.insert( TQString::tqfromLatin1("JPEG"), HELP_JPG ); + format_help.insert( TQString::tqfromLatin1("JPG"), HELP_JPG ); + format_help.insert( TQString::tqfromLatin1("EPS"), HELP_EPS ); } /* ********************************************************************** */ -ImgSaver::ImgSaver( TQWidget *parent, const KURL dir_name ) - : TQObject( parent ) +ImgSaver::ImgSaver( TQWidget *tqparent, const KURL dir_name ) + : TQObject( tqparent ) { if( dir_name.isEmpty() || dir_name.protocol() != "file" ) @@ -250,8 +250,8 @@ ImgSaver::ImgSaver( TQWidget *parent, const KURL dir_name ) } -ImgSaver::ImgSaver( TQWidget *parent ) - :TQObject( parent ) +ImgSaver::ImgSaver( TQWidget *tqparent ) + :TQObject( tqparent ) { directory = Previewer::galleryRoot(); createDir( directory ); @@ -276,14 +276,14 @@ void ImgSaver::createDir( const TQString& dir ) if( KIO::mkdir( KURL(dir))) { KMessageBox::sorry(0, i18n("The folder\n%1\n does not exist and could not be created;\n" - "please check the permissions.").arg(dir)); + "please check the permissions.").tqarg(dir)); } } #if 0 if( ! fi.isWritable() ) { KMessageBox::sorry(0, i18n("The directory\n%1\n is not writeable;\nplease check the permissions.") - .arg(dir)); + .tqarg(dir)); } #endif } @@ -395,7 +395,7 @@ TQString ImgSaver::createFilename( TQString format ) } /** - * This function gets a filename from the parent. The filename must not be relative. + * This function gets a filename from the tqparent. The filename must not be relative. **/ ImgSaveStat ImgSaver::saveImage( TQImage *image, const KURL& filename, const TQString& imgFormat ) { @@ -728,7 +728,7 @@ TQString ImgSaver::extension( const KURL& url ) { TQString extension = url.fileName(); - int dotPos = extension.findRev( '.' ); + int dotPos = extension.tqfindRev( '.' ); if( dotPos > 0 ) { int len = extension.length(); @@ -766,7 +766,7 @@ bool ImgSaver::renameImage( const KURL& fromUrl, KURL& toUrl, bool askExt, TQWi TQString s; s = i18n("The filename you supplied has no file extension.\nShould the correct one be added automatically? "); - s += i18n( "That would result in the new filename: %1" ).arg( fName); + s += i18n( "That would result in the new filename: %1" ).tqarg( fName); result = KMessageBox::questionYesNo(overWidget, s, i18n( "Extension Missing"), i18n("Add Extension"), i18n("Do Not Add"), @@ -863,7 +863,7 @@ bool ImgSaver::copyImage( const KURL& fromUrl, const KURL& toUrl, TQWidget *over TQString s; s = i18n("The filename you supplied has no file extension.\nShould the correct one be added automatically? "); - s += i18n( "That would result in the new filename: %1" ).arg( fName); + s += i18n( "That would result in the new filename: %1" ).tqarg( fName); result = KMessageBox::questionYesNo(overWidget, s, i18n( "Extension Missing"), i18n("Add Extension"), i18n("Do Not Add"), diff --git a/kooka/img_saver.h b/kooka/img_saver.h index 95204ad7..31f6d8ab 100644 --- a/kooka/img_saver.h +++ b/kooka/img_saver.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -101,8 +101,9 @@ class KookaImage; class FormatDialog:public KDialogBase { Q_OBJECT + TQ_OBJECT public: - FormatDialog( TQWidget *parent, const TQString&, const char * ); + FormatDialog( TQWidget *tqparent, const TQString&, const char * ); TQString getFormat( ) const; @@ -129,7 +130,7 @@ private: TQComboBox *cb_subf; TQListBox *lb_format; TQLabel *l_help; - QLabel *l2; + TQLabel *l2; TQCheckBox *cbRemember; TQCheckBox *cbDontAsk; }; @@ -144,6 +145,7 @@ private: class ImgSaver:public TQObject { Q_OBJECT + TQ_OBJECT public: /** * constructor of the image-saver object. @@ -153,8 +155,8 @@ public: * @param dir Name of the save root directory * @param name Name of a subdirectory in the saveroot. **/ - ImgSaver( TQWidget *parent, const KURL ); - ImgSaver( TQWidget *parent ); + ImgSaver( TQWidget *tqparent, const KURL ); + ImgSaver( TQWidget *tqparent ); TQString errorString( ImgSaveStat ); /** diff --git a/kooka/imgnamecombo.cpp b/kooka/imgnamecombo.cpp index 0e06646b..94faa083 100644 --- a/kooka/imgnamecombo.cpp +++ b/kooka/imgnamecombo.cpp @@ -20,8 +20,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -38,8 +38,8 @@ #include "imgnamecombo.h" #include "img_saver.h" -ImageNameCombo::ImageNameCombo( TQWidget *parent ) - : KComboBox( parent ) +ImageNameCombo::ImageNameCombo( TQWidget *tqparent ) + : KComboBox( tqparent ) { setInsertionPolicy( TQComboBox::AtTop ); } @@ -51,12 +51,12 @@ ImageNameCombo::~ImageNameCombo() void ImageNameCombo::slotPathRemove( KFileTreeBranch *branch, const TQString& relPath ) { - TQString path = branch->name() + TQString::fromLatin1(" - ") + relPath; + TQString path = branch->name() + TQString::tqfromLatin1(" - ") + relPath; kdDebug(28000) << "ImageNameCombo: Removing " << path << endl; TQString select = currentText(); - if( items.contains( path )) + if( items.tqcontains( path )) { kdDebug(28000) << "ImageNameCombo: Item exists-> deleting" << endl; items.remove( path ); @@ -74,7 +74,7 @@ void ImageNameCombo::rewriteList( KFileTreeBranch *branch, const TQString& selTe insertItem( branch->pixmap(), *it ); } - int index = items.findIndex( selText ); + int index = items.tqfindIndex( selText ); setCurrentItem( index ); } @@ -82,7 +82,7 @@ void ImageNameCombo::slotGalleryPathChanged( KFileTreeBranch* branch, const TQSt { TQString newPath; - newPath = branch->name() + TQString::fromLatin1(" - ") + relativPath; + newPath = branch->name() + TQString::tqfromLatin1(" - ") + relativPath; kdDebug( 28000) << "Inserting " << newPath << " to combobox" << endl; diff --git a/kooka/imgnamecombo.h b/kooka/imgnamecombo.h index 1beb1235..3a44aee3 100644 --- a/kooka/imgnamecombo.h +++ b/kooka/imgnamecombo.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -41,6 +41,7 @@ class KFileBranch; class ImageNameCombo: public KComboBox { Q_OBJECT + TQ_OBJECT public: ImageNameCombo( TQWidget* ); ~ImageNameCombo(); diff --git a/kooka/imgprintdialog.cpp b/kooka/imgprintdialog.cpp index fa7ee620..98a783f4 100644 --- a/kooka/imgprintdialog.cpp +++ b/kooka/imgprintdialog.cpp @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ #include "imgprintdialog.h" @@ -47,15 +47,15 @@ #define ID_CUSTOM 2 #define ID_FIT_PAGE 3 -ImgPrintDialog::ImgPrintDialog( KookaImage *img, TQWidget *parent, const char* name ) - : KPrintDialogPage( parent, name ), +ImgPrintDialog::ImgPrintDialog( KookaImage *img, TQWidget *tqparent, const char* name ) + : KPrintDialogPage( tqparent, name ), m_image(img), m_ignoreSignal(false) { setTitle(i18n("Image Printing")); - TQVBoxLayout *layout = new TQVBoxLayout( this ); - // layout->setMargin( KDialog::marginHint() ); - // layout->setSpacing( KDialog::spacingHint() ); + TQVBoxLayout *tqlayout = new TQVBoxLayout( this ); + // tqlayout->setMargin( KDialog::marginHint() ); + // tqlayout->setSpacing( KDialog::spacingHint() ); m_scaleRadios = new TQButtonGroup( 2, Qt::Vertical, i18n("Image Print Size"), this ); m_scaleRadios->setRadioButtonExclusive(true); @@ -84,11 +84,11 @@ ImgPrintDialog::ImgPrintDialog( KookaImage *img, TQWidget *parent, const char* n TQToolTip::add( m_rbFitPage, i18n("Printout uses maximum space on the selected pager. Aspect ratio is maintained.")); m_scaleRadios->insert( m_rbFitPage, ID_FIT_PAGE ); - layout->addWidget( m_scaleRadios ); + tqlayout->addWidget( m_scaleRadios ); TQHBoxLayout *hbox = new TQHBoxLayout( this ); - layout->addLayout( hbox ); + tqlayout->addLayout( hbox ); /** Box for Image Resolutions **/ TQVGroupBox *group1 = new TQVGroupBox( i18n("Resolutions"), this ); @@ -127,8 +127,8 @@ ImgPrintDialog::ImgPrintDialog( KookaImage *img, TQWidget *parent, const char* n TQWidget *spaceEater = new TQWidget( this ); - spaceEater->setSizePolicy( TQSizePolicy( TQSizePolicy::Ignored, TQSizePolicy::Ignored )); - layout->addWidget( spaceEater ); + spaceEater->tqsetSizePolicy( TQSizePolicy( TQSizePolicy::Ignored, TQSizePolicy::Ignored )); + tqlayout->addWidget( spaceEater ); /* Set start values */ m_rbScreen->setChecked(true); @@ -167,7 +167,7 @@ void ImgPrintDialog::setOptions(const TQMap& opts) m_sizeH->setValue( help ); help = opts[OPT_SCREEN_RES].toInt(); - m_screenRes->setText(i18n( "Screen resolution: %1 dpi").arg(help)); + m_screenRes->setText(i18n( "Screen resolution: %1 dpi").tqarg(help)); help = opts[OPT_PSGEN_DRAFT].toInt(); m_psDraft->setChecked( help == 1 ); diff --git a/kooka/imgprintdialog.h b/kooka/imgprintdialog.h index f710820e..389a546c 100644 --- a/kooka/imgprintdialog.h +++ b/kooka/imgprintdialog.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -53,8 +53,9 @@ class TQCheckBox; class ImgPrintDialog: public KPrintDialogPage { Q_OBJECT + TQ_OBJECT public: - ImgPrintDialog( KookaImage *img, TQWidget *parent=0L, const char* name=0L ); + ImgPrintDialog( KookaImage *img, TQWidget *tqparent=0L, const char* name=0L ); void setOptions(const TQMap& opts); void getOptions(TQMap& opts, bool include_def = false); diff --git a/kooka/kadmosocr.cpp b/kooka/kadmosocr.cpp index d0d41e13..3110451f 100644 --- a/kooka/kadmosocr.cpp +++ b/kooka/kadmosocr.cpp @@ -25,8 +25,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -313,12 +313,12 @@ void CRep::partStrings( int line, int graphKnode, TQString soFar ) void CRep::drawCharBox( TQPixmap *pix, const TQRect& r ) { - drawBox( pix, r, TQColor( Qt::red )); + drawBox( pix, r, TQColor( TQt::red )); } void CRep::drawLineBox( TQPixmap* pix, const TQRect& r ) { - drawBox( pix, r, TQColor( Qt::blue )); + drawBox( pix, r, TQColor( TQt::blue )); } void CRep::drawBox( TQPixmap* pix, const TQRect& r, const TQColor& color ) @@ -356,7 +356,7 @@ KADMOS_ERROR CRep::SetImage(TQImage *Image) m_RepData.image.width = Image->width(); m_RepData.image.height = Image->height(); m_RepData.image.bitsperpixel = Image->depth(); - m_RepData.image.alignment = 1; + m_RepData.image.tqalignment = 1; m_RepData.image.fillorder = FILLORDER_MSB2LSB; // color if( Image->depth() == 1 || (Image->numColors()==2 && Image->depth() == 8) ) diff --git a/kooka/kadmosocr.h b/kooka/kadmosocr.h index cc4d225f..ca7edcb4 100644 --- a/kooka/kadmosocr.h +++ b/kooka/kadmosocr.h @@ -23,8 +23,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -66,9 +66,10 @@ namespace Kadmos { const char CPP_ERROR[] = "Kadmos CPP interface error"; /* ==== CRep ========================================= */ - class CRep : public QObject + class CRep : public TQObject { Q_OBJECT + TQ_OBJECT public: CRep(); virtual ~CRep(); diff --git a/kooka/kocrbase.cpp b/kooka/kocrbase.cpp index 3ede6ef0..4c9ccc14 100644 --- a/kooka/kocrbase.cpp +++ b/kooka/kocrbase.cpp @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -59,10 +59,10 @@ #include #include -KOCRBase::KOCRBase( TQWidget *parent, KSpellConfig *spellConfig, +KOCRBase::KOCRBase( TQWidget *tqparent, KSpellConfig *spellConfig, KDialogBase::DialogType face ) :KDialogBase( face, i18n("Optical Character Recognition"), - User2|Close|User1, User1, parent,0, false, true, + User2|Close|User1, User1, tqparent,0, false, true, KGuiItem( i18n("Start OCR" ), "launch", i18n("Start the Optical Character Recognition process" )), KGuiItem( i18n("Cancel" ), "stopocr", @@ -98,11 +98,11 @@ KOCRBase::KOCRBase( TQWidget *parent, KSpellConfig *spellConfig, } -KAnimWidget* KOCRBase::getAnimation(TQWidget *parent) +KAnimWidget* KOCRBase::getAnimation(TQWidget *tqparent) { if( ! m_animation ) { - m_animation = new KAnimWidget( TQString("kde"), 48, parent, "ANIMATION" ); + m_animation = new KAnimWidget( TQString("kde"), 48, tqparent, "ANIMATION" ); } return( m_animation ); } @@ -129,7 +129,7 @@ void KOCRBase::imgIntro() m_previewPix = new TQLabel( m_imgHBox ); m_previewPix->setPixmap(TQPixmap()); m_previewPix->setFixedSize(m_previewSize); - m_previewPix->setAlignment( Qt::AlignCenter ); + m_previewPix->tqsetAlignment( TQt::AlignCenter ); m_previewPix->setFrameStyle( TQFrame::Panel | TQFrame::Sunken ); // m_previewPix->resize(m_previewSize); @@ -164,7 +164,7 @@ void KOCRBase::ocrIntro( ) hb_cap->setSpacing( KDialog::spacingHint()); TQLabel *imgLab = new TQLabel( hb_cap ); - imgLab->setAlignment( Qt::AlignHCenter | Qt::AlignTop ); + imgLab->tqsetAlignment( TQt::AlignHCenter | TQt::AlignTop ); imgLab->setPixmap( pix ); pa = hb_cap; } @@ -188,7 +188,7 @@ void KOCRBase::spellCheckIntro() KSpellConfig *sCfg = new KSpellConfig( m_gbSpellOpts, "SPELLCHK", m_spellConfig, false ); /* A space eater */ TQWidget *spaceEater = new TQWidget(m_spellchkPage); - spaceEater->setSizePolicy( TQSizePolicy( TQSizePolicy::Ignored, TQSizePolicy::Ignored )); + spaceEater->tqsetSizePolicy( TQSizePolicy( TQSizePolicy::Ignored, TQSizePolicy::Ignored )); /* connect toggle button */ connect( m_cbWantCheck, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(slWantSpellcheck(bool))); @@ -285,7 +285,7 @@ void KOCRBase::introduceImage( KookaImage* img) } } TQWidget *spaceEater = new TQWidget( m_metaBox ); - spaceEater->setSizePolicy( TQSizePolicy( TQSizePolicy::Ignored, TQSizePolicy::Ignored )); + spaceEater->tqsetSizePolicy( TQSizePolicy( TQSizePolicy::Ignored, TQSizePolicy::Ignored )); m_metaBox->show(); } diff --git a/kooka/kocrbase.h b/kooka/kocrbase.h index a2a04342..5f7e55a9 100644 --- a/kooka/kocrbase.h +++ b/kooka/kocrbase.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -54,6 +54,7 @@ class TQGroupBox; class KOCRBase: public KDialogBase { Q_OBJECT + TQ_OBJECT public: KOCRBase( TQWidget *, KSpellConfig *spellConfig, KDialogBase::DialogType face = KDialogBase::Plain ); @@ -106,7 +107,7 @@ protected: * ocr engine used. * It calls the virtual subs ocrEngineName, ocrEngineLogo and ocrEngineDesc which * must return the approbiate values for the engines. - * @return a pointer to a VBox in which further elements can be layouted + * @return a pointer to a VBox in which further elements can be tqlayouted */ virtual void ocrIntro(); diff --git a/kooka/kocrgocr.cpp b/kooka/kocrgocr.cpp index aa6eb333..dbb255c4 100644 --- a/kooka/kocrgocr.cpp +++ b/kooka/kocrgocr.cpp @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -58,8 +58,8 @@ -KGOCRDialog::KGOCRDialog( TQWidget *parent, KSpellConfig *spellConfig ) - :KOCRBase( parent, spellConfig, KDialogBase::Tabbed ), +KGOCRDialog::KGOCRDialog( TQWidget *tqparent, KSpellConfig *spellConfig ) + :KOCRBase( tqparent, spellConfig, KDialogBase::Tabbed ), m_ocrCmd( TQString()) { kdDebug(28000) << "Starting KOCR-Start-Dialog!" << endl; @@ -96,7 +96,7 @@ EngineError KGOCRDialog::setupGui() KConfig *conf = KGlobal::config (); conf->setGroup( CFG_GROUP_OCR_DIA ); - // Horizontal line + //Qt::Horizontal line // (void) new KSeparator( KSeparator::HLine, page); // Entry-Field. diff --git a/kooka/kocrgocr.h b/kooka/kocrgocr.h index f17cdd0a..2b42ebfb 100644 --- a/kooka/kocrgocr.h +++ b/kooka/kocrgocr.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -45,6 +45,7 @@ class KSpellConfig; class KGOCRDialog: public KOCRBase { Q_OBJECT + TQ_OBJECT public: KGOCRDialog( TQWidget*, KSpellConfig* ); ~KGOCRDialog(); diff --git a/kooka/kocrkadmos.cpp b/kooka/kocrkadmos.cpp index 6ac6fb12..97d8310f 100644 --- a/kooka/kocrkadmos.cpp +++ b/kooka/kocrkadmos.cpp @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -64,8 +64,8 @@ #define CNTRY_CZ i18n( "Czech Republic, Slovakia") #define CNTRY_GB i18n( "Great Britain, USA" ) -KadmosDialog::KadmosDialog( TQWidget *parent, KSpellConfig *spellConfig ) - :KOCRBase( parent, spellConfig, KDialogBase::Tabbed ), +KadmosDialog::KadmosDialog( TQWidget *tqparent, KSpellConfig *spellConfig ) + :KOCRBase( tqparent, spellConfig, KDialogBase::Tabbed ), m_cbNoise(0), m_cbAutoscale(0), m_haveNorm(false) @@ -163,7 +163,7 @@ EngineError KadmosDialog::findClassifiers() if( name.startsWith( "ttf" ) ) { TQString lang = name.mid(3,2); - if( allCountries.contains(lang) ) + if( allCountries.tqcontains(lang) ) { TQString lngCountry = locale->twoAlphaToCountryName(lang); if( lngCountry.isEmpty() ) @@ -188,7 +188,7 @@ EngineError KadmosDialog::findClassifiers() else if( name.startsWith( "hand" ) ) { TQString lang = name.mid(4,2); - if( allCountries.contains(lang) ) + if( allCountries.tqcontains(lang) ) { TQString lngCountry = locale->twoAlphaToCountryName(lang); if( lngCountry.isEmpty() ) @@ -271,7 +271,7 @@ EngineError KadmosDialog::setupGui() /* continue page setup on the first page */ TQVBox *page = ocrPage(); - // Horizontal line + //Qt::Horizontal line (void) new KSeparator( KSeparator::HLine, page); // FIXME: dynamic classifier reading. @@ -422,14 +422,14 @@ bool KadmosDialog::getSelClassifier( TQString& path ) const if( res && ! fi.exists() ) { kdDebug(28000) << "Classifier file does not exist" << endl; - path = i18n("Classifier file %1 does not exist").arg(classifier); + path = i18n("Classifier file %1 does not exist").tqarg(classifier); res = false; } if( res && ! fi.isReadable() ) { kdDebug(28000) << "Classifier file could not be read" << endl; - path = i18n("Classifier file %1 is not readable").arg(classifier); + path = i18n("Classifier file %1 is not readable").tqarg(classifier); res = false; } @@ -461,7 +461,7 @@ TQString KadmosDialog::getSelClassifierName() const /* Get the long text from the combo box */ TQString selLang = m_cbLang->currentText(); TQString trans; - if( fType != "norm" && m_longCountry2short.contains( selLang )) + if( fType != "norm" && m_longCountry2short.tqcontains( selLang )) { TQString langType = m_longCountry2short[selLang]; trans = fType+langType+".rec"; diff --git a/kooka/kocrkadmos.h b/kooka/kocrkadmos.h index 567af55b..ac9a4176 100644 --- a/kooka/kocrkadmos.h +++ b/kooka/kocrkadmos.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -66,6 +66,7 @@ private: class KadmosDialog: public KOCRBase { Q_OBJECT + TQ_OBJECT public: KadmosDialog( TQWidget *, KSpellConfig *spellConfig ); ~KadmosDialog(); @@ -105,7 +106,7 @@ private: TQCheckBox *m_cbAutoscale; TQString m_customClassifierPath; - QButtonGroup *m_bbFont; + TQButtonGroup *m_bbFont; TQRadioButton *m_rbMachine; TQRadioButton *m_rbHand; diff --git a/kooka/kocrocrad.cpp b/kooka/kocrocrad.cpp index aab63405..31c3bc40 100644 --- a/kooka/kocrocrad.cpp +++ b/kooka/kocrocrad.cpp @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -54,8 +54,8 @@ -ocradDialog::ocradDialog( TQWidget *parent, KSpellConfig *spellConfig ) - :KOCRBase( parent, spellConfig, KDialogBase::Tabbed ), +ocradDialog::ocradDialog( TQWidget *tqparent, KSpellConfig *spellConfig ) + :KOCRBase( tqparent, spellConfig, KDialogBase::Tabbed ), m_ocrCmd( TQString()), m_orfUrlRequester(0L), m_layoutMode(0), @@ -92,7 +92,7 @@ TQString ocradDialog::ocrEngineDesc() const } -int ocradDialog::layoutDetectionMode() const +int ocradDialog::tqlayoutDetectionMode() const { return m_layoutMode->currentItem(); } @@ -107,7 +107,7 @@ EngineError ocradDialog::setupGui() KConfig *conf = KGlobal::config (); conf->setGroup( CFG_GROUP_OCR_DIA ); - // Horizontal line + //Qt::Horizontal line // (void) new KSeparator( KSeparator::HLine, page); // Entry-Field. @@ -129,20 +129,20 @@ EngineError ocradDialog::setupGui() else m_ocrCmd = res; - /** layout detection button **/ + /** tqlayout detection button **/ conf->setGroup( CFG_GROUP_OCRAD ); - int layoutDetect = conf->readNumEntry( CFG_OCRAD_LAYOUT_DETECTION, 0 ); - kdDebug(28000) << "Layout detection from config: " << layoutDetect << endl; + int tqlayoutDetect = conf->readNumEntry( CFG_OCRAD_LAYOUT_DETECTION, 0 ); + kdDebug(28000) << "Layout detection from config: " << tqlayoutDetect << endl; (void) new KSeparator( KSeparator::HLine, page); TQHBox *hb1 = new TQHBox(page); hb1->setSpacing( KDialog::spacingHint() ); - (void) new TQLabel( i18n("OCRAD layout analysis mode: "), hb1); + (void) new TQLabel( i18n("OCRAD tqlayout analysis mode: "), hb1); m_layoutMode = new TQComboBox(hb1); m_layoutMode->insertItem(i18n("No Layout Detection"), 0 ); m_layoutMode->insertItem(i18n("Column Detection"), 1 ); m_layoutMode->insertItem(i18n("Full Layout Detection"), 2); - m_layoutMode->setCurrentItem(layoutDetect); + m_layoutMode->setCurrentItem(tqlayoutDetect); /** stating the ocrad binary **/ (void) new KSeparator( KSeparator::HLine, page); diff --git a/kooka/kocrocrad.h b/kooka/kocrocrad.h index 828aceed..d33f03a3 100644 --- a/kooka/kocrocrad.h +++ b/kooka/kocrocrad.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -38,7 +38,7 @@ #include "kocrbase.h" #define CFG_GROUP_OCRAD "ocrad" -#define CFG_OCRAD_LAYOUT_DETECTION "layoutDetection" +#define CFG_OCRAD_LAYOUT_DETECTION "tqlayoutDetection" #define CFG_OCRAD_EXTRA_ARGUMENTS "extraArguments" #define CFG_OCRAD_FORMAT "format" #define CFG_OCRAD_CHARSET "charset" @@ -55,6 +55,7 @@ class TQComboBox; class ocradDialog: public KOCRBase { Q_OBJECT + TQ_OBJECT public: ocradDialog( TQWidget*, KSpellConfig* ); ~ocradDialog(); @@ -70,7 +71,7 @@ public: TQString orfUrl() const; - int layoutDetectionMode() const; + int tqlayoutDetectionMode() const; /** * returns the numeric version of the ocrad program. diff --git a/kooka/kooka.cpp b/kooka/kooka.cpp index aea6c2d8..dc05a622 100644 --- a/kooka/kooka.cpp +++ b/kooka/kooka.cpp @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ #include "kooka.h" @@ -96,7 +96,7 @@ Kooka::Kooka( const TQCString& deviceToUse) changeCaption( i18n( "KDE Scanning" )); - setAutoSaveSettings( TQString::fromLatin1("General Options"), + setAutoSaveSettings( TQString::tqfromLatin1("General Options"), true ); } @@ -125,14 +125,14 @@ void Kooka::startup( void ) void Kooka::setupActions() { - KStdAction::print(this, TQT_SLOT(filePrint()), actionCollection()); - KStdAction::quit(this , TQT_SLOT(close()), actionCollection()); + KStdAction::print(TQT_TQOBJECT(this), TQT_SLOT(filePrint()), actionCollection()); + KStdAction::quit(TQT_TQOBJECT(this) , TQT_SLOT(close()), actionCollection()); KStdAction::keyBindings(guiFactory(), TQT_SLOT(configureShortcuts()), actionCollection()); - KStdAction::configureToolbars(this, TQT_SLOT(optionsConfigureToolbars()), + KStdAction::configureToolbars(TQT_TQOBJECT(this), TQT_SLOT(optionsConfigureToolbars()), actionCollection()); - KStdAction::preferences(this, TQT_SLOT(optionsPreferences()), actionCollection()); + KStdAction::preferences(TQT_TQOBJECT(this), TQT_SLOT(optionsPreferences()), actionCollection()); m_view->createDockMenu(actionCollection(), this, "settings_show_docks" ); @@ -161,7 +161,7 @@ actionCollection()); actionCollection(), "scaleOriginal" ); m_view->connectViewerAction( act ); -#ifdef QICONSET_HONOUR_ON_OFF +#ifdef TQICONSET_HONOUR_ON_OFF /* The Toggleaction does not seem to handle the on/off icon from TQIconSet */ TQIconSet lockSet; lockSet.setPixmap(BarIcon("lock") , TQIconSet::Automatic, TQIconSet::Normal, TQIconSet::On ); @@ -180,68 +180,68 @@ actionCollection()); /* thumbview and gallery actions */ act = new KAction(i18n("Set Zoom..."), "viewmag", 0, - m_view, TQT_SLOT( slIVShowZoomDialog()), + TQT_TQOBJECT(m_view), TQT_SLOT( slIVShowZoomDialog()), actionCollection(), "showZoomDialog" ); m_view->connectViewerAction( act ); (void) new KAction(i18n("Create From Selectio&n"), "crop", CTRL+Key_N, - m_view, TQT_SLOT( slCreateNewImgFromSelection() ), + TQT_TQOBJECT(m_view), TQT_SLOT( slCreateNewImgFromSelection() ), actionCollection(), "createFromSelection" ); (void) new KAction(i18n("Mirror Image &Vertically"), "mirror-vert", CTRL+Key_V, - this, TQT_SLOT( slMirrorVertical() ), + TQT_TQOBJECT(this), TQT_SLOT( slMirrorVertical() ), actionCollection(), "mirrorVertical" ); - (void) new KAction(i18n("&Mirror Image Horizontally"), "mirror-horiz", CTRL+Key_M, - this, TQT_SLOT( slMirrorHorizontal() ), + (void) new KAction(i18n("&Mirror ImageQt::Horizontally"), "mirror-horiz", CTRL+Key_M, + TQT_TQOBJECT(this), TQT_SLOT( slMirrorHorizontal() ), actionCollection(), "mirrorHorizontal" ); (void) new KAction(i18n("Mirror Image &Both Directions"), "mirror-both", CTRL+Key_B, - this, TQT_SLOT( slMirrorBoth() ), + TQT_TQOBJECT(this), TQT_SLOT( slMirrorBoth() ), actionCollection(), "mirrorBoth" ); (void) new KAction(i18n("Open Image in &Graphic Application..."), "fileopen", CTRL+Key_G, - m_view, TQT_SLOT( slOpenCurrInGraphApp() ), + TQT_TQOBJECT(m_view), TQT_SLOT( slOpenCurrInGraphApp() ), actionCollection(), "openInGraphApp" ); act = new KAction(i18n("&Rotate Image Clockwise"), "rotate_cw", CTRL+Key_R, - this, TQT_SLOT( slRotateClockWise() ), + TQT_TQOBJECT(this), TQT_SLOT( slRotateClockWise() ), actionCollection(), "rotateClockwise" ); m_view->connectViewerAction( act ); act = new KAction(i18n("Rotate Image Counter-Clock&wise"), "rotate_ccw", CTRL+Key_W, - this, TQT_SLOT( slRotateCounterClockWise() ), + TQT_TQOBJECT(this), TQT_SLOT( slRotateCounterClockWise() ), actionCollection(), "rotateCounterClockwise" ); m_view->connectViewerAction( act ); act = new KAction(i18n("Rotate Image 180 &Degrees"), "rotate", CTRL+Key_D, - this, TQT_SLOT( slRotate180() ), + TQT_TQOBJECT(this), TQT_SLOT( slRotate180() ), actionCollection(), "upsitedown" ); m_view->connectViewerAction( act ); /* Gallery actions */ act = new KAction(i18n("&Create Folder..."), "folder_new", 0, - m_view->gallery(), TQT_SLOT( slotCreateFolder() ), + TQT_TQOBJECT(m_view->gallery()),TQT_SLOT( slotCreateFolder() ), actionCollection(), "foldernew" ); m_view->connectGalleryAction( act ); act = new KAction(i18n("&Save Image..."), "filesave", 0, - m_view->gallery(), TQT_SLOT( slotExportFile() ), + TQT_TQOBJECT(m_view->gallery()),TQT_SLOT( slotExportFile() ), actionCollection(), "saveImage" ); m_view->connectGalleryAction( act ); act = new KAction(i18n("&Import Image..."), "inline_image", 0, - m_view->gallery(), TQT_SLOT( slotImportFile() ), + TQT_TQOBJECT(m_view->gallery()),TQT_SLOT( slotImportFile() ), actionCollection(), "importImage" ); m_view->connectGalleryAction( act ); act = new KAction(i18n("&Delete Image"), "edittrash", 0, - m_view->gallery(), TQT_SLOT( slotDeleteItems() ), + TQT_TQOBJECT(m_view->gallery()),TQT_SLOT( slotDeleteItems() ), actionCollection(), "deleteImage" ); m_view->connectGalleryAction( act ); act = new KAction(i18n("&Unload Image"), "fileclose", 0, - m_view->gallery(), TQT_SLOT( slotUnloadItems() ), + TQT_TQOBJECT(m_view->gallery()),TQT_SLOT( slotUnloadItems() ), actionCollection(), "unloadImage" ); m_view->connectGalleryAction( act ); @@ -257,11 +257,11 @@ actionCollection()); #endif (void) new KAction(i18n("Select Scan Device"), "scanner", 0, - m_view, TQT_SLOT( slSelectDevice()), + TQT_TQOBJECT(m_view), TQT_SLOT( slSelectDevice()), actionCollection(), "selectsource" ); (void) new KAction( i18n("Enable All Warnings && Messages"), 0, - this, TQT_SLOT(slEnableWarnings()), + TQT_TQOBJECT(this), TQT_SLOT(slEnableWarnings()), actionCollection(), "enable_msgs"); @@ -308,7 +308,7 @@ void Kooka::dragEnterEvent(TQDragEnterEvent *event) void Kooka::dropEvent(TQDropEvent *event) { // this is a very simplistic implementation of a drop event. we - // will only accept a dropped URL. the Qt dnd code can do *much* + // will only accept a dropped URL. the TQt dnd code can do *much* // much more, so please read the docs there KURL::List uri; diff --git a/kooka/kooka.h b/kooka/kooka.h index 91a98fea..6fa12078 100644 --- a/kooka/kooka.h +++ b/kooka/kooka.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -55,6 +55,7 @@ class KookaView; class Kooka : public KParts::DockMainWindow { Q_OBJECT + TQ_OBJECT public: /** * Default Constructor @@ -74,7 +75,7 @@ public: protected: /** - * Overridden virtuals for Qt drag 'n drop (XDND) + * Overridden virtuals for TQt drag 'n drop (XDND) */ virtual void dragEnterEvent(TQDragEnterEvent *event); // virtual void dropEvent(TQDropEvent *event); diff --git a/kooka/kookaimage.cpp b/kooka/kookaimage.cpp index 5857440a..a89a97cb 100644 --- a/kooka/kookaimage.cpp +++ b/kooka/kookaimage.cpp @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -167,7 +167,7 @@ bool KookaImage::loadFromUrl( const KURL& url ) #endif if( !haveTiff ) { - /* Qt can only read one image */ + /* TQt can only read one image */ ret = load(filename); if( ret ) { @@ -205,15 +205,15 @@ void KookaImage::extractNow() { kdDebug(28000) << "extracting a subimage number " << m_subNo << endl; - KookaImage *parent = parentImage(); + KookaImage *tqparent = tqparentImage(); - if( parent ) + if( tqparent ) { - loadTiffDir( parent->localFileName(), m_subNo ); + loadTiffDir( tqparent->localFileName(), m_subNo ); } else { - kdDebug(28000) << "ERR: No parent defined - can not laod subimage" << endl; + kdDebug(28000) << "ERR: No tqparent defined - can not laod subimage" << endl; } } @@ -300,7 +300,7 @@ bool KookaImage::loadTiffDir( const TQString& filename, int no ) float yScalefactor = xReso / yReso; kdDebug(28000) << "Different resolution x/y, rescaling with factor " << yScalefactor << endl; /* rescale the image */ - *this = smoothScale( imgWidth, int(imgHeight*yScalefactor), TQImage::ScaleFree ); + *this = smoothScale( imgWidth, int(imgHeight*yScalefactor), TQ_ScaleFree ); } else { @@ -308,7 +308,7 @@ bool KookaImage::loadTiffDir( const TQString& filename, int no ) float scalefactor = yReso / xReso; kdDebug(28000) << "Different resolution x/y, rescaling x with factor " << scalefactor << endl; /* rescale the image */ - *this = smoothScale( int(imgWidth*scalefactor), imgHeight, TQImage::ScaleFree ); + *this = smoothScale( int(imgWidth*scalefactor), imgHeight, TQ_ScaleFree ); } } @@ -328,7 +328,7 @@ KookaImage::~KookaImage() } -KookaImage* KookaImage::parentImage() const +KookaImage* KookaImage::tqparentImage() const { return( m_parent ); } diff --git a/kooka/kookaimage.h b/kooka/kookaimage.h index c75c2dae..53ae5eaf 100644 --- a/kooka/kookaimage.h +++ b/kooka/kookaimage.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -47,15 +47,15 @@ class KFileItem; typedef enum { MaxCut, MediumCut } TileMode; -class KookaImage: public QImage +class KookaImage: public TQImage { public: KookaImage( ); /** - * creating a subimage for a parent image. + * creating a subimage for a tqparent image. * @param subNo contains the sequence number of subimages to create. - * @param p is the parent image. + * @param p is the tqparent image. */ KookaImage( int subNo, KookaImage *p ); KookaImage( const TQImage& img ); @@ -76,9 +76,9 @@ public: int subImagesCount() const; /** - * the parent image. + * the tqparent image. */ - KookaImage* parentImage() const; + KookaImage* tqparentImage() const; /** * returns true if this is a subimage. @@ -144,7 +144,7 @@ private: bool loadTiffDir( const TQString&, int ); /* if subNo is 0, the image is the one and only. If it is larger than 0, the - * parent contains the filename */ + * tqparent contains the filename */ int m_subNo; /* In case being a subimage */ diff --git a/kooka/kookaimagemeta.cpp b/kooka/kookaimagemeta.cpp index 7ba1963d..cac78bdc 100644 --- a/kooka/kookaimagemeta.cpp +++ b/kooka/kookaimagemeta.cpp @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ diff --git a/kooka/kookaimagemeta.h b/kooka/kookaimagemeta.h index fd269ddd..7b090037 100644 --- a/kooka/kookaimagemeta.h +++ b/kooka/kookaimagemeta.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ diff --git a/kooka/kookapref.cpp b/kooka/kookapref.cpp index 06274670..b453045a 100644 --- a/kooka/kookapref.cpp +++ b/kooka/kookapref.cpp @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -149,7 +149,7 @@ void KookaPreferences::setupOCRPage() #endif top->addWidget( kgp ); TQWidget *spaceEater = new TQWidget( page ); - spaceEater->setSizePolicy( TQSizePolicy( TQSizePolicy::Ignored, TQSizePolicy::Ignored )); + spaceEater->tqsetSizePolicy( TQSizePolicy( TQSizePolicy::Ignored, TQSizePolicy::Ignored )); top->addWidget( spaceEater ); /* @@ -176,17 +176,17 @@ void KookaPreferences::setupOCRPage() } } -KURLRequester* KookaPreferences::binaryCheckBox( TQWidget *parent, const TQString& program ) +KURLRequester* KookaPreferences::binaryCheckBox( TQWidget *tqparent, const TQString& program ) { - TQHBox *hbox = new TQHBox( parent ); + TQHBox *hbox = new TQHBox( tqparent ); - (void) new TQLabel( i18n("Select the %1 binary to use:").arg( program ), hbox ); - KURLRequester* urlRequester = new KURLRequester( parent ); + (void) new TQLabel( i18n("Select the %1 binary to use:").tqarg( program ), hbox ); + KURLRequester* urlRequester = new KURLRequester( tqparent ); urlRequester->setMode( KFile::File | KFile::ExistingOnly | KFile::LocalOnly ); TQToolTip::add( urlRequester, i18n( "Enter the path to %1, the optical-character-recognition " - "command line tool.").arg(program)); + "command line tool.").tqarg(program)); return urlRequester; } @@ -207,7 +207,7 @@ TQString KookaPreferences::tryFindBinary( const TQString& bin, const TQString& c if( res != "notFound" ) { TQFileInfo fi( res ); - if( fi.exists() && fi.isExecutable() && !fi.isDir() && res.contains(bin) ) + if( fi.exists() && fi.isExecutable() && !fi.isDir() && res.tqcontains(bin) ) { return res; } @@ -272,7 +272,7 @@ void KookaPreferences::checkOCRBinarySilent( const TQString& cmd ) #endif bool KookaPreferences::checkOCRBinIntern( const TQString& cmd, const TQString& tool, bool show_msg ) { - if( ! cmd.contains( tool )) return false; + if( ! cmd.tqcontains( tool )) return false; bool ret = true; TQFileInfo fi( cmd ); @@ -316,7 +316,7 @@ void KookaPreferences::setupStartupPage() /* Query for network scanner (Checkbox) */ cbNetQuery = new TQCheckBox( i18n("Query network for available scanners"), - page, "CB_NET_QUERY" ); + page, "CB_NET_TQUERY" ); TQToolTip::add( cbNetQuery, i18n( "Check this if you want a network query for available scanners.\nNote that this does not mean a query over the entire network but only the stations configured for SANE!" )); cbNetQuery->setChecked( ! (konf->readBoolEntry( STARTUP_ONLY_LOCAL, false )) ); @@ -356,7 +356,7 @@ void KookaPreferences::setupSaveFormatPage( ) /* Skip the format asking if a format entry exists */ cbSkipFormatAsk = new TQCheckBox( i18n("Always display image save assistant"), - page, "CB_IMGASSIST_QUERY" ); + page, "CB_IMGASSIST_TQUERY" ); cbSkipFormatAsk->setChecked( konf->readBoolEntry( OP_FILE_ASK_FORMAT, true )); TQToolTip::add( cbSkipFormatAsk, i18n("Check this if you want to see the image save assistant even if there is a default format for the image type." )); top->addWidget( cbSkipFormatAsk ); @@ -418,8 +418,8 @@ void KookaPreferences::setupThumbnailPage() /* Frame Stuff */ int frameWidth = konf->readNumEntry( THUMB_MARGIN, 3 ); - TQColor col1 = konf->readColorEntry( MARGIN_COLOR1, &(colorGroup().base())); - TQColor col2 = konf->readColorEntry( MARGIN_COLOR2, &(colorGroup().foreground())); + TQColor col1 = konf->readColorEntry( MARGIN_COLOR1, &(tqcolorGroup().base())); + TQColor col2 = konf->readColorEntry( MARGIN_COLOR2, &(tqcolorGroup().foreground())); TQGrid *fGrid = new TQGrid( 2, hgb3 ); fGrid->setSpacing( 2 ); @@ -457,7 +457,7 @@ void KookaPreferences::slotApply( void ) /* ** startup options ** */ /** write the global one, to read from libkscan also */ - konf->setGroup(TQString::fromLatin1(GROUP_STARTUP)); + konf->setGroup(TQString::tqfromLatin1(GROUP_STARTUP)); bool cbVal = !(cbShowScannerSelection->isChecked()); kdDebug(28000) << "Writing for " << STARTUP_SKIP_ASK << ": " << cbVal << endl; konf->writeEntry( STARTUP_SKIP_ASK, cbVal, true, true ); /* global flag goes to kdeglobals */ @@ -532,8 +532,8 @@ void KookaPreferences::slotDefault( void ) m_tileSelector->setURL( KURL(bgImg) ); m_thumbWidth->setValue( 100 ); m_thumbHeight->setValue( 120 ); - TQColor col1 = TQColor( colorGroup().base()); - TQColor col2 = TQColor( colorGroup().foreground()); + TQColor col1 = TQColor( tqcolorGroup().base()); + TQColor col2 = TQColor( tqcolorGroup().foreground()); m_frameWidth->setValue( 3 ); m_colButt1->setColor( col1 ); diff --git a/kooka/kookapref.h b/kooka/kookapref.h index 46f27bb4..e199fabd 100644 --- a/kooka/kookapref.h +++ b/kooka/kookapref.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ #ifndef KOOKAPREF_H @@ -47,6 +47,7 @@ class TQCheckBox; class KookaPreferences : public KDialogBase { Q_OBJECT + TQ_OBJECT public: KookaPreferences(); static TQString tryFindGocr( void ); diff --git a/kooka/kookaprint.cpp b/kooka/kookaprint.cpp index 5dad1f33..829cd8a5 100644 --- a/kooka/kookaprint.cpp +++ b/kooka/kookaprint.cpp @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -112,7 +112,7 @@ bool KookaPrint::printImage( KookaImage *img ) kdDebug(28000) << "Scaling to printer size " << newWidth << " x " << newHeight << endl; - tmpImg = img->smoothScale(newWidth, newHeight, TQImage::ScaleFree); + tmpImg = img->smoothScale(newWidth, newHeight, TQ_ScaleFree); TQSize sz = tmpImg.size(); // the current image size TQSize maxOnPage = maxPageSize(); // the maximum space on one side @@ -177,7 +177,7 @@ void KookaPrint::printFittingToPage(KookaImage *img) newHeight = int( double( img->height() ) * hAspect ); } - tmpImg = img->smoothScale(newWidth, newHeight, TQImage::ScaleFree); + tmpImg = img->smoothScale(newWidth, newHeight, TQ_ScaleFree); m_painter->drawImage( 0,0, tmpImg ); @@ -201,7 +201,7 @@ void KookaPrint::drawCutSign( const TQPoint& p, int num, MarkerDirection dir ) int start = 0; const int radius=20; - TQColor brushColor( Qt::red ); + TQColor brushColor( TQt::red ); int toffX=0; int toffY=0; TQString numStr = TQString::number(num); @@ -215,7 +215,7 @@ void KookaPrint::drawCutSign( const TQPoint& p, int num, MarkerDirection dir ) { case SW: start = -90; - brushColor = Qt::green; + brushColor = TQt::green; toffX =-1; toffY = 1; textXOff = -1*textWidth; @@ -223,7 +223,7 @@ void KookaPrint::drawCutSign( const TQPoint& p, int num, MarkerDirection dir ) break; case NW: start = -180; - brushColor = Qt::blue; + brushColor = TQt::blue; toffX =-1; toffY =-1; textXOff = -1*textWidth; @@ -231,7 +231,7 @@ void KookaPrint::drawCutSign( const TQPoint& p, int num, MarkerDirection dir ) break; case NO: start = -270; - brushColor = Qt::yellow; + brushColor = TQt::yellow; toffX = 1; toffY = -1; textXOff = -1*textWidth; @@ -240,7 +240,7 @@ void KookaPrint::drawCutSign( const TQPoint& p, int num, MarkerDirection dir ) break; case SO: start = 0; - brushColor = Qt::magenta; + brushColor = TQt::magenta; toffX = 1; toffY = 1; textXOff = -1*textWidth; diff --git a/kooka/kookaprint.h b/kooka/kookaprint.h index 0373b642..d1470251 100644 --- a/kooka/kookaprint.h +++ b/kooka/kookaprint.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -52,9 +52,10 @@ private: }; -class KookaPrint:public QObject +class KookaPrint:public TQObject { Q_OBJECT + TQ_OBJECT public: KookaPrint(KPrinter*); diff --git a/kooka/kookarc b/kooka/kookarc index 13875fff..a604a280 100644 --- a/kooka/kookarc +++ b/kooka/kookarc @@ -2,17 +2,17 @@ Kookas MainDock,Preview ,Thumbs:first_name=Kookas MainDock,Preview\s Kookas MainDock,Preview ,Thumbs:last_name=Thumbs Kookas MainDock,Preview ,Thumbs:orientation=0 -Kookas MainDock,Preview ,Thumbs:parent=yes +Kookas MainDock,Preview ,Thumbs:tqparent=yes Kookas MainDock,Preview ,Thumbs:sepPos=72 Kookas MainDock,Preview ,Thumbs:stayButton=false Kookas MainDock,Preview ,Thumbs:type=GROUP Kookas MainDock,Preview :curTab=0 -Kookas MainDock,Preview :parent=yes +Kookas MainDock,Preview :tqparent=yes Kookas MainDock,Preview :stayButton=false Kookas MainDock,Preview :tabNames=Kookas MainDock,Preview\s Kookas MainDock,Preview :type=TAB_GROUP Kookas MainDock,Thumbs,Preview :curTab=1 -Kookas MainDock,Thumbs,Preview :parent=yes +Kookas MainDock,Thumbs,Preview :tqparent=yes Kookas MainDock,Thumbs,Preview :stayButton=false Kookas MainDock,Thumbs,Preview :tabNames=Kookas MainDock,Thumbs,Preview\s Kookas MainDock,Thumbs,Preview :type=TAB_GROUP @@ -20,7 +20,7 @@ Kookas MainDock,Thumbs:curTab=1 Kookas MainDock,Thumbs:first_name=Kookas MainDock Kookas MainDock,Thumbs:last_name=Thumbs Kookas MainDock,Thumbs:orientation=0 -Kookas MainDock,Thumbs:parent=yes +Kookas MainDock,Thumbs:tqparent=yes Kookas MainDock,Thumbs:sepPos=54 Kookas MainDock,Thumbs:stayButton=false Kookas MainDock,Thumbs:tabNames=Kookas MainDock,Thumbs @@ -35,28 +35,28 @@ NameList=Kookas MainDock,Thumbs,Scanpackager,Recent,Scan Parameter,Preview ,Kook Preview ,Scanpackager,Recent,Scan Parameter,Kookas MainDock,Thumbs:first_name=Preview ,Scanpackager,Recent,Scan Parameter Preview ,Scanpackager,Recent,Scan Parameter,Kookas MainDock,Thumbs:last_name=Kookas MainDock,Thumbs Preview ,Scanpackager,Recent,Scan Parameter,Kookas MainDock,Thumbs:orientation=1 -Preview ,Scanpackager,Recent,Scan Parameter,Kookas MainDock,Thumbs:parent=yes +Preview ,Scanpackager,Recent,Scan Parameter,Kookas MainDock,Thumbs:tqparent=yes Preview ,Scanpackager,Recent,Scan Parameter,Kookas MainDock,Thumbs:sepPos=38 Preview ,Scanpackager,Recent,Scan Parameter,Kookas MainDock,Thumbs:stayButton=false Preview ,Scanpackager,Recent,Scan Parameter,Kookas MainDock,Thumbs:type=GROUP Preview ,Scanpackager,Recent,Scan Parameter:first_name=Preview ,Scanpackager,Recent Preview ,Scanpackager,Recent,Scan Parameter:last_name=Scan Parameter Preview ,Scanpackager,Recent,Scan Parameter:orientation=0 -Preview ,Scanpackager,Recent,Scan Parameter:parent=yes +Preview ,Scanpackager,Recent,Scan Parameter:tqparent=yes Preview ,Scanpackager,Recent,Scan Parameter:sepPos=50 Preview ,Scanpackager,Recent,Scan Parameter:stayButton=false Preview ,Scanpackager,Recent,Scan Parameter:type=GROUP Preview ,Scanpackager,Recent:first_name=Preview ,Scanpackager Preview ,Scanpackager,Recent:last_name=Recent Preview ,Scanpackager,Recent:orientation=0 -Preview ,Scanpackager,Recent:parent=yes +Preview ,Scanpackager,Recent:tqparent=yes Preview ,Scanpackager,Recent:sepPos=84 Preview ,Scanpackager,Recent:stayButton=false Preview ,Scanpackager,Recent:type=GROUP Preview ,Scanpackager:first_name=Preview\s Preview ,Scanpackager:last_name=Scanpackager Preview ,Scanpackager:orientation=0 -Preview ,Scanpackager:parent=yes +Preview ,Scanpackager:tqparent=yes Preview ,Scanpackager:sepPos=50 Preview ,Scanpackager:stayButton=false Preview ,Scanpackager:type=GROUP @@ -65,7 +65,7 @@ Preview :type=DOCK Recent,Scan Parameter:first_name=Recent Recent,Scan Parameter:last_name=Scan Parameter Recent,Scan Parameter:orientation=0 -Recent,Scan Parameter:parent=yes +Recent,Scan Parameter:tqparent=yes Recent,Scan Parameter:sepPos=14 Recent,Scan Parameter:stayButton=false Recent,Scan Parameter:type=GROUP @@ -76,40 +76,40 @@ Scan Parameter:type=DOCK Scanpackager,Preview ,Recent,Scan Parameter,Kookas MainDock,Thumbs:first_name=Scanpackager,Preview ,Recent,Scan Parameter Scanpackager,Preview ,Recent,Scan Parameter,Kookas MainDock,Thumbs:last_name=Kookas MainDock,Thumbs Scanpackager,Preview ,Recent,Scan Parameter,Kookas MainDock,Thumbs:orientation=1 -Scanpackager,Preview ,Recent,Scan Parameter,Kookas MainDock,Thumbs:parent=yes +Scanpackager,Preview ,Recent,Scan Parameter,Kookas MainDock,Thumbs:tqparent=yes Scanpackager,Preview ,Recent,Scan Parameter,Kookas MainDock,Thumbs:sepPos=38 Scanpackager,Preview ,Recent,Scan Parameter,Kookas MainDock,Thumbs:stayButton=false Scanpackager,Preview ,Recent,Scan Parameter,Kookas MainDock,Thumbs:type=GROUP Scanpackager,Preview ,Recent,Scan Parameter:first_name=Scanpackager,Preview\s Scanpackager,Preview ,Recent,Scan Parameter:last_name=Recent,Scan Parameter Scanpackager,Preview ,Recent,Scan Parameter:orientation=0 -Scanpackager,Preview ,Recent,Scan Parameter:parent=yes +Scanpackager,Preview ,Recent,Scan Parameter:tqparent=yes Scanpackager,Preview ,Recent,Scan Parameter:sepPos=48 Scanpackager,Preview ,Recent,Scan Parameter:stayButton=false Scanpackager,Preview ,Recent,Scan Parameter:type=GROUP Scanpackager,Preview :curTab=0 -Scanpackager,Preview :parent=yes +Scanpackager,Preview :tqparent=yes Scanpackager,Preview :stayButton=false Scanpackager,Preview :tabNames=Scanpackager,Preview\s Scanpackager,Preview :type=TAB_GROUP Scanpackager,Recent,Scan Parameter,Kookas MainDock,Preview ,Thumbs:first_name=Scanpackager,Recent,Scan Parameter Scanpackager,Recent,Scan Parameter,Kookas MainDock,Preview ,Thumbs:last_name=Kookas MainDock,Preview ,Thumbs Scanpackager,Recent,Scan Parameter,Kookas MainDock,Preview ,Thumbs:orientation=1 -Scanpackager,Recent,Scan Parameter,Kookas MainDock,Preview ,Thumbs:parent=yes +Scanpackager,Recent,Scan Parameter,Kookas MainDock,Preview ,Thumbs:tqparent=yes Scanpackager,Recent,Scan Parameter,Kookas MainDock,Preview ,Thumbs:sepPos=41 Scanpackager,Recent,Scan Parameter,Kookas MainDock,Preview ,Thumbs:stayButton=false Scanpackager,Recent,Scan Parameter,Kookas MainDock,Preview ,Thumbs:type=GROUP Scanpackager,Recent,Scan Parameter,Kookas MainDock,Thumbs,Preview :first_name=Scanpackager,Recent,Scan Parameter Scanpackager,Recent,Scan Parameter,Kookas MainDock,Thumbs,Preview :last_name=Kookas MainDock,Thumbs,Preview\s Scanpackager,Recent,Scan Parameter,Kookas MainDock,Thumbs,Preview :orientation=1 -Scanpackager,Recent,Scan Parameter,Kookas MainDock,Thumbs,Preview :parent=yes +Scanpackager,Recent,Scan Parameter,Kookas MainDock,Thumbs,Preview :tqparent=yes Scanpackager,Recent,Scan Parameter,Kookas MainDock,Thumbs,Preview :sepPos=38 Scanpackager,Recent,Scan Parameter,Kookas MainDock,Thumbs,Preview :stayButton=false Scanpackager,Recent,Scan Parameter,Kookas MainDock,Thumbs,Preview :type=GROUP Scanpackager,Recent,Scan Parameter:first_name=Scanpackager Scanpackager,Recent,Scan Parameter:last_name=Recent,Scan Parameter Scanpackager,Recent,Scan Parameter:orientation=0 -Scanpackager,Recent,Scan Parameter:parent=yes +Scanpackager,Recent,Scan Parameter:tqparent=yes Scanpackager,Recent,Scan Parameter:sepPos=42 Scanpackager,Recent,Scan Parameter:stayButton=false Scanpackager,Recent,Scan Parameter:type=GROUP diff --git a/kooka/kookaview.cpp b/kooka/kookaview.cpp index 2843535f..fb0d57fc 100644 --- a/kooka/kookaview.cpp +++ b/kooka/kookaview.cpp @@ -21,8 +21,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -82,7 +82,7 @@ #define STARTUP_IMG_SELECTION "SelectedImageOnStartup" -KookaView::KookaView( KParts::DockMainWindow *parent, const TQCString& deviceToUse) +KookaView::KookaView( KParts::DockMainWindow *tqparent, const TQCString& deviceToUse) : TQObject(), m_ocrResultImg(0), ocrFabric(0), @@ -93,21 +93,21 @@ KookaView::KookaView( KParts::DockMainWindow *parent, const TQCString& deviceToU m_dockRecent(0), m_dockPreview(0), m_dockOCRText(0), - m_mainWindow(parent), + m_mainWindow(tqparent), m_ocrResEdit(0) { KIconLoader *loader = KGlobal::iconLoader(); scan_params = 0L; preview_canvas = 0L; - m_mainDock = parent->createDockWidget( "Kookas MainDock", + m_mainDock = tqparent->createDockWidget( "Kookas MainDock", loader->loadIcon( "folder_image", KIcon::Small ), 0L, i18n("Image Viewer")); m_mainDock->setEnableDocking(KDockWidget::DockNone ); m_mainDock->setDockSite( KDockWidget::DockFullSite ); - parent->setView( m_mainDock); - parent->setMainDockWidget( m_mainDock); + tqparent->setView( m_mainDock); + tqparent->setMainDockWidget( m_mainDock); img_canvas = new ImageCanvas( m_mainDock ); img_canvas->setMinimumSize(100,200); @@ -121,7 +121,7 @@ KookaView::KookaView( KParts::DockMainWindow *parent, const TQCString& deviceToU m_mainDock->setWidget( img_canvas ); /** Thumbview **/ - m_dockThumbs = parent->createDockWidget( "Thumbs", + m_dockThumbs = tqparent->createDockWidget( "Thumbs", loader->loadIcon( "thumbnail", KIcon::Small ), 0L, i18n("Thumbnails")); m_dockThumbs->setDockSite(KDockWidget::DockFullSite ); @@ -136,7 +136,7 @@ KookaView::KookaView( KParts::DockMainWindow *parent, const TQCString& deviceToU /** Packager Dock **/ /* A new packager to contain the already scanned images */ - m_dockPackager = parent->createDockWidget( "Scanpackager", + m_dockPackager = tqparent->createDockWidget( "Scanpackager", loader->loadIcon( "palette_color", KIcon::Small ), 0L, i18n("Gallery")); m_dockPackager->setDockSite(KDockWidget::DockFullSite); @@ -155,7 +155,7 @@ KookaView::KookaView( KParts::DockMainWindow *parent, const TQCString& deviceToU /* * Create a Kombobox that holds the last folders visible even on the preview page */ - m_dockRecent = parent->createDockWidget( "Recent", + m_dockRecent = tqparent->createDockWidget( "Recent", loader->loadIcon( "image", KIcon::Small ), 0L, i18n("Gallery Folders")); @@ -164,7 +164,7 @@ KookaView::KookaView( KParts::DockMainWindow *parent, const TQCString& deviceToU TQHBox *recentBox = new TQHBox( m_dockRecent ); recentBox->setMargin(KDialog::marginHint()); TQLabel *lab = new TQLabel( i18n("Gallery:"), recentBox ); - lab->setSizePolicy( TQSizePolicy(TQSizePolicy::Fixed, TQSizePolicy::Fixed) ); + lab->tqsetSizePolicy( TQSizePolicy(TQSizePolicy::Fixed, TQSizePolicy::Fixed) ); recentFolder = new ImageNameCombo( recentBox ); m_dockRecent->setWidget( recentBox ); @@ -184,14 +184,14 @@ KookaView::KookaView( KParts::DockMainWindow *parent, const TQCString& deviceToU packager, TQT_SLOT(slotSelectDirectory( const TQString& ))); /* the object from the kscan lib to handle low level scanning */ - m_dockScanParam = parent->createDockWidget( "Scan Parameter", + m_dockScanParam = tqparent->createDockWidget( "Scan Parameter", loader->loadIcon( "folder", KIcon::Small ), 0L, i18n("Scan Parameter")); // m_dockScanParam->setDockSite(KDockWidget::DockFullSite); m_dockScanParam->setWidget( 0 ); // later - sane = new KScanDevice( m_dockScanParam ); + sane = new KScanDevice( TQT_TQOBJECT(m_dockScanParam) ); Q_CHECK_PTR(sane); m_dockScanParam->manualDock( m_dockRecent, // dock target @@ -203,7 +203,7 @@ KookaView::KookaView( KParts::DockMainWindow *parent, const TQCString& deviceToU * the complete scanner options dialog * scan_params must be zero for that */ - m_dockPreview = parent->createDockWidget( "Preview ", + m_dockPreview = tqparent->createDockWidget( "Preview ", loader->loadIcon( "viewmag", KIcon::Small ), 0L, i18n("Scan Preview")); @@ -222,7 +222,7 @@ KookaView::KookaView( KParts::DockMainWindow *parent, const TQCString& deviceToU /* Create a text editor part for ocr results */ - m_dockOCRText = parent->createDockWidget( "OCRResults", + m_dockOCRText = tqparent->createDockWidget( "OCRResults", loader->loadIcon("edit", KIcon::Small ), 0L, i18n("OCR Result Text")); // m_textEdit @@ -235,7 +235,7 @@ KookaView::KookaView( KParts::DockMainWindow *parent, const TQCString& deviceToU KDockWidget::DockCenter, // dock site 100 ); // relation target/this (in percent) - m_ocrResEdit->setTextFormat( Qt::PlainText ); + m_ocrResEdit->setTextFormat( TQt::PlainText ); m_ocrResEdit->setWordWrap( TQTextEdit::NoWrap ); // m_dockOCRText->hide(); } @@ -277,7 +277,7 @@ KookaView::KookaView( KParts::DockMainWindow *parent, const TQCString& deviceToU packager->openRoots(); - /* Status Bar */ + /* tqStatus Bar */ KStatusBar *statBar = m_mainWindow->statusBar(); // statBar->insertItem(TQString("1"), SBAR_ZOOM, 0, true ); @@ -472,7 +472,7 @@ void KookaView::print() printer.setUsePrinterResolution(true); printer.addDialogPage( new ImgPrintDialog( img )); - if( printer.setup( m_mainWindow, i18n("Print %1").arg(img->localFileName().section('/', -1)) )) + if( printer.setup( m_mainWindow, i18n("Print %1").tqarg(img->localFileName().section('/', -1)) )) { KookaPrint kookaprint( &printer ); kookaprint.printImage(img); @@ -564,8 +564,8 @@ void KookaView::startOCR( KookaImage *img ) connect( ocrFabric, TQT_SIGNAL( newOCRResultText( const TQString& )), m_dockOCRText, TQT_SLOT( show() )); - connect( ocrFabric, TQT_SIGNAL( repaintOCRResImage( )), - img_canvas, TQT_SLOT(repaint())); + connect( ocrFabric, TQT_SIGNAL( tqrepaintOCRResImage( )), + img_canvas, TQT_SLOT(tqrepaint())); connect( ocrFabric, TQT_SIGNAL( clearOCRResultText()), m_ocrResEdit, TQT_SLOT(clear())); @@ -626,7 +626,7 @@ void KookaView::slScanStart( ) KLed *led = scan_params->operationLED(); if( led ) { - led->setColor( Qt::red ); + led->setColor( TQt::red ); led->setState( KLed::On ); } } @@ -640,7 +640,7 @@ void KookaView::slAcquireStart( ) KLed *led = scan_params->operationLED(); if( led ) { - led->setColor( Qt::green ); + led->setColor( TQt::green ); } } } @@ -663,7 +663,7 @@ void KookaView::slScanFinished( KScanStat stat ) KLed *led = scan_params->operationLED(); if( led ) { - led->setColor( Qt::green ); + led->setColor( TQt::green ); led->setState( KLed::Off ); } } @@ -842,7 +842,7 @@ void KookaView::slShowAImage( KookaImage *img ) ocrFabric->slSetImage( img ); } - /* Status Bar */ + /* tqStatus Bar */ KStatusBar *statBar = m_mainWindow->statusBar(); if( img_canvas ) statBar->changeItem( img_canvas->imageInfoString(), StatusImage ); @@ -876,7 +876,7 @@ void KookaView::slShowThumbnails(KFileTreeViewItem *dirKfi, bool forceRedraw ) } else { - kftvi = static_cast(static_cast(kftvi)->parent()); + kftvi = static_cast(static_cast(kftvi)->tqparent()); dirKfi = kftvi; forceRedraw = true; packager->setSelected( static_cast(dirKfi), true ); @@ -913,7 +913,7 @@ void KookaView::slShowThumbnails(KFileTreeViewItem *dirKfi, bool forceRedraw ) */ void KookaView::slStartLoading( const KURL& url ) { - emit( signalChangeStatusbar( i18n("Loading %1" ).arg( url.prettyURL() ) )); + emit( signalChangeStatusbar( i18n("Loading %1" ).tqarg( url.prettyURL() ) )); // if( m_stack->visibleWidget() != img_canvas ) // { diff --git a/kooka/kookaview.h b/kooka/kookaview.h index 10017e88..21d5509a 100644 --- a/kooka/kookaview.h +++ b/kooka/kookaview.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ #ifndef KOOKAVIEW_H @@ -66,9 +66,10 @@ class ocrResEdit; * @author Klaas Freitag * @version 0.1 */ -class KookaView : public QObject +class KookaView : public TQObject { Q_OBJECT + TQ_OBJECT public: typedef enum { MirrorVertical, MirrorHorizontal, MirrorBoth } MirrorType; typedef enum { StatusTemp, StatusImage } StatusBarIDs; @@ -76,7 +77,7 @@ public: /** * Default constructor */ - KookaView(KParts::DockMainWindow *parent, const TQCString& deviceToUse); + KookaView(KParts::DockMainWindow *tqparent, const TQCString& deviceToUse); /** * Destructor diff --git a/kooka/ksaneocr.cpp b/kooka/ksaneocr.cpp index 365624c6..709b1f1f 100644 --- a/kooka/ksaneocr.cpp +++ b/kooka/ksaneocr.cpp @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -183,26 +183,26 @@ void KSANEOCR::slLineBox( const TQRect& ) * starts visual ocr process. Depending on the ocr engine, this function creates * a new dialog, and shows it. */ -bool KSANEOCR::startOCRVisible( TQWidget *parent ) +bool KSANEOCR::startOCRVisible( TQWidget *tqparent ) { if( visibleOCRRunning ) return( false ); bool res = true; - m_parent = parent; + m_parent = tqparent; if( m_ocrEngine == GOCR ) { - m_ocrProcessDia = new KGOCRDialog ( parent, m_spellInitialConfig ); + m_ocrProcessDia = new KGOCRDialog ( tqparent, m_spellInitialConfig ); } else if( m_ocrEngine == OCRAD ) { - m_ocrProcessDia = new ocradDialog( parent, m_spellInitialConfig ); + m_ocrProcessDia = new ocradDialog( tqparent, m_spellInitialConfig ); } else if( m_ocrEngine == KADMOS ) { #ifdef HAVE_KADMOS /*** Kadmos Engine OCR ***/ - m_ocrProcessDia = new KadmosDialog( parent, m_spellInitialConfig ); + m_ocrProcessDia = new KadmosDialog( tqparent, m_spellInitialConfig ); #else KMessageBox::sorry(0, i18n("This version of Kooka was not compiled with KADMOS support.\n" "Please select another OCR engine in Kooka's options dialog.")); @@ -399,9 +399,9 @@ void KSANEOCR::startOCRAD( ) *daemon << cmd; *daemon << TQString("-x"); *daemon << m_tmpOrfName; // the orf result file - *daemon << TQFile::encodeName( m_ocrImagePBM ); // The name of the image + *daemon << TQFile::encodeName( m_ocrImagePBM ).data(); // The name of the image *daemon << TQString("-l"); - *daemon << TQString::number( ocrDia->layoutDetectionMode()); + *daemon << TQString::number( ocrDia->tqlayoutDetectionMode()); KConfig *konf = KGlobal::config (); KConfigGroupSaver( konf, CFG_GROUP_OCRAD ); @@ -543,7 +543,7 @@ void KSANEOCR::startOCRProcess( void ) this, TQT_SLOT( gocrStdErr(KProcess*, char*, int))); TQString opt; - *daemon << TQFile::encodeName(cmd); + *daemon << TQFile::encodeName(cmd).data(); *daemon << "-x"; *daemon << "-"; if( !( m_img->numColors() > 0 && m_img->numColors() <3 )) /* not a bw-image */ @@ -566,7 +566,7 @@ void KSANEOCR::startOCRProcess( void ) // Unfortunately this is fixed by gocr. m_ocrResultImage = "out30.bmp"; - *daemon << TQFile::encodeName(tmpFile); + *daemon << TQFile::encodeName(tmpFile).data(); m_ocrCurrLine = 0; // Important in gocrStdIn to store the results @@ -631,7 +631,7 @@ void KSANEOCR::startOCRProcess( void ) // rep.Recognize(); m_rep.run(); - /* Dealing with threads or no threads (using QT_THREAD_SUPPORT to distinguish) + /* Dealing with threads or no threads (using TQT_THREAD_SUPPORT to distinguish) * If threads are here, the recognition task is started in its own thread. The gui thread * needs to wait until the recognition thread is finished. Therefore, a timer is fired once * that calls slotKadmosResult and checks if the recognition task is finished. If it is not, @@ -647,7 +647,7 @@ void KSANEOCR::startOCRProcess( void ) * It does not :( That is why it is not used here. Maybe some day... */ } -#ifdef QT_THREAD_SUPPORT +#ifdef TQT_THREAD_SUPPORT /* start a timer and wait until it fires. */ TQTimer::singleShot( 500, this, TQT_SLOT( slotKadmosResult() )); #else @@ -660,7 +660,7 @@ void KSANEOCR::startOCRProcess( void ) /* * This method is called to check if the kadmos process was already finished, if - * thread support is enabled (check for preprocessor variable QT_THREAD_SUPPORT) + * thread support is enabled (check for preprocessor variable TQT_THREAD_SUPPORT) * The problem is that the kadmos library seems not to be thread stable so thread * support should not be enabled by default. In case threads are enabled, this slot * checks if the KADMOS engine is finished already and if not it fires a timer. @@ -814,11 +814,11 @@ bool KSANEOCR::readORF( const TQString& fileName, TQString& errStr ) TQFileInfo fi( fileName ); if( ! fi.exists() ) { error = true; - errStr = i18n("The orf %1 does not exist.").arg(fileName); + errStr = i18n("The orf %1 does not exist.").tqarg(fileName); } if( ! error && ! fi.isReadable() ) { error = true; - errStr = i18n("Permission denied on file %1.").arg(fileName); + errStr = i18n("Permission denied on file %1.").tqarg(fileName); } @@ -890,7 +890,7 @@ bool KSANEOCR::readORF( const TQString& fileName, TQString& errStr ) { /* Read one line per character */ TQString charLine = stream.readLine(); - int semiPos = charLine.find(';'); + int semiPos = charLine.tqfind(';'); if( semiPos == -1 ) { kdDebug(28000) << "invalid line: " << charLine << endl; @@ -906,7 +906,7 @@ bool KSANEOCR::readORF( const TQString& fileName, TQString& errStr ) // find the amount of alternatives. int altCount = 0; - int h = results.find(','); // search the first comma + int h = results.tqfind(','); // search the first comma if( h > -1 ) { // kdDebug(28000) << "Results of count search: " << results.left(h) << endl; altCount = results.left(h).toInt(); @@ -1127,7 +1127,7 @@ bool KSANEOCR::eventFilter( TQObject *object, TQEvent *event ) { if( event->type() == TQEvent::MouseButtonDblClick ) { - TQMouseEvent *mev = static_cast(event); + TQMouseEvent *mev = TQT_TQMOUSEEVENT(event); int x = mev->x(); int y = mev->y(); @@ -1328,7 +1328,7 @@ void KSANEOCR::slMisspelling( const TQString& originalword, const TQStringList& /* draw a line under the word to check */ /* copy the source */ - emit repaintOCRResImage(); + emit tqrepaintOCRResImage(); } else { diff --git a/kooka/ksaneocr.h b/kooka/ksaneocr.h index fabb25e8..4996819a 100644 --- a/kooka/ksaneocr.h +++ b/kooka/ksaneocr.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -72,16 +72,17 @@ class KConfig; */ typedef enum{ ENG_ERROR, ENG_OK, ENG_DATA_MISSING, ENG_BAD_SETUP } EngineError; -class KSANEOCR : public QObject +class KSANEOCR : public TQObject { Q_OBJECT + TQ_OBJECT public: enum OCREngines{ GOCR, OCRAD, KADMOS }; KSANEOCR( TQWidget*, KConfig *); ~KSANEOCR(); - bool startOCRVisible( TQWidget* parent=0); + bool startOCRVisible( TQWidget* tqparent=0); void finishedOCRVisible( bool ); @@ -161,7 +162,7 @@ signals: /** * signal the tells that the result image was modified. */ - void repaintOCRResImage( ); + void tqrepaintOCRResImage( ); /** * indicates that the text editor holding the text that came through diff --git a/kooka/main.cpp b/kooka/main.cpp index 67f014c9..f0f3c32a 100644 --- a/kooka/main.cpp +++ b/kooka/main.cpp @@ -21,8 +21,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -58,8 +58,8 @@ static const char license[] = "Kreuzlingen and distribute the resulting executable without\n" "including the source code for KADMOS in the source distribution.\n\n" "As a special exception, permission is given to link this program\n" -"with any edition of Qt, and distribute the resulting executable,\n" -"without including the source code for Qt in the source distribution.\n"; +"with any edition of TQt, and distribute the resulting executable,\n" +"without including the source code for TQt in the source distribution.\n"; static KCmdLineOptions options[] = diff --git a/kooka/ocrresedit.cpp b/kooka/ocrresedit.cpp index a8d842a1..8465d09c 100644 --- a/kooka/ocrresedit.cpp +++ b/kooka/ocrresedit.cpp @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ #include @@ -36,8 +36,8 @@ /* -------------------- ocrResEdit -------------------- */ -ocrResEdit::ocrResEdit( TQWidget *parent ) - : TQTextEdit(parent) +ocrResEdit::ocrResEdit( TQWidget *tqparent ) + : TQTextEdit(tqparent) { m_updateColor.setNamedColor( "SeaGreen"); m_ignoreColor.setNamedColor( "CadetBlue4" ); @@ -75,11 +75,11 @@ void ocrResEdit::slSelectWord( int line, const ocrWord& word ) if( line < paragraphs() ) { TQString editLine = text(line); - int cnt = editLine.contains( word); + int cnt = editLine.tqcontains( word); if( cnt > 0 ) { - int pos = editLine.find(word); + int pos = editLine.tqfind(word); setCursorPosition( line, pos ); setSelection( line, pos, line, pos + word.length()); } @@ -96,11 +96,11 @@ void ocrResEdit::slReplaceWord( int line, const TQString& wordFrom, if( line < paragraphs() ) { TQString editLine = text(line); - int cnt = editLine.contains( wordFrom ); + int cnt = editLine.tqcontains( wordFrom ); if( cnt > 0 ) { - int pos = editLine.find(wordFrom); + int pos = editLine.tqfind(wordFrom); setSelection( line, pos, line, pos+wordFrom.length()); TQColor saveCol = this->color(); diff --git a/kooka/ocrresedit.h b/kooka/ocrresedit.h index 19191266..f7e40dca 100644 --- a/kooka/ocrresedit.h +++ b/kooka/ocrresedit.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -33,11 +33,12 @@ class TQString; class TQColor; class ocrWord; -class ocrResEdit : public QTextEdit +class ocrResEdit : public TQTextEdit { Q_OBJECT + TQ_OBJECT public: - ocrResEdit( TQWidget *parent ); + ocrResEdit( TQWidget *tqparent ); public slots: void slUpdateOCRResult( int line, const TQString& wordFrom, diff --git a/kooka/ocrword.cpp b/kooka/ocrword.cpp index 4b04ea6e..2260e770 100644 --- a/kooka/ocrword.cpp +++ b/kooka/ocrword.cpp @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -76,7 +76,7 @@ TQStringList ocrWordList::stringList() * decided. Solution: KSpell should treat dash-linked words correctly. * We live with the problem here that dashes bring confusion ;-) */ - if( (*it).contains( rx ) ) + if( (*it).tqcontains( rx ) ) res += TQStringList::split( rx, (*it) ); else #endif @@ -95,9 +95,9 @@ bool ocrWordList::updateOCRWord( const TQString& from, const TQString& to ) { TQString word = (*it); kdDebug(28000) << "updateOCRWord in list: Comparing word " << word << endl; - if( word.contains( from, true ) ) // case sensitive search + if( word.tqcontains( from, true ) ) // case sensitive search { - word.replace( from, to ); + word.tqreplace( from, to ); *it = ocrWord( word ); res = true; break; diff --git a/kooka/ocrword.h b/kooka/ocrword.h index fd906367..5fbc209e 100644 --- a/kooka/ocrword.h +++ b/kooka/ocrword.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -37,7 +37,7 @@ class TQRect; /* ==== ocrWord ====================================== */ -class ocrWord : public QString +class ocrWord : public TQString { public: ocrWord(const TQString& s); diff --git a/kooka/resource.h b/kooka/resource.h index 51c9488f..687a7ddc 100644 --- a/kooka/resource.h +++ b/kooka/resource.h @@ -20,8 +20,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -52,7 +52,7 @@ #define ID_FILE_PRINT 10080 -#define ID_FILE_QUIT 10100 +#define ID_FILE_TQUIT 10100 /////////////////////////////////////////////////////////////////// diff --git a/kooka/scanpackager.cpp b/kooka/scanpackager.cpp index 2dd3096b..230acae1 100644 --- a/kooka/scanpackager.cpp +++ b/kooka/scanpackager.cpp @@ -21,8 +21,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -71,7 +71,7 @@ /* ----------------------------------------------------------------------- */ /* Constructor Scan Packager */ -ScanPackager::ScanPackager( TQWidget *parent ) : KFileTreeView( parent ) +ScanPackager::ScanPackager( TQWidget *tqparent ) : KFileTreeView( tqparent ) { // TODO: setItemsRenameable (true ); @@ -245,7 +245,7 @@ void ScanPackager::slotDecorate( KFileTreeViewItem* item ) } /* set image size in pixels */ - TQString t = i18n( "%1 x %2" ).arg( img->width()).arg(img->height()); + TQString t = i18n( "%1 x %2" ).tqarg( img->width()).tqarg(img->height()); item->setText( 1, t ); kdDebug( 28000) << "Image loaded and decorated!" << endl; } @@ -412,7 +412,7 @@ TQString ScanPackager::itemDirectory( const KFileTreeViewItem* item, bool relati if( ! item ) { kdDebug(28000) << "ERR: itemDirectory without item" << endl; - return TQString::null; + return TQString(); } TQString relativUrl= (item->url()).prettyURL(); @@ -420,7 +420,7 @@ TQString ScanPackager::itemDirectory( const KFileTreeViewItem* item, bool relati if( ! item->isDir() ) { // Cut off the filename in case it is not a dir - relativUrl.truncate( relativUrl.findRev( '/' )+1); + relativUrl.truncate( relativUrl.tqfindRev( '/' )+1); } else { @@ -463,8 +463,8 @@ void ScanPackager::slotSelectDirectory( const TQString & dirString ) { kdDebug(28000) << "Trying to decode directory string " << dirString << endl; - TQString searchFor = TQString::fromLatin1(" - "); - int pos = dirString.find( searchFor ); + TQString searchFor = TQString::tqfromLatin1(" - "); + int pos = dirString.tqfind( searchFor ); if( pos > -1 ) { @@ -531,7 +531,7 @@ void ScanPackager::slClicked( TQListViewItem *newItem ) } else { - emit( showThumbnails( static_cast(item->parent()))); + emit( showThumbnails( static_cast(item->tqparent()))); } } else @@ -600,7 +600,7 @@ void ScanPackager::loadImageForItem( KFileTreeViewItem *item ) prevItem = subImgItem; subImgItem->setPixmap( 0, loader->loadIcon( "editcopy", KIcon::Small )); - subImgItem->setText( 0, i18n("Sub-image %1").arg( i ) ); + subImgItem->setText( 0, i18n("Sub-image %1").tqarg( i ) ); KookaImage *subImgImg = new KookaImage( i, img ); subImgImg->setFileItem( newKfi ); newKfi->setExtraData( (void*) this, (void*) subImgImg ); @@ -711,7 +711,7 @@ TQCString ScanPackager::getImgFormat( KFileTreeViewItem* item ) const TQString ScanPackager::localFileName( KFileTreeViewItem *it ) const { - if( ! it ) return( TQString::null ); + if( ! it ) return( TQString() ); KURL url = it->url(); @@ -853,15 +853,15 @@ void ScanPackager::slAddImage( TQImage *img, KookaImageMeta* ) m_nextUrlToShow = lurl; TQString s; - /* Count amount of children of the father */ - TQListViewItem *paps = curr->parent(); + /* Count amount of tqchildren of the father */ + TQListViewItem *paps = curr->tqparent(); if( curr->isDir() ) /* take only father if the is no directory */ paps = curr; if( paps ) { int childcount = paps->childCount(); - s = i18n("%1 images").arg(childcount); + s = i18n("%1 images").tqarg(childcount); paps->setText( 1, s); setOpen( paps, true ); } @@ -1012,7 +1012,7 @@ void ScanPackager::slotImportFile() if( ! curr->isDir() ) { - KFileTreeViewItem *pa = static_cast(curr->parent()); + KFileTreeViewItem *pa = static_cast(curr->tqparent()); impTarget = pa->url(); } kdDebug(28000) << "Importing to " << impTarget.url() << endl; @@ -1136,7 +1136,7 @@ void ScanPackager::slotDeleteItems( ) s = i18n("Do you really want to delete this image?\nIt cannot be restored!" ); if( item->isDir() ) { - s = i18n("Do you really want to delete the folder %1\nand all the images inside?").arg(""); + s = i18n("Do you really want to delete the folder %1\nand all the images inside?").tqarg(""); } result = KMessageBox::warningContinueCancel(this, s, i18n( "Delete Collection Item"), KStdGuiItem::del(), "AskForDeleteFiles" ); @@ -1168,7 +1168,7 @@ void ScanPackager::slotCreateFolder( ) { bool ok; TQString folder = KInputDialog::getText( i18n( "New Folder" ), - i18n( "Please enter a name for the new folder:" ), TQString::null, + i18n( "Please enter a name for the new folder:" ), TQString(), &ok, this ); if( ok ) @@ -1214,7 +1214,7 @@ TQString ScanPackager::getImgName( TQString name_on_disk ) TQString s; (void) name_on_disk; - s = i18n("image %1").arg(img_counter++); + s = i18n("image %1").tqarg(img_counter++); return( s ); } @@ -1239,12 +1239,12 @@ void ScanPackager::contentsDragMoveEvent( TQDragMoveEvent *e ) } TQListViewItem *afterme = 0; - TQListViewItem *parent = 0; + TQListViewItem *tqparent = 0; - findDrop( e->pos(), parent, afterme ); + findDrop( e->pos(), tqparent, afterme ); // "afterme" is 0 when aiming at a directory itself - TQListViewItem *item = afterme ? afterme : parent; + TQListViewItem *item = afterme ? afterme : tqparent; if( item ) { diff --git a/kooka/scanpackager.h b/kooka/scanpackager.h index 496d6dee..c50c4d56 100644 --- a/kooka/scanpackager.h +++ b/kooka/scanpackager.h @@ -19,8 +19,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -74,8 +74,9 @@ private: class ScanPackager : public KFileTreeView { Q_OBJECT + TQ_OBJECT public: - ScanPackager( TQWidget *parent); + ScanPackager( TQWidget *tqparent); ~ScanPackager(); virtual TQString getImgName( TQString name_on_disk ); @@ -142,7 +143,7 @@ private: KFileTreeViewItem *spFindItem( SearchType type, const TQString name, const KFileTreeBranch* branch = 0 ); TQString itemDirectory( const KFileTreeViewItem*, bool relativ = false ) const; - // int readDir( TQListViewItem *parent, TQString dir_to_read ); + // int readDir( TQListViewItem *tqparent, TQString dir_to_read ); void showContextMenu( TQPoint p, bool show_folder = true ); TQString m_currImportDir; diff --git a/kooka/thumbview.cpp b/kooka/thumbview.cpp index b085e197..60312bad 100644 --- a/kooka/thumbview.cpp +++ b/kooka/thumbview.cpp @@ -22,8 +22,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -47,8 +47,8 @@ -ThumbView::ThumbView( TQWidget *parent, const char *name ) - : TQVBox( parent ), +ThumbView::ThumbView( TQWidget *tqparent, const char *name ) + : TQVBox( tqparent ), m_iconView(0), m_job(0) { @@ -91,14 +91,14 @@ bool ThumbView::readSettings() bool dirty = false; TQColor color; - color = cfg->readColorEntry( MARGIN_COLOR1, &(colorGroup().base())); + color = cfg->readColorEntry( MARGIN_COLOR1, &(tqcolorGroup().base())); if( color != m_marginColor1 ) { dirty = true; m_marginColor1 = color; } - color = cfg->readColorEntry( MARGIN_COLOR2, &(colorGroup().foreground())); + color = cfg->readColorEntry( MARGIN_COLOR2, &(tqcolorGroup().foreground())); if( color != m_marginColor2 ) { dirty = true; @@ -238,7 +238,7 @@ void ThumbView::slCheckForUpdate( KFileItem *kfit ) bool haveItem = false; /* iterate over all icon items and compare urls. - * TODO: Check the parent url to avoid iteration over all */ + * TODO: Check the tqparent url to avoid iteration over all */ for ( TQIconViewItem *item = m_iconView->firstItem(); item && !haveItem; item = item->nextItem() ) { @@ -269,7 +269,7 @@ bool ThumbView::deleteImage( KFileItem *kfit ) bool haveItem = false; /* iterate over all icon items and compare urls. - * TODO: Check the parent url to avoid iteration over all */ + * TODO: Check the tqparent url to avoid iteration over all */ for ( TQIconViewItem *item = m_iconView->firstItem(); item && !haveItem; item = item->nextItem() ) { if( searchUrl == static_cast(item)->itemUrl() ) diff --git a/kooka/thumbview.h b/kooka/thumbview.h index e1bc78cb..52b2bf05 100644 --- a/kooka/thumbview.h +++ b/kooka/thumbview.h @@ -21,8 +21,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -59,10 +59,11 @@ class KIO::PreviewJob; class ThumbView: public TQVBox /* KIconView */ { Q_OBJECT + TQ_OBJECT public: - ThumbView( TQWidget *parent, const char *name=0 ); + ThumbView( TQWidget *tqparent, const char *name=0 ); ~ThumbView(); void setCurrentDir( const KURL& s) diff --git a/kooka/thumbviewitem.cpp b/kooka/thumbviewitem.cpp index c8f8dab3..fe62e7e8 100644 --- a/kooka/thumbviewitem.cpp +++ b/kooka/thumbviewitem.cpp @@ -21,8 +21,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -32,10 +32,10 @@ #include "thumbview.h" #include "thumbviewitem.h" -ThumbViewItem::ThumbViewItem(TQIconView *parent, const TQString &text, +ThumbViewItem::ThumbViewItem(TQIconView *tqparent, const TQString &text, const TQPixmap &pixmap, KFileItem *fi ) - :KFileIconViewItem( parent, text, pixmap,fi ) + :KFileIconViewItem( tqparent, text, pixmap,fi ) { } diff --git a/kooka/thumbviewitem.h b/kooka/thumbviewitem.h index 74dad84b..5bf829dd 100644 --- a/kooka/thumbviewitem.h +++ b/kooka/thumbviewitem.h @@ -21,8 +21,8 @@ * including the source code for KADMOS in the source distribution. * * * As a special exception, permission is given to link this program * - * with any edition of Qt, and distribute the resulting executable, * - * without including the source code for Qt in the source distribution. * + * with any edition of TQt, and distribute the resulting executable, * + * without including the source code for TQt in the source distribution. * * * ***************************************************************************/ @@ -41,7 +41,7 @@ class KFileTreeViewItem; class ThumbViewItem: public KFileIconViewItem { public: - ThumbViewItem( TQIconView *parent, + ThumbViewItem( TQIconView *tqparent, const TQString &text, const TQPixmap &pixmap, KFileItem *fi ); -- cgit v1.2.3