Rename obsolete tq methods to standard names

pull/1/head
Timothy Pearson 13 years ago
parent 98fe2a53a7
commit 864fecb39f

@ -76,7 +76,7 @@ Knowit::Knowit(TQWidget*, const char *name) : KMainWindow(0, name),
setAutoSaveSettings();
setCentralWidget(Layout);
TQWhatsThis::add(Layout, i18n("Move it to change tree/edit tqlayout."));
TQWhatsThis::add(Layout, i18n("Move it to change tree/edit layout."));
connect(Items, TQT_SIGNAL(contextMenu(KListView*, TQListViewItem*, const TQPoint&)),
TQT_TQOBJECT(this), TQT_SLOT(slotContextMenu(KListView*, TQListViewItem*, const TQPoint&)));
connect(Items, TQT_SIGNAL(selectionChanged(TQListViewItem*)), this,
@ -1322,7 +1322,7 @@ void Knowit::slotLinkCopy()
{
if (Links->currentItem() == -1) return;
TNoteLink link = currentNote()->link(Links->currentItem());
kapp->tqclipboard()->setText(link.link, TQClipboard::Clipboard);
kapp->tqclipboard()->setText(link.link, TQClipboard::Selection);
kapp->clipboard()->setText(link.link, TQClipboard::Clipboard);
kapp->clipboard()->setText(link.link, TQClipboard::Selection);
}

@ -31,28 +31,28 @@ KnowitChooser::KnowitChooser(int flags)
{
TQLabel* l1;
TQLabel* l2;
TQVBoxLayout* tqlayout = new TQVBoxLayout(plainPage());
tqlayout->addWidget(l1 = new TQLabel(i18n("&Exported notes:"), plainPage()));
tqlayout->addWidget(notes = new KComboBox(plainPage(), "Notes"));
TQVBoxLayout* layout = new TQVBoxLayout(plainPage());
layout->addWidget(l1 = new TQLabel(i18n("&Exported notes:"), plainPage()));
layout->addWidget(notes = new KComboBox(plainPage(), "Notes"));
l1->setBuddy(notes);
notes->insertItem(i18n("All"));
notes->insertItem(i18n("Current with children"));
notes->insertItem(i18n("Current only"));
tqlayout->addWidget(l2 = new TQLabel(i18n("&Encoding:"), plainPage()));
tqlayout->addWidget(charset = new KComboBox(plainPage(), "Encoding"));
layout->addWidget(l2 = new TQLabel(i18n("&Encoding:"), plainPage()));
layout->addWidget(charset = new KComboBox(plainPage(), "Encoding"));
l2->setBuddy(charset);
charset->insertItem(i18n("Local (8-bit)"));
charset->insertItem(i18n("UTF-8"));
tqlayout->addItem(new TQSpacerItem(0, 10));
tqlayout->addWidget(enumerate = new TQCheckBox(i18n("Numbered titles"),
layout->addItem(new TQSpacerItem(0, 10));
layout->addWidget(enumerate = new TQCheckBox(i18n("Numbered titles"),
plainPage(), "Numbered"));
tqlayout->addWidget(toc = new TQCheckBox(i18n("Table of contents"),
layout->addWidget(toc = new TQCheckBox(i18n("Table of contents"),
plainPage(), "TOC"));
tqlayout->addWidget(rule = new TQCheckBox(i18n("Rule betweeen notes"),
layout->addWidget(rule = new TQCheckBox(i18n("Rule betweeen notes"),
plainPage(), "Rule"));
tqlayout->addWidget(style = new TQCheckBox(i18n("Use editor font and colors"),
layout->addWidget(style = new TQCheckBox(i18n("Use editor font and colors"),
plainPage(), "Style"));
setChoice(flags);
}

@ -33,27 +33,27 @@
KnowitLinkDialog::KnowitLinkDialog()
: KDialogBase(Plain, i18n("Modify link"), Ok|Cancel, Ok)
{
TQVBoxLayout* tqlayout = new TQVBoxLayout(plainPage());
TQVBoxLayout* layout = new TQVBoxLayout(plainPage());
TQHBox* typeBox = new TQHBox(plainPage());
tqlayout->addWidget(typeBox);
layout->addWidget(typeBox);
new TQLabel(i18n("Referenced item:"), typeBox);
linkType = new KComboBox(typeBox, "LinkType");
linkType->insertItem(i18n("File or URL"));
linkType->insertItem(i18n("KnowIt note"));
tqlayout->addItem(new TQSpacerItem(0, 5));
layout->addItem(new TQSpacerItem(0, 5));
TQHBox* editBox = new TQHBox(plainPage());
tqlayout->addWidget(editBox);
layout->addWidget(editBox);
linkValue = new KLineEdit("Link text", editBox);
linkValue->setMinimumWidth(300);
browse = new TQToolButton(editBox, "Browse");
browse->setIconSet(TQIconSet(KGlobal::iconLoader()->loadIcon("fileopen",
KIcon::Toolbar, KIcon::SizeSmall)));
tqlayout->addItem(new TQSpacerItem(0, 5));
tqlayout->addWidget(new TQLabel(i18n("Link description:"), plainPage()));
tqlayout->addWidget(linkDescription = new KLineEdit("Link description", plainPage()));
layout->addItem(new TQSpacerItem(0, 5));
layout->addWidget(new TQLabel(i18n("Link description:"), plainPage()));
layout->addWidget(linkDescription = new KLineEdit("Link description", plainPage()));
connect(browse, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotBrowse()));
connect(linkType, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotTypeChanged(int)));

@ -132,17 +132,17 @@ KnowitPreferences::KnowitPreferences()
: KDialogBase(IconList, i18n("KnowIt Preferences"), Ok|Cancel, Ok)
{
TQFrame* page;
TQVBoxLayout* tqlayout;
TQVBoxLayout* layout;
/* first page: General */
page = addPage(i18n("General"), i18n("General options"),
KGlobal::iconLoader()->loadIcon(TQString("configure"), KIcon::Toolbar, KIcon::SizeMedium));
tqlayout = new TQVBoxLayout(page, 0, spacingHint());
tqlayout->addWidget(docked = new TQCheckBox(i18n("&Dock in System tray"), page, "Dock"));
tqlayout->addWidget(reopen = new TQCheckBox(i18n("Open &last file on startup"), page, "Reopen"));
layout = new TQVBoxLayout(page, 0, spacingHint());
layout->addWidget(docked = new TQCheckBox(i18n("&Dock in System tray"), page, "Dock"));
layout->addWidget(reopen = new TQCheckBox(i18n("Open &last file on startup"), page, "Reopen"));
TQHBox* autosaveBox = new TQHBox(page);
tqlayout->addWidget(autosaveBox);
layout->addWidget(autosaveBox);
new TQLabel(i18n("Autosave:"), autosaveBox);
autosave = new TQSpinBox(0, 120, 5, autosaveBox, "Autosave");
autosave->setPrefix(i18n("every "));
@ -151,32 +151,32 @@ KnowitPreferences::KnowitPreferences()
TQWhatsThis::add(autosave, i18n("Current file will be automatically saved "
"after the specified interval. Set to <i>never</i> to disable autosave."));
tqlayout->addWidget(unconditionalSave = new TQCheckBox(i18n("Automatically save file on e&xit"),
layout->addWidget(unconditionalSave = new TQCheckBox(i18n("Automatically save file on e&xit"),
page, "UnconditionalSave"));
TQWhatsThis::add(unconditionalSave, i18n("Current file will be automatically saved "
"on exit without confirmation."));
tqlayout->addWidget(backup = new TQCheckBox(i18n("Create &backups"),
layout->addWidget(backup = new TQCheckBox(i18n("Create &backups"),
page, "Backup"));
TQWhatsThis::add(backup, i18n("Create backup of current document before it is saved."));
tqlayout->addWidget(multipleInstances = new TQCheckBox(i18n("Allow &multiple instances of KnowIt"),
layout->addWidget(multipleInstances = new TQCheckBox(i18n("Allow &multiple instances of KnowIt"),
page, "Instances"));
TQWhatsThis::add(multipleInstances, i18n("If this option is disabled, only one "
"instance of KnowIt will be allowed. If there is another instance already running, "
"it will be automatically activated instead of running new one."));
tqlayout->addStretch(1);
layout->addStretch(1);
/* second page: Interface */
page = addPage(i18n("Interface"), i18n("Interface options"),
KGlobal::iconLoader()->loadIcon(TQString("misc"), KIcon::Toolbar, KIcon::SizeMedium));
tqlayout = new TQVBoxLayout(page, 0, spacingHint());
tqlayout->addWidget(horizontalSplit = new TQCheckBox(i18n("Split window &horizontally"), page, "Split"));
layout = new TQVBoxLayout(page, 0, spacingHint());
layout->addWidget(horizontalSplit = new TQCheckBox(i18n("Split window &horizontally"), page, "Split"));
TQWhatsThis::add(horizontalSplit, i18n("If this option is set, notes tree will "
"be displayed on the left and the editor on the right (this is default).<br>"
"Otherwise notes tree will be displayed at the top and the editor at the bottom."));
TQHBox* defaultNameBox = new TQHBox(page);
tqlayout->addWidget(defaultNameBox);
layout->addWidget(defaultNameBox);
new TQLabel(i18n("Default note name:"), defaultNameBox);
defaultName = new KLineEdit(defaultNameBox, "DefaultName");
TQWhatsThis::add(defaultName, i18n("Default name for new notes. It would be "
@ -184,7 +184,7 @@ KnowitPreferences::KnowitPreferences()
"consider setting default name to none."));
TQHBox* linkBox = new TQHBox(page);
tqlayout->addWidget(linkBox);
layout->addWidget(linkBox);
new TQLabel(i18n("Link format:"), linkBox);
linkFormat = new KComboBox(linkBox, "LinkFormat");
linkFormat->insertItem(i18n("Description (link)"));
@ -193,31 +193,31 @@ KnowitPreferences::KnowitPreferences()
linkFormat->insertItem(i18n("Description only"));
TQHBox* alternateBox = new TQHBox(page);
tqlayout->addWidget(alternateBox);
layout->addWidget(alternateBox);
alternateTree = new TQCheckBox(i18n("Alternate colors in tree"), alternateBox, "Alternate");
alternateColor = new KColorButton(TQColor("White"), alternateBox, "AlternateColor");
tqlayout->addWidget(autoCollapse = new TQCheckBox(i18n("Automatically collapse other notes"), page, "AutoCollapse"));
layout->addWidget(autoCollapse = new TQCheckBox(i18n("Automatically collapse other notes"), page, "AutoCollapse"));
TQWhatsThis::add(autoCollapse, i18n("If this option is set, only current subtree "
"will be visible, other notes will be automatically collapsed."));
tqlayout->addStretch(1);
layout->addStretch(1);
/* third page: Editor */
page = addPage(i18n("Editor"), i18n("Editor options"),
KGlobal::iconLoader()->loadIcon(TQString("edit"), KIcon::Toolbar, KIcon::SizeMedium));
tqlayout = new TQVBoxLayout(page, 0, spacingHint());
tqlayout->addWidget(wordwrap = new TQCheckBox(i18n("Use &word wrap"),
layout = new TQVBoxLayout(page, 0, spacingHint());
layout->addWidget(wordwrap = new TQCheckBox(i18n("Use &word wrap"),
page, "WordWrap"));
tqlayout->addWidget(enterBreakLine = new TQCheckBox(i18n("'Enter' ends current line, not paragraph"),
layout->addWidget(enterBreakLine = new TQCheckBox(i18n("'Enter' ends current line, not paragraph"),
page, "EnterLineBreak"));
tqlayout->addWidget(tabfocus = new TQCheckBox(i18n("'Tab' in editor changes focus"),
layout->addWidget(tabfocus = new TQCheckBox(i18n("'Tab' in editor changes focus"),
page, "TabFocus"));
#if TDE_VERSION_MAJOR == 3 && TDE_VERSION_MINOR < 1
tabfocus->hide();
#endif
TQHBox* colorBox = new TQHBox(page);
tqlayout->addWidget(colorBox);
layout->addWidget(colorBox);
customColors = new TQCheckBox(i18n("Use &custom colors"), colorBox, "CustomColors");
editColors = new KDualColorButton(colorBox);
@ -226,7 +226,7 @@ KnowitPreferences::KnowitPreferences()
KFontChooser::getFontList(fontList, false);
TQHBox* fontBox = new TQHBox(page);
tqlayout->addWidget(fontBox);
layout->addWidget(fontBox);
customFont = new TQCheckBox(i18n("Use custom font:"), fontBox, "customFont");
fontFamily = new KComboBox(true, fontBox);
fontFamily->insertStringList(fontList);
@ -235,13 +235,13 @@ KnowitPreferences::KnowitPreferences()
fontSize->insertItem(TQString(TQString().setNum(fontSizes[i])),i);
}
tqlayout->addStretch(1);
layout->addStretch(1);
/* fourth page: Templates */
page = addPage(i18n("Templates"), i18n("Templates configuration"),
KGlobal::iconLoader()->loadIcon(TQString("wizard"), KIcon::Toolbar, KIcon::SizeMedium));
tqlayout = new TQVBoxLayout(page, 0, spacingHint());
layout = new TQVBoxLayout(page, 0, spacingHint());
TQWhatsThis::add(page, i18n("<html>\n"
"<p>These expressions may be used: </p>\n"
"<table>\n"
@ -266,13 +266,13 @@ KnowitPreferences::KnowitPreferences()
"</table></html>"));
TQHBox* topBox = new TQHBox(page);
tqlayout->addWidget(topBox);
layout->addWidget(topBox);
TQLabel * label1 = new TQLabel(i18n("Date Format: "), topBox);
label1->setFixedSize(label1->sizeHint());
insertDatePreview = new TQLabel("", topBox);
TQHBox *tmpBox = new TQHBox(page);
tqlayout->addWidget(tmpBox);
layout->addWidget(tmpBox);
insertDateColorButton = new KColorButton(TQColor("Blue"), tmpBox, "InsertDateColorButton");
insertDateFormatEdit = new KLineEdit(tmpBox, "InsertDateFormatEdit");
insertDateItalicButton = new TQToolButton(tmpBox,"InsertDateItalicButton");
@ -286,7 +286,7 @@ KnowitPreferences::KnowitPreferences()
insertDateUnderlineButton->setToggleButton(true);
insertDateColorButton->setFixedSize(insertDateBoldButton->sizeHint());
insertDateFormatEdit->setMinimumWidth(6*insertDateBoldButton->sizeHint().width());
tqlayout->addStretch(1);
layout->addStretch(1);
setIconListAllVisible(true);
}

Loading…
Cancel
Save