diff options
Diffstat (limited to 'kdialog')
-rw-r--r-- | kdialog/README | 2 | ||||
-rw-r--r-- | kdialog/kdialog.cpp | 50 | ||||
-rw-r--r-- | kdialog/klistboxdialog.cpp | 2 | ||||
-rwxr-xr-x | kdialog/progressdemo | 2 | ||||
-rwxr-xr-x | kdialog/test | 24 | ||||
-rw-r--r-- | kdialog/widgets.cpp | 6 |
6 files changed, 43 insertions, 43 deletions
diff --git a/kdialog/README b/kdialog/README index e7df11e1f..d029419c0 100644 --- a/kdialog/README +++ b/kdialog/README @@ -3,7 +3,7 @@ The syntax is very much inspired from the "dialog" command (which shows text mode dialogs). However the width and height attributes have been removed for -most dialogs - Qt/KDE have tqlayouts ;) +most dialogs - Qt/KDE have layouts ;) A tutorial on using kdialog is available at http://developer.kde.org/documentation/tutorials/kdialog/t1.html diff --git a/kdialog/kdialog.cpp b/kdialog/kdialog.cpp index 297822e96..8cf9b581f 100644 --- a/kdialog/kdialog.cpp +++ b/kdialog/kdialog.cpp @@ -108,10 +108,10 @@ class WinIdEmbedder: public QObject { public: WinIdEmbedder(bool printID, WId winId): - TQObject(tqApp), print(printID), id(winId) + TQObject(qApp), print(printID), id(winId) { - if (tqApp) - tqApp->installEventFilter(this); + if (qApp) + qApp->installEventFilter(this); } protected: bool eventFilter(TQObject *o, TQEvent *e); @@ -241,9 +241,9 @@ static int directCommand(KCmdLineArgs *args) TQString text = TQString::fromLocal8Bit(args->getOption( option )); int pos; - while ((pos = text.find( TQString::tqfromLatin1("\\n") )) >= 0) + while ((pos = text.find( TQString::fromLatin1("\\n") )) >= 0) { - text.tqreplace(pos, 2, TQString::tqfromLatin1("\n")); + text.replace(pos, 2, TQString::fromLatin1("\n")); } if ( type == KMessageBox::WarningContinueCancel ) { @@ -491,7 +491,7 @@ static int directCommand(KCmdLineArgs *args) if (args->count() >= 1) { filter = TQString::fromLocal8Bit(args->arg(0)); } - // copied from KFileDialog::getSaveFileName(), so we can add tqgeometry + // copied from KFileDialog::getSaveFileName(), so we can add geometry bool specialDir = ( startDir.at(0) == ':' ); KFileDialog dlg( specialDir ? startDir : TQString::null, filter, 0, "filedialog", true ); if ( !specialDir ) @@ -597,44 +597,44 @@ static int directCommand(KCmdLineArgs *args) contextStr = TQString::fromLocal8Bit(args->arg(0)); } KIcon::Group group = KIcon::NoGroup; - if ( groupStr == TQString::tqfromLatin1( "Desktop" ) ) + if ( groupStr == TQString::fromLatin1( "Desktop" ) ) group = KIcon::Desktop; - else if ( groupStr == TQString::tqfromLatin1( "Toolbar" ) ) + else if ( groupStr == TQString::fromLatin1( "Toolbar" ) ) group = KIcon::Toolbar; - else if ( groupStr == TQString::tqfromLatin1( "MainToolbar" ) ) + else if ( groupStr == TQString::fromLatin1( "MainToolbar" ) ) group = KIcon::MainToolbar; - else if ( groupStr == TQString::tqfromLatin1( "Small" ) ) + else if ( groupStr == TQString::fromLatin1( "Small" ) ) group = KIcon::Small; - else if ( groupStr == TQString::tqfromLatin1( "Panel" ) ) + else if ( groupStr == TQString::fromLatin1( "Panel" ) ) group = KIcon::Panel; - else if ( groupStr == TQString::tqfromLatin1( "User" ) ) + else if ( groupStr == TQString::fromLatin1( "User" ) ) group = KIcon::User; KIcon::Context context = KIcon::Any; // From kicontheme.cpp - if ( contextStr == TQString::tqfromLatin1( "Devices" ) ) + if ( contextStr == TQString::fromLatin1( "Devices" ) ) context = KIcon::Device; - else if ( contextStr == TQString::tqfromLatin1( "MimeTypes" ) ) + else if ( contextStr == TQString::fromLatin1( "MimeTypes" ) ) context = KIcon::MimeType; - else if ( contextStr == TQString::tqfromLatin1( "FileSystems" ) ) + else if ( contextStr == TQString::fromLatin1( "FileSystems" ) ) context = KIcon::FileSystem; - else if ( contextStr == TQString::tqfromLatin1( "Applications" ) ) + else if ( contextStr == TQString::fromLatin1( "Applications" ) ) context = KIcon::Application; - else if ( contextStr == TQString::tqfromLatin1( "Actions" ) ) + else if ( contextStr == TQString::fromLatin1( "Actions" ) ) context = KIcon::Action; - else if ( contextStr == QString::tqfromLatin1( "Animations" ) ) + else if ( contextStr == QString::fromLatin1( "Animations" ) ) context = KIcon::Animation; - else if ( contextStr == QString::tqfromLatin1( "Categories" ) ) + else if ( contextStr == QString::fromLatin1( "Categories" ) ) context = KIcon::Category; - else if ( contextStr == QString::tqfromLatin1( "Emblems" ) ) + else if ( contextStr == QString::fromLatin1( "Emblems" ) ) context = KIcon::Emblem; - else if ( contextStr == QString::tqfromLatin1( "Emotes" ) ) + else if ( contextStr == QString::fromLatin1( "Emotes" ) ) context = KIcon::Emote; - else if ( contextStr == QString::tqfromLatin1( "International" ) ) + else if ( contextStr == QString::fromLatin1( "International" ) ) context = KIcon::International; - else if ( contextStr == QString::tqfromLatin1( "Places" ) ) + else if ( contextStr == QString::fromLatin1( "Places" ) ) context = KIcon::Place; - else if ( contextStr == QString::tqfromLatin1( "tqStatus" ) ) - context = KIcon::tqStatusIcon; + else if ( contextStr == QString::fromLatin1( "Status" ) ) + context = KIcon::StatusIcon; KIconDialog dlg(0, "icon dialog"); kapp->setTopWidget( &dlg ); diff --git a/kdialog/klistboxdialog.cpp b/kdialog/klistboxdialog.cpp index 23fe18f53..d7abfb694 100644 --- a/kdialog/klistboxdialog.cpp +++ b/kdialog/klistboxdialog.cpp @@ -32,7 +32,7 @@ KListBoxDialog::KListBoxDialog(TQString text, TQWidget *parent) TQVBox *page = makeVBoxMainWidget(); label = new TQLabel(text, page); - label->tqsetAlignment(AlignCenter); + label->setAlignment(AlignCenter); table = new TQListBox(page); table->setFocus(); diff --git a/kdialog/progressdemo b/kdialog/progressdemo index 6c2ac6afb..e6f4bb48c 100755 --- a/kdialog/progressdemo +++ b/kdialog/progressdemo @@ -1,5 +1,5 @@ #!/bin/sh -dcopRef=`./kdialog --tqgeometry 300x200+100-100 --progressbar "Initialising" 6` +dcopRef=`./kdialog --geometry 300x200+100-100 --progressbar "Initialising" 6` dcop $dcopRef setProgress 1 dcop $dcopRef setLabel "Thinking really hard" sleep 2 diff --git a/kdialog/test b/kdialog/test index 442b9c307..0d41dbb0a 100755 --- a/kdialog/test +++ b/kdialog/test @@ -1,6 +1,6 @@ #!/bin/sh echo "yesno box:" -./kdialog --tqgeometry 400x300+100+50 --title "This is a yesno box" --yesno "Choose: yes or no" +./kdialog --geometry 400x300+100+50 --title "This is a yesno box" --yesno "Choose: yes or no" if [ $? = 0 ]; then echo " your choice was: yes" else @@ -8,7 +8,7 @@ else fi echo "continue or cancel warning box:" -./kdialog --tqgeometry 200x300+100-50 --title "This is a warningcontinuecancel box" --warningcontinuecancel "Choose: continue or cancel" +./kdialog --geometry 200x300+100-50 --title "This is a warningcontinuecancel box" --warningcontinuecancel "Choose: continue or cancel" if [ $? = 0 ]; then echo " your choice was: continue" else @@ -16,7 +16,7 @@ else fi echo "message box:" -./kdialog --tqgeometry 300x400-100-50 --title "This is a message" --msgbox "Well, this is it:\nthe message" +./kdialog --geometry 300x400-100-50 --title "This is a message" --msgbox "Well, this is it:\nthe message" echo "input box:" ./kdialog --title "This is a input box" --inputbox "What is your name" "Joe User" @@ -26,8 +26,8 @@ else echo " you did not accept" fi -echo "input box, with tqgeometry:" -./kdialog --tqgeometry 300x400-100-50 --title "This is a input box" --inputbox "What is your name" "Joe User" +echo "input box, with geometry:" +./kdialog --geometry 300x400-100-50 --title "This is a input box" --inputbox "What is your name" "Joe User" if [ $? = 0 ]; then echo " you accepted" else @@ -35,25 +35,25 @@ else fi echo "text box:" -./kdialog --tqgeometry 300x400-100-50 --miniicon "about_kde" --title "This is a text box" --textbox widgets.h 400 300 +./kdialog --geometry 300x400-100-50 --miniicon "about_kde" --title "This is a text box" --textbox widgets.h 400 300 echo "menu:" -./kdialog --miniicon "about_kde" --tqgeometry 300x400-100-50 --title "This is a menu" --default "French" --menu "Choose one of these" a English b German c French d Spanish +./kdialog --miniicon "about_kde" --geometry 300x400-100-50 --title "This is a menu" --default "French" --menu "Choose one of these" a English b German c French d Spanish echo "checklist:" -./kdialog --tqgeometry 400x300+100+50 --miniicon "about_kde" --title "This is a checklist" --checklist "Choose some of these" a English on b German off c French off d Spanish on +./kdialog --geometry 400x300+100+50 --miniicon "about_kde" --title "This is a checklist" --checklist "Choose some of these" a English on b German off c French off d Spanish on echo "radiolist:" -./kdialog --tqgeometry 400x300+100+50 --miniicon "about_kde" --title "This is a radiolist" --radiolist "Choose one of these" a English off b German off c French on d Spanish off +./kdialog --geometry 400x300+100+50 --miniicon "about_kde" --title "This is a radiolist" --radiolist "Choose one of these" a English off b German off c French on d Spanish off echo "combobox:" -./kdialog --tqgeometry 400x300+100+50 --miniicon "about_kde" --default "Chocolate" --title "This is a combobox" --combobox "Pick your favorite ice-cream flavor:" "Vanilla" "Chocolate" "Strawberry" "Fudge" +./kdialog --geometry 400x300+100+50 --miniicon "about_kde" --default "Chocolate" --title "This is a combobox" --combobox "Pick your favorite ice-cream flavor:" "Vanilla" "Chocolate" "Strawberry" "Fudge" echo "passivepopup:" -./kdialog --tqgeometry 1x1+200+350 --title "This is a passive popup" --passivepopup "It will disappear in about 10 seconds" 10 +./kdialog --geometry 1x1+200+350 --title "This is a passive popup" --passivepopup "It will disappear in about 10 seconds" 10 echo "password:" -./kdialog --title "This is a password dialog" --tqgeometry 400x300+100+50 --icon "desktop" --miniicon "about_kde" --password "Enter the password:" +./kdialog --title "This is a password dialog" --geometry 400x300+100+50 --icon "desktop" --miniicon "about_kde" --password "Enter the password:" echo "Open File:" ./kdialog --getopenfilename . "*.cpp *.cc *.c |C and C++ Source Files" diff --git a/kdialog/widgets.cpp b/kdialog/widgets.cpp index be20c51d7..a2064a5ba 100644 --- a/kdialog/widgets.cpp +++ b/kdialog/widgets.cpp @@ -218,7 +218,7 @@ bool Widgets::checkList(TQWidget *parent, const TQString& title, const TQString& table.setCurrentItem(0); // This is to circumvent a Qt bug for (unsigned int i=0; i+2<args.count(); i += 3) { - table.setSelected( i/3, args[i+2] == TQString::tqfromLatin1("on") ); + table.setSelected( i/3, args[i+2] == TQString::fromLatin1("on") ); } handleXGeometry(&box); @@ -233,7 +233,7 @@ bool Widgets::checkList(TQWidget *parent, const TQString& title, const TQString& } else { for (unsigned int i=0; i<table.count(); i++) if (table.isSelected(i)) - rs += TQString::tqfromLatin1("\"") + tags[i] + TQString::tqfromLatin1("\" "); + rs += TQString::fromLatin1("\"") + tags[i] + TQString::fromLatin1("\" "); result.append(rs); } } @@ -260,7 +260,7 @@ bool Widgets::radioBox(TQWidget *parent, const TQString& title, const TQString& table.insertStringList(entries); for (unsigned int i=0; i+2<args.count(); i += 3) { - table.setSelected( i/3, args[i+2] == TQString::tqfromLatin1("on") ); + table.setSelected( i/3, args[i+2] == TQString::fromLatin1("on") ); } handleXGeometry(&box); |