summaryrefslogtreecommitdiffstats
path: root/kolf/newgame.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kolf/newgame.cpp')
-rw-r--r--kolf/newgame.cpp42
1 files changed, 21 insertions, 21 deletions
diff --git a/kolf/newgame.cpp b/kolf/newgame.cpp
index 8ee1f7c7..36bb795e 100644
--- a/kolf/newgame.cpp
+++ b/kolf/newgame.cpp
@@ -16,7 +16,7 @@
#include <tqevent.h>
#include <tqframe.h>
#include <tqpen.h>
-#include <tqlayout.h>
+#include <layout.h>
#include <tqlabel.h>
#include <klistbox.h>
#include <tqstyle.h>
@@ -56,14 +56,14 @@ NewGameDialog::NewGameDialog(bool enableCourses, TQWidget *parent, const char *_
scroller = new TQScrollView(playerPage);
bigLayout->addWidget(scroller);
- tqlayout = new TQVBox(scroller->viewport());
+ layout = new TQVBox(scroller->viewport());
if (!TQPixmapCache::find("grass", grass))
{
grass.load(locate("appdata", "pics/grass.png"));
TQPixmapCache::insert("grass", grass);
}
scroller->viewport()->setBackgroundPixmap(grass);
- scroller->addChild(tqlayout);
+ scroller->addChild(layout);
TQMap<TQString, TQString> entries = config->entryMap("New Game Dialog");
unsigned int i = 0;
@@ -95,7 +95,7 @@ NewGameDialog::NewGameDialog(bool enableCourses, TQWidget *parent, const char *_
connect(coursesLink, TQT_SIGNAL(leftClickedURL(const TQString &)), kapp, TQT_SLOT(invokeBrowser(const TQString &)));
coursePageLayout->addWidget(coursesLink);
- TQHBoxLayout *htqlayout = new TQHBoxLayout(coursePageLayout, spacingHint());
+ TQHBoxLayout *hlayout = new TQHBoxLayout(coursePageLayout, spacingHint());
// following use this group
config->setGroup("New Game Dialog Mode");
@@ -128,13 +128,13 @@ NewGameDialog::NewGameDialog(bool enableCourses, TQWidget *parent, const char *_
nameList.append(newName);
courseList = new KListBox(coursePage);
- htqlayout->addWidget(courseList);
+ hlayout->addWidget(courseList);
courseList->insertStringList(nameList);
courseList->setCurrentItem(curItem);
connect(courseList, TQT_SIGNAL(highlighted(int)), this, TQT_SLOT(courseSelected(int)));
connect(courseList, TQT_SIGNAL(selectionChanged()), this, TQT_SLOT(selectionChanged()));
- TQVBoxLayout *detailLayout = new TQVBoxLayout(htqlayout, spacingHint());
+ TQVBoxLayout *detailLayout = new TQVBoxLayout(hlayout, spacingHint());
name = new TQLabel(coursePage);
detailLayout->addWidget(name);
author = new TQLabel(coursePage);
@@ -170,15 +170,15 @@ NewGameDialog::NewGameDialog(bool enableCourses, TQWidget *parent, const char *_
// options page
optionsPage = addPage(i18n("Options"), i18n("Game Options"));
- TQVBoxLayout *vtqlayout = new TQVBoxLayout(optionsPage, marginHint(), spacingHint());
+ TQVBoxLayout *vlayout = new TQVBoxLayout(optionsPage, marginHint(), spacingHint());
mode = new TQCheckBox(i18n("&Strict mode"), optionsPage);
- vtqlayout->addWidget(mode);
+ vlayout->addWidget(mode);
mode->setChecked(config->readBoolEntry("competition", false));
TQLabel *desc = new TQLabel(i18n("In strict mode, undo, editing, and switching holes is not allowed. This is generally for competition. Only in strict mode are highscores kept."), optionsPage);
desc->setTextFormat(RichText);
- vtqlayout->addWidget(desc);
+ vlayout->addWidget(desc);
}
void NewGameDialog::slotOk()
@@ -212,11 +212,11 @@ void NewGameDialog::courseSelected(int index)
CourseInfo &curinfo = info[currentCourse];
- name->setText(TQString("<strong>%1</strong>").tqarg(curinfo.name));
+ name->setText(TQString("<strong>%1</strong>").arg(curinfo.name));
- author->setText(i18n("By %1").tqarg(curinfo.author));
- par->setText(i18n("Par %1").tqarg(curinfo.par));
- holes->setText(i18n("%1 Holes").tqarg(curinfo.holes));
+ author->setText(i18n("By %1").arg(curinfo.author));
+ par->setText(i18n("Par %1").arg(curinfo.par));
+ holes->setText(i18n("%1 Holes").arg(curinfo.holes));
}
void NewGameDialog::showHighscores()
@@ -224,7 +224,7 @@ void NewGameDialog::showHighscores()
KScoreDialog *scoreDialog = new KScoreDialog(KScoreDialog::Name | KScoreDialog::Custom1 | KScoreDialog::Score, this);
scoreDialog->addField(KScoreDialog::Custom1, i18n("Par"), "Par");
scoreDialog->setConfigGroup(info[currentCourse].untranslatedName + TQString(" Highscores"));
- scoreDialog->setComment(i18n("High Scores for %1").tqarg(info[currentCourse].name));
+ scoreDialog->setComment(i18n("High Scores for %1").arg(info[currentCourse].name));
scoreDialog->show();
}
@@ -253,7 +253,7 @@ void NewGameDialog::selectionChanged()
void NewGameDialog::addCourse()
{
- TQStringList files = KFileDialog::getOpenFileNames(":kourses", TQString::tqfromLatin1("application/x-kourse"), this, i18n("Pick Kolf Course"));
+ TQStringList files = KFileDialog::getOpenFileNames(":kourses", TQString::fromLatin1("application/x-kourse"), this, i18n("Pick Kolf Course"));
bool hasDuplicates = false;
@@ -287,7 +287,7 @@ void NewGameDialog::addPlayer()
if (editors.count() >= startColors.count())
return;
- editors.append(new PlayerEditor(i18n("Player %1").tqarg(editors.count() + 1), *startColors.at(editors.count()), tqlayout));
+ editors.append(new PlayerEditor(i18n("Player %1").arg(editors.count() + 1), *startColors.at(editors.count()), layout));
editors.last()->show();
connect(editors.last(), TQT_SIGNAL(deleteEditor(PlayerEditor *)), this, TQT_SLOT(deleteEditor(PlayerEditor *)));
@@ -314,7 +314,7 @@ void NewGameDialog::enableButtons()
PlayerEditor::PlayerEditor(TQString startName, TQColor startColor, TQWidget *parent, const char *_name)
: TQWidget(parent, _name)
{
- TQHBoxLayout *tqlayout = new TQHBoxLayout(this, KDialogBase::spacingHint());
+ TQHBoxLayout *layout = new TQHBoxLayout(this, KDialogBase::spacingHint());
if (!TQPixmapCache::find("grass", grass))
{
@@ -324,17 +324,17 @@ PlayerEditor::PlayerEditor(TQString startName, TQColor startColor, TQWidget *par
setBackgroundPixmap(grass);
editor = new KLineEdit(this);
- tqlayout->addWidget(editor);
+ layout->addWidget(editor);
editor->setFrame(false);
editor->setText(startName);
- tqlayout->addStretch();
- tqlayout->addWidget(colorButton = new KColorButton(startColor, this));
+ layout->addStretch();
+ layout->addWidget(colorButton = new KColorButton(startColor, this));
colorButton->setAutoMask(true);
colorButton->setBackgroundPixmap(grass);
KPushButton *remove = new KPushButton(i18n("Remove"), this);
remove->setAutoMask(true);
- tqlayout->addWidget(remove);
+ layout->addWidget(remove);
remove->setBackgroundPixmap(grass);
connect(remove, TQT_SIGNAL(clicked()), this, TQT_SLOT(removeMe()));
}