diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-25 05:28:35 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-25 05:28:35 +0000 |
commit | f008adb5a77e094eaf6abf3fc0f36958e66896a5 (patch) | |
tree | 8e9244c4d4957c36be81e15b566b4aa5ea26c982 /kpresenter/KPrWebPresentation.cpp | |
parent | 1210f27b660efb7b37ff43ec68763e85a403471f (diff) | |
download | koffice-f008adb5a77e094eaf6abf3fc0f36958e66896a5.tar.gz koffice-f008adb5a77e094eaf6abf3fc0f36958e66896a5.zip |
TQt4 port koffice
This should enable compilation under both Qt3 and Qt4; fixes for any missed components will be forthcoming
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/koffice@1238284 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kpresenter/KPrWebPresentation.cpp')
-rw-r--r-- | kpresenter/KPrWebPresentation.cpp | 526 |
1 files changed, 263 insertions, 263 deletions
diff --git a/kpresenter/KPrWebPresentation.cpp b/kpresenter/KPrWebPresentation.cpp index 627013f9..78afb783 100644 --- a/kpresenter/KPrWebPresentation.cpp +++ b/kpresenter/KPrWebPresentation.cpp @@ -32,26 +32,26 @@ #include <sys/types.h> #include <ktempfile.h> -#include <qfile.h> -#include <qtextstream.h> -#include <qvbox.h> -#include <qhbox.h> -#include <qlabel.h> -#include <qpushbutton.h> -#include <qfileinfo.h> -#include <qframe.h> -#include <qfont.h> -#include <qpixmap.h> -#include <qdatetime.h> -#include <qdir.h> -#include <qheader.h> -#include <qwmatrix.h> -#include <qtextcodec.h> -#include <qregexp.h> -#include <qimage.h> -#include <qlayout.h> -#include <qwhatsthis.h> -#include <qcheckbox.h> +#include <tqfile.h> +#include <tqtextstream.h> +#include <tqvbox.h> +#include <tqhbox.h> +#include <tqlabel.h> +#include <tqpushbutton.h> +#include <tqfileinfo.h> +#include <tqframe.h> +#include <tqfont.h> +#include <tqpixmap.h> +#include <tqdatetime.h> +#include <tqdir.h> +#include <tqheader.h> +#include <tqwmatrix.h> +#include <tqtextcodec.h> +#include <tqregexp.h> +#include <tqimage.h> +#include <tqlayout.h> +#include <tqwhatsthis.h> +#include <tqcheckbox.h> #include <kdebug.h> #include <klocale.h> @@ -78,16 +78,16 @@ // Comes from koffice/filters/libexport/KWEFUtils.cc -static QString EscapeSgmlText(const QTextCodec* codec, const QString& strIn, +static TQString EscapeSgmlText(const TQTextCodec* codec, const TQString& strIn, const bool quot = false , const bool apos = false ) { - QString strReturn; - QChar ch; + TQString strReturn; + TQChar ch; for (uint i=0; i<strIn.length(); i++) { ch=strIn[i]; - switch (ch.unicode()) + switch (ch.tqunicode()) { case 38: // & { @@ -129,7 +129,7 @@ static QString EscapeSgmlText(const QTextCodec* codec, const QString& strIn, { if (!codec->canEncode(ch)) { - strReturn+=QString("&#%1;").arg(ch.unicode()); + strReturn+=TQString("&#%1;").tqarg(ch.tqunicode()); break; } } @@ -144,10 +144,10 @@ static QString EscapeSgmlText(const QTextCodec* codec, const QString& strIn, // Escape only if the encoding do not support the character // Special SGML characters like < > & are supposed to be already escaped. -static QString EscapeEncodingOnly(const QTextCodec* codec, const QString& strIn) +static TQString EscapeEncodingOnly(const TQTextCodec* codec, const TQString& strIn) { - QString strReturn; - QChar ch; + TQString strReturn; + TQChar ch; for (uint i=0; i<strIn.length(); i++) { @@ -156,7 +156,7 @@ static QString EscapeEncodingOnly(const QTextCodec* codec, const QString& strIn) { if (!codec->canEncode(ch)) { - strReturn+=QString("&#%1;").arg(ch.unicode()); + strReturn+=TQString("&#%1;").tqarg(ch.tqunicode()); continue; } } @@ -166,14 +166,14 @@ static QString EscapeEncodingOnly(const QTextCodec* codec, const QString& strIn) } KPrWebPresentation::KPrWebPresentation( KPrDocument *_doc, KPrView *_view ) - : config( QString::null ), xml( false ) + : config( TQString() ), xml( false ) { doc = _doc; view = _view; init(); } -KPrWebPresentation::KPrWebPresentation( const QString &_config, KPrDocument *_doc, KPrView *_view ) +KPrWebPresentation::KPrWebPresentation( const TQString &_config, KPrDocument *_doc, KPrView *_view ) : config( _config ), xml( false ), m_bWriteHeader( true ), m_bWriteFooter( true ), m_bLoopSlides( false ) { doc = _doc; @@ -211,7 +211,7 @@ void KPrWebPresentation::loadConfig() if ( num <= slideInfos.count() ) { for ( unsigned int i = 0; i < num; i++ ) { - QString key = QString::fromLatin1( "SlideTitle%1" ).arg( i ); + TQString key = TQString::tqfromLatin1( "SlideTitle%1" ).tqarg( i ); if ( cfg.hasKey( key ) ) { // We'll assume that the selected pages haven't changed... Hmm. @@ -245,7 +245,7 @@ void KPrWebPresentation::saveConfig() cfg.writeEntry( "Slides", slideInfos.count() ); for ( unsigned int i = 0; i < slideInfos.count(); i++ ) - cfg.writeEntry( QString::fromLatin1( "SlideTitle%1" ).arg( i ), slideInfos[ i ].slideTitle ); + cfg.writeEntry( TQString::tqfromLatin1( "SlideTitle%1" ).tqarg( i ), slideInfos[ i ].slideTitle ); cfg.writeEntry( "BackColor", backColor ); cfg.writeEntry( "TitleColor", titleColor ); @@ -266,17 +266,17 @@ void KPrWebPresentation::saveConfig() void KPrWebPresentation::initCreation( KProgress *progressBar ) { - QString cmd; + TQString cmd; int p; KURL str( path + "/html" ); - KIO::NetAccess::mkdir( str,( QWidget* )0L ); + KIO::NetAccess::mkdir( str,( TQWidget* )0L ); p = progressBar->progress(); progressBar->setProgress( ++p ); kapp->processEvents(); str = path + "/pics"; - KIO::NetAccess::mkdir( str,( QWidget* )0L ); + KIO::NetAccess::mkdir( str,( TQWidget* )0L ); p = progressBar->progress(); progressBar->setProgress( ++p ); @@ -288,7 +288,7 @@ void KPrWebPresentation::initCreation( KProgress *progressBar ) for ( uint index = 0; pics[ index ]; index ++ ) { - QString filename = pics[ index ]; + TQString filename = pics[ index ]; filename += ".png"; srcurl.setPath( locate( "slideshow", filename, KPrFactory::global() ) ); desturl = path; @@ -304,13 +304,13 @@ void KPrWebPresentation::createSlidesPictures( KProgress *progressBar ) { if ( slideInfos.isEmpty() ) return; - QPixmap pix( 10, 10 ); - QString filename; + TQPixmap pix( 10, 10 ); + TQString filename; int p; for ( unsigned int i = 0; i < slideInfos.count(); i++ ) { int pgNum = slideInfos[i].pageNumber; view->getCanvas()->drawPageInPix( pix, pgNum, zoom, true /*force real variable value*/ ); - filename = QString( "%1/pics/slide_%2.png" ).arg( path ).arg( i + 1 ); + filename = TQString( "%1/pics/slide_%2.png" ).tqarg( path ).tqarg( i + 1 ); KTempFile tmp; pix.save( tmp.name(), "PNG" ); @@ -323,16 +323,16 @@ void KPrWebPresentation::createSlidesPictures( KProgress *progressBar ) } } -QString KPrWebPresentation::escapeHtmlText( QTextCodec *codec, const QString& strText ) const +TQString KPrWebPresentation::escapeHtmlText( TQTextCodec *codec, const TQString& strText ) const { // Escape quotes (needed in attributes) // Do not escape apostrophs (only allowed in XHTML!) return EscapeSgmlText( codec, strText, true, false ); } -void KPrWebPresentation::writeStartOfHeader(QTextStream& streamOut, QTextCodec *codec, const QString& subtitle, const QString& next) +void KPrWebPresentation::writeStartOfHeader(TQTextStream& streamOut, TQTextCodec *codec, const TQString& subtitle, const TQString& next) { - QString mimeName ( codec->mimeName() ); + TQString mimeName ( codec->mimeName() ); if ( isXML() ) { //Write out the XML declaration streamOut << "<?xml version=\"1.0\" encoding=\"" @@ -363,11 +363,11 @@ void KPrWebPresentation::writeStartOfHeader(QTextStream& streamOut, QTextCodec * streamOut << mimeName << '"' << ( isXML() ?" /":"") << ">\n" ; // Tell who we are (with the CVS revision number) in case we have a bug in our output! - QString strVersion("$Revision: 508787 $"); + TQString strVersion("$Revision: 508787 $"); // Eliminate the dollar signs // (We don't want that the version number changes if the HTML file is itself put in a CVS storage.) streamOut << "<meta name=\"Generator\" content=\"KPresenter's Web Presentation " - << strVersion.mid(10).replace("$","") + << strVersion.mid(10).tqreplace("$","") << "\""<< ( isXML() ?" /":"") // X(HT)ML closes empty elements, HTML not! << ">\n"; @@ -387,20 +387,20 @@ void KPrWebPresentation::writeStartOfHeader(QTextStream& streamOut, QTextCodec * void KPrWebPresentation::createSlidesHTML( KProgress *progressBar ) { - QTextCodec *codec = KGlobal::charsets()->codecForName( m_encoding ); + TQTextCodec *codec = KGlobal::charsets()->codecForName( m_encoding ); - const QString brtag ( "<br" + QString(isXML()?" /":"") + ">" ); + const TQString brtag ( "<br" + TQString(isXML()?" /":"") + ">" ); for ( unsigned int i = 0; i < slideInfos.count(); i++ ) { unsigned int pgNum = i + 1; // pgquiles # elpauer . org - I think this is a bug, seems to be an overflow if we have max_unsigned_int slides KTempFile tmp; - QString dest= QString( "%1/html/slide_%2.html" ).arg( path ).arg( pgNum ); - QString next= QString( "slide_%2.html" ).arg( pgNum<slideInfos.count() ? pgNum+1 : (m_bLoopSlides ? 1 : pgNum ) ); // Ugly, but it works + TQString dest= TQString( "%1/html/slide_%2.html" ).tqarg( path ).tqarg( pgNum ); + TQString next= TQString( "slide_%2.html" ).tqarg( pgNum<slideInfos.count() ? pgNum+1 : (m_bLoopSlides ? 1 : pgNum ) ); // Ugly, but it works - QFile file( tmp.name() ); + TQFile file( tmp.name() ); file.open( IO_WriteOnly ); - QTextStream streamOut( &file ); + TQTextStream streamOut( &file ); streamOut.setCodec( codec ); writeStartOfHeader( streamOut, codec, slideInfos[ i ].slideTitle, next ); @@ -480,7 +480,7 @@ void KPrWebPresentation::createSlidesHTML( KProgress *progressBar ) streamOut << "<a href=\"" << next << "\">"; streamOut << "<img src=\"../pics/slide_" << pgNum << ".png\" border=\"0\" alt=\"" - << i18n( "Slide %1" ).arg( pgNum ) << "\"" << ( isXML() ?" /":"") << ">"; + << i18n( "Slide %1" ).tqarg( pgNum ) << "\"" << ( isXML() ?" /":"") << ">"; if ( i < slideInfos.count() - 1 ) streamOut << "</a>"; @@ -492,26 +492,26 @@ void KPrWebPresentation::createSlidesHTML( KProgress *progressBar ) if (m_bWriteFooter) { streamOut << brtag << "<hr noshade=\"noshade\"" << ( isXML() ?" /":"") << ">\n"; - QPtrList<KPrPage> _tmpList( doc->getPageList() ); - QString note ( escapeHtmlText( codec, _tmpList.at(i)->noteText() ) ); + TQPtrList<KPrPage> _tmpList( doc->getPageList() ); + TQString note ( escapeHtmlText( codec, _tmpList.at(i)->noteText() ) ); if ( !note.isEmpty() ) { streamOut << " <b>" << escapeHtmlText( codec, i18n( "Note" ) ) << "</b>\n"; streamOut << " <blockquote>\n"; - streamOut << note.replace( "\n", brtag ); + streamOut << note.tqreplace( "\n", brtag ); streamOut << " </blockquote><hr noshade=\"noshade\"" << ( isXML() ?" /":"") << ">\n"; } streamOut << " <center>\n"; - QString htmlAuthor; + TQString htmlAuthor; if (email.isEmpty()) htmlAuthor=escapeHtmlText( codec, author ); else - htmlAuthor=QString("<a href=\"mailto:%1\">%2</a>").arg( escapeHtmlText( codec, email )).arg( escapeHtmlText( codec, author )); + htmlAuthor=TQString("<a href=\"mailto:%1\">%2</a>").tqarg( escapeHtmlText( codec, email )).tqarg( escapeHtmlText( codec, author )); streamOut << EscapeEncodingOnly ( codec, i18n( "Created on %1 by <i>%2</i> with <a href=\"http://www.koffice.org/kpresenter\">KPresenter</a>" ) - .arg( KGlobal::locale()->formatDate ( QDate::currentDate() ) ).arg( htmlAuthor ) ); + .tqarg( KGlobal::locale()->formatDate ( TQDate::tqcurrentDate() ) ).tqarg( htmlAuthor ) ); streamOut << " </center><hr noshade=\"noshade\"" << ( isXML() ?" /":"") << ">\n"; } @@ -530,15 +530,15 @@ void KPrWebPresentation::createSlidesHTML( KProgress *progressBar ) void KPrWebPresentation::createMainPage( KProgress *progressBar ) { - QTextCodec *codec = KGlobal::charsets()->codecForName( m_encoding ); + TQTextCodec *codec = KGlobal::charsets()->codecForName( m_encoding ); KTempFile tmp; - QString dest = QString( "%1/index.html" ).arg( path ); - QFile file( tmp.name() ); + TQString dest = TQString( "%1/index.html" ).tqarg( path ); + TQFile file( tmp.name() ); file.open( IO_WriteOnly ); - QTextStream streamOut( &file ); + TQTextStream streamOut( &file ); streamOut.setCodec( codec ); - writeStartOfHeader( streamOut, codec, i18n("Table of Contents"), QString() ); + writeStartOfHeader( streamOut, codec, i18n("Table of Contents"), TQString() ); streamOut << "</head>\n"; streamOut << "<body bgcolor=\"" << backColor.name() << "\" text=\"" << textColor.name() << "\">\n"; @@ -559,10 +559,10 @@ void KPrWebPresentation::createMainPage( KProgress *progressBar ) streamOut << "</ol>\n"; // footer: author name, e-mail - QString htmlAuthor = email.isEmpty() ? escapeHtmlText( codec, author ) : - QString("<a href=\"mailto:%1\">%2</a>").arg( escapeHtmlText( codec, email )).arg( escapeHtmlText( codec, author )); + TQString htmlAuthor = email.isEmpty() ? escapeHtmlText( codec, author ) : + TQString("<a href=\"mailto:%1\">%2</a>").tqarg( escapeHtmlText( codec, email )).tqarg( escapeHtmlText( codec, author )); streamOut << EscapeEncodingOnly ( codec, i18n( "Created on %1 by <i>%2</i> with <a href=\"http://www.koffice.org/kpresenter\">KPresenter</a>" ) - .arg( KGlobal::locale()->formatDate ( QDate::currentDate() ) ).arg( htmlAuthor ) ); + .tqarg( KGlobal::locale()->formatDate ( TQDate::tqcurrentDate() ) ).tqarg( htmlAuthor ) ); streamOut << "</body>\n</html>\n"; file.close(); @@ -601,9 +601,9 @@ void KPrWebPresentation::init() } if ( slideInfos.isEmpty() ) kdWarning() << "No slides selected!" << endl; - backColor = Qt::white; - textColor = Qt::black; - titleColor = Qt::red; + backColor = TQt::white; + textColor = TQt::black; + titleColor = TQt::red; path = KGlobalSettings::documentPath() + "www"; @@ -611,10 +611,10 @@ void KPrWebPresentation::init() timeBetweenSlides = 0; - m_encoding = QTextCodec::codecForLocale()->name(); + m_encoding = TQTextCodec::codecForLocale()->name(); } -KPrWebPresentationWizard::KPrWebPresentationWizard( const QString &_config, KPrDocument *_doc, +KPrWebPresentationWizard::KPrWebPresentationWizard( const TQString &_config, KPrDocument *_doc, KPrView *_view ) : KWizard( 0, "", false ), config( _config ), webPres( config, _doc, _view ) { @@ -627,9 +627,9 @@ KPrWebPresentationWizard::KPrWebPresentationWizard( const QString &_config, KPrD setupPage4(); setupPage5(); - connect( nextButton(), SIGNAL( clicked() ), this, SLOT( pageChanged() ) ); - connect( backButton(), SIGNAL( clicked() ), this, SLOT( pageChanged() ) ); - connect( finishButton(), SIGNAL( clicked() ), this, SLOT( finish() ) ); + connect( nextButton(), TQT_SIGNAL( clicked() ), this, TQT_SLOT( pageChanged() ) ); + connect( backButton(), TQT_SIGNAL( clicked() ), this, TQT_SLOT( pageChanged() ) ); + connect( finishButton(), TQT_SIGNAL( clicked() ), this, TQT_SLOT( finish() ) ); } KPrWebPresentationWizard::~KPrWebPresentationWizard() @@ -637,7 +637,7 @@ KPrWebPresentationWizard::~KPrWebPresentationWizard() view->enableWebPres(); } -void KPrWebPresentationWizard::createWebPresentation( const QString &_config, KPrDocument *_doc, +void KPrWebPresentationWizard::createWebPresentation( const TQString &_config, KPrDocument *_doc, KPrView *_view ) { KPrWebPresentationWizard *dlg = new KPrWebPresentationWizard( _config, _doc, _view ); @@ -648,97 +648,97 @@ void KPrWebPresentationWizard::createWebPresentation( const QString &_config, KP void KPrWebPresentationWizard::setupPage1() { - page1 = new QHBox( this ); - QWhatsThis::add( page1, i18n("This page allows you to specify some of the key" + page1 = new TQHBox( this ); + TQWhatsThis::add( page1, i18n("This page allows you to specify some of the key" " values for how your presentation will be shown" " in HTML. Select individual items for more help" " on what they do.") ); page1->setSpacing( KDialog::spacingHint() ); page1->setMargin( KDialog::marginHint() ); - QLabel* sidebar = new QLabel( page1 ); + TQLabel* sidebar = new TQLabel( page1 ); sidebar->setMinimumSize( 106, 318 ); sidebar->setMaximumSize( 106, 318 ); - sidebar->setFrameShape( QFrame::Panel ); - sidebar->setFrameShadow( QFrame::Sunken ); + sidebar->setFrameShape( TQFrame::Panel ); + sidebar->setFrameShadow( TQFrame::Sunken ); sidebar->setPixmap(locate("data", "kpresenter/pics/webslideshow-sidebar.png")); - QWidget* canvas = new QWidget( page1 ); - QGridLayout *layout = new QGridLayout( canvas, 7, 2, + TQWidget* canvas = new TQWidget( page1 ); + TQGridLayout *tqlayout = new TQGridLayout( canvas, 7, 2, KDialog::marginHint(), KDialog::spacingHint() ); - QLabel *helptext = new QLabel( canvas ); - helptext->setAlignment( Qt::WordBreak | Qt::AlignTop| Qt::AlignLeft ); + TQLabel *helptext = new TQLabel( canvas ); + helptext->tqsetAlignment( TQt::WordBreak | TQt::AlignTop| TQt::AlignLeft ); helptext->setText( i18n( "Enter your name, email address and " "the title of the web presentation. " "Also enter the output directory where the " "web presentation should be saved. " ) ); - layout->addMultiCellWidget( helptext, 0, 0, 0, 1 ); + tqlayout->addMultiCellWidget( helptext, 0, 0, 0, 1 ); - layout->addMultiCell( new QSpacerItem( 1, 50 ), 1, 1, 0, 1 ); + tqlayout->addMultiCell( new TQSpacerItem( 1, 50 ), 1, 1, 0, 1 ); - QLabel *label1 = new QLabel( i18n("Author:"), canvas ); - label1->setAlignment( Qt::AlignVCenter | Qt::AlignRight ); - QWhatsThis::add( label1, i18n("This is where you enter the name of the person or " + TQLabel *label1 = new TQLabel( i18n("Author:"), canvas ); + label1->tqsetAlignment( TQt::AlignVCenter | TQt::AlignRight ); + TQWhatsThis::add( label1, i18n("This is where you enter the name of the person or " "organization that should be named as the author of " "the presentation.") ); - layout->addWidget( label1, 2, 0 ); + tqlayout->addWidget( label1, 2, 0 ); - QLabel *label2 = new QLabel( i18n("Title:"), canvas ); - label2->setAlignment( Qt::AlignVCenter | Qt::AlignRight ); - QWhatsThis::add( label2, i18n("This is where you enter the title of the overall " + TQLabel *label2 = new TQLabel( i18n("Title:"), canvas ); + label2->tqsetAlignment( TQt::AlignVCenter | TQt::AlignRight ); + TQWhatsThis::add( label2, i18n("This is where you enter the title of the overall " "presentation." ) ); - layout->addWidget( label2, 3, 0 ); + tqlayout->addWidget( label2, 3, 0 ); - QLabel *label3 = new QLabel( i18n("Email address:"), canvas ); - label3->setAlignment( Qt::AlignVCenter | Qt::AlignRight ); - QWhatsThis::add( label3, i18n("This is where you enter the email address of the " + TQLabel *label3 = new TQLabel( i18n("Email address:"), canvas ); + label3->tqsetAlignment( TQt::AlignVCenter | TQt::AlignRight ); + TQWhatsThis::add( label3, i18n("This is where you enter the email address of the " "person or organization that is responsible for " "the presentation.") ); - layout->addWidget( label3, 4, 0 ); + tqlayout->addWidget( label3, 4, 0 ); - QLabel *label4 = new QLabel( i18n("Path:"), canvas ); - label4->setAlignment( Qt::AlignVCenter | Qt::AlignRight ); - QWhatsThis::add( label4, i18n("The value entered for the path is the directory " + TQLabel *label4 = new TQLabel( i18n("Path:"), canvas ); + label4->tqsetAlignment( TQt::AlignVCenter | TQt::AlignRight ); + TQWhatsThis::add( label4, i18n("The value entered for the path is the directory " "where the presentation will be saved. If it does " "not exist, you'll be asked if you want to create " "the directory or abort the creation.") ); - layout->addWidget( label4, 5, 0 ); + tqlayout->addWidget( label4, 5, 0 ); author = new KLineEdit( webPres.getAuthor(), canvas ); - QWhatsThis::add( author, i18n("This is where you enter the name of the person or " + TQWhatsThis::add( author, i18n("This is where you enter the name of the person or " "organization that should be named as the author of " "the presentation.") ); - layout->addWidget( author, 2, 1 ); + tqlayout->addWidget( author, 2, 1 ); title = new KLineEdit( webPres.getTitle(), canvas ); - QWhatsThis::add( title, i18n("This is where you enter the title of the overall " + TQWhatsThis::add( title, i18n("This is where you enter the title of the overall " "presentation." ) ); - layout->addWidget( title, 3, 1 ); + tqlayout->addWidget( title, 3, 1 ); email = new KLineEdit( webPres.getEmail(), canvas ); - QWhatsThis::add( email, i18n("This is where you enter the email address of the " + TQWhatsThis::add( email, i18n("This is where you enter the email address of the " "person or organization that is responsible for " "the presentation.") ); - layout->addWidget( email, 4, 1 ); + tqlayout->addWidget( email, 4, 1 ); path=new KURLRequester( canvas ); path->setMode( KFile::Directory); path->lineEdit()->setText(webPres.getPath()); - QWhatsThis::add( path, i18n("The value entered for the path is the directory " + TQWhatsThis::add( path, i18n("The value entered for the path is the directory " "where the presentation will be saved. If it does " "not exist, you'll be asked if you want to create " "the directory or abort the creation.") ); - layout->addWidget( path, 5, 1 ); + tqlayout->addWidget( path, 5, 1 ); - QSpacerItem* spacer = new QSpacerItem( 1, 10, - QSizePolicy::Minimum, QSizePolicy::Expanding ); - layout->addMultiCell( spacer, 6, 6, 0, 1 ); + TQSpacerItem* spacer = new TQSpacerItem( 1, 10, + TQSizePolicy::Minimum, TQSizePolicy::Expanding ); + tqlayout->addMultiCell( spacer, 6, 6, 0, 1 ); - connect(path, SIGNAL(textChanged(const QString&)), - this,SLOT(slotChoosePath(const QString&))); - connect(path, SIGNAL(urlSelected( const QString& )), - this,SLOT(slotChoosePath(const QString&))); + connect(path, TQT_SIGNAL(textChanged(const TQString&)), + this,TQT_SLOT(slotChoosePath(const TQString&))); + connect(path, TQT_SIGNAL(urlSelected( const TQString& )), + this,TQT_SLOT(slotChoosePath(const TQString&))); addPage( page1, i18n( "Step 1: General Information" ) ); @@ -747,67 +747,67 @@ void KPrWebPresentationWizard::setupPage1() void KPrWebPresentationWizard::setupPage2() { - page2 = new QHBox( this ); - QWhatsThis::add( page2, i18n("This page allows you to specify how the HTML " + page2 = new TQHBox( this ); + TQWhatsThis::add( page2, i18n("This page allows you to specify how the HTML " "for your presentation will be displayed. Select " "individual items for more help on what they do.") ); page2->setSpacing( KDialog::spacingHint() ); page2->setMargin( KDialog::marginHint() ); - QLabel* sidebar = new QLabel( page2 ); + TQLabel* sidebar = new TQLabel( page2 ); sidebar->setMinimumSize( 106, 318 ); sidebar->setMaximumSize( 106, 318 ); - sidebar->setFrameShape( QFrame::Panel ); - sidebar->setFrameShadow( QFrame::Sunken ); + sidebar->setFrameShape( TQFrame::Panel ); + sidebar->setFrameShadow( TQFrame::Sunken ); sidebar->setPixmap(locate("data", "kpresenter/pics/webslideshow-sidebar.png")); - QWidget* canvas = new QWidget( page2 ); - QGridLayout *layout = new QGridLayout( canvas, 6, 2, + TQWidget* canvas = new TQWidget( page2 ); + TQGridLayout *tqlayout = new TQGridLayout( canvas, 6, 2, KDialog::marginHint(), KDialog::spacingHint() ); - QLabel *helptext = new QLabel( canvas ); - helptext->setAlignment( Qt::WordBreak | Qt::AlignVCenter| Qt::AlignLeft ); - QString help = i18n("Here you can configure the style of the web pages."); + TQLabel *helptext = new TQLabel( canvas ); + helptext->tqsetAlignment( TQt::WordBreak | TQt::AlignVCenter| TQt::AlignLeft ); + TQString help = i18n("Here you can configure the style of the web pages."); help += i18n( "You can also specify the zoom for the slides." ); helptext->setText(help); - layout->addMultiCellWidget( helptext, 0, 0, 0, 1 ); + tqlayout->addMultiCellWidget( helptext, 0, 0, 0, 1 ); - layout->addMultiCell( new QSpacerItem( 1, 50 ), 1, 1, 0, 1 ); + tqlayout->addMultiCell( new TQSpacerItem( 1, 50 ), 1, 1, 0, 1 ); - QLabel *label1 = new QLabel( i18n("Zoom:"), canvas ); - label1->setAlignment( Qt::AlignVCenter | Qt::AlignRight ); - QWhatsThis::add( label1, i18n( "This selection allows you to specify " + TQLabel *label1 = new TQLabel( i18n("Zoom:"), canvas ); + label1->tqsetAlignment( TQt::AlignVCenter | TQt::AlignRight ); + TQWhatsThis::add( label1, i18n( "This selection allows you to specify " "the size of the slide image." ) ); - layout->addWidget( label1, 2, 0 ); + tqlayout->addWidget( label1, 2, 0 ); - QLabel *label2 = new QLabel( i18n( "Encoding:" ), canvas ); - label2->setAlignment( Qt::AlignVCenter | Qt::AlignRight ); + TQLabel *label2 = new TQLabel( i18n( "Encoding:" ), canvas ); + label2->tqsetAlignment( TQt::AlignVCenter | TQt::AlignRight ); - layout->addWidget( label2, 3, 0 ); + tqlayout->addWidget( label2, 3, 0 ); - QLabel *label3 = new QLabel( i18n( "Document type:" ), canvas ); - label3->setAlignment( Qt::AlignVCenter | Qt::AlignRight ); - layout->addWidget( label3, 4, 0 ); + TQLabel *label3 = new TQLabel( i18n( "Document type:" ), canvas ); + label3->tqsetAlignment( TQt::AlignVCenter | TQt::AlignRight ); + tqlayout->addWidget( label3, 4, 0 ); zoom = new KIntNumInput( webPres.getZoom(), canvas ); - QWhatsThis::add( zoom, i18n( "This selection allows you to specify " + TQWhatsThis::add( zoom, i18n( "This selection allows you to specify " "the size of the slide image." ) ); - layout->addWidget( zoom, 2, 1 ); + tqlayout->addWidget( zoom, 2, 1 ); zoom->setSuffix( " %" ); zoom->setRange( 25, 1000, 5 ); encoding = new KComboBox( false, canvas ); - layout->addWidget( encoding, 3, 1 ); + tqlayout->addWidget( encoding, 3, 1 ); // Fill encoding combo // Stolen from kdelibs/kate/part/katedialogs.cpp - QStringList encodings(KGlobal::charsets()->descriptiveEncodingNames()); + TQStringList encodings(KGlobal::charsets()->descriptiveEncodingNames()); int idx = 0; for (uint i = 0; i < encodings.count(); i++) { bool found = false; - QTextCodec *codecForEnc = KGlobal::charsets()->codecForName(KGlobal::charsets()->encodingForName(encodings[i]), found); + TQTextCodec *codecForEnc = KGlobal::charsets()->codecForName(KGlobal::charsets()->encodingForName(encodings[i]), found); if (found) { encoding->insertItem(encodings[i]); @@ -819,15 +819,15 @@ void KPrWebPresentationWizard::setupPage2() } doctype = new KComboBox( false, canvas ); - layout->addWidget( doctype, 4, 1 ); + tqlayout->addWidget( doctype, 4, 1 ); doctype->insertItem( "HTML 4.01", -1 ); doctype->insertItem( "XHTML 1.0", -1 ); doctype->setCurrentItem( webPres.isXML() ? 1 : 0 ); - QSpacerItem* spacer = new QSpacerItem( 1, 10, - QSizePolicy::Minimum, QSizePolicy::Expanding ); - layout->addMultiCell( spacer, 5, 5, 0, 1 ); + TQSpacerItem* spacer = new TQSpacerItem( 1, 10, + TQSizePolicy::Minimum, TQSizePolicy::Expanding ); + tqlayout->addMultiCell( spacer, 5, 5, 0, 1 ); addPage( page2, i18n( "Step 2: Configure HTML" ) ); @@ -836,56 +836,56 @@ void KPrWebPresentationWizard::setupPage2() void KPrWebPresentationWizard::setupPage3() { - page3 = new QHBox( this ); - QWhatsThis::add( page3, i18n("This page allows you to specify the colors for " + page3 = new TQHBox( this ); + TQWhatsThis::add( page3, i18n("This page allows you to specify the colors for " "your presentation display. Select individual " "items for more help on what they do.") ); page3->setSpacing( KDialog::spacingHint() ); page3->setMargin( KDialog::marginHint() ); - QLabel* sidebar = new QLabel( page3 ); + TQLabel* sidebar = new TQLabel( page3 ); sidebar->setMinimumSize( 106, 318 ); sidebar->setMaximumSize( 106, 318 ); - sidebar->setFrameShape( QFrame::Panel ); - sidebar->setFrameShadow( QFrame::Sunken ); + sidebar->setFrameShape( TQFrame::Panel ); + sidebar->setFrameShadow( TQFrame::Sunken ); sidebar->setPixmap(locate("data", "kpresenter/pics/webslideshow-sidebar.png")); - QWidget* canvas = new QWidget( page3 ); - QGridLayout *layout = new QGridLayout( canvas, 6, 2, + TQWidget* canvas = new TQWidget( page3 ); + TQGridLayout *tqlayout = new TQGridLayout( canvas, 6, 2, KDialog::marginHint(), KDialog::spacingHint() ); - QLabel *helptext = new QLabel( canvas ); - helptext->setAlignment( Qt::WordBreak | Qt::AlignVCenter| Qt::AlignLeft ); + TQLabel *helptext = new TQLabel( canvas ); + helptext->tqsetAlignment( TQt::WordBreak | TQt::AlignVCenter| TQt::AlignLeft ); helptext->setText( i18n( "Now you can customize the colors of the web pages." ) ); - layout->addMultiCellWidget( helptext, 0, 0, 0, 1 ); + tqlayout->addMultiCellWidget( helptext, 0, 0, 0, 1 ); - layout->addMultiCell( new QSpacerItem( 1, 50 ), 1, 1, 0, 1 ); + tqlayout->addMultiCell( new TQSpacerItem( 1, 50 ), 1, 1, 0, 1 ); - QLabel *label1 = new QLabel( i18n("Text color:"), canvas ); - label1->setAlignment( Qt::AlignVCenter | Qt::AlignRight ); - layout->addWidget( label1, 2, 0 ); + TQLabel *label1 = new TQLabel( i18n("Text color:"), canvas ); + label1->tqsetAlignment( TQt::AlignVCenter | TQt::AlignRight ); + tqlayout->addWidget( label1, 2, 0 ); - QLabel *label2 = new QLabel( i18n("Title color:"), canvas ); - label2->setAlignment( Qt::AlignVCenter | Qt::AlignRight ); - layout->addWidget( label2, 3, 0 ); + TQLabel *label2 = new TQLabel( i18n("Title color:"), canvas ); + label2->tqsetAlignment( TQt::AlignVCenter | TQt::AlignRight ); + tqlayout->addWidget( label2, 3, 0 ); - QLabel *label3 = new QLabel( i18n("Background color:"), canvas ); - label3->setAlignment( Qt::AlignVCenter | Qt::AlignRight ); - layout->addWidget( label3, 4, 0 ); + TQLabel *label3 = new TQLabel( i18n("Background color:"), canvas ); + label3->tqsetAlignment( TQt::AlignVCenter | TQt::AlignRight ); + tqlayout->addWidget( label3, 4, 0 ); textColor = new KColorButton( webPres.getTextColor(), canvas ); - layout->addWidget( textColor, 2, 1 ); + tqlayout->addWidget( textColor, 2, 1 ); titleColor = new KColorButton( webPres.getTitleColor(), canvas ); - layout->addWidget( titleColor, 3, 1 ); + tqlayout->addWidget( titleColor, 3, 1 ); backColor = new KColorButton( webPres.getBackColor(), canvas ); - layout->addWidget( backColor, 4, 1 ); + tqlayout->addWidget( backColor, 4, 1 ); - QSpacerItem* spacer = new QSpacerItem( 1, 10, - QSizePolicy::Minimum, QSizePolicy::Expanding ); - layout->addMultiCell( spacer, 5, 5, 0, 1 ); + TQSpacerItem* spacer = new TQSpacerItem( 1, 10, + TQSizePolicy::Minimum, TQSizePolicy::Expanding ); + tqlayout->addMultiCell( spacer, 5, 5, 0, 1 ); addPage( page3, i18n( "Step 3: Customize Colors" ) ); @@ -894,26 +894,26 @@ void KPrWebPresentationWizard::setupPage3() void KPrWebPresentationWizard::setupPage4() { - page4 = new QHBox( this ); - QWhatsThis::add( page4, i18n("This page allows you to modify the titles of " + page4 = new TQHBox( this ); + TQWhatsThis::add( page4, i18n("This page allows you to modify the titles of " "each slide, if required. You normally do not need " "to do this, but it is available if required.") ); page4->setSpacing( KDialog::spacingHint() ); page4->setMargin( KDialog::marginHint() ); - QLabel* sidebar = new QLabel( page4 ); + TQLabel* sidebar = new TQLabel( page4 ); sidebar->setMinimumSize( 106, 318 ); sidebar->setMaximumSize( 106, 318 ); - sidebar->setFrameShape( QFrame::Panel ); - sidebar->setFrameShadow( QFrame::Sunken ); + sidebar->setFrameShape( TQFrame::Panel ); + sidebar->setFrameShadow( TQFrame::Sunken ); sidebar->setPixmap(locate("data", "kpresenter/pics/webslideshow-sidebar.png")); - QWidget* canvas = new QWidget( page4 ); - QGridLayout *layout = new QGridLayout( canvas, 3, 2, + TQWidget* canvas = new TQWidget( page4 ); + TQGridLayout *tqlayout = new TQGridLayout( canvas, 3, 2, KDialog::marginHint(), KDialog::spacingHint() ); - QLabel *helptext = new QLabel( canvas ); - helptext->setAlignment( Qt::WordBreak | Qt::AlignVCenter| Qt::AlignLeft ); + TQLabel *helptext = new TQLabel( canvas ); + helptext->tqsetAlignment( TQt::WordBreak | TQt::AlignVCenter| TQt::AlignLeft ); helptext->setText( i18n( "Here you can specify titles for " "each slide. Click on a slide in " "the list and then enter the title " @@ -921,32 +921,32 @@ void KPrWebPresentationWizard::setupPage4() "click on a title, KPresenter " "mainview will display the slide.") ); - layout->addMultiCellWidget( helptext, 0, 0, 0, 1 ); + tqlayout->addMultiCellWidget( helptext, 0, 0, 0, 1 ); - QLabel *label = new QLabel( i18n( "Slide title:" ), canvas ); - label->setAlignment( Qt::AlignVCenter | Qt::AlignRight ); - layout->addWidget( label, 1, 0 ); + TQLabel *label = new TQLabel( i18n( "Slide title:" ), canvas ); + label->tqsetAlignment( TQt::AlignVCenter | TQt::AlignRight ); + tqlayout->addWidget( label, 1, 0 ); slideTitle = new KLineEdit( canvas ); - layout->addWidget( slideTitle, 1, 1 ); - connect( slideTitle, SIGNAL( textChanged( const QString & ) ), this, - SLOT( slideTitleChanged( const QString & ) ) ); + tqlayout->addWidget( slideTitle, 1, 1 ); + connect( slideTitle, TQT_SIGNAL( textChanged( const TQString & ) ), this, + TQT_SLOT( slideTitleChanged( const TQString & ) ) ); slideTitles = new KListView( canvas ); - layout->addMultiCellWidget( slideTitles, 2, 2, 0, 1 ); + tqlayout->addMultiCellWidget( slideTitles, 2, 2, 0, 1 ); slideTitles->addColumn( i18n( "No." ) ); slideTitles->addColumn( i18n( "Slide Title" ) ); - connect( slideTitles, SIGNAL( selectionChanged( QListViewItem * ) ), this, - SLOT( slideTitleChanged( QListViewItem * ) ) ); + connect( slideTitles, TQT_SIGNAL( selectionChanged( TQListViewItem * ) ), this, + TQT_SLOT( slideTitleChanged( TQListViewItem * ) ) ); slideTitles->setSorting( -1 ); slideTitles->setAllColumnsShowFocus( true ); - slideTitles->setResizeMode( QListView::LastColumn ); + slideTitles->setResizeMode( TQListView::LastColumn ); slideTitles->header()->setMovingEnabled( false ); - QValueList<KPrWebPresentation::SlideInfo> infos = webPres.getSlideInfos(); + TQValueList<KPrWebPresentation::SlideInfo> infos = webPres.getSlideInfos(); for ( int i = infos.count() - 1; i >= 0; --i ) { KListViewItem *item = new KListViewItem( slideTitles ); - item->setText( 0, QString::number( i + 1 ) ); + item->setText( 0, TQString::number( i + 1 ) ); //kdDebug(33001) << "KPrWebPresentationWizard::setupPage3 " << infos[ i ].slideTitle << endl; item->setText( 1, infos[ i ].slideTitle ); } @@ -960,8 +960,8 @@ void KPrWebPresentationWizard::setupPage4() void KPrWebPresentationWizard::setupPage5() { - page5 = new QHBox( this ); - QWhatsThis::add( page5, i18n("This page allows you to specify some options for " + page5 = new TQHBox( this ); + TQWhatsThis::add( page5, i18n("This page allows you to specify some options for " "presentations which run unattended, such as time " "elapsed before advancing to the next slide, looping " "and the presence of headers. If you do not want " @@ -969,68 +969,68 @@ void KPrWebPresentationWizard::setupPage5() page5->setSpacing( KDialog::spacingHint() ); page5->setMargin( KDialog::marginHint() ); - QLabel* sidebar = new QLabel( page5 ); + TQLabel* sidebar = new TQLabel( page5 ); sidebar->setMinimumSize( 106, 318 ); sidebar->setMaximumSize( 106, 318 ); - sidebar->setFrameShape( QFrame::Panel ); - sidebar->setFrameShadow( QFrame::Sunken ); + sidebar->setFrameShape( TQFrame::Panel ); + sidebar->setFrameShadow( TQFrame::Sunken ); sidebar->setPixmap(locate("data", "kpresenter/pics/webslideshow-sidebar.png")); - QWidget* canvas = new QWidget( page5 ); - QGridLayout *layout = new QGridLayout( canvas, 6, 2, + TQWidget* canvas = new TQWidget( page5 ); + TQGridLayout *tqlayout = new TQGridLayout( canvas, 6, 2, KDialog::marginHint(), KDialog::spacingHint() ); - QLabel *helptext = new QLabel( canvas ); - helptext->setAlignment( Qt::WordBreak | Qt::AlignVCenter| Qt::AlignLeft ); - QString help = i18n("Here you can configure some options for unattended " + TQLabel *helptext = new TQLabel( canvas ); + helptext->tqsetAlignment( TQt::WordBreak | TQt::AlignVCenter| TQt::AlignLeft ); + TQString help = i18n("Here you can configure some options for unattended " "presentations, such as time elapsed before automatically advance to " "the next slide, looping and the presence of headers."); helptext->setText(help); - layout->addMultiCellWidget( helptext, 0, 0, 0, 1 ); + tqlayout->addMultiCellWidget( helptext, 0, 0, 0, 1 ); - layout->addMultiCell( new QSpacerItem( 1, 50 ), 1, 1, 0, 1 ); + tqlayout->addMultiCell( new TQSpacerItem( 1, 50 ), 1, 1, 0, 1 ); - QLabel *label1 = new QLabel( i18n("Advance after:"), canvas ); - label1->setAlignment( Qt::AlignVCenter | Qt::AlignRight ); - QWhatsThis::add( label1, i18n( "This selection allows you to specify " + TQLabel *label1 = new TQLabel( i18n("Advance after:"), canvas ); + label1->tqsetAlignment( TQt::AlignVCenter | TQt::AlignRight ); + TQWhatsThis::add( label1, i18n( "This selection allows you to specify " "the time between slides." ) ); - layout->addWidget( label1, 2, 0 ); + tqlayout->addWidget( label1, 2, 0 ); timeBetweenSlides = new KIntNumInput( webPres.getTimeBetweenSlides(), canvas ); timeBetweenSlides->setSpecialValueText(i18n( "Disabled" )); - QWhatsThis::add( timeBetweenSlides, i18n( "This selection allows you to specify " + TQWhatsThis::add( timeBetweenSlides, i18n( "This selection allows you to specify " "the time between slides." ) ); - layout->addWidget( timeBetweenSlides, 2, 1 ); + tqlayout->addWidget( timeBetweenSlides, 2, 1 ); timeBetweenSlides->setSuffix( " seconds" ); timeBetweenSlides->setRange( 0, 900, 1 ); - layout->addMultiCell( new QSpacerItem( 1, 10 ), 1, 1, 0, 1 ); + tqlayout->addMultiCell( new TQSpacerItem( 1, 10 ), 1, 1, 0, 1 ); - writeHeader=new QCheckBox( i18n("Write header to the slides"), canvas); - QWhatsThis::add( writeHeader, i18n( "This checkbox allows you to specify if you " + writeHeader=new TQCheckBox( i18n("Write header to the slides"), canvas); + TQWhatsThis::add( writeHeader, i18n( "This checkbox allows you to specify if you " "want to write the navigation buttons on top " "of the slide." ) ); writeHeader->setChecked( webPres.wantHeader() ); - layout->addWidget( writeHeader, 3, 1); + tqlayout->addWidget( writeHeader, 3, 1); - writeFooter=new QCheckBox( i18n("Write footer to the slides"), canvas); - QWhatsThis::add( writeFooter, i18n( "This checkbox allows you to specify if you " + writeFooter=new TQCheckBox( i18n("Write footer to the slides"), canvas); + TQWhatsThis::add( writeFooter, i18n( "This checkbox allows you to specify if you " "want to write an imprint consisting on the author " "and the software used to create these slides." ) ); writeFooter->setChecked( webPres.wantFooter() ); - layout->addWidget( writeFooter, 4, 1); + tqlayout->addWidget( writeFooter, 4, 1); - loopSlides=new QCheckBox( i18n("Loop presentation"), canvas); - QWhatsThis::add( loopSlides, i18n( "This checkbox allows you to specify if you " + loopSlides=new TQCheckBox( i18n("Loop presentation"), canvas); + TQWhatsThis::add( loopSlides, i18n( "This checkbox allows you to specify if you " "want the presentation to start again once " "the latest slide is reached." ) ); loopSlides->setChecked( webPres.wantLoopSlides() ); - layout->addWidget( loopSlides, 5, 1); + tqlayout->addWidget( loopSlides, 5, 1); - QSpacerItem* spacer = new QSpacerItem( 1, 10, - QSizePolicy::Minimum, QSizePolicy::Expanding ); - layout->addMultiCell( spacer, 5, 5, 0, 1 ); + TQSpacerItem* spacer = new TQSpacerItem( 1, 10, + TQSizePolicy::Minimum, TQSizePolicy::Expanding ); + tqlayout->addMultiCell( spacer, 5, 5, 0, 1 ); addPage( page5, i18n( "Step 5: Options for Unattended Presentations" ) ); @@ -1045,7 +1045,7 @@ void KPrWebPresentationWizard::finish() webPres.setEMail( email->text() ); webPres.setTitle( title->text() ); - QListViewItemIterator it( slideTitles ); + TQListViewItemIterator it( slideTitles ); for ( ; it.current(); ++it ) webPres.setSlideTitle( it.current()->text( 0 ).toInt() - 1, it.current()->text( 1 ) ); @@ -1060,7 +1060,7 @@ void KPrWebPresentationWizard::finish() webPres.setLoopSlides( loopSlides->isChecked() ); webPres.setXML( doctype->currentItem() != 0 ); bool found = false; - QTextCodec *codecForEnc = KGlobal::charsets()->codecForName(KGlobal::charsets()->encodingForName(encoding->currentText()), found); + TQTextCodec *codecForEnc = KGlobal::charsets()->codecForName(KGlobal::charsets()->encodingForName(encoding->currentText()), found); if ( found ) { webPres.setEncoding( codecForEnc->name() ); @@ -1074,14 +1074,14 @@ void KPrWebPresentationWizard::pageChanged() { if ( currentPage() != page5 ) { - QString pathname = path->lineEdit()->text(); + TQString pathname = path->lineEdit()->text(); // path doesn't exist. ask user if it should be created. if ( !KIO::NetAccess::exists( pathname, true/*write*/,this ) ) { - QString msg = i18n( "<qt>The directory <b>%1</b> does not exist.<br>" + TQString msg = i18n( "<qt>The directory <b>%1</b> does not exist.<br>" "Do you want create it?</qt>" ); - if( KMessageBox::questionYesNo( this, msg.arg( pathname ), + if( KMessageBox::questionYesNo( this, msg.tqarg( pathname ), i18n( "Directory Not Found" ) ) == KMessageBox::Yes) { @@ -1107,13 +1107,13 @@ void KPrWebPresentationWizard::pageChanged() finishButton()->setEnabled( true ); } -void KPrWebPresentationWizard::slideTitleChanged( const QString &s ) +void KPrWebPresentationWizard::slideTitleChanged( const TQString &s ) { if ( slideTitles->currentItem() ) slideTitles->currentItem()->setText( 1, s ); } -void KPrWebPresentationWizard::slideTitleChanged( QListViewItem *i ) +void KPrWebPresentationWizard::slideTitleChanged( TQListViewItem *i ) { if ( !i ) return; @@ -1121,20 +1121,20 @@ void KPrWebPresentationWizard::slideTitleChanged( QListViewItem *i ) view->skipToPage( i->text( 0 ).toInt() - 1 ); } -void KPrWebPresentationWizard::closeEvent( QCloseEvent *e ) +void KPrWebPresentationWizard::closeEvent( TQCloseEvent *e ) { view->enableWebPres(); KWizard::closeEvent( e ); } -void KPrWebPresentationWizard::slotChoosePath(const QString &text) +void KPrWebPresentationWizard::slotChoosePath(const TQString &text) { webPres.setPath(text); } KPrWebPresentationCreateDialog::KPrWebPresentationCreateDialog( KPrDocument *_doc, KPrView *_view, const KPrWebPresentation &_webPres ) - : QDialog( 0, "", false ), webPres( _webPres ) + : TQDialog( 0, "", false ), webPres( _webPres ) { doc = _doc; view = _view; @@ -1173,7 +1173,7 @@ void KPrWebPresentationCreateDialog::start() void KPrWebPresentationCreateDialog::initCreation() { - QFont f = step1->font(), f2 = step1->font(); + TQFont f = step1->font(), f2 = step1->font(); f.setBold( true ); step1->setFont( f ); @@ -1188,7 +1188,7 @@ void KPrWebPresentationCreateDialog::initCreation() void KPrWebPresentationCreateDialog::createSlidesPictures() { - QFont f = step2->font(), f2 = f; + TQFont f = step2->font(), f2 = f; f.setBold( true ); step2->setFont( f ); @@ -1205,7 +1205,7 @@ void KPrWebPresentationCreateDialog::createSlidesPictures() void KPrWebPresentationCreateDialog::createSlidesHTML() { - QFont f = step3->font(), f2 = step3->font(); + TQFont f = step3->font(), f2 = step3->font(); f.setBold( true ); step3->setFont( f ); @@ -1222,7 +1222,7 @@ void KPrWebPresentationCreateDialog::createSlidesHTML() void KPrWebPresentationCreateDialog::createMainPage() { - QFont f = step4->font(), f2 = step4->font(); + TQFont f = step4->font(), f2 = step4->font(); f.setBold( true ); step4->setFont( f ); @@ -1237,29 +1237,29 @@ void KPrWebPresentationCreateDialog::createMainPage() void KPrWebPresentationCreateDialog::setupGUI() { - back = new QVBox( this ); + back = new TQVBox( this ); back->setMargin( KDialog::marginHint() ); - QFrame *line; + TQFrame *line; - line = new QFrame( back ); - line->setFrameStyle( QFrame::HLine | QFrame::Sunken ); + line = new TQFrame( back ); + line->setFrameStyle( TQFrame::HLine | TQFrame::Sunken ); line->setMaximumHeight( 20 ); - step1 = new QLabel( i18n( "Initialize (create file structure, etc.)" ), back ); - step2 = new QLabel( i18n( "Create Pictures of the Slides" ), back ); - step3 = new QLabel( i18n( "Create HTML Pages for the Slides" ), back ); - step4 = new QLabel( i18n( "Create Main Page (Table of Contents)" ), back ); - step5 = new QLabel( i18n( "Options for Unattended Presentations" ), back); + step1 = new TQLabel( i18n( "Initialize (create file structure, etc.)" ), back ); + step2 = new TQLabel( i18n( "Create Pictures of the Slides" ), back ); + step3 = new TQLabel( i18n( "Create HTML Pages for the Slides" ), back ); + step4 = new TQLabel( i18n( "Create Main Page (Table of Contents)" ), back ); + step5 = new TQLabel( i18n( "Options for Unattended Presentations" ), back); - line = new QFrame( back ); - line->setFrameStyle( QFrame::HLine | QFrame::Sunken ); + line = new TQFrame( back ); + line->setFrameStyle( TQFrame::HLine | TQFrame::Sunken ); line->setMaximumHeight( 20 ); progressBar = new KProgress( back ); - line = new QFrame( back ); - line->setFrameStyle( QFrame::HLine | QFrame::Sunken ); + line = new TQFrame( back ); + line->setFrameStyle( TQFrame::HLine | TQFrame::Sunken ); line->setMaximumHeight( 20 ); KButtonBox *bb = new KButtonBox( back ); @@ -1270,26 +1270,26 @@ void KPrWebPresentationCreateDialog::setupGUI() bSave->setEnabled( false ); bDone->setEnabled( false ); - connect( bDone, SIGNAL( clicked() ), this, SLOT( accept() ) ); - connect( bSave, SIGNAL( clicked() ), this, SLOT( saveConfig() ) ); + connect( bDone, TQT_SIGNAL( clicked() ), this, TQT_SLOT( accept() ) ); + connect( bSave, TQT_SIGNAL( clicked() ), this, TQT_SLOT( saveConfig() ) ); } -void KPrWebPresentationCreateDialog::resizeEvent( QResizeEvent *e ) +void KPrWebPresentationCreateDialog::resizeEvent( TQResizeEvent *e ) { - QDialog::resizeEvent( e ); + TQDialog::resizeEvent( e ); back->resize( size() ); } void KPrWebPresentationCreateDialog::saveConfig() { - QString filename = webPres.getConfig(); - if ( QFileInfo( filename ).exists() ) - filename = QFileInfo( filename ).absFilePath(); + TQString filename = webPres.getConfig(); + if ( TQFileInfo( filename ).exists() ) + filename = TQFileInfo( filename ).absFilePath(); else - filename = QString::null; + filename = TQString(); KFileDialog fd (filename, i18n("*.kpweb|KPresenter Web-Presentation (*.kpweb)"), - 0/*parent*/, 0/*name*/, true/*modal*/); + 0/*tqparent*/, 0/*name*/, true/*modal*/); fd.setCaption (i18n ("Save Web Presentation Configuration")); fd.setOperationMode (KFileDialog::Saving); fd.setMode (KFile::File | KFile::LocalOnly); |