summaryrefslogtreecommitdiffstats
path: root/kommander
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-16 19:02:47 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-16 19:02:47 +0000
commite985f7e545f4739493965aad69bbecb136dc9346 (patch)
tree54afd409d8acd6202dd8ab611d24e78c28e4c0a0 /kommander
parentf7670c198945adc3b95ad69a959fe5f8ae55b493 (diff)
downloadtdewebdev-e985f7e545f4739493965aad69bbecb136dc9346.tar.gz
tdewebdev-e985f7e545f4739493965aad69bbecb136dc9346.zip
TQt4 port kdewebdev
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdewebdev@1237029 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kommander')
-rw-r--r--kommander/Kommander-TODO.kno24
-rw-r--r--kommander/editor/actiondnd.cpp438
-rw-r--r--kommander/editor/actiondnd.h86
-rw-r--r--kommander/editor/actioneditor.ui16
-rw-r--r--kommander/editor/actioneditorimpl.cpp31
-rw-r--r--kommander/editor/actioneditorimpl.h5
-rw-r--r--kommander/editor/actionlistview.cpp14
-rw-r--r--kommander/editor/actionlistview.h29
-rw-r--r--kommander/editor/asciivalidator.cpp16
-rw-r--r--kommander/editor/asciivalidator.h11
-rw-r--r--kommander/editor/assistproc.cpp6
-rw-r--r--kommander/editor/assistproc.h9
-rw-r--r--kommander/editor/assoctexteditor.ui38
-rw-r--r--kommander/editor/assoctexteditorimpl.cpp48
-rw-r--r--kommander/editor/assoctexteditorimpl.h1
-rw-r--r--kommander/editor/choosewidget.ui24
-rw-r--r--kommander/editor/choosewidgetimpl.cpp14
-rw-r--r--kommander/editor/choosewidgetimpl.h3
-rw-r--r--kommander/editor/command.cpp384
-rw-r--r--kommander/editor/command.h81
-rw-r--r--kommander/editor/connectioneditor.ui42
-rw-r--r--kommander/editor/connectioneditorimpl.cpp82
-rw-r--r--kommander/editor/connectioneditorimpl.h10
-rw-r--r--kommander/editor/createtemplate.ui22
-rw-r--r--kommander/editor/defs.cpp2
-rw-r--r--kommander/editor/defs.h2
-rw-r--r--kommander/editor/filechooser.cpp14
-rw-r--r--kommander/editor/filechooser.h9
-rw-r--r--kommander/editor/formfile.cpp24
-rw-r--r--kommander/editor/formfile.h5
-rw-r--r--kommander/editor/formsettings.ui36
-rw-r--r--kommander/editor/formsettingsimpl.cpp14
-rw-r--r--kommander/editor/formsettingsimpl.h5
-rw-r--r--kommander/editor/formwindow.cpp576
-rw-r--r--kommander/editor/formwindow.h37
-rw-r--r--kommander/editor/functions.ui100
-rw-r--r--kommander/editor/functionsimpl.cpp40
-rw-r--r--kommander/editor/functionsimpl.h1
-rw-r--r--kommander/editor/globaldefs.h2
-rw-r--r--kommander/editor/hierarchyview.cpp144
-rw-r--r--kommander/editor/hierarchyview.h26
-rw-r--r--kommander/editor/iconvieweditor.ui58
-rw-r--r--kommander/editor/iconvieweditorimpl.cpp8
-rw-r--r--kommander/editor/iconvieweditorimpl.h5
-rw-r--r--kommander/editor/kommander-new.xml18
-rw-r--r--kommander/editor/kommander.xml26
-rw-r--r--kommander/editor/layout.cpp298
-rw-r--r--kommander/editor/layout.h45
-rw-r--r--kommander/editor/listboxeditor.ui56
-rw-r--r--kommander/editor/listboxeditorimpl.cpp8
-rw-r--r--kommander/editor/listboxeditorimpl.h5
-rw-r--r--kommander/editor/listeditor.ui22
-rw-r--r--kommander/editor/listvieweditor.ui120
-rw-r--r--kommander/editor/listvieweditorimpl.cpp44
-rw-r--r--kommander/editor/listvieweditorimpl.h7
-rw-r--r--kommander/editor/main.cpp2
-rw-r--r--kommander/editor/mainwindow.cpp290
-rw-r--r--kommander/editor/mainwindow.h13
-rw-r--r--kommander/editor/mainwindowactions.cpp288
-rw-r--r--kommander/editor/messagelog.cpp10
-rw-r--r--kommander/editor/messagelog.h5
-rw-r--r--kommander/editor/metadatabase.cpp206
-rw-r--r--kommander/editor/metadatabase.h6
-rw-r--r--kommander/editor/multilineeditor.ui20
-rw-r--r--kommander/editor/multilineeditorimpl.cpp20
-rw-r--r--kommander/editor/multilineeditorimpl.h10
-rw-r--r--kommander/editor/newform.ui32
-rw-r--r--kommander/editor/newformimpl.cpp28
-rw-r--r--kommander/editor/newformimpl.h7
-rw-r--r--kommander/editor/orderindicator.cpp6
-rw-r--r--kommander/editor/orderindicator.h5
-rw-r--r--kommander/editor/paletteeditor.ui46
-rw-r--r--kommander/editor/paletteeditoradvanced.ui62
-rw-r--r--kommander/editor/paletteeditoradvancedimpl.cpp24
-rw-r--r--kommander/editor/paletteeditoradvancedimpl.h7
-rw-r--r--kommander/editor/paletteeditorimpl.cpp10
-rw-r--r--kommander/editor/paletteeditorimpl.h7
-rw-r--r--kommander/editor/parser.cpp16
-rw-r--r--kommander/editor/parser.h2
-rw-r--r--kommander/editor/pics/images.h58
-rw-r--r--kommander/editor/pixmapchooser.cpp50
-rw-r--r--kommander/editor/pixmapchooser.h16
-rw-r--r--kommander/editor/pixmapfunction.ui32
-rw-r--r--kommander/editor/preferences.ui62
-rw-r--r--kommander/editor/previewframe.cpp8
-rw-r--r--kommander/editor/previewframe.h14
-rw-r--r--kommander/editor/previewwidget.ui44
-rw-r--r--kommander/editor/previewwidgetimpl.cpp8
-rw-r--r--kommander/editor/previewwidgetimpl.h5
-rw-r--r--kommander/editor/propertyeditor.cpp350
-rw-r--r--kommander/editor/propertyeditor.h52
-rw-r--r--kommander/editor/qcompletionedit.cpp16
-rw-r--r--kommander/editor/qcompletionedit.h13
-rw-r--r--kommander/editor/resource.cpp507
-rw-r--r--kommander/editor/resource.h14
-rw-r--r--kommander/editor/sizehandle.cpp62
-rw-r--r--kommander/editor/sizehandle.h9
-rw-r--r--kommander/editor/styledbutton.cpp42
-rw-r--r--kommander/editor/styledbutton.h25
-rw-r--r--kommander/editor/tableeditor.ui118
-rw-r--r--kommander/editor/tableeditorimpl.cpp60
-rw-r--r--kommander/editor/tableeditorimpl.h3
-rw-r--r--kommander/editor/templates/Configuration_Dialog.ui22
-rw-r--r--kommander/editor/templates/Dialog_with_Buttons_(Bottom).ui14
-rw-r--r--kommander/editor/templates/Dialog_with_Buttons_(Right).ui14
-rw-r--r--kommander/editor/templates/Tab_Dialog.ui20
-rw-r--r--kommander/editor/timestamp.cpp6
-rw-r--r--kommander/editor/timestamp.h7
-rw-r--r--kommander/editor/widgetdatabase.cpp138
-rw-r--r--kommander/editor/widgetdatabase.h8
-rw-r--r--kommander/editor/widgetfactory.cpp824
-rw-r--r--kommander/editor/widgetfactory.h217
-rw-r--r--kommander/editor/widgetinterface.h8
-rw-r--r--kommander/editor/wizardeditor.ui40
-rw-r--r--kommander/editor/wizardeditorimpl.cpp20
-rw-r--r--kommander/editor/wizardeditorimpl.h5
-rw-r--r--kommander/editor/workspace.cpp54
-rw-r--r--kommander/editor/workspace.h19
-rwxr-xr-xkommander/examples/current/a1.kmdr16
-rwxr-xr-xkommander/examples/current/b1.kmdr12
-rwxr-xr-xkommander/examples/current/editor-poc.kmdr22
-rw-r--r--kommander/examples/current/keyvaluecombo.kmdr12
-rwxr-xr-xkommander/examples/current/kpartmwframe.kmdr8
-rwxr-xr-xkommander/examples/current/kpartpart.kmdr18
-rw-r--r--kommander/examples/current/passvariables.kmdr24
-rwxr-xr-xkommander/examples/current/tableselect.kmdr10
-rw-r--r--kommander/examples/old/checkmail.kmdr2
-rw-r--r--kommander/examples/old/ex1.kmdr2
-rw-r--r--kommander/examples/old/execprogram.kmdr8
-rw-r--r--kommander/examples/old/firstform.kmdr.kmdr4
-rw-r--r--kommander/examples/old/form1.kmdr2
-rw-r--r--kommander/examples/old/form2.kmdr6
-rw-r--r--kommander/examples/old/form3.kmdr2
-rw-r--r--kommander/examples/old/form4.kmdr4
-rw-r--r--kommander/examples/old/form5.kmdr6
-rw-r--r--kommander/examples/old/newfile.kmdr6
-rw-r--r--kommander/examples/old/populate.kmdr6
-rw-r--r--kommander/examples/old/resize.kmdr20
-rw-r--r--kommander/examples/old/selectedwidgettext.kmdr6
-rw-r--r--kommander/examples/old/settings.kmdr16
-rw-r--r--kommander/examples/old/simplelist.kmdr4
-rw-r--r--kommander/examples/old/tar.kmdr24
-rw-r--r--kommander/examples/old/tidy.kmdr26
-rw-r--r--kommander/examples/old/widgetgenerator.kmdr32
-rwxr-xr-xkommander/examples/old/wizard.kmdr10
-rw-r--r--kommander/examples/tutorial/append.kmdr8
-rw-r--r--kommander/examples/tutorial/arrays.kmdr10
-rw-r--r--kommander/examples/tutorial/calc.kmdr28
-rw-r--r--kommander/examples/tutorial/cmdline.kmdr6
-rw-r--r--kommander/examples/tutorial/dcop.kmdr8
-rw-r--r--kommander/examples/tutorial/dialogs.kmdr4
-rw-r--r--kommander/examples/tutorial/globals.kmdr4
-rw-r--r--kommander/examples/tutorial/initialize.kmdr12
-rw-r--r--kommander/examples/tutorial/loop.kmdr6
-rw-r--r--kommander/examples/tutorial/picview.kmdr10
-rw-r--r--kommander/examples/tutorial/progressbar.kmdr10
-rw-r--r--kommander/examples/tutorial/settings.kmdr16
-rw-r--r--kommander/examples/tutorial/slots.kmdr16
-rw-r--r--kommander/examples/tutorial/statusbar.kmdr2
-rw-r--r--kommander/examples/tutorial/strings.kmdr18
-rw-r--r--kommander/examples/tutorial/table.kmdr8
-rw-r--r--kommander/examples/tutorial/tree.kmdr10
-rw-r--r--kommander/examples/tutorial/widgets.kmdr8
-rw-r--r--kommander/executor/dcopkommanderif.h2
-rw-r--r--kommander/executor/instance.cpp26
-rw-r--r--kommander/executor/instance.h7
-rw-r--r--kommander/executor/main.cpp2
-rw-r--r--kommander/executor/register.cpp8
-rw-r--r--kommander/factory/domtool.cpp10
-rw-r--r--kommander/factory/domtool.h4
-rw-r--r--kommander/factory/kommanderfactory.cpp367
-rw-r--r--kommander/factory/kommanderfactory.h22
-rwxr-xr-xkommander/kmdrtools/dcoptool-oldparser.kmdr74
-rwxr-xr-xkommander/kmdrtools/examples.kmdr8
-rw-r--r--kommander/part/kommander_part.cpp10
-rw-r--r--kommander/part/kommander_part.h5
-rw-r--r--kommander/plugin/kommanderplugin.h23
-rw-r--r--kommander/plugin/specialinformation.cpp58
-rw-r--r--kommander/plugin/specialinformation.h10
-rw-r--r--kommander/plugin/specials.h10
-rw-r--r--kommander/pluginmanager/main.cpp6
-rw-r--r--kommander/pluginmanager/mainwindow.cpp6
-rw-r--r--kommander/pluginmanager/mainwindow.h3
-rw-r--r--kommander/pluginmanager/pluginmanager.cpp4
-rw-r--r--kommander/widget/expression.cpp2
-rw-r--r--kommander/widget/functionlib.cpp62
-rw-r--r--kommander/widget/invokeclass.cpp10
-rw-r--r--kommander/widget/invokeclass.h3
-rw-r--r--kommander/widget/kmdrmainwindow.cpp4
-rw-r--r--kommander/widget/kmdrmainwindow.h3
-rw-r--r--kommander/widget/kommanderfunctions.cpp34
-rw-r--r--kommander/widget/kommanderwidget.cpp90
-rw-r--r--kommander/widget/kommanderwidget.h12
-rw-r--r--kommander/widget/myprocess.cpp10
-rw-r--r--kommander/widget/myprocess.h3
-rw-r--r--kommander/widget/parsenode.cpp4
-rw-r--r--kommander/widget/parser.cpp44
-rw-r--r--kommander/widget/parser.h4
-rw-r--r--kommander/widget/parserdata.cpp6
-rw-r--r--kommander/widgets/aboutdialog.cpp4
-rw-r--r--kommander/widgets/aboutdialog.h9
-rw-r--r--kommander/widgets/buttongroup.cpp10
-rw-r--r--kommander/widgets/buttongroup.h7
-rw-r--r--kommander/widgets/checkbox.cpp6
-rw-r--r--kommander/widgets/checkbox.h7
-rw-r--r--kommander/widgets/closebutton.cpp12
-rw-r--r--kommander/widgets/closebutton.h9
-rw-r--r--kommander/widgets/combobox.cpp8
-rw-r--r--kommander/widgets/combobox.h7
-rw-r--r--kommander/widgets/datepicker.cpp6
-rw-r--r--kommander/widgets/datepicker.h7
-rw-r--r--kommander/widgets/dialog.cpp18
-rw-r--r--kommander/widgets/dialog.h15
-rw-r--r--kommander/widgets/execbutton.cpp16
-rw-r--r--kommander/widgets/execbutton.h11
-rw-r--r--kommander/widgets/fileselector.cpp12
-rw-r--r--kommander/widgets/fileselector.h19
-rw-r--r--kommander/widgets/fontdialog.cpp4
-rw-r--r--kommander/widgets/fontdialog.h10
-rw-r--r--kommander/widgets/groupbox.cpp10
-rw-r--r--kommander/widgets/groupbox.h7
-rw-r--r--kommander/widgets/konsole.cpp4
-rw-r--r--kommander/widgets/konsole.h9
-rw-r--r--kommander/widgets/label.cpp6
-rw-r--r--kommander/widgets/label.h7
-rw-r--r--kommander/widgets/lineedit.cpp6
-rw-r--r--kommander/widgets/lineedit.h7
-rw-r--r--kommander/widgets/listbox.cpp16
-rw-r--r--kommander/widgets/listbox.h7
-rw-r--r--kommander/widgets/pixmaplabel.cpp6
-rw-r--r--kommander/widgets/pixmaplabel.h7
-rw-r--r--kommander/widgets/plugin.cpp70
-rw-r--r--kommander/widgets/popupmenu.cpp12
-rw-r--r--kommander/widgets/popupmenu.h9
-rw-r--r--kommander/widgets/progressbar.cpp10
-rw-r--r--kommander/widgets/progressbar.h7
-rw-r--r--kommander/widgets/radiobutton.cpp6
-rw-r--r--kommander/widgets/radiobutton.h7
-rw-r--r--kommander/widgets/richtexteditor.cpp30
-rw-r--r--kommander/widgets/richtexteditor.h9
-rw-r--r--kommander/widgets/scriptobject.cpp8
-rw-r--r--kommander/widgets/scriptobject.h7
-rw-r--r--kommander/widgets/slider.cpp2
-rw-r--r--kommander/widgets/slider.h8
-rw-r--r--kommander/widgets/spinboxint.cpp6
-rw-r--r--kommander/widgets/spinboxint.h7
-rw-r--r--kommander/widgets/statusbar.cpp6
-rw-r--r--kommander/widgets/statusbar.h7
-rw-r--r--kommander/widgets/subdialog.cpp2
-rw-r--r--kommander/widgets/subdialog.h9
-rw-r--r--kommander/widgets/table.cpp12
-rw-r--r--kommander/widgets/table.h9
-rw-r--r--kommander/widgets/tabwidget.cpp2
-rw-r--r--kommander/widgets/tabwidget.h7
-rw-r--r--kommander/widgets/textbrowser.cpp2
-rw-r--r--kommander/widgets/textbrowser.h7
-rw-r--r--kommander/widgets/textedit.cpp12
-rw-r--r--kommander/widgets/textedit.h8
-rw-r--r--kommander/widgets/timer.cpp2
-rw-r--r--kommander/widgets/timer.h11
-rw-r--r--kommander/widgets/toolbox.cpp8
-rw-r--r--kommander/widgets/toolbox.h9
-rw-r--r--kommander/widgets/treewidget.cpp56
-rw-r--r--kommander/widgets/treewidget.h11
-rw-r--r--kommander/widgets/wizard.cpp2
-rw-r--r--kommander/widgets/wizard.h11
-rw-r--r--kommander/working/plugintemplate/plugin.cpp6
-rw-r--r--kommander/working/plugintemplate/src-Makefile.am2
-rw-r--r--kommander/working/plugintemplate/widget.cpp10
-rw-r--r--kommander/working/plugintemplate/widget.h9
270 files changed, 4802 insertions, 4650 deletions
diff --git a/kommander/Kommander-TODO.kno b/kommander/Kommander-TODO.kno
index ebbe5651..d21460b5 100644
--- a/kommander/Kommander-TODO.kno
+++ b/kommander/Kommander-TODO.kno
@@ -16,10 +16,10 @@
\NewEntry 1 Editor
<html><head><meta name="qrichtext" content="1" /></head><body style="font-size:10pt;font-family:Sans Serif">
<p><span style="font-weight:600">Layout of Edit Kommander Text dialog<br /><br />Old ideas:</span></p>
-<ul type="disc"><li>better layout</li>
+<ul type="disc"><li>better tqlayout</li>
<li>replace list of widgets with tree of widgets</li>
<li>replace widget class with widget pixmap in combos</li>
-<li>redesign layout</li>
+<li>redesign tqlayout</li>
<li>cleanup Connections, not it is unusable, may be obsolete</li>
<li>find in scripts</li>
<li>list of non-empty scripts for current dialog</li>
@@ -37,7 +37,7 @@
<li>use KDE dialogs, not Qt ones if possible</li>
<li>some widget information on mouseover</li>
<li>review of event model</li>
-<li>add more layout-handling commands (center selected widgets horizontally/vertically, fit to window width/height)</li>
+<li>add more tqlayout-handling commands (center selected widgets horizontally/vertically, fit to window width/height)</li>
<li>handle middle click</li>
<li>carefully check defaults, choose most useful ones</li>
<li>add wizards? (replace current New dialogs with Kommander-based ones?)</li>
@@ -72,8 +72,8 @@
\NewEntry 1 Other
<html><head><meta name="qrichtext" content="1" /></head><body style="font-size:10pt;font-family:Sans Serif">
<p><span style="font-weight:600">Other GUI-related issues</span></p>
-<ul type="disc"><li>cleanup slots/signals/connections interface</li>
-<li>find out why slots are shown only for current tab<br /></li></ul>
+<ul type="disc"><li>cleanup Q_SLOTS/Q_SIGNALS/connections interface</li>
+<li>find out why Q_SLOTS are shown only for current tab<br /></li></ul>
<p><span style="font-weight:600">KDE4 ideas:<br /></span></p>
<ul type="disc"><li>create a KDevelop plugin for the editor</li>
<li>use KFormDesigner or the new Qt Designer</li></ul>
@@ -85,7 +85,7 @@
<ul type="disc"><li>Charset is sometimes incorrectly converted from/to local charset</li>
<li>SubDialog crashes now</li>
<li>Labels do not show up unless you edit their text</li>
-<li>toolbox editing is ugly after group layout is applied. Goes back to normal if the dialog is reloaded.</li>
+<li>toolbox editing is ugly after group tqlayout is applied. Goes back to normal if the dialog is reloaded.</li>
<div></div></ul>
</body></html>
@@ -147,7 +147,7 @@
<ul type="disc"><li>detect incorrect path at shebang, allow user to choose correct one and remeber that pair</li>
<div></div>
<div></div></ul>
-<p><span style="font-weight:600">If we keep the old parser.<br /><br /></span><br />Make it possible to use any language with Kommander. The idea is to replace Kommander specials with language specific code in a way that it will not break conditions and loops, like now. example:<br />#!/bin/bash<br />array=&quot;1 2 3 4 5&quot;<br />for i in $array do<br /> @Label.setText($i)<br />done<br /><br />This does not work now. The idea is to replace @Widget.method() with a language specific DCOP call.<br />If the language has DCOP bindings, use those bindings to execute the dcop call. If not, use the command line<br />DCOP application. This is slower, but always works. In the above case, Kommander would replace <br />@Label.setText($i) <br />with<br />dcop kmdr-executor-PID KommanderIf setText Label $i<br /><br />Kommander will have description files for each supported language about how to execute DCOP calls.<br />If the language has DCOP bindings, this description tells the syntax of the bindings. If it doesn't have, the description gives a way how to execute external applications. This should always exists, as all languages can execute external applications.<br /><br />In KDE4, of course use DBUS instead of DCOP.<br /><br /></p>
+<p><span style="font-weight:600">If we keep the old parser.<br /><br /></span><br />Make it possible to use any language with Kommander. The idea is to replace Kommander specials with language specific code in a way that it will not break conditions and loops, like now. example:<br />#!/bin/bash<br />array=&quot;1 2 3 4 5&quot;<br />for i in $array do<br /> @Label.setText($i)<br />done<br /><br />This does not work now. The idea is to tqreplace @Widget.method() with a language specific DCOP call.<br />If the language has DCOP bindings, use those bindings to execute the dcop call. If not, use the command line<br />DCOP application. This is slower, but always works. In the above case, Kommander would tqreplace <br />@Label.setText($i) <br />with<br />dcop kmdr-executor-PID KommanderIf setText Label $i<br /><br />Kommander will have description files for each supported language about how to execute DCOP calls.<br />If the language has DCOP bindings, this description tells the syntax of the bindings. If it doesn't have, the description gives a way how to execute external applications. This should always exists, as all languages can execute external applications.<br /><br />In KDE4, of course use DBUS instead of DCOP.<br /><br /></p>
</body></html>
\NewEntry 1 Aliases
@@ -160,8 +160,8 @@
\NewEntry 1 Signals
<html><head><meta name="qrichtext" content="1" /></head><body style="font-size:10pt;font-family:Georgia">
-<p><span style="font-weight:600">New signals for existing widgets</span></p>
-<ul type="disc"><li>add signals for D&amp;D<br /><span style="font-style:italic">Requires dragContent and dragType, perhaps dragSource to be set.</span></li>
+<p><span style="font-weight:600">New Q_SIGNALS for existing widgets</span></p>
+<ul type="disc"><li>add Q_SIGNALS for D&amp;D<br /><span style="font-style:italic">Requires dragContent and dragType, perhaps dragSource to be set.</span></li>
<li></li></ul>
</body></html>
@@ -218,7 +218,7 @@
\NewEntry 1 Done
<html><head><meta name="qrichtext" content="1" /></head><body style="font-size:10pt;font-family:Sans Serif">
-<p>New widgets include the DatePicker, Popup Menu and Toolbox. New functions inlcude widget creation, hooking and unhooking signals and slots and full slot access as well as passing and returning parameters in scripts. WooHoo! Take that do list!<br /></p>
+<p>New widgets include the DatePicker, Popup Menu and Toolbox. New functions inlcude widget creation, hooking and unhooking Q_SIGNALS and Q_SLOTS and full slot access as well as passing and returning parameters in scripts. WooHoo! Take that do list!<br /></p>
<ul type="disc"><li>fixed dcop functions</li>
<li>added indexed array functions</li>
<li>made color slot work in TextEdit</li>
@@ -238,7 +238,7 @@
<html><head><meta name="qrichtext" content="1" /></head><body style="font-size:10pt;font-family:Sans Serif">
<p><span style="font-weight:600">Executing Kommander scripts</span></p>
<ul type="disc"><li>detect and handle missing plugin widgets</li>
-<li>cache @pid, @dcopid, @parentPid, perhaps calculate and cache @parentdcopid</li>
+<li>cache @pid, @dcopid, @tqparentPid, perhaps calculate and cache @tqparentdcopid</li>
<li>handle multiple dialogs: they could be packaged in single *.tgz file, unpacked and executed internally</li>
<div></div>
<div><br /></div></ul>
@@ -284,7 +284,7 @@
<html><head><meta name="qrichtext" content="1" /></head><body style="font-size:10pt;font-family:Georgia">
<li type="disc"><span style="font-weight:600">ChangeLog of Kommander</span></li>
<li type="disc"><span style="font-style:italic">See ChangeLog file for details and dates</span></li>
-<ul type="disc"><li>added @parentPid evaluated to parent process pid</li>
+<ul type="disc"><li>added @tqparentPid evaluated to tqparent process pid</li>
<li>added @pid evaluated to current process pid</li>
<li>added @dcopid evaluated to current process DCOP id</li>
<li>significantly improved Kommander Text editor usability</li>
diff --git a/kommander/editor/actiondnd.cpp b/kommander/editor/actiondnd.cpp
index 67491ef4..119f481b 100644
--- a/kommander/editor/actiondnd.cpp
+++ b/kommander/editor/actiondnd.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -42,7 +42,7 @@
#include <klocale.h>
-bool QDesignerAction::addTo( TQWidget *w )
+bool TQDesignerAction::addTo( TQWidget *w )
{
if ( !widgetToInsert )
return TQAction::addTo( w );
@@ -55,7 +55,7 @@ bool QDesignerAction::addTo( TQWidget *w )
return true;
}
-bool QDesignerAction::removeFrom( TQWidget *w )
+bool TQDesignerAction::removeFrom( TQWidget *w )
{
if ( !widgetToInsert )
return TQAction::removeFrom( w );
@@ -64,70 +64,70 @@ bool QDesignerAction::removeFrom( TQWidget *w )
return true;
}
-void QDesignerAction::remove()
+void TQDesignerAction::remove()
{
if ( !widgetToInsert )
return;
- MainWindow::self->formWindow()->selectWidget( widgetToInsert, false );
+ MainWindow::self->formWindow()->selectWidget( TQT_TQOBJECT(widgetToInsert), false );
widgetToInsert->reparent( 0, TQPoint( 0, 0 ), false );
}
-QDesignerToolBarSeparator::QDesignerToolBarSeparator(Orientation o , TQToolBar *parent,
+TQDesignerToolBarSeparator::TQDesignerToolBarSeparator(Qt::Orientation o , TQToolBar *tqparent,
const char* name )
- : TQWidget( parent, name )
+ : TQWidget( tqparent, name )
{
- connect( parent, TQT_SIGNAL(orientationChanged(Orientation)),
- this, TQT_SLOT(setOrientation(Orientation)) );
+ connect( tqparent, TQT_SIGNAL(orientationChanged(Qt::Orientation)),
+ this, TQT_SLOT(setOrientation(Qt::Orientation)) );
setOrientation( o );
- setBackgroundMode( parent->backgroundMode() );
+ setBackgroundMode( tqparent->backgroundMode() );
setBackgroundOrigin( ParentOrigin );
- setSizePolicy( TQSizePolicy( TQSizePolicy::Minimum, TQSizePolicy::Minimum ) );
+ tqsetSizePolicy( TQSizePolicy( TQSizePolicy::Minimum, TQSizePolicy::Minimum ) );
}
-void QDesignerToolBarSeparator::setOrientation( Orientation o )
+void TQDesignerToolBarSeparator::setOrientation( Qt::Orientation o )
{
orient = o;
}
-void QDesignerToolBarSeparator::styleChange( TQStyle& )
+void TQDesignerToolBarSeparator::styleChange( TQStyle& )
{
setOrientation( orient );
}
-TQSize QDesignerToolBarSeparator::sizeHint() const
+TQSize TQDesignerToolBarSeparator::tqsizeHint() const
{
- int extent = style().pixelMetric( TQStyle::PM_DockWindowSeparatorExtent,
+ int extent = tqstyle().tqpixelMetric( TQStyle::PM_DockWindowSeparatorExtent,
this );
- if ( orient == Horizontal )
+ if ( orient ==Qt::Horizontal )
return TQSize( extent, 0 );
else
return TQSize( 0, extent );
}
-void QDesignerToolBarSeparator::paintEvent( TQPaintEvent * )
+void TQDesignerToolBarSeparator::paintEvent( TQPaintEvent * )
{
TQPainter p( this );
TQStyle::SFlags flags = TQStyle::Style_Default;
- if ( orientation() == Horizontal )
+ if ( orientation() ==Qt::Horizontal )
flags |= TQStyle::Style_Horizontal;
- style().drawPrimitive( TQStyle::PE_DockWindowSeparator, &p, rect(),
- colorGroup(), flags );
+ tqstyle().tqdrawPrimitive( TQStyle::PE_DockWindowSeparator, &p, rect(),
+ tqcolorGroup(), flags );
}
-QSeparatorAction::QSeparatorAction( TQObject *parent )
- : TQAction( parent, "qt_designer_separator" ), wid( 0 )
+TQSeparatorAction::TQSeparatorAction( TQObject *tqparent )
+ : TQAction( tqparent, "qt_designer_separator" ), wid( 0 )
{
}
-bool QSeparatorAction::addTo( TQWidget *w )
+bool TQSeparatorAction::addTo( TQWidget *w )
{
if ( w->inherits( TQTOOLBAR_OBJECT_NAME_STRING ) ) {
TQToolBar *tb = (TQToolBar*)w;
- wid = new QDesignerToolBarSeparator( tb->orientation(), tb );
+ wid = new TQDesignerToolBarSeparator( tb->orientation(), tb );
return true;
} else if ( w->inherits( TQPOPUPMENU_OBJECT_NAME_STRING ) ) {
idx = ( (TQPopupMenu*)w )->count();
@@ -137,7 +137,7 @@ bool QSeparatorAction::addTo( TQWidget *w )
return false;
}
-bool QSeparatorAction::removeFrom( TQWidget *w )
+bool TQSeparatorAction::removeFrom( TQWidget *w )
{
if ( w->inherits( TQTOOLBAR_OBJECT_NAME_STRING ) ) {
delete wid;
@@ -149,7 +149,7 @@ bool QSeparatorAction::removeFrom( TQWidget *w )
return false;
}
-TQWidget *QSeparatorAction::widget() const
+TQWidget *TQSeparatorAction::widget() const
{
return wid;
}
@@ -157,15 +157,15 @@ TQWidget *QSeparatorAction::widget() const
-QDesignerToolBar::QDesignerToolBar( TQMainWindow *mw )
+TQDesignerToolBar::TQDesignerToolBar( TQMainWindow *mw )
: TQToolBar( mw ), lastIndicatorPos( -1, -1 )
{
insertAnchor = 0;
afterAnchor = true;
setAcceptDrops( true );
- MetaDataBase::addEntry( this );
+ MetaDataBase::addEntry( TQT_TQOBJECT(this) );
lastIndicatorPos = TQPoint( -1, -1 );
- indicator = new QDesignerIndicatorWidget( this );
+ indicator = new TQDesignerIndicatorWidget( this );
indicator->hide();
installEventFilter( this );
widgetInserting = false;
@@ -173,65 +173,65 @@ QDesignerToolBar::QDesignerToolBar( TQMainWindow *mw )
mw->setDockEnabled( DockTornOff, false );
}
-QDesignerToolBar::QDesignerToolBar( TQMainWindow *mw, Dock dock )
- : TQToolBar( TQString::null, mw, dock), lastIndicatorPos( -1, -1 )
+TQDesignerToolBar::TQDesignerToolBar( TQMainWindow *mw, Dock dock )
+ : TQToolBar( TQString(), mw, dock), lastIndicatorPos( -1, -1 )
{
insertAnchor = 0;
afterAnchor = true;
setAcceptDrops( true );
- indicator = new QDesignerIndicatorWidget( this );
+ indicator = new TQDesignerIndicatorWidget( this );
indicator->hide();
- MetaDataBase::addEntry( this );
+ MetaDataBase::addEntry( TQT_TQOBJECT(this) );
installEventFilter( this );
widgetInserting = false;
findFormWindow();
mw->setDockEnabled( DockTornOff, false );
}
-void QDesignerToolBar::findFormWindow()
+void TQDesignerToolBar::findFormWindow()
{
TQWidget *w = this;
while ( w ) {
if ( w->inherits( "FormWindow" ) )
formWindow = (FormWindow*)w;
- w = w->parentWidget();
+ w = w->tqparentWidget();
}
}
-void QDesignerToolBar::addAction( TQAction *a )
+void TQDesignerToolBar::addAction( TQAction *a )
{
actionList.append( a );
connect( a, TQT_SIGNAL( destroyed() ), this, TQT_SLOT( actionRemoved() ) );
if ( a->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) ) {
- ( (QDesignerActionGroup*)a )->widget()->installEventFilter( this );
- actionMap.insert( ( (QDesignerActionGroup*)a )->widget(), a );
- } else if ( a->inherits( "QSeparatorAction" ) ) {
- ( (QSeparatorAction*)a )->widget()->installEventFilter( this );
- actionMap.insert( ( (QSeparatorAction*)a )->widget(), a );
+ ( (TQDesignerActionGroup*)a )->widget()->installEventFilter( this );
+ actionMap.insert( ( (TQDesignerActionGroup*)a )->widget(), a );
+ } else if ( a->inherits( "TQSeparatorAction" ) ) {
+ ( (TQSeparatorAction*)a )->widget()->installEventFilter( this );
+ actionMap.insert( ( (TQSeparatorAction*)a )->widget(), a );
} else {
- ( (QDesignerAction*)a )->widget()->installEventFilter( this );
- actionMap.insert( ( (QDesignerAction*)a )->widget(), a );
+ ( (TQDesignerAction*)a )->widget()->installEventFilter( this );
+ actionMap.insert( ( (TQDesignerAction*)a )->widget(), a );
}
}
static void fixObject( TQObject *&o )
{
- while ( o && o->parent() && !o->parent()->inherits( "QDesignerToolBar" ) )
- o = o->parent();
+ while ( o && o->tqparent() && !o->tqparent()->inherits( "TQDesignerToolBar" ) )
+ o = o->tqparent();
}
-bool QDesignerToolBar::eventFilter( TQObject *o, TQEvent *e )
+bool TQDesignerToolBar::eventFilter( TQObject *o, TQEvent *e )
{
- if ( !o || !e || o->inherits( "QDockWindowHandle" ) || o->inherits( "QDockWindowTitleBar" ) )
+ if ( !o || !e || o->inherits( TQDOCKWINDOWHANDLE_OBJECT_NAME_STRING ) || o->inherits( "TQDockWindowTitleBar" ) )
return TQToolBar::eventFilter( o, e );
- if ( o == this && e->type() == TQEvent::MouseButtonPress &&
- ( ( TQMouseEvent*)e )->button() == LeftButton ) {
+ if ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(this) && e->type() == TQEvent::MouseButtonPress &&
+ ( ( TQMouseEvent*)e )->button() == Qt::LeftButton ) {
mousePressEvent( (TQMouseEvent*)e );
return true;
}
- if ( o == this )
+ if ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(this) )
return TQToolBar::eventFilter( o, e );
if ( e->type() == TQEvent::MouseButtonPress ) {
@@ -279,7 +279,7 @@ bool QDesignerToolBar::eventFilter( TQObject *o, TQEvent *e )
return TQToolBar::eventFilter( o, e );
}
-void QDesignerToolBar::paintEvent( TQPaintEvent *e )
+void TQDesignerToolBar::paintEvent( TQPaintEvent *e )
{
TQToolBar::paintEvent( e );
if ( e->rect() != rect() )
@@ -287,24 +287,24 @@ void QDesignerToolBar::paintEvent( TQPaintEvent *e )
lastIndicatorPos = TQPoint( -1, -1 );
}
-void QDesignerToolBar::contextMenuEvent( TQContextMenuEvent *e )
+void TQDesignerToolBar::contextMenuEvent( TQContextMenuEvent *e )
{
e->accept();
TQPopupMenu menu( 0 );
menu.insertItem( i18n("Delete Toolbar" ), 1 );
int res = menu.exec( e->globalPos() );
if ( res != -1 ) {
- RemoveToolBarCommand *cmd = new RemoveToolBarCommand( i18n("Delete Toolbar '%1'" ).arg( name() ),
+ RemoveToolBarCommand *cmd = new RemoveToolBarCommand( i18n("Delete Toolbar '%1'" ).tqarg( name() ),
formWindow, 0, this );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
}
}
-void QDesignerToolBar::mousePressEvent( TQMouseEvent *e )
+void TQDesignerToolBar::mousePressEvent( TQMouseEvent *e )
{
widgetInserting = false;
- if ( e->button() == LeftButton &&
+ if ( e->button() == Qt::LeftButton &&
MainWindow::self->currentTool() != POINTER_TOOL &&
MainWindow::self->currentTool() != ORDER_TOOL ) {
@@ -318,33 +318,33 @@ void QDesignerToolBar::mousePressEvent( TQMouseEvent *e )
}
}
-void QDesignerToolBar::mouseReleaseEvent( TQMouseEvent *e )
+void TQDesignerToolBar::mouseReleaseEvent( TQMouseEvent *e )
{
if ( widgetInserting )
doInsertWidget( mapFromGlobal( e->globalPos() ) );
widgetInserting = false;
}
-void QDesignerToolBar::buttonMouseReleaseEvent( TQMouseEvent *e, TQObject *w )
+void TQDesignerToolBar::buttonMouseReleaseEvent( TQMouseEvent *e, TQObject *w )
{
if ( widgetInserting )
doInsertWidget( mapFromGlobal( e->globalPos() ) );
- else if ( w->isWidgetType() && formWindow->widgets()->find( w ) ) {
+ else if ( w->isWidgetType() && formWindow->widgets()->tqfind( w ) ) {
formWindow->clearSelection( false );
formWindow->selectWidget( w );
}
widgetInserting = false;
}
-void QDesignerToolBar::buttonContextMenuEvent( TQContextMenuEvent *e, TQObject *o )
+void TQDesignerToolBar::buttonContextMenuEvent( TQContextMenuEvent *e, TQObject *o )
{
e->accept();
TQPopupMenu menu( 0 );
const int ID_DELETE = 1;
const int ID_SEP = 2;
const int ID_DELTOOLBAR = 3;
- TQMap<TQWidget*, TQAction*>::Iterator it = actionMap.find( (TQWidget*)o );
- if ( it != actionMap.end() && (*it)->inherits( "QSeparatorAction" ) )
+ TQMap<TQWidget*, TQAction*>::Iterator it = actionMap.tqfind( (TQWidget*)o );
+ if ( it != actionMap.end() && (*it)->inherits( "TQSeparatorAction" ) )
menu.insertItem( i18n("Delete Separator" ), ID_DELETE );
else
menu.insertItem( i18n("Delete Item" ), ID_DELETE );
@@ -353,21 +353,21 @@ void QDesignerToolBar::buttonContextMenuEvent( TQContextMenuEvent *e, TQObject *
menu.insertItem( i18n("Delete Toolbar" ), ID_DELTOOLBAR );
int res = menu.exec( e->globalPos() );
if ( res == ID_DELETE ) {
- TQMap<TQWidget*, TQAction*>::Iterator it = actionMap.find( (TQWidget*)o );
+ TQMap<TQWidget*, TQAction*>::Iterator it = actionMap.tqfind( (TQWidget*)o );
if ( it == actionMap.end() )
return;
TQAction *a = *it;
- int index = actionList.find( a );
+ int index = actionList.tqfind( a );
RemoveActionFromToolBarCommand *cmd = new RemoveActionFromToolBarCommand(
i18n("Delete Action '%1' From Toolbar '%2'" ).
- arg( a->name() ).arg( caption() ),
+ tqarg( a->name() ).tqarg( caption() ),
formWindow, a, this, index );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
} else if ( res == ID_SEP ) {
calcIndicatorPos( mapFromGlobal( e->globalPos() ) );
- TQAction *a = new QSeparatorAction( 0 );
- int index = actionList.findRef( *actionMap.find( insertAnchor ) );
+ TQAction *a = new TQSeparatorAction( 0 );
+ int index = actionList.tqfindRef( *actionMap.tqfind( insertAnchor ) );
if ( index != -1 && afterAnchor )
++index;
if ( !insertAnchor )
@@ -380,21 +380,21 @@ void QDesignerToolBar::buttonContextMenuEvent( TQContextMenuEvent *e, TQObject *
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
} else if ( res == ID_DELTOOLBAR ) {
- RemoveToolBarCommand *cmd = new RemoveToolBarCommand( i18n("Delete Toolbar '%1'" ).arg( name() ),
+ RemoveToolBarCommand *cmd = new RemoveToolBarCommand( i18n("Delete Toolbar '%1'" ).tqarg( name() ),
formWindow, 0, this );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
}
}
-void QDesignerToolBar::buttonMousePressEvent( TQMouseEvent *e, TQObject * )
+void TQDesignerToolBar::buttonMousePressEvent( TQMouseEvent *e, TQObject * )
{
widgetInserting = false;
- if ( e->button() == MidButton )
+ if ( e->button() == Qt::MidButton )
return;
- if ( e->button() == LeftButton &&
+ if ( e->button() == Qt::LeftButton &&
MainWindow::self->currentTool() != POINTER_TOOL &&
MainWindow::self->currentTool() != ORDER_TOOL ) {
@@ -411,16 +411,16 @@ void QDesignerToolBar::buttonMousePressEvent( TQMouseEvent *e, TQObject * )
dragStartPos = e->pos();
}
-void QDesignerToolBar::removeWidget( TQWidget *w )
+void TQDesignerToolBar::removeWidget( TQWidget *w )
{
- TQMap<TQWidget*, TQAction*>::Iterator it = actionMap.find( w );
+ TQMap<TQWidget*, TQAction*>::Iterator it = actionMap.tqfind( w );
if ( it == actionMap.end() )
return;
TQAction *a = *it;
- int index = actionList.find( a );
+ int index = actionList.tqfind( a );
RemoveActionFromToolBarCommand *cmd =
new RemoveActionFromToolBarCommand( i18n("Delete Action '%1' From Toolbar '%2'" ).
- arg( a->name() ).arg( caption() ),
+ tqarg( a->name() ).tqarg( caption() ),
formWindow, a, this, index );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
@@ -428,22 +428,22 @@ void QDesignerToolBar::removeWidget( TQWidget *w )
adjustSize();
}
-void QDesignerToolBar::buttonMouseMoveEvent( TQMouseEvent *e, TQObject *o )
+void TQDesignerToolBar::buttonMouseMoveEvent( TQMouseEvent *e, TQObject *o )
{
- if ( widgetInserting || ( e->state() & LeftButton ) == 0 )
+ if ( widgetInserting || ( e->state() & Qt::LeftButton ) == 0 )
return;
- if ( QABS( TQPoint( dragStartPos - e->pos() ).manhattanLength() ) < TQApplication::startDragDistance() )
+ if ( TQABS( TQPoint( dragStartPos - e->pos() ).manhattanLength() ) < TQApplication::startDragDistance() )
return;
- TQMap<TQWidget*, TQAction*>::Iterator it = actionMap.find( (TQWidget*)o );
+ TQMap<TQWidget*, TQAction*>::Iterator it = actionMap.tqfind( (TQWidget*)o );
if ( it == actionMap.end() )
return;
TQAction *a = *it;
if ( !a )
return;
- int index = actionList.find( a );
+ int index = actionList.tqfind( a );
RemoveActionFromToolBarCommand *cmd =
new RemoveActionFromToolBarCommand( i18n("Delete Action '%1' From Toolbar '%2'" ).
- arg( a->name() ).arg( caption() ),
+ tqarg( a->name() ).tqarg( caption() ),
formWindow, a, this, index );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
@@ -451,18 +451,18 @@ void QDesignerToolBar::buttonMouseMoveEvent( TQMouseEvent *e, TQObject *o )
adjustSize();
TQString type = a->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) ? TQString( "application/x-designer-actiongroup" ) :
- a->inherits( "QSeparatorAction" ) ? TQString( "application/x-designer-separator" ) : TQString( "application/x-designer-actions" );
+ a->inherits( "TQSeparatorAction" ) ? TQString( "application/x-designer-separator" ) : TQString( "application/x-designer-actions" );
TQStoredDrag *drag = new TQStoredDrag( type, this );
TQString s = TQString::number( (long)a ); // #### huha, that is evil
drag->setEncodedData( TQCString( s.latin1() ) );
drag->setPixmap( a->iconSet().pixmap() );
- if ( a->inherits( "QDesignerAction" ) ) {
- if ( formWindow->widgets()->find( ( (QDesignerAction*)a )->widget() ) )
- formWindow->selectWidget( ( (QDesignerAction*)a )->widget(), false );
+ if ( a->inherits( "TQDesignerAction" ) ) {
+ if ( formWindow->widgets()->tqfind( ( (TQDesignerAction*)a )->widget() ) )
+ formWindow->selectWidget( TQT_TQOBJECT(( (TQDesignerAction*)a )->widget()), false );
}
if ( !drag->drag() ) {
AddActionToToolBarCommand *cmd = new AddActionToToolBarCommand( i18n("Add Action '%1' to Toolbar '%2'" ).
- arg( a->name() ).arg( caption() ),
+ tqarg( a->name() ).tqarg( caption() ),
formWindow, a, this, index );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
@@ -471,9 +471,9 @@ void QDesignerToolBar::buttonMouseMoveEvent( TQMouseEvent *e, TQObject *o )
indicator->hide();
}
-#ifndef QT_NO_DRAGANDDROP
+#ifndef TQT_NO_DRAGANDDROP
-void QDesignerToolBar::dragEnterEvent( TQDragEnterEvent *e )
+void TQDesignerToolBar::dragEnterEvent( TQDragEnterEvent *e )
{
widgetInserting = false;
lastIndicatorPos = TQPoint( -1, -1 );
@@ -483,7 +483,7 @@ void QDesignerToolBar::dragEnterEvent( TQDragEnterEvent *e )
e->accept();
}
-void QDesignerToolBar::dragMoveEvent( TQDragMoveEvent *e )
+void TQDesignerToolBar::dragMoveEvent( TQDragMoveEvent *e )
{
if ( e->provides( "application/x-designer-actions" ) ||
e->provides( "application/x-designer-actiongroup" ) ||
@@ -494,14 +494,14 @@ void QDesignerToolBar::dragMoveEvent( TQDragMoveEvent *e )
drawIndicator( calcIndicatorPos( e->pos() ) );
}
-void QDesignerToolBar::dragLeaveEvent( TQDragLeaveEvent * )
+void TQDesignerToolBar::dragLeaveEvent( TQDragLeaveEvent * )
{
indicator->hide();
insertAnchor = 0;
afterAnchor = true;
}
-void QDesignerToolBar::dropEvent( TQDropEvent *e )
+void TQDesignerToolBar::dropEvent( TQDropEvent *e )
{
if ( e->provides( "application/x-designer-actions" ) ||
e->provides( "application/x-designer-actiongroup" ) ||
@@ -511,15 +511,15 @@ void QDesignerToolBar::dropEvent( TQDropEvent *e )
return;
TQString s;
if ( e->provides( "application/x-designer-actiongroup" ) )
- s = TQString( e->encodedData( "application/x-designer-actiongroup" ) );
+ s = TQString( e->tqencodedData( "application/x-designer-actiongroup" ) );
else if ( e->provides( "application/x-designer-separator" ) )
- s = TQString( e->encodedData( "application/x-designer-separator" ) );
+ s = TQString( e->tqencodedData( "application/x-designer-separator" ) );
else
- s = TQString( e->encodedData( "application/x-designer-actions" ) );
+ s = TQString( e->tqencodedData( "application/x-designer-actions" ) );
indicator->hide();
TQAction *a = 0;
- int index = actionList.findRef( *actionMap.find( insertAnchor ) );
+ int index = actionList.tqfindRef( *actionMap.tqfind( insertAnchor ) );
if ( index != -1 && afterAnchor )
++index;
if ( !insertAnchor )
@@ -527,14 +527,14 @@ void QDesignerToolBar::dropEvent( TQDropEvent *e )
if ( e->provides( "application/x-designer-actions" ) ||
e->provides( "application/x-designer-separator" ) ) {
if ( e->provides( "application/x-designer-actions" ) )
- a = (QDesignerAction*)s.toLong();
+ a = (TQDesignerAction*)s.toLong();
else
- a = (QSeparatorAction*)s.toLong();
+ a = (TQSeparatorAction*)s.toLong();
} else {
- a = (QDesignerActionGroup*)s.toLong();
+ a = (TQDesignerActionGroup*)s.toLong();
}
- if ( actionList.findRef( a ) != -1 ) {
+ if ( actionList.tqfindRef( a ) != -1 ) {
TQMessageBox::warning( MainWindow::self, i18n("Insert/Move Action" ),
i18n("Action '%1' has already been added to this toolbar.\n"
"An Action may only occur once in a given toolbar." ).
@@ -543,7 +543,7 @@ void QDesignerToolBar::dropEvent( TQDropEvent *e )
}
AddActionToToolBarCommand *cmd = new AddActionToToolBarCommand( i18n("Add Action '%1' to Toolbar '%2'" ).
- arg( a->name() ).arg( caption() ),
+ tqarg( a->name() ).tqarg( caption() ),
formWindow, a, this, index );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
@@ -553,7 +553,7 @@ void QDesignerToolBar::dropEvent( TQDropEvent *e )
#endif
-void QDesignerToolBar::reInsert()
+void TQDesignerToolBar::reInsert()
{
TQAction *a = 0;
actionMap.clear();
@@ -561,36 +561,37 @@ void QDesignerToolBar::reInsert()
for ( a = actionList.first(); a; a = actionList.next() ) {
a->addTo( this );
if ( a->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) ) {
- actionMap.insert( ( (QDesignerActionGroup*)a )->widget(), a );
- if ( ( (QDesignerActionGroup*)a )->widget() )
- ( (QDesignerActionGroup*)a )->widget()->installEventFilter( this );
- } else if ( a->inherits( "QDesignerAction" ) ) {
- actionMap.insert( ( (QDesignerAction*)a )->widget(), a );
- ( (QDesignerAction*)a )->widget()->installEventFilter( this );
- } else if ( a->inherits( "QSeparatorAction" ) ) {
- actionMap.insert( ( (QSeparatorAction*)a )->widget(), a );
- ( (QSeparatorAction*)a )->widget()->installEventFilter( this );
+ actionMap.insert( ( (TQDesignerActionGroup*)a )->widget(), a );
+ if ( ( (TQDesignerActionGroup*)a )->widget() )
+ ( (TQDesignerActionGroup*)a )->widget()->installEventFilter( this );
+ } else if ( a->inherits( "TQDesignerAction" ) ) {
+ actionMap.insert( ( (TQDesignerAction*)a )->widget(), a );
+ ( (TQDesignerAction*)a )->widget()->installEventFilter( this );
+ } else if ( a->inherits( "TQSeparatorAction" ) ) {
+ actionMap.insert( ( (TQSeparatorAction*)a )->widget(), a );
+ ( (TQSeparatorAction*)a )->widget()->installEventFilter( this );
}
}
TQApplication::sendPostedEvents();
adjustSize();
}
-void QDesignerToolBar::actionRemoved()
+void TQDesignerToolBar::actionRemoved()
{
actionList.removeRef( (TQAction*)sender() );
}
-TQPoint QDesignerToolBar::calcIndicatorPos( const TQPoint &pos )
+TQPoint TQDesignerToolBar::calcIndicatorPos( const TQPoint &pos )
{
- if ( orientation() == Horizontal ) {
+ if ( orientation() ==Qt::Horizontal ) {
TQPoint pnt( width() - 2, 0 );
insertAnchor = 0;
afterAnchor = true;
- if ( !children() )
+ TQObjectList clo = childrenListObject();
+ if ( clo.isEmpty() )
return pnt;
pnt = TQPoint( 13, 0 );
- TQObjectListIt it( *children() );
+ TQObjectListIt it( clo );
TQObject * obj;
while( (obj=it.current()) != 0 ) {
++it;
@@ -609,10 +610,11 @@ TQPoint QDesignerToolBar::calcIndicatorPos( const TQPoint &pos )
TQPoint pnt( 0, height() - 2 );
insertAnchor = 0;
afterAnchor = true;
- if ( !children() )
+ TQObjectList clo = childrenListObject();
+ if ( clo.isEmpty() )
return pnt;
pnt = TQPoint( 0, 13 );
- TQObjectListIt it( *children() );
+ TQObjectListIt it( clo );
TQObject * obj;
while( (obj=it.current()) != 0 ) {
++it;
@@ -630,12 +632,12 @@ TQPoint QDesignerToolBar::calcIndicatorPos( const TQPoint &pos )
}
}
-void QDesignerToolBar::drawIndicator( const TQPoint &pos )
+void TQDesignerToolBar::drawIndicator( const TQPoint &pos )
{
if ( lastIndicatorPos == pos )
return;
bool wasVsisible = indicator->isVisible();
- if ( orientation() == Horizontal ) {
+ if ( orientation() ==Qt::Horizontal ) {
indicator->resize( 3, height() );
if ( pos != TQPoint( -1, -1 ) )
indicator->move( pos.x() - 1, 0 );
@@ -654,7 +656,7 @@ void QDesignerToolBar::drawIndicator( const TQPoint &pos )
TQApplication::sendPostedEvents();
}
-void QDesignerToolBar::doInsertWidget( const TQPoint &p )
+void TQDesignerToolBar::doInsertWidget( const TQPoint &p )
{
if ( formWindow != MainWindow::self->formWindow() )
return;
@@ -662,30 +664,30 @@ void QDesignerToolBar::doInsertWidget( const TQPoint &p )
TQWidget *w = WidgetFactory::create( MainWindow::self->currentTool(), this, 0, true );
installEventFilters( w );
MainWindow::self->formWindow()->insertWidget( w, true );
- QDesignerAction *a = new QDesignerAction( w, parent() );
- int index = actionList.findRef( *actionMap.find( insertAnchor ) );
+ TQDesignerAction *a = new TQDesignerAction( w, tqparent() );
+ int index = actionList.tqfindRef( *actionMap.tqfind( insertAnchor ) );
if ( index != -1 && afterAnchor )
++index;
if ( !insertAnchor )
index = 0;
AddActionToToolBarCommand *cmd = new AddActionToToolBarCommand( i18n("Add Widget '%1' to Toolbar '%2'" ).
- arg( w->name() ).arg( caption() ),
+ tqarg( w->name() ).tqarg( caption() ),
formWindow, a, this, index );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
MainWindow::self->resetTool();
}
-void QDesignerToolBar::clear()
+void TQDesignerToolBar::clear()
{
for ( TQAction *a = actionList.first(); a; a = actionList.next() ) {
- if ( a->inherits( "QDesignerAction" ) )
- ( (QDesignerAction*)a )->remove();
+ if ( a->inherits( "TQDesignerAction" ) )
+ ( (TQDesignerAction*)a )->remove();
}
TQToolBar::clear();
}
-void QDesignerToolBar::installEventFilters( TQWidget *w )
+void TQDesignerToolBar::installEventFilters( TQWidget *w )
{
if ( !w )
return;
@@ -697,32 +699,32 @@ void QDesignerToolBar::installEventFilters( TQWidget *w )
-QDesignerMenuBar::QDesignerMenuBar( TQWidget *mw )
+TQDesignerMenuBar::TQDesignerMenuBar( TQWidget *mw )
: TQMenuBar( mw, 0 )
{
show();
setAcceptDrops( true );
- MetaDataBase::addEntry( this );
+ MetaDataBase::addEntry( TQT_TQOBJECT(this) );
itemNum = 0;
mousePressed = false;
lastIndicatorPos = TQPoint( -1, -1 );
insertAt = -1;
- indicator = new QDesignerIndicatorWidget( this );
+ indicator = new TQDesignerIndicatorWidget( this );
indicator->hide();
findFormWindow();
}
-void QDesignerMenuBar::findFormWindow()
+void TQDesignerMenuBar::findFormWindow()
{
TQWidget *w = this;
while ( w ) {
if ( w->inherits( "FormWindow" ) )
formWindow = (FormWindow*)w;
- w = w->parentWidget();
+ w = w->tqparentWidget();
}
}
-void QDesignerMenuBar::contextMenuEvent( TQContextMenuEvent *e )
+void TQDesignerMenuBar::contextMenuEvent( TQContextMenuEvent *e )
{
e->accept();
int itm = itemAtPos( e->pos() );
@@ -736,17 +738,17 @@ void QDesignerMenuBar::contextMenuEvent( TQContextMenuEvent *e )
menu.insertItem( i18n("Rename Item..." ), 2 );
int res = menu.exec( e->globalPos() );
if ( res == 1 ) {
- TQMenuItem *item = findItem( idAt( itm ) );
- RemoveMenuCommand *cmd = new RemoveMenuCommand( i18n("Delete Menu '%1'" ).arg( item->text() ),
+ TQMenuItem *item = tqfindItem( idAt( itm ) );
+ RemoveMenuCommand *cmd = new RemoveMenuCommand( i18n("Delete Menu '%1'" ).tqarg( item->text() ),
formWindow,
- (TQMainWindow*)parentWidget(), this,
- (QDesignerPopupMenu*)item->popup(),
+ (TQMainWindow*)tqparentWidget(), this,
+ (TQDesignerPopupMenu*)item->popup(),
idAt( itm ), itm, item->text() );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
- // #### need to do a proper invalidate and re-layout
- parentWidget()->layout()->invalidate();
- parentWidget()->layout()->activate();
+ // #### need to do a proper tqinvalidate and re-tqlayout
+ tqparentWidget()->tqlayout()->tqinvalidate();
+ tqparentWidget()->tqlayout()->activate();
} else if ( res == 2 ) {
bool ok;
TQString old = text( idAt( itm ) );
@@ -754,7 +756,7 @@ void QDesignerMenuBar::contextMenuEvent( TQContextMenuEvent *e )
text( idAt( itm ) ), &ok, 0 );
if ( ok ) {
RenameMenuCommand *cmd = new RenameMenuCommand(
- i18n("Rename Menu '%1' to '%2'" ).arg( old ).arg( txt ),
+ i18n("Rename Menu '%1' to '%2'" ).tqarg( old ).tqarg( txt ),
formWindow, this, idAt( itm ), old, txt );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
@@ -762,33 +764,33 @@ void QDesignerMenuBar::contextMenuEvent( TQContextMenuEvent *e )
}
}
-void QDesignerMenuBar::mousePressEvent( TQMouseEvent *e )
+void TQDesignerMenuBar::mousePressEvent( TQMouseEvent *e )
{
lastIndicatorPos = TQPoint( -1, -1 );
insertAt = -1;
mousePressed = true;
- if ( e->button() == MidButton || e->button() == RightButton )
+ if ( e->button() == Qt::MidButton || e->button() == Qt::RightButton )
return;
dragStartPos = e->pos();
TQMenuBar::mousePressEvent( e );
}
-void QDesignerMenuBar::mouseMoveEvent( TQMouseEvent *e )
+void TQDesignerMenuBar::mouseMoveEvent( TQMouseEvent *e )
{
- if ( !mousePressed || e->state() == NoButton ) {
+ if ( !mousePressed || e->state() == Qt::NoButton ) {
TQMenuBar::mouseMoveEvent( e );
return;
}
- if ( QABS( TQPoint( dragStartPos - e->pos() ).manhattanLength() ) < TQApplication::startDragDistance() )
+ if ( TQABS( TQPoint( dragStartPos - e->pos() ).manhattanLength() ) < TQApplication::startDragDistance() )
return;
hidePopups();
activateItemAt( -1 );
int itm = itemAtPos( dragStartPos );
if ( itm == -1 )
return;
- TQPopupMenu *popup = findItem( idAt( itm ) )->popup();
- TQString txt = findItem( idAt( itm ) )->text();
+ TQPopupMenu *popup = tqfindItem( idAt( itm ) )->popup();
+ TQString txt = tqfindItem( idAt( itm ) )->text();
removeItemAt( itm );
TQStoredDrag *drag = new TQStoredDrag( "application/x-designer-menuitem", this );
@@ -812,15 +814,15 @@ void QDesignerMenuBar::mouseMoveEvent( TQMouseEvent *e )
mousePressed = false;
}
-void QDesignerMenuBar::mouseReleaseEvent( TQMouseEvent *e )
+void TQDesignerMenuBar::mouseReleaseEvent( TQMouseEvent *e )
{
TQMenuBar::mouseReleaseEvent( e );
mousePressed = false;
}
-#ifndef QT_NO_DRAGANDDROP
+#ifndef TQT_NO_DRAGANDDROP
-void QDesignerMenuBar::dragEnterEvent( TQDragEnterEvent *e )
+void TQDesignerMenuBar::dragEnterEvent( TQDragEnterEvent *e )
{
if ( e->provides( "application/x-designer-actions" ) ||
e->provides( "application/x-designer-actiongroup" ) ||
@@ -832,7 +834,7 @@ void QDesignerMenuBar::dragEnterEvent( TQDragEnterEvent *e )
insertAt = -1;
}
-void QDesignerMenuBar::dragMoveEvent( TQDragMoveEvent *e )
+void TQDesignerMenuBar::dragMoveEvent( TQDragMoveEvent *e )
{
if ( e->provides( "application/x-designer-actions" ) ||
e->provides( "application/x-designer-menuitem" ) ||
@@ -845,12 +847,12 @@ void QDesignerMenuBar::dragMoveEvent( TQDragMoveEvent *e )
e->provides( "application/x-designer-actiongroup" ) ||
e->provides( "application/x-designer-separator" ) ) {
int item = itemAtPos( e->pos() );
- bool uieffect = TQApplication::isEffectEnabled( UI_AnimateMenu );
- TQApplication::setEffectEnabled( UI_AnimateMenu, false );
- if ( !qApp->activePopupWidget() )
+ bool uieffect = TQApplication::isEffectEnabled( Qt::UI_AnimateMenu );
+ TQApplication::setEffectEnabled( Qt::UI_AnimateMenu, false );
+ if ( !tqApp->activePopupWidget() )
actItem = -1;
activateItemAt( item );
- TQApplication::setEffectEnabled( UI_AnimateMenu, uieffect );
+ TQApplication::setEffectEnabled( Qt::UI_AnimateMenu, uieffect );
if ( item == -1 )
hidePopups();
} else {
@@ -858,28 +860,28 @@ void QDesignerMenuBar::dragMoveEvent( TQDragMoveEvent *e )
}
}
-void QDesignerMenuBar::dragLeaveEvent( TQDragLeaveEvent * )
+void TQDesignerMenuBar::dragLeaveEvent( TQDragLeaveEvent * )
{
mousePressed = false;
lastIndicatorPos = TQPoint( -1, -1 );
insertAt = -1;
}
-void QDesignerMenuBar::dropEvent( TQDropEvent *e )
+void TQDesignerMenuBar::dropEvent( TQDropEvent *e )
{
mousePressed = false;
if ( !e->provides( "application/x-designer-menuitem" ) )
return;
e->accept();
- TQString s( e->encodedData( "application/x-designer-menuitem" ) );
- TQString s1 = s.left( s.find( "/" ) );
- TQString s2 = s.mid( s.find( "/" ) + 1 );
+ TQString s( e->tqencodedData( "application/x-designer-menuitem" ) );
+ TQString s1 = s.left( s.tqfind( "/" ) );
+ TQString s2 = s.mid( s.tqfind( "/" ) + 1 );
TQPopupMenu *popup = (TQPopupMenu*)s1.toLong(); // #### huha, that is evil
TQString txt = s2;
insertItem( txt, popup, -1, insertAt );
- MoveMenuCommand *cmd = new MoveMenuCommand( i18n("Move Menu '%1'" ).arg( txt ), formWindow,
- this, (QDesignerPopupMenu*)popup, oldPos, insertAt, txt );
+ MoveMenuCommand *cmd = new MoveMenuCommand( i18n("Move Menu '%1'" ).tqarg( txt ), formWindow,
+ this, (TQDesignerPopupMenu*)popup, oldPos, insertAt, txt );
// do not execute, we did the work already
formWindow->commandHistory()->addCommand( cmd );
@@ -888,12 +890,12 @@ void QDesignerMenuBar::dropEvent( TQDropEvent *e )
#endif
-TQPoint QDesignerMenuBar::calcIndicatorPos( const TQPoint &pos )
+TQPoint TQDesignerMenuBar::calcIndicatorPos( const TQPoint &pos )
{
int w = frameWidth();
insertAt = count();
for ( int i = 0; i < (int)count(); ++i ) {
- TQRect r = itemRect( i );
+ TQRect r = tqitemRect( i );
if ( pos.x() < w + r.width() / 2 ) {
insertAt = i;
break;
@@ -904,7 +906,7 @@ TQPoint QDesignerMenuBar::calcIndicatorPos( const TQPoint &pos )
return TQPoint( w, 0 );
}
-void QDesignerMenuBar::drawIndicator( const TQPoint &pos )
+void TQDesignerMenuBar::drawIndicator( const TQPoint &pos )
{
if ( lastIndicatorPos == pos )
return;
@@ -918,47 +920,47 @@ void QDesignerMenuBar::drawIndicator( const TQPoint &pos )
TQApplication::sendPostedEvents();
}
-void QDesignerMenuBar::setItemNumber( int num )
+void TQDesignerMenuBar::setItemNumber( int num )
{
itemNum = num;
}
-int QDesignerMenuBar::itemNumber() const
+int TQDesignerMenuBar::itemNumber() const
{
return itemNum;
}
-void QDesignerMenuBar::setItemText( const TQString &s )
+void TQDesignerMenuBar::setItemText( const TQString &s )
{
if ( itemNum < 0 || itemNum >= (int)count() )
return;
changeItem( idAt( itemNum ), s );
}
-TQString QDesignerMenuBar::itemText() const
+TQString TQDesignerMenuBar::itemText() const
{
if ( itemNum < 0 || (int)itemNum >= (int)count() )
- return TQString::null;
+ return TQString();
return text( idAt( itemNum ) );
}
-void QDesignerMenuBar::setItemName( const TQCString &s )
+void TQDesignerMenuBar::setItemName( const TQCString &s )
{
if ( itemNum < 0 || itemNum >= (int)count() )
return;
- findItem( idAt( itemNum ) )->popup()->setName( s );
+ tqfindItem( idAt( itemNum ) )->popup()->setName( s );
}
-TQCString QDesignerMenuBar::itemName() const
+TQCString TQDesignerMenuBar::itemName() const
{
if ( itemNum < 0 || itemNum >= (int)count() )
return "";
- return findItem( idAt( itemNum ) )->popup()->name();
+ return tqfindItem( idAt( itemNum ) )->popup()->name();
}
-QDesignerPopupMenu::QDesignerPopupMenu( TQWidget *w )
+TQDesignerPopupMenu::TQDesignerPopupMenu( TQWidget *w )
: TQPopupMenu( w, 0 ),
popupMenu( 0 )
{
@@ -967,27 +969,27 @@ QDesignerPopupMenu::QDesignerPopupMenu( TQWidget *w )
insertAt = -1;
mousePressed = false;
lastIndicatorPos = TQPoint( -1, -1 );
- indicator = new QDesignerIndicatorWidget( this );
+ indicator = new TQDesignerIndicatorWidget( this );
indicator->hide();
}
-void QDesignerPopupMenu::contextMenuEvent( TQContextMenuEvent *e )
+void TQDesignerPopupMenu::contextMenuEvent( TQContextMenuEvent *e )
{
-#if defined( Q_WS_MAC ) //the mac needs us to use context menu rather than right click
+#if defined( TQ_WS_MAC ) //the mac needs us to use context menu rather than right click
e->accept();
- TQMouseEvent me( TQEvent::MouseButtonPress, e->pos(), e->globalPos(), RightButton, RightButton );
+ TQMouseEvent me( TQEvent::MouseButtonPress, e->pos(), e->globalPos(), Qt::RightButton, Qt::RightButton );
mousePressEvent(&me);
#else
Q_UNUSED( e );
#endif
}
-void QDesignerPopupMenu::mousePressEvent( TQMouseEvent *e )
+void TQDesignerPopupMenu::mousePressEvent( TQMouseEvent *e )
{
- if ( e->button() == MidButton )
+ if ( e->button() == Qt::MidButton )
return;
- if ( e->button() == RightButton ) {
+ if ( e->button() == Qt::RightButton ) {
// A popup for a popup, we only need one, so make sure that
// we don't create multiple. The timer keeps the event loop sane.
popupPos = e->globalPos();
@@ -1004,7 +1006,7 @@ void QDesignerPopupMenu::mousePressEvent( TQMouseEvent *e )
TQPopupMenu::mousePressEvent( e );
}
-void QDesignerPopupMenu::createPopupMenu()
+void TQDesignerPopupMenu::createPopupMenu()
{
// actually creates our popup for the popupmenu.
TQPopupMenu menu( 0 );
@@ -1016,7 +1018,7 @@ void QDesignerPopupMenu::createPopupMenu()
if ( itm == -1 )
return;
TQAction *a = actionList.at( itm );
- if ( a && a->inherits( "QSeparatorAction" ) )
+ if ( a && a->inherits( "TQSeparatorAction" ) )
menu.insertItem( i18n("Delete Separator" ), ID_DELETE );
else
menu.insertItem( i18n("Delete Item" ), ID_DELETE );
@@ -1028,35 +1030,35 @@ void QDesignerPopupMenu::createPopupMenu()
return;
RemoveActionFromPopupCommand *cmd = new RemoveActionFromPopupCommand(
i18n("Delete Action '%1' From Popup Menu '%2'" ).
- arg( a->name() ).arg( caption() ),
+ tqarg( a->name() ).tqarg( caption() ),
formWindow, a, this, itm );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
} else if ( res == ID_SEP ) {
TQPoint p( pos() );
calcIndicatorPos( mapFromGlobal( popupPos ) );
- TQAction *a = new QSeparatorAction( 0 );
+ TQAction *a = new TQSeparatorAction( 0 );
AddActionToPopupCommand *cmd = new AddActionToPopupCommand(
i18n("Add Separator to Popup Menu '%1'" ).
arg( name() ),
formWindow, a, this, insertAt );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
- ( (QDesignerMenuBar*)( (TQMainWindow*)parentWidget() )->menuBar() )->hidePopups();
- ( (QDesignerMenuBar*)( (TQMainWindow*)parentWidget() )->menuBar() )->activateItemAt( -1 );
+ ( (TQDesignerMenuBar*)( (TQMainWindow*)tqparentWidget() )->menuBar() )->hidePopups();
+ ( (TQDesignerMenuBar*)( (TQMainWindow*)tqparentWidget() )->menuBar() )->activateItemAt( -1 );
popup( p );
}
// set this back to zero so we know a popup (will soon) not exist.
popupMenu = 0;
}
-void QDesignerPopupMenu::mouseMoveEvent( TQMouseEvent *e )
+void TQDesignerPopupMenu::mouseMoveEvent( TQMouseEvent *e )
{
- if ( !mousePressed || e->state() == NoButton ) {
+ if ( !mousePressed || e->state() == Qt::NoButton ) {
TQPopupMenu::mouseMoveEvent( e );
return;
}
- if ( QABS( TQPoint( dragStartPos - e->pos() ).manhattanLength() ) < TQApplication::startDragDistance() ) {
+ if ( TQABS( TQPoint( dragStartPos - e->pos() ).manhattanLength() ) < TQApplication::startDragDistance() ) {
TQPopupMenu::mouseMoveEvent( e );
return;
}
@@ -1067,20 +1069,20 @@ void QDesignerPopupMenu::mouseMoveEvent( TQMouseEvent *e )
if ( !a )
return;
RemoveActionFromPopupCommand *cmd = new RemoveActionFromPopupCommand( i18n("Delete Action '%1' From Popup Menu '%2'" ).
- arg( a->name() ).arg( caption() ),
+ tqarg( a->name() ).tqarg( caption() ),
formWindow, a, this, itm );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
TQString type = a->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) ? TQString( "application/x-designer-actiongroup" ) :
- a->inherits( "QSeparatorAction" ) ? TQString( "application/x-designer-separator" ) : TQString( "application/x-designer-actions" );
+ a->inherits( "TQSeparatorAction" ) ? TQString( "application/x-designer-separator" ) : TQString( "application/x-designer-actions" );
TQStoredDrag *drag = new TQStoredDrag( type, this );
TQString s = TQString::number( (long)a ); // #### huha, that is evil
drag->setEncodedData( TQCString( s.latin1() ) );
drag->setPixmap( a->iconSet().pixmap() );
if ( !drag->drag() ) {
AddActionToPopupCommand *cmd = new AddActionToPopupCommand( i18n("Add Action '%1' to Popup Menu '%2'" ).
- arg( a->name() ).arg( name() ),
+ tqarg( a->name() ).tqarg( name() ),
formWindow, a, this, itm );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
@@ -1090,15 +1092,15 @@ void QDesignerPopupMenu::mouseMoveEvent( TQMouseEvent *e )
mousePressed = false;
}
-void QDesignerPopupMenu::mouseReleaseEvent( TQMouseEvent *e )
+void TQDesignerPopupMenu::mouseReleaseEvent( TQMouseEvent *e )
{
mousePressed = false;
TQPopupMenu::mouseReleaseEvent( e );
}
-#ifndef QT_NO_DRAGANDDROP
+#ifndef TQT_NO_DRAGANDDROP
-void QDesignerPopupMenu::dragEnterEvent( TQDragEnterEvent *e )
+void TQDesignerPopupMenu::dragEnterEvent( TQDragEnterEvent *e )
{
mousePressed = false;
lastIndicatorPos = TQPoint( -1, -1 );
@@ -1108,7 +1110,7 @@ void QDesignerPopupMenu::dragEnterEvent( TQDragEnterEvent *e )
e->accept();
}
-void QDesignerPopupMenu::dragMoveEvent( TQDragMoveEvent *e )
+void TQDesignerPopupMenu::dragMoveEvent( TQDragMoveEvent *e )
{
mousePressed = false;
if ( e->provides( "application/x-designer-actions" ) ||
@@ -1120,14 +1122,14 @@ void QDesignerPopupMenu::dragMoveEvent( TQDragMoveEvent *e )
drawIndicator( calcIndicatorPos( e->pos() ) );
}
-void QDesignerPopupMenu::dragLeaveEvent( TQDragLeaveEvent * )
+void TQDesignerPopupMenu::dragLeaveEvent( TQDragLeaveEvent * )
{
mousePressed = false;
indicator->hide();
insertAt = -1;
}
-void QDesignerPopupMenu::dropEvent( TQDropEvent *e )
+void TQDesignerPopupMenu::dropEvent( TQDropEvent *e )
{
mousePressed = false;
if ( e->provides( "application/x-designer-actions" ) ||
@@ -1140,20 +1142,20 @@ void QDesignerPopupMenu::dropEvent( TQDropEvent *e )
TQPoint p = pos();
TQAction *a = 0;
if ( e->provides( "application/x-designer-actiongroup" ) ) {
- TQString s( e->encodedData( "application/x-designer-actiongroup" ) );
- a = (QDesignerActionGroup*)s.toLong();
+ TQString s( e->tqencodedData( "application/x-designer-actiongroup" ) );
+ a = (TQDesignerActionGroup*)s.toLong();
} else {
TQString s;
if ( e->provides( "application/x-designer-separator" ) ) {
- s = TQString( e->encodedData( "application/x-designer-separator" ) );
- a = (QSeparatorAction*)s.toLong();
+ s = TQString( e->tqencodedData( "application/x-designer-separator" ) );
+ a = (TQSeparatorAction*)s.toLong();
} else {
- s = TQString( e->encodedData( "application/x-designer-actions" ) );
- a = (QDesignerAction*)s.toLong();
+ s = TQString( e->tqencodedData( "application/x-designer-actions" ) );
+ a = (TQDesignerAction*)s.toLong();
}
}
- if ( actionList.findRef( a ) != -1 ) {
+ if ( actionList.tqfindRef( a ) != -1 ) {
TQMessageBox::warning( MainWindow::self, i18n("Insert/Move Action" ),
i18n("Action '%1' has already been added to this menu.\n"
"An Action may only occur once in a given menu." ).
@@ -1162,27 +1164,27 @@ void QDesignerPopupMenu::dropEvent( TQDropEvent *e )
}
AddActionToPopupCommand *cmd = new AddActionToPopupCommand( i18n("Add Action '%1' to Popup Menu '%2'" ).
- arg( a->name() ).arg( name() ),
+ tqarg( a->name() ).tqarg( name() ),
formWindow, a, this, insertAt );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
- ( (QDesignerMenuBar*)( (TQMainWindow*)parentWidget() )->menuBar() )->hidePopups();
- ( (QDesignerMenuBar*)( (TQMainWindow*)parentWidget() )->menuBar() )->activateItemAt( -1 );
+ ( (TQDesignerMenuBar*)( (TQMainWindow*)tqparentWidget() )->menuBar() )->hidePopups();
+ ( (TQDesignerMenuBar*)( (TQMainWindow*)tqparentWidget() )->menuBar() )->activateItemAt( -1 );
indicator->hide();
popup( p );
}
#endif
-void QDesignerPopupMenu::reInsert()
+void TQDesignerPopupMenu::reInsert()
{
clear();
for ( TQAction *a = actionList.first(); a; a = actionList.next() )
a->addTo( this );
}
-void QDesignerPopupMenu::drawIndicator( const TQPoint &pos )
+void TQDesignerPopupMenu::drawIndicator( const TQPoint &pos )
{
if ( lastIndicatorPos == pos )
return;
@@ -1196,7 +1198,7 @@ void QDesignerPopupMenu::drawIndicator( const TQPoint &pos )
TQApplication::sendPostedEvents();
}
-TQPoint QDesignerPopupMenu::calcIndicatorPos( const TQPoint &pos )
+TQPoint TQDesignerPopupMenu::calcIndicatorPos( const TQPoint &pos )
{
int h = frameWidth();
insertAt = count();
@@ -1212,18 +1214,18 @@ TQPoint QDesignerPopupMenu::calcIndicatorPos( const TQPoint &pos )
return TQPoint( 0, h );
}
-void QDesignerPopupMenu::addAction( TQAction *a )
+void TQDesignerPopupMenu::addAction( TQAction *a )
{
actionList.append( a );
connect( a, TQT_SIGNAL( destroyed() ), this, TQT_SLOT( actionRemoved() ) );
}
-void QDesignerPopupMenu::actionRemoved()
+void TQDesignerPopupMenu::actionRemoved()
{
actionList.removeRef( (TQAction*)sender() );
}
-void QDesignerPopupMenu::paintEvent( TQPaintEvent *e )
+void TQDesignerPopupMenu::paintEvent( TQPaintEvent *e )
{
TQPopupMenu::paintEvent( e );
if ( e->rect() != rect() )
@@ -1231,13 +1233,13 @@ void QDesignerPopupMenu::paintEvent( TQPaintEvent *e )
lastIndicatorPos = TQPoint( -1, -1 );
}
-void QDesignerPopupMenu::findFormWindow()
+void TQDesignerPopupMenu::findFormWindow()
{
TQWidget *w = this;
while ( w ) {
if ( w->inherits( "FormWindow" ) )
formWindow = (FormWindow*)w;
- w = w->parentWidget();
+ w = w->tqparentWidget();
}
}
diff --git a/kommander/editor/actiondnd.h b/kommander/editor/actiondnd.h
index af5a76e5..5d1c314d 100644
--- a/kommander/editor/actiondnd.h
+++ b/kommander/editor/actiondnd.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -30,20 +30,21 @@
#include <tqtoolbar.h>
#include <tqguardedptr.h>
-class QDesignerPopupMenu;
-class QDesignerIndicatorWidget;
+class TQDesignerPopupMenu;
+class TQDesignerIndicatorWidget;
class FormWindow;
-class QDesignerActionGroup : public QActionGroup
+class TQDesignerActionGroup : public TQActionGroup
{
Q_OBJECT
+ TQ_OBJECT
public:
- QDesignerActionGroup( TQObject *parent )
- : TQActionGroup( !parent || parent->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) ? parent : 0 ), wid( 0 ), idx( -1 ) {}
+ TQDesignerActionGroup( TQObject *tqparent )
+ : TQActionGroup( !tqparent || tqparent->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) ? tqparent : 0 ), wid( 0 ), idx( -1 ) {}
TQWidget *widget() const { return wid; }
- TQWidget *widget( TQAction *a ) const { return *widgets.find( a ); }
+ TQWidget *widget( TQAction *a ) const { return *widgets.tqfind( a ); }
int index() const { return idx; }
protected:
@@ -64,15 +65,16 @@ private:
};
-class QDesignerAction : public QAction
+class TQDesignerAction : public TQAction
{
Q_OBJECT
+ TQ_OBJECT
public:
- QDesignerAction( TQObject *parent )
- : TQAction( !parent || parent->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) ? parent : 0 ), wid( 0 ), idx( -1 ), widgetToInsert( 0 ) {}
- QDesignerAction( TQWidget *w, TQObject *parent )
- : TQAction( !parent || parent->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) ? parent : 0 ), wid( 0 ), idx( -1 ), widgetToInsert( w ) {}
+ TQDesignerAction( TQObject *tqparent )
+ : TQAction( !tqparent || tqparent->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) ? tqparent : 0 ), wid( 0 ), idx( -1 ), widgetToInsert( 0 ) {}
+ TQDesignerAction( TQWidget *w, TQObject *tqparent )
+ : TQAction( !tqparent || tqparent->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) ? tqparent : 0 ), wid( 0 ), idx( -1 ), widgetToInsert( w ) {}
TQWidget *widget() const { return wid; }
int index() const { return idx; }
@@ -98,31 +100,33 @@ private:
};
-class QDesignerToolBarSeparator : public QWidget
+class TQDesignerToolBarSeparator : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- QDesignerToolBarSeparator( Orientation, TQToolBar *parent, const char* name=0 );
+ TQDesignerToolBarSeparator( Qt::Orientation, TQToolBar *tqparent, const char* name=0 );
- TQSize sizeHint() const;
- Orientation orientation() const { return orient; }
+ TQSize tqsizeHint() const;
+ Qt::Orientation orientation() const { return orient; }
public slots:
- void setOrientation( Orientation );
+ void setOrientation( Qt::Orientation );
protected:
void styleChange( TQStyle& );
void paintEvent( TQPaintEvent * );
private:
- Orientation orient;
+ Qt::Orientation orient;
};
-class QSeparatorAction : public QAction
+class TQSeparatorAction : public TQAction
{
Q_OBJECT
+ TQ_OBJECT
public:
- QSeparatorAction( TQObject *parent );
+ TQSeparatorAction( TQObject *tqparent );
bool addTo( TQWidget *w );
bool removeFrom( TQWidget *w );
@@ -135,13 +139,14 @@ private:
};
-class QDesignerToolBar : public QToolBar
+class TQDesignerToolBar : public TQToolBar
{
Q_OBJECT
+ TQ_OBJECT
public:
- QDesignerToolBar( TQMainWindow *mw );
- QDesignerToolBar( TQMainWindow *mw, Dock dock );
+ TQDesignerToolBar( TQMainWindow *mw );
+ TQDesignerToolBar( TQMainWindow *mw, Dock dock );
TQPtrList<TQAction> insertedActions() const { return actionList; }
void addAction( TQAction *a );
@@ -157,7 +162,7 @@ public:
protected:
bool eventFilter( TQObject *, TQEvent * );
void paintEvent( TQPaintEvent * );
-#ifndef QT_NO_DRAGANDDROP
+#ifndef TQT_NO_DRAGANDDROP
void dragEnterEvent( TQDragEnterEvent * );
void dragMoveEvent( TQDragMoveEvent * );
void dragLeaveEvent( TQDragLeaveEvent * );
@@ -187,23 +192,24 @@ private:
TQPtrList<TQAction> actionList;
TQMap<TQWidget*, TQAction*> actionMap;
TQPoint dragStartPos;
- QDesignerIndicatorWidget *indicator;
+ TQDesignerIndicatorWidget *indicator;
bool widgetInserting;
FormWindow *formWindow;
};
-class QDesignerMenuBar : public QMenuBar
+class TQDesignerMenuBar : public TQMenuBar
{
Q_OBJECT
- friend class QDesignerPopupMenu;
+ TQ_OBJECT
+ friend class TQDesignerPopupMenu;
- Q_PROPERTY( int itemNumber WRITE setItemNumber READ itemNumber )
- Q_PROPERTY( TQString itemText WRITE setItemText READ itemText )
- Q_PROPERTY( TQCString itemName WRITE setItemName READ itemName )
+ TQ_PROPERTY( int itemNumber WRITE setItemNumber READ itemNumber )
+ TQ_PROPERTY( TQString itemText WRITE setItemText READ itemText )
+ TQ_PROPERTY( TQCString itemName WRITE setItemName READ itemName )
public:
- QDesignerMenuBar( TQWidget *mw );
+ TQDesignerMenuBar( TQWidget *mw );
void setItemNumber( int num );
int itemNumber() const;
@@ -217,7 +223,7 @@ protected:
void mouseMoveEvent( TQMouseEvent *e );
void mouseReleaseEvent( TQMouseEvent *e );
void contextMenuEvent( TQContextMenuEvent *e );
-#ifndef QT_NO_DRAGANDDROP
+#ifndef TQT_NO_DRAGANDDROP
void dragEnterEvent( TQDragEnterEvent * );
void dragMoveEvent( TQDragMoveEvent * );
void dragLeaveEvent( TQDragLeaveEvent * );
@@ -235,18 +241,19 @@ private:
bool mousePressed;
TQPoint lastIndicatorPos;
int insertAt;
- QDesignerIndicatorWidget *indicator;
+ TQDesignerIndicatorWidget *indicator;
FormWindow *formWindow;
int oldPos;
};
-class QDesignerPopupMenu : public QPopupMenu
+class TQDesignerPopupMenu : public TQPopupMenu
{
Q_OBJECT
+ TQ_OBJECT
public:
- QDesignerPopupMenu( TQWidget *w );
+ TQDesignerPopupMenu( TQWidget *w );
TQPtrList<TQAction> insertedActions() const { return actionList; }
void addAction( TQAction *a );
void reInsert();
@@ -259,7 +266,7 @@ protected:
void mouseReleaseEvent( TQMouseEvent *e );
void contextMenuEvent( TQContextMenuEvent *e );
void paintEvent( TQPaintEvent * );
-#ifndef QT_NO_DRAGANDDROP
+#ifndef TQT_NO_DRAGANDDROP
void dragEnterEvent( TQDragEnterEvent * );
void dragMoveEvent( TQDragMoveEvent * );
void dragLeaveEvent( TQDragLeaveEvent * );
@@ -281,7 +288,7 @@ private:
TQPtrList<TQAction> actionList;
TQPoint dragStartPos;
bool mousePressed;
- QDesignerIndicatorWidget *indicator;
+ TQDesignerIndicatorWidget *indicator;
FormWindow *formWindow;
TQGuardedPtr<TQPopupMenu> popupMenu;
TQPoint popupPos;
@@ -289,12 +296,13 @@ private:
};
-class QDesignerIndicatorWidget : public QWidget
+class TQDesignerIndicatorWidget : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- QDesignerIndicatorWidget( TQWidget *p )
+ TQDesignerIndicatorWidget( TQWidget *p )
: TQWidget( p, "qt_dockwidget_internal" ) {
setBackgroundColor( red );
}
diff --git a/kommander/editor/actioneditor.ui b/kommander/editor/actioneditor.ui
index 733e5b29..794849cd 100644
--- a/kommander/editor/actioneditor.ui
+++ b/kommander/editor/actioneditor.ui
@@ -2,8 +2,8 @@
<class>ActionEditorBase</class>
<include location="local" implDecl="in declaration">actioneditor.ui.h</include>
<forward>class QListViewItem;</forward>
-<layoutdefaults spacing="6" margin="11"/>
-<widget class="QWidget">
+<tqlayoutdefaults spacing="6" margin="11"/>
+<widget class="TQWidget">
<property name="name">
<cstring>ActionEditorBase</cstring>
</property>
@@ -18,7 +18,7 @@
<property name="caption">
<string>Edit Actions</string>
</property>
- <property name="layoutMargin" stdset="0">
+ <property name="tqlayoutMargin" stdset="0">
</property>
<vbox>
<property name="name">
@@ -30,7 +30,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout2</cstring>
</property>
@@ -44,7 +44,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QToolButton">
+ <widget class="TQToolButton">
<property name="name">
<cstring>buttonNewAction</cstring>
</property>
@@ -61,7 +61,7 @@
<string>Create new Action</string>
</property>
</widget>
- <widget class="QToolButton">
+ <widget class="TQToolButton">
<property name="name">
<cstring>buttonDeleteAction</cstring>
</property>
@@ -78,7 +78,7 @@
<string>Delete current Action</string>
</property>
</widget>
- <widget class="QToolButton">
+ <widget class="TQToolButton">
<property name="name">
<cstring>buttonConnect</cstring>
</property>
@@ -105,7 +105,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
diff --git a/kommander/editor/actioneditorimpl.cpp b/kommander/editor/actioneditorimpl.cpp
index e5358100..0e4d2a8f 100644
--- a/kommander/editor/actioneditorimpl.cpp
+++ b/kommander/editor/actioneditorimpl.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -37,8 +37,8 @@
#include <klocale.h>
-ActionEditor::ActionEditor( TQWidget* parent, const char* name, WFlags fl )
- : ActionEditorBase( parent, name, fl ), currentAction( 0 ), formWindow( 0 )
+ActionEditor::ActionEditor( TQWidget* tqparent, const char* name, WFlags fl )
+ : ActionEditorBase( tqparent, name, fl ), currentAction( 0 ), formWindow( 0 )
{
listActions->addColumn( i18n("Actions" ) );
setEnabled( false );
@@ -87,10 +87,10 @@ void ActionEditor::deleteAction()
formWindow->actionList().removeRef( currentAction );
delete currentAction;
TQValueList<MetaDataBase::Connection> conns =
- MetaDataBase::connections( formWindow, currentAction );
+ MetaDataBase::connections( TQT_TQOBJECT(formWindow), currentAction );
for ( TQValueList<MetaDataBase::Connection>::Iterator it2 = conns.begin();
it2 != conns.end(); ++it2 )
- MetaDataBase::removeConnection( formWindow, (*it2).sender, (*it2).signal,
+ MetaDataBase::removeConnection( TQT_TQOBJECT(formWindow), (*it2).sender, (*it2).signal,
(*it2).receiver, (*it2).slot );
delete it.current();
break;
@@ -98,10 +98,10 @@ void ActionEditor::deleteAction()
formWindow->actionList().removeRef( currentAction );
delete currentAction;
TQValueList<MetaDataBase::Connection> conns =
- MetaDataBase::connections( formWindow, currentAction );
+ MetaDataBase::connections( TQT_TQOBJECT(formWindow), currentAction );
for ( TQValueList<MetaDataBase::Connection>::Iterator it2 = conns.begin();
it2 != conns.end(); ++it2 )
- MetaDataBase::removeConnection( formWindow, (*it2).sender, (*it2).signal,
+ MetaDataBase::removeConnection( TQT_TQOBJECT(formWindow), (*it2).sender, (*it2).signal,
(*it2).receiver, (*it2).slot );
delete it.current();
break;
@@ -110,7 +110,7 @@ void ActionEditor::deleteAction()
}
if ( formWindow )
- formWindow->setActiveObject( formWindow->mainContainer() );
+ formWindow->setActiveObject( TQT_TQOBJECT(formWindow->mainContainer()) );
}
void ActionEditor::newAction()
@@ -119,7 +119,7 @@ void ActionEditor::newAction()
if ( actionParent ) {
if ( !actionParent->actionGroup() ||
!actionParent->actionGroup()->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) )
- actionParent = (ActionItem*)actionParent->parent();
+ actionParent = (ActionItem*)actionParent->tqparent();
}
ActionItem *i = 0;
@@ -151,7 +151,7 @@ void ActionEditor::newActionGroup()
if ( actionParent ) {
if ( !actionParent->actionGroup() ||
!actionParent->actionGroup()->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) )
- actionParent = (ActionItem*)actionParent->parent();
+ actionParent = (ActionItem*)actionParent->tqparent();
}
ActionItem *i = 0;
@@ -193,7 +193,7 @@ void ActionEditor::setFormWindow( FormWindow *fw )
setEnabled( true );
for ( TQAction *a = formWindow->actionList().first(); a; a = formWindow->actionList().next() ) {
ActionItem *i = 0;
- if ( a->parent() && a->parent()->inherits( TQACTION_OBJECT_NAME_STRING ) )
+ if ( a->tqparent() && a->tqparent()->inherits( TQACTION_OBJECT_NAME_STRING ) )
continue;
i = new ActionItem( listActions, a );
i->setText( 0, a->name() );
@@ -211,9 +211,12 @@ void ActionEditor::setFormWindow( FormWindow *fw )
void ActionEditor::insertChildActions( ActionItem *i )
{
- if ( !i->actionGroup() || !i->actionGroup()->children() )
+ if ( !i->actionGroup() )
return;
- TQObjectListIt it( *i->actionGroup()->children() );
+ TQObjectList clo = i->actionGroup()->childrenListObject();
+ if (clo.isEmpty())
+ return;
+ TQObjectListIt it( clo );
while ( it.current() ) {
TQObject *o = it.current();
++it;
@@ -255,7 +258,7 @@ void ActionEditor::updateActionIcon( TQAction *a )
void ActionEditor::connectionsClicked()
{
- ConnectionEditor editor( formWindow->mainWindow(), currentAction, formWindow, formWindow );
+ ConnectionEditor editor( formWindow->mainWindow(), TQT_TQOBJECT(currentAction), TQT_TQOBJECT(formWindow), formWindow );
editor.exec();
}
#include "actioneditorimpl.moc"
diff --git a/kommander/editor/actioneditorimpl.h b/kommander/editor/actioneditorimpl.h
index f6436d31..40ed78ac 100644
--- a/kommander/editor/actioneditorimpl.h
+++ b/kommander/editor/actioneditorimpl.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -30,9 +30,10 @@ class ActionItem;
class ActionEditor : public ActionEditorBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- ActionEditor( TQWidget* parent = 0, const char* name = 0, WFlags fl = 0 );
+ ActionEditor( TQWidget* tqparent = 0, const char* name = 0, WFlags fl = 0 );
void setFormWindow( FormWindow *fw );
void updateActionName( TQAction *a );
void updateActionIcon( TQAction *a );
diff --git a/kommander/editor/actionlistview.cpp b/kommander/editor/actionlistview.cpp
index 1c764f35..20a0ee4e 100644
--- a/kommander/editor/actionlistview.cpp
+++ b/kommander/editor/actionlistview.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -24,8 +24,8 @@
#include <klocale.h>
-ActionListView::ActionListView( TQWidget *parent, const char *name )
- : TQListView( parent, name )
+ActionListView::ActionListView( TQWidget *tqparent, const char *name )
+ : TQListView( tqparent, name )
{
header()->setStretchEnabled( true );
setRootIsDecorated( true );
@@ -38,9 +38,9 @@ ActionItem::ActionItem( TQListView *lv, TQAction *ac )
: TQListViewItem( lv ), a( 0 ), g( 0 )
{
if ( ac->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) )
- g = (QDesignerActionGroup*)ac;
+ g = (TQDesignerActionGroup*)ac;
else
- a = (QDesignerAction*)ac;
+ a = (TQDesignerAction*)ac;
setDragEnabled( true );
}
@@ -48,9 +48,9 @@ ActionItem::ActionItem( TQListViewItem *i, TQAction *ac )
: TQListViewItem( i ), a( 0 ), g( 0 )
{
if ( ac->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) )
- g = (QDesignerActionGroup*)ac;
+ g = (TQDesignerActionGroup*)ac;
else
- a = (QDesignerAction*)ac;
+ a = (TQDesignerAction*)ac;
setDragEnabled( true );
moveToEnd();
}
diff --git a/kommander/editor/actionlistview.h b/kommander/editor/actionlistview.h
index 160d2abb..53a5fda6 100644
--- a/kommander/editor/actionlistview.h
+++ b/kommander/editor/actionlistview.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -24,38 +24,39 @@
#include <tqlistview.h>
#include "actiondnd.h"
-class ActionItem : public QListViewItem
+class ActionItem : public TQListViewItem
{
public:
ActionItem( TQListView *lv, bool group )
: TQListViewItem( lv ),
- a( group ? 0 : new QDesignerAction( 0 ) ),
- g( group ? new QDesignerActionGroup( 0 ) : 0 ) { setDragEnabled( TRUE ); }
+ a( group ? 0 : new TQDesignerAction( 0 ) ),
+ g( group ? new TQDesignerActionGroup( 0 ) : 0 ) { setDragEnabled( TRUE ); }
ActionItem( TQListView *lv, TQAction *ac );
ActionItem( TQListViewItem *i, TQAction *ac );
- ActionItem( ActionItem *parent, bool group = FALSE )
- : TQListViewItem( parent ),
- a( group ? 0 : new QDesignerAction( parent->actionGroup() ) ),
- g( group ? new QDesignerActionGroup( parent->actionGroup() ) : 0 ) { setDragEnabled( TRUE ); moveToEnd(); }
+ ActionItem( ActionItem *tqparent, bool group = FALSE )
+ : TQListViewItem( tqparent ),
+ a( group ? 0 : new TQDesignerAction( tqparent->actionGroup() ) ),
+ g( group ? new TQDesignerActionGroup( tqparent->actionGroup() ) : 0 ) { setDragEnabled( TRUE ); moveToEnd(); }
- QDesignerAction *action() const { return a; }
- QDesignerActionGroup *actionGroup() const { return g; }
+ TQDesignerAction *action() const { return a; }
+ TQDesignerActionGroup *actionGroup() const { return g; }
private:
void moveToEnd();
private:
- QDesignerAction *a;
- QDesignerActionGroup *g;
+ TQDesignerAction *a;
+ TQDesignerActionGroup *g;
};
-class ActionListView : public QListView
+class ActionListView : public TQListView
{
Q_OBJECT
+ TQ_OBJECT
public:
- ActionListView( TQWidget *parent = 0, const char *name = 0 );
+ ActionListView( TQWidget *tqparent = 0, const char *name = 0 );
protected:
TQDragObject *dragObject();
diff --git a/kommander/editor/asciivalidator.cpp b/kommander/editor/asciivalidator.cpp
index 6f63e626..947b3ec1 100644
--- a/kommander/editor/asciivalidator.cpp
+++ b/kommander/editor/asciivalidator.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -22,18 +22,18 @@
#include <tqstring.h>
-AsciiValidator::AsciiValidator( TQObject * parent, const char *name )
- : TQValidator( parent, name ), functionName( false )
+AsciiValidator::AsciiValidator( TQObject * tqparent, const char *name )
+ : TQValidator( tqparent, name ), functionName( false )
{
}
-AsciiValidator::AsciiValidator( bool funcName, TQObject * parent, const char *name )
- : TQValidator( parent, name ), functionName( funcName )
+AsciiValidator::AsciiValidator( bool funcName, TQObject * tqparent, const char *name )
+ : TQValidator( tqparent, name ), functionName( funcName )
{
}
-AsciiValidator::AsciiValidator( const TQString &allow, TQObject * parent, const char *name )
- : TQValidator( parent, name ), functionName( false ), allowedChars( allow )
+AsciiValidator::AsciiValidator( const TQString &allow, TQObject * tqparent, const char *name )
+ : TQValidator( tqparent, name ), functionName( false ), allowedChars( allow )
{
}
@@ -67,7 +67,7 @@ TQValidator::State AsciiValidator::validate( TQString &s, int & ) const
}
}
- if ( allowedChars.find( s[ i ] ) != -1 )
+ if ( allowedChars.tqfind( s[ i ] ) != -1 )
continue;
s[i] = '_';
diff --git a/kommander/editor/asciivalidator.h b/kommander/editor/asciivalidator.h
index 20131f01..1c1d6c2c 100644
--- a/kommander/editor/asciivalidator.h
+++ b/kommander/editor/asciivalidator.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -25,13 +25,14 @@
#include <tqvalidator.h>
-class AsciiValidator: public QValidator
+class AsciiValidator: public TQValidator
{
Q_OBJECT
+ TQ_OBJECT
public:
- AsciiValidator( TQObject * parent, const char *name = 0 );
- AsciiValidator( bool funcName, TQObject * parent, const char *name = 0 );
- AsciiValidator( const TQString &allow, TQObject * parent, const char *name = 0 );
+ AsciiValidator( TQObject * tqparent, const char *name = 0 );
+ AsciiValidator( bool funcName, TQObject * tqparent, const char *name = 0 );
+ AsciiValidator( const TQString &allow, TQObject * tqparent, const char *name = 0 );
~AsciiValidator();
TQValidator::State validate( TQString &, int & ) const;
diff --git a/kommander/editor/assistproc.cpp b/kommander/editor/assistproc.cpp
index f5f765d8..bfe67544 100644
--- a/kommander/editor/assistproc.cpp
+++ b/kommander/editor/assistproc.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -19,8 +19,8 @@
**********************************************************************/
#include "assistproc.h"
-AssistProc::AssistProc( TQObject *parent, const char *name, const TQString &path )
- : TQProcess( parent, name )
+AssistProc::AssistProc( TQObject *tqparent, const char *name, const TQString &path )
+ : TQProcess( tqparent, name )
{
assistantPath = path;
connect( this, TQT_SIGNAL(readyReadStdout()), this, TQT_SLOT(processOutput()) );
diff --git a/kommander/editor/assistproc.h b/kommander/editor/assistproc.h
index f457a8e8..93986cef 100644
--- a/kommander/editor/assistproc.h
+++ b/kommander/editor/assistproc.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -25,13 +25,14 @@
#include <tqsocket.h>
#include <tqstring.h>
-class AssistProc : public QProcess
+class AssistProc : public TQProcess
{
Q_OBJECT
+ TQ_OBJECT
public:
- AssistProc( TQObject *parent=0, const char * name = 0, const TQString &path = TQString::null );
+ AssistProc( TQObject *tqparent=0, const char * name = 0, const TQString &path = TQString() );
~AssistProc();
- bool run( const TQString &path = TQString::null );
+ bool run( const TQString &path = TQString() );
public slots:
bool sendRequest( const TQString &data );
diff --git a/kommander/editor/assoctexteditor.ui b/kommander/editor/assoctexteditor.ui
index e3258b73..c7af592a 100644
--- a/kommander/editor/assoctexteditor.ui
+++ b/kommander/editor/assoctexteditor.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.3" stdsetdef="1">
<class>AssocTextEditorBase</class>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>AssocTextEditorBase</cstring>
</property>
@@ -19,15 +19,15 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLayoutWidget" row="0" column="0">
+ <widget class="TQLayoutWidget" row="0" column="0">
<property name="name">
- <cstring>layout5</cstring>
+ <cstring>tqlayout5</cstring>
</property>
<hbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>textLabel1_2</cstring>
</property>
@@ -38,7 +38,7 @@
<cstring>widgetsComboBox</cstring>
</property>
</widget>
- <widget class="QComboBox">
+ <widget class="TQComboBox">
<property name="name">
<cstring>widgetsComboBox</cstring>
</property>
@@ -51,7 +51,7 @@
</sizepolicy>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>treeWidgetButton</cstring>
</property>
@@ -59,7 +59,7 @@
<string>...</string>
</property>
</widget>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>textLabel1</cstring>
</property>
@@ -70,7 +70,7 @@
<cstring>stateComboBox</cstring>
</property>
</widget>
- <widget class="QComboBox">
+ <widget class="TQComboBox">
<property name="name">
<cstring>stateComboBox</cstring>
</property>
@@ -85,7 +85,7 @@
</widget>
</hbox>
</widget>
- <widget class="QGroupBox" row="2" column="0">
+ <widget class="TQGroupBox" row="2" column="0">
<property name="name">
<cstring>groupBox1</cstring>
</property>
@@ -114,14 +114,14 @@
<property name="sizeType">
<enum>Fixed</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>TextLabel3</cstring>
</property>
@@ -140,7 +140,7 @@
<cstring>widgetComboBox</cstring>
</property>
</widget>
- <widget class="QComboBox">
+ <widget class="TQComboBox">
<property name="name">
<cstring>widgetComboBox</cstring>
</property>
@@ -152,7 +152,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>150</width>
<height>0</height>
@@ -169,14 +169,14 @@
<property name="sizeType">
<enum>Fixed</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>filePushButton</cstring>
</property>
@@ -186,7 +186,7 @@
</widget>
</hbox>
</widget>
- <widget class="QFrame" row="1" column="0">
+ <widget class="TQFrame" row="1" column="0">
<property name="name">
<cstring>editorFrame</cstring>
</property>
@@ -215,8 +215,8 @@
<slot>AssocTextEditorBase_destroyed(QObject*)</slot>
</connection>
</connections>
-<slots>
+<Q_SLOTS>
<slot>AssocTextEditorBase_destroyed(QObject*)</slot>
-</slots>
-<layoutdefaults spacing="6" margin="11"/>
+</Q_SLOTS>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/editor/assoctexteditorimpl.cpp b/kommander/editor/assoctexteditorimpl.cpp
index cb5502a2..76bf67f6 100644
--- a/kommander/editor/assoctexteditorimpl.cpp
+++ b/kommander/editor/assoctexteditorimpl.cpp
@@ -70,7 +70,7 @@ AssocTextEditor::AssocTextEditor(TQWidget *a_widget, FormWindow* a_form,
// text editor
/* associatedTextEdit->setFont(KGlobalSettings::fixedFont());
associatedTextEdit->setTabStopWidth(associatedTextEdit->fontMetrics().maxWidth() * 3);
- associatedTextEdit->setTextFormat(Qt::PlainText);*/
+ associatedTextEdit->setTextFormat(TQt::PlainText);*/
// icon for non-empty scripts
scriptPixmap = KGlobal::iconLoader()->loadIcon("source", KIcon::Small);
@@ -89,10 +89,10 @@ AssocTextEditor::AssocTextEditor(TQWidget *a_widget, FormWindow* a_form,
break;
}
- doc = KTextEditor::createDocument ("libkatepart", a_parent, "KTextEditor::Document");
- TQGridLayout *layout = new TQGridLayout(editorFrame, 1, 1);
+ doc = KTextEditor::createDocument ("libkatepart", TQT_TQOBJECT(a_parent), "KTextEditor::Document");
+ TQGridLayout *tqlayout = new TQGridLayout(editorFrame, 1, 1);
view = doc->createView(editorFrame);
- layout->addWidget(view, 1,1);
+ tqlayout->addWidget(view, 1,1);
partManager->addPart(doc, true);
//trick to import all the KatePart actions into the dialog
@@ -113,7 +113,7 @@ AssocTextEditor::AssocTextEditor(TQWidget *a_widget, FormWindow* a_form,
if (a)
a->plug(popup);
popup->insertSeparator();
- a = view->actionCollection()->action("edit_find");
+ a = view->actionCollection()->action("edit_tqfind");
if (a)
a->plug(popup);
a = view->actionCollection()->action("edit_find_next");
@@ -122,7 +122,7 @@ AssocTextEditor::AssocTextEditor(TQWidget *a_widget, FormWindow* a_form,
a = view->actionCollection()->action("edit_find_prev");
if (a)
a->plug(popup);
- a = view->actionCollection()->action("edit_replace");
+ a = view->actionCollection()->action("edit_tqreplace");
if (a)
a->plug(popup);
popup->insertSeparator();
@@ -208,7 +208,7 @@ void AssocTextEditor::setWidget(TQWidget *a_widget)
++at_it;
}
else
- m_atdict[(*s_it)] = TQString::null;
+ m_atdict[(*s_it)] = TQString();
}
m_populationText = a_atw->populationText();
@@ -246,7 +246,7 @@ void AssocTextEditor::setWidget(TQWidget *a_widget)
undoIf->clearUndo();
- if (openedWidgets.contains(m_widget))
+ if (openedWidgets.tqcontains(m_widget))
{
if (readOnlyAction && !readOnly)
readOnlyAction->activate();
@@ -268,23 +268,23 @@ void AssocTextEditor::save() const
if (atw->associatedText() != associatedText())
{
- TQString text = i18n("Set the \'text association\' of \'%1\'").arg(m_widget->name());
+ TQString text = i18n("Set the \'text association\' of \'%1\'").tqarg(m_widget->name());
SetPropertyCommand *cmd = new SetPropertyCommand(text, m_formWindow,
- m_widget, m_propertyEditor, "associations", atw->associatedText(),
- associatedText(), TQString::null, TQString::null, false);
+ TQT_TQOBJECT(m_widget), m_propertyEditor, "associations", atw->associatedText(),
+ associatedText(), TQString(), TQString(), false);
cmd->execute();
m_formWindow->commandHistory()->addCommand(cmd);
- MetaDataBase::setPropertyChanged(m_widget, "associations", true);
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(m_widget), "associations", true);
}
if (atw->populationText() != populationText())
{
- TQString text = i18n("Set the \'population text\' of \'%1\'").arg(m_widget->name());
- SetPropertyCommand *cmd = new SetPropertyCommand(text, m_formWindow, m_widget,
+ TQString text = i18n("Set the \'population text\' of \'%1\'").tqarg(m_widget->name());
+ SetPropertyCommand *cmd = new SetPropertyCommand(text, m_formWindow, TQT_TQOBJECT(m_widget),
m_propertyEditor, "populationText", atw->populationText(),
- populationText(), TQString::null, TQString::null, false);
+ populationText(), TQString(), TQString(), false);
cmd->execute();
m_formWindow->commandHistory()->addCommand(cmd);
- MetaDataBase::setPropertyChanged(m_widget, "populationText", true);
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(m_widget), "populationText", true);
}
}
@@ -305,7 +305,7 @@ TQString AssocTextEditor::populationText() const
TQStringList AssocTextEditor::buildWidgetList()
{
TQStringList widgetList;
- TQObject* thisObject = m_formWindow->mainContainer();
+ TQObject* thisObject = TQT_TQOBJECT(m_formWindow->mainContainer());
TQObjectList *objectList = thisObject->queryList();
objectList->prepend(thisObject);
@@ -314,10 +314,10 @@ TQStringList AssocTextEditor::buildWidgetList()
// There is a warning message with the property() function if it does not exist.
// Verify the property exists with the meta information first */
bool pExists = false;
- TQMetaObject *metaObj = it.current()->metaObject();
+ TQMetaObject *metaObj = it.current()->tqmetaObject();
if(metaObj)
{
- int id = metaObj->findProperty("KommanderWidget", true);
+ int id = metaObj->tqfindProperty("KommanderWidget", true);
const TQMetaProperty *metaProp = metaObj->property(id, true);
if(metaProp && metaProp->isValid())
pExists = true;
@@ -363,7 +363,7 @@ void AssocTextEditor::stateChanged(int a_index)
{
if (hlIf->hlModeSectionName(i) == "Scripts")
highlightPopup->insertItem(hlIf->hlModeName(i), i);
- if (hlIf->hlModeName(i).contains(hlType, false) > 0)
+ if (hlIf->hlModeName(i).tqcontains(hlType, false) > 0)
{
hlIf->setHlMode(i);
highlightPopup->setItemChecked(i, true);
@@ -427,7 +427,7 @@ void AssocTextEditor::insertFile()
TQFile insertFile(fileName);
if(!insertFile.open(IO_ReadOnly))
{
- KMessageBox::error( this, i18n("<qt>Cannot open file<br><b>%1</b></qt").arg( fileName ) );
+ KMessageBox::error( this, i18n("<qt>Cannot open file<br><b>%1</b></qt").tqarg( fileName ) );
return;
}
TQTextStream insertStream(&insertFile);
@@ -454,9 +454,9 @@ void AssocTextEditor::insertFunction()
TQString AssocTextEditor::widgetToString(TQWidget* widget, bool formatted)
{
if (!widget)
- return TQString::null;
+ return TQString();
else if (formatted)
- return TQString("%1 (%2)").arg(widget->name()).arg(widget->className());
+ return TQString("%1 (%2)").tqarg(widget->name()).tqarg(widget->className());
else
return widget->name();
}
@@ -464,7 +464,7 @@ TQString AssocTextEditor::widgetToString(TQWidget* widget, bool formatted)
TQWidget* AssocTextEditor::widgetFromString(const TQString& name)
{
TQString realname = name;
- int i = realname.find(' ');
+ int i = realname.tqfind(' ');
if (i != -1)
realname.truncate(i);
return m_widgetList[realname];
diff --git a/kommander/editor/assoctexteditorimpl.h b/kommander/editor/assoctexteditorimpl.h
index 37c582ab..c9539450 100644
--- a/kommander/editor/assoctexteditorimpl.h
+++ b/kommander/editor/assoctexteditorimpl.h
@@ -49,6 +49,7 @@ class KPopupMenu;
class AssocTextEditor : public AssocTextEditorBase
{
Q_OBJECT
+ TQ_OBJECT
public:
AssocTextEditor(TQWidget*, FormWindow*, PropertyEditor*, KParts::PartManager *partManager, TQWidget*, const char* = 0, bool = true);
~AssocTextEditor();
diff --git a/kommander/editor/choosewidget.ui b/kommander/editor/choosewidget.ui
index 809f38ea..19c728f9 100644
--- a/kommander/editor/choosewidget.ui
+++ b/kommander/editor/choosewidget.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
<class>ChooseWidgetBase</class>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>ChooseWidgetBase</cstring>
</property>
@@ -22,9 +22,9 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLayoutWidget" row="2" column="0">
+ <widget class="TQLayoutWidget" row="2" column="0">
<property name="name">
- <cstring>layout2</cstring>
+ <cstring>tqlayout2</cstring>
</property>
<hbox>
<property name="name">
@@ -40,14 +40,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonOk</cstring>
</property>
@@ -64,7 +64,7 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonCancel</cstring>
</property>
@@ -88,7 +88,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
@@ -102,15 +102,15 @@
<cstring>widgetView</cstring>
</property>
</widget>
- <widget class="QLayoutWidget" row="1" column="0">
+ <widget class="TQLayoutWidget" row="1" column="0">
<property name="name">
- <cstring>layout3</cstring>
+ <cstring>tqlayout3</cstring>
</property>
<hbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>textLabel1</cstring>
</property>
@@ -118,7 +118,7 @@
<string>Find:</string>
</property>
</widget>
- <widget class="QLineEdit">
+ <widget class="TQLineEdit">
<property name="name">
<cstring>nameEdit</cstring>
</property>
@@ -143,7 +143,7 @@
<slot>reject()</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>klistview.h</includehint>
</includehints>
diff --git a/kommander/editor/choosewidgetimpl.cpp b/kommander/editor/choosewidgetimpl.cpp
index 527137b4..4fe816e2 100644
--- a/kommander/editor/choosewidgetimpl.cpp
+++ b/kommander/editor/choosewidgetimpl.cpp
@@ -55,7 +55,7 @@ void ChooseWidget::setWidget(TQWidget* w)
TQPtrStack<TQWidget> p_widgets;
TQPtrStack<TQListViewItem> p_items;
- item = new TQListViewItem(widgetView, TQString("%1 (%2)").arg(w->name()).arg(w->className()));
+ item = new TQListViewItem(widgetView, TQString("%1 (%2)").tqarg(w->name()).tqarg(w->className()));
item->setOpen(true);
p_widgets.push(w);
@@ -68,8 +68,8 @@ void ChooseWidget::setWidget(TQWidget* w)
for (TQObjectListIt it(*objectList); it.current(); ++it) {
TQListViewItem* newItem = item;
if (isKommanderWidget(*it))
- newItem = new TQListViewItem(item, TQString("%1 (%2)").arg((*it)->name()).arg((*it)->className()));
- if ((*it)->children()) {
+ newItem = new TQListViewItem(item, TQString("%1 (%2)").tqarg((*it)->name()).tqarg((*it)->className()));
+ if (!(*it)->childrenListObject().isEmpty()) {
p_widgets.push((TQWidget*)(*it));
p_items.push(newItem);
}
@@ -88,12 +88,12 @@ TQString ChooseWidget::selection()
if (widgetView->currentItem())
return widgetView->currentItem()->text(0);
else
- return TQString::null;
+ return TQString();
}
void ChooseWidget::textChanged(const TQString& text)
{
- TQListViewItem* item = widgetView->findItem(text, 0, Qt::BeginsWith);
+ TQListViewItem* item = widgetView->tqfindItem(text, 0, TQt::BeginsWith);
if (item) {
widgetView->setCurrentItem(item);
widgetView->ensureItemVisible(item);
@@ -103,10 +103,10 @@ void ChooseWidget::textChanged(const TQString& text)
bool ChooseWidget::isKommanderWidget(TQObject* w)
{
bool pExists = false;
- TQMetaObject *metaObj = w->metaObject();
+ TQMetaObject *metaObj = w->tqmetaObject();
if (metaObj)
{
- int id = metaObj->findProperty("KommanderWidget", true);
+ int id = metaObj->tqfindProperty("KommanderWidget", true);
const TQMetaProperty *metaProp = metaObj->property(id, true);
if (metaProp && metaProp->isValid())
pExists = true;
diff --git a/kommander/editor/choosewidgetimpl.h b/kommander/editor/choosewidgetimpl.h
index 4dea4c77..4c2bbd45 100644
--- a/kommander/editor/choosewidgetimpl.h
+++ b/kommander/editor/choosewidgetimpl.h
@@ -22,10 +22,11 @@
class ChooseWidget : public ChooseWidgetBase
{
Q_OBJECT
+ TQ_OBJECT
public:
ChooseWidget(TQWidget*, const char* = 0, bool=true);
~ChooseWidget();
- // Put current widget and all of its children in a tree
+ // Put current widget and all of its tqchildren in a tree
void setWidget(TQWidget *);
// Return current widget
TQString selection();
diff --git a/kommander/editor/command.cpp b/kommander/editor/command.cpp
index a0f8ec37..a549c915 100644
--- a/kommander/editor/command.cpp
+++ b/kommander/editor/command.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -43,7 +43,7 @@
#include <tqmultilineedit.h>
#include <tqptrstack.h>
#include <tqheader.h>
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
#include <tqtable.h>
#endif
#include <tqaction.h>
@@ -235,8 +235,8 @@ void ResizeCommand::execute()
{
widget->setGeometry( newRect );
formWindow()->updateSelection( widget );
- formWindow()->emitUpdateProperties( widget );
- if ( WidgetFactory::layoutType( widget ) != WidgetFactory::NoLayout )
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(widget) );
+ if ( WidgetFactory::tqlayoutType( widget ) != WidgetFactory::NoLayout )
formWindow()->updateChildSelections( widget );
}
@@ -244,8 +244,8 @@ void ResizeCommand::unexecute()
{
widget->setGeometry( oldRect );
formWindow()->updateSelection( widget );
- formWindow()->emitUpdateProperties( widget );
- if ( WidgetFactory::layoutType( widget ) != WidgetFactory::NoLayout )
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(widget) );
+ if ( WidgetFactory::tqlayoutType( widget ) != WidgetFactory::NoLayout )
formWindow()->updateChildSelections( widget );
}
@@ -253,32 +253,32 @@ void ResizeCommand::unexecute()
InsertCommand::InsertCommand( const TQString &n, FormWindow *fw,
TQWidget *w, const TQRect &g )
- : Command( n, fw ), widget( w ), geometry( g )
+ : Command( n, fw ), widget( w ), tqgeometry( g )
{
}
void InsertCommand::execute()
{
- if ( geometry.size() == TQSize( 0, 0 ) ) {
- widget->move( geometry.topLeft() );
+ if ( tqgeometry.size() == TQSize( 0, 0 ) ) {
+ widget->move( tqgeometry.topLeft() );
widget->adjustSize();
} else {
- TQSize s = geometry.size().expandedTo( widget->minimumSize() );
- s = s.expandedTo( widget->minimumSizeHint() );
- TQRect r( geometry.topLeft(), s );
+ TQSize s = tqgeometry.size().expandedTo( widget->tqminimumSize() );
+ s = s.expandedTo( widget->tqminimumSizeHint() );
+ TQRect r( tqgeometry.topLeft(), s );
widget->setGeometry( r );
}
widget->show();
formWindow()->widgets()->insert( widget, widget );
formWindow()->clearSelection( false );
- formWindow()->selectWidget( widget );
+ formWindow()->selectWidget( TQT_TQOBJECT(widget) );
formWindow()->mainWindow()->objectHierarchy()->widgetInserted( widget );
}
void InsertCommand::unexecute()
{
widget->hide();
- formWindow()->selectWidget( widget, false );
+ formWindow()->selectWidget( TQT_TQOBJECT(widget), false );
formWindow()->widgets()->remove( widget );
formWindow()->mainWindow()->objectHierarchy()->widgetRemoved( widget );
}
@@ -312,13 +312,13 @@ bool MoveCommand::canMerge( Command *c )
void MoveCommand::execute()
{
for ( TQWidget *w = widgets.first(); w; w = widgets.next() ) {
- if ( !w->parentWidget() || WidgetFactory::layoutType( w->parentWidget() ) == WidgetFactory::NoLayout ) {
+ if ( !w->tqparentWidget() || WidgetFactory::tqlayoutType( w->tqparentWidget() ) == WidgetFactory::NoLayout ) {
if ( newParent && oldParent && newParent != oldParent ) {
TQPoint pos = newParent->mapFromGlobal( w->mapToGlobal( TQPoint( 0,0 ) ) );
w->reparent( newParent, pos, true );
formWindow()->raiseSelection( w );
formWindow()->raiseChildSelections( w );
- formWindow()->widgetChanged( w );
+ formWindow()->widgetChanged( TQT_TQOBJECT(w) );
formWindow()->mainWindow()->objectHierarchy()->widgetRemoved( w );
formWindow()->mainWindow()->objectHierarchy()->widgetInserted( w );
}
@@ -326,20 +326,20 @@ void MoveCommand::execute()
}
formWindow()->updateSelection( w );
formWindow()->updateChildSelections( w );
- formWindow()->emitUpdateProperties( w );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(w) );
}
}
void MoveCommand::unexecute()
{
for ( TQWidget *w = widgets.first(); w; w = widgets.next() ) {
- if ( !w->parentWidget() || WidgetFactory::layoutType( w->parentWidget() ) == WidgetFactory::NoLayout ) {
+ if ( !w->tqparentWidget() || WidgetFactory::tqlayoutType( w->tqparentWidget() ) == WidgetFactory::NoLayout ) {
if ( newParent && oldParent && newParent != oldParent ) {
TQPoint pos = oldParent->mapFromGlobal( w->mapToGlobal( TQPoint( 0,0 ) ) );
w->reparent( oldParent, pos, true );
formWindow()->raiseSelection( w );
formWindow()->raiseChildSelections( w );
- formWindow()->widgetChanged( w );
+ formWindow()->widgetChanged( TQT_TQOBJECT(w) );
formWindow()->mainWindow()->objectHierarchy()->widgetRemoved( w );
formWindow()->mainWindow()->objectHierarchy()->widgetInserted( w );
}
@@ -347,7 +347,7 @@ void MoveCommand::unexecute()
}
formWindow()->updateSelection( w );
formWindow()->updateChildSelections( w );
- formWindow()->emitUpdateProperties( w );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(w) );
}
}
@@ -369,13 +369,13 @@ void DeleteCommand::execute()
TQString s = w->name();
s.prepend( "qt_dead_widget_" );
w->setName( s );
- formWindow()->selectWidget( w, false );
+ formWindow()->selectWidget( TQT_TQOBJECT(w), false );
formWindow()->widgets()->remove( w );
- TQValueList<MetaDataBase::Connection> conns = MetaDataBase::connections( formWindow(), w );
+ TQValueList<MetaDataBase::Connection> conns = MetaDataBase::connections( TQT_TQOBJECT(formWindow()), TQT_TQOBJECT(w) );
connections.insert( w, conns );
TQValueList<MetaDataBase::Connection>::Iterator it = conns.begin();
for ( ; it != conns.end(); ++it ) {
- MetaDataBase::removeConnection( formWindow(), (*it).sender,
+ MetaDataBase::removeConnection( TQT_TQOBJECT(formWindow()), (*it).sender,
(*it).signal, (*it).receiver, (*it).slot );
}
}
@@ -395,11 +395,11 @@ void DeleteCommand::unexecute()
s.remove( 0, TQString( "qt_dead_widget_" ).length() );
w->setName( s );
formWindow()->widgets()->insert( w, w );
- formWindow()->selectWidget( w );
- TQValueList<MetaDataBase::Connection> conns = *connections.find( w );
+ formWindow()->selectWidget( TQT_TQOBJECT(w) );
+ TQValueList<MetaDataBase::Connection> conns = *connections.tqfind( w );
TQValueList<MetaDataBase::Connection>::Iterator it = conns.begin();
for ( ; it != conns.end(); ++it ) {
- MetaDataBase::addConnection( formWindow(), (*it).sender,
+ MetaDataBase::addConnection( TQT_TQOBJECT(formWindow()), (*it).sender,
(*it).signal, (*it).receiver, (*it).slot );
}
}
@@ -430,7 +430,7 @@ void SetPropertyCommand::execute()
if ( isResetCommand ) {
MetaDataBase::setPropertyChanged( widget, propName, false );
if ( WidgetFactory::resetProperty( widget, propName ) ) {
- if ( !formWindow()->isWidgetSelected( widget ) && widget != formWindow() )
+ if ( !formWindow()->isWidgetSelected( widget ) && TQT_BASE_OBJECT(widget) != TQT_BASE_OBJECT(formWindow()) )
formWindow()->selectWidget( widget );
if ( editor->widget() != widget )
editor->setWidget( widget, formWindow() );
@@ -461,7 +461,7 @@ bool SetPropertyCommand::canMerge( Command *c )
{
SetPropertyCommand *cmd = (SetPropertyCommand*)c;
const TQMetaProperty *p =
- widget->metaObject()->property( widget->metaObject()->findProperty( propName, true ), true );
+ widget->tqmetaObject()->property( widget->tqmetaObject()->tqfindProperty( propName, true ), true );
if ( !p ) {
if ( propName == "toolTip" || propName == "whatsThis" )
return true;
@@ -516,8 +516,8 @@ bool SetPropertyCommand::checkProperty()
return false;
}
- if ( widget->parent() && widget->parent()->inherits( "FormWindow" ) )
- formWindow()->mainWindow()->formNameChanged( (FormWindow*)( (TQWidget*)widget )->parentWidget() );
+ if ( widget->tqparent() && widget->tqparent()->inherits( "FormWindow" ) )
+ formWindow()->mainWindow()->formNameChanged( (FormWindow*)( (TQWidget*)widget )->tqparentWidget() );
}
return true;
}
@@ -532,30 +532,30 @@ void SetPropertyCommand::setProperty( const TQVariant &v, const TQString &curren
editor->propertyList()->setCurrentProperty( propName );
const TQMetaProperty *p =
- widget->metaObject()->property( widget->metaObject()->findProperty( propName, true ), true );
+ widget->tqmetaObject()->property( widget->tqmetaObject()->tqfindProperty( propName, true ), true );
if ( !p ) {
if ( propName == "hAlign" ) {
- p = widget->metaObject()->property( widget->metaObject()->findProperty( "alignment", true ), true );
- int align = widget->property( "alignment" ).toInt();
+ p = widget->tqmetaObject()->property( widget->tqmetaObject()->tqfindProperty( "tqalignment", true ), true );
+ int align = widget->property( "tqalignment" ).toInt();
align &= ~( AlignHorizontal_Mask );
align |= p->keyToValue( currentItemText );
- widget->setProperty( "alignment", TQVariant( align ) );
+ widget->setProperty( "tqalignment", TQVariant( align ) );
} else if ( propName == "vAlign" ) {
- p = widget->metaObject()->property( widget->metaObject()->findProperty( "alignment", true ), true );
- int align = widget->property( "alignment" ).toInt();
+ p = widget->tqmetaObject()->property( widget->tqmetaObject()->tqfindProperty( "tqalignment", true ), true );
+ int align = widget->property( "tqalignment" ).toInt();
align &= ~( AlignVertical_Mask );
align |= p->keyToValue( currentItemText );
- widget->setProperty( "alignment", TQVariant( align ) );
+ widget->setProperty( "tqalignment", TQVariant( align ) );
} else if ( propName == "wordwrap" ) {
- int align = widget->property( "alignment" ).toInt();
+ int align = widget->property( "tqalignment" ).toInt();
align &= ~WordBreak;
if ( v.toBool() )
align |= WordBreak;
- widget->setProperty( "alignment", TQVariant( align ) );
- } else if ( propName == "layoutSpacing" ) {
- MetaDataBase::setSpacing( WidgetFactory::containerOfWidget( (TQWidget*)editor->widget() ), v.toInt() );
- } else if ( propName == "layoutMargin" ) {
- MetaDataBase::setMargin( WidgetFactory::containerOfWidget( (TQWidget*)editor->widget() ), v.toInt() );
+ widget->setProperty( "tqalignment", TQVariant( align ) );
+ } else if ( propName == "tqlayoutSpacing" ) {
+ MetaDataBase::setSpacing( TQT_TQOBJECT(WidgetFactory::containerOfWidget( TQT_TQWIDGET(editor->widget()) )), v.toInt() );
+ } else if ( propName == "tqlayoutMargin" ) {
+ MetaDataBase::setMargin( TQT_TQOBJECT(WidgetFactory::containerOfWidget( TQT_TQWIDGET(editor->widget()) )), v.toInt() );
} else if ( propName == "toolTip" || propName == "whatsThis" || propName == "database" || propName == "frameworkCode" ) {
MetaDataBase::setFakeProperty( editor->widget(), propName, v );
} else if ( editor->widget()->inherits( "CustomWidget" ) ) {
@@ -567,7 +567,7 @@ void SetPropertyCommand::setProperty( const TQVariant &v, const TQString &curren
editor->refetchData();
editor->emitWidgetChanged();
( ( PropertyItem* )editor->propertyList()->currentItem() )->setChanged( MetaDataBase::isPropertyChanged( widget, propName ) );
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
if ( propName == "database" )
formWindow()->mainWindow()->objectHierarchy()->databasePropertyChanged( (TQWidget*)widget, MetaDataBase::fakeProperty( widget, "database" ).toStringList() );
#endif
@@ -587,9 +587,9 @@ void SetPropertyCommand::setProperty( const TQVariant &v, const TQString &curren
oldSerNum = v.toPixmap().serialNumber();
widget->setProperty( propName, v );
if ( oldSerNum != -1 && oldSerNum != widget->property( propName ).toPixmap().serialNumber() )
- MetaDataBase::setPixmapKey( formWindow(),
+ MetaDataBase::setPixmapKey( TQT_TQOBJECT(formWindow()),
widget->property( propName ).toPixmap().serialNumber(),
- MetaDataBase::pixmapKey( formWindow(), oldSerNum ) );
+ MetaDataBase::pixmapKey( TQT_TQOBJECT(formWindow()), oldSerNum ) );
if ( propName == "cursor" )
MetaDataBase::setCursor( (TQWidget*)widget, v.toCursor() );
if ( propName == "name" && widget->isWidgetType() ) {
@@ -628,156 +628,156 @@ void SetPropertyCommand::setProperty( const TQVariant &v, const TQString &curren
// ------------------------------------------------------------
LayoutHorizontalCommand::LayoutHorizontalCommand( const TQString &n, FormWindow *fw,
- TQWidget *parent, TQWidget *layoutBase,
+ TQWidget *tqparent, TQWidget *tqlayoutBase,
const TQWidgetList &wl )
- : Command( n, fw ), layout( wl, parent, fw, layoutBase )
+ : Command( n, fw ), tqlayout( wl, tqparent, fw, tqlayoutBase )
{
}
void LayoutHorizontalCommand::execute()
{
formWindow()->clearSelection( false );
- layout.doLayout();
+ tqlayout.doLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
void LayoutHorizontalCommand::unexecute()
{
formWindow()->clearSelection( false );
- layout.undoLayout();
+ tqlayout.undoLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
// ------------------------------------------------------------
LayoutHorizontalSplitCommand::LayoutHorizontalSplitCommand( const TQString &n, FormWindow *fw,
- TQWidget *parent, TQWidget *layoutBase,
+ TQWidget *tqparent, TQWidget *tqlayoutBase,
const TQWidgetList &wl )
- : Command( n, fw ), layout( wl, parent, fw, layoutBase, true, true )
+ : Command( n, fw ), tqlayout( wl, tqparent, fw, tqlayoutBase, true, true )
{
}
void LayoutHorizontalSplitCommand::execute()
{
formWindow()->clearSelection( false );
- layout.doLayout();
+ tqlayout.doLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
void LayoutHorizontalSplitCommand::unexecute()
{
formWindow()->clearSelection( false );
- layout.undoLayout();
+ tqlayout.undoLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
// ------------------------------------------------------------
LayoutVerticalCommand::LayoutVerticalCommand( const TQString &n, FormWindow *fw,
- TQWidget *parent, TQWidget *layoutBase,
+ TQWidget *tqparent, TQWidget *tqlayoutBase,
const TQWidgetList &wl )
- : Command( n, fw ), layout( wl, parent, fw, layoutBase )
+ : Command( n, fw ), tqlayout( wl, tqparent, fw, tqlayoutBase )
{
}
void LayoutVerticalCommand::execute()
{
formWindow()->clearSelection( false );
- layout.doLayout();
+ tqlayout.doLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
void LayoutVerticalCommand::unexecute()
{
formWindow()->clearSelection( false );
- layout.undoLayout();
+ tqlayout.undoLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
// ------------------------------------------------------------
LayoutVerticalSplitCommand::LayoutVerticalSplitCommand( const TQString &n, FormWindow *fw,
- TQWidget *parent, TQWidget *layoutBase,
+ TQWidget *tqparent, TQWidget *tqlayoutBase,
const TQWidgetList &wl )
- : Command( n, fw ), layout( wl, parent, fw, layoutBase, true, true )
+ : Command( n, fw ), tqlayout( wl, tqparent, fw, tqlayoutBase, true, true )
{
}
void LayoutVerticalSplitCommand::execute()
{
formWindow()->clearSelection( false );
- layout.doLayout();
+ tqlayout.doLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
void LayoutVerticalSplitCommand::unexecute()
{
formWindow()->clearSelection( false );
- layout.undoLayout();
+ tqlayout.undoLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
// ------------------------------------------------------------
LayoutGridCommand::LayoutGridCommand( const TQString &n, FormWindow *fw,
- TQWidget *parent, TQWidget *layoutBase,
+ TQWidget *tqparent, TQWidget *tqlayoutBase,
const TQWidgetList &wl, int xres, int yres )
- : Command( n, fw ), layout( wl, parent, fw, layoutBase, TQSize( QMAX(5,xres), QMAX(5,yres) ) )
+ : Command( n, fw ), tqlayout( wl, tqparent, fw, tqlayoutBase, TQSize( TQMAX(5,xres), TQMAX(5,yres) ) )
{
}
void LayoutGridCommand::execute()
{
formWindow()->clearSelection( false );
- layout.doLayout();
+ tqlayout.doLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
void LayoutGridCommand::unexecute()
{
formWindow()->clearSelection( false );
- layout.undoLayout();
+ tqlayout.undoLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
}
// ------------------------------------------------------------
BreakLayoutCommand::BreakLayoutCommand( const TQString &n, FormWindow *fw,
- TQWidget *layoutBase, const TQWidgetList &wl )
- : Command( n, fw ), lb( layoutBase ), widgets( wl )
+ TQWidget *tqlayoutBase, const TQWidgetList &wl )
+ : Command( n, fw ), lb( tqlayoutBase ), widgets( wl )
{
- WidgetFactory::LayoutType lay = WidgetFactory::layoutType( layoutBase );
- spacing = MetaDataBase::spacing( layoutBase );
- margin = MetaDataBase::margin( layoutBase );
- layout = 0;
+ WidgetFactory::LayoutType lay = WidgetFactory::tqlayoutType( tqlayoutBase );
+ spacing = MetaDataBase::spacing( TQT_TQOBJECT(tqlayoutBase) );
+ margin = MetaDataBase::margin( TQT_TQOBJECT(tqlayoutBase) );
+ tqlayout = 0;
if ( lay == WidgetFactory::HBox )
- layout = new HorizontalLayout( wl, layoutBase, fw, layoutBase, false, layoutBase->inherits( TQSPLITTER_OBJECT_NAME_STRING ) );
+ tqlayout = new HorizontalLayout( wl, tqlayoutBase, fw, tqlayoutBase, false, tqlayoutBase->inherits( TQSPLITTER_OBJECT_NAME_STRING ) );
else if ( lay == WidgetFactory::VBox )
- layout = new VerticalLayout( wl, layoutBase, fw, layoutBase, false, layoutBase->inherits( TQSPLITTER_OBJECT_NAME_STRING ) );
+ tqlayout = new VerticalLayout( wl, tqlayoutBase, fw, tqlayoutBase, false, tqlayoutBase->inherits( TQSPLITTER_OBJECT_NAME_STRING ) );
else if ( lay == WidgetFactory::Grid )
- layout = new GridLayout( wl, layoutBase, fw, layoutBase, TQSize( QMAX( 5, fw->grid().x()), QMAX( 5, fw->grid().y()) ), false );
+ tqlayout = new GridLayout( wl, tqlayoutBase, fw, tqlayoutBase, TQSize( TQMAX( 5, fw->grid().x()), TQMAX( 5, fw->grid().y()) ), false );
}
void BreakLayoutCommand::execute()
{
- if ( !layout )
+ if ( !tqlayout )
return;
formWindow()->clearSelection( false );
- layout->breakLayout();
+ tqlayout->breakLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
for ( TQWidget *w = widgets.first(); w; w = widgets.next() )
- w->resize( QMAX( 16, w->width() ), QMAX( 16, w->height() ) );
+ w->resize( TQMAX( 16, w->width() ), TQMAX( 16, w->height() ) );
}
void BreakLayoutCommand::unexecute()
{
- if ( !layout )
+ if ( !tqlayout )
return;
formWindow()->clearSelection( false );
- layout->doLayout();
+ tqlayout->doLayout();
formWindow()->mainWindow()->objectHierarchy()->rebuild();
- MetaDataBase::setSpacing( WidgetFactory::containerOfWidget( lb ), spacing );
- MetaDataBase::setMargin( WidgetFactory::containerOfWidget( lb ), margin );
+ MetaDataBase::setSpacing( TQT_TQOBJECT(WidgetFactory::containerOfWidget( lb )), spacing );
+ MetaDataBase::setMargin( TQT_TQOBJECT(WidgetFactory::containerOfWidget( lb )), margin );
}
// ------------------------------------------------------------
@@ -806,19 +806,19 @@ AddTabPageCommand::AddTabPageCommand( const TQString &n, FormWindow *fw,
TQTabWidget *tw, const TQString &label )
: Command( n, fw ), tabWidget( tw ), tabLabel( label )
{
- tabPage = new QDesignerWidget( formWindow(), tabWidget, "tab" );
+ tabPage = new TQDesignerWidget( formWindow(), tabWidget, "tab" );
tabPage->hide();
index = -1;
- MetaDataBase::addEntry( tabPage );
+ MetaDataBase::addEntry( TQT_TQOBJECT(tabPage) );
}
void AddTabPageCommand::execute()
{
if ( index == -1 )
- index = ( (QDesignerTabWidget*)tabWidget )->count();
+ index = ( (TQDesignerTabWidget*)tabWidget )->count();
tabWidget->insertTab( tabPage, tabLabel, index );
tabWidget->showPage( tabPage );
- formWindow()->emitUpdateProperties( formWindow()->currentWidget() );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(formWindow()->currentWidget()) );
formWindow()->mainWindow()->objectHierarchy()->tabsChanged( tabWidget );
}
@@ -826,7 +826,7 @@ void AddTabPageCommand::unexecute()
{
tabWidget->removePage( tabPage );
tabPage->hide();
- formWindow()->emitUpdateProperties( formWindow()->currentWidget() );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(formWindow()->currentWidget()) );
formWindow()->mainWindow()->objectHierarchy()->tabsChanged( tabWidget );
}
@@ -837,10 +837,10 @@ AddToolBoxPageCommand::AddToolBoxPageCommand( const TQString &n, FormWindow *fw,
TQToolBox *tw, const TQString &_label )
: Command( n, fw ), toolBox( tw ), label( _label )
{
- page = new QDesignerWidget( formWindow(), toolBox, "tab" );
+ page = new TQDesignerWidget( formWindow(), toolBox, "tab" );
page->hide();
index = -1;
- MetaDataBase::addEntry( page );
+ MetaDataBase::addEntry( TQT_TQOBJECT(page) );
}
void AddToolBoxPageCommand::execute()
@@ -849,7 +849,7 @@ void AddToolBoxPageCommand::execute()
index = ( (EditorToolBox*)toolBox)->count();
toolBox->insertItem(index, page, label);
toolBox->setCurrentItem( page );
- formWindow()->emitUpdateProperties( formWindow()->currentWidget() );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(formWindow()->currentWidget()) );
formWindow()->mainWindow()->objectHierarchy()->tabsChanged( toolBox );
}
@@ -857,7 +857,7 @@ void AddToolBoxPageCommand::unexecute()
{
toolBox->removeItem( page );
page->hide();
- formWindow()->emitUpdateProperties( formWindow()->currentWidget() );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(formWindow()->currentWidget()) );
formWindow()->mainWindow()->objectHierarchy()->tabsChanged( toolBox );
}
@@ -873,19 +873,19 @@ MoveTabPageCommand::MoveTabPageCommand( const TQString &n, FormWindow *fw,
void MoveTabPageCommand::execute()
{
- ((QDesignerTabWidget*)tabWidget )->removePage( tabPage );
- ((QDesignerTabWidget*)tabWidget )->insertTab( tabPage, tabLabel, newIndex );
- ((QDesignerTabWidget*)tabWidget )->showPage( tabPage );
- formWindow()->emitUpdateProperties( formWindow()->currentWidget() );
+ ((TQDesignerTabWidget*)tabWidget )->removePage( tabPage );
+ ((TQDesignerTabWidget*)tabWidget )->insertTab( tabPage, tabLabel, newIndex );
+ ((TQDesignerTabWidget*)tabWidget )->showPage( tabPage );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(formWindow()->currentWidget()) );
formWindow()->mainWindow()->objectHierarchy()->tabsChanged( tabWidget );
}
void MoveTabPageCommand::unexecute()
{
- ((QDesignerTabWidget*)tabWidget )->removePage( tabPage );
- ((QDesignerTabWidget*)tabWidget )->insertTab( tabPage, tabLabel, oldIndex );
- ((QDesignerTabWidget*)tabWidget )->showPage( tabPage );
- formWindow()->emitUpdateProperties( formWindow()->currentWidget() );
+ ((TQDesignerTabWidget*)tabWidget )->removePage( tabPage );
+ ((TQDesignerTabWidget*)tabWidget )->insertTab( tabPage, tabLabel, oldIndex );
+ ((TQDesignerTabWidget*)tabWidget )->showPage( tabPage );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(formWindow()->currentWidget()) );
formWindow()->mainWindow()->objectHierarchy()->tabsChanged( tabWidget );
}
@@ -895,15 +895,15 @@ DeleteTabPageCommand::DeleteTabPageCommand( const TQString &n, FormWindow *fw,
TQTabWidget *tw, TQWidget *page )
: Command( n, fw ), tabWidget( tw ), tabPage( page )
{
- tabLabel = ( (QDesignerTabWidget*)tabWidget )->pageTitle();
- index = ( (QDesignerTabWidget*)tabWidget )->currentPage();
+ tabLabel = ( (TQDesignerTabWidget*)tabWidget )->pageTitle();
+ index = ( (TQDesignerTabWidget*)tabWidget )->currentPage();
}
void DeleteTabPageCommand::execute()
{
tabWidget->removePage( tabPage );
tabPage->hide();
- formWindow()->emitUpdateProperties( formWindow()->currentWidget() );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(formWindow()->currentWidget()) );
formWindow()->mainWindow()->objectHierarchy()->tabsChanged( tabWidget );
}
@@ -911,7 +911,7 @@ void DeleteTabPageCommand::unexecute()
{
tabWidget->insertTab( tabPage, tabLabel, index );
tabWidget->showPage( tabPage );
- formWindow()->emitUpdateProperties( formWindow()->currentWidget() );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(formWindow()->currentWidget()) );
formWindow()->mainWindow()->objectHierarchy()->tabsChanged( tabWidget );
}
@@ -929,7 +929,7 @@ void DeleteToolBoxPageCommand::execute()
{
toolBox->removeItem( page );
page->hide();
- formWindow()->emitUpdateProperties( formWindow()->currentWidget() );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(formWindow()->currentWidget()) );
formWindow()->mainWindow()->objectHierarchy()->tabsChanged( toolBox );
}
@@ -937,7 +937,7 @@ void DeleteToolBoxPageCommand::unexecute()
{
toolBox->insertItem(index, page, label);
toolBox->setCurrentItem( page );
- formWindow()->emitUpdateProperties( formWindow()->currentWidget() );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(formWindow()->currentWidget()) );
formWindow()->mainWindow()->objectHierarchy()->tabsChanged( toolBox );
}
@@ -947,11 +947,11 @@ AddWizardPageCommand::AddWizardPageCommand( const TQString &n, FormWindow *fw,
TQWizard *w, const TQString &label, int i, bool s )
: Command( n, fw ), wizard( w ), pageLabel( label )
{
- page = new QDesignerWidget( formWindow(), wizard, "page" );
+ page = new TQDesignerWidget( formWindow(), wizard, "page" );
page->hide();
index = i;
show = s;
- MetaDataBase::addEntry( page );
+ MetaDataBase::addEntry( TQT_TQOBJECT(page) );
}
void AddWizardPageCommand::execute()
@@ -960,8 +960,8 @@ void AddWizardPageCommand::execute()
index = wizard->pageCount();
wizard->insertPage( page, pageLabel, index );
if ( show )
- ( (QDesignerWizard*)wizard )->setCurrentPage( ( (QDesignerWizard*)wizard )->pageNum( page ) );
- formWindow()->emitUpdateProperties( formWindow()->currentWidget() );
+ ( (TQDesignerWizard*)wizard )->setCurrentPage( ( (TQDesignerWizard*)wizard )->pageNum( page ) );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(formWindow()->currentWidget()) );
formWindow()->mainWindow()->objectHierarchy()->pagesChanged( wizard );
}
@@ -969,7 +969,7 @@ void AddWizardPageCommand::unexecute()
{
wizard->removePage( page );
page->hide();
- formWindow()->emitUpdateProperties( formWindow()->currentWidget() );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(formWindow()->currentWidget()) );
formWindow()->mainWindow()->objectHierarchy()->pagesChanged( wizard );
}
@@ -988,7 +988,7 @@ void DeleteWizardPageCommand::execute()
pageLabel = wizard->title( page );
wizard->removePage( page );
page->hide();
- formWindow()->emitUpdateProperties( formWindow()->currentWidget() );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(formWindow()->currentWidget()) );
formWindow()->mainWindow()->objectHierarchy()->pagesChanged( wizard );
}
@@ -996,8 +996,8 @@ void DeleteWizardPageCommand::unexecute()
{
wizard->insertPage( page, pageLabel, index );
if ( show )
- ( (QDesignerWizard*)wizard )->setCurrentPage( ( (QDesignerWizard*)wizard )->pageNum( page ) );
- formWindow()->emitUpdateProperties( formWindow()->currentWidget() );
+ ( (TQDesignerWizard*)wizard )->setCurrentPage( ( (TQDesignerWizard*)wizard )->pageNum( page ) );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(formWindow()->currentWidget()) );
formWindow()->mainWindow()->objectHierarchy()->pagesChanged( wizard );
}
@@ -1017,7 +1017,7 @@ void RenameWizardPageCommand::execute()
wizard->setTitle( page, label );
label = oldLabel;
- formWindow()->emitUpdateProperties( formWindow()->currentWidget() );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(formWindow()->currentWidget()) );
}
void RenameWizardPageCommand::unexecute()
@@ -1042,7 +1042,7 @@ void SwapWizardPagesCommand::execute()
wizard->removePage( page2 );
wizard->insertPage( page1, page1Label, index2 );
wizard->insertPage( page2, page2Label, index1 );
- formWindow()->emitUpdateProperties( formWindow()->currentWidget() );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(formWindow()->currentWidget()) );
formWindow()->mainWindow()->objectHierarchy()->pagesChanged( wizard );
}
@@ -1061,7 +1061,7 @@ AddConnectionCommand::AddConnectionCommand( const TQString &name, FormWindow *fw
void AddConnectionCommand::execute()
{
- MetaDataBase::addConnection( formWindow(), connection.sender,
+ MetaDataBase::addConnection( TQT_TQOBJECT(formWindow()), connection.sender,
connection.signal, connection.receiver, connection.slot );
#ifndef KOMMANDER
if ( connection.receiver == formWindow()->mainContainer() )
@@ -1074,7 +1074,7 @@ void AddConnectionCommand::execute()
void AddConnectionCommand::unexecute()
{
- MetaDataBase::removeConnection( formWindow(), connection.sender,
+ MetaDataBase::removeConnection( TQT_TQOBJECT(formWindow()), connection.sender,
connection.signal, connection.receiver, connection.slot );
#ifndef KOMMANDER
if ( connection.receiver == formWindow()->mainContainer() )
@@ -1095,7 +1095,7 @@ RemoveConnectionCommand::RemoveConnectionCommand( const TQString &name, FormWind
void RemoveConnectionCommand::execute()
{
- MetaDataBase::removeConnection( formWindow(), connection.sender,
+ MetaDataBase::removeConnection( TQT_TQOBJECT(formWindow()), connection.sender,
connection.signal, connection.receiver, connection.slot );
#ifndef KOMMANDER
if ( connection.receiver == formWindow()->mainContainer() )
@@ -1108,7 +1108,7 @@ void RemoveConnectionCommand::execute()
void RemoveConnectionCommand::unexecute()
{
- MetaDataBase::addConnection( formWindow(), connection.sender,
+ MetaDataBase::addConnection( TQT_TQOBJECT(formWindow()), connection.sender,
connection.signal, connection.receiver, connection.slot );
#ifndef KOMMANDER
if ( connection.receiver == formWindow()->mainContainer() )
@@ -1131,7 +1131,7 @@ AddSlotCommand::AddSlotCommand( const TQString &name, FormWindow *fw, const TQCS
void AddSlotCommand::execute()
{
- MetaDataBase::addSlot( formWindow(), slot, specifier, access, language, returnType );
+ MetaDataBase::addSlot( TQT_TQOBJECT(formWindow()), slot, specifier, access, language, returnType );
#ifndef KOMMANDER
formWindow()->mainWindow()->slotsChanged();
#endif
@@ -1141,7 +1141,7 @@ void AddSlotCommand::execute()
void AddSlotCommand::unexecute()
{
- MetaDataBase::removeSlot( formWindow(), slot, specifier, access, language, returnType );
+ MetaDataBase::removeSlot( TQT_TQOBJECT(formWindow()), slot, specifier, access, language, returnType );
#ifndef KOMMANDER
formWindow()->mainWindow()->slotsChanged();
#endif
@@ -1160,7 +1160,7 @@ RemoveSlotCommand::RemoveSlotCommand( const TQString &name, FormWindow *fw, cons
void RemoveSlotCommand::execute()
{
- MetaDataBase::removeSlot( formWindow(), slot, specifier, access, language, returnType );
+ MetaDataBase::removeSlot( TQT_TQOBJECT(formWindow()), slot, specifier, access, language, returnType );
#ifndef KOMMANDER
formWindow()->mainWindow()->slotsChanged();
#endif
@@ -1170,7 +1170,7 @@ void RemoveSlotCommand::execute()
void RemoveSlotCommand::unexecute()
{
- MetaDataBase::addSlot( formWindow(), slot, specifier, access, language, returnType );
+ MetaDataBase::addSlot( TQT_TQOBJECT(formWindow()), slot, specifier, access, language, returnType );
#ifndef KOMMANDER
formWindow()->mainWindow()->slotsChanged();
#endif
@@ -1238,7 +1238,7 @@ void PasteCommand::execute()
{
for ( TQWidget *w = widgets.first(); w; w = widgets.next() ) {
w->show();
- formWindow()->selectWidget( w );
+ formWindow()->selectWidget( TQT_TQOBJECT(w) );
formWindow()->widgets()->insert( w, w );
formWindow()->mainWindow()->objectHierarchy()->widgetInserted( w );
}
@@ -1248,7 +1248,7 @@ void PasteCommand::unexecute()
{
for ( TQWidget *w = widgets.first(); w; w = widgets.next() ) {
w->hide();
- formWindow()->selectWidget( w, false );
+ formWindow()->selectWidget( TQT_TQOBJECT(w), false );
formWindow()->widgets()->remove( w );
formWindow()->mainWindow()->objectHierarchy()->widgetRemoved( w );
}
@@ -1331,7 +1331,7 @@ PopulateIconViewCommand::PopulateIconViewCommand( const TQString &n, FormWindow
TQIconView *iv, const TQValueList<Item> &items )
: Command( n, fw ), newItems( items ), iconview( iv )
{
-#ifndef QT_NO_ICONVIEW
+#ifndef TQT_NO_ICONVIEW
TQIconViewItem *i = 0;
for ( i = iconview->firstItem(); i; i = i->nextItem() ) {
Item item;
@@ -1345,7 +1345,7 @@ PopulateIconViewCommand::PopulateIconViewCommand( const TQString &n, FormWindow
void PopulateIconViewCommand::execute()
{
-#ifndef QT_NO_ICONVIEW
+#ifndef TQT_NO_ICONVIEW
iconview->clear();
for ( TQValueList<Item>::Iterator it = newItems.begin(); it != newItems.end(); ++it ) {
Item i = *it;
@@ -1356,7 +1356,7 @@ void PopulateIconViewCommand::execute()
void PopulateIconViewCommand::unexecute()
{
-#ifndef QT_NO_ICONVIEW
+#ifndef TQT_NO_ICONVIEW
iconview->clear();
for ( TQValueList<Item>::Iterator it = oldItems.begin(); it != oldItems.end(); ++it ) {
Item i = *it;
@@ -1417,7 +1417,7 @@ void PopulateListViewCommand::transferItems( TQListView *from, TQListView *to )
from->setSorting( -1 );
for ( ; it.current(); ++it ) {
TQListViewItem *i = it.current();
- if ( i->parent() == fromParents.top() ) {
+ if ( i->tqparent() == fromParents.top() ) {
TQListViewItem *pi = toParents.top();
TQListViewItem *ni = 0;
if ( pi )
@@ -1434,7 +1434,7 @@ void PopulateListViewCommand::transferItems( TQListView *from, TQListView *to )
if ( pi )
pi->setOpen( true );
} else {
- if ( i->parent() == fromLast ) {
+ if ( i->tqparent() == fromLast ) {
fromParents.push( fromLast );
toParents.push( toLasts.top() );
toLasts.push( 0 );
@@ -1454,7 +1454,7 @@ void PopulateListViewCommand::transferItems( TQListView *from, TQListView *to )
if ( pi )
pi->setOpen( true );
} else {
- while ( fromParents.top() != i->parent() ) {
+ while ( fromParents.top() != i->tqparent() ) {
fromParents.pop();
toParents.pop();
toLasts.pop();
@@ -1490,21 +1490,21 @@ PopulateMultiLineEditCommand::PopulateMultiLineEditCommand( const TQString &n, F
: Command( n, fw ), newText( txt ), mlined( mle )
{
oldText = mlined->text();
- wasChanged = MetaDataBase::isPropertyChanged( mlined, "text" );
+ wasChanged = MetaDataBase::isPropertyChanged( TQT_TQOBJECT(mlined), "text" );
}
void PopulateMultiLineEditCommand::execute()
{
mlined->setText( newText );
- MetaDataBase::setPropertyChanged( mlined, "text", true );
- formWindow()->emitUpdateProperties( mlined );
+ MetaDataBase::setPropertyChanged( TQT_TQOBJECT(mlined), "text", true );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(mlined) );
}
void PopulateMultiLineEditCommand::unexecute()
{
mlined->setText( oldText );
- MetaDataBase::setPropertyChanged( mlined, "text", wasChanged );
- formWindow()->emitUpdateProperties( mlined );
+ MetaDataBase::setPropertyChanged( TQT_TQOBJECT(mlined), "text", wasChanged );
+ formWindow()->emitUpdateProperties( TQT_TQOBJECT(mlined) );
}
// ------------------------------------------------------------
@@ -1514,15 +1514,15 @@ PopulateTableCommand::PopulateTableCommand( const TQString &n, FormWindow *fw, T
const TQValueList<Column> &columns )
: Command( n, fw ), newRows( rows ), newColumns( columns ), table( t )
{
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
int i = 0;
- TQMap<TQString, TQString> columnFields = MetaDataBase::columnFields( table );
+ TQMap<TQString, TQString> columnFields = MetaDataBase::columnFields( TQT_TQOBJECT(table));
for ( i = 0; i < table->horizontalHeader()->count(); ++i ) {
PopulateTableCommand::Column col;
col.text = table->horizontalHeader()->label( i );
if ( table->horizontalHeader()->iconSet( i ) )
col.pix = table->horizontalHeader()->iconSet( i )->pixmap();
- col.field = *columnFields.find( col.text );
+ col.field = *columnFields.tqfind( col.text );
oldColumns.append( col );
}
for ( i = 0; i < table->verticalHeader()->count(); ++i ) {
@@ -1537,7 +1537,7 @@ PopulateTableCommand::PopulateTableCommand( const TQString &n, FormWindow *fw, T
void PopulateTableCommand::execute()
{
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
TQMap<TQString, TQString> columnFields;
table->setNumCols( newColumns.count() );
int i = 0;
@@ -1546,7 +1546,7 @@ void PopulateTableCommand::execute()
if ( !(*cit).field.isEmpty() )
columnFields.insert( (*cit).text, (*cit).field );
}
- MetaDataBase::setColumnFields( table, columnFields );
+ MetaDataBase::setColumnFields( TQT_TQOBJECT(table), columnFields );
table->setNumRows( newRows.count() );
i = 0;
for ( TQValueList<Row>::Iterator rit = newRows.begin(); rit != newRows.end(); ++rit, ++i )
@@ -1556,7 +1556,7 @@ void PopulateTableCommand::execute()
void PopulateTableCommand::unexecute()
{
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
TQMap<TQString, TQString> columnFields;
table->setNumCols( oldColumns.count() );
int i = 0;
@@ -1565,7 +1565,7 @@ void PopulateTableCommand::unexecute()
if ( !(*cit).field.isEmpty() )
columnFields.insert( (*cit).text, (*cit).field );
}
- MetaDataBase::setColumnFields( table, columnFields );
+ MetaDataBase::setColumnFields( TQT_TQOBJECT(table), columnFields );
table->setNumRows( oldRows.count() );
i = 0;
for ( TQValueList<Row>::Iterator rit = oldRows.begin(); rit != oldRows.end(); ++rit, ++i )
@@ -1576,7 +1576,7 @@ void PopulateTableCommand::unexecute()
// ------------------------------------------------------------
AddActionToToolBarCommand::AddActionToToolBarCommand( const TQString &n, FormWindow *fw,
- TQAction *a, QDesignerToolBar *tb, int idx )
+ TQAction *a, TQDesignerToolBar *tb, int idx )
: Command( n, fw ), action( a ), toolBar( tb ), index( idx )
{
}
@@ -1585,25 +1585,25 @@ void AddActionToToolBarCommand::execute()
{
action->addTo( toolBar );
- if ( action->inherits( "QDesignerAction" ) ) {
- TQString s = ( (QDesignerAction*)action )->widget()->name();
+ if ( action->inherits( "TQDesignerAction" ) ) {
+ TQString s = ( (TQDesignerAction*)action )->widget()->name();
if ( s.startsWith( "qt_dead_widget_" ) ) {
s.remove( 0, TQString( "qt_dead_widget_" ).length() );
- ( (QDesignerAction*)action )->widget()->setName( s );
+ ( (TQDesignerAction*)action )->widget()->setName( s );
}
}
- if ( action->inherits( "QDesignerAction" ) ) {
- toolBar->insertAction( ( (QDesignerAction*)action )->widget(), action );
- ( (QDesignerAction*)action )->widget()->installEventFilter( toolBar );
- } else if ( action->inherits( "QDesignerActionGroup" ) ) {
- if ( ( (QDesignerActionGroup*)action )->usesDropDown() ) {
- toolBar->insertAction( ( (QDesignerActionGroup*)action )->widget(), action );
- ( (QDesignerActionGroup*)action )->widget()->installEventFilter( toolBar );
+ if ( action->inherits( "TQDesignerAction" ) ) {
+ toolBar->insertAction( ( (TQDesignerAction*)action )->widget(), action );
+ ( (TQDesignerAction*)action )->widget()->installEventFilter( toolBar );
+ } else if ( action->inherits( "TQDesignerActionGroup" ) ) {
+ if ( ( (TQDesignerActionGroup*)action )->usesDropDown() ) {
+ toolBar->insertAction( ( (TQDesignerActionGroup*)action )->widget(), action );
+ ( (TQDesignerActionGroup*)action )->widget()->installEventFilter( toolBar );
}
- } else if ( action->inherits( "QSeparatorAction" ) ) {
- toolBar->insertAction( ( (QSeparatorAction*)action )->widget(), action );
- ( (QSeparatorAction*)action )->widget()->installEventFilter( toolBar );
+ } else if ( action->inherits( "TQSeparatorAction" ) ) {
+ toolBar->insertAction( ( (TQSeparatorAction*)action )->widget(), action );
+ ( (TQSeparatorAction*)action )->widget()->installEventFilter( toolBar );
}
if ( !action->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) || ( (TQActionGroup*)action )->usesDropDown()) {
if ( index == -1 )
@@ -1613,8 +1613,9 @@ void AddActionToToolBarCommand::execute()
toolBar->reInsert();
TQObject::connect( action, TQT_SIGNAL( destroyed() ), toolBar, TQT_SLOT( actionRemoved() ) );
} else {
- TQObjectListIt it( *action->children() );
- if ( action->children() ) {
+ TQObjectList clo = action->childrenListObject();
+ if (!clo.isEmpty()) {
+ TQObjectListIt it( clo );
int i = 0;
while ( it.current() ) {
TQObject *o = it.current();
@@ -1622,8 +1623,8 @@ void AddActionToToolBarCommand::execute()
if ( !o->inherits( TQACTION_OBJECT_NAME_STRING ) )
continue;
// ### fix it for nested actiongroups
- if ( o->inherits( "QDesignerAction" ) ) {
- QDesignerAction *ac = (QDesignerAction*)o;
+ if ( o->inherits( "TQDesignerAction" ) ) {
+ TQDesignerAction *ac = (TQDesignerAction*)o;
toolBar->insertAction( ac->widget(), ac );
ac->widget()->installEventFilter( toolBar );
if ( index == -1 )
@@ -1640,10 +1641,10 @@ void AddActionToToolBarCommand::execute()
void AddActionToToolBarCommand::unexecute()
{
- if ( action->inherits( "QDesignerAction" ) ) {
- TQString s = ( (QDesignerAction*)action )->widget()->name();
+ if ( action->inherits( "TQDesignerAction" ) ) {
+ TQString s = ( (TQDesignerAction*)action )->widget()->name();
s.prepend( "qt_dead_widget_" );
- ( (QDesignerAction*)action )->widget()->setName( s );
+ ( (TQDesignerAction*)action )->widget()->setName( s );
}
toolBar->removeAction( action );
@@ -1652,14 +1653,15 @@ void AddActionToToolBarCommand::unexecute()
if ( !action->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) || ( (TQActionGroup*)action )->usesDropDown()) {
action->removeEventFilter( toolBar );
} else {
- if ( action->children() ) {
- TQObjectListIt it( *action->children() );
+ TQObjectList clo = action->childrenListObject();
+ if ( !clo.isEmpty() ) {
+ TQObjectListIt it( clo );
while ( it.current() ) {
TQObject *o = it.current();
++it;
if ( !o->inherits( TQACTION_OBJECT_NAME_STRING ) )
continue;
- if ( o->inherits( "QDesignerAction" ) ) {
+ if ( o->inherits( "TQDesignerAction" ) ) {
o->removeEventFilter( toolBar );
toolBar->removeAction( (TQAction*)o );
}
@@ -1671,7 +1673,7 @@ void AddActionToToolBarCommand::unexecute()
// ------------------------------------------------------------
AddActionToPopupCommand::AddActionToPopupCommand( const TQString &n, FormWindow *fw,
- TQAction *a, QDesignerPopupMenu *p, int idx )
+ TQAction *a, TQDesignerPopupMenu *p, int idx )
: Command( n, fw ), action( a ), popup( p ), index( idx )
{
}
@@ -1684,15 +1686,16 @@ void AddActionToPopupCommand::execute()
popup->insertAction( index, action );
} else {
action->addTo( popup );
- if ( action->children() ) {
- TQObjectListIt it( *action->children() );
+ TQObjectList clo = action->childrenListObject();
+ if ( !clo.isEmpty() ) {
+ TQObjectListIt it( clo );
int i = 0;
while ( it.current() ) {
TQObject *o = it.current();
++it;
if ( !o->inherits( TQACTION_OBJECT_NAME_STRING ) )
continue;
- QDesignerAction *ac = (QDesignerAction*)o;
+ TQDesignerAction *ac = (TQDesignerAction*)o;
popup->insertAction( index + (i++), ac );
}
}
@@ -1700,7 +1703,7 @@ void AddActionToPopupCommand::execute()
popup->reInsert();
TQObject::connect( action, TQT_SIGNAL( destroyed() ), popup, TQT_SLOT( actionRemoved() ) );
} else {
- if ( !action->inherits( "QDesignerAction" ) || ( (QDesignerAction*)action )->supportsMenu() ) {
+ if ( !action->inherits( "TQDesignerAction" ) || ( (TQDesignerAction*)action )->supportsMenu() ) {
action->addTo( popup );
popup->insertAction( index, action );
popup->reInsert();
@@ -1717,14 +1720,15 @@ void AddActionToPopupCommand::unexecute()
if ( !action->inherits( TQACTIONGROUP_OBJECT_NAME_STRING ) || ( (TQActionGroup*)action )->usesDropDown()) {
action->removeEventFilter( popup );
} else {
- if ( action->children() ) {
- TQObjectListIt it( *action->children() );
+ TQObjectList clo = action->childrenListObject();
+ if ( !clo.isEmpty() ) {
+ TQObjectListIt it( clo );
while ( it.current() ) {
TQObject *o = it.current();
++it;
if ( !o->inherits( TQACTION_OBJECT_NAME_STRING ) )
continue;
- if ( o->inherits( "QDesignerAction" ) ) {
+ if ( o->inherits( "TQDesignerAction" ) ) {
o->removeEventFilter( popup );
popup->removeAction( (TQAction*)o );
}
@@ -1744,21 +1748,21 @@ void AddMenuCommand::execute()
{
if ( !popup ) {
TQString n = "PopupMenu";
- popup = new QDesignerPopupMenu( mainWindow );
- formWindow()->unify( popup, n, true );
+ popup = new TQDesignerPopupMenu( mainWindow );
+ formWindow()->unify( TQT_TQOBJECT(popup), n, true );
popup->setName( n );
}
if ( !mainWindow->child( 0, TQMENUBAR_OBJECT_NAME_STRING ) ) {
- menuBar = new QDesignerMenuBar( (TQWidget*)mainWindow );
+ menuBar = new TQDesignerMenuBar( (TQWidget*)mainWindow );
menuBar->setName( "menubar" );
} else {
- menuBar = (QDesignerMenuBar*)mainWindow->menuBar();
+ menuBar = (TQDesignerMenuBar*)mainWindow->menuBar();
}
if ( id == -1 )
id = mainWindow->menuBar()->insertItem( name, popup );
else
id = mainWindow->menuBar()->insertItem( name, popup, id, index );
- formWindow()->killAccels( formWindow() );
+ formWindow()->killAccels( TQT_TQOBJECT(formWindow()) );
}
void AddMenuCommand::unexecute()
@@ -1766,12 +1770,12 @@ void AddMenuCommand::unexecute()
if ( !popup || !menuBar )
return;
menuBar->removeItem( id );
- formWindow()->killAccels( formWindow() );
+ formWindow()->killAccels( TQT_TQOBJECT(formWindow()) );
}
// ------------------------------------------------------------
-RenameMenuCommand::RenameMenuCommand( const TQString &n, FormWindow *fw, QDesignerMenuBar *mb,
+RenameMenuCommand::RenameMenuCommand( const TQString &n, FormWindow *fw, TQDesignerMenuBar *mb,
int i, const TQString &on, const TQString &nn )
: Command( n, fw ), menuBar( mb ), id( i ), oldName( on ), newName( nn )
{
@@ -1780,19 +1784,19 @@ RenameMenuCommand::RenameMenuCommand( const TQString &n, FormWindow *fw, QDesign
void RenameMenuCommand::execute()
{
menuBar->changeItem( id, newName );
- formWindow()->killAccels( formWindow() );
+ formWindow()->killAccels( TQT_TQOBJECT(formWindow()) );
}
void RenameMenuCommand::unexecute()
{
menuBar->changeItem( id, oldName );
- formWindow()->killAccels( formWindow() );
+ formWindow()->killAccels( TQT_TQOBJECT(formWindow()) );
}
// ------------------------------------------------------------
-MoveMenuCommand::MoveMenuCommand( const TQString &n, FormWindow *fw, QDesignerMenuBar *mb,
- QDesignerPopupMenu *p, int fidx, int tidx, const TQString &txt )
+MoveMenuCommand::MoveMenuCommand( const TQString &n, FormWindow *fw, TQDesignerMenuBar *mb,
+ TQDesignerPopupMenu *p, int fidx, int tidx, const TQString &txt )
: Command( n, fw ), menuBar( mb ), popup( p ), fromIdx( fidx ), toIdx( tidx ), text( txt )
{
}
@@ -1801,14 +1805,14 @@ void MoveMenuCommand::execute()
{
menuBar->removeItem( menuBar->idAt( fromIdx ) );
menuBar->insertItem( text, popup, -1, toIdx );
- formWindow()->killAccels( formWindow() );
+ formWindow()->killAccels( TQT_TQOBJECT(formWindow()) );
}
void MoveMenuCommand::unexecute()
{
menuBar->removeItem( menuBar->idAt( toIdx ) );
menuBar->insertItem( text, popup, -1, fromIdx );
- formWindow()->killAccels( formWindow() );
+ formWindow()->killAccels( TQT_TQOBJECT(formWindow()) );
}
// ------------------------------------------------------------
@@ -1821,9 +1825,9 @@ AddToolBarCommand::AddToolBarCommand( const TQString &n, FormWindow *fw, TQMainW
void AddToolBarCommand::execute()
{
if ( !toolBar ) {
- toolBar = new QDesignerToolBar( mainWindow );
+ toolBar = new TQDesignerToolBar( mainWindow );
TQString n = "Toolbar";
- formWindow()->unify( toolBar, n, true );
+ formWindow()->unify( TQT_TQOBJECT(toolBar), n, true );
toolBar->setName( n );
mainWindow->addToolBar( toolBar, n );
} else {
diff --git a/kommander/editor/command.h b/kommander/editor/command.h
index a2162dca..3fd83e1c 100644
--- a/kommander/editor/command.h
+++ b/kommander/editor/command.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -44,13 +44,13 @@ class TQIconView;
class TQMultiLineEdit;
class TQTable;
class TQAction;
-class QDesignerToolBar;
+class TQDesignerToolBar;
class TQMainWindow;
-class QDesignerPopupMenu;
-class QDesignerMenuBar;
+class TQDesignerPopupMenu;
+class TQDesignerMenuBar;
class TQToolBox;
-class Command : public Qt
+class Command : public TQt
{
public:
Command( const TQString &n, FormWindow *fw );
@@ -120,9 +120,10 @@ private:
};
-class CommandHistory : public QObject
+class CommandHistory : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
CommandHistory( int s );
@@ -180,7 +181,7 @@ public:
private:
TQWidget *widget;
- TQRect geometry;
+ TQRect tqgeometry;
};
@@ -254,7 +255,7 @@ class LayoutHorizontalCommand : public Command
{
public:
LayoutHorizontalCommand( const TQString &n, FormWindow *fw,
- TQWidget *parent, TQWidget *layoutBase,
+ TQWidget *tqparent, TQWidget *tqlayoutBase,
const TQWidgetList &wl );
void execute();
@@ -262,7 +263,7 @@ public:
Type type() const { return LayoutHorizontal; }
private:
- HorizontalLayout layout;
+ HorizontalLayout tqlayout;
};
@@ -270,7 +271,7 @@ class LayoutHorizontalSplitCommand : public Command
{
public:
LayoutHorizontalSplitCommand( const TQString &n, FormWindow *fw,
- TQWidget *parent, TQWidget *layoutBase,
+ TQWidget *tqparent, TQWidget *tqlayoutBase,
const TQWidgetList &wl );
void execute();
@@ -278,7 +279,7 @@ public:
Type type() const { return LayoutHorizontalSplitter; }
private:
- HorizontalLayout layout;
+ HorizontalLayout tqlayout;
};
@@ -286,7 +287,7 @@ class LayoutVerticalCommand : public Command
{
public:
LayoutVerticalCommand( const TQString &n, FormWindow *fw,
- TQWidget *parent, TQWidget *layoutBase,
+ TQWidget *tqparent, TQWidget *tqlayoutBase,
const TQWidgetList &wl );
void execute();
@@ -294,7 +295,7 @@ public:
Type type() const { return LayoutVertical; }
private:
- VerticalLayout layout;
+ VerticalLayout tqlayout;
};
@@ -302,7 +303,7 @@ class LayoutVerticalSplitCommand : public Command
{
public:
LayoutVerticalSplitCommand( const TQString &n, FormWindow *fw,
- TQWidget *parent, TQWidget *layoutBase,
+ TQWidget *tqparent, TQWidget *tqlayoutBase,
const TQWidgetList &wl );
void execute();
@@ -310,7 +311,7 @@ public:
Type type() const { return LayoutVerticalSplitter; }
private:
- VerticalLayout layout;
+ VerticalLayout tqlayout;
};
@@ -318,7 +319,7 @@ class LayoutGridCommand : public Command
{
public:
LayoutGridCommand( const TQString &n, FormWindow *fw,
- TQWidget *parent, TQWidget *layoutBase,
+ TQWidget *tqparent, TQWidget *tqlayoutBase,
const TQWidgetList &wl, int xres, int yres );
void execute();
@@ -326,7 +327,7 @@ public:
Type type() const { return LayoutGrid; }
private:
- GridLayout layout;
+ GridLayout tqlayout;
};
@@ -334,14 +335,14 @@ class BreakLayoutCommand : public Command
{
public:
BreakLayoutCommand( const TQString &n, FormWindow *fw,
- TQWidget *layoutBase, const TQWidgetList &wl );
+ TQWidget *tqlayoutBase, const TQWidgetList &wl );
void execute();
void unexecute();
Type type() const { return BreakLayout; }
private:
- Layout *layout;
+ Layout *tqlayout;
int spacing;
int margin;
TQWidget *lb;
@@ -658,7 +659,7 @@ public:
{
TQString text;
TQPixmap pix;
-#if defined(Q_FULL_TEMPLATE_INSTANTIATION)
+#if defined(TQ_FULL_TEMPLATE_INSTANTIATION)
bool operator==( const Item & ) const { return FALSE; }
#endif
};
@@ -684,7 +685,7 @@ public:
{
TQString text;
TQPixmap pix;
-#if defined(Q_FULL_TEMPLATE_INSTANTIATION)
+#if defined(TQ_FULL_TEMPLATE_INSTANTIATION)
bool operator==( const Item & ) const { return FALSE; }
#endif
};
@@ -744,7 +745,7 @@ public:
{
TQString text;
TQPixmap pix;
-#if defined(Q_FULL_TEMPLATE_INSTANTIATION)
+#if defined(TQ_FULL_TEMPLATE_INSTANTIATION)
bool operator==( const Row& ) const { return FALSE; }
#endif
};
@@ -754,7 +755,7 @@ public:
TQString text;
TQPixmap pix;
TQString field;
-#if defined(Q_FULL_TEMPLATE_INSTANTIATION)
+#if defined(TQ_FULL_TEMPLATE_INSTANTIATION)
bool operator==( const Column& ) const { return FALSE; }
#endif
};
@@ -778,7 +779,7 @@ class AddActionToToolBarCommand : public Command
{
public:
AddActionToToolBarCommand( const TQString &n, FormWindow *fw,
- TQAction *a, QDesignerToolBar *tb, int idx );
+ TQAction *a, TQDesignerToolBar *tb, int idx );
void execute();
void unexecute();
@@ -786,7 +787,7 @@ public:
private:
TQAction *action;
- QDesignerToolBar *toolBar;
+ TQDesignerToolBar *toolBar;
int index;
};
@@ -795,7 +796,7 @@ class RemoveActionFromToolBarCommand : public AddActionToToolBarCommand
{
public:
RemoveActionFromToolBarCommand( const TQString &n, FormWindow *fw,
- TQAction *a, QDesignerToolBar *tb, int idx )
+ TQAction *a, TQDesignerToolBar *tb, int idx )
: AddActionToToolBarCommand( n, fw, a, tb, idx ) {}
void execute() { AddActionToToolBarCommand::unexecute(); }
@@ -808,7 +809,7 @@ class AddActionToPopupCommand : public Command
{
public:
AddActionToPopupCommand( const TQString &n, FormWindow *fw,
- TQAction *a, QDesignerPopupMenu *p, int idx );
+ TQAction *a, TQDesignerPopupMenu *p, int idx );
void execute();
void unexecute();
@@ -816,7 +817,7 @@ public:
private:
TQAction *action;
- QDesignerPopupMenu *popup;
+ TQDesignerPopupMenu *popup;
int index;
};
@@ -825,7 +826,7 @@ class RemoveActionFromPopupCommand : public AddActionToPopupCommand
{
public:
RemoveActionFromPopupCommand( const TQString &n, FormWindow *fw,
- TQAction *a, QDesignerPopupMenu *p, int idx )
+ TQAction *a, TQDesignerPopupMenu *p, int idx )
: AddActionToPopupCommand( n, fw, a, p, idx ) {}
void execute() { AddActionToPopupCommand::unexecute(); }
@@ -844,8 +845,8 @@ public:
Type type() const { return AddMenu; }
protected:
- QDesignerMenuBar *menuBar;
- QDesignerPopupMenu *popup;
+ TQDesignerMenuBar *menuBar;
+ TQDesignerPopupMenu *popup;
TQMainWindow *mainWindow;
int id;
int index;
@@ -857,7 +858,7 @@ class RemoveMenuCommand : public AddMenuCommand
{
public:
RemoveMenuCommand( const TQString &n, FormWindow *fw, TQMainWindow *mw,
- QDesignerMenuBar *mb, QDesignerPopupMenu *p, int i, int idx, const TQString &mn )
+ TQDesignerMenuBar *mb, TQDesignerPopupMenu *p, int i, int idx, const TQString &mn )
: AddMenuCommand( n, fw, mw ) { menuBar = mb; popup = p; id = i; index = idx, name = mn; }
void execute() { AddMenuCommand::unexecute(); }
@@ -869,7 +870,7 @@ public:
class RenameMenuCommand : public Command
{
public:
- RenameMenuCommand( const TQString &n, FormWindow *fw, QDesignerMenuBar *mb,
+ RenameMenuCommand( const TQString &n, FormWindow *fw, TQDesignerMenuBar *mb,
int i, const TQString &on, const TQString &nn );
void execute();
@@ -877,7 +878,7 @@ public:
Type type() const { return RenameMenu; }
private:
- QDesignerMenuBar *menuBar;
+ TQDesignerMenuBar *menuBar;
int id;
TQString oldName, newName;
@@ -886,16 +887,16 @@ private:
class MoveMenuCommand : public Command
{
public:
- MoveMenuCommand( const TQString &n, FormWindow *fw, QDesignerMenuBar *mb,
- QDesignerPopupMenu *p, int fidx, int tidx, const TQString &txt );
+ MoveMenuCommand( const TQString &n, FormWindow *fw, TQDesignerMenuBar *mb,
+ TQDesignerPopupMenu *p, int fidx, int tidx, const TQString &txt );
void execute();
void unexecute();
Type type() const { return MoveMenu; }
private:
- QDesignerMenuBar *menuBar;
- QDesignerPopupMenu *popup;
+ TQDesignerMenuBar *menuBar;
+ TQDesignerPopupMenu *popup;
int fromIdx, toIdx;
TQString text;
@@ -911,7 +912,7 @@ public:
Type type() const { return AddToolBar; }
protected:
- QDesignerToolBar *toolBar;
+ TQDesignerToolBar *toolBar;
TQMainWindow *mainWindow;
};
@@ -919,7 +920,7 @@ protected:
class RemoveToolBarCommand : public AddToolBarCommand
{
public:
- RemoveToolBarCommand( const TQString &n, FormWindow *fw, TQMainWindow *mw, QDesignerToolBar *tb )
+ RemoveToolBarCommand( const TQString &n, FormWindow *fw, TQMainWindow *mw, TQDesignerToolBar *tb )
: AddToolBarCommand( n, fw, mw ) { toolBar = tb; }
void execute() { AddToolBarCommand::unexecute(); }
diff --git a/kommander/editor/connectioneditor.ui b/kommander/editor/connectioneditor.ui
index d9e5a161..5eed9c1e 100644
--- a/kommander/editor/connectioneditor.ui
+++ b/kommander/editor/connectioneditor.ui
@@ -19,7 +19,7 @@
** not clear to you.
**
*********************************************************************</comment>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>ConnectionEditorBase</cstring>
</property>
@@ -116,7 +116,7 @@
<cstring>slotBox</cstring>
</property>
<property name="whatsThis" stdset="0">
- <string>&lt;b&gt;A list of slots for the receiver.&lt;/b&gt;&lt;p&gt;The slots that are displayed are only those which have arguments that correspond with the arguments of the signal that is currently selected in the Signal-list.&lt;/b&gt;</string>
+ <string>&lt;b&gt;A list of Q_SLOTS for the receiver.&lt;/b&gt;&lt;p&gt;The Q_SLOTS that are displayed are only those which have arguments that correspond with the arguments of the signal that is currently selected in the Signal-list.&lt;/b&gt;</string>
</property>
</widget>
<widget class="KListBox" row="1" column="0">
@@ -124,18 +124,18 @@
<cstring>signalBox</cstring>
</property>
<property name="whatsThis" stdset="0">
- <string>Displays the list of signals that the widget emits.</string>
+ <string>Displays the list of Q_SIGNALS that the widget emits.</string>
</property>
</widget>
- <widget class="QLayoutWidget" row="0" column="0">
+ <widget class="TQLayoutWidget" row="0" column="0">
<property name="name">
- <cstring>layout3</cstring>
+ <cstring>tqlayout3</cstring>
</property>
<hbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>labelSignal</cstring>
</property>
@@ -161,7 +161,7 @@
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget" row="0" column="1">
+ <widget class="TQLayoutWidget" row="0" column="1">
<property name="name">
<cstring>Layout3</cstring>
</property>
@@ -175,7 +175,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>labelSlot</cstring>
</property>
@@ -201,9 +201,9 @@
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget" row="4" column="0" rowspan="1" colspan="2">
+ <widget class="TQLayoutWidget" row="4" column="0" rowspan="1" colspan="2">
<property name="name">
- <cstring>layout7</cstring>
+ <cstring>tqlayout7</cstring>
</property>
<hbox>
<property name="name">
@@ -239,7 +239,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>71</width>
<height>21</height>
@@ -293,7 +293,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>230</width>
<height>20</height>
@@ -302,15 +302,15 @@
</spacer>
</hbox>
</widget>
- <widget class="QLayoutWidget" row="2" column="0" rowspan="1" colspan="2">
+ <widget class="TQLayoutWidget" row="2" column="0" rowspan="1" colspan="2">
<property name="name">
- <cstring>layout8</cstring>
+ <cstring>tqlayout8</cstring>
</property>
<hbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -331,7 +331,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>231</width>
<height>20</height>
@@ -368,7 +368,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>211</width>
<height>20</height>
@@ -390,7 +390,7 @@
<tabstop>okButton</tabstop>
<tabstop>cancelButton</tabstop>
</tabstops>
-<slots>
+<Q_SLOTS>
<slot access="protected">init()</slot>
<slot access="protected">destroy()</slot>
<slot>addSlotClicked()</slot>
@@ -400,10 +400,10 @@
<slot access="protected">receiverChanged( const QString &amp; )</slot>
<slot access="protected">okClicked()</slot>
<slot access="protected">signalChanged()</slot>
- <slot access="protected">slotsChanged()</slot>
+ <slot access="protected">Q_SLOTSChanged()</slot>
<slot access="protected">cancelClicked()</slot>
-</slots>
-<layoutdefaults spacing="6" margin="11"/>
+</Q_SLOTS>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>klistview.h</includehint>
<includehint>klistbox.h</includehint>
diff --git a/kommander/editor/connectioneditorimpl.cpp b/kommander/editor/connectioneditorimpl.cpp
index a430290e..e6a48fde 100644
--- a/kommander/editor/connectioneditorimpl.cpp
+++ b/kommander/editor/connectioneditorimpl.cpp
@@ -1,5 +1,5 @@
/**********************************************************************
- This file is based on Qt Designer, Copyright (C) 2000 Trolltech AS. All rights reserved.
+ This file is based on TQt Designer, Copyright (C) 2000 Trolltech AS. All rights reserved.
This file may be distributed and/or modified under the terms of the
GNU General Public License version 2 as published by the Free Software
@@ -44,14 +44,14 @@ static const char *const ignore_slots[] = {
"update()",
"update(int,int,int,int)",
"update(const TQRect&)",
- "repaint()",
- "repaint(bool)",
- "repaint(int,int,int,int,bool)",
- "repaint(const TQRect&,bool)",
- "repaint(const TQRegion&,bool)",
- "repaint(int,int,int,int)",
- "repaint(const TQRect&)",
- "repaint(const TQRegion&)",
+ "tqrepaint()",
+ "tqrepaint(bool)",
+ "tqrepaint(int,int,int,int,bool)",
+ "tqrepaint(const TQRect&,bool)",
+ "tqrepaint(const TQRegion&,bool)",
+ "tqrepaint(int,int,int,int)",
+ "tqrepaint(const TQRect&)",
+ "tqrepaint(const TQRegion&)",
//"show()",
//"hide()",
"iconify()",
@@ -89,13 +89,13 @@ static const char *const ignore_signals[] = {
};
-ConnectionEditor::ConnectionEditor(TQWidget* parent, TQObject* sndr, TQObject* rcvr, FormWindow* fw)
- : ConnectionEditorBase(parent, 0, true), m_formWindow(fw)
+ConnectionEditor::ConnectionEditor(TQWidget* tqparent, TQObject* sndr, TQObject* rcvr, FormWindow* fw)
+ : ConnectionEditorBase(tqparent, 0, true), m_formWindow(fw)
{
- if (!rcvr || rcvr == m_formWindow)
- rcvr = m_formWindow->mainContainer();
- if (!sndr || sndr == m_formWindow)
- sndr = m_formWindow->mainContainer();
+ if (!rcvr || TQT_BASE_OBJECT(rcvr) == TQT_BASE_OBJECT(m_formWindow))
+ rcvr = TQT_TQOBJECT(m_formWindow->mainContainer());
+ if (!sndr || TQT_BASE_OBJECT(sndr) == TQT_BASE_OBJECT(m_formWindow))
+ sndr = TQT_TQOBJECT(m_formWindow->mainContainer());
m_sender = sndr;
m_receiver = rcvr;
@@ -105,11 +105,11 @@ ConnectionEditor::ConnectionEditor(TQWidget* parent, TQObject* sndr, TQObject* r
for (TQPtrDictIterator<TQWidget> it(*m_formWindow->widgets()); it.current(); ++it)
{
if (it.current()->isVisibleTo(this) &&
- !it.current()->inherits("QLayoutWidget") &&
+ !it.current()->inherits(TQLAYOUTWIDGET_OBJECT_NAME_STRING) &&
!it.current()->inherits("Spacer") &&
qstrcmp(it.current()->name(), "central widget") &&
- !m_formWindow->isMainContainer(it.current()) &&
- !lst.contains(it.current()->name()))
+ !m_formWindow->isMainContainer(TQT_TQOBJECT(it.current())) &&
+ !lst.tqcontains(it.current()->name()))
lst << it.current()->name();
}
@@ -152,21 +152,21 @@ bool ConnectionEditor::isSignalIgnored(const char *signal) const
return false;
}
-bool ConnectionEditor::isSlotIgnored(const QMetaData* md)
+bool ConnectionEditor::isSlotIgnored(const TQMetaData* md)
{
- if (md->access != QMetaData::Public && (md->access != QMetaData::Protected ||
- !m_formWindow->isMainContainer((TQWidget*)m_receiver)))
+ if (md->tqt_mo_access != TQMetaData::Public && (md->tqt_mo_access != TQMetaData::Protected ||
+ !m_formWindow->isMainContainer(TQT_TQOBJECT(m_receiver))))
return true;
for (int i = 0; ignore_slots[i]; i++)
- if (!qstrcmp(md->name, ignore_slots[i]))
+ if (!qstrcmp(md->tqt_mo_ci_name, ignore_slots[i]))
return true;
- if (!m_formWindow->isMainContainer((TQWidget *)m_receiver) && !qstrcmp(md->name, "close()"))
+ if (!m_formWindow->isMainContainer(TQT_TQOBJECT(m_receiver)) && !qstrcmp(md->tqt_mo_ci_name, "close()"))
return true;
- if (!qstrcmp(md->name, "setFocus()") && m_receiver->isWidgetType() &&
- ((TQWidget*)m_receiver)->focusPolicy() == TQWidget::NoFocus)
+ if (!qstrcmp(md->tqt_mo_ci_name, "setFocus()") && m_receiver->isWidgetType() &&
+ ((TQWidget*)m_receiver)->focusPolicy() == TQ_NoFocus)
return true;
for (int i = 0; i<comboSender->count(); i++)
- if (checkConnectArgs(MetaDataBase::normalizeSlot(signalBox->text(i)).latin1(), m_receiver, md->name))
+ if (checkConnectArgs(MetaDataBase::normalizeSlot(signalBox->text(i)).latin1(), m_receiver, md->tqt_mo_ci_name))
return false;
return true;
}
@@ -175,11 +175,11 @@ TQObject* ConnectionEditor::objectByName(const TQString& s) const
{
for (TQPtrDictIterator <TQWidget> it(*m_formWindow->widgets()); it.current(); ++it)
if (TQString(it.current()->name()) == s)
- return it.current();
+ return TQT_TQOBJECT(it.current());
for (TQPtrListIterator<TQAction> it(m_formWindow->actionList()); it.current(); ++it)
if (TQString(it.current()->name()) == s)
- return it.current();
+ return TQT_TQOBJECT(it.current());
return 0;
}
@@ -213,7 +213,7 @@ void ConnectionEditor::disconnectClicked()
if (!p_item)
return;
- TQMap <TQListViewItem*, MetaDataBase::Connection>::Iterator it = m_connections.find(p_item);
+ TQMap <TQListViewItem*, MetaDataBase::Connection>::Iterator it = m_connections.tqfind(p_item);
if (it != m_connections.end())
m_connections.remove(it);
delete p_item;
@@ -226,7 +226,7 @@ void ConnectionEditor::disconnectClicked()
void ConnectionEditor::okClicked()
{
MacroCommand* rmConn = 0, *addConn = 0;
- TQString n = i18n("Connect/Disconnect the signals and slots of '%1' and '%2'").arg(m_sender->name()).
+ TQString n = i18n("Connect/Disconnect the signals and slots of '%1' and '%2'").tqarg(m_sender->name()).
arg(m_receiver->name());
TQValueList <MetaDataBase::Connection>::Iterator cit;
if (!m_oldConnections.isEmpty())
@@ -274,13 +274,13 @@ void ConnectionEditor::senderChanged(const TQString& s)
if (!p_object)
return;
m_sender = p_object;
- TQStrList p_sigs = m_sender->metaObject()->signalNames(true);
+ TQStrList p_sigs = m_sender->tqmetaObject()->signalNames(true);
signalBox->clear();
for (TQStrListIterator it(p_sigs); it.current(); ++it)
- if (!isSignalIgnored(it.current()) && !signalBox->findItem(it.current(), Qt::ExactMatch))
+ if (!isSignalIgnored(it.current()) && !signalBox->tqfindItem(it.current(), TQt::ExactMatch))
signalBox->insertItem(it.current());
- if (m_sender == m_formWindow->mainContainer())
- signalBox->insertStringList(MetaDataBase::signalList(m_formWindow));
+ if (TQT_BASE_OBJECT(m_sender) == TQT_BASE_OBJECT(m_formWindow->mainContainer()))
+ signalBox->insertStringList(MetaDataBase::signalList(TQT_TQOBJECT(m_formWindow)));
signalBox->sort();
signalBox->setCurrentItem(signalBox->firstItem());
// Update slots - some may (not) have their signal equivalents now.
@@ -293,13 +293,13 @@ void ConnectionEditor::receiverChanged(const TQString& s)
if (!p_object)
return;
m_receiver = p_object;
- int n = m_receiver->metaObject()->numSlots(true);
+ int n = m_receiver->tqmetaObject()->numSlots(true);
slotBox->clear();
for (int i = 0; i < n; ++i)
{
- const QMetaData* md = m_receiver->metaObject()->slot(i, true);
- if (!isSlotIgnored(md) && !slotBox->findItem(md->name, Qt::ExactMatch))
- slotBox->insertItem(md->name);
+ const TQMetaData* md = m_receiver->tqmetaObject()->slot(i, true);
+ if (!isSlotIgnored(md) && !slotBox->tqfindItem(md->tqt_mo_ci_name, TQt::ExactMatch))
+ slotBox->insertItem(md->tqt_mo_ci_name);
}
slotBox->sort();
slotBox->setCurrentItem(slotBox->firstItem());
@@ -336,14 +336,14 @@ void ConnectionEditor::fillConnectionsList()
{
connectionView->clear();
m_connections.clear();
- m_oldConnections = MetaDataBase::connections(m_formWindow);
+ m_oldConnections = MetaDataBase::connections(TQT_TQOBJECT(m_formWindow));
if (!m_oldConnections.isEmpty())
{
TQValueList <MetaDataBase::Connection>::Iterator it = m_oldConnections.begin();
for (; it != m_oldConnections.end(); ++it)
{
- if (m_formWindow->isMainContainer((TQWidget*)(*it).receiver) &&
- !MetaDataBase::hasSlot(m_formWindow, MetaDataBase::normalizeSlot((*it).slot).latin1()))
+ if (m_formWindow->isMainContainer(TQT_TQOBJECT((*it).receiver)) &&
+ !MetaDataBase::hasSlot(TQT_TQOBJECT(m_formWindow), MetaDataBase::normalizeSlot((*it).slot).latin1()))
continue;
MetaDataBase::Connection conn = *it;
KListViewItem *i = new KListViewItem(connectionView, conn.sender->name(), conn.signal,
diff --git a/kommander/editor/connectioneditorimpl.h b/kommander/editor/connectioneditorimpl.h
index 35a3445b..35e3f2e0 100644
--- a/kommander/editor/connectioneditorimpl.h
+++ b/kommander/editor/connectioneditorimpl.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -31,8 +31,10 @@ class FormWindow;
class ConnectionEditor : public ConnectionEditorBase
{
-Q_OBJECT public:
- ConnectionEditor(TQWidget* parent, TQObject* sender, TQObject* receiver, FormWindow* fw);
+ Q_OBJECT
+ TQ_OBJECT
+public:
+ ConnectionEditor(TQWidget* tqparent, TQObject* sender, TQObject* receiver, FormWindow* fw);
~ConnectionEditor();
protected slots:
@@ -61,7 +63,7 @@ private:
// Whether given signal should appear in the signal list
bool isSignalIgnored(const char*) const;
// Whether given slot should appear in the slot list
- bool isSlotIgnored(const QMetaData* md);
+ bool isSlotIgnored(const TQMetaData* md);
// Finds widget by name
TQObject* objectByName(const TQString& s) const;
bool hasConnection(const TQString & snder, const TQString & signal,
diff --git a/kommander/editor/createtemplate.ui b/kommander/editor/createtemplate.ui
index a6034d03..f97acfc6 100644
--- a/kommander/editor/createtemplate.ui
+++ b/kommander/editor/createtemplate.ui
@@ -19,13 +19,13 @@
**
*********************************************************************</comment>
<widget>
- <class>QDialog</class>
+ <class>TQDialog</class>
<property stdset="1">
<name>name</name>
<cstring>CreateTemplate</cstring>
</property>
<property stdset="1">
- <name>geometry</name>
+ <name>tqgeometry</name>
<rect>
<x>0</x>
<y>0</y>
@@ -51,7 +51,7 @@
<number>6</number>
</property>
<widget row="0" column="0" >
- <class>QLabel</class>
+ <class>TQLabel</class>
<property stdset="1">
<name>name</name>
<cstring>TextLabel1</cstring>
@@ -66,7 +66,7 @@
</property>
</widget>
<widget row="0" column="1" >
- <class>QLineEdit</class>
+ <class>TQLineEdit</class>
<property stdset="1">
<name>name</name>
<cstring>editName</cstring>
@@ -81,7 +81,7 @@
</property>
</widget>
<widget row="1" column="1" rowspan="2" colspan="1" >
- <class>QListBox</class>
+ <class>TQListBox</class>
<property stdset="1">
<name>name</name>
<cstring>listClass</cstring>
@@ -96,7 +96,7 @@
</property>
</widget>
<widget row="3" column="0" rowspan="1" colspan="2" >
- <class>QLayoutWidget</class>
+ <class>TQLayoutWidget</class>
<property stdset="1">
<name>name</name>
<cstring>Layout1</cstring>
@@ -124,7 +124,7 @@
<enum>Expanding</enum>
</property>
<property>
- <name>sizeHint</name>
+ <name>tqsizeHint</name>
<size>
<width>20</width>
<height>20</height>
@@ -132,7 +132,7 @@
</property>
</spacer>
<widget>
- <class>QPushButton</class>
+ <class>TQPushButton</class>
<property stdset="1">
<name>name</name>
<cstring>buttonCreate</cstring>
@@ -151,7 +151,7 @@
</property>
</widget>
<widget>
- <class>QPushButton</class>
+ <class>TQPushButton</class>
<property stdset="1">
<name>name</name>
<cstring>PushButton1</cstring>
@@ -168,7 +168,7 @@
</hbox>
</widget>
<widget row="1" column="0" >
- <class>QLabel</class>
+ <class>TQLabel</class>
<property stdset="1">
<name>name</name>
<cstring>TextLabel2</cstring>
@@ -196,7 +196,7 @@
<enum>Expanding</enum>
</property>
<property>
- <name>sizeHint</name>
+ <name>tqsizeHint</name>
<size>
<width>20</width>
<height>20</height>
diff --git a/kommander/editor/defs.cpp b/kommander/editor/defs.cpp
index 9f158b6d..d4e71303 100644
--- a/kommander/editor/defs.cpp
+++ b/kommander/editor/defs.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
diff --git a/kommander/editor/defs.h b/kommander/editor/defs.h
index 03cffd98..fcf4c305 100644
--- a/kommander/editor/defs.h
+++ b/kommander/editor/defs.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
diff --git a/kommander/editor/filechooser.cpp b/kommander/editor/filechooser.cpp
index dfb8575b..0133974a 100644
--- a/kommander/editor/filechooser.cpp
+++ b/kommander/editor/filechooser.cpp
@@ -4,21 +4,21 @@
#include <kfiledialog.h>
#include <tqlayout.h>
-FileChooser::FileChooser( TQWidget *parent, const char *name )
- : TQWidget( parent, name ), md( File )
+FileChooser::FileChooser( TQWidget *tqparent, const char *name )
+ : TQWidget( tqparent, name ), md( File )
{
- TQHBoxLayout *layout = new TQHBoxLayout( this );
- layout->setMargin( 0 );
+ TQHBoxLayout *tqlayout = new TQHBoxLayout( this );
+ tqlayout->setMargin( 0 );
lineEdit = new TQLineEdit( this, "filechooser_lineedit" );
- layout->addWidget( lineEdit );
+ tqlayout->addWidget( lineEdit );
connect( lineEdit, TQT_SIGNAL( textChanged( const TQString & ) ),
this, TQT_SIGNAL( fileNameChanged( const TQString & ) ) );
button = new TQPushButton( "...", this, "filechooser_button" );
button->setFixedWidth( button->fontMetrics().width( " ... " ) );
- layout->addWidget( button );
+ tqlayout->addWidget( button );
connect( button, TQT_SIGNAL( clicked() ),
this, TQT_SLOT( chooseFile() ) );
@@ -50,7 +50,7 @@ void FileChooser::chooseFile()
{
TQString fn;
if ( mode() == File )
- fn = KFileDialog::getOpenFileName( lineEdit->text(), TQString::null, this );
+ fn = KFileDialog::getOpenFileName( lineEdit->text(), TQString(), this );
else
fn = KFileDialog::getExistingDirectory( lineEdit->text(),this );
diff --git a/kommander/editor/filechooser.h b/kommander/editor/filechooser.h
index aa60518f..df518db6 100644
--- a/kommander/editor/filechooser.h
+++ b/kommander/editor/filechooser.h
@@ -6,16 +6,17 @@
class TQLineEdit;
class TQPushButton;
-class FileChooser : public QWidget
+class FileChooser : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
Q_ENUMS( Mode )
- Q_PROPERTY( Mode mode READ mode WRITE setMode )
- Q_PROPERTY( TQString fileName READ fileName WRITE setFileName )
+ TQ_PROPERTY( Mode mode READ mode WRITE setMode )
+ TQ_PROPERTY( TQString fileName READ fileName WRITE setFileName )
public:
- FileChooser( TQWidget *parent = 0, const char *name = 0);
+ FileChooser( TQWidget *tqparent = 0, const char *name = 0);
enum Mode { File, Directory };
diff --git a/kommander/editor/formfile.cpp b/kommander/editor/formfile.cpp
index 0f5ab63c..90b9ba18 100644
--- a/kommander/editor/formfile.cpp
+++ b/kommander/editor/formfile.cpp
@@ -1,5 +1,5 @@
/**********************************************************************
- This file is based on Qt Designer, Copyright (C) 2000 Trolltech AS. All rights reserved.
+ This file is based on TQt Designer, Copyright (C) 2000 Trolltech AS. All rights reserved.
This file may be distributed and/or modified under the terms of the
GNU General Public License version 2 as published by the Free Software
@@ -26,10 +26,10 @@
#include "resource.h"
#include "workspace.h"
-// Qt includes
+// TQt includes
#include <tqfile.h>
#include <tqregexp.h>
-#include <tqstatusbar.h>
+#include <statusbar.h>
#include <tqtimer.h>
// KDE includes
@@ -80,7 +80,7 @@ void FormFile::setFileName(const TQString &fn)
return;
if (fn.isEmpty()) {
fileNameTemp = true;
- if (filename.find("unnamed"))
+ if (filename.tqfind("unnamed"))
filename = createUnnamedFileName();
return;
}
@@ -119,12 +119,12 @@ bool FormFile::save(bool withMsgBox)
if (!resource.save(filename, false))
{
if (KMessageBox::questionYesNo(MainWindow::self, i18n("Failed to save file '%1'.\n"
- "Do you want to use another file name?").arg(filename), TQString::null, i18n("Try Another"), i18n("Do Not Try")) == KMessageBox::Yes)
+ "Do you want to use another file name?").tqarg(filename), TQString(), i18n("Try Another"), i18n("Do Not Try")) == KMessageBox::Yes)
return saveAs();
else
return false;
}
- MainWindow::self->statusBar()->message(i18n("'%1' saved.").arg(filename), 3000);
+ MainWindow::self->statusBar()->message(i18n("'%1' saved.").tqarg(filename), 3000);
::chmod(filename.local8Bit(), S_IRWXU);
setModified(false);
return true;
@@ -137,9 +137,9 @@ bool FormFile::saveAs()
f = TQString(formWindow()->name()).lower() + ".kmdr";
bool saved = false;
while (!saved) {
- TQString fn = KFileDialog::getSaveFileName(TQString::null,
+ TQString fn = KFileDialog::getSaveFileName(TQString(),
i18n("*.kmdr|Kommander Files"), MainWindow::self,
- i18n("Save Form '%1' As").arg(formWindow()->name()));
+ i18n("Save Form '%1' As").tqarg(formWindow()->name()));
if (fn.isEmpty())
return false;
TQFileInfo fi(fn);
@@ -182,7 +182,7 @@ bool FormFile::closeEvent()
}
switch (KMessageBox::warningYesNoCancel(MainWindow::self, i18n("Dialog '%1' was modified."
- "Do you want to save it?").arg(filename), i18n("Save File?"), KStdGuiItem::save(), KStdGuiItem::discard())) {
+ "Do you want to save it?").tqarg(filename), i18n("Save File?"), KStdGuiItem::save(), KStdGuiItem::discard())) {
case KMessageBox::Yes:
if (!save())
return false;
@@ -264,7 +264,7 @@ TQString FormFile::formName() const
line = ts.readLine();
if (!className.isEmpty())
{
- int end = line.find("</class>");
+ int end = line.tqfind("</class>");
if (end == -1)
className += line;
else
@@ -275,9 +275,9 @@ TQString FormFile::formName() const
continue;
}
int start;
- if ((start = line.find("<class>")) != -1)
+ if ((start = line.tqfind("<class>")) != -1)
{
- int end = line.find("</class>");
+ int end = line.tqfind("</class>");
if (end == -1)
className = line.mid(start + 7);
else
diff --git a/kommander/editor/formfile.h b/kommander/editor/formfile.h
index 89ba2f1d..d7c63bce 100644
--- a/kommander/editor/formfile.h
+++ b/kommander/editor/formfile.h
@@ -1,5 +1,5 @@
/**********************************************************************
- This file is based on Qt Designer, Copyright (C) 2000 Trolltech AS. �All rights reserved.
+ This file is based on TQt Designer, Copyright (C) 2000 Trolltech AS. �All rights reserved.
This file may be distributed and/or modified under the terms of the
GNU General Public License version 2 as published by the Free Software
@@ -26,9 +26,10 @@
class FormWindow;
-class FormFile : public QObject
+class FormFile : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
FormFile(const TQString &fn, bool temp);
diff --git a/kommander/editor/formsettings.ui b/kommander/editor/formsettings.ui
index 321de024..6e391265 100644
--- a/kommander/editor/formsettings.ui
+++ b/kommander/editor/formsettings.ui
@@ -19,7 +19,7 @@
** not clear to you.
**
*********************************************************************</comment>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>FormSettingsBase</cstring>
</property>
@@ -50,7 +50,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget" row="2" column="0">
+ <widget class="TQLayoutWidget" row="2" column="0">
<property name="name">
<cstring>Layout4</cstring>
</property>
@@ -74,7 +74,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
@@ -114,7 +114,7 @@
</widget>
</hbox>
</widget>
- <widget class="QGroupBox" row="1" column="0">
+ <widget class="TQGroupBox" row="1" column="0">
<property name="name">
<cstring>GroupBox2</cstring>
</property>
@@ -131,7 +131,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QSpinBox" row="0" column="1">
+ <widget class="TQSpinBox" row="0" column="1">
<property name="name">
<cstring>spinMargin</cstring>
</property>
@@ -139,7 +139,7 @@
<number>11</number>
</property>
</widget>
- <widget class="QSpinBox" row="1" column="1">
+ <widget class="TQSpinBox" row="1" column="1">
<property name="name">
<cstring>spinSpacing</cstring>
</property>
@@ -147,7 +147,7 @@
<number>6</number>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>TextLabel1_3</cstring>
</property>
@@ -158,7 +158,7 @@
<cstring>spinMargin</cstring>
</property>
</widget>
- <widget class="QLabel" row="1" column="0">
+ <widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>TextLabel2_2</cstring>
</property>
@@ -171,7 +171,7 @@
</widget>
</grid>
</widget>
- <widget class="QGroupBox" row="0" column="0">
+ <widget class="TQGroupBox" row="0" column="0">
<property name="name">
<cstring>GroupBox1</cstring>
</property>
@@ -194,7 +194,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QMultiLineEdit" row="3" column="1" rowspan="2" colspan="1">
+ <widget class="TQMultiLineEdit" row="3" column="1" rowspan="2" colspan="1">
<property name="name">
<cstring>editComment</cstring>
</property>
@@ -212,14 +212,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>130</height>
</size>
</property>
</spacer>
- <widget class="QLabel" row="3" column="0">
+ <widget class="TQLabel" row="3" column="0">
<property name="name">
<cstring>TextLabel2</cstring>
</property>
@@ -230,7 +230,7 @@
<cstring>editComment</cstring>
</property>
</widget>
- <widget class="QLabel" row="2" column="0">
+ <widget class="TQLabel" row="2" column="0">
<property name="name">
<cstring>TextLabel1_2_2</cstring>
</property>
@@ -252,7 +252,7 @@
<string>Enter your name.</string>
</property>
</widget>
- <widget class="QLabel" row="1" column="0">
+ <widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>TextLabel1_2_3</cstring>
</property>
@@ -263,7 +263,7 @@
<cstring>editAuthor</cstring>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>TextLabel1_2</cstring>
</property>
@@ -326,10 +326,10 @@
<tabstop>buttonOk</tabstop>
<tabstop>buttonCancel</tabstop>
</tabstops>
-<slots>
+<Q_SLOTS>
<slot>okClicked()</slot>
-</slots>
-<layoutdefaults spacing="6" margin="11"/>
+</Q_SLOTS>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>klineedit.h</includehint>
<includehint>klineedit.h</includehint>
diff --git a/kommander/editor/formsettingsimpl.cpp b/kommander/editor/formsettingsimpl.cpp
index f3f7c3c2..9912634f 100644
--- a/kommander/editor/formsettingsimpl.cpp
+++ b/kommander/editor/formsettingsimpl.cpp
@@ -1,5 +1,5 @@
/**********************************************************************
- This file is based on Qt Designer, Copyright (C) 2000 Trolltech AS. All rights reserved.
+ This file is based on TQt Designer, Copyright (C) 2000 Trolltech AS. All rights reserved.
This file may be distributed and/or modified under the terms of the
GNU General Public License version 2 as published by the Free Software
@@ -27,16 +27,16 @@
#include <klineedit.h>
#include <tqspinbox.h>
-FormSettings::FormSettings( TQWidget *parent, FormWindow *fw )
- : FormSettingsBase( parent, 0, true ), formwindow( fw )
+FormSettings::FormSettings( TQWidget *tqparent, FormWindow *fw )
+ : FormSettingsBase( tqparent, 0, true ), formwindow( fw )
{
- MetaDataBase::MetaInfo info = MetaDataBase::metaInfo(fw);
+ MetaDataBase::MetaInfo info = MetaDataBase::metaInfo(TQT_TQOBJECT(fw));
editAuthor->setText(info.author);
editVersion->setText(info.version);
editLicense->setText(info.license);
editComment->setText(info.comment);
- spinSpacing->setValue(formwindow->layoutDefaultSpacing());
- spinMargin->setValue(formwindow->layoutDefaultMargin());
+ spinSpacing->setValue(formwindow->tqlayoutDefaultSpacing());
+ spinMargin->setValue(formwindow->tqlayoutDefaultMargin());
}
void FormSettings::okClicked()
@@ -46,7 +46,7 @@ void FormSettings::okClicked()
info.version = editVersion->text();
info.license = editLicense->text();
info.comment = editComment->text();
- MetaDataBase::setMetaInfo(formwindow, info);
+ MetaDataBase::setMetaInfo(TQT_TQOBJECT(formwindow), info);
formwindow->commandHistory()->setModified(true);
formwindow->setLayoutDefaultSpacing(spinSpacing->value());
diff --git a/kommander/editor/formsettingsimpl.h b/kommander/editor/formsettingsimpl.h
index 194f168a..e8940b9d 100644
--- a/kommander/editor/formsettingsimpl.h
+++ b/kommander/editor/formsettingsimpl.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -28,9 +28,10 @@ class FormWindow;
class FormSettings : public FormSettingsBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- FormSettings( TQWidget *parent, FormWindow *fw );
+ FormSettings( TQWidget *tqparent, FormWindow *fw );
protected slots:
void okClicked();
diff --git a/kommander/editor/formwindow.cpp b/kommander/editor/formwindow.cpp
index ac0712b4..2218a977 100644
--- a/kommander/editor/formwindow.cpp
+++ b/kommander/editor/formwindow.cpp
@@ -1,5 +1,5 @@
/**********************************************************************
- This file is based on Qt Designer, Copyright (C) 2000 Trolltech AS. All rights reserved.
+ This file is based on TQt Designer, Copyright (C) 2000 Trolltech AS. All rights reserved.
This file may be distributed and/or modified under the terms of the
GNU General Public License version 2 as published by the Free Software
@@ -17,7 +17,7 @@
**********************************************************************/
-// Qt includes
+// TQt includes
#include <tqaccel.h>
#include <tqapplication.h>
#include <tqbitmap.h>
@@ -36,7 +36,7 @@
#include <tqpushbutton.h>
#include <tqsizegrip.h>
#include <tqspinbox.h>
-#include <tqstatusbar.h>
+#include <statusbar.h>
#include <tqtimer.h>
#include <tqtooltip.h>
#include <tqwhatsthis.h>
@@ -54,7 +54,7 @@
#include "sizehandle.h"
#include "metadatabase.h"
#include "resource.h"
-#include "layout.h"
+#include "tqlayout.h"
#include "connectioneditorimpl.h"
#include "widgetdatabase.h"
#include "pixmapchooser.h"
@@ -70,9 +70,9 @@
static void setCursorToAll(const TQCursor &c, TQWidget *start)
{
start->setCursor(c);
- TQObjectList *l = (TQObjectList*)start->children();
- if (l)
- for (TQObject *o = l->first(); o; o = l->next())
+ TQObjectList l = start->childrenListObject();
+ if (!l.isEmpty())
+ for (TQObject *o = l.first(); o; o = l.next())
{
if (o->isWidgetType() && !o->inherits("SizeHandle"))
setCursorToAll(c, ((TQWidget*)o));
@@ -81,13 +81,13 @@ static void setCursorToAll(const TQCursor &c, TQWidget *start)
static void restoreCursors(TQWidget *start, FormWindow *fw)
{
- if (fw->widgets()->find(start))
+ if (fw->widgets()->tqfind(start))
start->setCursor(MetaDataBase::cursor(start));
else
- start->setCursor(Qt::ArrowCursor);
- TQObjectList *l = (TQObjectList*)start->children();
- if (l)
- for (TQObject *o = l->first(); o; o = l->next())
+ start->setCursor(TQt::ArrowCursor);
+ TQObjectList l = start->childrenListObject();
+ if (!l.isEmpty())
+ for (TQObject *o = l.first(); o; o = l.next())
{
if (o->isWidgetType() && !o->inherits("SizeHandle"))
restoreCursors(((TQWidget*)o), fw);
@@ -110,8 +110,8 @@ static void restoreCursors(TQWidget *start, FormWindow *fw)
event filter which is implemented in MainWindow::eventFilter().
*/
-FormWindow::FormWindow(FormFile *f, MainWindow *mw, TQWidget *parent, const char *name)
- : TQWidget(parent, name, WDestructiveClose), mainwindow(mw),
+FormWindow::FormWindow(FormFile *f, MainWindow *mw, TQWidget *tqparent, const char *name)
+ : TQWidget(tqparent, name, WDestructiveClose), mainwindow(mw),
commands(100), pixInline(true)
{
ff = f;
@@ -119,8 +119,8 @@ FormWindow::FormWindow(FormFile *f, MainWindow *mw, TQWidget *parent, const char
initSlots();
}
-FormWindow::FormWindow(FormFile *f, TQWidget *parent, const char *name)
- : TQWidget(parent, name, WDestructiveClose), mainwindow(0),
+FormWindow::FormWindow(FormFile *f, TQWidget *tqparent, const char *name)
+ : TQWidget(tqparent, name, WDestructiveClose), mainwindow(0),
commands(100), pixInline(true)
{
ff = f;
@@ -129,7 +129,7 @@ FormWindow::FormWindow(FormFile *f, TQWidget *parent, const char *name)
void FormWindow::init()
{
- MetaDataBase::addEntry(this);
+ MetaDataBase::addEntry(TQT_TQOBJECT(this));
ff->setFormWindow(this);
propertyWidget = 0;
toolFixed = false;
@@ -140,7 +140,7 @@ void FormWindow::init()
unclippedPainter = 0;
widgetPressed = false;
drawRubber = false;
- setFocusPolicy(ClickFocus);
+ setFocusPolicy(TQ_ClickFocus);
sizePreviewLabel = 0;
checkSelectionsTimer = new TQTimer(this, "checkSelectionsTimer");
connect(checkSelectionsTimer, TQT_SIGNAL(timeout()),
@@ -167,7 +167,7 @@ void FormWindow::init()
TQWidget *w = WidgetFactory::create(WidgetDatabase::idFromClassName(TQFRAME_OBJECT_NAME_STRING), this);
setMainContainer(w);
- propertyWidget = w;
+ propertyWidget = TQT_TQOBJECT(w);
targetContainer = 0;
hadOwnPalette = false;
@@ -178,7 +178,7 @@ void FormWindow::init()
void FormWindow::setMainWindow(MainWindow *w)
{
mainwindow = w;
- MetaDataBase::addEntry(this);
+ MetaDataBase::addEntry(TQT_TQOBJECT(this));
initSlots();
}
@@ -190,7 +190,7 @@ FormWindow::~FormWindow()
{
if (MainWindow::self->objectHierarchy()->formWindow() == this)
MainWindow::self->objectHierarchy()->setFormWindow(0, 0);
- MetaDataBase::clear(this);
+ MetaDataBase::clear(TQT_TQOBJECT(this));
if (ff)
ff->setFormWindow(0);
}
@@ -210,17 +210,17 @@ void FormWindow::paintGrid(TQWidget *w, TQPaintEvent *e)
TQPixmap grid;
TQString grid_name;
grid_name.sprintf("FormWindowGrid_%d_%d", mainWindow()->grid().x(), mainWindow()->grid().y());
- if(!TQPixmapCache::find(grid_name, grid)) {
+ if(!TQPixmapCache::tqfind(grid_name, grid)) {
grid = TQPixmap(350 + (350 % mainWindow()->grid().x()), 350 + (350 % mainWindow()->grid().y()));
- grid.fill(colorGroup().color(TQColorGroup::Foreground));
- TQBitmap mask(grid.width(), grid.height());
- mask.fill(color0);
- TQPainter p(&mask);
+ grid.fill(tqcolorGroup().color(TQColorGroup::Foreground));
+ TQBitmap tqmask(grid.width(), grid.height());
+ tqmask.fill(color0);
+ TQPainter p(&tqmask);
p.setPen(color1);
for (int y = 0; y < grid.width(); y += mainWindow()->grid().y())
for (int x = 0; x < grid.height(); x += mainWindow()->grid().x())
p.drawPoint(x, y);
- grid.setMask(mask);
+ grid.setMask(tqmask);
TQPixmapCache::insert(grid_name, grid);
}
TQPainter p(w);
@@ -267,7 +267,7 @@ TQPoint FormWindow::gridPoint(const TQPoint &p)
void FormWindow::drawSizePreview(const TQPoint &pos, const TQString& text)
{
unclippedPainter->save();
- unclippedPainter->setPen(TQPen(colorGroup().foreground(), 1 ));
+ unclippedPainter->setPen(TQPen(tqcolorGroup().foreground(), 1 ));
unclippedPainter->setRasterOp(CopyROP);
if (!sizePreviewPixmap.isNull())
unclippedPainter->drawPixmap(sizePreviewPos, sizePreviewPixmap);
@@ -295,7 +295,7 @@ void FormWindow::insertWidget()
return;
bool useSizeHint = !oldRectValid || (currRect.width() < 2 && currRect.height() < 2);
- Orientation orient = Horizontal;
+ Qt::Orientation orient =Qt::Horizontal;
TQString n = WidgetDatabase::className(currTool);
if (useSizeHint && (n == "Spacer" || n == TQSLIDER_OBJECT_NAME_STRING || n == "Line" || n == TQSCROLLBAR_OBJECT_NAME_STRING)) {
TQPopupMenu m(mainWindow());
@@ -303,7 +303,7 @@ void FormWindow::insertWidget()
int ver = m.insertItem(i18n("&Vertical"));
int r = m.exec(TQCursor::pos());
if (r == ver)
- orient = Vertical;
+ orient =Qt::Vertical;
}
TQWidget *w = WidgetFactory::create(currTool, insertParent, 0, true, &currRect, orient);
@@ -312,27 +312,27 @@ void FormWindow::insertWidget()
if (!savePixmapInline() && currTool == WidgetDatabase::idFromClassName("PixmapLabel"))
((TQLabel*)w)->setPixmap(PixmapChooser::loadPixmap("image.xpm"));
- int id = WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(w));
+ int id = WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(TQT_TQOBJECT(w)));
if (WidgetDatabase::isCustomWidget(id)) {
TQWhatsThis::add(w, i18n("<b>A %1 (custom widget)</b> "
"<p>Click <b>Edit Custom Widgets...</b> in the <b>Tools|Custom</b> "
"menu to add and change custom widgets. You can add "
"properties as well as signals and slots to integrate custom widgets into "
- "<i>Qt Designer</i>, and provide a pixmap which will be used to represent "
+ "<i>TQt Designer</i>, and provide a pixmap which will be used to represent "
"the widget on the form.</p>")
- .arg(WidgetDatabase::toolTip(id)));
- TQToolTip::add(w, i18n("A %1 (custom widget)").arg(WidgetDatabase::toolTip(id)));
+ .tqarg(WidgetDatabase::toolTip(id)));
+ TQToolTip::add(w, i18n("A %1 (custom widget)").tqarg(WidgetDatabase::toolTip(id)));
}
else
{
TQString tt = WidgetDatabase::toolTip(id);
TQString wt = WidgetDatabase::whatsThis(id);
if (!wt.isEmpty() && !tt.isEmpty())
- TQWhatsThis::add(w, i18n("<b>A %1</b><p>%2</p>").arg(tt).arg(wt));
+ TQWhatsThis::add(w, i18n("<b>A %1</b><p>%2</p>").tqarg(tt).tqarg(wt));
}
TQString s = w->name();
- unify(w, s, true);
+ unify(TQT_TQOBJECT(w), s, true);
w->setName(s);
insertWidget(w);
TQRect r(currRect);
@@ -345,8 +345,8 @@ void FormWindow::insertWidget()
r = TQRect(p, r.size());
if (useSizeHint)
{
- r.setWidth(w->sizeHint().width());
- r.setHeight(w->sizeHint().height());
+ r.setWidth(w->tqsizeHint().width());
+ r.setHeight(w->tqsizeHint().height());
}
if (r.width() < 2 * grid().x())
@@ -354,18 +354,18 @@ void FormWindow::insertWidget()
if (r.height() < 2 * grid().y())
r.setHeight(2 * grid().y());
- const TQObjectList *l = insertParent->children();
- TQObjectListIt it(*l);
+ const TQObjectList l = insertParent->childrenListObject();
+ TQObjectListIt it(l);
TQWidgetList lst;
- if (WidgetDatabase::isContainer(WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(w))))
+ if (WidgetDatabase::isContainer(WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(TQT_TQOBJECT(w)))))
for (; it.current();) {
TQObject *o = it.current();
++it;
if (o->isWidgetType() && ((TQWidget*)o)->isVisibleTo(this) &&
- insertedWidgets.find((TQWidget*)o) && o != w)
+ insertedWidgets.tqfind((TQWidget*)o) && TQT_BASE_OBJECT(o) != TQT_BASE_OBJECT(w))
{
TQRect r2(((TQWidget*)o)->pos(), ((TQWidget*)o)->size());
- if (r.contains(r2))
+ if (r.tqcontains(r2))
lst.append((TQWidget*)o);
}
}
@@ -381,19 +381,19 @@ void FormWindow::insertWidget()
pos -= r.topLeft();
np.append(pos);
}
- MoveCommand *mv = new MoveCommand(i18n("Reparent Widgets"), this, lst, op, np, insertParent, pw);
+ MoveCommand *mv = new MoveCommand(i18n("Retqparent Widgets"), this, lst, op, np, insertParent, pw);
if (!toolFixed)
mainwindow->resetTool();
else
setCursorToAll(CrossCursor, w);
- InsertCommand *cmd = new InsertCommand(i18n("Insert %1").arg(w->name()), this, w, r);
+ InsertCommand *cmd = new InsertCommand(i18n("Insert %1").tqarg(w->name()), this, w, r);
TQPtrList<Command> commands;
commands.append(mv);
commands.append(cmd);
- MacroCommand *mc = new MacroCommand(i18n("Insert %1").arg(w->name()), this, commands);
+ MacroCommand *mc = new MacroCommand(i18n("Insert %1").tqarg(w->name()), this, commands);
commandHistory()->addCommand(mc);
mc->execute();
}
@@ -404,7 +404,7 @@ void FormWindow::insertWidget()
else
setCursorToAll(CrossCursor, w);
- InsertCommand *cmd = new InsertCommand(i18n("Insert %1").arg(w->name()), this, w, r);
+ InsertCommand *cmd = new InsertCommand(i18n("Insert %1").tqarg(w->name()), this, w, r);
commandHistory()->addCommand(cmd);
cmd->execute();
}
@@ -414,29 +414,29 @@ void FormWindow::insertWidget(TQWidget *w, bool checkName)
{
if (checkName) {
TQString s = w->name();
- unify(w, s, true);
+ unify(TQT_TQOBJECT(w), s, true);
w->setName(s);
}
- MetaDataBase::addEntry(w);
- int id = WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(w));
+ MetaDataBase::addEntry(TQT_TQOBJECT(w));
+ int id = WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(TQT_TQOBJECT(w)));
if (WidgetDatabase::isCustomWidget(id))
{
TQWhatsThis::add(w, i18n("<b>A %1 (custom widget)</b> "
"<p>Click <b>Edit Custom Widgets...</b> in the <b>Tools|Custom</b> "
"menu to add and change custom widgets. You can add "
"properties as well as signals and slots to integrate custom widgets into "
- "<i>Qt Designer</i>, and provide a pixmap which will be used to represent "
+ "<i>TQt Designer</i>, and provide a pixmap which will be used to represent "
"the widget on the form.</p>")
- .arg(WidgetDatabase::toolTip(id)));
- TQToolTip::add(w, i18n("A %1 (custom widget)").arg(WidgetDatabase::toolTip(id)));
+ .tqarg(WidgetDatabase::toolTip(id)));
+ TQToolTip::add(w, i18n("A %1 (custom widget)").tqarg(WidgetDatabase::toolTip(id)));
}
else
{
TQString tt = WidgetDatabase::toolTip(id);
TQString wt = WidgetDatabase::whatsThis(id);
if (!wt.isEmpty() && !tt.isEmpty())
- TQWhatsThis::add(w, i18n("<b>A %1</b><p>%2</p>").arg(tt).arg(wt));
+ TQWhatsThis::add(w, i18n("<b>A %1</b><p>%2</p>").tqarg(tt).tqarg(wt));
}
restoreCursors(w, this);
@@ -446,7 +446,7 @@ void FormWindow::insertWidget(TQWidget *w, bool checkName)
void FormWindow::removeWidget(TQWidget *w)
{
- MetaDataBase::removeEntry(w);
+ MetaDataBase::removeEntry(TQT_TQOBJECT(w));
widgets()->take(w);
}
@@ -454,15 +454,15 @@ void FormWindow::handleContextMenu(TQContextMenuEvent *e, TQWidget *w)
{
switch (currTool) {
case POINTER_TOOL:
- if (!isMainContainer(w) && qstrcmp(w->name(), "central widget"))
+ if (!isMainContainer(TQT_TQOBJECT(w)) && qstrcmp(w->name(), "central widget"))
{ // press on a child widget
raiseChildSelections(w); // raise selections and select widget
- selectWidget(w);
+ selectWidget(TQT_TQOBJECT(w));
// if widget is laid out, find the first non-laid out super-widget
TQWidget *realWidget = w; // but store the original one
- while (w->parentWidget() && (WidgetFactory::layoutType(w->parentWidget()) !=
- WidgetFactory::NoLayout || !insertedWidgets.find(w)))
- w = w->parentWidget();
+ while (w->tqparentWidget() && (WidgetFactory::tqlayoutType(w->tqparentWidget()) !=
+ WidgetFactory::NoLayout || !insertedWidgets.tqfind(w)))
+ w = w->tqparentWidget();
if (mainContainer()->inherits(TQMAINWINDOW_OBJECT_NAME_STRING) &&
((TQMainWindow*)mainContainer())->centralWidget() == realWidget)
{
@@ -500,10 +500,10 @@ void FormWindow::handleMousePress(TQMouseEvent *e, TQWidget *w)
switch (currTool) {
case POINTER_TOOL:
- if (!isMainContainer(w) && qstrcmp(w->name(), "central widget") != 0)
+ if (!isMainContainer(TQT_TQOBJECT(w)) && qstrcmp(w->name(), "central widget") != 0)
{ // press on a child widget
- // if the clicked widget is not in a layout, raise it
- if (!w->parentWidget() || WidgetFactory::layoutType(w->parentWidget()) == WidgetFactory::NoLayout)
+ // if the clicked widget is not in a tqlayout, raise it
+ if (!w->tqparentWidget() || WidgetFactory::tqlayoutType(w->tqparentWidget()) == WidgetFactory::NoLayout)
w->raise();
if ((e->state() & ControlButton))
{ // with control pressed, always start rubber band selection
@@ -513,16 +513,16 @@ void FormWindow::handleMousePress(TQMouseEvent *e, TQWidget *w)
break;
}
- bool sel = isWidgetSelected(w);
+ bool sel = isWidgetSelected(TQT_TQOBJECT(w));
if (!((e->state() & ControlButton) || (e->state() & ShiftButton)))
{ // control not pressed...
if (!sel) // ...and widget no selectted: unselect all
clearSelection(false);
else
{ // ...widget selected
- // only if widget has a layout (it is a layout meta widget or a laid out container!),
+ // only if widget has a tqlayout (it is a tqlayout meta widget or a laid out container!),
// unselect its childs
- if (WidgetFactory::layoutType(w) != WidgetFactory::NoLayout)
+ if (WidgetFactory::tqlayoutType(w) != WidgetFactory::NoLayout)
{
TQObjectList *l = w->queryList(TQWIDGET_OBJECT_NAME_STRING);
setPropertyShowingBlocked(true);
@@ -530,60 +530,60 @@ void FormWindow::handleMousePress(TQMouseEvent *e, TQWidget *w)
{
if (!o->isWidgetType())
continue;
- if (insertedWidgets.find((TQWidget*)o))
- selectWidget((TQWidget*)o, false);
+ if (insertedWidgets.tqfind((TQWidget*)o))
+ selectWidget(TQT_TQOBJECT(o), false);
}
setPropertyShowingBlocked(false);
delete l;
}
}
- qApp->processEvents();
+ tqApp->processEvents();
}
if (((e->state() & ControlButton) || (e->state() & ShiftButton)) &&
- sel && e->button() == LeftButton)
+ sel && e->button() == Qt::LeftButton)
{ // control pressed and selected, unselect widget
- selectWidget(w, false);
+ selectWidget(TQT_TQOBJECT(w), false);
break;
}
raiseChildSelections(w); // raise selections and select widget
- selectWidget(w);
+ selectWidget(TQT_TQOBJECT(w));
// if widget is laid out, find the first non-laid out super-widget
- while (w->parentWidget() &&
- (WidgetFactory::layoutType(w->parentWidget()) != WidgetFactory::NoLayout
- || !insertedWidgets.find(w)))
- w = w->parentWidget();
+ while (w->tqparentWidget() &&
+ (WidgetFactory::tqlayoutType(w->tqparentWidget()) != WidgetFactory::NoLayout
+ || !insertedWidgets.tqfind(w)))
+ w = w->tqparentWidget();
- if (e->button() == LeftButton)
- { // left button: store original geometry and more as the widget might start moving
+ if (e->button() == Qt::LeftButton)
+ { // left button: store original tqgeometry and more as the widget might start moving
widgetPressed = true;
widgetGeom = TQRect(w->pos(), w->size());
oldPressPos = w->mapFromGlobal(e->globalPos());
origPressPos = oldPressPos;
checkedSelectionsForMove = false;
moving.clear();
- if (w->parentWidget() && !isMainContainer(w->parentWidget()) &&
- !isCentralWidget(w->parentWidget()))
+ if (w->tqparentWidget() && !isMainContainer(TQT_TQOBJECT(w->tqparentWidget())) &&
+ !isCentralWidget(TQT_TQOBJECT(w->tqparentWidget())))
{
- targetContainer = w->parentWidget();
- hadOwnPalette = w->parentWidget()->ownPalette();
- restorePalette = w->parentWidget()->palette();
+ targetContainer = w->tqparentWidget();
+ hadOwnPalette = w->tqparentWidget()->ownPalette();
+ restorePalette = w->tqparentWidget()->palette();
}
}
}
else
{ // press was on the formwindow
- if (e->button() == LeftButton)
+ if (e->button() == Qt::LeftButton)
{ // left button: start rubber selection and show formwindow properties
drawRubber = true;
if (!((e->state() & ControlButton) || (e->state() & ShiftButton)))
{
clearSelection(false);
TQObject *opw = propertyWidget;
- propertyWidget = mainContainer();
+ propertyWidget = TQT_TQOBJECT(mainContainer());
if (opw->isWidgetType())
- repaintSelection((TQWidget*)opw);
+ tqrepaintSelection((TQWidget*)opw);
}
currRect = TQRect(0, 0, -1, -1);
startRectDraw(mapFromGlobal(e->globalPos()), e->globalPos(), this, Rubber);
@@ -591,25 +591,25 @@ void FormWindow::handleMousePress(TQMouseEvent *e, TQWidget *w)
}
break;
case CONNECT_TOOL:
- if (e->button() != LeftButton)
+ if (e->button() != Qt::LeftButton)
break;
saveBackground();
- mainWindow()->statusBar()->message(i18n("Connect '%1' with...").arg(w->name()));
+ mainWindow()->statusBar()->message(i18n("Connect '%1' with...").tqarg(w->name()));
connectStartPos = mapFromGlobal(e->globalPos());
currentConnectPos = mapFromGlobal(e->globalPos());
- connectSender = designerWidget(w);
- connectReceiver = connectableObject(designerWidget(w), connectReceiver);
+ connectSender = TQT_TQOBJECT(designerWidget(TQT_TQOBJECT(w)));
+ connectReceiver = connectableObject(TQT_TQOBJECT(designerWidget(TQT_TQOBJECT(w))), connectReceiver);
beginUnclippedPainter(false);
drawConnectLine();
break;
case ORDER_TOOL:
- if (!isMainContainer(w))
+ if (!isMainContainer(TQT_TQOBJECT(w)))
{ // press on a child widget
orderedWidgets.removeRef(w);
orderedWidgets.append(w);
for (TQWidget *wid = orderedWidgets.last(); wid; wid = orderedWidgets.prev())
{
- int i = stackedWidgets.findRef(wid);
+ int i = stackedWidgets.tqfindRef(wid);
if (i != -1)
{
stackedWidgets.removeRef(wid);
@@ -625,25 +625,25 @@ void FormWindow::handleMousePress(TQMouseEvent *e, TQWidget *w)
}
break;
default: // any insert widget tool
- if (e->button() == LeftButton)
+ if (e->button() == Qt::LeftButton)
{
insertParent = WidgetFactory::containerOfWidget(mainContainer());
- // default parent for new widget is the formwindow
- if (!isMainContainer(w))
- { // press was not on formwindow, check if we can find another parent
+ // default tqparent for new widget is the formwindow
+ if (!isMainContainer(TQT_TQOBJECT(w)))
+ { // press was not on formwindow, check if we can find another tqparent
TQWidget *wid = w;
for (;;)
{
- int id = WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(wid));
+ int id = WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(TQT_TQOBJECT(wid)));
if ((WidgetDatabase::isContainer(id) || wid == mainContainer()) &&
!wid->inherits(TQLAYOUTWIDGET_OBJECT_NAME_STRING) && !wid->inherits(TQSPLITTER_OBJECT_NAME_STRING))
{
- insertParent = WidgetFactory::containerOfWidget(wid); // found another parent, store it
+ insertParent = WidgetFactory::containerOfWidget(wid); // found another tqparent, store it
break;
}
else
{
- wid = wid->parentWidget();
+ wid = wid->tqparentWidget();
if (!wid)
break;
}
@@ -659,13 +659,13 @@ void FormWindow::handleMouseDblClick(TQMouseEvent *, TQWidget *w)
{
switch (currTool) {
case ORDER_TOOL:
- if (!isMainContainer(w))
+ if (!isMainContainer(TQT_TQOBJECT(w)))
{ // press on a child widget
orderedWidgets.clear();
orderedWidgets.append(w);
for (TQWidget *wid = orderedWidgets.last(); wid; wid = orderedWidgets.prev())
{
- int i = stackedWidgets.findRef(wid);
+ int i = stackedWidgets.tqfindRef(wid);
if (i != -1)
{
stackedWidgets.removeRef(wid);
@@ -685,7 +685,7 @@ void FormWindow::handleMouseDblClick(TQMouseEvent *, TQWidget *w)
void FormWindow::handleMouseMove(TQMouseEvent *e, TQWidget *w)
{
- if ((e->state() & LeftButton) != LeftButton)
+ if ((e->state() & Qt::LeftButton) != Qt::LeftButton)
return;
TQWidget *newReceiver = (TQWidget*)connectReceiver, *oldReceiver = (TQWidget*)connectReceiver, *wid;
@@ -695,16 +695,16 @@ void FormWindow::handleMouseMove(TQMouseEvent *e, TQWidget *w)
if (widgetPressed && allowMove(w))
{ // we are prepated for a move
// if widget is laid out, find the first non-laid out super-widget
- while (w->parentWidget() && (WidgetFactory::layoutType(w->parentWidget()) !=
- WidgetFactory::NoLayout || !insertedWidgets.find(w)))
- w = w->parentWidget();
+ while (w->tqparentWidget() && (WidgetFactory::tqlayoutType(w->tqparentWidget()) !=
+ WidgetFactory::NoLayout || !insertedWidgets.tqfind(w)))
+ w = w->tqparentWidget();
// calc correct position
TQPoint pos = w->mapFromGlobal(e->globalPos());
// calc move distance and store it
TQPoint d = oldPressPos - pos;
- if (QABS(d.x()) < grid().x())
+ if (TQABS(d.x()) < grid().x())
d.setX(0);
- if (QABS(d.y()) < grid().y())
+ if (TQABS(d.y()) < grid().y())
d.setY(0);
if (d.x() == 0)
pos.setX(oldPressPos.x());
@@ -724,19 +724,19 @@ void FormWindow::handleMouseMove(TQMouseEvent *e, TQWidget *w)
{ // if we actually have to move
if (!checkedSelectionsForMove)
{ // if not checked yet, check if the correct widget are selected...
- if (!isWidgetSelected(w))
+ if (!isWidgetSelected(TQT_TQOBJECT(w)))
{ // and unselect others. Only siblings can be moved at the same time
setPropertyShowingBlocked(true);
- selectWidget(w);
+ selectWidget(TQT_TQOBJECT(w));
setPropertyShowingBlocked(false);
}
checkSelectionsForMove(w);
}
// check whether we would have to reparent the selection and
- // highlight the possible new parent container
+ // highlight the possible new tqparent container
TQMapConstIterator<ulong, TQPoint> it = moving.begin();
TQWidget* wa = containerAt(e->globalPos(), ((TQWidget*)it.key()));
- if (wa && !isMainContainer(wa) && !isCentralWidget(wa))
+ if (wa && !isMainContainer(TQT_TQOBJECT(wa)) && !isCentralWidget(TQT_TQOBJECT(wa)))
{
wa = WidgetFactory::containerOfWidget(wa);
// ok, looks like we moved onto a container
@@ -753,7 +753,7 @@ void FormWindow::handleMouseMove(TQMouseEvent *e, TQWidget *w)
targetContainer = wa;
hadOwnPalette = wa->ownPalette();
restorePalette = wa->palette();
- wa->setPaletteBackgroundColor(wa->colorGroup().midlight());
+ wa->setPaletteBackgroundColor(wa->tqcolorGroup().midlight());
}
}
else if (targetContainer)
@@ -767,7 +767,7 @@ void FormWindow::handleMouseMove(TQMouseEvent *e, TQWidget *w)
// finally move the selected widgets and show/update preview label
moveSelectedWidgets(x - p.x(), y - p.y());
- sizePreviewLabel->setText(TQString("%1/%2").arg(w->pos().x()).arg(w->pos().y()));
+ sizePreviewLabel->setText(TQString("%1/%2").tqarg(w->pos().x()).tqarg(w->pos().y()));
sizePreviewLabel->adjustSize();
TQRect lg(mapFromGlobal(e->globalPos()) + TQPoint(16, 16), sizePreviewLabel->size());
checkPreviewGeometry(lg);
@@ -790,24 +790,24 @@ void FormWindow::handleMouseMove(TQMouseEvent *e, TQWidget *w)
break;
case CONNECT_TOOL:
restoreConnectionLine();
- wid = qApp->widgetAt(e->globalPos(), true);
+ wid = tqApp->widgetAt(e->globalPos(), true);
if (wid)
- wid = designerWidget(wid);
- if (wid && (isMainContainer(wid) || insertedWidgets.find(wid)) && wid->isVisibleTo(this))
+ wid = designerWidget(TQT_TQOBJECT(wid));
+ if (wid && (isMainContainer(TQT_TQOBJECT(wid)) || insertedWidgets.tqfind(wid)) && wid->isVisibleTo(this))
newReceiver = wid;
- if (newReceiver && (newReceiver->inherits("QLayoutWidget")
+ if (newReceiver && (newReceiver->inherits(TQLAYOUTWIDGET_OBJECT_NAME_STRING)
|| newReceiver->inherits("Spacer")))
newReceiver = (TQWidget*)connectReceiver;
- drawRecRect = newReceiver != connectReceiver;
+ drawRecRect = TQT_BASE_OBJECT(newReceiver) != TQT_BASE_OBJECT(connectReceiver);
currentConnectPos = mapFromGlobal(e->globalPos());
- if (newReceiver && (isMainContainer(newReceiver)
- || insertedWidgets.find(newReceiver)) && !isCentralWidget(newReceiver))
- connectReceiver = connectableObject(newReceiver, connectReceiver);
- mainWindow()->statusBar()->message(i18n("Connect '%1' to '%2'").arg(connectSender->name()).
+ if (newReceiver && (isMainContainer(TQT_TQOBJECT(newReceiver))
+ || insertedWidgets.tqfind(newReceiver)) && !isCentralWidget(TQT_TQOBJECT(newReceiver)))
+ connectReceiver = connectableObject(TQT_TQOBJECT(newReceiver), TQT_TQOBJECT(connectReceiver));
+ mainWindow()->statusBar()->message(i18n("Connect '%1' to '%2'").tqarg(connectSender->name()).
arg(connectReceiver->name()));
- qApp->processEvents();
+ tqApp->processEvents();
if (drawRecRect)
- restoreRect(TQRect(mapToForm(((TQWidget*)oldReceiver)->parentWidget(),
+ restoreRect(TQRect(mapToForm(((TQWidget*)oldReceiver)->tqparentWidget(),
((TQWidget*)oldReceiver)->pos()), ((TQWidget*)oldReceiver)->size()));
drawConnectLine();
break;
@@ -822,7 +822,7 @@ void FormWindow::handleMouseMove(TQMouseEvent *e, TQWidget *w)
void FormWindow::handleMouseRelease(TQMouseEvent * e, TQWidget * w)
{
- if (e->button() != LeftButton)
+ if (e->button() != Qt::LeftButton)
return;
switch (currTool)
@@ -832,7 +832,7 @@ void FormWindow::handleMouseRelease(TQMouseEvent * e, TQWidget * w)
{ // we moved the widget
sizePreviewLabel->hide();
- if (moving.isEmpty() || w->pos() == *moving.find((ulong) w))
+ if (moving.isEmpty() || w->pos() == *moving.tqfind((ulong) w))
break;
// restore targetContainer
@@ -848,7 +848,7 @@ void FormWindow::handleMouseRelease(TQMouseEvent * e, TQWidget * w)
emitUpdateProperties(propertyWidget);
TQMapConstIterator < ulong, TQPoint > it = moving.begin();
- TQWidget *oldParent = ((TQWidget *) it.key())->parentWidget();
+ TQWidget *oldParent = ((TQWidget *) it.key())->tqparentWidget();
TQWidget *newParent = oldParent;
// check whether we have to reparent the selection
TQWidget *wa = containerAt(e->globalPos(), ((TQWidget *) it.key()));
@@ -857,21 +857,21 @@ void FormWindow::handleMouseRelease(TQMouseEvent * e, TQWidget * w)
wa = WidgetFactory::containerOfWidget(wa);
// ok, looks like we moved onto a container
- // check whether we really have different parents.
- if (wa == ((TQWidget *) it.key())->parentWidget())
+ // check whether we really have different tqparents.
+ if (wa == ((TQWidget *) it.key())->tqparentWidget())
goto make_move_command;
- // break layout if necessary
- if (WidgetFactory::layoutType(wa) != WidgetFactory::NoLayout)
+ // break tqlayout if necessary
+ if (WidgetFactory::tqlayoutType(wa) != WidgetFactory::NoLayout)
{
if (KMessageBox::questionYesNo(mainWindow(),
i18n("You tried to insert a widget into the "
- "layout Container Widget '%1'.\n"
+ "tqlayout Container Widget '%1'.\n"
"This is not possible. "
- "In order to insert the widget, the layout of '%1'\n"
+ "In order to insert the widget, the tqlayout of '%1'\n"
"must first be broken.\n"
- "Break the layout or cancel the operation?").
- arg(wa->name()).arg(wa->name()), i18n("Inserting Widget"),
+ "Break the tqlayout or cancel the operation?").
+ tqarg(wa->name()).tqarg(wa->name()), i18n("Inserting Widget"),
i18n("&Break Layout"), KStdGuiItem::cancel()) == KMessageBox::No)
goto make_move_command; // cancel
breakLayout(wa);
@@ -883,27 +883,27 @@ void FormWindow::handleMouseRelease(TQMouseEvent * e, TQWidget * w)
TQWidget *i = (TQWidget *) it.key();
if (!emitSelChanged && i->inherits(TQBUTTON_OBJECT_NAME_STRING))
{
- if (i->parentWidget() && i->parentWidget()->inherits(TQBUTTONGROUP_OBJECT_NAME_STRING) ||
+ if (i->tqparentWidget() && i->tqparentWidget()->inherits(TQBUTTONGROUP_OBJECT_NAME_STRING) ||
wa->inherits(TQBUTTONGROUP_OBJECT_NAME_STRING))
emitSelChanged = true;
if (!wa->inherits(TQBUTTONGROUP_OBJECT_NAME_STRING))
{
- MetaDataBase::setPropertyChanged(i, "buttonGroupId", false);
- if (i->parentWidget() && i->parentWidget()->inherits(TQBUTTONGROUP_OBJECT_NAME_STRING))
- ((TQButtonGroup *) i->parentWidget())->remove((TQButton *) i);
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(i), "buttonGroupId", false);
+ if (i->tqparentWidget() && i->tqparentWidget()->inherits(TQBUTTONGROUP_OBJECT_NAME_STRING))
+ ((TQButtonGroup *) i->tqparentWidget())->remove((TQButton *) i);
}
}
TQPoint pos = wa->mapFromGlobal(i->mapToGlobal(TQPoint(0, 0)));
i->reparent(wa, pos, true);
raiseSelection(i);
raiseChildSelections(i);
- widgetChanged(i);
+ widgetChanged(TQT_TQOBJECT(i));
mainWindow()->objectHierarchy()->widgetRemoved(i);
mainWindow()->objectHierarchy()->widgetInserted(i);
}
if (emitSelChanged)
{
- emit showProperties(wa);
+ emit showProperties(TQT_TQOBJECT(wa));
emit showProperties(propertyWidget);
}
newParent = wa;
@@ -935,13 +935,13 @@ void FormWindow::handleMouseRelease(TQMouseEvent * e, TQWidget * w)
case CONNECT_TOOL:
restoreConnectionLine();
if (connectSender)
- restoreRect(TQRect(mapToForm(((TQWidget *) connectSender)->parentWidget(),
+ restoreRect(TQRect(mapToForm(((TQWidget *) connectSender)->tqparentWidget(),
((TQWidget *) connectSender)->pos()), ((TQWidget *) connectSender)->size()));
if (connectReceiver)
- restoreRect(TQRect(mapToForm(((TQWidget *) connectReceiver)->parentWidget(),
+ restoreRect(TQRect(mapToForm(((TQWidget *) connectReceiver)->tqparentWidget(),
((TQWidget *) connectReceiver)->pos()), ((TQWidget *) connectReceiver)->size()));
endUnclippedPainter();
- qApp->processEvents();
+ tqApp->processEvents();
if (connectSender && connectReceiver)
editConnections();
break;
@@ -951,15 +951,15 @@ void FormWindow::handleMouseRelease(TQMouseEvent * e, TQWidget * w)
if (insertParent)
{ // we should insert the new widget now
endRectDraw();
- if (WidgetFactory::layoutType(insertParent) != WidgetFactory::NoLayout)
+ if (WidgetFactory::tqlayoutType(insertParent) != WidgetFactory::NoLayout)
{
if (KMessageBox::questionYesNo(mainWindow(),
i18n("You tried to insert a widget into the "
- "layout Container Widget '%1'.\n"
+ "tqlayout Container Widget '%1'.\n"
"This is not possible. "
- "In order to insert the widget, the layout of '%1'\n"
+ "In order to insert the widget, the tqlayout of '%1'\n"
"must first be broken.\n"
- "Break the layout or cancel the operation?").
+ "Break the tqlayout or cancel the operation?").
arg(insertParent->name()).
arg(insertParent->name()), i18n("Inserting Widget"),
i18n("&Break Layout"), KStdGuiItem::cancel()) == KMessageBox::Yes)
@@ -1064,7 +1064,7 @@ void FormWindow::handleKeyPress(TQKeyEvent * e, TQWidget * w)
TQObjectList *l = queryList(TQWIDGET_OBJECT_NAME_STRING);
if (!l)
return;
- if (l->find(w) != -1)
+ if (l->tqfind(TQT_TQOBJECT(w)) != -1)
e->accept();
delete l;
}
@@ -1086,12 +1086,12 @@ void FormWindow::selectWidget(TQObject * o, bool select)
TQWidget *w = (TQWidget *) o;
- if (isMainContainer(w))
+ if (isMainContainer(TQT_TQOBJECT(w)))
{
TQObject *opw = propertyWidget;
- propertyWidget = mainContainer();
+ propertyWidget = TQT_TQOBJECT(mainContainer());
if (opw->isWidgetType())
- repaintSelection((TQWidget *) opw);
+ tqrepaintSelection((TQWidget *) opw);
emitShowProperties(propertyWidget);
return;
}
@@ -1100,25 +1100,25 @@ void FormWindow::selectWidget(TQObject * o, bool select)
w == ((TQMainWindow *) mainContainer())->centralWidget())
{
TQObject *opw = propertyWidget;
- propertyWidget = mainContainer();
+ propertyWidget = TQT_TQOBJECT(mainContainer());
if (opw->isWidgetType())
- repaintSelection((TQWidget *) opw);
+ tqrepaintSelection((TQWidget *) opw);
emitShowProperties(propertyWidget);
return;
}
- if (o->inherits("QDesignerToolBar") || o->inherits("QDesignerMenuBar"))
+ if (o->inherits("TQDesignerToolBar") || o->inherits("TQDesignerMenuBar"))
return;
if (select)
{
TQObject *opw = propertyWidget;
- propertyWidget = w;
+ propertyWidget = TQT_TQOBJECT(w);
if (opw->isWidgetType())
- repaintSelection((TQWidget *) opw);
+ tqrepaintSelection((TQWidget *) opw);
if (!isPropertyShowingBlocked())
emitShowProperties(propertyWidget);
- WidgetSelection *s = usedSelections.find(w);
+ WidgetSelection *s = usedSelections.tqfind(w);
if (s)
{
s->show();
@@ -1143,16 +1143,16 @@ void FormWindow::selectWidget(TQObject * o, bool select)
emitSelectionChanged();
} else
{
- WidgetSelection *s = usedSelections.find(w);
+ WidgetSelection *s = usedSelections.tqfind(w);
if (s)
s->setWidget(0);
TQObject *opw = propertyWidget;
if (!usedSelections.isEmpty())
- propertyWidget = TQPtrDictIterator < WidgetSelection > (usedSelections).current()->widget();
+ propertyWidget = TQT_TQOBJECT(TQPtrDictIterator < WidgetSelection > (usedSelections).current()->widget());
else
- propertyWidget = mainContainer();
+ propertyWidget = TQT_TQOBJECT(mainContainer());
if (opw->isWidgetType())
- repaintSelection((TQWidget *) opw);
+ tqrepaintSelection((TQWidget *) opw);
if (!isPropertyShowingBlocked())
emitShowProperties(propertyWidget);
emitSelectionChanged();
@@ -1168,23 +1168,23 @@ TQPoint FormWindow::grid() const
void FormWindow::updateSelection(TQWidget * w)
{
- WidgetSelection *s = usedSelections.find(w);
+ WidgetSelection *s = usedSelections.tqfind(w);
if (!w->isVisibleTo(this))
- selectWidget(w, false);
+ selectWidget(TQT_TQOBJECT(w), false);
else if (s)
s->updateGeometry();
}
void FormWindow::raiseSelection(TQWidget * w)
{
- WidgetSelection *s = usedSelections.find(w);
+ WidgetSelection *s = usedSelections.tqfind(w);
if (s)
s->show();
}
-void FormWindow::repaintSelection(TQWidget * w)
+void FormWindow::tqrepaintSelection(TQWidget * w)
{
- WidgetSelection *s = usedSelections.find(w);
+ WidgetSelection *s = usedSelections.tqfind(w);
if (s)
s->update();
}
@@ -1199,9 +1199,9 @@ void FormWindow::clearSelection(bool changePropertyDisplay)
if (changePropertyDisplay)
{
TQObject *opw = propertyWidget;
- propertyWidget = mainContainer();
+ propertyWidget = TQT_TQOBJECT(mainContainer());
if (opw->isWidgetType())
- repaintSelection((TQWidget *) opw);
+ tqrepaintSelection((TQWidget *) opw);
emitShowProperties(propertyWidget);
}
emitSelectionChanged();
@@ -1239,7 +1239,7 @@ void FormWindow::continueRectDraw(const TQPoint & p, const TQPoint & global, TQW
if (currRect == r)
{
TQString t("%1/%2");
- t = t.arg(r.width() - 1).arg(r.height() - 1);
+ t = t.tqarg(r.width() - 1).tqarg(r.height() - 1);
drawSizePreview(pos, t);
return;
}
@@ -1253,7 +1253,7 @@ void FormWindow::continueRectDraw(const TQPoint & p, const TQPoint & global, TQW
if (t == Insert)
{
TQString t("%1/%2");
- t = t.arg(r.width() - 1).arg(r.height() - 1);
+ t = t.tqarg(r.width() - 1).tqarg(r.height() - 1);
drawSizePreview(pos, t);
}
unclippedPainter->setClipRegion(TQRegion(rect()).subtract(TQRect(sizePreviewPos,
@@ -1275,7 +1275,7 @@ void FormWindow::endRectDraw()
if (oldRectValid)
unclippedPainter->drawRect(currRect);
- drawSizePreview(TQPoint(-1, -1), TQString::null);
+ drawSizePreview(TQPoint(-1, -1), TQString());
endUnclippedPainter();
}
@@ -1291,8 +1291,8 @@ void FormWindow::selectWidgets()
TQPoint p = ((TQWidget *) o)->mapToGlobal(TQPoint(0, 0));
p = mapFromGlobal(p);
TQRect r(p, ((TQWidget *) o)->size());
- if (r.intersects(currRect) && !r.contains(currRect))
- selectWidget((TQWidget *) o);
+ if (r.intersects(currRect) && !r.tqcontains(currRect))
+ selectWidget(TQT_TQOBJECT(o));
}
}
delete l;
@@ -1303,8 +1303,8 @@ void FormWindow::selectWidgets()
bool FormWindow::isWidgetSelected(TQObject * w)
{
if (w->isWidgetType())
- return usedSelections.find((TQWidget *) w) != 0;
- return false; // #### do stuff for QObjects
+ return usedSelections.tqfind((TQWidget *) w) != 0;
+ return false; // #### do stuff for TQObjects
}
void FormWindow::moveSelectedWidgets(int dx, int dy)
@@ -1314,8 +1314,8 @@ void FormWindow::moveSelectedWidgets(int dx, int dy)
{
WidgetSelection *s = it.current();
TQWidget *w = s->widget();
- if (w->parentWidget()
- && WidgetFactory::layoutType(w->parentWidget()) != WidgetFactory::NoLayout)
+ if (w->tqparentWidget()
+ && WidgetFactory::tqlayoutType(w->tqparentWidget()) != WidgetFactory::NoLayout)
continue;
w->move(w->x() + dx, w->y() + dy);
s->updateGeometry();
@@ -1350,7 +1350,7 @@ void FormWindow::raiseChildSelections(TQWidget * w)
TQPtrDictIterator < WidgetSelection > it(usedSelections);
for (; it.current(); ++it)
{
- if (l->findRef(it.current()->widget()) != -1)
+ if (l->tqfindRef(TQT_TQOBJECT(it.current()->widget())) != -1)
it.current()->show();
}
delete l;
@@ -1363,7 +1363,7 @@ void FormWindow::updateChildSelections(TQWidget * w)
{
for (TQObject * o = l->first(); o; o = l->next())
{
- if (o->isWidgetType() && insertedWidgets.find((TQWidget *) o))
+ if (o->isWidgetType() && insertedWidgets.tqfind((TQWidget *) o))
updateSelection((TQWidget *) o);
}
delete l;
@@ -1374,7 +1374,7 @@ void FormWindow::checkSelectionsForMove(TQWidget * w)
{
checkedSelectionsForMove = true;
- TQObjectList *l = w->parentWidget()->queryList(TQWIDGET_OBJECT_NAME_STRING, 0, false, false);
+ TQObjectList *l = w->tqparentWidget()->queryList(TQWIDGET_OBJECT_NAME_STRING, 0, false, false);
moving.clear();
if (l)
{
@@ -1385,13 +1385,13 @@ void FormWindow::checkSelectionsForMove(TQWidget * w)
if (it.current()->widget() == mainContainer())
continue;
++it;
- if (l->find(sel->widget()) == -1)
+ if (l->tqfind(TQT_TQOBJECT(sel->widget())) == -1)
{
- if (WidgetFactory::layoutType(w) == WidgetFactory::NoLayout)
+ if (WidgetFactory::tqlayoutType(w) == WidgetFactory::NoLayout)
sel->setWidget(0);
} else
{
- if (WidgetFactory::layoutType(sel->widget()->parentWidget()) == WidgetFactory::NoLayout)
+ if (WidgetFactory::tqlayoutType(sel->widget()->tqparentWidget()) == WidgetFactory::NoLayout)
{
moving.insert((ulong) sel->widget(), sel->widget()->pos());
sel->widget()->raise();
@@ -1411,10 +1411,10 @@ void FormWindow::deleteWidgets()
for (; it.current(); ++it)
{
TQWidget *tb = 0;
- if (!(tb = mainWindow()->isAToolBarChild(it.current()->widget())))
+ if (!(tb = mainWindow()->isAToolBarChild(TQT_TQOBJECT(it.current()->widget()))))
widgets.append(it.current()->widget());
else
- ((QDesignerToolBar *) tb)->removeWidget(it.current()->widget());
+ ((TQDesignerToolBar *) tb)->removeWidget(it.current()->widget());
}
if (widgets.isEmpty())
@@ -1431,13 +1431,13 @@ void FormWindow::editAdjustSize()
TQWidgetList widgets = selectedWidgets();
if (widgets.isEmpty())
{
- TQRect oldr = geometry();
+ TQRect oldr = tqgeometry();
mainContainer()->adjustSize();
resize(mainContainer()->size());
// check whether our own size constraint hit us
if (size() != mainContainer()->size())
mainContainer()->resize(size());
- TQRect nr = geometry();
+ TQRect nr = tqgeometry();
if (oldr != nr)
{
ResizeCommand *cmd = new ResizeCommand(i18n("Adjust Size"), this, this, oldr, nr);
@@ -1447,12 +1447,12 @@ void FormWindow::editAdjustSize()
}
for (TQWidget * w = widgets.first(); w; w = widgets.next())
{
- if (w->parentWidget()
- && WidgetFactory::layoutType(w->parentWidget()) != WidgetFactory::NoLayout)
+ if (w->tqparentWidget()
+ && WidgetFactory::tqlayoutType(w->tqparentWidget()) != WidgetFactory::NoLayout)
continue;
- TQRect oldr = w->geometry();
+ TQRect oldr = w->tqgeometry();
w->adjustSize();
- TQRect nr = w->geometry();
+ TQRect nr = w->tqgeometry();
if (oldr != nr)
commands.append(new ResizeCommand(i18n("Adjust Size"), this, w, oldr, nr));
}
@@ -1500,7 +1500,7 @@ void FormWindow::invalidCheckedSelections()
void FormWindow::checkPreviewGeometry(TQRect & r)
{
- if (rect().contains(r))
+ if (TQT_TQRECT_OBJECT(rect()).tqcontains(r))
return;
if (r.left() < rect().left())
r.moveTopLeft(TQPoint(0, r.top()));
@@ -1527,9 +1527,9 @@ void FormWindow::focusOutEvent(TQFocusEvent *)
if (propertyWidget && !isMainContainer(propertyWidget) && !isWidgetSelected(propertyWidget))
{
TQObject *opw = propertyWidget;
- propertyWidget = mainContainer();
+ propertyWidget = TQT_TQOBJECT(mainContainer());
if (opw->isWidgetType())
- repaintSelection((TQWidget *) opw);
+ tqrepaintSelection((TQWidget *) opw);
}
}
@@ -1552,8 +1552,8 @@ TQWidget *FormWindow::designerWidget(TQObject * o) const
if (!o || !o->isWidgetType())
return 0;
TQWidget *w = (TQWidget *) o;
- while (w && !isMainContainer(w) && !insertedWidgets[(void *) w] || isCentralWidget(w))
- w = (TQWidget *) w->parent();
+ while (w && !isMainContainer(TQT_TQOBJECT(w)) && !insertedWidgets[(void *) w] || isCentralWidget(TQT_TQOBJECT(w)))
+ w = (TQWidget *) w->tqparent();
return w;
}
@@ -1564,7 +1564,7 @@ void FormWindow::emitShowProperties(TQObject * w)
TQObject *opw = propertyWidget;
propertyWidget = w;
if (opw->isWidgetType())
- repaintSelection((TQWidget *) opw);
+ tqrepaintSelection((TQWidget *) opw);
}
showPropertiesTimer->stop();
showPropertiesTimer->start(0, true);
@@ -1618,10 +1618,10 @@ void FormWindow::currentToolChanged()
case CONNECT_TOOL:
restoreConnectionLine();
if (connectSender)
- restoreRect(TQRect(mapToForm(((TQWidget *) connectSender)->parentWidget(),
+ restoreRect(TQRect(mapToForm(((TQWidget *) connectSender)->tqparentWidget(),
((TQWidget *) connectSender)->pos()), ((TQWidget *) connectSender)->size()));
if (connectReceiver)
- restoreRect(TQRect(mapToForm(((TQWidget *) connectReceiver)->parentWidget(),
+ restoreRect(TQRect(mapToForm(((TQWidget *) connectReceiver)->tqparentWidget(),
((TQWidget *) connectReceiver)->pos()), ((TQWidget *) connectReceiver)->size()));
endUnclippedPainter();
break;
@@ -1652,7 +1652,7 @@ void FormWindow::currentToolChanged()
{
case POINTER_TOOL:
if (propertyWidget && !isMainContainer(propertyWidget) && !isWidgetSelected(propertyWidget))
- emitShowProperties(mainContainer());
+ emitShowProperties(TQT_TQOBJECT(mainContainer()));
restoreCursors(this, this);
break;
case ORDER_TOOL:
@@ -1662,7 +1662,7 @@ void FormWindow::currentToolChanged()
orderedWidgets.clear();
showOrderIndicators();
if (mainWindow()->formWindow() == this)
- emitShowProperties(mainContainer());
+ emitShowProperties(TQT_TQOBJECT(mainContainer()));
setCursorToAll(ArrowCursor, this);
}
break;
@@ -1670,14 +1670,14 @@ void FormWindow::currentToolChanged()
mainWindow()->statusBar()->message(i18n("Drag a line to create a connection..."));
setCursorToAll(CrossCursor, this);
if (mainWindow()->formWindow() == this)
- emitShowProperties(mainContainer());
+ emitShowProperties(TQT_TQOBJECT(mainContainer()));
break;
default:
mainWindow()->statusBar()->message(i18n("Click on the form to insert a %1...").
arg(WidgetDatabase::toolTip(currTool).lower()));
setCursorToAll(CrossCursor, this);
if (mainWindow()->formWindow() == this)
- emitShowProperties(mainContainer());
+ emitShowProperties(TQT_TQOBJECT(mainContainer()));
break;
}
}
@@ -1694,12 +1694,12 @@ void FormWindow::showOrderIndicators()
for (TQObject * o = l->first(); o; o = l->next())
{
TQWidget *w = (TQWidget *) o;
- if (w->isVisibleTo(w->parentWidget()) &&
- insertedWidgets[(void *) w] && w->focusPolicy() != NoFocus)
+ if (w->isVisibleTo(w->tqparentWidget()) &&
+ insertedWidgets[(void *) w] && w->focusPolicy() != TQ_NoFocus)
{
OrderIndicator *ind = new OrderIndicator(order++, w, this);
orderIndicators.append(ind);
- if (stackedWidgets.findRef(w) == -1)
+ if (stackedWidgets.tqfindRef(w) == -1)
stackedWidgets.append(w);
}
}
@@ -1743,7 +1743,7 @@ bool FormWindow::checkCustomWidgets()
{
if (it.current()->isA("CustomWidget"))
{
- TQString className = WidgetFactory::classNameOf(it.current());
+ TQString className = WidgetFactory::classNameOf(TQT_TQOBJECT(it.current()));
if (!MetaDataBase::hasCustomWidget(className))
missingCustomWidgets << className;
}
@@ -1788,14 +1788,14 @@ void FormWindow::lowerWidgets()
static void find_accel(const TQString & txt, TQMap < TQChar, TQWidgetList > &accels, TQWidget * w)
{
- int i = txt.find("&");
+ int i = txt.tqfind("&");
if (i == -1)
return;
TQChar c = txt[i + 1];
if (c.isNull() || c == '&')
return;
c = c.lower();
- TQMap < TQChar, TQWidgetList >::Iterator it = accels.find(c);
+ TQMap < TQChar, TQWidgetList >::Iterator it = accels.tqfind(c);
if (it == accels.end())
{
TQWidgetList wl;
@@ -1820,11 +1820,11 @@ void FormWindow::checkAccels()
{
TQWidget *w = (TQWidget *) o;
const TQMetaProperty *text =
- w->metaObject()->property(w->metaObject()->findProperty("text", true), true);
+ w->tqmetaObject()->property(w->tqmetaObject()->tqfindProperty("text", true), true);
const TQMetaProperty *title =
- w->metaObject()->property(w->metaObject()->findProperty("title", true), true);
+ w->tqmetaObject()->property(w->tqmetaObject()->tqfindProperty("title", true), true);
const TQMetaProperty *pageTitle =
- w->metaObject()->property(w->metaObject()->findProperty("pageTitle", true), true);
+ w->tqmetaObject()->property(w->tqmetaObject()->tqfindProperty("pageTitle", true), true);
if (text)
find_accel(w->property("text").toString(), accels, w);
if (title)
@@ -1844,12 +1844,12 @@ void FormWindow::checkAccels()
{
ok = false;
if (KMessageBox::questionYesNo(mainWindow(),
- i18n("Accelerator '%1' is used %2 times.").arg(it.key().upper()).arg((*it).count()),
+ i18n("Accelerator '%1' is used %2 times.").tqarg(it.key().upper()).tqarg((*it).count()),
i18n("Check Accelerators"), i18n("&Select"), KStdGuiItem::cancel()) == KMessageBox::Yes)
{
clearSelection(false);
for (wid = (*it).first(); wid; wid = (*it).next())
- selectWidget(wid, true);
+ selectWidget(TQT_TQOBJECT(wid), true);
}
return;
}
@@ -1872,11 +1872,11 @@ void FormWindow::raiseWidgets()
commandHistory()->addCommand(cmd);
}
-void FormWindow::paste(const TQString & cb, TQWidget * parent)
+void FormWindow::paste(const TQString & cb, TQWidget * tqparent)
{
Resource resource(mainWindow());
resource.setWidget(this);
- resource.paste(cb, parent);
+ resource.paste(cb, tqparent);
}
void FormWindow::selectAll()
@@ -1890,7 +1890,7 @@ void FormWindow::selectAll()
{
if (((TQWidget *) o)->isVisibleTo(this) && insertedWidgets[(void *) o])
{
- selectWidget((TQWidget *) o);
+ selectWidget(TQT_TQOBJECT(o));
}
}
delete l;
@@ -1903,49 +1903,49 @@ void FormWindow::selectAll()
emitSelectionChanged();
}
-void FormWindow::layoutHorizontal()
+void FormWindow::tqlayoutHorizontal()
{
TQWidgetList widgets(selectedWidgets());
- LayoutHorizontalCommand *cmd = new LayoutHorizontalCommand(i18n("Lay Out Horizontally"),
+ LayoutHorizontalCommand *cmd = new LayoutHorizontalCommand(i18n("Lay OutQt::Horizontally"),
this, mainContainer(), 0, widgets);
clearSelection(false);
commandHistory()->addCommand(cmd);
cmd->execute();
}
-void FormWindow::layoutVertical()
+void FormWindow::tqlayoutVertical()
{
TQWidgetList widgets(selectedWidgets());
- LayoutVerticalCommand *cmd = new LayoutVerticalCommand(i18n("Lay Out Vertically"),
+ LayoutVerticalCommand *cmd = new LayoutVerticalCommand(i18n("Lay OutQt::Vertically"),
this, mainContainer(), 0, widgets);
clearSelection(false);
commandHistory()->addCommand(cmd);
cmd->execute();
}
-void FormWindow::layoutHorizontalSplit()
+void FormWindow::tqlayoutHorizontalSplit()
{
TQWidgetList widgets(selectedWidgets());
LayoutHorizontalSplitCommand *cmd =
- new LayoutHorizontalSplitCommand(i18n("Lay Out Horizontally (in splitter)"),
+ new LayoutHorizontalSplitCommand(i18n("Lay OutQt::Horizontally (in splitter)"),
this, mainContainer(), 0, widgets);
clearSelection(false);
commandHistory()->addCommand(cmd);
cmd->execute();
}
-void FormWindow::layoutVerticalSplit()
+void FormWindow::tqlayoutVerticalSplit()
{
TQWidgetList widgets(selectedWidgets());
LayoutVerticalSplitCommand *cmd =
- new LayoutVerticalSplitCommand(i18n("Lay Out Vertically (in splitter)"),
+ new LayoutVerticalSplitCommand(i18n("Lay OutQt::Vertically (in splitter)"),
this, mainContainer(), 0, widgets);
clearSelection(false);
commandHistory()->addCommand(cmd);
cmd->execute();
}
-void FormWindow::layoutGrid()
+void FormWindow::tqlayoutGrid()
{
int xres = grid().x();
int yres = grid().y();
@@ -1958,63 +1958,63 @@ void FormWindow::layoutGrid()
cmd->execute();
}
-void FormWindow::layoutHorizontalContainer(TQWidget * w)
+void FormWindow::tqlayoutHorizontalContainer(TQWidget * w)
{
if (w == this)
w = mainContainer();
- TQObjectList *l = (TQObjectList *) WidgetFactory::containerOfWidget(w)->children();
- if (!l)
+ TQObjectList l = WidgetFactory::containerOfWidget(w)->childrenListObject();
+ if (l.isEmpty())
return;
TQWidgetList widgets;
- for (TQObject * o = l->first(); o; o = l->next())
+ for (TQObject * o = l.first(); o; o = l.next())
{
if (o->isWidgetType() &&
- ((TQWidget *) o)->isVisibleTo(this) && insertedWidgets.find((TQWidget *) o))
+ ((TQWidget *) o)->isVisibleTo(this) && insertedWidgets.tqfind((TQWidget *) o))
widgets.append((TQWidget *) o);
}
- LayoutHorizontalCommand *cmd = new LayoutHorizontalCommand(i18n("Lay Out Children Horizontally"),
+ LayoutHorizontalCommand *cmd = new LayoutHorizontalCommand(i18n("Lay Out ChildrenQt::Horizontally"),
this, mainContainer(), w, widgets);
clearSelection(false);
commandHistory()->addCommand(cmd);
cmd->execute();
}
-void FormWindow::layoutVerticalContainer(TQWidget * w)
+void FormWindow::tqlayoutVerticalContainer(TQWidget * w)
{
if (w == this)
w = mainContainer();
- TQObjectList *l = (TQObjectList *) WidgetFactory::containerOfWidget(w)->children();
- if (!l)
+ TQObjectList l = WidgetFactory::containerOfWidget(w)->childrenListObject();
+ if (l.isEmpty())
return;
TQWidgetList widgets;
- for (TQObject * o = l->first(); o; o = l->next())
+ for (TQObject * o = l.first(); o; o = l.next())
{
if (o->isWidgetType() &&
- ((TQWidget *) o)->isVisibleTo(this) && insertedWidgets.find((TQWidget *) o))
+ ((TQWidget *) o)->isVisibleTo(this) && insertedWidgets.tqfind((TQWidget *) o))
widgets.append((TQWidget *) o);
}
- LayoutVerticalCommand *cmd = new LayoutVerticalCommand(i18n("Lay Out Children Vertically"),
+ LayoutVerticalCommand *cmd = new LayoutVerticalCommand(i18n("Lay Out ChildrenQt::Vertically"),
this, mainContainer(), w, widgets);
clearSelection(false);
commandHistory()->addCommand(cmd);
cmd->execute();
}
-void FormWindow::layoutGridContainer(TQWidget * w)
+void FormWindow::tqlayoutGridContainer(TQWidget * w)
{
if (w == this)
w = mainContainer();
int xres = grid().x();
int yres = grid().y();
- TQObjectList *l = (TQObjectList *) WidgetFactory::containerOfWidget(w)->children();
- if (!l)
+ TQObjectList l = WidgetFactory::containerOfWidget(w)->childrenListObject();
+ if (l.isEmpty())
return;
TQWidgetList widgets;
- for (TQObject * o = l->first(); o; o = l->next())
+ for (TQObject * o = l.first(); o; o = l.next())
{
if (o->isWidgetType() &&
- ((TQWidget *) o)->isVisibleTo(this) && insertedWidgets.find((TQWidget *) o))
+ ((TQWidget *) o)->isVisibleTo(this) && insertedWidgets.tqfind((TQWidget *) o))
widgets.append((TQWidget *) o);
}
LayoutGridCommand *cmd = new LayoutGridCommand(i18n("Lay Out Children in a Grid"),
@@ -2035,8 +2035,8 @@ void FormWindow::breakLayout(TQWidget * w)
{
if (!w || w == this)
break;
- if (WidgetFactory::layoutType(w) != WidgetFactory::NoLayout &&
- WidgetDatabase::isContainer(WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(w))))
+ if (WidgetFactory::tqlayoutType(w) != WidgetFactory::NoLayout &&
+ WidgetDatabase::isContainer(WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(TQT_TQOBJECT(w)))))
{
Command *cmd = breakLayoutCommand(w);
if (cmd)
@@ -2044,7 +2044,7 @@ void FormWindow::breakLayout(TQWidget * w)
if (!w->inherits(TQLAYOUTWIDGET_OBJECT_NAME_STRING) && !w->inherits(TQSPLITTER_OBJECT_NAME_STRING))
break;
}
- w = w->parentWidget();
+ w = w->tqparentWidget();
}
if (commands.isEmpty())
@@ -2058,16 +2058,16 @@ void FormWindow::breakLayout(TQWidget * w)
BreakLayoutCommand *FormWindow::breakLayoutCommand(TQWidget * w)
{
- TQObjectList *l = (TQObjectList *) w->children();
- if (!l)
+ TQObjectList l = w->childrenListObject();
+ if (l.isEmpty())
return 0;
TQWidgetList widgets;
- for (TQObject * o = l->first(); o; o = l->next())
+ for (TQObject * o = l.first(); o; o = l.next())
{
if (o->isWidgetType() &&
- !mainWindow()->isAToolBarChild((TQWidget *) o) &&
- ((TQWidget *) o)->isVisibleTo(this) && insertedWidgets.find((TQWidget *) o))
+ !mainWindow()->isAToolBarChild(TQT_TQOBJECT(o)) &&
+ ((TQWidget *) o)->isVisibleTo(this) && insertedWidgets.tqfind((TQWidget *) o))
widgets.append((TQWidget *) o);
}
return new BreakLayoutCommand(i18n("Break Layout"), this,
@@ -2102,7 +2102,7 @@ bool FormWindow::hasInsertedChildren(TQWidget *w) const
for (TQObject *o = l->first(); o; o = l->next())
if (o->isWidgetType() && ((TQWidget*)o)->isVisibleTo((FormWindow*)this) &&
- insertedWidgets.find((TQWidget*)o))
+ insertedWidgets.tqfind((TQWidget*)o))
{
delete l;
return true;
@@ -2113,13 +2113,13 @@ bool FormWindow::hasInsertedChildren(TQWidget *w) const
bool FormWindow::allowMove(TQWidget *w)
{
- w = w->parentWidget();
+ w = w->tqparentWidget();
while (w)
{
- if ((isMainContainer(w) || insertedWidgets.find(w)) && WidgetFactory::layoutType(w) ==
+ if ((isMainContainer(TQT_TQOBJECT(w)) || insertedWidgets.tqfind(w)) && WidgetFactory::tqlayoutType(w) ==
WidgetFactory::NoLayout)
return true;
- w = w->parentWidget();
+ w = w->tqparentWidget();
}
return false;
}
@@ -2152,8 +2152,8 @@ void FormWindow::restoreConnectionLine()
if (!unclippedPainter || !buffer)
return;
- int a =QABS(connectStartPos.x() - currentConnectPos.x());
- int b = QABS(connectStartPos.y() - currentConnectPos.y());
+ int a =TQABS(connectStartPos.x() - currentConnectPos.x());
+ int b = TQABS(connectStartPos.y() - currentConnectPos.y());
TQRect r(connectStartPos, currentConnectPos);
if (a < 32 || b < 32)
@@ -2197,7 +2197,7 @@ void FormWindow::restoreConnectionLine()
w = h = 64;
r = r.normalize();
- while (r.contains(p))
+ while (r.tqcontains(p))
{
unclippedPainter->drawPixmap(p, *buffer, TQRect(p, TQSize(w, h)));
unclippedPainter->setPen(red);
@@ -2274,7 +2274,7 @@ bool FormWindow::unify(TQObject *w, TQString &s, bool changeIt)
int num = 1;
TQPtrDictIterator<TQWidget> it(insertedWidgets);
for (; it.current();)
- if (it.current() != w && !qstrcmp(it.current()->name(), s.latin1()))
+ if (TQT_BASE_OBJECT(it.current()) != TQT_BASE_OBJECT(w) && !qstrcmp(it.current()->name(), s.latin1()))
{
found = true;
if (!changeIt)
@@ -2328,7 +2328,7 @@ bool FormWindow::unify(TQObject *w, TQString &s, bool changeIt)
}
if (!found)
{
- TQObjectList *l = mainContainer()->queryList("QDesignerPopupMenu", 0, true);
+ TQObjectList *l = mainContainer()->queryList("TQDesignerPopupMenu", 0, true);
for (TQObject *o = l->first(); o; o = l->next())
if (o != w && !qstrcmp(o->name(), s.latin1()))
{
@@ -2351,7 +2351,7 @@ bool FormWindow::isCustomWidgetUsed(MetaDataBase::CustomWidget *w)
{
TQPtrDictIterator<TQWidget> it(insertedWidgets);
for (; it.current(); ++it)
- if (it.current()->isA("CustomWidget") && !qstrcmp(WidgetFactory::classNameOf(it.current()),
+ if (it.current()->isA("CustomWidget") && !qstrcmp(WidgetFactory::classNameOf(TQT_TQOBJECT(it.current())),
w->className.utf8()))
return true;
return false;
@@ -2359,14 +2359,14 @@ bool FormWindow::isCustomWidgetUsed(MetaDataBase::CustomWidget *w)
bool FormWindow::isDatabaseWidgetUsed() const
{
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
TQStringList dbClasses;
dbClasses << TQDATATABLE_OBJECT_NAME_STRING; // add more here
TQPtrDictIterator<TQWidget> it(insertedWidgets);
for (; it.current(); ++it)
{
TQString c(it.current()->className());
- if (dbClasses.contains(c) > 0)
+ if (dbClasses.tqcontains(c) > 0)
return true;
}
#endif
@@ -2375,9 +2375,9 @@ bool FormWindow::isDatabaseWidgetUsed() const
bool FormWindow::isDatabaseAware() const
{
-#ifndef QT_NO_SQL
- if (TQString(mContainer->className()) == "QDesignerDataBrowser" ||
- TQString(mContainer->className()) == "QDesignerDataView")
+#ifndef TQT_NO_SQL
+ if (TQString(mContainer->className()) == "TQDesignerDataBrowser" ||
+ TQString(mContainer->className()) == "TQDesignerDataView")
return true;
return isDatabaseWidgetUsed();
#else
@@ -2388,7 +2388,7 @@ bool FormWindow::isDatabaseAware() const
void FormWindow::visibilityChanged()
{
if (currTool != ORDER_TOOL)
- emitUpdateProperties(currentWidget());
+ emitUpdateProperties(TQT_TQOBJECT(currentWidget()));
else
{
updateOrderIndicators();
@@ -2407,10 +2407,10 @@ TQPoint FormWindow::mapToForm(const TQWidget* w, const TQPoint& pos) const
{
TQPoint p = pos;
const TQWidget* i = w;
- while (i && !i->isTopLevel() && !isMainContainer((TQWidget*)i))
+ while (i && !i->isTopLevel() && !isMainContainer(TQT_TQOBJECT(const_cast<TQWidget*>(i))))
{
p = i->mapToParent(p);
- i = i->parentWidget();
+ i = i->tqparentWidget();
}
return mapFromGlobal(w->mapToGlobal(pos));
}
@@ -2421,7 +2421,7 @@ static int widgetDepth(TQWidget *w)
while (w && !w->isTopLevel())
{
d++;
- w = w->parentWidget();
+ w = w->tqparentWidget();
}
return d;
@@ -2433,7 +2433,7 @@ static bool isChildOf(TQWidget *c, TQWidget *p)
{
if (c == p)
return true;
- c = c->parentWidget();
+ c = c->tqparentWidget();
}
return false;
}
@@ -2444,7 +2444,7 @@ TQWidget *FormWindow::containerAt(const TQPoint &pos, TQWidget *notParentOf)
TQWidget *container = 0;
int depth = -1;
TQWidgetList selected = selectedWidgets();
- if (rect().contains(mapFromGlobal(pos)))
+ if (TQT_TQRECT_OBJECT(rect()).tqcontains(mapFromGlobal(pos)))
{
container = mainContainer();
depth = widgetDepth(container);
@@ -2457,26 +2457,26 @@ TQWidget *FormWindow::containerAt(const TQPoint &pos, TQWidget *notParentOf)
continue;
if (!it.current()->isVisibleTo(this))
continue;
- if (selected.find(it.current()) != -1)
+ if (selected.tqfind(it.current()) != -1)
continue;
if (!WidgetDatabase::isContainer(WidgetDatabase::idFromClassName(
- WidgetFactory::classNameOf(it.current()))) && it.current() != mainContainer())
+ WidgetFactory::classNameOf(TQT_TQOBJECT(it.current())))) && it.current() != mainContainer())
continue;
// the rectangles of all ancestors of the container must contain the insert position
TQWidget *w = it.current();
while (w && !w->isTopLevel())
{
- if (!w->rect().contains((w->mapFromGlobal(pos))))
+ if (!TQT_TQRECT_OBJECT(w->rect()).tqcontains((w->mapFromGlobal(pos))))
break;
- w = w->parentWidget();
+ w = w->tqparentWidget();
}
if (w && !w->isTopLevel()) continue; // we did not get through the full while loop
int wd = widgetDepth(it.current());
- if (wd == depth && container && ((TQObjectList*)it.current()->parentWidget()->
- children())->find(it.current()) >
- ((TQObjectList*)container->parentWidget()->children())->find(container))
+ if (wd == depth && container && (it.current()->tqparentWidget()->
+ childrenListObject()).tqfind(TQT_TQOBJECT(it.current())) >
+ (container->tqparentWidget()->childrenListObject()).tqfind(TQT_TQOBJECT(container)))
wd++;
if (wd > depth && !isChildOf(it.current(), notParentOf)) {
depth = wd;
@@ -2489,7 +2489,7 @@ TQWidget *FormWindow::containerAt(const TQPoint &pos, TQWidget *notParentOf)
bool FormWindow::isMainContainer(TQObject *w) const
{
- return w && w->isWidgetType() && (w == (TQWidget*)this || w == mainContainer());
+ return w && w->isWidgetType() && (TQT_BASE_OBJECT(w) == this || TQT_BASE_OBJECT(w) == TQT_BASE_OBJECT(mainContainer()));
}
void FormWindow::setMainContainer(TQWidget *w)
@@ -2497,20 +2497,20 @@ void FormWindow::setMainContainer(TQWidget *w)
bool resetPropertyWidget = isMainContainer(propertyWidget);
if (mContainer)
insertedWidgets.remove(mContainer);
- if (propertyWidget == mContainer)
+ if (TQT_BASE_OBJECT(propertyWidget) == TQT_BASE_OBJECT(mContainer))
propertyWidget = 0;
delete mContainer;
mContainer = w;
insertedWidgets.insert(mContainer, mContainer);
- delete layout();
+ delete tqlayout();
TQHBoxLayout *l = new TQHBoxLayout(this);
l->addWidget(w);
if (resetPropertyWidget)
{
TQObject *opw = propertyWidget;
- propertyWidget = mContainer;
+ propertyWidget = TQT_TQOBJECT(mContainer);
if (opw && opw->isWidgetType())
- repaintSelection((TQWidget*)opw);
+ tqrepaintSelection((TQWidget*)opw);
}
}
@@ -2567,7 +2567,7 @@ bool FormWindow::isCentralWidget(TQObject *w) const
{
if (!mainContainer()->inherits(TQMAINWINDOW_OBJECT_NAME_STRING))
return false;
- return w == ((TQMainWindow*)mainContainer())->centralWidget();
+ return TQT_BASE_OBJECT(w) == TQT_BASE_OBJECT(((TQMainWindow*)mainContainer())->centralWidget());
}
TQObject *FormWindow::connectableObject(TQObject *w, TQObject *)
@@ -2575,12 +2575,12 @@ TQObject *FormWindow::connectableObject(TQObject *w, TQObject *)
return w;
}
-int FormWindow::layoutDefaultSpacing() const
+int FormWindow::tqlayoutDefaultSpacing() const
{
return defSpacing;
}
-int FormWindow::layoutDefaultMargin() const
+int FormWindow::tqlayoutDefaultMargin() const
{
return defMargin;
}
diff --git a/kommander/editor/formwindow.h b/kommander/editor/formwindow.h
index fd0964e7..214ea668 100644
--- a/kommander/editor/formwindow.h
+++ b/kommander/editor/formwindow.h
@@ -1,5 +1,5 @@
/**********************************************************************
- This file is based on Qt Designer, Copyright (C) 2000 Trolltech AS.  All rights reserved.
+ This file is based on TQt Designer, Copyright (C) 2000 Trolltech AS.  All rights reserved.
This file may be distributed and/or modified under the terms of the
GNU General Public License version 2 as published by the Free Software
@@ -49,20 +49,21 @@ class TQPixmap;
class TQSizeGrip;
class FormFile;
-#if defined(Q_FULL_TEMPLATE_INSTANTIATION)
+#if defined(TQ_FULL_TEMPLATE_INSTANTIATION)
#include "orderindicator.h"
#else
class OrderIndicator;
#endif
-class FormWindow : public QWidget
+class FormWindow : public TQWidget
{
Q_OBJECT
- Q_PROPERTY( TQString fileName READ fileName WRITE setFileName )
+ TQ_OBJECT
+ TQ_PROPERTY( TQString fileName READ fileName WRITE setFileName )
public:
- FormWindow( FormFile *f, MainWindow *mw, TQWidget *parent, const char *name = 0 );
- FormWindow( FormFile *f, TQWidget *parent, const char *name = 0 );
+ FormWindow( FormFile *f, MainWindow *mw, TQWidget *tqparent, const char *name = 0 );
+ FormWindow( FormFile *f, TQWidget *tqparent, const char *name = 0 );
~FormWindow();
void init();
@@ -79,20 +80,20 @@ public:
virtual void undo();
virtual void redo();
virtual TQString copy();
- virtual void paste( const TQString &cb, TQWidget *parent );
+ virtual void paste( const TQString &cb, TQWidget *tqparent );
virtual void lowerWidgets();
virtual void raiseWidgets();
virtual void checkAccels();
- virtual void layoutHorizontal();
- virtual void layoutVertical();
- virtual void layoutHorizontalSplit();
- virtual void layoutVerticalSplit();
- virtual void layoutGrid();
+ virtual void tqlayoutHorizontal();
+ virtual void tqlayoutVertical();
+ virtual void tqlayoutHorizontalSplit();
+ virtual void tqlayoutVerticalSplit();
+ virtual void tqlayoutGrid();
- virtual void layoutHorizontalContainer( TQWidget *w );
- virtual void layoutVerticalContainer( TQWidget *w );
- virtual void layoutGridContainer( TQWidget *w );
+ virtual void tqlayoutHorizontalContainer( TQWidget *w );
+ virtual void tqlayoutVerticalContainer( TQWidget *w );
+ virtual void tqlayoutGridContainer( TQWidget *w );
virtual void breakLayout( TQWidget *w );
@@ -100,7 +101,7 @@ public:
virtual void selectAll();
virtual void updateSelection( TQWidget *w );
virtual void raiseSelection( TQWidget *w );
- virtual void repaintSelection( TQWidget *w );
+ virtual void tqrepaintSelection( TQWidget *w );
virtual void clearSelection( bool changePropertyDisplay = TRUE );
virtual void selectWidgets();
bool isWidgetSelected( TQObject *w );
@@ -177,8 +178,8 @@ public:
void killAccels( TQObject *top );
- int layoutDefaultSpacing() const;
- int layoutDefaultMargin() const;
+ int tqlayoutDefaultSpacing() const;
+ int tqlayoutDefaultMargin() const;
void setLayoutDefaultSpacing( int s );
void setLayoutDefaultMargin( int s );
diff --git a/kommander/editor/functions.ui b/kommander/editor/functions.ui
index 48616099..35d53c2c 100644
--- a/kommander/editor/functions.ui
+++ b/kommander/editor/functions.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.3" stdsetdef="1">
<class>FunctionsDialogBase</class>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>FunctionsDialogBase</cstring>
</property>
@@ -22,15 +22,15 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLayoutWidget" row="0" column="2">
+ <widget class="TQLayoutWidget" row="0" column="2">
<property name="name">
- <cstring>layout7_2</cstring>
+ <cstring>tqlayout7_2</cstring>
</property>
<vbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>textLabel1_2</cstring>
</property>
@@ -42,7 +42,7 @@
<property name="name">
<cstring>descriptionText</cstring>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>200</width>
<height>0</height>
@@ -51,15 +51,15 @@
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget" row="0" column="0">
+ <widget class="TQLayoutWidget" row="0" column="0">
<property name="name">
- <cstring>layout7</cstring>
+ <cstring>tqlayout7</cstring>
</property>
<vbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>textLabel1</cstring>
</property>
@@ -82,14 +82,14 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>150</width>
<height>0</height>
</size>
</property>
</widget>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>textLabel2</cstring>
</property>
@@ -115,11 +115,11 @@
</widget>
</vbox>
</widget>
- <widget class="QGroupBox" row="0" column="1">
+ <widget class="TQGroupBox" row="0" column="1">
<property name="name">
<cstring>groupBox1</cstring>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>250</width>
<height>0</height>
@@ -132,7 +132,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel" row="6" column="0">
+ <widget class="TQLabel" row="6" column="0">
<property name="name">
<cstring>argLabel3</cstring>
</property>
@@ -140,7 +140,7 @@
<string>Arg3</string>
</property>
</widget>
- <widget class="QLabel" row="10" column="0">
+ <widget class="TQLabel" row="10" column="0">
<property name="name">
<cstring>argLabel5</cstring>
</property>
@@ -158,7 +158,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>16</height>
@@ -177,7 +177,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>32767</width>
<height>32</height>
@@ -190,7 +190,7 @@
<string>Insert function</string>
</property>
</widget>
- <widget class="QLabel" row="8" column="0">
+ <widget class="TQLabel" row="8" column="0">
<property name="name">
<cstring>argLabel4</cstring>
</property>
@@ -211,9 +211,9 @@
</sizepolicy>
</property>
</widget>
- <widget class="QLayoutWidget" row="3" column="0">
+ <widget class="TQLayoutWidget" row="3" column="0">
<property name="name">
- <cstring>layout11</cstring>
+ <cstring>tqlayout11</cstring>
</property>
<hbox>
<property name="name">
@@ -232,7 +232,7 @@
</sizepolicy>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>quote1</cstring>
</property>
@@ -255,7 +255,7 @@
</widget>
</hbox>
</widget>
- <widget class="QLabel" row="2" column="0">
+ <widget class="TQLabel" row="2" column="0">
<property name="name">
<cstring>argLabel1</cstring>
</property>
@@ -263,9 +263,9 @@
<string>Arg1</string>
</property>
</widget>
- <widget class="QLayoutWidget" row="5" column="0">
+ <widget class="TQLayoutWidget" row="5" column="0">
<property name="name">
- <cstring>layout12</cstring>
+ <cstring>tqlayout12</cstring>
</property>
<hbox>
<property name="name">
@@ -287,7 +287,7 @@
</sizepolicy>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>quote2</cstring>
</property>
@@ -310,9 +310,9 @@
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget" row="7" column="0">
+ <widget class="TQLayoutWidget" row="7" column="0">
<property name="name">
- <cstring>layout13</cstring>
+ <cstring>tqlayout13</cstring>
</property>
<hbox>
<property name="name">
@@ -331,7 +331,7 @@
</sizepolicy>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>quote3</cstring>
</property>
@@ -354,7 +354,7 @@
</widget>
</hbox>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>widgetLabel</cstring>
</property>
@@ -362,9 +362,9 @@
<string>Widget:</string>
</property>
</widget>
- <widget class="QLayoutWidget" row="9" column="0">
+ <widget class="TQLayoutWidget" row="9" column="0">
<property name="name">
- <cstring>layout14</cstring>
+ <cstring>tqlayout14</cstring>
</property>
<hbox>
<property name="name">
@@ -383,7 +383,7 @@
</sizepolicy>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>quote4</cstring>
</property>
@@ -406,9 +406,9 @@
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget" row="11" column="0">
+ <widget class="TQLayoutWidget" row="11" column="0">
<property name="name">
- <cstring>layout15</cstring>
+ <cstring>tqlayout15</cstring>
</property>
<hbox>
<property name="name">
@@ -427,7 +427,7 @@
</sizepolicy>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>quote5</cstring>
</property>
@@ -450,9 +450,9 @@
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget" row="13" column="0">
+ <widget class="TQLayoutWidget" row="13" column="0">
<property name="name">
- <cstring>layout16</cstring>
+ <cstring>tqlayout16</cstring>
</property>
<hbox>
<property name="name">
@@ -471,7 +471,7 @@
</sizepolicy>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>quote6</cstring>
</property>
@@ -494,7 +494,7 @@
</widget>
</hbox>
</widget>
- <widget class="QLabel" row="12" column="0">
+ <widget class="TQLabel" row="12" column="0">
<property name="name">
<cstring>argLabel6</cstring>
</property>
@@ -502,7 +502,7 @@
<string>Arg6</string>
</property>
</widget>
- <widget class="QLabel" row="4" column="0">
+ <widget class="TQLabel" row="4" column="0">
<property name="name">
<cstring>argLabel2</cstring>
</property>
@@ -512,9 +512,9 @@
</widget>
</grid>
</widget>
- <widget class="QLayoutWidget" row="2" column="0" rowspan="1" colspan="3">
+ <widget class="TQLayoutWidget" row="2" column="0" rowspan="1" colspan="3">
<property name="name">
- <cstring>layout6</cstring>
+ <cstring>tqlayout6</cstring>
</property>
<hbox>
<property name="name">
@@ -530,7 +530,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>100</width>
<height>20</height>
@@ -578,7 +578,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>100</width>
<height>20</height>
@@ -587,17 +587,17 @@
</spacer>
</hbox>
</widget>
- <widget class="QLayoutWidget" row="1" column="0" rowspan="1" colspan="3">
+ <widget class="TQLayoutWidget" row="1" column="0" rowspan="1" colspan="3">
<property name="name">
- <cstring>layout12</cstring>
+ <cstring>tqlayout12</cstring>
</property>
<hbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout11</cstring>
+ <cstring>tqlayout11</cstring>
</property>
<hbox>
<property name="name">
@@ -607,7 +607,7 @@
<property name="name">
<cstring>clearButton</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>32767</width>
<height>20</height>
@@ -623,7 +623,7 @@
<string>Clear edited text</string>
</property>
</widget>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>textLabel4</cstring>
</property>
@@ -695,7 +695,7 @@
<tabstop>buttonOk</tabstop>
<tabstop>buttonCancel</tabstop>
</tabstops>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>ktextbrowser.h</includehint>
<includehint>kcombobox.h</includehint>
diff --git a/kommander/editor/functionsimpl.cpp b/kommander/editor/functionsimpl.cpp
index a758ab30..991377f8 100644
--- a/kommander/editor/functionsimpl.cpp
+++ b/kommander/editor/functionsimpl.cpp
@@ -130,13 +130,13 @@ TQString FunctionsDialog::currentFunctionText()
function = s + ".";
}
if (groupComboBox->currentText() == "Kommander")
- return TQString("%1%2%3").arg(prefix).arg(functionListBox->currentText()).arg(params());
+ return TQString("%1%2%3").tqarg(prefix).tqarg(functionListBox->currentText()).tqarg(params());
else if (groupComboBox->currentItem() == m_DCOP || groupComboBox->currentItem() == m_Slots)
- return TQString("%1%2.%3%4").arg(prefix).arg(widgetComboBox->currentText().section(' ', 0, 0))
- .arg(functionListBox->currentText().left(functionListBox->currentText().find('('))).arg(params());
+ return TQString("%1%2.%3%4").tqarg(prefix).tqarg(widgetComboBox->currentText().section(' ', 0, 0))
+ .tqarg(functionListBox->currentText().left(functionListBox->currentText().tqfind('('))).tqarg(params());
else
- return TQString("%1%2%3%4").arg(prefix).arg(function)
- .arg(functionListBox->currentText()).arg(params());
+ return TQString("%1%2%3%4").tqarg(prefix).tqarg(function)
+ .tqarg(functionListBox->currentText()).tqarg(params());
}
void FunctionsDialog::groupChanged(int index)
@@ -147,15 +147,15 @@ void FunctionsDialog::groupChanged(int index)
if (index == m_Slots)
{
KommanderWidget* a_atw = dynamic_cast<KommanderWidget *>(m_widgetList[widgetComboBox->currentText()]);
- TQStringList pFunctions = TQStringList::fromStrList(a_atw->object()->metaObject()->slotNames(true));
+ TQStringList pFunctions = TQStringList::fromStrList(a_atw->object()->tqmetaObject()->slotNames(true));
for (uint i=0; i<pFunctions.count(); i++)
{
TQString slot = pFunctions[i];
TQString slotArgStr = slot.section(TQRegExp("\\(|\\)"), 1);
- if (slotArgStr.isEmpty() || m_acceptedSlots.contains(slotArgStr))
+ if (slotArgStr.isEmpty() || m_acceptedSlots.tqcontains(slotArgStr))
{
TQString name = slot.remove("()");
- if (!m_slotList.contains(name))
+ if (!m_slotList.tqcontains(name))
{
m_slotList[name] = slot;
functionListBox->insertItem(name);
@@ -195,13 +195,13 @@ void FunctionsDialog::functionChanged(int)
{
KommanderWidget* w = dynamic_cast<KommanderWidget *>(m_widgetList[widgetComboBox->currentText()]);
TQObject *o = w->object();
- TQString slotHelp = i18n("To learn more about the slot, look at the documentation of the base Qt/KDE class, most probably <i>%1</i>.").arg(o->metaObject()->superClassName() ? TQString(o->metaObject()->superClassName()) : TQString(o->className()) );
+ TQString slotHelp = i18n("To learn more about the slot, look at the documentation of the base TQt/KDE class, most probably <i>%1</i>.").tqarg(o->tqmetaObject()->tqsuperClassName() ? TQString(o->tqmetaObject()->tqsuperClassName()) : TQString(o->className()) );
TQString slotName = functionListBox->currentText();
TQString slot = m_slotList[slotName];
descriptionText->clear();
descriptionText->setText(i18n("<qt><h3>%1</h3>"
"<p><b>Description:</b> %2\n<p><b>Syntax:</b> <i>%3</i>%4</qt>")
- .arg(slotName).arg(slotHelp).arg(slot).arg(""));
+ .tqarg(slotName).tqarg(slotHelp).tqarg(slot).tqarg(""));
} else
{
int index = groupComboBox->currentItem();
@@ -224,8 +224,8 @@ void FunctionsDialog::functionChanged(int)
descriptionText->clear();
descriptionText->setText(i18n("<qt><h3>%1</h3>"
"<p><b>Description:</b> %2\n<p><b>Syntax:</b> <i>%3</i>%4</qt>")
- .arg(functionListBox->currentText()).arg(m_function.description())
- .arg(m_function.prototype(pflags)).arg(defArgs));
+ .tqarg(functionListBox->currentText()).tqarg(m_function.description())
+ .tqarg(m_function.prototype(pflags)).tqarg(defArgs));
}
showParameters();
@@ -238,7 +238,7 @@ void FunctionsDialog::copyText()
insertedText->getCursorPosition(&para, &i);
// int cursorPos = insertedText->cursorPosition();
insertedText->insert(text);
- insertedText->setCursorPosition(para, i + text.find('(') + 1);
+ insertedText->setCursorPosition(para, i + text.tqfind('(') + 1);
}
void FunctionsDialog::showParameters()
@@ -262,7 +262,7 @@ void FunctionsDialog::showParameters()
if (i < argsCount)
{
type = slotArgs[i].remove(TQRegExp("\\*|\\&|const\\s"));
- labels[i]->setText(TQString("%1:").arg(type));
+ labels[i]->setText(TQString("%1:").tqarg(type));
}
quotes[i]->setChecked(true);
quotes[i]->setShown(false);
@@ -279,7 +279,7 @@ void FunctionsDialog::showParameters()
combos[i]->setShown(false);
edits[i]->setShown(i < argsCount);
edits[i]->clear();
- if (type == "TQString")
+ if (type == TQSTRING_OBJECT_NAME_STRING)
{
quotes[i]->setShown(i < argsCount);
}
@@ -303,7 +303,7 @@ void FunctionsDialog::showParameters()
{
labels[i]->setShown(i < argsCount);
if (i < argsCount)
- labels[i]->setText(TQString("%1:").arg(m_function.argumentName(i)));
+ labels[i]->setText(TQString("%1:").tqarg(m_function.argumentName(i)));
quotes[i]->setChecked(true);
quotes[i]->setShown(false);
if (m_function.argumentType(i) == "bool")
@@ -336,7 +336,7 @@ void FunctionsDialog::showParameters()
combos[i]->setShown(false);
edits[i]->setShown(i < argsCount);
edits[i]->clear();
- if (m_function.argumentType(i) == "TQString")
+ if (m_function.argumentType(i) == TQSTRING_OBJECT_NAME_STRING)
{
quotes[i]->setShown(i < argsCount);
}
@@ -362,8 +362,8 @@ TQString FunctionsDialog::params()
TQString s = edits[i]->text();
if (!s.isEmpty() || i < m_function.minArg())
{
- if (quotes[i]->isChecked() && ( (!slotsShown && m_function.argumentType(i) == "TQString")
- || (slotsShown && labels[i]->text().startsWith("TQString")) ) )
+ if (quotes[i]->isChecked() && ( (!slotsShown && m_function.argumentType(i) == TQSTRING_OBJECT_NAME_STRING)
+ || (slotsShown && labels[i]->text().startsWith(TQSTRING_OBJECT_NAME_STRING)) ) )
s = '"' + s + '"';
pars.append(s);
}
@@ -383,7 +383,7 @@ TQString FunctionsDialog::params()
}
TQString a_param = pars.join(", ");
if (params)
- return TQString("(%1)").arg(a_param);
+ return TQString("(%1)").tqarg(a_param);
else
return a_param;
}
diff --git a/kommander/editor/functionsimpl.h b/kommander/editor/functionsimpl.h
index 05df768f..a583f199 100644
--- a/kommander/editor/functionsimpl.h
+++ b/kommander/editor/functionsimpl.h
@@ -26,6 +26,7 @@
class FunctionsDialog : public FunctionsDialogBase
{
Q_OBJECT
+ TQ_OBJECT
public:
FunctionsDialog(TQWidget*, const TQDict<TQWidget>&, bool m_useInternalParser, char* = 0, bool = true);
~FunctionsDialog();
diff --git a/kommander/editor/globaldefs.h b/kommander/editor/globaldefs.h
index aebf63c3..45698cde 100644
--- a/kommander/editor/globaldefs.h
+++ b/kommander/editor/globaldefs.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
diff --git a/kommander/editor/hierarchyview.cpp b/kommander/editor/hierarchyview.cpp
index 57dc817c..5907b348 100644
--- a/kommander/editor/hierarchyview.cpp
+++ b/kommander/editor/hierarchyview.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000-2001 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -74,15 +74,15 @@ static const char * const folder_xpm[]={
TQListViewItem *newItem = 0;
-HierarchyItem::HierarchyItem( Type type, TQListViewItem *parent,
+HierarchyItem::HierarchyItem( Type type, TQListViewItem *tqparent,
const TQString &txt1, const TQString &txt2, const TQString &txt3 )
- : TQListViewItem( parent, txt1, txt2, txt3 ), typ( type )
+ : TQListViewItem( tqparent, txt1, txt2, txt3 ), typ( type )
{
}
-HierarchyItem::HierarchyItem( Type type, TQListView *parent,
+HierarchyItem::HierarchyItem( Type type, TQListView *tqparent,
const TQString &txt1, const TQString &txt2, const TQString &txt3 )
- : TQListViewItem( parent, txt1, txt2, txt3 ), typ( type )
+ : TQListViewItem( tqparent, txt1, txt2, txt3 ), typ( type )
{
}
@@ -90,8 +90,8 @@ void HierarchyItem::paintCell( TQPainter *p, const TQColorGroup &cg, int column,
{
TQColorGroup g( cg );
g.setColor( TQColorGroup::Base, backgroundColor() );
- g.setColor( TQColorGroup::Foreground, Qt::black );
- g.setColor( TQColorGroup::Text, Qt::black );
+ g.setColor( TQColorGroup::Foreground, TQt::black );
+ g.setColor( TQColorGroup::Text, TQt::black );
TQString txt = text( 0 );
if ( rtti() == Slot &&
( txt == "init()" || txt == "destroy()" ) ) {
@@ -177,8 +177,8 @@ void HierarchyItem::cancelRename( int col )
-HierarchyList::HierarchyList( TQWidget *parent, FormWindow *fw, bool doConnects )
- : TQListView( parent ), formWindow( fw )
+HierarchyList::HierarchyList( TQWidget *tqparent, FormWindow *fw, bool doConnects )
+ : TQListView( tqparent ), formWindow( fw )
{
init_colors();
@@ -250,21 +250,21 @@ void HierarchyList::objectClicked( TQListViewItem *i )
if ( formWindow == w ) {
if ( deselect )
formWindow->clearSelection( false );
- formWindow->emitShowProperties( formWindow );
+ formWindow->emitShowProperties( TQT_TQOBJECT(formWindow) );
return;
}
- if ( !formWindow->widgets()->find( w ) ) {
- if ( w->parent() && w->parent()->inherits( TQWIDGETSTACK_OBJECT_NAME_STRING ) &&
- w->parent()->parent() &&
- ( w->parent()->parent()->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) ||
- w->parent()->parent()->inherits( TQWIZARD_OBJECT_NAME_STRING ) ) ) {
- if ( w->parent()->parent()->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) )
- ( (TQTabWidget*)w->parent()->parent() )->showPage( w );
+ if ( !formWindow->widgets()->tqfind( w ) ) {
+ if ( w->tqparent() && w->tqparent()->inherits( TQWIDGETSTACK_OBJECT_NAME_STRING ) &&
+ w->tqparent()->tqparent() &&
+ ( w->tqparent()->tqparent()->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) ||
+ w->tqparent()->tqparent()->inherits( TQWIZARD_OBJECT_NAME_STRING ) ) ) {
+ if ( w->tqparent()->tqparent()->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) )
+ ( (TQTabWidget*)w->tqparent()->tqparent() )->showPage( w );
else
- ( (QDesignerWizard*)w->parent()->parent() )->setCurrentPage( ( (QDesignerWizard*)w->parent()->parent() )->pageNum( w ) );
- w = (TQWidget*)w->parent()->parent();
- formWindow->emitUpdateProperties( formWindow->currentWidget() );
+ ( (TQDesignerWizard*)w->tqparent()->tqparent() )->setCurrentPage( ( (TQDesignerWizard*)w->tqparent()->tqparent() )->pageNum( w ) );
+ w = (TQWidget*)w->tqparent()->tqparent();
+ formWindow->emitUpdateProperties( TQT_TQOBJECT(formWindow->currentWidget()) );
} else {
return;
}
@@ -273,7 +273,7 @@ void HierarchyList::objectClicked( TQListViewItem *i )
if ( deselect )
formWindow->clearSelection( false );
if ( w->isVisibleTo( formWindow ) )
- formWindow->selectWidget( w, true );
+ formWindow->selectWidget( TQT_TQOBJECT(w), true );
}
TQWidget *HierarchyList::findWidget( TQListViewItem *i )
@@ -310,7 +310,7 @@ void HierarchyList::changeNameOf( TQWidget *w, const TQString &name )
void HierarchyList::changeDatabaseOf( TQWidget *w, const TQString & info )
{
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
if ( !formWindow->isDatabaseAware() )
return;
TQListViewItem *item = findItem( w );
@@ -329,7 +329,7 @@ void HierarchyList::setup()
return;
clear();
TQWidget *w = formWindow->mainContainer();
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
if ( formWindow->isDatabaseAware() ) {
if ( columns() == 2 ) {
addColumn( i18n("Database" ) );
@@ -345,7 +345,7 @@ void HierarchyList::setup()
}
#endif
if ( w )
- insertObject( w, 0 );
+ insertObject( TQT_TQOBJECT(w), 0 );
}
void HierarchyList::setOpen( TQListViewItem *i, bool b )
@@ -353,11 +353,11 @@ void HierarchyList::setOpen( TQListViewItem *i, bool b )
TQListView::setOpen( i, b );
}
-void HierarchyList::insertObject( TQObject *o, TQListViewItem *parent )
+void HierarchyList::insertObject( TQObject *o, TQListViewItem *tqparent )
{
bool fakeMainWindow = false;
if ( o && o->inherits( TQMAINWINDOW_OBJECT_NAME_STRING ) ) {
- TQObject *cw = ( (TQMainWindow*)o )->centralWidget();
+ TQObject *cw = TQT_TQOBJECT(( (TQMainWindow*)o )->centralWidget());
if ( cw ) {
o = cw;
fakeMainWindow = true;
@@ -366,7 +366,7 @@ void HierarchyList::insertObject( TQObject *o, TQListViewItem *parent )
TQListViewItem *item = 0;
TQString className = WidgetFactory::classNameOf( o );
if ( o->inherits( TQLAYOUTWIDGET_OBJECT_NAME_STRING ) ) {
- switch ( WidgetFactory::layoutType( (TQWidget*)o ) ) {
+ switch ( WidgetFactory::tqlayoutType( (TQWidget*)o ) ) {
case WidgetFactory::HBox:
className = "HBox";
break;
@@ -382,79 +382,79 @@ void HierarchyList::insertObject( TQObject *o, TQListViewItem *parent )
}
TQString dbInfo;
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
dbInfo = MetaDataBase::fakeProperty( o, "database" ).toStringList().join(".");
#endif
TQString name = o->name();
- if ( o->parent() && o->parent()->inherits( TQWIDGETSTACK_OBJECT_NAME_STRING ) &&
- o->parent()->parent() ) {
- if ( o->parent()->parent()->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) )
- name = ( (TQTabWidget*)o->parent()->parent() )->tabLabel( (TQWidget*)o );
- else if ( o->parent()->parent()->inherits( TQWIZARD_OBJECT_NAME_STRING ) )
- name = ( (TQWizard*)o->parent()->parent() )->title( (TQWidget*)o );
+ if ( o->tqparent() && o->tqparent()->inherits( TQWIDGETSTACK_OBJECT_NAME_STRING ) &&
+ o->tqparent()->tqparent() ) {
+ if ( o->tqparent()->tqparent()->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) )
+ name = ( (TQTabWidget*)o->tqparent()->tqparent() )->tabLabel( (TQWidget*)o );
+ else if ( o->tqparent()->tqparent()->inherits( TQWIZARD_OBJECT_NAME_STRING ) )
+ name = ( (TQWizard*)o->tqparent()->tqparent() )->title( (TQWidget*)o );
}
TQToolBox *tb;
- if ( o->parent() && o->parent()->parent() &&
- (tb = ::qt_cast<TQToolBox*>(o->parent()->parent()->parent())) )
+ if ( o->tqparent() && o->tqparent()->tqparent() &&
+ (tb = ::tqqt_cast<TQToolBox*>(o->tqparent()->tqparent()->tqparent())) )
name = tb->itemLabel( tb->indexOf((TQWidget*)o) );
if ( fakeMainWindow ) {
- name = o->parent()->name();
+ name = o->tqparent()->name();
className = TQMAINWINDOW_OBJECT_NAME_STRING;
}
- if ( !parent )
+ if ( !tqparent )
item = new HierarchyItem( HierarchyItem::Widget, this, name, className, dbInfo );
else
- item = new HierarchyItem( HierarchyItem::Widget, parent, name, className, dbInfo );
- if ( !parent )
+ item = new HierarchyItem( HierarchyItem::Widget, tqparent, name, className, dbInfo );
+ if ( !tqparent )
item->setPixmap( 0, PixmapChooser::loadPixmap( "form.xpm", PixmapChooser::Mini ) );
- else if ( o->inherits( "QLayoutWidget") )
- item->setPixmap( 0, PixmapChooser::loadPixmap( "layout.xpm", PixmapChooser::Small ) );
+ else if ( o->inherits( TQLAYOUTWIDGET_OBJECT_NAME_STRING) )
+ item->setPixmap( 0, PixmapChooser::loadPixmap( "tqlayout.xpm", PixmapChooser::Small ) );
else
item->setPixmap( 0, WidgetDatabase::iconSet( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( o ) ) ).
pixmap( TQIconSet::Small, TQIconSet::Normal ) );
( (HierarchyItem*)item )->setWidget( (TQWidget*)o );
- const TQObjectList *l = o->children();
- if ( !l )
+ const TQObjectList l = o->childrenListObject();
+ if ( l.isEmpty() )
return;
- TQObjectListIt it( *l );
+ TQObjectListIt it( l );
it.toLast();
for ( ; it.current(); --it ) {
if ( !it.current()->isWidgetType() || ( (TQWidget*)it.current() )->isHidden() )
continue;
- if ( !formWindow->widgets()->find( (TQWidget*)it.current() ) ) {
- if ( it.current()->parent() &&
- ( it.current()->parent()->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) ||
- it.current()->parent()->inherits( TQWIZARD_OBJECT_NAME_STRING ) ) &&
+ if ( !formWindow->widgets()->tqfind( (TQWidget*)it.current() ) ) {
+ if ( it.current()->tqparent() &&
+ ( it.current()->tqparent()->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) ||
+ it.current()->tqparent()->inherits( TQWIZARD_OBJECT_NAME_STRING ) ) &&
it.current()->inherits( TQWIDGETSTACK_OBJECT_NAME_STRING ) ) {
TQObject *obj = it.current();
TQObjectList *l2 = obj->queryList( TQWIDGET_OBJECT_NAME_STRING, 0, true, false );
- QDesignerTabWidget *tw = 0;
- QDesignerWizard *dw = 0;
- if ( it.current()->parent()->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) )
- tw = (QDesignerTabWidget*)it.current()->parent();
- if ( it.current()->parent()->inherits( TQWIZARD_OBJECT_NAME_STRING ) )
- dw = (QDesignerWizard*)it.current()->parent();
+ TQDesignerTabWidget *tw = 0;
+ TQDesignerWizard *dw = 0;
+ if ( it.current()->tqparent()->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) )
+ tw = (TQDesignerTabWidget*)it.current()->tqparent();
+ if ( it.current()->tqparent()->inherits( TQWIZARD_OBJECT_NAME_STRING ) )
+ dw = (TQDesignerWizard*)it.current()->tqparent();
TQWidgetStack *stack = (TQWidgetStack*)obj;
for ( obj = l2->last(); obj; obj = l2->prev() ) {
- if ( qstrcmp( obj->className(), "QWidgetStackPrivate::Invisible" ) == 0 ||
+ if ( qstrcmp( obj->className(), "TQWidgetStackPrivate::Invisible" ) == 0 ||
( tw && !tw->tabBar()->tab( stack->id( (TQWidget*)obj ) ) ) ||
( dw && dw->isPageRemoved( (TQWidget*)obj ) ) )
continue;
insertObject( obj, item );
}
delete l2;
- } else if ( ::qt_cast<TQToolBox*>(it.current()->parent()) ) {
- if ( !::qt_cast<TQScrollView*>(it.current()) )
+ } else if ( ::tqqt_cast<TQToolBox*>(it.current()->tqparent()) ) {
+ if ( !::tqqt_cast<TQScrollView*>(it.current()) )
continue;
- TQToolBox *tb = (TQToolBox*)it.current()->parent();
+ TQToolBox *tb = (TQToolBox*)it.current()->tqparent();
for ( int i = tb->count() - 1; i >= 0; --i )
- insertObject( tb->item( i ), item );
+ insertObject( TQT_TQOBJECT(tb->item( i )), item );
}
continue;
}
@@ -491,7 +491,7 @@ void HierarchyList::showRMBMenu( TQListViewItem *i, const TQPoint & p )
return;
if ( w != formWindow &&
- !formWindow->widgets()->find( w ) )
+ !formWindow->widgets()->tqfind( w ) )
return;
if ( w->isVisibleTo( formWindow ) ) {
@@ -516,13 +516,13 @@ void HierarchyList::addTabPage()
return;
if ( w->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) ) {
TQTabWidget *tw = (TQTabWidget*)w;
- AddTabPageCommand *cmd = new AddTabPageCommand( i18n("Add Page to %1" ).arg( tw->name() ), formWindow,
+ AddTabPageCommand *cmd = new AddTabPageCommand( i18n("Add Page to %1" ).tqarg( tw->name() ), formWindow,
tw, "Tab" );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
} else if ( w->inherits( TQWIZARD_OBJECT_NAME_STRING ) ) {
TQWizard *wiz = (TQWizard*)formWindow->mainContainer();
- AddWizardPageCommand *cmd = new AddWizardPageCommand( i18n("Add Page to %1" ).arg( wiz->name() ), formWindow,
+ AddWizardPageCommand *cmd = new AddWizardPageCommand( i18n("Add Page to %1" ).tqarg( wiz->name() ), formWindow,
wiz, "Page" );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
@@ -537,9 +537,9 @@ void HierarchyList::removeTabPage()
if ( w->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) ) {
TQTabWidget *tw = (TQTabWidget*)w;
if ( tw->currentPage() ) {
- QDesignerTabWidget *dtw = (QDesignerTabWidget*)tw;
+ TQDesignerTabWidget *dtw = (TQDesignerTabWidget*)tw;
DeleteTabPageCommand *cmd = new DeleteTabPageCommand( i18n("Delete Page %1 of %2" ).
- arg( dtw->pageTitle() ).arg( tw->name() ),
+ tqarg( dtw->pageTitle() ).tqarg( tw->name() ),
formWindow, tw, tw->currentPage() );
formWindow->commandHistory()->addCommand( cmd );
cmd->execute();
@@ -547,9 +547,9 @@ void HierarchyList::removeTabPage()
} else if ( w->inherits( TQWIZARD_OBJECT_NAME_STRING ) ) {
TQWizard *wiz = (TQWizard*)formWindow->mainContainer();
if ( wiz->currentPage() ) {
- QDesignerWizard *dw = (QDesignerWizard*)wiz;
+ TQDesignerWizard *dw = (TQDesignerWizard*)wiz;
DeleteWizardPageCommand *cmd = new DeleteWizardPageCommand( i18n("Delete Page %1 of %2" ).
- arg( dw->pageTitle() ).arg( wiz->name() ),
+ tqarg( dw->pageTitle() ).tqarg( wiz->name() ),
formWindow, wiz,
wiz->indexOf( wiz->currentPage() ), true );
formWindow->commandHistory()->addCommand( cmd );
@@ -587,19 +587,19 @@ static HierarchyItem::Type getChildType( int type )
void HierarchyList::insertEntry( TQListViewItem *i, const TQPixmap &pix, const TQString &s )
{
HierarchyItem *item = new HierarchyItem( getChildType( i->rtti() ), i, s,
- TQString::null, TQString::null );
+ TQString(), TQString() );
if ( !pix.isNull() )
item->setPixmap( 0, pix );
item->setRenameEnabled( 0, true );
setCurrentItem( item );
ensureItemVisible( item );
- qApp->processEvents();
+ tqApp->processEvents();
newItem = item;
item->startRename( 0 );
}
-HierarchyView::HierarchyView( TQWidget *parent )
- : TQTabWidget( parent, 0, WStyle_Customize | WStyle_NormalBorder | WStyle_Title |
+HierarchyView::HierarchyView( TQWidget *tqparent )
+ : TQTabWidget( tqparent, 0, WStyle_Customize | WStyle_NormalBorder | WStyle_Title |
WStyle_Tool |WStyle_MinMax | WStyle_SysMenu )
{
formwindow = 0;
@@ -685,7 +685,7 @@ void HierarchyView::namePropertyChanged( TQWidget *w, const TQVariant & )
void HierarchyView::databasePropertyChanged( TQWidget *w, const TQStringList& info )
{
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
TQString i = info.join( "." );
listview->changeDatabaseOf( w, i );
#else
diff --git a/kommander/editor/hierarchyview.h b/kommander/editor/hierarchyview.h
index 8e833962..f3f1fc91 100644
--- a/kommander/editor/hierarchyview.h
+++ b/kommander/editor/hierarchyview.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -25,7 +25,7 @@
#include <tqlistview.h>
#include <tqtabwidget.h>
#include <tqguardedptr.h>
-#include <private/qcom_p.h>
+#include <private/tqcom_p.h>
class FormWindow;
class TQCloseEvent;
@@ -35,7 +35,7 @@ class TQMouseEvent;
class TQWizard;
class TQToolBox;
-class HierarchyItem:public QListViewItem
+class HierarchyItem:public TQListViewItem
{
public:
enum Type
@@ -52,9 +52,9 @@ public:
EventFunction
};
- HierarchyItem(Type type, TQListViewItem * parent,
+ HierarchyItem(Type type, TQListViewItem * tqparent,
const TQString & txt1, const TQString & txt2, const TQString & txt3);
- HierarchyItem(Type type, TQListView * parent,
+ HierarchyItem(Type type, TQListView * tqparent,
const TQString & txt1, const TQString & txt2, const TQString & txt3);
void paintCell(TQPainter * p, const TQColorGroup & cg, int column, int width, int align);
@@ -77,11 +77,12 @@ private:
Type typ;
};
-class HierarchyList:public QListView
+class HierarchyList:public TQListView
{
- Q_OBJECT
+ Q_OBJECT
+ TQ_OBJECT
public:
- HierarchyList(TQWidget * parent, FormWindow * fw, bool doConnects = TRUE);
+ HierarchyList(TQWidget * tqparent, FormWindow * fw, bool doConnects = TRUE);
virtual void setup();
virtual void setCurrent(TQWidget * w);
@@ -93,7 +94,7 @@ public:
{ setUpdatesEnabled(FALSE); triggerUpdate(); setUpdatesEnabled(TRUE);
TQListView::drawContentsOffset(p, ox, oy, cx, cy, cw, ch); }
void insertEntry(TQListViewItem * i, const TQPixmap & pix = TQPixmap(), const TQString & s =
- TQString::null);
+ TQString());
protected:
void keyPressEvent(TQKeyEvent * e);
@@ -106,7 +107,7 @@ public slots:
void removeTabPage();
private:
- void insertObject(TQObject * o, TQListViewItem * parent);
+ void insertObject(TQObject * o, TQListViewItem * tqparent);
TQWidget *findWidget(TQListViewItem * i);
TQListViewItem *findItem(TQWidget * w);
TQWidget *current() const;
@@ -120,12 +121,13 @@ protected:
bool deselect;
};
-class HierarchyView : public QTabWidget
+class HierarchyView : public TQTabWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- HierarchyView( TQWidget *parent );
+ HierarchyView( TQWidget *tqparent );
~HierarchyView();
void setFormWindow( FormWindow *fw, TQWidget *w );
diff --git a/kommander/editor/iconvieweditor.ui b/kommander/editor/iconvieweditor.ui
index afa18459..26d1aa8b 100644
--- a/kommander/editor/iconvieweditor.ui
+++ b/kommander/editor/iconvieweditor.ui
@@ -19,7 +19,7 @@
** not clear to you.
**
*********************************************************************</comment>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>IconViewEditorBase</cstring>
</property>
@@ -50,7 +50,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout6</cstring>
</property>
@@ -64,7 +64,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QIconView">
+ <widget class="TQIconView">
<property name="name">
<cstring>preview</cstring>
</property>
@@ -72,7 +72,7 @@
<string>All items in the iconview.</string>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout5</cstring>
</property>
@@ -86,7 +86,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>itemNew</cstring>
</property>
@@ -100,7 +100,7 @@
<string>Create a new item for the iconview.</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>itemDelete</cstring>
</property>
@@ -124,7 +124,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
@@ -133,7 +133,7 @@
</spacer>
</vbox>
</widget>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>GroupBox1</cstring>
</property>
@@ -156,7 +156,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>Label1</cstring>
</property>
@@ -167,11 +167,11 @@
<cstring>itemText</cstring>
</property>
</widget>
- <widget class="QLineEdit" row="0" column="1">
+ <widget class="TQLineEdit" row="0" column="1">
<property name="name">
<cstring>itemText</cstring>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>0</width>
<height>0</height>
@@ -184,7 +184,7 @@
<string>Change the text for the selected item.</string>
</property>
</widget>
- <widget class="QLabel" row="1" column="0">
+ <widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>Label2</cstring>
</property>
@@ -195,7 +195,7 @@
<cstring>itemChoosePixmap</cstring>
</property>
</widget>
- <widget class="QLayoutWidget" row="1" column="1">
+ <widget class="TQLayoutWidget" row="1" column="1">
<property name="name">
<cstring>Layout4</cstring>
</property>
@@ -209,7 +209,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>itemPixmap</cstring>
</property>
@@ -217,11 +217,11 @@
<string>Label4</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>itemDeletePixmap</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>30</width>
<height>22</height>
@@ -240,11 +240,11 @@
<string>Delete the selected item's pixmap.</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>itemChoosePixmap</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>30</width>
<height>22</height>
@@ -266,7 +266,7 @@
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -280,7 +280,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonHelp</cstring>
</property>
@@ -301,14 +301,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonOk</cstring>
</property>
@@ -325,7 +325,7 @@
<string>Close the dialog and apply all the changes.</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonApply</cstring>
</property>
@@ -339,7 +339,7 @@
<string>Apply all changes.</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonCancel</cstring>
</property>
@@ -407,15 +407,15 @@
</connection>
<connection>
<sender>preview</sender>
- <signal>selectionChanged(QIconViewItem*)</signal>
+ <signal>selectionChanged(TQIconViewItem*)</signal>
<receiver>IconViewEditorBase</receiver>
- <slot>currentItemChanged(QIconViewItem*)</slot>
+ <slot>currentItemChanged(TQIconViewItem*)</slot>
</connection>
<connection>
<sender>preview</sender>
- <signal>currentChanged(QIconViewItem*)</signal>
+ <signal>currentChanged(TQIconViewItem*)</signal>
<receiver>IconViewEditorBase</receiver>
- <slot>currentItemChanged(QIconViewItem*)</slot>
+ <slot>currentItemChanged(TQIconViewItem*)</slot>
</connection>
<connection>
<sender>itemDeletePixmap</sender>
@@ -428,7 +428,7 @@
<slot access="protected" language="C++" returnType="void">applyClicked()</slot>
<slot access="protected" language="C++" returnType="void">cancelClicked()</slot>
<slot access="protected" language="C++" returnType="void">choosePixmap()</slot>
- <slot access="protected" language="C++" returnType="void">currentItemChanged( QIconViewItem * )</slot>
+ <slot access="protected" language="C++" returnType="void">currentItemChanged( TQIconViewItem * )</slot>
<slot access="protected" language="C++" returnType="void">currentTextChanged( const QString &amp; )</slot>
<slot access="protected" language="C++" returnType="void">deleteCurrentItem()</slot>
<slot access="protected" language="C++" returnType="void">insertNewItem()</slot>
diff --git a/kommander/editor/iconvieweditorimpl.cpp b/kommander/editor/iconvieweditorimpl.cpp
index 9bff67ae..549e5c96 100644
--- a/kommander/editor/iconvieweditorimpl.cpp
+++ b/kommander/editor/iconvieweditorimpl.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -31,8 +31,8 @@
#include <klocale.h>
-IconViewEditor::IconViewEditor( TQWidget *parent, TQWidget *editWidget, FormWindow *fw )
- : IconViewEditorBase( parent, 0, true ), formwindow( fw )
+IconViewEditor::IconViewEditor( TQWidget *tqparent, TQWidget *editWidget, FormWindow *fw )
+ : IconViewEditorBase( tqparent, 0, true ), formwindow( fw )
{
connect( buttonHelp, TQT_SIGNAL( clicked() ), MainWindow::self, TQT_SLOT( showDialogHelp() ) );
iconview = (TQIconView*)editWidget;
@@ -121,7 +121,7 @@ void IconViewEditor::applyClicked()
items.append( item );
}
- PopulateIconViewCommand *cmd = new PopulateIconViewCommand( i18n("Edit Items of '%1'" ).arg( iconview->name() ),
+ PopulateIconViewCommand *cmd = new PopulateIconViewCommand( i18n("Edit Items of '%1'" ).tqarg( iconview->name() ),
formwindow, iconview, items );
cmd->execute();
formwindow->commandHistory()->addCommand( cmd );
diff --git a/kommander/editor/iconvieweditorimpl.h b/kommander/editor/iconvieweditorimpl.h
index ffde0403..4e3972ff 100644
--- a/kommander/editor/iconvieweditorimpl.h
+++ b/kommander/editor/iconvieweditorimpl.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -28,9 +28,10 @@ class FormWindow;
class IconViewEditor : public IconViewEditorBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- IconViewEditor( TQWidget *parent, TQWidget *editWidget, FormWindow *fw );
+ IconViewEditor( TQWidget *tqparent, TQWidget *editWidget, FormWindow *fw );
protected slots:
void insertNewItem();
diff --git a/kommander/editor/kommander-new.xml b/kommander/editor/kommander-new.xml
index deb3d88a..8cfe86e2 100644
--- a/kommander/editor/kommander-new.xml
+++ b/kommander/editor/kommander-new.xml
@@ -25,7 +25,7 @@
<item>cellText</item>
<item>clear</item>
<item>checked</item>
- <item>children</item>
+ <item>tqchildren</item>
<item>columnCount</item>
<item>count</item>
<item>currentColumn</item>
@@ -33,7 +33,7 @@
<item>currentRow</item>
<item>execute</item>
<item>findItem</item>
- <item>geometry</item>
+ <item>tqgeometry</item>
<item>global</item>
<item>hasFocus</item>
<item>insertColumn</item>
@@ -76,7 +76,7 @@
<item>null</item>
<item>pid</item>
<item>dcopid</item>
- <item>parentPid</item>
+ <item>tqparentPid</item>
<item>debug</item>
<item>echo</item>
<item>env</item>
@@ -140,14 +140,14 @@
<list name="kmdrstring">
<item>str_length</item>
- <item>str_contains</item>
- <item>str_find</item>
- <item>str_findRev</item>
+ <item>str_tqcontains</item>
+ <item>str_tqfind</item>
+ <item>str_tqfindRev</item>
<item>str_left</item>
<item>str_right</item>
<item>str_mid</item>
<item>str_remove</item>
- <item>str_replace</item>
+ <item>str_tqreplace</item>
<item>str_upper</item>
<item>str_lower</item>
<item>str_compare</item>
@@ -260,7 +260,7 @@
<!-- FindCommands matches many items that can be expected outside strings, substitutions etc. -->
<context attribute="Normal Text" lineEndContext="#stay" name="FindCommands">
- <!-- start expression in double parentheses -->
+ <!-- start expression in double tqparentheses -->
<Detect2Chars attribute="Keyword" context="ExprDblParen" char="(" char1="(" beginRegion="expression" />
<!-- start expression in double brackets -->
<RegExpr attribute="Keyword" context="ExprDblBracket" String="\[\[&eos;" beginRegion="expression" column="0"/>
@@ -524,7 +524,7 @@
</context>
<!-- Case is called after the case keyword is encoutered. We handle this because of
- the lonely closing parentheses that would otherwise disturb the expr matching -->
+ the lonely closing tqparentheses that would otherwise disturb the expr matching -->
<context attribute="Normal Text" lineEndContext="#stay" name="Case">
<RegExpr attribute="Keyword" context="CaseIn" String="\sin\b" />
<IncludeRules context="FindAll" />
diff --git a/kommander/editor/kommander.xml b/kommander/editor/kommander.xml
index f5880b2f..cfa64c8a 100644
--- a/kommander/editor/kommander.xml
+++ b/kommander/editor/kommander.xml
@@ -25,14 +25,14 @@
<item>cellText</item>
<item>clear</item>
<item>checked</item>
- <item>children</item>
+ <item>tqchildren</item>
<item>count</item>
<item>currentColumn</item>
<item>currentItem</item>
<item>currentRow</item>
<item>execute</item>
<item>findItem</item>
- <item>geometry</item>
+ <item>tqgeometry</item>
<item>global</item>
<item>hasFocus</item>
<item>insertColumn</item>
@@ -69,7 +69,7 @@
<item>null</item>
<item>pid</item>
<item>dcopid</item>
- <item>parentPid</item>
+ <item>tqparentPid</item>
<item>debug</item>
<item>echo</item>
<item>env</item>
@@ -104,14 +104,14 @@
<list name="kmdrstring">
<item>length</item>
- <item>contains</item>
- <item>find</item>
- <item>findRev</item>
+ <item>tqcontains</item>
+ <item>tqfind</item>
+ <item>tqfindRev</item>
<item>left</item>
<item>right</item>
<item>mid</item>
<item>remove</item>
- <item>replace</item>
+ <item>tqreplace</item>
<item>upper</item>
<item>lower</item>
<item>compare</item>
@@ -341,8 +341,8 @@
<item> true </item>
<item> umount </item>
<item> uname </item>
- <item> unicode_start </item>
- <item> unicode_stop </item>
+ <item> tqunicode_start </item>
+ <item> tqunicode_stop </item>
<item> unlink </item>
<item> utmpdump </item>
<item> uuidgen </item>
@@ -418,7 +418,7 @@
<item> expr </item>
<item> fbset </item>
<item> file </item>
- <item> find </item>
+ <item> tqfind </item>
<item> flex </item>
<item> flex++ </item>
<item> fmt </item>
@@ -598,7 +598,7 @@
<IncludeRules context="##Alerts" />
</context>
- <!-- FindCommentsParen consumes shell comments till EOL or a closing parenthese -->
+ <!-- FindCommentsParen consumes shell comments till EOL or a closing tqparenthese -->
<context attribute="Normal Text" lineEndContext="#pop" name="FindCommentsParen">
<DetectChar attribute="Comment" context="CommentParen" char="#" firstNonSpace="true"/>
<RegExpr attribute="Normal Text" context="CommentParen" String="[\s;](?=#)" />
@@ -621,7 +621,7 @@
<!-- FindCommands matches many items that can be expected outside strings, substitutions etc. -->
<context attribute="Normal Text" lineEndContext="#stay" name="FindCommands">
- <!-- start expression in double parentheses -->
+ <!-- start expression in double tqparentheses -->
<Detect2Chars attribute="Keyword" context="ExprDblParen" char="(" char1="(" beginRegion="expression" />
<!-- start expression in double brackets -->
<RegExpr attribute="Keyword" context="ExprDblBracket" String="\[\[&eos;" beginRegion="expression" column="0"/>
@@ -900,7 +900,7 @@
</context>
<!-- Case is called after the case keyword is encoutered. We handle this because of
- the lonely closing parentheses that would otherwise disturb the expr matching -->
+ the lonely closing tqparentheses that would otherwise disturb the expr matching -->
<context attribute="Normal Text" lineEndContext="#stay" name="Case">
<RegExpr attribute="Keyword" context="CaseIn" String="\sin\b" />
<IncludeRules context="FindMost" />
diff --git a/kommander/editor/layout.cpp b/kommander/editor/layout.cpp
index 7860aeae..998b4fce 100644
--- a/kommander/editor/layout.cpp
+++ b/kommander/editor/layout.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -19,11 +19,11 @@
**********************************************************************/
#include "formwindow.h"
-#include "layout.h"
+#include "tqlayout.h"
#include "widgetdatabase.h"
#include "widgetfactory.h"
-#include <tqlayout.h>
+#include <layout.h>
#include <tqevent.h>
#include <tqpainter.h>
#include <tqpen.h>
@@ -36,34 +36,34 @@ bool operator<( const TQGuardedPtr<TQWidget> &p1, const TQGuardedPtr<TQWidget> &
}
/*!
- \class Layout layout.h
- \brief Baseclass for layouting widgets in the Designer
+ \class Layout tqlayout.h
+ \brief Baseclass for tqlayouting widgets in the Designer
- Classes derived from this abstract base class are used for layouting
+ Classes derived from this abstract base class are used for tqlayouting
operations in the Designer.
*/
-/*! \a p specifies the parent of the layoutBase \a lb. The parent
- might be changed in setup(). If the layoutBase is a
- container, the parent and the layoutBase are the same. Also they
+/*! \a p specifies the tqparent of the tqlayoutBase \a lb. The tqparent
+ might be changed in setup(). If the tqlayoutBase is a
+ container, the tqparent and the tqlayoutBase are the same. Also they
always have to be a widget known to the designer (e.g. in the case
- of the tabwidget parent and layoutBase are the tabwidget and not the
+ of the tabwidget tqparent and tqlayoutBase are the tabwidget and not the
page which actually gets laid out. For actual usage the correct
widget is found later by Layout.)
*/
Layout::Layout( const TQWidgetList &wl, TQWidget *p, FormWindow *fw, TQWidget *lb, bool doSetup, bool splitter )
- : widgets( wl ), parent( p ), formWindow( fw ), isBreak( !doSetup ), useSplitter( splitter )
+ : widgets( wl ), tqparent( p ), formWindow( fw ), isBreak( !doSetup ), useSplitter( splitter )
{
widgets.setAutoDelete( false );
- layoutBase = lb;
- if ( !doSetup && layoutBase )
- oldGeometry = layoutBase->geometry();
+ tqlayoutBase = lb;
+ if ( !doSetup && tqlayoutBase )
+ oldGeometry = tqlayoutBase->tqgeometry();
}
/*! The widget list we got in the constructor might contain too much
- widgets (like widgets with different parents, already laid out
+ widgets (like widgets with different tqparents, already laid out
widgets, etc.). Here we set up the list and so the only the "best"
widgets get laid out.
*/
@@ -77,20 +77,20 @@ void Layout::setup()
TQWidget *w = 0;
// Go through all widgets of the list we got. As we can only
- // layout widgets which have the same parent, we first do some
- // sorting which means create a list for each parent containing
+ // tqlayout widgets which have the same tqparent, we first do some
+ // sorting which means create a list for each tqparent containing
// its child here. After that we keep working on the list of
// childs which has the most entries.
// Widgets which are already laid out are thrown away here too
for ( w = widgets.first(); w; w = widgets.next() ) {
- if ( w->parentWidget() && WidgetFactory::layoutType( w->parentWidget() ) != WidgetFactory::NoLayout )
+ if ( w->tqparentWidget() && WidgetFactory::tqlayoutType( w->tqparentWidget() ) != WidgetFactory::NoLayout )
continue;
- if ( lastParent != w->parentWidget() ) {
+ if ( lastParent != w->tqparentWidget() ) {
lastList = 0;
- lastParent = w->parentWidget();
+ lastParent = w->tqparentWidget();
TQValueList<TQWidgetList>::Iterator it = lists.begin();
for ( ; it != lists.end(); ++it ) {
- if ( ( *it ).first()->parentWidget() == w->parentWidget() )
+ if ( ( *it ).first()->tqparentWidget() == w->tqparentWidget() )
lastList = &( *it );
}
if ( !lastList ) {
@@ -112,12 +112,12 @@ void Layout::setup()
}
// If we found no list (because no widget did fit at all) or the
- // best list has only one entry and we do not layout a container,
+ // best list has only one entry and we do not tqlayout a container,
// we leave here.
if ( !lastList || ( lastList->count() < 2 &&
- ( !layoutBase ||
- ( !WidgetDatabase::isContainer( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( layoutBase ) ) ) &&
- layoutBase != formWindow->mainContainer() ) )
+ ( !tqlayoutBase ||
+ ( !WidgetDatabase::isContainer( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf(TQT_TQOBJECT( tqlayoutBase )) ) ) &&
+ tqlayoutBase != formWindow->mainContainer() ) )
) ) {
widgets.clear();
startPoint = TQPoint( 0, 0 );
@@ -125,23 +125,23 @@ void Layout::setup()
}
// Now we have a new and clean widget list, which makes sense
- // to layout
+ // to tqlayout
widgets = *lastList;
- // Also use the only correct parent later, so store it
- parent = WidgetFactory::widgetOfContainer( widgets.first()->parentWidget() );
- // Now calculate the position where the layout-meta-widget should
+ // Also use the only correct tqparent later, so store it
+ tqparent = WidgetFactory::widgetOfContainer( widgets.first()->tqparentWidget() );
+ // Now calculate the position where the tqlayout-meta-widget should
// be placed and connect to widgetDestroyed() signals of the
// widgets to get informed if one gets deleted to be able to
// handle that and do not crash in this case
for ( w = widgets.first(); w; w = widgets.next() ) {
connect( w, TQT_SIGNAL( destroyed() ),
this, TQT_SLOT( widgetDestroyed() ) );
- startPoint = TQPoint( QMIN( startPoint.x(), w->x() ),
- QMIN( startPoint.y(), w->y() ) );
+ startPoint = TQPoint( TQMIN( startPoint.x(), w->x() ),
+ TQMIN( startPoint.y(), w->y() ) );
geometries.insert( w, TQRect( w->pos(), w->size() ) );
// Change the Z-order, as saving/loading uses the Z-order for
// writing/creating widgets and this has to be the same as in
- // the layout. Else saving + loading will give different results
+ // the tqlayout. Else saving + loading will give different results
w->raise();
}
}
@@ -152,46 +152,46 @@ void Layout::widgetDestroyed()
widgets.removeRef( (TQWidget*)sender() );
}
-bool Layout::prepareLayout( bool &needMove, bool &needReparent )
+bool Layout::prepareLayout( bool &needMove, bool &needRetqparent )
{
if ( !widgets.count() )
return false;
for ( TQWidget *w = widgets.first(); w; w = widgets.next() )
w->raise();
- needMove = !layoutBase;
- needReparent = needMove || layoutBase->inherits( "QLayoutWidget" ) || layoutBase->inherits( TQSPLITTER_OBJECT_NAME_STRING );
- if ( !layoutBase ) {
+ needMove = !tqlayoutBase;
+ needRetqparent = needMove || tqlayoutBase->inherits( TQLAYOUTWIDGET_OBJECT_NAME_STRING ) || tqlayoutBase->inherits( TQSPLITTER_OBJECT_NAME_STRING );
+ if ( !tqlayoutBase ) {
if ( !useSplitter )
- layoutBase = WidgetFactory::create( WidgetDatabase::idFromClassName( "QLayoutWidget" ),
- WidgetFactory::containerOfWidget( parent ) );
+ tqlayoutBase = WidgetFactory::create( WidgetDatabase::idFromClassName( TQLAYOUTWIDGET_OBJECT_NAME_STRING ),
+ WidgetFactory::containerOfWidget( tqparent ) );
else
- layoutBase = WidgetFactory::create( WidgetDatabase::idFromClassName( TQSPLITTER_OBJECT_NAME_STRING ),
- WidgetFactory::containerOfWidget( parent ) );
+ tqlayoutBase = WidgetFactory::create( WidgetDatabase::idFromClassName( TQSPLITTER_OBJECT_NAME_STRING ),
+ WidgetFactory::containerOfWidget( tqparent ) );
} else {
- WidgetFactory::deleteLayout( layoutBase );
+ WidgetFactory::deleteLayout( tqlayoutBase );
}
return true;
}
-void Layout::finishLayout( bool needMove, TQLayout *layout )
+void Layout::finishLayout( bool needMove, TQLayout *tqlayout )
{
if ( needMove )
- layoutBase->move( startPoint );
- TQRect g( TQRect( layoutBase->pos(), layoutBase->size() ) );
- if ( WidgetFactory::layoutType( layoutBase->parentWidget() ) == WidgetFactory::NoLayout && !isBreak )
- layoutBase->adjustSize();
+ tqlayoutBase->move( startPoint );
+ TQRect g( TQRect( tqlayoutBase->pos(), tqlayoutBase->size() ) );
+ if ( WidgetFactory::tqlayoutType( tqlayoutBase->tqparentWidget() ) == WidgetFactory::NoLayout && !isBreak )
+ tqlayoutBase->adjustSize();
else if ( isBreak )
- layoutBase->setGeometry( oldGeometry );
+ tqlayoutBase->setGeometry( oldGeometry );
oldGeometry = g;
- layoutBase->show();
- layout->activate();
- formWindow->insertWidget( layoutBase );
- formWindow->selectWidget( layoutBase );
- TQString n = layoutBase->name();
- if ( n.find( "qt_dead_widget_" ) != -1 ) {
+ tqlayoutBase->show();
+ tqlayout->activate();
+ formWindow->insertWidget( tqlayoutBase );
+ formWindow->selectWidget( TQT_TQOBJECT(tqlayoutBase) );
+ TQString n = tqlayoutBase->name();
+ if ( n.tqfind( "qt_dead_widget_" ) != -1 ) {
n.remove( 0, TQString( "qt_dead_widget_" ).length() );
- layoutBase->setName( n );
+ tqlayoutBase->setName( n );
}
}
@@ -203,23 +203,23 @@ void Layout::undoLayout()
for ( ; it != geometries.end(); ++it ) {
if ( !it.key() )
continue;
- it.key()->reparent( WidgetFactory::containerOfWidget( parent ), 0, ( *it ).topLeft(), it.key()->isVisibleTo( formWindow ) );
+ it.key()->reparent( WidgetFactory::containerOfWidget( tqparent ), 0, ( *it ).topLeft(), it.key()->isVisibleTo( formWindow ) );
it.key()->resize( ( *it ).size() );
}
- formWindow->selectWidget( layoutBase, false );
- WidgetFactory::deleteLayout( layoutBase );
- if ( parent != layoutBase && !layoutBase->inherits( TQMAINWINDOW_OBJECT_NAME_STRING ) ) {
- layoutBase->hide();
- TQString n = layoutBase->name();
+ formWindow->selectWidget( TQT_TQOBJECT(tqlayoutBase), false );
+ WidgetFactory::deleteLayout( tqlayoutBase );
+ if ( tqparent != tqlayoutBase && !tqlayoutBase->inherits( TQMAINWINDOW_OBJECT_NAME_STRING ) ) {
+ tqlayoutBase->hide();
+ TQString n = tqlayoutBase->name();
n.prepend( "qt_dead_widget_" );
- layoutBase->setName( n );
+ tqlayoutBase->setName( n );
} else {
- layoutBase->setGeometry( oldGeometry );
+ tqlayoutBase->setGeometry( oldGeometry );
}
if ( widgets.first() )
- formWindow->selectWidget( widgets.first() );
+ formWindow->selectWidget( TQT_TQOBJECT(widgets.first()) );
else
- formWindow->selectWidget( formWindow );
+ formWindow->selectWidget( TQT_TQOBJECT(formWindow) );
}
void Layout::breakLayout()
@@ -228,43 +228,43 @@ void Layout::breakLayout()
if ( !widgets.isEmpty() ) {
TQWidget *w;
for ( w = widgets.first(); w; w = widgets.next() )
- rects.insert( w, w->geometry() );
+ rects.insert( w, w->tqgeometry() );
}
- WidgetFactory::deleteLayout( layoutBase );
- bool needReparent = qstrcmp( layoutBase->className(), "QLayoutWidget" ) == 0 ||
- qstrcmp( layoutBase->className(), TQSPLITTER_OBJECT_NAME_STRING ) == 0 ||
- ( !WidgetDatabase::isContainer( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( layoutBase ) ) ) &&
- layoutBase != formWindow->mainContainer() );
- bool needResize = qstrcmp( layoutBase->className(), TQSPLITTER_OBJECT_NAME_STRING ) == 0;
+ WidgetFactory::deleteLayout( tqlayoutBase );
+ bool needRetqparent = qstrcmp( tqlayoutBase->className(), TQLAYOUTWIDGET_OBJECT_NAME_STRING ) == 0 ||
+ qstrcmp( tqlayoutBase->className(), TQSPLITTER_OBJECT_NAME_STRING ) == 0 ||
+ ( !WidgetDatabase::isContainer( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf(TQT_TQOBJECT( tqlayoutBase )) ) ) &&
+ tqlayoutBase != formWindow->mainContainer() );
+ bool needResize = qstrcmp( tqlayoutBase->className(), TQSPLITTER_OBJECT_NAME_STRING ) == 0;
bool add = geometries.isEmpty();
for ( TQWidget *w = widgets.first(); w; w = widgets.next() ) {
- if ( needReparent )
- w->reparent( layoutBase->parentWidget(), 0,
- layoutBase->pos() + w->pos(), true );
+ if ( needRetqparent )
+ w->reparent( tqlayoutBase->tqparentWidget(), 0,
+ tqlayoutBase->pos() + w->pos(), true );
if ( needResize ) {
- TQMap<TQWidget*, TQRect>::Iterator it = rects.find( w );
+ TQMap<TQWidget*, TQRect>::Iterator it = rects.tqfind( w );
if ( it != rects.end() )
- w->setGeometry( TQRect( layoutBase->pos() + (*it).topLeft(), (*it).size() ) );
+ w->setGeometry( TQRect( tqlayoutBase->pos() + (*it).topLeft(), (*it).size() ) );
}
if ( add )
geometries.insert( w, TQRect( w->pos(), w->size() ) );
}
- if ( needReparent ) {
- layoutBase->hide();
- parent = layoutBase->parentWidget();
- TQString n = layoutBase->name();
+ if ( needRetqparent ) {
+ tqlayoutBase->hide();
+ tqparent = tqlayoutBase->tqparentWidget();
+ TQString n = tqlayoutBase->name();
n.prepend( "qt_dead_widget_" );
- layoutBase->setName( n );
+ tqlayoutBase->setName( n );
} else {
- parent = layoutBase;
+ tqparent = tqlayoutBase;
}
if ( widgets.first() && widgets.first()->isVisibleTo( formWindow ) )
- formWindow->selectWidget( widgets.first() );
+ formWindow->selectWidget( TQT_TQOBJECT(widgets.first()) );
else
- formWindow->selectWidget( formWindow );
+ formWindow->selectWidget( TQT_TQOBJECT(formWindow) );
}
-class HorizontalLayoutList : public QWidgetList
+class HorizontalLayoutList : public TQWidgetList
{
public:
HorizontalLayoutList( const TQWidgetList &l )
@@ -299,36 +299,36 @@ void HorizontalLayout::setup()
void HorizontalLayout::doLayout()
{
- bool needMove, needReparent;
- if ( !prepareLayout( needMove, needReparent ) )
+ bool needMove, needRetqparent;
+ if ( !prepareLayout( needMove, needRetqparent ) )
return;
- TQHBoxLayout *layout = (TQHBoxLayout*)WidgetFactory::createLayout( layoutBase, 0, WidgetFactory::HBox );
+ TQHBoxLayout *tqlayout = (TQHBoxLayout*)WidgetFactory::createLayout( tqlayoutBase, 0, WidgetFactory::HBox );
for ( TQWidget *w = widgets.first(); w; w = widgets.next() ) {
- if ( needReparent && w->parent() != layoutBase )
- w->reparent( layoutBase, 0, TQPoint( 0, 0 ), false );
+ if ( needRetqparent && TQT_BASE_OBJECT(w->tqparent()) != TQT_BASE_OBJECT(tqlayoutBase) )
+ w->reparent( tqlayoutBase, 0, TQPoint( 0, 0 ), false );
if ( !useSplitter ) {
if ( qstrcmp( w->className(), "Spacer" ) == 0 )
- layout->addWidget( w, 0, ( (Spacer*)w )->alignment() );
+ tqlayout->addWidget( w, 0, ( (Spacer*)w )->tqalignment() );
else
- layout->addWidget( w );
- if ( w->inherits( "QLayoutWidget" ) )
- ( (QLayoutWidget*)w )->updateSizePolicy();
+ tqlayout->addWidget( w );
+ if ( w->inherits( TQLAYOUTWIDGET_OBJECT_NAME_STRING ) )
+ ( (TQLayoutWidget*)w )->updateSizePolicy();
}
w->show();
}
- if ( layoutBase->inherits( TQSPLITTER_OBJECT_NAME_STRING ) )
- ( (TQSplitter*)layoutBase )->setOrientation( Qt::Horizontal );
+ if ( tqlayoutBase->inherits( TQSPLITTER_OBJECT_NAME_STRING ) )
+ ( (TQSplitter*)tqlayoutBase )->setOrientation( Qt::Horizontal );
- finishLayout( needMove, layout );
+ finishLayout( needMove, tqlayout );
}
-class VerticalLayoutList : public QWidgetList
+class VerticalLayoutList : public TQWidgetList
{
public:
VerticalLayoutList( const TQWidgetList &l )
@@ -363,30 +363,30 @@ void VerticalLayout::setup()
void VerticalLayout::doLayout()
{
- bool needMove, needReparent;
- if ( !prepareLayout( needMove, needReparent ) )
+ bool needMove, needRetqparent;
+ if ( !prepareLayout( needMove, needRetqparent ) )
return;
- TQVBoxLayout *layout = (TQVBoxLayout*)WidgetFactory::createLayout( layoutBase, 0, WidgetFactory::VBox );
+ TQVBoxLayout *tqlayout = (TQVBoxLayout*)WidgetFactory::createLayout( tqlayoutBase, 0, WidgetFactory::VBox );
for ( TQWidget *w = widgets.first(); w; w = widgets.next() ) {
- if ( needReparent && w->parent() != layoutBase )
- w->reparent( layoutBase, 0, TQPoint( 0, 0 ), false );
+ if ( needRetqparent && TQT_BASE_OBJECT(w->tqparent()) != TQT_BASE_OBJECT(tqlayoutBase) )
+ w->reparent( tqlayoutBase, 0, TQPoint( 0, 0 ), false );
if ( !useSplitter ) {
if ( qstrcmp( w->className(), "Spacer" ) == 0 )
- layout->addWidget( w, 0, ( (Spacer*)w )->alignment() );
+ tqlayout->addWidget( w, 0, ( (Spacer*)w )->tqalignment() );
else
- layout->addWidget( w );
- if ( w->inherits( "QLayoutWidget" ) )
- ( (QLayoutWidget*)w )->updateSizePolicy();
+ tqlayout->addWidget( w );
+ if ( w->inherits( TQLAYOUTWIDGET_OBJECT_NAME_STRING ) )
+ ( (TQLayoutWidget*)w )->updateSizePolicy();
}
w->show();
}
- if ( layoutBase->inherits( TQSPLITTER_OBJECT_NAME_STRING ) )
- ( (TQSplitter*)layoutBase )->setOrientation( Qt::Vertical );
+ if ( tqlayoutBase->inherits( TQSPLITTER_OBJECT_NAME_STRING ) )
+ ( (TQSplitter*)tqlayoutBase )->setOrientation( Qt::Vertical );
- finishLayout( needMove, layout );
+ finishLayout( needMove, tqlayout );
}
@@ -729,11 +729,11 @@ GridLayout::~GridLayout()
void GridLayout::doLayout()
{
- bool needMove, needReparent;
- if ( !prepareLayout( needMove, needReparent ) )
+ bool needMove, needRetqparent;
+ if ( !prepareLayout( needMove, needRetqparent ) )
return;
- QDesignerGridLayout *layout = (QDesignerGridLayout*)WidgetFactory::createLayout( layoutBase, 0, WidgetFactory::Grid );
+ TQDesignerGridLayout *tqlayout = (TQDesignerGridLayout*)WidgetFactory::createLayout( tqlayoutBase, 0, WidgetFactory::Grid );
if ( !grid )
buildGrid();
@@ -742,21 +742,21 @@ void GridLayout::doLayout()
int r, c, rs, cs;
for ( w = widgets.first(); w; w = widgets.next() ) {
if ( grid->locateWidget( w, r, c, rs, cs) ) {
- if ( needReparent && w->parent() != layoutBase )
- w->reparent( layoutBase, 0, TQPoint( 0, 0 ), false );
+ if ( needRetqparent && TQT_BASE_OBJECT(w->tqparent()) != TQT_BASE_OBJECT(tqlayoutBase) )
+ w->reparent( tqlayoutBase, 0, TQPoint( 0, 0 ), false );
if ( rs * cs == 1 ) {
- layout->addWidget( w, r, c, w->inherits( "Spacer" ) ? ( (Spacer*)w )->alignment() : 0 );
+ tqlayout->addWidget( w, r, c, w->inherits( "Spacer" ) ? ( (Spacer*)w )->tqalignment() : 0 );
} else {
- layout->addMultiCellWidget( w, r, r+rs-1, c, c+cs-1, w->inherits( "Spacer" ) ? ( (Spacer*)w )->alignment() : 0 );
+ tqlayout->addMultiCellWidget( w, r, r+rs-1, c, c+cs-1, w->inherits( "Spacer" ) ? ( (Spacer*)w )->tqalignment() : 0 );
}
- if ( w->inherits( "QLayoutWidget" ) )
- ( (QLayoutWidget*)w )->updateSizePolicy();
+ if ( w->inherits( TQLAYOUTWIDGET_OBJECT_NAME_STRING ) )
+ ( (TQLayoutWidget*)w )->updateSizePolicy();
w->show();
} else {
- qWarning("ooops, widget '%s' does not fit in layout", w->name() );
+ qWarning("ooops, widget '%s' does not fit in tqlayout", w->name() );
}
}
- finishLayout( needMove, layout );
+ finishLayout( needMove, tqlayout );
}
void GridLayout::setup()
@@ -770,7 +770,7 @@ void GridLayout::buildGrid()
TQWidget* w;
TQRect br;
for ( w = widgets.first(); w; w = widgets.next() )
- br = br.unite( w->geometry() );
+ br = br.unite( w->tqgeometry() );
delete grid;
grid = new Grid( br.height() / resolution.height() + 1,
@@ -784,7 +784,7 @@ void GridLayout::buildGrid()
TQRect cr( p, resolution );
for ( w = widgets.first(); w; w = widgets.next() ) {
// check that the overlap is significant
- TQRect intersect = cr.intersect( w->geometry() );
+ TQRect intersect = cr.intersect( w->tqgeometry() );
if ( intersect.size().width() > resolution.width()/2 &&
intersect.size().height() > resolution.height()/2 ) {
grid->setCell( r, c, w );
@@ -801,9 +801,9 @@ void GridLayout::buildGrid()
-Spacer::Spacer( TQWidget *parent, const char *name )
- : TQWidget( parent, name, WMouseNoMask ),
- orient( Vertical ), interactive(true), sh( TQSize(20,20) )
+Spacer::Spacer( TQWidget *tqparent, const char *name )
+ : TQWidget( tqparent, name, WMouseNoMask ),
+ orient(Qt::Vertical ), interactive(true), sh( TQSize(20,20) )
{
setSizeType( Expanding );
setAutoMask( true );
@@ -812,11 +812,11 @@ Spacer::Spacer( TQWidget *parent, const char *name )
void Spacer::paintEvent( TQPaintEvent * )
{
TQPainter p( this );
- p.setPen( Qt::blue );
+ p.setPen( TQt::blue );
- if ( orient == Horizontal ) {
+ if ( orient ==Qt::Horizontal ) {
const int dist = 3;
- const int amplitude = QMIN( 3, height() / 3 );
+ const int amplitude = TQMIN( 3, height() / 3 );
const int base = height() / 2;
int i = 0;
p.setPen( white );
@@ -829,7 +829,7 @@ void Spacer::paintEvent( TQPaintEvent * )
p.drawLine( width() - 1, 0, width() - 1, height());
} else {
const int dist = 3;
- const int amplitude = QMIN( 3, width() / 3 );
+ const int amplitude = TQMIN( 3, width() / 3 );
const int base = width() / 2;
int i = 0;
p.setPen( white );
@@ -846,20 +846,20 @@ void Spacer::paintEvent( TQPaintEvent * )
void Spacer::resizeEvent( TQResizeEvent* e)
{
TQWidget::resizeEvent( e );
- if ( !parentWidget() || WidgetFactory::layoutType( parentWidget() ) == WidgetFactory::NoLayout )
+ if ( !tqparentWidget() || WidgetFactory::tqlayoutType( tqparentWidget() ) == WidgetFactory::NoLayout )
sh = size();
}
void Spacer::updateMask()
{
TQRegion r( rect() );
- if ( orient == Horizontal ) {
- const int amplitude = QMIN( 3, height() / 3 );
+ if ( orient ==Qt::Horizontal ) {
+ const int amplitude = TQMIN( 3, height() / 3 );
const int base = height() / 2;
r = r.subtract( TQRect(1, 0, width() - 2, base - amplitude ) );
r = r.subtract( TQRect(1, base + amplitude, width() - 2, height() - base - amplitude ) );
} else {
- const int amplitude = QMIN( 3, width() / 3 );
+ const int amplitude = TQMIN( 3, width() / 3 );
const int base = width() / 2;
r = r.subtract( TQRect(0, 1, base - amplitude, height() - 2 ) );
r = r.subtract( TQRect( base + amplitude, 1, width() - base - amplitude, height() - 2 ) );
@@ -870,38 +870,38 @@ void Spacer::updateMask()
void Spacer::setSizeType( SizeType t )
{
TQSizePolicy sizeP;
- if ( orient == Vertical )
+ if ( orient ==Qt::Vertical )
sizeP = TQSizePolicy( TQSizePolicy::Minimum, (TQSizePolicy::SizeType)t );
else
sizeP = TQSizePolicy( (TQSizePolicy::SizeType)t, TQSizePolicy::Minimum );
- setSizePolicy( sizeP );
+ tqsetSizePolicy( sizeP );
}
Spacer::SizeType Spacer::sizeType() const
{
- if ( orient == Vertical )
- return (SizeType)sizePolicy().verData();
- return (SizeType)sizePolicy().horData();
+ if ( orient ==Qt::Vertical )
+ return (SizeType)tqsizePolicy().verData();
+ return (SizeType)tqsizePolicy().horData();
}
-int Spacer::alignment() const
+int Spacer::tqalignment() const
{
- if ( orient == Vertical )
+ if ( orient ==Qt::Vertical )
return AlignHCenter;
return AlignVCenter;
}
-TQSize Spacer::minimumSize() const
+TQSize Spacer::tqminimumSize() const
{
return TQSize( 20, 20 );
}
-TQSize Spacer::sizeHint() const
+TQSize Spacer::tqsizeHint() const
{
TQSize s = sh.expandedTo( TQSize(0,0) );
if ( sizeType() == Expanding )
- if ( orient == Horizontal )
+ if ( orient ==Qt::Horizontal )
s.rheight() = 0;
else
s.rwidth() = 0;
@@ -912,8 +912,8 @@ TQSize Spacer::sizeHint() const
void Spacer::setSizeHint( const TQSize &s )
{
sh = s;
- if ( !parentWidget() || WidgetFactory::layoutType( parentWidget() ) == WidgetFactory::NoLayout )
- resize( sizeHint() );
+ if ( !tqparentWidget() || WidgetFactory::tqlayoutType( tqparentWidget() ) == WidgetFactory::NoLayout )
+ resize( tqsizeHint() );
updateGeometry();
}
@@ -932,7 +932,7 @@ void Spacer::setOrientation( Qt::Orientation o )
setSizeType( st );
if ( interactive ) {
sh = TQSize( sh.height(), sh.width() );
- if (!parentWidget() || WidgetFactory::layoutType( parentWidget() ) == WidgetFactory::NoLayout )
+ if (!tqparentWidget() || WidgetFactory::tqlayoutType( tqparentWidget() ) == WidgetFactory::NoLayout )
resize( height(), width() );
}
updateMask();
@@ -941,13 +941,13 @@ void Spacer::setOrientation( Qt::Orientation o )
}
-void QDesignerGridLayout::addWidget( TQWidget *w, int row, int col, int align_ )
+void TQDesignerGridLayout::addWidget( TQWidget *w, int row, int col, int align_ )
{
items.insert( w, Item(row, col, 1, 1) );
TQGridLayout::addWidget( w, row, col, align_ );
}
-void QDesignerGridLayout::addMultiCellWidget( TQWidget *w, int fromRow, int toRow,
+void TQDesignerGridLayout::addMultiCellWidget( TQWidget *w, int fromRow, int toRow,
int fromCol, int toCol, int align_ )
{
items.insert( w, Item(fromRow, fromCol, toRow - fromRow + 1, toCol - fromCol +1) );
diff --git a/kommander/editor/layout.h b/kommander/editor/layout.h
index c8b85a3a..107a4083 100644
--- a/kommander/editor/layout.h
+++ b/kommander/editor/layout.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -31,9 +31,10 @@
class FormWindow;
class TQPaintEvent;
-class Layout : public QObject
+class Layout : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
Layout( const TQWidgetList &wl, TQWidget *p, FormWindow *fw, TQWidget *lb, bool doSetup = TRUE, bool splitter = FALSE );
@@ -42,15 +43,15 @@ public:
virtual void doLayout() = 0;
virtual void undoLayout();
virtual void breakLayout();
- virtual bool prepareLayout( bool &needMove, bool &needReparent );
- virtual void finishLayout( bool needMove, TQLayout *layout );
+ virtual bool prepareLayout( bool &needMove, bool &needRetqparent );
+ virtual void finishLayout( bool needMove, TQLayout *tqlayout );
protected:
TQWidgetList widgets;
- TQWidget *parent;
+ TQWidget *tqparent;
TQPoint startPoint;
TQMap<TQGuardedPtr<TQWidget>, TQRect> geometries;
- TQWidget *layoutBase;
+ TQWidget *tqlayoutBase;
FormWindow *formWindow;
TQRect oldGeometry;
bool isBreak;
@@ -108,16 +109,17 @@ protected:
};
-class Spacer : public QWidget
+class Spacer : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_OVERRIDE( TQCString name )
- Q_PROPERTY( Orientation orientation READ orientation WRITE setOrientation )
+ TQ_OVERRIDE( TQCString name )
+ TQ_PROPERTY( Qt::Orientation orientation READ orientation WRITE setOrientation )
Q_ENUMS( SizeType )
- Q_PROPERTY( SizeType sizeType READ sizeType WRITE setSizeType )
- Q_PROPERTY( TQSize sizeHint READ sizeHint WRITE setSizeHint DESIGNABLE true STORED true )
- Q_OVERRIDE( TQRect geometry DESIGNABLE false )
+ TQ_PROPERTY( SizeType sizeType READ sizeType WRITE setSizeType )
+ TQ_PROPERTY( TQSize tqsizeHint READ tqsizeHint WRITE setSizeHint DESIGNABLE true STORED true )
+ TQ_OVERRIDE( TQRect tqgeometry DESIGNABLE false )
private:
enum { HSize = 6, HMask = 0x3f, VMask = HMask << HSize,
@@ -131,15 +133,15 @@ public:
MinimumExpanding = Minimum|ExpMask,
Expanding = MinimumExpanding|MayShrink };
- Spacer( TQWidget *parent, const char *name );
+ Spacer( TQWidget *tqparent, const char *name );
- TQSize minimumSize() const;
- TQSize sizeHint() const;
+ TQSize tqminimumSize() const;
+ TQSize tqsizeHint() const;
void setSizeType( SizeType t );
SizeType sizeType() const;
- int alignment() const;
- Orientation orientation() const;
- void setOrientation( Orientation o );
+ int tqalignment() const;
+ Qt::Orientation orientation() const;
+ void setOrientation( Qt::Orientation o );
void setInteraciveMode( bool b ) { interactive = b; };
void setSizeHint( const TQSize &s );
@@ -152,12 +154,13 @@ protected:
TQSize sh;
};
-class QDesignerGridLayout : public QGridLayout
+class TQDesignerGridLayout : public TQGridLayout
{
Q_OBJECT
+ TQ_OBJECT
public:
- QDesignerGridLayout( TQWidget *parent ) : TQGridLayout( parent ){};
- QDesignerGridLayout( TQLayout *parentLayout ) : TQGridLayout( parentLayout ){};
+ TQDesignerGridLayout( TQWidget *tqparent ) : TQGridLayout( tqparent ){};
+ TQDesignerGridLayout( TQLayout *tqparentLayout ) : TQGridLayout( tqparentLayout ){};
void addWidget( TQWidget *, int row, int col, int align = 0 );
void addMultiCellWidget( TQWidget *, int fromRow, int toRow,
diff --git a/kommander/editor/listboxeditor.ui b/kommander/editor/listboxeditor.ui
index 2b462987..fc03fa8f 100644
--- a/kommander/editor/listboxeditor.ui
+++ b/kommander/editor/listboxeditor.ui
@@ -19,7 +19,7 @@
** not clear to you.
**
*********************************************************************</comment>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>ListBoxEditorBase</cstring>
</property>
@@ -50,7 +50,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget" row="5" column="0" rowspan="1" colspan="3">
+ <widget class="TQLayoutWidget" row="5" column="0" rowspan="1" colspan="3">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -64,7 +64,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>helpButton</cstring>
</property>
@@ -85,14 +85,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonOk</cstring>
</property>
@@ -109,7 +109,7 @@
<string>Close the dialog and apply all the changes.</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonApply</cstring>
</property>
@@ -123,7 +123,7 @@
<string>Apply all changes.</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonCancel</cstring>
</property>
@@ -139,7 +139,7 @@
</widget>
</hbox>
</widget>
- <widget class="QListBox" row="0" column="0" rowspan="5" colspan="1">
+ <widget class="TQListBox" row="0" column="0" rowspan="5" colspan="1">
<property name="name">
<cstring>preview</cstring>
</property>
@@ -150,7 +150,7 @@
<string>The list of items.</string>
</property>
</widget>
- <widget class="QGroupBox" row="0" column="2" rowspan="5" colspan="1">
+ <widget class="TQGroupBox" row="0" column="2" rowspan="5" colspan="1">
<property name="name">
<cstring>GroupBox1</cstring>
</property>
@@ -167,7 +167,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel" row="1" column="0">
+ <widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>Label2</cstring>
</property>
@@ -178,7 +178,7 @@
<cstring>itemChoosePixmap</cstring>
</property>
</widget>
- <widget class="QLabel" row="1" column="1">
+ <widget class="TQLabel" row="1" column="1">
<property name="name">
<cstring>itemPixmap</cstring>
</property>
@@ -186,11 +186,11 @@
<string>Label4</string>
</property>
</widget>
- <widget class="QPushButton" row="1" column="2">
+ <widget class="TQPushButton" row="1" column="2">
<property name="name">
<cstring>itemDeletePixmap</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>30</width>
<height>22</height>
@@ -209,11 +209,11 @@
<string>Delete the selected item's pixmap.</string>
</property>
</widget>
- <widget class="QPushButton" row="1" column="3">
+ <widget class="TQPushButton" row="1" column="3">
<property name="name">
<cstring>itemChoosePixmap</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>30</width>
<height>22</height>
@@ -229,7 +229,7 @@
<string>Choose a pixmap file for the selected item.</string>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>Label1</cstring>
</property>
@@ -240,11 +240,11 @@
<cstring>itemText</cstring>
</property>
</widget>
- <widget class="QLineEdit" row="0" column="1" rowspan="1" colspan="3">
+ <widget class="TQLineEdit" row="0" column="1" rowspan="1" colspan="3">
<property name="name">
<cstring>itemText</cstring>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>0</width>
<height>0</height>
@@ -259,7 +259,7 @@
</widget>
</grid>
</widget>
- <widget class="QPushButton" row="0" column="1">
+ <widget class="TQPushButton" row="0" column="1">
<property name="name">
<cstring>itemNew</cstring>
</property>
@@ -273,7 +273,7 @@
<string>&lt;b&gt;Add a new item.&lt;/b&gt;&lt;p&gt;New items are appended to the list.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QPushButton" row="1" column="1">
+ <widget class="TQPushButton" row="1" column="1">
<property name="name">
<cstring>itemDelete</cstring>
</property>
@@ -297,14 +297,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton" row="3" column="1">
+ <widget class="TQPushButton" row="3" column="1">
<property name="name">
<cstring>itemUp</cstring>
</property>
@@ -321,7 +321,7 @@
<string>Moves the selected item up.</string>
</property>
</widget>
- <widget class="QPushButton" row="4" column="1">
+ <widget class="TQPushButton" row="4" column="1">
<property name="name">
<cstring>itemDown</cstring>
</property>
@@ -414,21 +414,21 @@
</connection>
<connection>
<sender>preview</sender>
- <signal>selectionChanged(QListBoxItem*)</signal>
+ <signal>selectionChanged(TQListBoxItem*)</signal>
<receiver>ListBoxEditorBase</receiver>
- <slot>currentItemChanged(QListBoxItem*)</slot>
+ <slot>currentItemChanged(TQListBoxItem*)</slot>
</connection>
<connection>
<sender>preview</sender>
- <signal>currentChanged( QListBoxItem * )</signal>
+ <signal>currentChanged( TQListBoxItem * )</signal>
<receiver>ListBoxEditorBase</receiver>
- <slot>currentItemChanged(QListBoxItem*)</slot>
+ <slot>currentItemChanged(TQListBoxItem*)</slot>
</connection>
<slot access="protected" language="C++" returnType="void">init()</slot>
<slot access="protected" language="C++" returnType="void">destroy()</slot>
<slot access="protected" language="C++" returnType="void">insertNewItem()</slot>
<slot access="protected" language="C++" returnType="void">deleteCurrentItem()</slot>
- <slot access="protected" language="C++" returnType="void">currentItemChanged( QListBoxItem * )</slot>
+ <slot access="protected" language="C++" returnType="void">currentItemChanged( TQListBoxItem * )</slot>
<slot access="protected" language="C++" returnType="void">currentTextChanged( const QString &amp; )</slot>
<slot access="protected" language="C++" returnType="void">okClicked()</slot>
<slot access="protected" language="C++" returnType="void">cancelClicked()</slot>
diff --git a/kommander/editor/listboxeditorimpl.cpp b/kommander/editor/listboxeditorimpl.cpp
index 1f820081..80382c95 100644
--- a/kommander/editor/listboxeditorimpl.cpp
+++ b/kommander/editor/listboxeditorimpl.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -32,8 +32,8 @@
#include <klocale.h>
-ListBoxEditor::ListBoxEditor( TQWidget *parent, TQWidget *editWidget, FormWindow *fw )
- : ListBoxEditorBase( parent, 0, true ), formwindow( fw )
+ListBoxEditor::ListBoxEditor( TQWidget *tqparent, TQWidget *editWidget, FormWindow *fw )
+ : ListBoxEditorBase( tqparent, 0, true ), formwindow( fw )
{
connect( helpButton, TQT_SIGNAL( clicked() ), MainWindow::self, TQT_SLOT( showDialogHelp() ) );
listbox = (TQListBox*)editWidget;
@@ -131,7 +131,7 @@ void ListBoxEditor::applyClicked()
items.append( item );
}
- PopulateListBoxCommand *cmd = new PopulateListBoxCommand( i18n("Edit Items of '%1'" ).arg( listbox->name() ),
+ PopulateListBoxCommand *cmd = new PopulateListBoxCommand( i18n("Edit Items of '%1'" ).tqarg( listbox->name() ),
formwindow, listbox, items );
cmd->execute();
formwindow->commandHistory()->addCommand( cmd );
diff --git a/kommander/editor/listboxeditorimpl.h b/kommander/editor/listboxeditorimpl.h
index 41bcc8a7..07e18f1f 100644
--- a/kommander/editor/listboxeditorimpl.h
+++ b/kommander/editor/listboxeditorimpl.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -29,9 +29,10 @@ class FormWindow;
class ListBoxEditor : public ListBoxEditorBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- ListBoxEditor( TQWidget *parent, TQWidget *editWidget, FormWindow *fw );
+ ListBoxEditor( TQWidget *tqparent, TQWidget *editWidget, FormWindow *fw );
protected slots:
void insertNewItem();
diff --git a/kommander/editor/listeditor.ui b/kommander/editor/listeditor.ui
index 6cafeed0..66efc1ae 100644
--- a/kommander/editor/listeditor.ui
+++ b/kommander/editor/listeditor.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.1" stdsetdef="1">
<class>ListEditor</class>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>ListEditor</cstring>
</property>
@@ -25,7 +25,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QListView" row="0" column="0" rowspan="5" colspan="1">
+ <widget class="TQListView" row="0" column="0" rowspan="5" colspan="1">
<column>
<property name="text">
<string>Column 1</string>
@@ -47,7 +47,7 @@
<enum>AllColumns</enum>
</property>
</widget>
- <widget class="QPushButton" row="0" column="1">
+ <widget class="TQPushButton" row="0" column="1">
<property name="name">
<cstring>PushButton1</cstring>
</property>
@@ -55,7 +55,7 @@
<string>&amp;Add</string>
</property>
</widget>
- <widget class="QPushButton" row="1" column="1">
+ <widget class="TQPushButton" row="1" column="1">
<property name="name">
<cstring>PushButton2</cstring>
</property>
@@ -63,7 +63,7 @@
<string>&amp;Remove</string>
</property>
</widget>
- <widget class="QPushButton" row="2" column="1">
+ <widget class="TQPushButton" row="2" column="1">
<property name="name">
<cstring>PushButton3</cstring>
</property>
@@ -71,7 +71,7 @@
<string>Re&amp;name</string>
</property>
</widget>
- <widget class="QPushButton" row="4" column="1">
+ <widget class="TQPushButton" row="4" column="1">
<property name="name">
<cstring>PushButton4</cstring>
</property>
@@ -89,7 +89,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
@@ -133,15 +133,15 @@
<forwards>
<forward>class QStringList;</forward>
</forwards>
-<slots>
+<Q_SLOTS>
<slot>init()</slot>
<slot>setList( const QStringList &amp; l )</slot>
<slot>addItem()</slot>
<slot>renamed( QListViewItem * i )</slot>
<slot>removeItems()</slot>
- <slot returnType="QStringList">items()</slot>
+ <slot returnType="TQStringList">items()</slot>
<slot>renameItem()</slot>
-</slots>
+</Q_SLOTS>
<pixmapinproject/>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/editor/listvieweditor.ui b/kommander/editor/listvieweditor.ui
index 32c5f135..2ec9e9ba 100644
--- a/kommander/editor/listvieweditor.ui
+++ b/kommander/editor/listvieweditor.ui
@@ -19,7 +19,7 @@
** not clear to you.
**
*********************************************************************</comment>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>ListViewEditorBase</cstring>
</property>
@@ -50,11 +50,11 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QTabWidget">
+ <widget class="TQTabWidget">
<property name="name">
<cstring>tabWidget</cstring>
</property>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>Widget10</cstring>
</property>
@@ -71,7 +71,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QPushButton" row="2" column="1">
+ <widget class="TQPushButton" row="2" column="1">
<property name="name">
<cstring>itemDelete</cstring>
</property>
@@ -85,7 +85,7 @@
<string>&lt;b&gt;Deletes the selected item.&lt;/b&gt;&lt;p&gt;Any sub-items are also deleted.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QGroupBox" row="0" column="2" rowspan="8" colspan="1">
+ <widget class="TQGroupBox" row="0" column="2" rowspan="8" colspan="1">
<property name="name">
<cstring>GroupBox1</cstring>
</property>
@@ -108,7 +108,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel" row="2" column="0">
+ <widget class="TQLabel" row="2" column="0">
<property name="name">
<cstring>Label2</cstring>
</property>
@@ -119,7 +119,7 @@
<cstring>itemChoosePixmap</cstring>
</property>
</widget>
- <widget class="QLabel" row="1" column="0">
+ <widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>Label1</cstring>
</property>
@@ -130,11 +130,11 @@
<cstring>itemText</cstring>
</property>
</widget>
- <widget class="QLineEdit" row="1" column="1">
+ <widget class="TQLineEdit" row="1" column="1">
<property name="name">
<cstring>itemText</cstring>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>0</width>
<height>0</height>
@@ -147,7 +147,7 @@
<string>&lt;b&gt;Change the text of the item.&lt;/b&gt;&lt;p&gt;The text will be changed in the current column of the selected item.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QSpinBox" row="0" column="1">
+ <widget class="TQSpinBox" row="0" column="1">
<property name="name">
<cstring>itemColumn</cstring>
</property>
@@ -158,7 +158,7 @@
<string>&lt;b&gt;Select the current column.&lt;/b&gt;&lt;p&gt;The item's text and pixmap will be changed for the current column&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>Label4</cstring>
</property>
@@ -169,7 +169,7 @@
<cstring>itemColumn</cstring>
</property>
</widget>
- <widget class="QLayoutWidget" row="2" column="1">
+ <widget class="TQLayoutWidget" row="2" column="1">
<property name="name">
<cstring>Layout2</cstring>
</property>
@@ -183,7 +183,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>itemPixmap</cstring>
</property>
@@ -191,11 +191,11 @@
<string>Label4</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>itemDeletePixmap</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>30</width>
<height>22</height>
@@ -214,11 +214,11 @@
<string>&lt;b&gt;Delete the selected item's pixmap.&lt;/b&gt;&lt;p&gt;The pixmap in the current column of the selected item will be deleted.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>itemChoosePixmap</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>30</width>
<height>22</height>
@@ -238,7 +238,7 @@
</widget>
</grid>
</widget>
- <widget class="QPushButton" row="0" column="1">
+ <widget class="TQPushButton" row="0" column="1">
<property name="name">
<cstring>itemNew</cstring>
</property>
@@ -252,7 +252,7 @@
<string>&lt;b&gt;Adds a new item to the list.&lt;/b&gt;&lt;p&gt;The item will be inserted at the top of the list and can be moved using the up- and down-buttons.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QListView" row="0" column="0" rowspan="8" colspan="1">
+ <widget class="TQListView" row="0" column="0" rowspan="8" colspan="1">
<property name="name">
<cstring>itemsPreview</cstring>
</property>
@@ -260,7 +260,7 @@
<string>The list of items.</string>
</property>
</widget>
- <widget class="QPushButton" row="1" column="1">
+ <widget class="TQPushButton" row="1" column="1">
<property name="name">
<cstring>itemNewSub</cstring>
</property>
@@ -284,14 +284,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton" row="4" column="1">
+ <widget class="TQPushButton" row="4" column="1">
<property name="name">
<cstring>itemUp</cstring>
</property>
@@ -308,7 +308,7 @@
<string>&lt;b&gt;Move the selected item up.&lt;/b&gt;&lt;p&gt;The item will be moved within its level in the hierarchy.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QPushButton" row="5" column="1">
+ <widget class="TQPushButton" row="5" column="1">
<property name="name">
<cstring>itemDown</cstring>
</property>
@@ -325,7 +325,7 @@
<string>&lt;b&gt;Move the selected item down.&lt;/b&gt;&lt;p&gt;The item will be moved within its level in the hierarchy.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QPushButton" row="6" column="1">
+ <widget class="TQPushButton" row="6" column="1">
<property name="name">
<cstring>itemLeft</cstring>
</property>
@@ -342,7 +342,7 @@
<string>&lt;b&gt;Move the selected item one level up.&lt;/b&gt;&lt;p&gt;This will also change the level of the item's sub-items.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QPushButton" row="7" column="1">
+ <widget class="TQPushButton" row="7" column="1">
<property name="name">
<cstring>itemRight</cstring>
</property>
@@ -361,7 +361,7 @@
</widget>
</grid>
</widget>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>Widget11</cstring>
</property>
@@ -378,7 +378,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QGroupBox" row="0" column="2" rowspan="5" colspan="1">
+ <widget class="TQGroupBox" row="0" column="2" rowspan="5" colspan="1">
<property name="name">
<cstring>GroupBox1</cstring>
</property>
@@ -395,7 +395,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel" row="1" column="0">
+ <widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>Label2</cstring>
</property>
@@ -406,7 +406,7 @@
<cstring>colChoosePixmap</cstring>
</property>
</widget>
- <widget class="QLabel" row="1" column="1">
+ <widget class="TQLabel" row="1" column="1">
<property name="name">
<cstring>colPixmap</cstring>
</property>
@@ -414,11 +414,11 @@
<string>Label4</string>
</property>
</widget>
- <widget class="QPushButton" row="1" column="2">
+ <widget class="TQPushButton" row="1" column="2">
<property name="name">
<cstring>colDeletePixmap</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>30</width>
<height>22</height>
@@ -437,11 +437,11 @@
<string>Delete the pixmap of the selected column.</string>
</property>
</widget>
- <widget class="QPushButton" row="1" column="3">
+ <widget class="TQPushButton" row="1" column="3">
<property name="name">
<cstring>colChoosePixmap</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>30</width>
<height>22</height>
@@ -457,7 +457,7 @@
<string>&lt;b&gt;Select a pixmap file for the selected column.&lt;/b&gt;&lt;p&gt;The pixmap will be displayed in the header of the listview.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>Label1</cstring>
</property>
@@ -468,11 +468,11 @@
<cstring>colText</cstring>
</property>
</widget>
- <widget class="QLineEdit" row="0" column="1" rowspan="1" colspan="3">
+ <widget class="TQLineEdit" row="0" column="1" rowspan="1" colspan="3">
<property name="name">
<cstring>colText</cstring>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>0</width>
<height>0</height>
@@ -485,7 +485,7 @@
<string>&lt;b&gt;Enter the text for the selected column.&lt;/b&gt;&lt;p&gt;The text will be displayed in the header of the listview.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QCheckBox" row="2" column="0" rowspan="1" colspan="2">
+ <widget class="TQCheckBox" row="2" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>colClickable</cstring>
</property>
@@ -496,7 +496,7 @@
<string>If this option is checked, the selected column will react to mouse clicks on the header.</string>
</property>
</widget>
- <widget class="QCheckBox" row="3" column="0" rowspan="1" colspan="2">
+ <widget class="TQCheckBox" row="3" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>colResizeable</cstring>
</property>
@@ -509,7 +509,7 @@
</widget>
</grid>
</widget>
- <widget class="QPushButton" row="1" column="1">
+ <widget class="TQPushButton" row="1" column="1">
<property name="name">
<cstring>colDelete</cstring>
</property>
@@ -523,7 +523,7 @@
<string>Deletes the selected Column.</string>
</property>
</widget>
- <widget class="QPushButton" row="4" column="1">
+ <widget class="TQPushButton" row="4" column="1">
<property name="name">
<cstring>colDown</cstring>
</property>
@@ -540,7 +540,7 @@
<string>&lt;b&gt;Move the selected item down.&lt;/b&gt;&lt;p&gt;The top-most column will be the first column in the list.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QPushButton" row="0" column="1">
+ <widget class="TQPushButton" row="0" column="1">
<property name="name">
<cstring>colNew</cstring>
</property>
@@ -554,7 +554,7 @@
<string>&lt;b&gt;Create a new column.&lt;/b&gt;&lt;p&gt;New columns are appended at the end of (right of) the list and may be moved using the up- and down-buttons.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QPushButton" row="3" column="1">
+ <widget class="TQPushButton" row="3" column="1">
<property name="name">
<cstring>colUp</cstring>
</property>
@@ -571,7 +571,7 @@
<string>&lt;b&gt;Move the selected item up.&lt;/b&gt;&lt;p&gt;The top-most column will be the first column in the list.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QListBox" row="0" column="0" rowspan="5" colspan="1">
+ <widget class="TQListBox" row="0" column="0" rowspan="5" colspan="1">
<property name="name">
<cstring>colPreview</cstring>
</property>
@@ -589,7 +589,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
@@ -599,7 +599,7 @@
</grid>
</widget>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -613,7 +613,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>helpButton</cstring>
</property>
@@ -634,14 +634,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>okButton</cstring>
</property>
@@ -658,7 +658,7 @@
<string>Close the dialog and apply all the changes.</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>applyButton</cstring>
</property>
@@ -672,7 +672,7 @@
<string>Apply all changes.</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>cancelButton</cstring>
</property>
@@ -836,27 +836,27 @@
</connection>
<connection>
<sender>colPreview</sender>
- <signal>currentChanged(QListBoxItem*)</signal>
+ <signal>currentChanged(TQListBoxItem*)</signal>
<receiver>ListViewEditorBase</receiver>
- <slot>currentColumnChanged(QListBoxItem*)</slot>
+ <slot>currentColumnChanged(TQListBoxItem*)</slot>
</connection>
<connection>
<sender>colPreview</sender>
- <signal>selectionChanged(QListBoxItem*)</signal>
+ <signal>selectionChanged(TQListBoxItem*)</signal>
<receiver>ListViewEditorBase</receiver>
- <slot>currentColumnChanged(QListBoxItem*)</slot>
+ <slot>currentColumnChanged(TQListBoxItem*)</slot>
</connection>
<connection>
<sender>itemsPreview</sender>
- <signal>currentChanged(QListViewItem*)</signal>
+ <signal>currentChanged(TQListViewItem*)</signal>
<receiver>ListViewEditorBase</receiver>
- <slot>currentItemChanged(QListViewItem*)</slot>
+ <slot>currentItemChanged(TQListViewItem*)</slot>
</connection>
<connection>
<sender>itemsPreview</sender>
- <signal>selectionChanged(QListViewItem*)</signal>
+ <signal>selectionChanged(TQListViewItem*)</signal>
<receiver>ListViewEditorBase</receiver>
- <slot>currentItemChanged(QListViewItem*)</slot>
+ <slot>currentItemChanged(TQListViewItem*)</slot>
</connection>
<connection>
<sender>itemNewSub</sender>
@@ -886,8 +886,8 @@
<slot access="protected" language="C++" returnType="void">columnResizable(bool)</slot>
<slot access="protected" language="C++" returnType="void">columnTextChanged(const QString &amp;)</slot>
<slot access="protected" language="C++" returnType="void">columnUpClicked()</slot>
- <slot access="protected" language="C++" returnType="void">currentColumnChanged(QListBoxItem*)</slot>
- <slot access="protected" language="C++" returnType="void">currentItemChanged(QListViewItem*)</slot>
+ <slot access="protected" language="C++" returnType="void">currentColumnChanged(TQListBoxItem*)</slot>
+ <slot access="protected" language="C++" returnType="void">currentItemChanged(TQListViewItem*)</slot>
<slot access="protected" language="C++" returnType="void">deleteColumnClicked()</slot>
<slot access="protected" language="C++" returnType="void">initTabPage(const QString &amp;)</slot>
<slot access="protected" language="C++" returnType="void">itemColChanged(int)</slot>
diff --git a/kommander/editor/listvieweditorimpl.cpp b/kommander/editor/listvieweditorimpl.cpp
index fb2f0a6a..abed8458 100644
--- a/kommander/editor/listvieweditorimpl.cpp
+++ b/kommander/editor/listvieweditorimpl.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -37,8 +37,8 @@
#include <klocale.h>
-ListViewEditor::ListViewEditor( TQWidget *parent, TQListView *lv, FormWindow *fw )
- : ListViewEditorBase( parent, 0, true ), listview( lv ), formwindow( fw )
+ListViewEditor::ListViewEditor( TQWidget *tqparent, TQListView *lv, FormWindow *fw )
+ : ListViewEditorBase( tqparent, 0, true ), listview( lv ), formwindow( fw )
{
connect( helpButton, TQT_SIGNAL( clicked() ), MainWindow::self, TQT_SLOT( showDialogHelp() ) );
itemText->setEnabled( false );
@@ -63,7 +63,7 @@ ListViewEditor::ListViewEditor( TQWidget *parent, TQListView *lv, FormWindow *fw
void ListViewEditor::applyClicked()
{
setupItems();
- PopulateListViewCommand *cmd = new PopulateListViewCommand( i18n("Edit Items and Columns of '%1'" ).arg( listview->name() ),
+ PopulateListViewCommand *cmd = new PopulateListViewCommand( i18n("Edit Items and Columns of '%1'" ).tqarg( listview->name() ),
formwindow, listview, itemsPreview );
cmd->execute();
formwindow->commandHistory()->addCommand( cmd );
@@ -321,10 +321,10 @@ void ListViewEditor::itemDownClicked()
return;
TQListViewItemIterator it( i );
- TQListViewItem *parent = i->parent();
+ TQListViewItem *tqparent = i->tqparent();
it++;
while ( it.current() ) {
- if ( it.current()->parent() == parent )
+ if ( it.current()->tqparent() == tqparent )
break;
it++;
}
@@ -346,11 +346,11 @@ void ListViewEditor::itemNewClicked()
void ListViewEditor::itemNewSubClicked()
{
- TQListViewItem *parent = itemsPreview->currentItem();
+ TQListViewItem *tqparent = itemsPreview->currentItem();
TQListViewItem *item = 0;
- if ( parent ) {
- item = new TQListViewItem( parent );
- parent->setOpen( true );
+ if ( tqparent ) {
+ item = new TQListViewItem( tqparent );
+ tqparent->setOpen( true );
} else {
item = new TQListViewItem( itemsPreview );
}
@@ -405,10 +405,10 @@ void ListViewEditor::itemUpClicked()
return;
TQListViewItemIterator it( i );
- TQListViewItem *parent = i->parent();
+ TQListViewItem *tqparent = i->tqparent();
--it;
while ( it.current() ) {
- if ( it.current()->parent() == parent )
+ if ( it.current()->tqparent() == tqparent )
break;
--it;
}
@@ -427,13 +427,13 @@ void ListViewEditor::itemRightClicked()
return;
TQListViewItemIterator it( i );
- TQListViewItem *parent = i->parent();
- parent = parent ? parent->firstChild() : itemsPreview->firstChild();
- if ( !parent )
+ TQListViewItem *tqparent = i->tqparent();
+ tqparent = tqparent ? tqparent->firstChild() : itemsPreview->firstChild();
+ if ( !tqparent )
return;
it++;
while ( it.current() ) {
- if ( it.current()->parent() == parent )
+ if ( it.current()->tqparent() == tqparent )
break;
it++;
}
@@ -467,13 +467,13 @@ void ListViewEditor::itemLeftClicked()
return;
TQListViewItemIterator it( i );
- TQListViewItem *parent = i->parent();
- if ( !parent )
+ TQListViewItem *tqparent = i->tqparent();
+ if ( !tqparent )
return;
- parent = parent->parent();
+ tqparent = tqparent->tqparent();
--it;
while ( it.current() ) {
- if ( it.current()->parent() == parent )
+ if ( it.current()->tqparent() == tqparent )
break;
--it;
}
@@ -531,7 +531,7 @@ void ListViewEditor::setupColumns()
void ListViewEditor::setupItems()
{
itemColumn->setMinValue( 0 );
- itemColumn->setMaxValue( QMAX( numColumns - 1, 0 ) );
+ itemColumn->setMaxValue( TQMAX( numColumns - 1, 0 ) );
int i = 0;
TQHeader *header = itemsPreview->header();
for ( TQListBoxItem *item = colPreview->firstItem(); item; item = item->next() ) {
@@ -548,7 +548,7 @@ void ListViewEditor::setupItems()
while ( itemsPreview->columns() > i )
itemsPreview->removeColumn( i );
- itemColumn->setValue( QMIN( numColumns - 1, itemColumn->value() ) );
+ itemColumn->setValue( TQMIN( numColumns - 1, itemColumn->value() ) );
}
ListViewEditor::Column *ListViewEditor::findColumn( TQListBoxItem *i )
diff --git a/kommander/editor/listvieweditorimpl.h b/kommander/editor/listvieweditorimpl.h
index 37f9154e..9a7d7457 100644
--- a/kommander/editor/listvieweditorimpl.h
+++ b/kommander/editor/listvieweditorimpl.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -32,9 +32,10 @@ class FormWindow;
class ListViewEditor : public ListViewEditorBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- ListViewEditor( TQWidget *parent, TQListView *lv, FormWindow *fw );
+ ListViewEditor( TQWidget *tqparent, TQListView *lv, FormWindow *fw );
protected slots:
void applyClicked();
@@ -70,7 +71,7 @@ private:
TQString text;
TQPixmap pixmap;
bool clickable, resizable;
-#if defined(Q_FULL_TEMPLATE_INSTANTIATION)
+#if defined(TQ_FULL_TEMPLATE_INSTANTIATION)
bool operator==( const Column& ) const { return FALSE; }
#endif
};
diff --git a/kommander/editor/main.cpp b/kommander/editor/main.cpp
index 7be1f31d..644e10d7 100644
--- a/kommander/editor/main.cpp
+++ b/kommander/editor/main.cpp
@@ -30,7 +30,7 @@
static const char *description =
I18N_NOOP("Kommander is a graphical editor of scripted dialogs.");
static const char *text =
- I18N_NOOP("Based on Qt Designer, (C) 2000 Trolltech AS.");
+ I18N_NOOP("Based on TQt Designer, (C) 2000 Trolltech AS.");
static KCmdLineOptions options[] =
{
diff --git a/kommander/editor/mainwindow.cpp b/kommander/editor/mainwindow.cpp
index 069d30dd..f87b7c2c 100644
--- a/kommander/editor/mainwindow.cpp
+++ b/kommander/editor/mainwindow.cpp
@@ -1,5 +1,5 @@
/**********************************************************************
- This file is based on Qt Designer, Copyright (C) 2000 Trolltech AS. All rights reserved.
+ This file is based on TQt Designer, Copyright (C) 2000 Trolltech AS. All rights reserved.
This file may be distributed and/or modified under the terms of the
GNU General Public License version 2 as published by the Free Software
@@ -108,7 +108,7 @@ static TQString textNoAccel(const TQString& text)
{
TQString t = text;
int i;
- while ((i = t.find('&'))>= 0) {
+ while ((i = t.tqfind('&'))>= 0) {
t.remove(i,1);
}
return t;
@@ -118,7 +118,7 @@ static TQString textNoAccel(const TQString& text)
MainWindow::MainWindow(bool asClient)
: KParts::DockMainWindow(0, "mainwindow", WType_TopLevel | WDestructiveClose | WGroupLeader),
grd(10, 10), sGrid(true), snGrid(true), restoreConfig(true), splashScreen(true),
- docPath("$QTDIR/doc/html"), client(asClient), databaseAutoEdit(false), previewing(false)
+ docPath("$TQTDIR/doc/html"), client(asClient), databaseAutoEdit(false), previewing(false)
{
m_partManager = new KParts::PartManager(this);
//connect(m_partManager, TQT_SIGNAL(activePartChanged(KParts::Part * )), this, TQT_SLOT(slotActivePartChanged(KParts::Part * )));
@@ -143,9 +143,9 @@ MainWindow::MainWindow(bool asClient)
setupMDI();
setupFileActions();
setupEditActions();
- layoutToolBar = new KToolBar(this, "Layout");
- ((KToolBar *) layoutToolBar)->setFullSize(false);
- addToolBar(layoutToolBar, i18n("Layout"));
+ tqlayoutToolBar = new KToolBar(this, "Layout");
+ ((KToolBar *) tqlayoutToolBar)->setFullSize(false);
+ addToolBar(tqlayoutToolBar, i18n("Layout"));
setupToolActions();
setupLayoutActions();
setupWorkspace();
@@ -171,8 +171,8 @@ MainWindow::MainWindow(bool asClient)
connect(kapp->clipboard(), TQT_SIGNAL(dataChanged()), this, TQT_SLOT(clipboardChanged()));
clipboardChanged();
- layoutChilds = false;
- layoutSelected = false;
+ tqlayoutChilds = false;
+ tqlayoutSelected = false;
breakLayout = false;
backPix = true;
@@ -191,7 +191,7 @@ MainWindow::MainWindow(bool asClient)
w = WidgetFactory::create(WidgetDatabase::idFromClassName(TQFRAME_OBJECT_NAME_STRING), this, 0, false);
delete w;
- assistant = new AssistProc(this, "Internal Assistant", assistantPath());
+ assistant = new AssistProc(TQT_TQOBJECT(this), "Internal Assistant", assistantPath());
statusBar()->setSizeGripEnabled(true);
SpecialInformation::registerSpecials();
@@ -237,7 +237,7 @@ void MainWindow::setupPropertyEditor()
{
KDockWidget *dw = createDockWidget("Property Editor", TQPixmap(), 0, i18n("Properties"));
propertyEditor = new PropertyEditor(dw);
- //addToolBar(dw, Qt::DockLeft);
+ //addToolBar(dw, TQt::DockLeft);
dw->setWidget(propertyEditor);
dw->manualDock(getMainDockWidget(), KDockWidget::DockLeft, 20);
dw->setCaption(i18n("Property Editor"));
@@ -274,7 +274,7 @@ void MainWindow::setupHierarchyView()
"<p>The Object Explorer provides an overview of the relationships "
"between the widgets in a form. You can use the clipboard functions using "
"a context menu for each item in the view. It is also useful for selecting widgets "
- "in forms that have complex layouts.</p>"
+ "in forms that have complex tqlayouts.</p>"
"<p>The columns can be resized by dragging the separator in the list's header.</p>"
"<p>The second tab shows all the form's slots, class variables, includes, etc.</p>"));
}
@@ -300,7 +300,7 @@ void MainWindow::setupActionEditor()
{
KDockWidget *dw = createDockWidget("Action Editor", TQPixmap(), 0, i18n("Actions"));
actionEditor = new ActionEditor(dw, "ActionEditor");
- //addToolBar(dw, Qt::DockLeft);
+ //addToolBar(dw, TQt::DockLeft);
dw->setWidget(actionEditor);
dw->setCaption(i18n("Action Editor"));
TQWhatsThis::add(actionEditor, i18n("<b>The Action Editor</b>"
@@ -368,7 +368,7 @@ int MainWindow::currentTool() const
{
if (!actionCurrentTool)
return POINTER_TOOL;
- return TQString::fromLatin1(actionCurrentTool->name()).toInt();
+ return TQString::tqfromLatin1(actionCurrentTool->name()).toInt();
}
void MainWindow::slotCreateBackups()
@@ -392,7 +392,7 @@ void MainWindow::slotCreateBackups()
form->formFile()->setModified(true);
if (!form->formFile()->save(false))
{
- KMessageBox::error(this, i18n("<qt>Cannot create backup file <i>%1</i>.</qt>").arg(backupName));
+ KMessageBox::error(this, i18n("<qt>Cannot create backup file <i>%1</i>.</qt>").tqarg(backupName));
}
form->formFile()->setFileName(fileName);
form->formFile()->setModified(modified);
@@ -417,7 +417,7 @@ void MainWindow::runForm()
while ((editor = it.current()) != 0L)
{
++it;
- static_cast<AssocTextEditor*>(editor)->save();
+ static_cast<AssocTextEditor*>(TQT_TQWIDGET(editor))->save();
}
delete editors;
@@ -436,7 +436,7 @@ void MainWindow::runForm()
::stat(m_fileName.local8Bit(), &statbuf);
if (!readOnlyFile && !KIO::NetAccess::file_copy(KURL::fromPathOrURL(m_fileName), KURL::fromPathOrURL(m_backupName), statbuf.st_mode, true))
{
- KMessageBox::error(this, i18n("<qt>Cannot create temporary file <i>%1</i>.</qt>").arg(m_backupName));
+ KMessageBox::error(this, i18n("<qt>Cannot create temporary file <i>%1</i>.</qt>").tqarg(m_backupName));
return;
}
form->formFile()->setFileName(m_fileName);
@@ -446,12 +446,12 @@ void MainWindow::runForm()
{
if (!readOnlyFile && !KIO::NetAccess::file_copy(KURL::fromPathOrURL(m_fileName), KURL::fromPathOrURL(m_fileName + ".backup"), statbuf.st_mode, true))
{
- KMessageBox::error(this, i18n("<qt>Cannot create backup file <i>%1</i>.</qt>").arg(m_fileName + ".backup"));
+ KMessageBox::error(this, i18n("<qt>Cannot create backup file <i>%1</i>.</qt>").tqarg(m_fileName + ".backup"));
}
::chmod(m_fileName.local8Bit(), S_IRWXU);
KProcess* process = new KProcess;
process->setUseShell(true);
- (*process) << "kmdr-executor" << TQString("\"%1\"").arg(form->formFile()->fileName());
+ (*process) << "kmdr-executor" << TQString("\"%1\"").tqarg(form->formFile()->fileName());
connect(process, TQT_SIGNAL(receivedStdout(KProcess*, char*, int)), messageLog,
TQT_SLOT(receivedStdout(KProcess*, char*, int)));
connect(process, TQT_SIGNAL(receivedStderr(KProcess*, char*, int)), messageLog,
@@ -481,7 +481,7 @@ void MainWindow::runForm4()
while ((editor = it.current()) != 0L)
{
++it;
- static_cast<AssocTextEditor*>(editor)->save();
+ static_cast<AssocTextEditor*>(TQT_TQWIDGET(editor))->save();
}
delete editors;
@@ -500,7 +500,7 @@ void MainWindow::runForm4()
::stat(m_fileName.local8Bit(), &statbuf);
if (!readOnlyFile && !KIO::NetAccess::file_copy(KURL::fromPathOrURL(m_fileName), KURL::fromPathOrURL(m_backupName), statbuf.st_mode, true))
{
- KMessageBox::error(this, i18n("<qt>Cannot create temporary file <i>%1</i>.</qt>").arg(m_backupName));
+ KMessageBox::error(this, i18n("<qt>Cannot create temporary file <i>%1</i>.</qt>").tqarg(m_backupName));
return;
}
form->formFile()->setFileName(m_fileName);
@@ -510,12 +510,12 @@ void MainWindow::runForm4()
{
if (!readOnlyFile && !KIO::NetAccess::file_copy(KURL::fromPathOrURL(m_fileName), KURL::fromPathOrURL(m_fileName + ".backup"), statbuf.st_mode, true))
{
- KMessageBox::error(this, i18n("<qt>Cannot create backup file <i>%1</i>.</qt>").arg(m_fileName + ".backup"));
+ KMessageBox::error(this, i18n("<qt>Cannot create backup file <i>%1</i>.</qt>").tqarg(m_fileName + ".backup"));
}
::chmod(m_fileName.local8Bit(), S_IRWXU);
KProcess* process = new KProcess;
process->setUseShell(true);
- (*process) << "kommander" << TQString("\"%1\"").arg(form->formFile()->fileName());
+ (*process) << "kommander" << TQString("\"%1\"").tqarg(form->formFile()->fileName());
connect(process, TQT_SIGNAL(receivedStdout(KProcess*, char*, int)), messageLog,
TQT_SLOT(receivedStdout(KProcess*, char*, int)));
connect(process, TQT_SIGNAL(receivedStderr(KProcess*, char*, int)), messageLog,
@@ -554,9 +554,9 @@ void MainWindow::showProperties(TQObject *o)
}
TQWidget *w = (TQWidget*)o;
setupHierarchyView();
- FormWindow *fw = (FormWindow*)isAFormWindowChild(w);
+ FormWindow *fw = (FormWindow*)isAFormWindowChild(TQT_TQOBJECT(w));
if (fw) {
- propertyEditor->setWidget(w, fw);
+ propertyEditor->setWidget(TQT_TQOBJECT(w), fw);
hierarchyView->setFormWindow(fw, w);
} else {
propertyEditor->setWidget(0, 0);
@@ -596,7 +596,7 @@ bool MainWindow::eventFilter(TQObject *o, TQEvent *e)
while (w) {
if (w->inherits("PropertyList"))
break;
- w = w->parentWidget(true);
+ w = w->tqparentWidget(true);
}
if (w) {
propertyEditor->propertyList()->showCurrentWhatsThis();
@@ -617,7 +617,7 @@ bool MainWindow::eventFilter(TQObject *o, TQEvent *e)
}
break;
case TQEvent::MouseButtonPress:
- if (((TQMouseEvent*)e)->button() == MidButton && dynamic_cast<KommanderWidget *>(o))
+ if (((TQMouseEvent*)e)->button() == Qt::MidButton && dynamic_cast<KommanderWidget *>(o))
{
AssocTextEditor *editor = new AssocTextEditor((TQWidget*)o, formWindow(), propertyEditor, m_partManager,
this, "AssocTextEditor", false); //deletes itself!
@@ -626,27 +626,27 @@ bool MainWindow::eventFilter(TQObject *o, TQEvent *e)
return true;
}
case TQEvent::ContextMenu:
- if (o->inherits("QDesignerPopupMenu"))
+ if (o->inherits("TQDesignerPopupMenu"))
break;
- if (o && currentTool() == POINTER_TOOL && (o->inherits("QDesignerMenuBar") ||
- o->inherits("QDesignerToolBar") ||
- (o->inherits(TQCOMBOBOX_OBJECT_NAME_STRING) || o->inherits(TQTOOLBUTTON_OBJECT_NAME_STRING) || o->inherits("QDesignerToolBarSeparator")) &&
- o->parent() && o->parent()->inherits("QDesignerToolBar"))) {
+ if (o && currentTool() == POINTER_TOOL && (o->inherits("TQDesignerMenuBar") ||
+ o->inherits("TQDesignerToolBar") ||
+ (o->inherits(TQCOMBOBOX_OBJECT_NAME_STRING) || o->inherits(TQTOOLBUTTON_OBJECT_NAME_STRING) || o->inherits("TQDesignerToolBarSeparator")) &&
+ o->tqparent() && o->tqparent()->inherits("TQDesignerToolBar"))) {
TQWidget *w = (TQWidget*)o;
- if (w->inherits(TQTOOLBUTTON_OBJECT_NAME_STRING) || w->inherits(TQCOMBOBOX_OBJECT_NAME_STRING) || w->inherits("QDesignerToolBarSeparator"))
- w = w->parentWidget();
- TQWidget *pw = w->parentWidget();
+ if (w->inherits(TQTOOLBUTTON_OBJECT_NAME_STRING) || w->inherits(TQCOMBOBOX_OBJECT_NAME_STRING) || w->inherits("TQDesignerToolBarSeparator"))
+ w = w->tqparentWidget();
+ TQWidget *pw = w->tqparentWidget();
while (pw) {
if (pw->inherits("FormWindow")) {
- ((FormWindow*)pw)->emitShowProperties(w);
- if (!o->inherits("QDesignerToolBar"))
+ ((FormWindow*)pw)->emitShowProperties(TQT_TQOBJECT(w));
+ if (!o->inherits("TQDesignerToolBar"))
return !o->inherits(TQTOOLBUTTON_OBJECT_NAME_STRING) && !o->inherits(TQMENUBAR_OBJECT_NAME_STRING) &&
- !o->inherits(TQCOMBOBOX_OBJECT_NAME_STRING) && !o->inherits("QDesignerToolBarSeparator");
+ !o->inherits(TQCOMBOBOX_OBJECT_NAME_STRING) && !o->inherits("TQDesignerToolBarSeparator");
}
- pw = pw->parentWidget();
+ pw = pw->tqparentWidget();
}
}
- if (o && (o->inherits("QDesignerToolBar") || o->inherits("QDockWindowHandle"))
+ if (o && (o->inherits("TQDesignerToolBar") || o->inherits(TQDOCKWINDOWHANDLE_OBJECT_NAME_STRING))
&& e->type() == TQEvent::ContextMenu)
break;
if (isAToolBarChild(o) && currentTool() != CONNECT_TOOL)
@@ -719,7 +719,7 @@ bool MainWindow::eventFilter(TQObject *o, TQEvent *e)
case TQEvent::MouseButtonDblClick:
if (!(w = isAFormWindowChild(o)) || o->inherits("SizeHandle") || o->inherits("OrderIndicator")) {
if (o && o->inherits(TQTOOLBUTTON_OBJECT_NAME_STRING) && ((TQToolButton*)o)->isOn() &&
- o->parent() && o->parent()->inherits(TQTOOLBAR_OBJECT_NAME_STRING) && formWindow())
+ o->tqparent() && o->tqparent()->inherits(TQTOOLBAR_OBJECT_NAME_STRING) && formWindow())
formWindow()->setToolFixed();
break;
}
@@ -740,19 +740,19 @@ bool MainWindow::eventFilter(TQObject *o, TQEvent *e)
case TQEvent::Hide:
if (!(w = isAFormWindowChild(o)) || o->inherits("SizeHandle") || o->inherits("OrderIndicator"))
break;
- if (((FormWindow*)w)->isWidgetSelected((TQWidget*)o))
- ((FormWindow*)w)->selectWidget((TQWidget*)o, false);
+ if (((FormWindow*)w)->isWidgetSelected(TQT_TQOBJECT(o)))
+ ((FormWindow*)w)->selectWidget(TQT_TQOBJECT(o), false);
break;
case TQEvent::Enter:
case TQEvent::Leave:
- if (!(w = isAFormWindowChild(o)) || o->inherits("SizeHandle") || o->inherits("OrderIndicator") || o->inherits("QDesignerMenuBar"))
+ if (!(w = isAFormWindowChild(o)) || o->inherits("SizeHandle") || o->inherits("OrderIndicator") || o->inherits("TQDesignerMenuBar"))
break;
return true;
case TQEvent::Resize:
case TQEvent::Move:
if (!(w = isAFormWindowChild(o)) || o->inherits("SizeHandle") || o->inherits("OrderIndicator"))
break;
- if (WidgetFactory::layoutType((TQWidget*)o->parent()) != WidgetFactory::NoLayout) {
+ if (WidgetFactory::tqlayoutType((TQWidget*)o->tqparent()) != WidgetFactory::NoLayout) {
((FormWindow*)w)->updateSelection((TQWidget*)o);
if (e->type() != TQEvent::Resize)
((FormWindow*)w)->updateChildSelections((TQWidget*)o);
@@ -761,25 +761,25 @@ bool MainWindow::eventFilter(TQObject *o, TQEvent *e)
case TQEvent::Close:
break;
case TQEvent::DragEnter:
- if (o == qWorkspace() || o == workspace() || o == workspace()->viewport()) {
+ if (TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(qWorkspace()) || TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(workspace()) || TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(workspace()->viewport())) {
workspace()->contentsDragEnterEvent((TQDragEnterEvent*)e);
return true;
}
break;
case TQEvent::DragMove:
- if (o == qWorkspace() || o == workspace() || o == workspace()->viewport()) {
+ if (TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(qWorkspace()) || TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(workspace()) || TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(workspace()->viewport())) {
workspace()->contentsDragMoveEvent((TQDragMoveEvent*)e);
return true;
}
break;
case TQEvent::Drop:
- if (o == qWorkspace() || o == workspace() || o == workspace()->viewport()) {
+ if (TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(qWorkspace()) || TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(workspace()) || TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(workspace()->viewport())) {
workspace()->contentsDropEvent((TQDropEvent*)e);
return true;
}
break;
case TQEvent::Show:
- if (o != this)
+ if (TQT_BASE_OBJECT(o) != TQT_BASE_OBJECT(this))
break;
if (((TQShowEvent*)e)->spontaneous())
break;
@@ -808,12 +808,12 @@ bool MainWindow::eventFilter(TQObject *o, TQEvent *e)
TQWidget *MainWindow::isAFormWindowChild(TQObject *o) const
{
- if (o->parent() && o->parent()->inherits(TQWIZARD_OBJECT_NAME_STRING) && !o->inherits(TQPUSHBUTTON_OBJECT_NAME_STRING))
+ if (o->tqparent() && o->tqparent()->inherits(TQWIZARD_OBJECT_NAME_STRING) && !o->inherits(TQPUSHBUTTON_OBJECT_NAME_STRING))
return 0;
while (o) {
if (o->inherits("FormWindow"))
return (TQWidget*)o;
- o = o->parent();
+ o = o->tqparent();
}
return 0;
}
@@ -821,11 +821,11 @@ TQWidget *MainWindow::isAFormWindowChild(TQObject *o) const
TQWidget *MainWindow::isAToolBarChild(TQObject *o) const
{
while (o) {
- if (o->inherits("QDesignerToolBar"))
+ if (o->inherits("TQDesignerToolBar"))
return (TQWidget*)o;
if (o->inherits("FormWindow"))
return 0;
- o = o->parent();
+ o = o->tqparent();
}
return 0;
}
@@ -837,7 +837,7 @@ FormWindow *MainWindow::formWindow()
if (qworkspace->activeWindow()->inherits("FormWindow"))
fw = (FormWindow*)qworkspace->activeWindow();
else if (lastActiveFormWindow &&
- qworkspace->windowList().find(lastActiveFormWindow) != -1)
+ qworkspace->windowList().tqfind(lastActiveFormWindow) != -1)
fw = lastActiveFormWindow;
return fw;
}
@@ -848,7 +848,7 @@ void MainWindow::insertFormWindow(FormWindow *fw)
{
if (fw)
TQWhatsThis::add(fw, i18n("<b>The Form Window</b>"
- "<p>Use the various tools to add widgets or to change the layout "
+ "<p>Use the various tools to add widgets or to change the tqlayout "
"and behavior of the components in the form. Select one or multiple "
"widgets to move them or lay them out. If a single widget is chosen it can "
"be resized using the resize handles.</p>"
@@ -872,12 +872,12 @@ void MainWindow::insertFormWindow(FormWindow *fw)
fw->show();
fw->currentToolChanged();
- if (fw->caption().isEmpty() && qstrlen(fw->name()) )
+ if (fw->caption().isEmpty() && tqstrlen(fw->name()) )
fw->setCaption(fw->name());
fw->mainContainer()->setCaption(fw->caption());
WidgetFactory::saveDefaultProperties(fw->mainContainer(),
WidgetDatabase::
- idFromClassName(WidgetFactory::classNameOf(fw->mainContainer())));
+ idFromClassName(WidgetFactory::classNameOf(TQT_TQOBJECT(fw->mainContainer()))));
activeWindowChanged(fw);
emit formWindowsChanged();
}
@@ -934,7 +934,7 @@ void MainWindow::activeWindowChanged(TQWidget *w)
emit hasActiveForm(false);
propertyEditor->clear();
hierarchyView->clear();
- updateUndoRedo(false, false, TQString::null, TQString::null);
+ updateUndoRedo(false, false, TQString(), TQString());
}
selectionChanged();
@@ -952,11 +952,11 @@ void MainWindow::updateUndoRedo(bool undoAvailable, bool redoAvailable,
actionEditUndo->setEnabled(undoAvailable);
actionEditRedo->setEnabled(redoAvailable);
if (!undoCmd.isEmpty())
- actionEditUndo->setText(i18n("&Undo: %1").arg(undoCmd));
+ actionEditUndo->setText(i18n("&Undo: %1").tqarg(undoCmd));
else
actionEditUndo->setText(i18n("&Undo: Not Available"));
if (!redoCmd.isEmpty())
- actionEditRedo->setText(i18n("&Redo: %1").arg(redoCmd));
+ actionEditRedo->setText(i18n("&Redo: %1").tqarg(redoCmd));
else
actionEditRedo->setText(i18n("&Redo: Not Available"));
@@ -1012,18 +1012,18 @@ void MainWindow::popupWidgetMenu(const TQPoint &gp, FormWindow * /*fw*/, TQWidge
void MainWindow::setupRMBProperties(TQValueList<int> &ids, TQMap<TQString, int> &props, TQWidget *w)
{
- const TQMetaProperty* text = w->metaObject()->property(w->metaObject()->findProperty("text", true), true);
+ const TQMetaProperty* text = w->tqmetaObject()->property(w->tqmetaObject()->tqfindProperty("text", true), true);
if (text && qstrcmp(text->type(), TQSTRING_OBJECT_NAME_STRING) != 0)
text = 0;
- const TQMetaProperty* title = w->metaObject()->property(w->metaObject()->findProperty("title", true), true);
+ const TQMetaProperty* title = w->tqmetaObject()->property(w->tqmetaObject()->tqfindProperty("title", true), true);
if (title && qstrcmp(title->type(), TQSTRING_OBJECT_NAME_STRING) != 0)
title = 0;
const TQMetaProperty* pagetitle =
- w->metaObject()->property(w->metaObject()->findProperty("pageTitle", true), true);
+ w->tqmetaObject()->property(w->tqmetaObject()->tqfindProperty("pageTitle", true), true);
if (pagetitle && qstrcmp(pagetitle->type(), TQSTRING_OBJECT_NAME_STRING) != 0)
pagetitle = 0;
const TQMetaProperty* pixmap =
- w->metaObject()->property(w->metaObject()->findProperty("pixmap", true), true);
+ w->tqmetaObject()->property(w->tqmetaObject()->tqfindProperty("pixmap", true), true);
if (pixmap && qstrcmp(pixmap->type(), TQPIXMAP_OBJECT_NAME_STRING) != 0)
pixmap = 0;
@@ -1056,7 +1056,7 @@ void MainWindow::setupRMBProperties(TQValueList<int> &ids, TQMap<TQString, int>
void MainWindow::setupRMBSpecialCommands(TQValueList<int> &ids, TQMap<TQString, int> &commands, TQWidget *w)
{
int id;
- // KommanderWidget doesn't derive from QObject
+ // KommanderWidget doesn't derive from TQObject
KommanderWidget *atw = dynamic_cast<KommanderWidget *>(w);
if(atw)
{
@@ -1071,7 +1071,7 @@ void MainWindow::setupRMBSpecialCommands(TQValueList<int> &ids, TQMap<TQString,
if (w->inherits(TQTABWIDGET_OBJECT_NAME_STRING)) {
if (ids.isEmpty())
ids << rmbWidgets->insertSeparator(0);
- if (((QDesignerTabWidget*)w)->count() > 1) {
+ if (((TQDesignerTabWidget*)w)->count() > 1) {
ids << (id = rmbWidgets->insertItem(i18n("Delete Page"), -1, 0));
commands.insert("remove", id);
}
@@ -1088,7 +1088,7 @@ void MainWindow::setupRMBSpecialCommands(TQValueList<int> &ids, TQMap<TQString,
ids << (id = rmbWidgets->insertItem(i18n("Add Page"), -1, 0));
commands.insert("add", id);
}
- if (WidgetFactory::hasSpecialEditor(WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(w))))
+ if (WidgetFactory::hasSpecialEditor(WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(TQT_TQOBJECT(w)))))
{
if (ids.isEmpty())
ids << rmbWidgets->insertSeparator(0);
@@ -1101,7 +1101,7 @@ void MainWindow::setupRMBSpecialCommands(TQValueList<int> &ids, TQMap<TQString,
{
int id;
- // KommanderWidget doesn't derive from QObject
+ // KommanderWidget doesn't derive from TQObject
KommanderWidget *atw = dynamic_cast<KommanderWidget *>(fw->mainContainer());
if(atw)
{
@@ -1153,49 +1153,49 @@ void MainWindow::handleRMBProperties(int id, TQMap<TQString, int> &props, TQWidg
text = KInputDialog::getText(i18n("Text"), i18n("New text:"), w->property("text").toString(), &ok, this);
}
if (ok) {
- TQString pn(i18n("Set the 'text' of '%1'").arg(w->name()));
- SetPropertyCommand *cmd = new SetPropertyCommand(pn, formWindow(), w, propertyEditor,
+ TQString pn(i18n("Set the 'text' of '%1'").tqarg(w->name()));
+ SetPropertyCommand *cmd = new SetPropertyCommand(pn, formWindow(), TQT_TQOBJECT(w), propertyEditor,
"text", w->property("text"),
- text, TQString::null, TQString::null);
+ text, TQString(), TQString());
cmd->execute();
formWindow()->commandHistory()->addCommand(cmd);
- MetaDataBase::setPropertyChanged(w, "text", true);
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(w), "text", true);
}
} else if (id == props[ "title" ]) {
bool ok = false;
TQString title = KInputDialog::getText(i18n("Title"), i18n("New title:"), w->property("title").toString(), &ok, this);
if (ok) {
- TQString pn(i18n("Set the 'title' of '%1'").arg(w->name()));
- SetPropertyCommand *cmd = new SetPropertyCommand(pn, formWindow(), w, propertyEditor,
+ TQString pn(i18n("Set the 'title' of '%1'").tqarg(w->name()));
+ SetPropertyCommand *cmd = new SetPropertyCommand(pn, formWindow(), TQT_TQOBJECT(w), propertyEditor,
"title", w->property("title"),
- title, TQString::null, TQString::null);
+ title, TQString(), TQString());
cmd->execute();
formWindow()->commandHistory()->addCommand(cmd);
- MetaDataBase::setPropertyChanged(w, "title", true);
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(w), "title", true);
}
} else if (id == props[ "pagetitle" ]) {
bool ok = false;
TQString text = KInputDialog::getText(i18n("Page Title"), i18n("New page title:"), w->property("pageTitle").toString(), &ok, this);
if (ok) {
- TQString pn(i18n("Set the 'pageTitle' of '%1'").arg(w->name()));
- SetPropertyCommand *cmd = new SetPropertyCommand(pn, formWindow(), w, propertyEditor,
+ TQString pn(i18n("Set the 'pageTitle' of '%1'").tqarg(w->name()));
+ SetPropertyCommand *cmd = new SetPropertyCommand(pn, formWindow(), TQT_TQOBJECT(w), propertyEditor,
"pageTitle", w->property("pageTitle"),
- text, TQString::null, TQString::null);
+ text, TQString(), TQString());
cmd->execute();
formWindow()->commandHistory()->addCommand(cmd);
- MetaDataBase::setPropertyChanged(w, "pageTitle", true);
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(w), "pageTitle", true);
}
} else if (id == props[ "pixmap" ]) {
- TQPixmap oldPix = w->property("pixmap").toPixmap();
+ TQPixmap oldPix = TQVariant(w->property("pixmap")).toPixmap();
TQPixmap pix = qChoosePixmap(this, formWindow(), oldPix);
if (!pix.isNull()) {
- TQString pn(i18n("Set the 'pixmap' of '%1'").arg(w->name()));
- SetPropertyCommand *cmd = new SetPropertyCommand(pn, formWindow(), w, propertyEditor,
+ TQString pn(i18n("Set the 'pixmap' of '%1'").tqarg(w->name()));
+ SetPropertyCommand *cmd = new SetPropertyCommand(pn, formWindow(), TQT_TQOBJECT(w), propertyEditor,
"pixmap", w->property("pixmap"),
- pix, TQString::null, TQString::null);
+ pix, TQString(), TQString());
cmd->execute();
formWindow()->commandHistory()->addCommand(cmd);
- MetaDataBase::setPropertyChanged(w, "pixmap", true);
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(w), "pixmap", true);
}
}
}
@@ -1214,15 +1214,15 @@ void MainWindow::handleRMBSpecialCommands(int id, TQMap<TQString, int> &commands
if (w->inherits(TQTABWIDGET_OBJECT_NAME_STRING)) {
TQTabWidget *tw = (TQTabWidget*)w;
if (id == commands[ "add" ]) {
- AddTabPageCommand *cmd = new AddTabPageCommand(i18n("Add Page to %1").arg(tw->name()), formWindow(),
+ AddTabPageCommand *cmd = new AddTabPageCommand(i18n("Add Page to %1").tqarg(tw->name()), formWindow(),
tw, "Tab");
formWindow()->commandHistory()->addCommand(cmd);
cmd->execute();
} else if (id == commands[ "remove" ]) {
if (tw->currentPage()) {
- QDesignerTabWidget *dtw = (QDesignerTabWidget*)tw;
+ TQDesignerTabWidget *dtw = (TQDesignerTabWidget*)tw;
DeleteTabPageCommand *cmd = new DeleteTabPageCommand(i18n("Delete Page %1 of %2").
- arg(dtw->pageTitle()).arg(tw->name()),
+ tqarg(dtw->pageTitle()).tqarg(tw->name()),
formWindow(), tw, tw->currentPage());
formWindow()->commandHistory()->addCommand(cmd);
cmd->execute();
@@ -1232,7 +1232,7 @@ void MainWindow::handleRMBSpecialCommands(int id, TQMap<TQString, int> &commands
if (w->inherits(TQTOOLBOX_OBJECT_NAME_STRING)) {
TQToolBox *tw = (TQToolBox*)w;
if (id == commands[ "add" ]) {
- AddToolBoxPageCommand *cmd = new AddToolBoxPageCommand(i18n("Add Page to %1").arg(tw->name()), formWindow(),
+ AddToolBoxPageCommand *cmd = new AddToolBoxPageCommand(i18n("Add Page to %1").tqarg(tw->name()), formWindow(),
tw, "Page");
formWindow()->commandHistory()->addCommand(cmd);
cmd->execute();
@@ -1240,16 +1240,16 @@ void MainWindow::handleRMBSpecialCommands(int id, TQMap<TQString, int> &commands
if (tw->currentItem()) {
EditorToolBox *dtw = (EditorToolBox*)tw;
DeleteToolBoxPageCommand *cmd = new DeleteToolBoxPageCommand(i18n("Delete Page %1 of %2").
- arg(dtw->pageTitle()).arg(tw->name()),
+ tqarg(dtw->pageTitle()).tqarg(tw->name()),
formWindow(), tw, tw->currentItem());
formWindow()->commandHistory()->addCommand(cmd);
cmd->execute();
}
}
}
- if (WidgetFactory::hasSpecialEditor(WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(w)))) {
+ if (WidgetFactory::hasSpecialEditor(WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(TQT_TQOBJECT(w))))) {
if (id == commands[ "edit" ])
- WidgetFactory::editWidget(WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(w)), this, w, formWindow());
+ WidgetFactory::editWidget(WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(TQT_TQOBJECT(w))), this, w, formWindow());
}
}
@@ -1267,15 +1267,15 @@ void MainWindow::handleRMBSpecialCommands(int id, TQMap<TQString, int> &commands
if (fw->mainContainer()->inherits(TQWIZARD_OBJECT_NAME_STRING)) {
TQWizard *wiz = (TQWizard*)fw->mainContainer();
if (id == commands[ "add" ]) {
- AddWizardPageCommand *cmd = new AddWizardPageCommand(i18n("Add Page to %1").arg(wiz->name()), formWindow(),
+ AddWizardPageCommand *cmd = new AddWizardPageCommand(i18n("Add Page to %1").tqarg(wiz->name()), formWindow(),
wiz, "Page");
formWindow()->commandHistory()->addCommand(cmd);
cmd->execute();
} else if (id == commands[ "remove" ]) {
if (wiz->currentPage()) {
- QDesignerWizard *dw = (QDesignerWizard*)wiz;
+ TQDesignerWizard *dw = (TQDesignerWizard*)wiz;
DeleteWizardPageCommand *cmd = new DeleteWizardPageCommand(i18n("Delete Page %1 of %2").
- arg(dw->pageTitle()).arg(wiz->name()),
+ tqarg(dw->pageTitle()).tqarg(wiz->name()),
formWindow(), wiz, wiz->indexOf(wiz->currentPage()));
formWindow()->commandHistory()->addCommand(cmd);
cmd->execute();
@@ -1287,10 +1287,10 @@ void MainWindow::handleRMBSpecialCommands(int id, TQMap<TQString, int> &commands
} else if (id == commands[ "rename" ]) {
bool ok = false;
- QDesignerWizard *dw = (QDesignerWizard*)wiz;
+ TQDesignerWizard *dw = (TQDesignerWizard*)wiz;
TQString text = KInputDialog::getText(i18n("Page Title"), i18n("New page title:"), dw->pageTitle(), &ok, this);
if (ok) {
- TQString pn(i18n("Rename page %1 of %2").arg(dw->pageTitle()).arg(wiz->name()));
+ TQString pn(i18n("Rename page %1 of %2").tqarg(dw->pageTitle()).tqarg(wiz->name()));
RenameWizardPageCommand *cmd = new RenameWizardPageCommand(pn, formWindow()
, wiz, wiz->indexOf(wiz->currentPage()), text);
formWindow()->commandHistory()->addCommand(cmd);
@@ -1300,11 +1300,11 @@ void MainWindow::handleRMBSpecialCommands(int id, TQMap<TQString, int> &commands
} else if (fw->mainContainer()->inherits(TQMAINWINDOW_OBJECT_NAME_STRING)) {
TQMainWindow *mw = (TQMainWindow*)fw->mainContainer();
if (id == commands[ "add_toolbar" ]) {
- AddToolBarCommand *cmd = new AddToolBarCommand(i18n("Add Toolbar to '%1'").arg(formWindow()->name()), formWindow(), mw);
+ AddToolBarCommand *cmd = new AddToolBarCommand(i18n("Add Toolbar to '%1'").tqarg(formWindow()->name()), formWindow(), mw);
formWindow()->commandHistory()->addCommand(cmd);
cmd->execute();
} else if (id == commands[ "add_menu_item" ]) {
- AddMenuCommand *cmd = new AddMenuCommand(i18n("Add Menu to '%1'").arg(formWindow()->name()), formWindow(), mw);
+ AddMenuCommand *cmd = new AddMenuCommand(i18n("Add Menu to '%1'").tqarg(formWindow()->name()), formWindow(), mw);
formWindow()->commandHistory()->addCommand(cmd);
cmd->execute();
}
@@ -1320,8 +1320,8 @@ void MainWindow::clipboardChanged()
void MainWindow::selectionChanged()
{
- layoutChilds = false;
- layoutSelected = false;
+ tqlayoutChilds = false;
+ tqlayoutSelected = false;
breakLayout = false;
if (!formWindow()) {
actionEditCut->setEnabled(false);
@@ -1358,7 +1358,7 @@ void MainWindow::selectionChanged()
int unlaidout = 0;
int laidout = 0;
for (TQWidget *w = widgets.first(); w; w = widgets.next()) {
- if (!w->parentWidget() || WidgetFactory::layoutType(w->parentWidget()) == WidgetFactory::NoLayout)
+ if (!w->tqparentWidget() || WidgetFactory::tqlayoutType(w->tqparentWidget()) == WidgetFactory::NoLayout)
unlaidout++;
else
laidout++;
@@ -1370,27 +1370,27 @@ void MainWindow::selectionChanged()
actionEditGridLayout->setEnabled(unlaidout > 1);
actionEditBreakLayout->setEnabled(laidout > 0);
actionEditAdjustSize->setEnabled(laidout > 0);
- layoutSelected = unlaidout > 1;
+ tqlayoutSelected = unlaidout > 1;
breakLayout = laidout > 0;
} else if (selectedWidgets == 1) {
TQWidget *w = widgets.first();
- bool isContainer = WidgetDatabase::isContainer(WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(w))) ||
+ bool isContainer = WidgetDatabase::isContainer(WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(TQT_TQOBJECT(w)))) ||
w == formWindow()->mainContainer();
- actionEditAdjustSize->setEnabled(!w->parentWidget() ||
- WidgetFactory::layoutType(w->parentWidget()) == WidgetFactory::NoLayout);
+ actionEditAdjustSize->setEnabled(!w->tqparentWidget() ||
+ WidgetFactory::tqlayoutType(w->tqparentWidget()) == WidgetFactory::NoLayout);
if (!isContainer) {
actionEditHLayout->setEnabled(false);
actionEditVLayout->setEnabled(false);
actionEditGridLayout->setEnabled(false);
- if (w->parentWidget() && WidgetFactory::layoutType(w->parentWidget()) != WidgetFactory::NoLayout) {
- actionEditBreakLayout->setEnabled(!isAToolBarChild(w));
+ if (w->tqparentWidget() && WidgetFactory::tqlayoutType(w->tqparentWidget()) != WidgetFactory::NoLayout) {
+ actionEditBreakLayout->setEnabled(!isAToolBarChild(TQT_TQOBJECT(w)));
breakLayout = true;
} else {
actionEditBreakLayout->setEnabled(false);
}
} else {
- if (WidgetFactory::layoutType(w) == WidgetFactory::NoLayout) {
+ if (WidgetFactory::tqlayoutType(w) == WidgetFactory::NoLayout) {
if (!formWindow()->hasInsertedChildren(w)) {
actionEditHLayout->setEnabled(false);
actionEditVLayout->setEnabled(false);
@@ -1401,24 +1401,24 @@ void MainWindow::selectionChanged()
actionEditVLayout->setEnabled(true);
actionEditGridLayout->setEnabled(true);
actionEditBreakLayout->setEnabled(false);
- layoutChilds = true;
+ tqlayoutChilds = true;
}
- if (w->parentWidget() && WidgetFactory::layoutType(w->parentWidget()) != WidgetFactory::NoLayout) {
- actionEditBreakLayout->setEnabled(!isAToolBarChild(w));
+ if (w->tqparentWidget() && WidgetFactory::tqlayoutType(w->tqparentWidget()) != WidgetFactory::NoLayout) {
+ actionEditBreakLayout->setEnabled(!isAToolBarChild(TQT_TQOBJECT(w)));
breakLayout = true;
}
} else {
actionEditHLayout->setEnabled(false);
actionEditVLayout->setEnabled(false);
actionEditGridLayout->setEnabled(false);
- actionEditBreakLayout->setEnabled(!isAToolBarChild(w));
+ actionEditBreakLayout->setEnabled(!isAToolBarChild(TQT_TQOBJECT(w)));
breakLayout = true;
}
}
} else if (selectedWidgets == 0 && formWindow()) {
actionEditAdjustSize->setEnabled(true);
TQWidget *w = formWindow()->mainContainer();
- if (WidgetFactory::layoutType(w) == WidgetFactory::NoLayout) {
+ if (WidgetFactory::tqlayoutType(w) == WidgetFactory::NoLayout) {
if (!formWindow()->hasInsertedChildren(w)) {
actionEditHLayout->setEnabled(false);
actionEditVLayout->setEnabled(false);
@@ -1429,7 +1429,7 @@ void MainWindow::selectionChanged()
actionEditVLayout->setEnabled(true);
actionEditGridLayout->setEnabled(true);
actionEditBreakLayout->setEnabled(false);
- layoutChilds = true;
+ tqlayoutChilds = true;
}
} else {
actionEditHLayout->setEnabled(false);
@@ -1464,7 +1464,7 @@ void MainWindow::writeConfig()
config->setGroup("Background");
config->writeEntry("UsePixmap", backPix);
- config->writeEntry("Color", qworkspace->backgroundColor().name());
+ config->writeEntry("Color", TQString(qworkspace->backgroundColor().name()));
/*
config->setGroup("Geometry");
@@ -1491,7 +1491,7 @@ void MainWindow::readConfig()
restoreConfig = config->readBoolEntry("RestoreWorkspace", true);
splashScreen = config->readBoolEntry("SplashScreen", true);
docPath = config->readEntry("DocPath", docPath);
- templPath = config->readEntry("TemplatePath", TQString::null);
+ templPath = config->readEntry("TemplatePath", TQString());
config->setGroup("Grid");
sGrid = config->readBoolEntry("Snap", true);
@@ -1541,9 +1541,9 @@ HierarchyView *MainWindow::objectHierarchy() const
return hierarchyView;
}
-TQPopupMenu *MainWindow::setupNormalHierarchyMenu(TQWidget *parent)
+TQPopupMenu *MainWindow::setupNormalHierarchyMenu(TQWidget *tqparent)
{
- TQPopupMenu *menu = new TQPopupMenu(parent);
+ TQPopupMenu *menu = new TQPopupMenu(tqparent);
actionEditCut->plug(menu);
actionEditCopy->plug(menu);
@@ -1553,12 +1553,12 @@ TQPopupMenu *MainWindow::setupNormalHierarchyMenu(TQWidget *parent)
return menu;
}
-TQPopupMenu *MainWindow::setupTabWidgetHierarchyMenu(TQWidget *parent, const char *addSlot, const char *removeSlot)
+TQPopupMenu *MainWindow::setupTabWidgetHierarchyMenu(TQWidget *tqparent, const char *addSlot, const char *removeSlot)
{
- TQPopupMenu *menu = new TQPopupMenu(parent);
+ TQPopupMenu *menu = new TQPopupMenu(tqparent);
- menu->insertItem(i18n("Add Page"), parent, addSlot);
- menu->insertItem(i18n("Delete Page"), parent, removeSlot);
+ menu->insertItem(i18n("Add Page"), tqparent, addSlot);
+ menu->insertItem(i18n("Delete Page"), tqparent, removeSlot);
menu->insertSeparator();
actionEditCut->plug(menu);
actionEditCopy->plug(menu);
@@ -1620,15 +1620,15 @@ ActionEditor *MainWindow::actioneditor() const
bool MainWindow::openEditor(TQWidget* w, FormWindow*)
{
- if (WidgetFactory::hasSpecialEditor(WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(w)))) {
- statusBar()->message(i18n("Edit %1...").arg(w->className()));
- WidgetFactory::editWidget(WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(w)), this, w, formWindow());
+ if (WidgetFactory::hasSpecialEditor(WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(TQT_TQOBJECT(w))))) {
+ statusBar()->message(i18n("Edit %1...").tqarg(w->className()));
+ WidgetFactory::editWidget(WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(TQT_TQOBJECT(w))), this, w, formWindow());
statusBar()->clear();
return true;
}
- const TQMetaProperty* text = w->metaObject()->property(w->metaObject()->findProperty("text", true), true);
- const TQMetaProperty* title = w->metaObject()->property(w->metaObject()->findProperty("title", true), true);
+ const TQMetaProperty* text = w->tqmetaObject()->property(w->tqmetaObject()->tqfindProperty("text", true), true);
+ const TQMetaProperty* title = w->tqmetaObject()->property(w->tqmetaObject()->tqfindProperty("title", true), true);
if (text && text->designable(w)) {
bool ok = false;
TQString text;
@@ -1639,13 +1639,13 @@ bool MainWindow::openEditor(TQWidget* w, FormWindow*)
text = KInputDialog::getText(i18n("Text"), i18n("New text:"), w->property("text").toString(), &ok, this);
}
if (ok) {
- TQString pn(i18n("Set the 'text' of '%2'").arg(w->name()));
- SetPropertyCommand *cmd = new SetPropertyCommand(pn, formWindow(), w, propertyEditor,
+ TQString pn(i18n("Set the 'text' of '%2'").tqarg(w->name()));
+ SetPropertyCommand *cmd = new SetPropertyCommand(pn, formWindow(), TQT_TQOBJECT(w), propertyEditor,
"text", w->property("text"),
- text, TQString::null, TQString::null);
+ text, TQString(), TQString());
cmd->execute();
formWindow()->commandHistory()->addCommand(cmd);
- MetaDataBase::setPropertyChanged(w, "text", true);
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(w), "text", true);
}
return true;
}
@@ -1654,13 +1654,13 @@ bool MainWindow::openEditor(TQWidget* w, FormWindow*)
TQString text;
text = KInputDialog::getText(i18n("Title"), i18n("New title:"), w->property("title").toString(), &ok, this);
if (ok) {
- TQString pn(i18n("Set the 'title' of '%2'").arg(w->name()));
- SetPropertyCommand *cmd = new SetPropertyCommand(pn, formWindow(), w, propertyEditor,
+ TQString pn(i18n("Set the 'title' of '%2'").tqarg(w->name()));
+ SetPropertyCommand *cmd = new SetPropertyCommand(pn, formWindow(), TQT_TQOBJECT(w), propertyEditor,
"title", w->property("title"),
- text, TQString::null, TQString::null);
+ text, TQString(), TQString());
cmd->execute();
formWindow()->commandHistory()->addCommand(cmd);
- MetaDataBase::setPropertyChanged(w, "title", true);
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(w), "title", true);
}
return true;
}
@@ -1706,9 +1706,9 @@ TQString MainWindow::documentationPath() const
TQString result = docPath;
if (docPath[0] == '$') {
- int fs = docPath.find('/');
+ int fs = docPath.tqfind('/');
if (fs == -1)
- fs = docPath.find('\\');
+ fs = docPath.tqfind('\\');
if (fs > -1) {
result = docPath.mid(1, fs-1);
@@ -1756,7 +1756,7 @@ void MainWindow::checkTempFiles()
void MainWindow::showDialogHelp()
{
TQWidget *w = (TQWidget*)sender();
- w = w->topLevelWidget();
+ w = w->tqtopLevelWidget();
TQString link = "designer-manual-12.html#";
@@ -1777,9 +1777,9 @@ void MainWindow::showDialogHelp()
else if (w->inherits("DatabaseConnectionBase"))
link += "dialog-edit-database-connections";
else if (w->inherits("FindDialog"))
- link += "dialog-find-text";
+ link += "dialog-tqfind-text";
else if (w->inherits("ReplaceDialog"))
- link += "dialog-replace-text";
+ link += "dialog-tqreplace-text";
else if (w->inherits("GotoLineDialog"))
link += "dialog-go-to-line";
else if (w->inherits("ConnectionEditorBase"))
@@ -1836,13 +1836,13 @@ void MainWindow::setModified(bool b, TQWidget *window)
((FormWindow *) w)->modificationChanged(b);
return;
}
- w = w->parentWidget(true);
+ w = w->tqparentWidget(true);
if (w->inherits("FormWindow"))
{
((FormWindow *) w)->modificationChanged(b);
return;
}
- w = w->parentWidget(true);
+ w = w->tqparentWidget(true);
}
}
@@ -1869,20 +1869,20 @@ void MainWindow::formNameChanged(FormWindow*)
int MainWindow::currentLayoutDefaultSpacing() const
{
if (((MainWindow*)this)->formWindow())
- return ((MainWindow*)this)->formWindow()->layoutDefaultSpacing();
+ return ((MainWindow*)this)->formWindow()->tqlayoutDefaultSpacing();
return BOXLAYOUT_DEFAULT_SPACING;
}
int MainWindow::currentLayoutDefaultMargin() const
{
if (((MainWindow*)this)->formWindow())
- return ((MainWindow*)this)->formWindow()->layoutDefaultMargin();
+ return ((MainWindow*)this)->formWindow()->tqlayoutDefaultMargin();
return BOXLAYOUT_DEFAULT_MARGIN;
}
TQString MainWindow::whatsThisFrom(const TQString&)
{
- return TQString::null;
+ return TQString();
}
void MainWindow::slotActivePartChanged(KParts::Part * part)
diff --git a/kommander/editor/mainwindow.h b/kommander/editor/mainwindow.h
index 1f4a9346..a8ac770e 100644
--- a/kommander/editor/mainwindow.h
+++ b/kommander/editor/mainwindow.h
@@ -1,5 +1,5 @@
/**********************************************************************
- This file is based on Qt Designer, Copyright (C) 2000 Trolltech AS. All rights reserved.
+ This file is based on TQt Designer, Copyright (C) 2000 Trolltech AS. All rights reserved.
This file may be distributed and/or modified under the terms of the
GNU General Public License version 2 as published by the Free Software
@@ -53,7 +53,7 @@ class MessageLog;
class ReplaceDialog;
class Workspace;
-#if defined(Q_FULL_TEMPLATE_INSTANTIATION)
+#if defined(TQ_FULL_TEMPLATE_INSTANTIATION)
#include <tqtoolbar.h>
#else
class TQToolBar;
@@ -68,6 +68,7 @@ namespace KParts {
class MainWindow : public KParts::DockMainWindow
{
Q_OBJECT
+ TQ_OBJECT
public:
MainWindow( bool asClient );
@@ -93,8 +94,8 @@ public:
void popupFormWindowMenu( const TQPoint &gp, FormWindow *fw );
void popupWidgetMenu( const TQPoint &gp, FormWindow *fw, TQWidget *w );
- TQPopupMenu *setupNormalHierarchyMenu( TQWidget *parent );
- TQPopupMenu *setupTabWidgetHierarchyMenu( TQWidget *parent, const char *addSlot, const char *removeSlot );
+ TQPopupMenu *setupNormalHierarchyMenu( TQWidget *tqparent );
+ TQPopupMenu *setupTabWidgetHierarchyMenu( TQWidget *tqparent, const char *addSlot, const char *removeSlot );
FormWindow *openFormWindow( const TQString &fn, bool validFileName = TRUE, FormFile *ff = 0 );
@@ -255,7 +256,7 @@ private:
TQWorkspace *qworkspace;
KMenuBar *menubar;
FormWindow *lastActiveFormWindow;
- bool breakLayout, layoutChilds, layoutSelected;
+ bool breakLayout, tqlayoutChilds, tqlayoutSelected;
TQPoint grd;
bool sGrid, snGrid;
bool restoreConfig;
@@ -279,7 +280,7 @@ private:
TQPopupMenu *rmbFormWindow;
TQPopupMenu *windowMenu, *fileMenu;
- TQToolBar *layoutToolBar;
+ TQToolBar *tqlayoutToolBar;
KToolBar *fileTb;
Preferences *prefDia;
diff --git a/kommander/editor/mainwindowactions.cpp b/kommander/editor/mainwindowactions.cpp
index a4d4c430..f57afd72 100644
--- a/kommander/editor/mainwindowactions.cpp
+++ b/kommander/editor/mainwindowactions.cpp
@@ -1,5 +1,5 @@
/**********************************************************************
- This file is based on Qt Designer, Copyright (C) 2000 Trolltech AS. All rights reserved.
+ This file is based on TQt Designer, Copyright (C) 2000 Trolltech AS. All rights reserved.
This file may be distributed and/or modified under the terms of the
GNU General Public License version 2 as published by the Free Software
@@ -19,6 +19,10 @@
#include "mainwindow.h"
+#ifdef QT_NO_SQL
+#define TQT_NO_SQL
+#endif // QT_NO_SQL
+
#include <tqapplication.h>
#include <tqclipboard.h>
#include <tqfileinfo.h>
@@ -26,7 +30,7 @@
#include <tqlistbox.h>
#include <tqsignalmapper.h>
#include <tqspinbox.h>
-#include <tqstatusbar.h>
+#include <statusbar.h>
#include <tqstylefactory.h>
#include <tqtooltip.h>
#include <tqwhatsthis.h>
@@ -47,7 +51,7 @@
#include "connectioneditorimpl.h"
#include "actioneditorimpl.h"
#include "formfile.h"
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
#include "dbconnectionsimpl.h"
#include "dbconnectionimpl.h"
#endif
@@ -92,81 +96,81 @@ int forms = 0;
void MainWindow::setupEditActions()
{
- actionEditUndo = KStdAction::undo(this, TQT_SLOT(editUndo()), actionCollection());
+ actionEditUndo = KStdAction::undo(TQT_TQOBJECT(this), TQT_SLOT(editUndo()), actionCollection());
actionEditUndo->setText(i18n("&Undo: Not Available"));
actionEditUndo->setToolTip(i18n("Undoes the last action"));
actionEditUndo->setWhatsThis(whatsThisFrom("Edit|Undo"));
actionEditUndo->setEnabled(false);
- actionEditRedo = KStdAction::redo(this, TQT_SLOT(editRedo()), actionCollection());
+ actionEditRedo = KStdAction::redo(TQT_TQOBJECT(this), TQT_SLOT(editRedo()), actionCollection());
actionEditRedo->setText(i18n("&Redo: Not Available"));
actionEditRedo->setToolTip(i18n("Redoes the last undone operation"));
actionEditRedo->setWhatsThis(whatsThisFrom("Edit|Redo"));
actionEditRedo->setEnabled(false);
- actionEditCut = KStdAction::cut(this, TQT_SLOT(editCut()), actionCollection());
+ actionEditCut = KStdAction::cut(TQT_TQOBJECT(this), TQT_SLOT(editCut()), actionCollection());
actionEditCut->setToolTip(i18n("Cuts the selected widgets and puts them on the clipboard"));
actionEditCut->setWhatsThis(whatsThisFrom("Edit|Cut"));
actionEditCut->setEnabled(false);
- actionEditCopy = KStdAction::copy(this, TQT_SLOT(editCopy()), actionCollection());
+ actionEditCopy = KStdAction::copy(TQT_TQOBJECT(this), TQT_SLOT(editCopy()), actionCollection());
actionEditCopy->setToolTip(i18n("Copies the selected widgets to the clipboard"));
actionEditCopy->setWhatsThis(whatsThisFrom("Edit|Copy"));
actionEditCopy->setEnabled(false);
- actionEditPaste = KStdAction::paste(this, TQT_SLOT(editPaste()), actionCollection());
+ actionEditPaste = KStdAction::paste(TQT_TQOBJECT(this), TQT_SLOT(editPaste()), actionCollection());
actionEditPaste->setToolTip(i18n("Pastes the clipboard's contents"));
actionEditPaste->setWhatsThis(whatsThisFrom("Edit|Paste"));
actionEditPaste->setEnabled(false);
- actionEditDelete = new KAction(i18n("Delete"), Key_Delete, this, TQT_SLOT(editDelete()),
+ actionEditDelete = new KAction(i18n("Delete"), Key_Delete, TQT_TQOBJECT(this), TQT_SLOT(editDelete()),
actionCollection(), "edit_delete");
actionEditDelete->setToolTip(i18n("Deletes the selected widgets"));
actionEditDelete->setWhatsThis(whatsThisFrom("Edit|Delete"));
actionEditDelete->setEnabled(false);
- actionEditSelectAll = KStdAction::selectAll(this, TQT_SLOT(editSelectAll()), actionCollection());
+ actionEditSelectAll = KStdAction::selectAll(TQT_TQOBJECT(this), TQT_SLOT(editSelectAll()), actionCollection());
actionEditSelectAll->setToolTip(i18n("Selects all widgets"));
actionEditSelectAll->setWhatsThis(whatsThisFrom("Edit|Select All"));
actionEditRaise = new KAction(i18n("Bring to Front"), createIconSet("editraise.xpm"),
- KShortcut::null(), this, TQT_SLOT(editRaise()), actionCollection(), "edit_raise");
+ KShortcut::null(), TQT_TQOBJECT(this), TQT_SLOT(editRaise()), actionCollection(), "edit_raise");
actionEditRaise->setToolTip(i18n("Raises the selected widgets"));
actionEditRaise->setEnabled(false);
actionEditLower = new KAction(i18n("Send to Back"), createIconSet("editlower.xpm"),
- KShortcut::null(), this, TQT_SLOT(editLower()), actionCollection(), "edit_lower");
+ KShortcut::null(), TQT_TQOBJECT(this), TQT_SLOT(editLower()), actionCollection(), "edit_lower");
actionEditLower->setToolTip(i18n("Lowers the selected widgets"));
actionEditLower->setWhatsThis(i18n("Lowers the selected widgets"));
actionEditLower->setEnabled(false);
- actionEditFindGlobal = new KAction(i18n("Find in Form..."), CTRL + ALT + Key_F, this, TQT_SLOT(editFindGlobal()), actionCollection(), "edit_find_global");
+ actionEditFindGlobal = new KAction(i18n("Find in Form..."), CTRL + ALT + Key_F, TQT_TQOBJECT(this), TQT_SLOT(editFindGlobal()), actionCollection(), "edit_find_global");
actionEditFindGlobal->setToolTip(i18n("Search for a text in the whole form."));
actionEditFindGlobal->setWhatsThis(whatsThisFrom("Edit|Find in Form"));
connect(this, TQT_SIGNAL(hasActiveForm(bool)), actionEditFindGlobal, TQT_SLOT(setEnabled(bool)));
- actionEditAccels = new KAction(i18n("Check Accelerators"), ALT + Key_R, this, TQT_SLOT(editAccels()),
+ actionEditAccels = new KAction(i18n("Check Accelerators"), ALT + Key_R, TQT_TQOBJECT(this), TQT_SLOT(editAccels()),
actionCollection(), "edit_check_accel");
actionEditAccels->setToolTip(i18n("Checks if the accelerators used in the form are unique"));
actionEditAccels->setWhatsThis(whatsThisFrom("Edit|Check Accelerator"));
connect(this, TQT_SIGNAL(hasActiveForm(bool)), actionEditAccels, TQT_SLOT(setEnabled(bool)));
actionEditConnections = new KAction(i18n("Connections"), createIconSet("connecttool.xpm"),
- KShortcut::null(), this, TQT_SLOT(editConnections()), actionCollection(),
+ KShortcut::null(), TQT_TQOBJECT(this), TQT_SLOT(editConnections()), actionCollection(),
"edit_connections");
actionEditConnections->setToolTip(i18n("Opens a dialog for editing connections"));
actionEditConnections->setWhatsThis(whatsThisFrom("Edit|Connections"));
connect(this, TQT_SIGNAL(hasActiveForm(bool)), actionEditConnections, TQT_SLOT(setEnabled(bool)));
actionEditFormSettings = new KAction(i18n("Form Settings..."), KShortcut::null(),
- this, TQT_SLOT(editFormSettings()), actionCollection(), "edit_form");
+ TQT_TQOBJECT(this), TQT_SLOT(editFormSettings()), actionCollection(), "edit_form");
actionEditFormSettings->setToolTip(i18n("Opens a dialog to change the form's settings"));
actionEditFormSettings->setWhatsThis(whatsThisFrom("Edit|Form Settings"));
connect(this, TQT_SIGNAL(hasActiveForm(bool)), actionEditFormSettings, TQT_SLOT(setEnabled(bool)));
KToolBar *tb = new KToolBar(this, "Edit");
tb->setFullSize(false);
- TQWhatsThis::add(tb, i18n("<b>The Edit toolbar</b>%1").arg(toolbarHelp));
+ TQWhatsThis::add(tb, i18n("<b>The Edit toolbar</b>%1").tqarg(toolbarHelp));
addToolBar(tb, i18n("Edit"));
actionEditUndo->plug(tb);
actionEditRedo->plug(tb);
@@ -198,70 +202,70 @@ void MainWindow::setupEditActions()
void MainWindow::setupLayoutActions()
{
actionEditAdjustSize = new KAction(i18n("Adjust Size"), createIconSet("adjustsize.xpm"),
- CTRL + Key_J, this, TQT_SLOT(editAdjustSize()), actionCollection(), "edit_adjust_size");
+ CTRL + Key_J, TQT_TQOBJECT(this), TQT_SLOT(editAdjustSize()), actionCollection(), "edit_adjust_size");
actionEditAdjustSize->setToolTip(i18n("Adjusts the size of the selected widget"));
actionEditAdjustSize->setWhatsThis(whatsThisFrom("Layout|Adjust Size"));
actionEditAdjustSize->setEnabled(false);
- actionEditHLayout = new KAction(i18n("Lay Out Horizontally"), createIconSet("edithlayout.xpm"),
- CTRL + Key_H, this, TQT_SLOT(editLayoutHorizontal()), actionCollection(), "edit_layout_h");
+ actionEditHLayout = new KAction(i18n("Lay OutQt::Horizontally"), createIconSet("edithtqlayout.xpm"),
+ CTRL + Key_H, TQT_TQOBJECT(this), TQT_SLOT(editLayoutHorizontal()), actionCollection(), "edit_layout_h");
actionEditHLayout->setToolTip(i18n("Lays out the selected widgets horizontally"));
- actionEditHLayout->setWhatsThis(whatsThisFrom("Layout|Lay Out Horizontally"));
+ actionEditHLayout->setWhatsThis(whatsThisFrom("Layout|Lay OutQt::Horizontally"));
actionEditHLayout->setEnabled(false);
- actionEditVLayout = new KAction(i18n("Lay Out Vertically"), createIconSet("editvlayout.xpm"),
- CTRL + Key_L, this, TQT_SLOT(editLayoutVertical()), actionCollection(), "edit_layout_v");
+ actionEditVLayout = new KAction(i18n("Lay OutQt::Vertically"), createIconSet("editvtqlayout.xpm"),
+ CTRL + Key_L, TQT_TQOBJECT(this), TQT_SLOT(editLayoutVertical()), actionCollection(), "edit_layout_v");
actionEditVLayout->setToolTip(i18n("Lays out the selected widgets vertically"));
- actionEditVLayout->setWhatsThis(whatsThisFrom("Layout|Lay Out Vertically"));
+ actionEditVLayout->setWhatsThis(whatsThisFrom("Layout|Lay OutQt::Vertically"));
actionEditVLayout->setEnabled(false);
actionEditGridLayout = new KAction(i18n("Lay Out in a Grid"), createIconSet("editgrid.xpm"),
- CTRL + Key_G, this, TQT_SLOT(editLayoutGrid()), actionCollection(), "edit_layout_grid");
+ CTRL + Key_G, TQT_TQOBJECT(this), TQT_SLOT(editLayoutGrid()), actionCollection(), "edit_layout_grid");
actionEditGridLayout->setToolTip(i18n("Lays out the selected widgets in a grid"));
actionEditGridLayout->setWhatsThis(whatsThisFrom("Layout|Lay Out in a Grid"));
actionEditGridLayout->setEnabled(false);
- actionEditSplitHorizontal = new KAction(i18n("Lay Out Horizontally in Splitter"), createIconSet("editvlayoutsplit.xpm"),
- KShortcut::null(), this, TQT_SLOT(editLayoutHorizontalSplit()), actionCollection(),
+ actionEditSplitHorizontal = new KAction(i18n("Lay OutQt::Horizontally in Splitter"), createIconSet("editvtqlayoutsplit.xpm"),
+ KShortcut::null(), TQT_TQOBJECT(this), TQT_SLOT(editLayoutHorizontalSplit()), actionCollection(),
"edit_split_h");
actionEditSplitHorizontal->setToolTip(i18n("Lays out the selected widgets horizontally in a splitter"));
- actionEditSplitHorizontal->setWhatsThis(whatsThisFrom("Layout|Lay Out Horizontally in Splitter"));
+ actionEditSplitHorizontal->setWhatsThis(whatsThisFrom("Layout|Lay OutQt::Horizontally in Splitter"));
actionEditSplitHorizontal->setEnabled(false);
- actionEditSplitVertical = new KAction(i18n("Lay Out Vertically in Splitter"), createIconSet("edithlayoutsplit.xpm"),
- KShortcut::null(), this, TQT_SLOT(editLayoutVerticalSplit()), actionCollection(),
+ actionEditSplitVertical = new KAction(i18n("Lay OutQt::Vertically in Splitter"), createIconSet("edithtqlayoutsplit.xpm"),
+ KShortcut::null(), TQT_TQOBJECT(this), TQT_SLOT(editLayoutVerticalSplit()), actionCollection(),
"edit_split_v");
actionEditSplitVertical->setToolTip(i18n("Lays out the selected widgets vertically in a splitter"));
- actionEditSplitVertical->setWhatsThis(whatsThisFrom("Layout|Lay Out Vertically (in Splitter)"));
+ actionEditSplitVertical->setWhatsThis(whatsThisFrom("Layout|Lay OutQt::Vertically (in Splitter)"));
actionEditSplitVertical->setEnabled(false);
actionEditBreakLayout = new KAction(i18n("Break Layout"), createIconSet("editbreaklayout.xpm"),
- CTRL + Key_B, this, TQT_SLOT(editBreakLayout()), actionCollection(), "edit_break_layout");
- actionEditBreakLayout->setToolTip(i18n("Breaks the selected layout"));
+ CTRL + Key_B, TQT_TQOBJECT(this), TQT_SLOT(editBreakLayout()), actionCollection(), "edit_break_layout");
+ actionEditBreakLayout->setToolTip(i18n("Breaks the selected tqlayout"));
actionEditBreakLayout->setWhatsThis(whatsThisFrom("Layout|Break Layout"));
int id = WidgetDatabase::idFromClassName("Spacer");
- KToggleAction *a = new KToggleAction(i18n("Spacer"), createIconSet("spacer.xpm"), KShortcut::null(), this, TQT_SLOT(toolSelected()),
+ KToggleAction *a = new KToggleAction(i18n("Spacer"), createIconSet("spacer.xpm"), KShortcut::null(), TQT_TQOBJECT(this), TQT_SLOT(toolSelected()),
actionCollection(), TQString::number(id).latin1());
a->setExclusiveGroup("tool");
a->setText(i18n("Add ") + WidgetDatabase::className(id));
- a->setToolTip(i18n("Insert a %1").arg(WidgetDatabase::toolTip(id)));
+ a->setToolTip(i18n("Insert a %1").tqarg(WidgetDatabase::toolTip(id)));
a->setWhatsThis(i18n("<b>A %1</b><p>%2</p>"
"<p>Click to insert a single %3,"
- "or double click to keep the tool selected.").arg(WidgetDatabase::toolTip(id)).
- arg(WidgetDatabase::whatsThis(id)).arg(WidgetDatabase::toolTip(id)));
-
- TQWhatsThis::add(layoutToolBar, i18n("<b>The Layout toolbar</b>%1").arg(toolbarHelp));
- actionEditAdjustSize->plug(layoutToolBar);
- layoutToolBar->addSeparator();
- actionEditHLayout->plug(layoutToolBar);
- actionEditVLayout->plug(layoutToolBar);
- actionEditGridLayout->plug(layoutToolBar);
- actionEditSplitHorizontal->plug(layoutToolBar);
- actionEditSplitVertical->plug(layoutToolBar);
- actionEditBreakLayout->plug(layoutToolBar);
- layoutToolBar->addSeparator();
- a->plug(layoutToolBar);
+ "or double click to keep the tool selected.").tqarg(WidgetDatabase::toolTip(id)).
+ tqarg(WidgetDatabase::whatsThis(id)).tqarg(WidgetDatabase::toolTip(id)));
+
+ TQWhatsThis::add(tqlayoutToolBar, i18n("<b>The Layout toolbar</b>%1").tqarg(toolbarHelp));
+ actionEditAdjustSize->plug(tqlayoutToolBar);
+ tqlayoutToolBar->addSeparator();
+ actionEditHLayout->plug(tqlayoutToolBar);
+ actionEditVLayout->plug(tqlayoutToolBar);
+ actionEditGridLayout->plug(tqlayoutToolBar);
+ actionEditSplitHorizontal->plug(tqlayoutToolBar);
+ actionEditSplitVertical->plug(tqlayoutToolBar);
+ actionEditBreakLayout->plug(tqlayoutToolBar);
+ tqlayoutToolBar->addSeparator();
+ a->plug(tqlayoutToolBar);
TQPopupMenu *menu = new TQPopupMenu(this, "Layout");
menuBar()->insertItem(i18n("&Layout"), menu);
@@ -280,21 +284,21 @@ void MainWindow::setupLayoutActions()
void MainWindow::setupToolActions()
{
actionPointerTool = new KToggleAction(i18n("Pointer"), "arrow", Key_F2,
- this, TQT_SLOT(toolSelected()), actionCollection(),
+ TQT_TQOBJECT(this), TQT_SLOT(toolSelected()), actionCollection(),
TQString::number(POINTER_TOOL).latin1());
actionPointerTool->setToolTip(i18n("Selects the pointer tool"));
actionPointerTool->setWhatsThis(whatsThisFrom("Tools|Pointer"));
actionPointerTool->setExclusiveGroup("tool");
actionConnectTool = new KToggleAction(i18n("Connect Signal/Slots"), createIconSet("connecttool.xpm"),
- Key_F3, this, TQT_SLOT(toolSelected()), actionCollection(),
+ Key_F3, TQT_TQOBJECT(this), TQT_SLOT(toolSelected()), actionCollection(),
TQString::number(CONNECT_TOOL).latin1());
actionConnectTool->setToolTip(i18n("Selects the connection tool"));
actionConnectTool->setWhatsThis(whatsThisFrom("Tools|Connect Signals and Slots"));
actionConnectTool->setExclusiveGroup("tool");
actionOrderTool = new KToggleAction(i18n("Tab Order"), createIconSet("ordertool.xpm"),
- Key_F4, this, TQT_SLOT(toolSelected()), actionCollection(),
+ Key_F4, TQT_TQOBJECT(this), TQT_SLOT(toolSelected()), actionCollection(),
TQString::number(ORDER_TOOL).latin1());
actionOrderTool->setToolTip(i18n("Selects the tab order tool"));
actionOrderTool->setWhatsThis(whatsThisFrom("Tools|Tab Order"));
@@ -302,7 +306,7 @@ void MainWindow::setupToolActions()
KToolBar *tb = new KToolBar(this, "Tools");
tb->setFullSize(false);
- TQWhatsThis::add(tb, i18n("<b>The Tools toolbar</b>%1").arg(toolbarHelp));
+ TQWhatsThis::add(tb, i18n("<b>The Tools toolbar</b>%1").tqarg(toolbarHelp));
addToolBar(tb, i18n("Tools"), TQMainWindow::DockTop, true);
actionPointerTool->plug(tb);
@@ -326,14 +330,14 @@ void MainWindow::setupToolActions()
bool plural = grp[(int) grp.length() - 1] == 's';
if (plural)
{
- TQWhatsThis::add(tb, i18n("<b>The %1</b>%2").arg(grp).arg(toolbarHelp).
- arg(i18n(" Click on a button to insert a single widget, "
- "or double click to insert multiple %1.")).arg(grp));
+ TQWhatsThis::add(tb, i18n("<b>The %1</b>%2").tqarg(grp).tqarg(toolbarHelp).
+ tqarg(i18n(" Click on a button to insert a single widget, "
+ "or double click to insert multiple %1.")).tqarg(grp));
} else
{
- TQWhatsThis::add(tb, i18n("<b>The %1 Widgets</b>%2").arg(grp).arg(toolbarHelp).
- arg(i18n(" Click on a button to insert a single %1 widget, "
- "or double click to insert multiple widgets.")).arg(grp));
+ TQWhatsThis::add(tb, i18n("<b>The %1 Widgets</b>%2").tqarg(grp).tqarg(toolbarHelp).
+ tqarg(i18n(" Click on a button to insert a single %1 widget, "
+ "or double click to insert multiple widgets.")).tqarg(grp));
}
addToolBar(tb, grp);
TQPopupMenu *menu = new TQPopupMenu(this, grp.latin1());
@@ -344,7 +348,7 @@ void MainWindow::setupToolActions()
if (WidgetDatabase::group(i) != grp)
continue; // only widgets, i.e. not forms and temp stuff
KToggleAction *a = new KToggleAction(WidgetDatabase::className(i), KShortcut::null(),
- this, TQT_SLOT(toolSelected()), actionCollection(), TQString::number(i).latin1());
+ TQT_TQOBJECT(this), TQT_SLOT(toolSelected()), actionCollection(), TQString::number(i).latin1());
a->setExclusiveGroup("tool");
TQString atext = WidgetDatabase::className(i);
if (atext[0] == 'Q')
@@ -359,11 +363,11 @@ void MainWindow::setupToolActions()
a->setToolTip(ttip);
if (!WidgetDatabase::isWhatsThisLoaded())
WidgetDatabase::loadWhatsThis(documentationPath());
- a->setToolTip(i18n("Insert a %1").arg(WidgetDatabase::className(i)));
+ a->setToolTip(i18n("Insert a %1").tqarg(WidgetDatabase::className(i)));
- TQString whats = i18n("<b>A %1</b>").arg(WidgetDatabase::className(i));
+ TQString whats = i18n("<b>A %1</b>").tqarg(WidgetDatabase::className(i));
if (!WidgetDatabase::whatsThis(i).isEmpty())
- whats += TQString("<p>%1</p>").arg(WidgetDatabase::whatsThis(i));
+ whats += TQString("<p>%1</p>").tqarg(WidgetDatabase::whatsThis(i));
a->setWhatsThis(whats + i18n("<p>Double click on this tool to keep it selected.</p>"));
if (grp != "KDE")
@@ -381,16 +385,16 @@ void MainWindow::setupToolActions()
if (!TQFile::exists(*it))
continue;
TQDir dir(*it);
- const QFileInfoList* fileList = dir.entryInfoList(TQDir::DefaultFilter, TQDir::DirsFirst | TQDir::Name);
+ const TQFileInfoList* fileList = dir.entryInfoList(TQDir::DefaultFilter, TQDir::DirsFirst | TQDir::Name);
if (fileList)
- for (QFileInfoListIterator fit(*fileList); fit.current(); ++fit)
+ for (TQFileInfoListIterator fit(*fileList); fit.current(); ++fit)
{
TQFileInfo* fi = fit.current();
if (!fi->isFile() || fi->extension() != "kmdr")
continue;
TQString name = fi->baseName();
- name = name.replace("_", " ");
- editMenu->insertItem(name, this, TQT_SLOT(editExternalTool(int)), 0, m_editorTools.count());
+ name = name.tqreplace("_", " ");
+ editMenu->insertItem(name, TQT_TQOBJECT(this), TQT_SLOT(editExternalTool(int)), 0, m_editorTools.count());
m_editorTools.append(fi->filePath());
}
}
@@ -405,29 +409,29 @@ void MainWindow::setupFileActions()
fileTb = new KToolBar(this, "File");
fileTb->setFullSize(false);
- TQWhatsThis::add(fileTb, i18n("<b>The File toolbar</b>%1").arg(toolbarHelp));
+ TQWhatsThis::add(fileTb, i18n("<b>The File toolbar</b>%1").tqarg(toolbarHelp));
addToolBar(fileTb, i18n("File"));
fileMenu = new TQPopupMenu(this, "File");
menuBar()->insertItem(i18n("&File"), fileMenu);
- KAction *a = KStdAction::openNew(this, TQT_SLOT(fileNew()), actionCollection());
+ KAction *a = KStdAction::openNew(TQT_TQOBJECT(this), TQT_SLOT(fileNew()), actionCollection());
a->setToolTip(i18n("Creates a new dialog"));
a->setWhatsThis(whatsThisFrom("File|New"));
a->plug(fileTb);
a->plug(fileMenu);
- a = KStdAction::open(this, TQT_SLOT(fileOpen()), actionCollection());
+ a = KStdAction::open(TQT_TQOBJECT(this), TQT_SLOT(fileOpen()), actionCollection());
a->setToolTip(i18n("Opens an existing dialog"));
a->setWhatsThis(whatsThisFrom("File|Open"));
a->plug(fileTb);
a->plug(fileMenu);
- actionRecent = KStdAction::openRecent(this, TQT_SLOT(fileOpenRecent(const KURL&)), actionCollection());
+ actionRecent = KStdAction::openRecent(TQT_TQOBJECT(this), TQT_SLOT(fileOpenRecent(const KURL&)), actionCollection());
actionRecent->setToolTip(i18n("Opens recently open file"));
actionRecent->plug(fileMenu);
fileMenu->insertSeparator();
- a = KStdAction::close(this, TQT_SLOT(fileClose()), actionCollection());
+ a = KStdAction::close(TQT_TQOBJECT(this), TQT_SLOT(fileClose()), actionCollection());
a->setToolTip(i18n("Closes the current dialog"));
a->setWhatsThis(whatsThisFrom("File|Close"));
connect(this, TQT_SIGNAL(hasActiveWindow(bool)), a, TQT_SLOT(setEnabled(bool)));
@@ -435,20 +439,20 @@ void MainWindow::setupFileActions()
fileMenu->insertSeparator();
- a = KStdAction::save(this, TQT_SLOT(fileSave()), actionCollection());
+ a = KStdAction::save(TQT_TQOBJECT(this), TQT_SLOT(fileSave()), actionCollection());
a->setToolTip(i18n("Saves the current dialog"));
a->setWhatsThis(whatsThisFrom("File|Save"));
connect(this, TQT_SIGNAL(hasActiveWindow(bool)), a, TQT_SLOT(setEnabled(bool)));
a->plug(fileTb);
a->plug(fileMenu);
- a = KStdAction::saveAs(this, TQT_SLOT(fileSaveAs()), actionCollection());
+ a = KStdAction::saveAs(TQT_TQOBJECT(this), TQT_SLOT(fileSaveAs()), actionCollection());
a->setToolTip(i18n("Saves the current dialog with a new filename"));
a->setWhatsThis(whatsThisFrom("File|Save As"));
connect(this, TQT_SIGNAL(hasActiveWindow(bool)), a, TQT_SLOT(setEnabled(bool)));
a->plug(fileMenu);
- a = new KAction(i18n("Save All"), "save_all", KShortcut::null(), this, TQT_SLOT(fileSaveAll()),
+ a = new KAction(i18n("Save All"), "save_all", KShortcut::null(), TQT_TQOBJECT(this), TQT_SLOT(fileSaveAll()),
actionCollection(), "file_close_all");
a->setToolTip(i18n("Saves all open dialogs"));
a->setWhatsThis(whatsThisFrom("File|Save All"));
@@ -457,7 +461,7 @@ void MainWindow::setupFileActions()
fileMenu->insertSeparator();
- a = KStdAction::quit(kapp, TQT_SLOT(closeAllWindows()), actionCollection());
+ a = KStdAction::quit(TQT_TQOBJECT(kapp), TQT_SLOT(closeAllWindows()), actionCollection());
a->setToolTip(i18n("Quits the application and prompts to save any changed dialogs"));
a->setWhatsThis(whatsThisFrom("File|Exit"));
a->plug(fileMenu);
@@ -470,7 +474,7 @@ void MainWindow::setupRunActions()
menuBar()->insertItem(i18n("&Run"), menu);
KAction* a = new KAction(i18n("Run Dialog"), "run", CTRL + Key_R,
- this, TQT_SLOT(runForm()), actionCollection(), "run");
+ TQT_TQOBJECT(this), TQT_SLOT(runForm()), actionCollection(), "run");
a->setToolTip(i18n("Executes dialog"));
a->setWhatsThis(whatsThisFrom("Run|Run dialog"));
connect(this, TQT_SIGNAL(hasActiveForm(bool)), a, TQT_SLOT(setEnabled(bool)));
@@ -478,8 +482,8 @@ void MainWindow::setupRunActions()
a->plug(menu);
// add KDE4 executor
- KAction* b = new KAction(i18n("Run Dialog K4"), "launch", CTRL + SHIFT + Qt::Key_R,
- this, TQT_SLOT(runForm4()), actionCollection(), "run4");
+ KAction* b = new KAction(i18n("Run Dialog K4"), "launch", CTRL + SHIFT + TQt::Key_R,
+ TQT_TQOBJECT(this), TQT_SLOT(runForm4()), actionCollection(), "run4");
b->setToolTip(i18n("Executes dialog in KDE4"));
b->setWhatsThis(whatsThisFrom("Run|Run dialog"));
connect(this, TQT_SIGNAL(hasActiveForm(bool)), b, TQT_SLOT(setEnabled(bool)));
@@ -493,39 +497,39 @@ void MainWindow::setupWindowActions()
{
windowActionsSetup = true;
- KAction* actionWindowTile = new KAction(i18n("Tile"), KShortcut::null(), qworkspace, TQT_SLOT(tile()),
+ KAction* actionWindowTile = new KAction(i18n("Tile"), KShortcut::null(), TQT_TQOBJECT(qworkspace), TQT_SLOT(tile()),
actionCollection(), "window_tile");
actionWindowTile->setToolTip(i18n("Tiles the windows so that they are all visible"));
actionWindowTile->setWhatsThis(whatsThisFrom("Window|Tile"));
- KAction* actionWindowCascade = new KAction(i18n("Cascade"), KShortcut::null(), qworkspace, TQT_SLOT(cascade()),
+ KAction* actionWindowCascade = new KAction(i18n("Cascade"), KShortcut::null(), TQT_TQOBJECT(qworkspace), TQT_SLOT(cascade()),
actionCollection(), "window_cascade");
actionWindowCascade->setToolTip(i18n("Cascades the windows so that all their title bars are visible"));
actionWindowCascade->setWhatsThis(whatsThisFrom("Window|Cascade"));
- KAction* actionWindowClose = new KAction(i18n("Cascade"), KShortcut::null(), qworkspace, TQT_SLOT(closeActiveWindow()),
+ KAction* actionWindowClose = new KAction(i18n("Cascade"), KShortcut::null(), TQT_TQOBJECT(qworkspace), TQT_SLOT(closeActiveWindow()),
actionCollection(), "window_close");
actionWindowClose->setToolTip(i18n("Closes the active window"));
actionWindowClose->setWhatsThis(whatsThisFrom("Window|Close"));
- KAction* actionWindowCloseAll = new KAction(i18n("Close All"), KShortcut::null(), qworkspace,
+ KAction* actionWindowCloseAll = new KAction(i18n("Close All"), KShortcut::null(), TQT_TQOBJECT(qworkspace),
TQT_SLOT(closeAllWindows()), actionCollection(), "window_close_all");
actionWindowCloseAll->setToolTip(i18n("Closes all form windows"));
actionWindowCloseAll->setWhatsThis(whatsThisFrom("Window|Close All"));
- KAction* actionWindowNext = new KAction(i18n("Next"), Key_F6, qworkspace,
+ KAction* actionWindowNext = new KAction(i18n("Next"), Key_F6, TQT_TQOBJECT(qworkspace),
TQT_SLOT(activateNextWindow()), actionCollection(), "window_next");
actionWindowNext->setToolTip(i18n("Activates the next window"));
actionWindowNext->setWhatsThis(whatsThisFrom("Window|Next"));
- KAction* actionWindowPrevious = new KAction(i18n("Previous"), CTRL + SHIFT + Key_F6, qworkspace,
+ KAction* actionWindowPrevious = new KAction(i18n("Previous"), CTRL + SHIFT + Key_F6, TQT_TQOBJECT(qworkspace),
TQT_SLOT(activatePreviousWindow()), actionCollection(), "window_prev");
actionWindowPrevious->setToolTip(i18n("Activates the previous window"));
actionWindowPrevious->setWhatsThis(whatsThisFrom("Window|Previous"));
windowMenu = new KPopupMenu(this, "Window");
menuBar()->insertItem(i18n("&Window"), windowMenu);
- connect(windowMenu, TQT_SIGNAL(aboutToShow()), this, TQT_SLOT(setupWindowActions()));
+ connect(windowMenu, TQT_SIGNAL(aboutToShow()), TQT_TQOBJECT(this), TQT_SLOT(setupWindowActions()));
actionWindowClose->plug(windowMenu);
actionWindowCloseAll->plug(windowMenu);
@@ -556,13 +560,13 @@ void MainWindow::setupWindowActions()
j++;
TQString itemText;
if (j < 10)
- itemText = TQString("&%1 ").arg(j);
+ itemText = TQString("&%1 ").tqarg(j);
if (w->inherits("FormWindow"))
itemText += w->name();
else
itemText += w->caption();
- int id = windowMenu->insertItem(itemText, this, TQT_SLOT(windowsMenuActivated(int)));
+ int id = windowMenu->insertItem(itemText, TQT_TQOBJECT(this), TQT_SLOT(windowsMenuActivated(int)));
windowMenu->setItemParameter(id, i);
windowMenu->setItemChecked(id, qworkspace->activeWindow() == windows.at(i));
}
@@ -572,21 +576,21 @@ void MainWindow::setupWindowActions()
void MainWindow::setupSettingsActions()
{
KPopupMenu *settings = new KPopupMenu(this, "Settings");
- KAction* a = KStdAction::keyBindings(this, TQT_SLOT(editShortcuts()), actionCollection());
+ KAction* a = KStdAction::keyBindings(TQT_TQOBJECT(this), TQT_SLOT(editShortcuts()), actionCollection());
a->setToolTip(i18n("Opens a dialog to change shortcuts"));
a->plug(settings);
- a = new KAction(i18n("Configure &Plugins..."), KShortcut::null(), this, TQT_SLOT(editPlugins()),
+ a = new KAction(i18n("Configure &Plugins..."), KShortcut::null(), TQT_TQOBJECT(this), TQT_SLOT(editPlugins()),
actionCollection(), "configure_plugins");
a->setToolTip(i18n("Opens a dialog to configure plugins"));
a->plug(settings);
- a = new KAction(i18n("&Configure Editor..."), KShortcut::null(), this, TQT_SLOT(configureEditor()),
+ a = new KAction(i18n("&Configure Editor..."), KShortcut::null(), TQT_TQOBJECT(this), TQT_SLOT(configureEditor()),
actionCollection(), "configure_editor");
a->setToolTip(i18n("Configure various aspects of this editor."));
a->plug(settings);
- a = KStdAction::preferences(this, TQT_SLOT(editPreferences()), actionCollection());
+ a = KStdAction::preferences(TQT_TQOBJECT(this), TQT_SLOT(editPreferences()), actionCollection());
a->setToolTip(i18n("Opens a dialog to change preferences"));
a->setWhatsThis(whatsThisFrom("Edit|Preferences"));
a->plug(settings);
@@ -604,7 +608,7 @@ void MainWindow::setupHelpActions()
void MainWindow::fileNew()
{
statusBar()->message(i18n("Create a new dialog..."));
- NewForm dlg(this, TQString::null);
+ NewForm dlg(this, TQString());
dlg.exec();
statusBar()->clear();
}
@@ -631,7 +635,7 @@ void MainWindow::fileOpen(const TQString & fn)
TQStringList filenames;
if (fn.isEmpty())
- filenames = KFileDialog::getOpenFileNames(TQString::null, i18n("*.kmdr|Kommander Files"), this, i18n("Open Files"));
+ filenames = KFileDialog::getOpenFileNames(TQString(), i18n("*.kmdr|Kommander Files"), this, i18n("Open Files"));
else
filenames << fn;
for (TQStringList::ConstIterator fit = filenames.constBegin(); fit != filenames.constEnd(); ++fit)
@@ -667,7 +671,7 @@ FormWindow *MainWindow::openFormWindow(const TQString &filename, bool validFileN
}
if (!makeNew)
{
- statusBar()->message(i18n("Reading file '%1'...").arg(filename));
+ statusBar()->message(i18n("Reading file '%1'...").tqarg(filename));
if (TQFile::exists(filename))
{
TQApplication::setOverrideCursor(WaitCursor);
@@ -676,18 +680,18 @@ FormWindow *MainWindow::openFormWindow(const TQString &filename, bool validFileN
ff = new FormFile(filename, false);
bool b = resource.load(ff) && (FormWindow *) resource.widget();
if (!validFileName && resource.widget())
- ((FormWindow *) resource.widget())->setFileName(TQString::null);
+ ((FormWindow *) resource.widget())->setFileName(TQString());
TQApplication::restoreOverrideCursor();
if (b)
{
- statusBar()->message(i18n("Loaded file '%1'").arg(filename), 3000);
+ statusBar()->message(i18n("Loaded file '%1'").tqarg(filename), 3000);
} else
{
emit removedFormFile(ff);
ff->close();
delete ff;
- statusBar()->message(i18n("Could not load file '%1'").arg(filename), 5000);
- KMessageBox::information(this, i18n("Could not load file '%1'").arg(filename), i18n("Load File"));
+ statusBar()->message(i18n("Could not load file '%1'").tqarg(filename), 5000);
+ KMessageBox::information(this, i18n("Could not load file '%1'").tqarg(filename), i18n("Load File"));
}
return (FormWindow *) resource.widget();
} else
@@ -750,7 +754,7 @@ void MainWindow::saveAllTemp()
if (inSaveAllTemp)
return;
inSaveAllTemp = true;
- statusBar()->message(i18n("Qt Designer is crashing. Attempting to save files..."));
+ statusBar()->message(i18n("TQt Designer is crashing. Attempting to save files..."));
TQWidgetList windows = qWorkspace()->windowList();
TQString baseName = TQDir::homeDirPath() + "/.designer/saved-form-";
int i = 1;
@@ -781,20 +785,20 @@ void MainWindow::fileCreateTemplate()
for (i = 0; i < WidgetDatabase::count(); ++i)
{
if (WidgetDatabase::isContainer(i) && !WidgetDatabase::isForm(i) &&
- WidgetDatabase::className(i) != "TQTabWidget" && WidgetDatabase::widgetGroup(i) != "Temp")
+ WidgetDatabase::className(i) != TQTABWIDGET_OBJECT_NAME_STRING && WidgetDatabase::widgetGroup(i) != "Temp")
{
dia.listClass->insertItem(WidgetDatabase::className(i));
}
}
dia.editName->setText(i18n("NewTemplate"));
- connect(dia.buttonCreate, TQT_SIGNAL(clicked()), this, TQT_SLOT(createNewTemplate()));
+ connect(dia.buttonCreate, TQT_SIGNAL(clicked()), TQT_TQOBJECT(this), TQT_SLOT(createNewTemplate()));
dia.exec();
}
void MainWindow::createNewTemplate()
{
- CreateTemplate *dia = (CreateTemplate *) sender()->parent();
+ CreateTemplate *dia = (CreateTemplate *) TQT_TQOBJECT(const_cast<TQT_BASE_OBJECT_NAME*>(sender()))->tqparent();
TQString fn = dia->editName->text();
TQString cn = dia->listClass->currentText();
if (fn.isEmpty() || cn.isEmpty())
@@ -804,14 +808,14 @@ void MainWindow::createNewTemplate()
}
TQStringList templRoots;
- const char *qtdir = getenv("QTDIR");
+ const char *qtdir = getenv("TQTDIR");
if (qtdir)
templRoots << qtdir;
-#ifdef QT_INSTALL_PREFIX
- templRoots << QT_INSTALL_PREFIX;
+#ifdef TQT_INSTALL_PREFIX
+ templRoots << TQT_INSTALL_PREFIX;
#endif
-#ifdef QT_INSTALL_DATA
- templRoots << QT_INSTALL_DATA;
+#ifdef TQT_INSTALL_DATA
+ templRoots << TQT_INSTALL_DATA;
#endif
if (qtdir) //try the tools/designer directory last!
templRoots << TQString(qtdir) + "/tools/designer";
@@ -841,7 +845,7 @@ void MainWindow::createNewTemplate()
ts << " <cstring>" << cn << "Form</cstring>" << endl;
ts << "</property>" << endl;
ts << "<property stdset=\"1\">" << endl;
- ts << " <name>geometry</name>" << endl;
+ ts << " <name>tqgeometry</name>" << endl;
ts << " <rect>" << endl;
ts << " <width>300</width>" << endl;
ts << " <height>400</height>" << endl;
@@ -876,7 +880,7 @@ void MainWindow::editCut()
void MainWindow::editCopy()
{
if (formWindow())
- qApp->clipboard()->setText(formWindow()->copy());
+ tqApp->clipboard()->setText(formWindow()->copy());
}
void MainWindow::editPaste()
@@ -889,21 +893,21 @@ void MainWindow::editPaste()
if (l.count() == 1)
{
w = l.first();
- if (WidgetFactory::layoutType(w) != WidgetFactory::NoLayout ||
+ if (WidgetFactory::tqlayoutType(w) != WidgetFactory::NoLayout ||
(!WidgetDatabase::isContainer(WidgetDatabase::idFromClassName(WidgetFactory::
- classNameOf(w))) && w != formWindow()->mainContainer()))
+ classNameOf(TQT_TQOBJECT(w)))) && w != formWindow()->mainContainer()))
w = formWindow()->mainContainer();
}
- if (w && WidgetFactory::layoutType(w) == WidgetFactory::NoLayout)
+ if (w && WidgetFactory::tqlayoutType(w) == WidgetFactory::NoLayout)
{
- formWindow()->paste(qApp->clipboard()->text(), WidgetFactory::containerOfWidget(w));
+ formWindow()->paste(tqApp->clipboard()->text(), WidgetFactory::containerOfWidget(w));
hierarchyView->widgetInserted(0);
formWindow()->commandHistory()->setModified(true);
} else
{
KMessageBox::information(this, i18n("Cannot paste widgets. Designer could not find a container\n"
- "to paste into which does not contain a layout. Break the layout\n"
+ "to paste into which does not contain a tqlayout. Break the tqlayout\n"
"of the container you want to paste into and select this container\n"
"and then paste again."), i18n("Paste Error"));
}
@@ -941,42 +945,42 @@ void MainWindow::editAdjustSize()
void MainWindow::editLayoutHorizontal()
{
- if (layoutChilds)
+ if (tqlayoutChilds)
editLayoutContainerHorizontal();
- else if (layoutSelected && formWindow())
- formWindow()->layoutHorizontal();
+ else if (tqlayoutSelected && formWindow())
+ formWindow()->tqlayoutHorizontal();
}
void MainWindow::editLayoutVertical()
{
- if (layoutChilds)
+ if (tqlayoutChilds)
editLayoutContainerVertical();
- else if (layoutSelected && formWindow())
- formWindow()->layoutVertical();
+ else if (tqlayoutSelected && formWindow())
+ formWindow()->tqlayoutVertical();
}
void MainWindow::editLayoutHorizontalSplit()
{
- if (layoutChilds)
+ if (tqlayoutChilds)
; // no way to do that
- else if (layoutSelected && formWindow())
- formWindow()->layoutHorizontalSplit();
+ else if (tqlayoutSelected && formWindow())
+ formWindow()->tqlayoutHorizontalSplit();
}
void MainWindow::editLayoutVerticalSplit()
{
- if (layoutChilds)
+ if (tqlayoutChilds)
; // no way to do that
- else if (layoutSelected && formWindow())
- formWindow()->layoutVerticalSplit();
+ else if (tqlayoutSelected && formWindow())
+ formWindow()->tqlayoutVerticalSplit();
}
void MainWindow::editLayoutGrid()
{
- if (layoutChilds)
+ if (tqlayoutChilds)
editLayoutContainerGrid();
- else if (layoutSelected && formWindow())
- formWindow()->layoutGrid();
+ else if (tqlayoutSelected && formWindow())
+ formWindow()->tqlayoutGrid();
}
void MainWindow::editLayoutContainerVertical()
@@ -988,7 +992,7 @@ void MainWindow::editLayoutContainerVertical()
if (l.count() == 1)
w = l.first();
if (w)
- formWindow()->layoutVerticalContainer(w);
+ formWindow()->tqlayoutVerticalContainer(w);
}
void MainWindow::editLayoutContainerHorizontal()
@@ -1000,7 +1004,7 @@ void MainWindow::editLayoutContainerHorizontal()
if (l.count() == 1)
w = l.first();
if (w)
- formWindow()->layoutHorizontalContainer(w);
+ formWindow()->tqlayoutHorizontalContainer(w);
}
void MainWindow::editLayoutContainerGrid()
@@ -1012,7 +1016,7 @@ void MainWindow::editLayoutContainerGrid()
if (l.count() == 1)
w = l.first();
if (w)
- formWindow()->layoutGridContainer(w);
+ formWindow()->tqlayoutGridContainer(w);
}
@@ -1025,8 +1029,8 @@ void MainWindow::editBreakLayout()
TQWidget *w = formWindow()->mainContainer();
if (formWindow()->currentWidget())
w = formWindow()->currentWidget();
- if (WidgetFactory::layoutType(w) != WidgetFactory::NoLayout ||
- w->parentWidget() && WidgetFactory::layoutType(w->parentWidget()) != WidgetFactory::NoLayout)
+ if (WidgetFactory::tqlayoutType(w) != WidgetFactory::NoLayout ||
+ w->tqparentWidget() && WidgetFactory::tqlayoutType(w->tqparentWidget()) != WidgetFactory::NoLayout)
{
formWindow()->breakLayout(w);
return;
@@ -1036,9 +1040,9 @@ void MainWindow::editBreakLayout()
TQWidgetList widgets = formWindow()->selectedWidgets();
for (w = widgets.first(); w; w = widgets.next())
{
- if (WidgetFactory::layoutType(w) != WidgetFactory::NoLayout ||
- w->parentWidget()
- && WidgetFactory::layoutType(w->parentWidget()) != WidgetFactory::NoLayout)
+ if (WidgetFactory::tqlayoutType(w) != WidgetFactory::NoLayout ||
+ w->tqparentWidget()
+ && WidgetFactory::tqlayoutType(w->tqparentWidget()) != WidgetFactory::NoLayout)
break;
}
if (w)
@@ -1049,8 +1053,8 @@ void MainWindow::editBreakLayout()
}
w = formWindow()->mainContainer();
- if (WidgetFactory::layoutType(w) != WidgetFactory::NoLayout ||
- w->parentWidget() && WidgetFactory::layoutType(w->parentWidget()) != WidgetFactory::NoLayout)
+ if (WidgetFactory::tqlayoutType(w) != WidgetFactory::NoLayout ||
+ w->tqparentWidget() && WidgetFactory::tqlayoutType(w->tqparentWidget()) != WidgetFactory::NoLayout)
{
formWindow()->breakLayout(w);
}
@@ -1119,7 +1123,7 @@ void MainWindow::editPreferences()
dia->checkBoxSplash->setChecked(splashScreen);
dia->editDocPath->setText(docPath);
dia->checkAutoEdit->setChecked(!databaseAutoEdit);
- connect(dia->buttonDocPath, TQT_SIGNAL(clicked()), this, TQT_SLOT(chooseDocPath()));
+ connect(dia->buttonDocPath, TQT_SIGNAL(clicked()), TQT_TQOBJECT(this), TQT_SLOT(chooseDocPath()));
if (dia->exec() == TQDialog::Accepted)
{
@@ -1193,7 +1197,7 @@ void MainWindow::chooseDocPath()
{
if (!prefDia)
return;
- TQString fn = KFileDialog::getExistingDirectory(TQString::null, this);
+ TQString fn = KFileDialog::getExistingDirectory(TQString(), this);
if (!fn.isEmpty())
prefDia->editDocPath->setText(fn);
}
diff --git a/kommander/editor/messagelog.cpp b/kommander/editor/messagelog.cpp
index ecaed31a..aeddb1e1 100644
--- a/kommander/editor/messagelog.cpp
+++ b/kommander/editor/messagelog.cpp
@@ -28,7 +28,7 @@
#include <tqfile.h>
#include <tqtextstream.h>
-MessageLog::MessageLog(TQWidget* parent, const char* name) : TQTabWidget(parent, name)
+MessageLog::MessageLog(TQWidget* tqparent, const char* name) : TQTabWidget(tqparent, name)
{
m_popupMenu = new KPopupMenu(this);
m_popupMenu->insertItem(SmallIconSet("editcopy"), i18n("Copy Current &Line"), this, TQT_SLOT(copyLine()));
@@ -108,12 +108,12 @@ void MessageLog::clearContent()
void MessageLog::copyLine()
{
if (m_lists[currentPageIndex()]->count())
- kapp->clipboard()->setText(m_lists[currentPageIndex()]->currentText(), QClipboard::Clipboard);
+ kapp->tqclipboard()->setText(m_lists[currentPageIndex()]->currentText(), TQClipboard::Clipboard);
}
void MessageLog::copyContent()
{
- kapp->clipboard()->setText(content(), QClipboard::Clipboard);
+ kapp->tqclipboard()->setText(content(), TQClipboard::Clipboard);
}
void MessageLog::saveToFile()
@@ -125,12 +125,12 @@ void MessageLog::saveToFile()
TQFileInfo fileinfo(url.path());
if (fileinfo.exists() && KMessageBox::warningContinueCancel(0,
i18n("<qt>File<br><b>%1</b><br>already exists. Overwrite it?</qt>")
- .arg(url.path()), TQString::null, i18n("Overwrite")) == KMessageBox::Cancel)
+ .tqarg(url.path()), TQString(), i18n("Overwrite")) == KMessageBox::Cancel)
return;
TQFile file(url.path());
if (!file.open(IO_WriteOnly)) {
KMessageBox::error(0, i18n("<qt>Cannot save log file<br><b>%1</b></qt>")
- .arg(url.url()));
+ .tqarg(url.url()));
return;
}
TQTextStream textfile(&file);
diff --git a/kommander/editor/messagelog.h b/kommander/editor/messagelog.h
index ef7c8638..bf1508b6 100644
--- a/kommander/editor/messagelog.h
+++ b/kommander/editor/messagelog.h
@@ -26,12 +26,13 @@ class KProcess;
class KPopupMenu;
class TQListBoxItem;
-class MessageLog : public QTabWidget
+class MessageLog : public TQTabWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
enum InfoType {Stdout, Stderr, All};
- MessageLog(TQWidget* parent = 0, const char* name = 0);
+ MessageLog(TQWidget* tqparent = 0, const char* name = 0);
~MessageLog();
virtual void insertItem(InfoType i, TQString text);
virtual void clear(InfoType i = All);
diff --git a/kommander/editor/metadatabase.cpp b/kommander/editor/metadatabase.cpp
index 3a8316b8..d8cdb32c 100644
--- a/kommander/editor/metadatabase.cpp
+++ b/kommander/editor/metadatabase.cpp
@@ -1,5 +1,5 @@
/**********************************************************************
- This file is based on Qt Designer, Copyright (C) 2000 Trolltech AS. All rights reserved.
+ This file is based on TQt Designer, Copyright (C) 2000 Trolltech AS. All rights reserved.
This file may be distributed and/or modified under the terms of the
GNU General Public License version 2 as published by the Free Software
@@ -34,7 +34,7 @@
#include <tqwidgetlist.h>
#include <tqmainwindow.h>
#include <tqregexp.h>
-#include <private/qpluginmanager_p.h>
+#include <private/tqpluginmanager_p.h>
#include <tqdatetime.h>
#include <tqfile.h>
#include <tqfileinfo.h>
@@ -110,7 +110,7 @@ void MetaDataBase::addEntry( TQObject *o )
if ( !o )
return;
setupDataBase();
- if ( db->find( o ) )
+ if ( db->tqfind( o ) )
return;
MetaDataBaseRecord *r = new MetaDataBaseRecord;
r->object = o;
@@ -129,7 +129,7 @@ void MetaDataBase::removeEntry( TQObject *o )
void MetaDataBase::setPropertyChanged( TQObject *o, const TQString &property, bool changed )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -137,24 +137,24 @@ void MetaDataBase::setPropertyChanged( TQObject *o, const TQString &property, bo
}
if ( changed ) {
- if ( r->changedProperties.findIndex( property ) == -1 )
+ if ( r->changedProperties.tqfindIndex( property ) == -1 )
r->changedProperties.append( property );
} else {
- if ( r->changedProperties.findIndex( property ) != -1 )
+ if ( r->changedProperties.tqfindIndex( property ) != -1 )
r->changedProperties.remove( property );
}
if ( doUpdate &&
( property == "hAlign" || property == "vAlign" || property == "wordwrap" ) ) {
doUpdate = false;
- setPropertyChanged( o, "alignment", changed ||
+ setPropertyChanged( o, "tqalignment", changed ||
isPropertyChanged( o, "hAlign" ) ||
isPropertyChanged( o, "vAlign" ) ||
isPropertyChanged( o, "wordwrap" ) );
doUpdate = true;
}
- if ( doUpdate && property == "alignment" ) {
+ if ( doUpdate && property == "tqalignment" ) {
doUpdate = false;
setPropertyChanged( o, "hAlign", changed );
setPropertyChanged( o, "vAlign", changed );
@@ -166,20 +166,20 @@ void MetaDataBase::setPropertyChanged( TQObject *o, const TQString &property, bo
bool MetaDataBase::isPropertyChanged( TQObject *o, const TQString &property )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
return false;
}
- return r->changedProperties.findIndex( property ) != -1;
+ return r->changedProperties.tqfindIndex( property ) != -1;
}
TQStringList MetaDataBase::changedProperties( TQObject *o )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -193,7 +193,7 @@ TQStringList MetaDataBase::changedProperties( TQObject *o )
void MetaDataBase::setPropertyComment( TQObject *o, const TQString &property, const TQString &comment )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -206,20 +206,20 @@ void MetaDataBase::setPropertyComment( TQObject *o, const TQString &property, co
TQString MetaDataBase::propertyComment( TQObject *o, const TQString &property )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
- return TQString::null;
+ return TQString();
}
- return *r->propertyComments.find( property );
+ return *r->propertyComments.tqfind( property );
}
void MetaDataBase::setFakeProperty( TQObject *o, const TQString &property, const TQVariant& value )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -231,13 +231,13 @@ void MetaDataBase::setFakeProperty( TQObject *o, const TQString &property, const
TQVariant MetaDataBase::fakeProperty( TQObject * o, const TQString &property)
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
return TQVariant();
}
- TQMap<TQString, TQVariant>::Iterator it = r->fakeProperties.find( property );
+ TQMap<TQString, TQVariant>::Iterator it = r->fakeProperties.tqfind( property );
if ( it != r->fakeProperties.end() )
return r->fakeProperties[property];
return WidgetFactory::defaultValue( o, property );
@@ -247,7 +247,7 @@ TQVariant MetaDataBase::fakeProperty( TQObject * o, const TQString &property)
TQMap<TQString,TQVariant>* MetaDataBase::fakeProperties( TQObject* o )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -261,7 +261,7 @@ void MetaDataBase::setSpacing( TQObject *o, int spacing )
if ( !o )
return;
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r || !o->isWidgetType() ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -269,10 +269,10 @@ void MetaDataBase::setSpacing( TQObject *o, int spacing )
}
r->spacing = spacing;
- TQLayout * layout = 0;
- WidgetFactory::layoutType( (TQWidget*)o, layout );
- if ( layout )
- layout->setSpacing( spacing );
+ TQLayout * tqlayout = 0;
+ WidgetFactory::tqlayoutType( (TQWidget*)o, tqlayout );
+ if ( tqlayout )
+ tqlayout->setSpacing( spacing );
}
int MetaDataBase::spacing( TQObject *o )
@@ -281,8 +281,8 @@ int MetaDataBase::spacing( TQObject *o )
return -1;
setupDataBase();
if ( o->inherits( TQMAINWINDOW_OBJECT_NAME_STRING ) )
- o = ( (TQMainWindow*)o )->centralWidget();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ o = TQT_TQOBJECT(( (TQMainWindow*)o )->centralWidget());
+ MetaDataBaseRecord *r = db->tqfind( TQT_TQOBJECT(o) );
if ( !r || !o->isWidgetType() ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -297,7 +297,7 @@ void MetaDataBase::setMargin( TQObject *o, int margin )
if ( !o )
return;
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r || !o->isWidgetType() ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -305,12 +305,12 @@ void MetaDataBase::setMargin( TQObject *o, int margin )
}
r->margin = margin;
- TQLayout * layout = 0;
- WidgetFactory::layoutType( (TQWidget*)o, layout );
+ TQLayout * tqlayout = 0;
+ WidgetFactory::tqlayoutType( (TQWidget*)o, tqlayout );
if ( margin < 1 )
margin = 1;
- if ( layout )
- layout->setMargin( margin );
+ if ( tqlayout )
+ tqlayout->setMargin( margin );
}
int MetaDataBase::margin( TQObject *o )
@@ -319,8 +319,8 @@ int MetaDataBase::margin( TQObject *o )
return -1;
setupDataBase();
if ( o->inherits( TQMAINWINDOW_OBJECT_NAME_STRING ) )
- o = ( (TQMainWindow*)o )->centralWidget();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ o = TQT_TQOBJECT(( (TQMainWindow*)o )->centralWidget());
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r || !o->isWidgetType() ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -334,7 +334,7 @@ void MetaDataBase::addConnection( TQObject *o, TQObject *sender, const TQCString
TQObject *receiver, const TQCString &slot )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -352,7 +352,7 @@ void MetaDataBase::removeConnection( TQObject *o, TQObject *sender, const TQCStr
TQObject *receiver, const TQCString &slot )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -374,7 +374,7 @@ void MetaDataBase::removeConnection( TQObject *o, TQObject *sender, const TQCStr
TQValueList<MetaDataBase::Connection> MetaDataBase::connections( TQObject *o )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -387,7 +387,7 @@ TQValueList<MetaDataBase::Connection> MetaDataBase::connections( TQObject *o, TQ
TQObject *receiver )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -409,7 +409,7 @@ TQValueList<MetaDataBase::Connection> MetaDataBase::connections( TQObject *o, TQ
TQValueList<MetaDataBase::Connection> MetaDataBase::connections( TQObject *o, TQObject *object )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -430,7 +430,7 @@ TQValueList<MetaDataBase::Connection> MetaDataBase::connections( TQObject *o, TQ
void MetaDataBase::doConnections( TQObject *o )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -465,16 +465,16 @@ void MetaDataBase::doConnections( TQObject *o )
delete l;
}
TQString s = "2""%1";
- s = s.arg( conn.signal );
+ s = s.tqarg( conn.signal.data() );
TQString s2 = "1""%1";
- s2 = s2.arg( conn.slot );
+ s2 = s2.tqarg( conn.slot.data() );
- TQStrList signalList = sender->metaObject()->signalNames( true );
- TQStrList slotList = receiver->metaObject()->slotNames( true );
+ TQStrList signalList = sender->tqmetaObject()->signalNames( true );
+ TQStrList slotList = receiver->tqmetaObject()->slotNames( true );
// avoid warnings
- if ( signalList.find( conn.signal ) == -1 ||
- slotList.find( conn.slot ) == -1 )
+ if ( signalList.tqfind( conn.signal ) == -1 ||
+ slotList.tqfind( conn.slot ) == -1 )
continue;
TQObject::connect( sender, s, receiver, s2 );
@@ -485,7 +485,7 @@ void MetaDataBase::addSlot( TQObject *o, const TQCString &slot, const TQString&
const TQString &access, const TQString &language, const TQString &returnType )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -498,7 +498,7 @@ void MetaDataBase::addSlot( TQObject *o, const TQCString &slot, const TQString&
s.access = access;
s.language = language;
s.returnType = returnType;
- TQValueList<MetaDataBase::Slot>::Iterator it = r->slotList.find( s );
+ TQValueList<MetaDataBase::Slot>::Iterator it = r->slotList.tqfind( s );
if ( it != r->slotList.end() )
r->slotList.remove( it );
r->slotList.append( s );
@@ -510,7 +510,7 @@ void MetaDataBase::addSlot( TQObject *o, const TQCString &slot, const TQString&
void MetaDataBase::setSlotList( TQObject *o, const TQValueList<Slot> &slotList )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -523,7 +523,7 @@ void MetaDataBase::removeSlot( TQObject *o, const TQCString &slot, const TQStrin
const TQString &access, const TQString &language, const TQString &returnType )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -546,7 +546,7 @@ void MetaDataBase::removeSlot( TQObject *o, const TQCString &slot, const TQStrin
void MetaDataBase::removeSlot( TQObject *o, const TQString &slot )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -565,7 +565,7 @@ void MetaDataBase::removeSlot( TQObject *o, const TQString &slot )
TQValueList<MetaDataBase::Slot> MetaDataBase::slotList( TQObject *o )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -578,7 +578,7 @@ TQValueList<MetaDataBase::Slot> MetaDataBase::slotList( TQObject *o )
bool MetaDataBase::isSlotUsed( TQObject *o, const TQCString &slot )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -596,7 +596,7 @@ bool MetaDataBase::isSlotUsed( TQObject *o, const TQCString &slot )
void MetaDataBase::changeSlot( TQObject *o, const TQCString &slot, const TQCString &newName )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -617,7 +617,7 @@ void MetaDataBase::changeSlotAttributes( TQObject *o, const TQCString &slot,
const TQString &language, const TQString &returnType )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -639,7 +639,7 @@ void MetaDataBase::changeSlotAttributes( TQObject *o, const TQCString &slot,
bool MetaDataBase::hasSlot( TQObject *o, const TQCString &slot, bool onlyCustom )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -647,14 +647,14 @@ bool MetaDataBase::hasSlot( TQObject *o, const TQCString &slot, bool onlyCustom
}
if ( !onlyCustom ) {
- TQStrList slotList = o->metaObject()->slotNames( true );
- if ( slotList.find( slot ) != -1 )
+ TQStrList slotList = o->tqmetaObject()->slotNames( true );
+ if ( slotList.tqfind( slot ) != -1 )
return true;
if ( o->inherits( "FormWindow" ) ) {
- o = ( (FormWindow*)o )->mainContainer();
- slotList = o->metaObject()->slotNames( true );
- if ( slotList.find( slot ) != -1 )
+ o = TQT_TQOBJECT(( (FormWindow*)o )->mainContainer());
+ slotList = o->tqmetaObject()->slotNames( true );
+ if ( slotList.tqfind( slot ) != -1 )
return true;
}
@@ -682,11 +682,11 @@ bool MetaDataBase::hasSlot( TQObject *o, const TQCString &slot, bool onlyCustom
TQString MetaDataBase::languageOfSlot( TQObject *o, const TQCString &slot )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
- return TQString::null;
+ return TQString();
}
TQString sl = slot;
@@ -698,7 +698,7 @@ TQString MetaDataBase::languageOfSlot( TQObject *o, const TQCString &slot )
if ( sl == sl2 )
return s.language;
}
- return TQString::null;
+ return TQString();
}
bool MetaDataBase::addCustomWidget( CustomWidget *wid )
@@ -779,7 +779,7 @@ bool MetaDataBase::hasCustomWidget( const TQString &className )
void MetaDataBase::setTabOrder( TQWidget *w, const TQWidgetList &order )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*) w );
+ MetaDataBaseRecord *r = db->tqfind( (void*) w );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
w, w->name(), w->className() );
@@ -792,7 +792,7 @@ void MetaDataBase::setTabOrder( TQWidget *w, const TQWidgetList &order )
TQWidgetList MetaDataBase::tabOrder( TQWidget *w )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*) w );
+ MetaDataBaseRecord *r = db->tqfind( (void*) w );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
w, w->name(), w->className() );
@@ -805,7 +805,7 @@ TQWidgetList MetaDataBase::tabOrder( TQWidget *w )
void MetaDataBase::setIncludes( TQObject *o, const TQValueList<Include> &incs )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -818,7 +818,7 @@ void MetaDataBase::setIncludes( TQObject *o, const TQValueList<Include> &incs )
TQValueList<MetaDataBase::Include> MetaDataBase::includes( TQObject *o )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -831,7 +831,7 @@ TQValueList<MetaDataBase::Include> MetaDataBase::includes( TQObject *o )
void MetaDataBase::setForwards( TQObject *o, const TQStringList &fwds )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -844,7 +844,7 @@ void MetaDataBase::setForwards( TQObject *o, const TQStringList &fwds )
TQStringList MetaDataBase::forwards( TQObject *o )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -857,7 +857,7 @@ TQStringList MetaDataBase::forwards( TQObject *o )
void MetaDataBase::setSignalList( TQObject *o, const TQStringList &sigs )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -871,10 +871,10 @@ void MetaDataBase::setSignalList( TQObject *o, const TQStringList &sigs )
bool hasSemicolon = s.endsWith( ";" );
if ( hasSemicolon )
s = s.left( s.length() - 1 );
- int p = s.find( '(' );
+ int p = s.tqfind( '(' );
if ( p < 0 )
p = s.length();
- int sp = s.find( ' ' );
+ int sp = s.tqfind( ' ' );
if ( sp >= 0 && sp < p ) {
s = s.mid( sp+1 );
p -= sp + 1;
@@ -890,7 +890,7 @@ void MetaDataBase::setSignalList( TQObject *o, const TQStringList &sigs )
TQStringList MetaDataBase::signalList( TQObject *o )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -903,7 +903,7 @@ TQStringList MetaDataBase::signalList( TQObject *o )
void MetaDataBase::setMetaInfo( TQObject *o, MetaInfo mi )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -916,7 +916,7 @@ void MetaDataBase::setMetaInfo( TQObject *o, MetaInfo mi )
MetaDataBase::MetaInfo MetaDataBase::metaInfo( TQObject *o )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -934,7 +934,7 @@ MetaDataBase::CustomWidget::CustomWidget()
className = "MyCustomWidget";
includeFile = "mywidget.h";
includePolicy = Local;
- sizeHint = TQSize( -1, -1 );
+ tqsizeHint = TQSize( -1, -1 );
pixmap = new TQPixmap( PixmapChooser::loadPixmap( "customwidget.xpm" ) );
id = -1;
sizePolicy = TQSizePolicy( TQSizePolicy::Preferred, TQSizePolicy::Preferred );
@@ -946,7 +946,7 @@ MetaDataBase::CustomWidget::CustomWidget( const CustomWidget &w )
className = w.className;
includeFile = w.includeFile;
includePolicy = w.includePolicy;
- sizeHint = w.sizeHint;
+ tqsizeHint = w.tqsizeHint;
if ( w.pixmap )
pixmap = new TQPixmap( *w.pixmap );
else
@@ -958,7 +958,7 @@ MetaDataBase::CustomWidget::CustomWidget( const CustomWidget &w )
void MetaDataBase::setCursor( TQWidget *w, const TQCursor &c )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)w );
+ MetaDataBaseRecord *r = db->tqfind( (void*)w );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
w, w->name(), w->className() );
@@ -971,7 +971,7 @@ void MetaDataBase::setCursor( TQWidget *w, const TQCursor &c )
TQCursor MetaDataBase::cursor( TQWidget *w )
{
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)w );
+ MetaDataBaseRecord *r = db->tqfind( (void*)w );
if ( !r ) {
w->unsetCursor();
return w->cursor();
@@ -991,7 +991,7 @@ MetaDataBase::CustomWidget &MetaDataBase::CustomWidget::operator=( const CustomW
className = w.className;
includeFile = w.includeFile;
includePolicy = w.includePolicy;
- sizeHint = w.sizeHint;
+ tqsizeHint = w.tqsizeHint;
if ( w.pixmap )
pixmap = new TQPixmap( *w.pixmap );
else
@@ -1006,8 +1006,8 @@ MetaDataBase::CustomWidget &MetaDataBase::CustomWidget::operator=( const CustomW
bool MetaDataBase::CustomWidget::hasSignal( const TQCString &signal ) const
{
- TQStrList sigList = TQWidget::staticMetaObject()->signalNames( true );
- if ( sigList.find( signal ) != -1 )
+ TQStrList sigList = TQWidget::tqstaticMetaObject()->signalNames( true );
+ if ( sigList.tqfind( signal ) != -1 )
return true;
for ( TQValueList<TQCString>::ConstIterator it = lstSignals.begin(); it != lstSignals.end(); ++it ) {
if ( normalizeSlot( *it ) == normalizeSlot( signal ) )
@@ -1018,8 +1018,8 @@ bool MetaDataBase::CustomWidget::hasSignal( const TQCString &signal ) const
bool MetaDataBase::CustomWidget::hasSlot( const TQCString &slot ) const
{
- TQStrList slotList = TQWidget::staticMetaObject()->slotNames( true );
- if ( slotList.find( normalizeSlot( slot ) ) != -1 )
+ TQStrList slotList = TQWidget::tqstaticMetaObject()->slotNames( true );
+ if ( slotList.tqfind( normalizeSlot( slot ) ) != -1 )
return true;
for ( TQValueList<MetaDataBase::Slot>::ConstIterator it = lstSlots.begin(); it != lstSlots.end(); ++it ) {
@@ -1031,8 +1031,8 @@ bool MetaDataBase::CustomWidget::hasSlot( const TQCString &slot ) const
bool MetaDataBase::CustomWidget::hasProperty( const TQCString &prop ) const
{
- TQStrList propList = TQWidget::staticMetaObject()->propertyNames( true );
- if ( propList.find( prop ) != -1 )
+ TQStrList propList = TQWidget::tqstaticMetaObject()->propertyNames( true );
+ if ( propList.tqfind( prop ) != -1 )
return true;
for ( TQValueList<MetaDataBase::Property>::ConstIterator it = lstProperties.begin(); it != lstProperties.end(); ++it ) {
@@ -1047,7 +1047,7 @@ void MetaDataBase::setPixmapArgument( TQObject *o, int pixmap, const TQString &a
if ( !o )
return;
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -1061,16 +1061,16 @@ void MetaDataBase::setPixmapArgument( TQObject *o, int pixmap, const TQString &a
TQString MetaDataBase::pixmapArgument( TQObject *o, int pixmap )
{
if ( !o )
- return TQString::null;
+ return TQString();
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
- return TQString::null;
+ return TQString();
}
- return *r->pixmapArguments.find( pixmap );
+ return *r->pixmapArguments.tqfind( pixmap );
}
void MetaDataBase::clearPixmapArguments( TQObject *o )
@@ -1078,7 +1078,7 @@ void MetaDataBase::clearPixmapArguments( TQObject *o )
if ( !o )
return;
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -1094,7 +1094,7 @@ void MetaDataBase::setPixmapKey( TQObject *o, int pixmap, const TQString &arg )
if ( !o )
return;
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -1108,16 +1108,16 @@ void MetaDataBase::setPixmapKey( TQObject *o, int pixmap, const TQString &arg )
TQString MetaDataBase::pixmapKey( TQObject *o, int pixmap )
{
if ( !o )
- return TQString::null;
+ return TQString();
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
- return TQString::null;
+ return TQString();
}
- return *r->pixmapKeys.find( pixmap );
+ return *r->pixmapKeys.tqfind( pixmap );
}
void MetaDataBase::clearPixmapKeys( TQObject *o )
@@ -1125,7 +1125,7 @@ void MetaDataBase::clearPixmapKeys( TQObject *o )
if ( !o )
return;
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -1142,7 +1142,7 @@ void MetaDataBase::setColumnFields( TQObject *o, const TQMap<TQString, TQString>
if ( !o )
return;
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -1157,7 +1157,7 @@ TQMap<TQString, TQString> MetaDataBase::columnFields( TQObject *o )
if ( !o )
return TQMap<TQString, TQString>();
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -1187,7 +1187,7 @@ void MetaDataBase::setExportMacro( TQObject *o, const TQString &macro )
if ( !o )
return;
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -1202,7 +1202,7 @@ TQString MetaDataBase::exportMacro( TQObject *o )
if ( !o )
return "";
setupDataBase();
- MetaDataBaseRecord *r = db->find( (void*)o );
+ MetaDataBaseRecord *r = db->tqfind( (void*)o );
if ( !r ) {
qWarning( "No entry for %p (%s, %s) found in MetaDataBase",
o, o->name(), o->className() );
@@ -1214,6 +1214,6 @@ TQString MetaDataBase::exportMacro( TQObject *o )
bool MetaDataBase::hasObject( TQObject *o )
{
- return !!db->find( o );
+ return !!db->tqfind( o );
}
diff --git a/kommander/editor/metadatabase.h b/kommander/editor/metadatabase.h
index d5aceff5..5251e793 100644
--- a/kommander/editor/metadatabase.h
+++ b/kommander/editor/metadatabase.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -92,7 +92,7 @@ public:
TQString className;
TQString includeFile;
IncludePolicy includePolicy;
- TQSize sizeHint;
+ TQSize tqsizeHint;
TQSizePolicy sizePolicy;
TQPixmap *pixmap;
TQValueList<TQCString> lstSignals;
@@ -125,7 +125,7 @@ public:
{
TQString name;
TQStringList args;
-#if defined(Q_FULL_TEMPLATE_INSTANTIATION)
+#if defined(TQ_FULL_TEMPLATE_INSTANTIATION)
bool operator==( const EventDescription& ) const { return FALSE; }
#endif
};
diff --git a/kommander/editor/multilineeditor.ui b/kommander/editor/multilineeditor.ui
index 9b9cbe9f..47ce1172 100644
--- a/kommander/editor/multilineeditor.ui
+++ b/kommander/editor/multilineeditor.ui
@@ -19,13 +19,13 @@
**
*********************************************************************</comment>
<widget>
- <class>QDialog</class>
+ <class>TQDialog</class>
<property stdset="1">
<name>name</name>
<cstring>MultiLineEditorBase</cstring>
</property>
<property stdset="1">
- <name>geometry</name>
+ <name>tqgeometry</name>
<rect>
<x>0</x>
<y>0</y>
@@ -55,7 +55,7 @@
<number>6</number>
</property>
<widget>
- <class>QLabel</class>
+ <class>TQLabel</class>
<property stdset="1">
<name>name</name>
<cstring>TextLabel1</cstring>
@@ -70,7 +70,7 @@
</property>
</widget>
<widget>
- <class>QMultiLineEdit</class>
+ <class>TQMultiLineEdit</class>
<property stdset="1">
<name>name</name>
<cstring>preview</cstring>
@@ -85,7 +85,7 @@
</property>
</widget>
<widget>
- <class>QLayoutWidget</class>
+ <class>TQLayoutWidget</class>
<property stdset="1">
<name>name</name>
<cstring>Layout1</cstring>
@@ -100,7 +100,7 @@
<number>6</number>
</property>
<widget>
- <class>QPushButton</class>
+ <class>TQPushButton</class>
<property stdset="1">
<name>name</name>
<cstring>buttonHelp</cstring>
@@ -128,7 +128,7 @@
<enum>Expanding</enum>
</property>
<property>
- <name>sizeHint</name>
+ <name>tqsizeHint</name>
<size>
<width>20</width>
<height>20</height>
@@ -136,7 +136,7 @@
</property>
</spacer>
<widget>
- <class>QPushButton</class>
+ <class>TQPushButton</class>
<property stdset="1">
<name>name</name>
<cstring>buttonOk</cstring>
@@ -159,7 +159,7 @@
</property>
</widget>
<widget>
- <class>QPushButton</class>
+ <class>TQPushButton</class>
<property stdset="1">
<name>name</name>
<cstring>buttonApply</cstring>
@@ -178,7 +178,7 @@
</property>
</widget>
<widget>
- <class>QPushButton</class>
+ <class>TQPushButton</class>
<property stdset="1">
<name>name</name>
<cstring>buttonCancel</cstring>
diff --git a/kommander/editor/multilineeditorimpl.cpp b/kommander/editor/multilineeditorimpl.cpp
index 2a0ec9b7..98ad65d6 100644
--- a/kommander/editor/multilineeditorimpl.cpp
+++ b/kommander/editor/multilineeditorimpl.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -28,13 +28,13 @@
#include <klocale.h>
-MultiLineEditor::MultiLineEditor( TQWidget *parent, TQWidget *editWidget, FormWindow *fw )
- : MultiLineEditorBase( parent, 0, true ), formwindow( fw )
+MultiLineEditor::MultiLineEditor( TQWidget *tqparent, TQWidget *editWidget, FormWindow *fw )
+ : MultiLineEditorBase( tqparent, 0, true ), formwindow( fw )
{
connect( buttonHelp, TQT_SIGNAL( clicked() ), MainWindow::self, TQT_SLOT( showDialogHelp() ) );
mlined = (TQMultiLineEdit*)editWidget;
// #### complete list of properties here
- preview->setAlignment( mlined->alignment() );
+ preview->tqsetAlignment( mlined->tqalignment() );
preview->setMaxLines( mlined->maxLines() );
preview->setWordWrap( mlined->wordWrap() );
preview->setWrapColumnOrWidth( mlined->wrapColumnOrWidth() );
@@ -53,7 +53,7 @@ void MultiLineEditor::okClicked()
void MultiLineEditor::applyClicked()
{
- PopulateMultiLineEditCommand *cmd = new PopulateMultiLineEditCommand( i18n("Set Text of '%1'" ).arg( mlined->name() ),
+ PopulateMultiLineEditCommand *cmd = new PopulateMultiLineEditCommand( i18n("Set Text of '%1'" ).tqarg( mlined->name() ),
formwindow, mlined, preview->text() );
cmd->execute();
formwindow->commandHistory()->addCommand( cmd );
@@ -61,8 +61,8 @@ void MultiLineEditor::applyClicked()
}
-TextEditor::TextEditor( TQWidget *parent, const TQString &text )
- : MultiLineEditorBase( parent, 0, true )
+TextEditor::TextEditor( TQWidget *tqparent, const TQString &text )
+ : MultiLineEditorBase( tqparent, 0, true )
{
buttonApply->hide();
setCaption( i18n("Text" ) );
@@ -71,9 +71,9 @@ TextEditor::TextEditor( TQWidget *parent, const TQString &text )
preview->selectAll();
}
-TQString TextEditor::getText( TQWidget *parent, const TQString &text )
+TQString TextEditor::getText( TQWidget *tqparent, const TQString &text )
{
- TextEditor dlg( parent, text );
+ TextEditor dlg( tqparent, text );
if ( dlg.exec() == TQDialog::Accepted ) {
TQString txt = dlg.preview->text();
int i = txt.length() - 1;
@@ -84,7 +84,7 @@ TQString TextEditor::getText( TQWidget *parent, const TQString &text )
}
return txt;
}
- return TQString::null;
+ return TQString();
}
void TextEditor::okClicked()
diff --git a/kommander/editor/multilineeditorimpl.h b/kommander/editor/multilineeditorimpl.h
index d26c7f78..a5d48479 100644
--- a/kommander/editor/multilineeditorimpl.h
+++ b/kommander/editor/multilineeditorimpl.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -29,9 +29,10 @@ class TQMultiLineEdit;
class MultiLineEditor : public MultiLineEditorBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- MultiLineEditor( TQWidget *parent, TQWidget *editWidget, FormWindow *fw );
+ MultiLineEditor( TQWidget *tqparent, TQWidget *editWidget, FormWindow *fw );
protected slots:
void okClicked();
@@ -46,11 +47,12 @@ private:
class TextEditor : public MultiLineEditorBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- TextEditor( TQWidget *parent, const TQString &text );
+ TextEditor( TQWidget *tqparent, const TQString &text );
- static TQString getText( TQWidget *parent, const TQString &text );
+ static TQString getText( TQWidget *tqparent, const TQString &text );
protected slots:
void okClicked();
diff --git a/kommander/editor/newform.ui b/kommander/editor/newform.ui
index 16bb0365..c1e14bd6 100644
--- a/kommander/editor/newform.ui
+++ b/kommander/editor/newform.ui
@@ -19,7 +19,7 @@
** not clear to you.
**
*********************************************************************</comment>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>NewFormBase</cstring>
</property>
@@ -50,7 +50,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget" row="2" column="0" rowspan="1" colspan="3">
+ <widget class="TQLayoutWidget" row="2" column="0" rowspan="1" colspan="3">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -64,7 +64,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>helpButton</cstring>
</property>
@@ -85,14 +85,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>0</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonOk</cstring>
</property>
@@ -109,7 +109,7 @@
<string>Create a new form using the selected template.</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonCancel</cstring>
</property>
@@ -125,7 +125,7 @@
</widget>
</hbox>
</widget>
- <widget class="QIconView" row="1" column="0" rowspan="1" colspan="3">
+ <widget class="TQIconView" row="1" column="0" rowspan="1" colspan="3">
<property name="name">
<cstring>templateView</cstring>
</property>
@@ -155,7 +155,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>0</height>
@@ -179,19 +179,19 @@
</connection>
<connection>
<sender>templateView</sender>
- <signal>currentChanged(QIconViewItem*)</signal>
+ <signal>currentChanged(TQIconViewItem*)</signal>
<receiver>NewFormBase</receiver>
- <slot>itemChanged(QIconViewItem*)</slot>
+ <slot>itemChanged(TQIconViewItem*)</slot>
</connection>
<connection>
<sender>templateView</sender>
- <signal>doubleClicked(QIconViewItem*)</signal>
+ <signal>doubleClicked(TQIconViewItem*)</signal>
<receiver>NewFormBase</receiver>
<slot>accept()</slot>
</connection>
<connection>
<sender>templateView</sender>
- <signal>returnPressed(QIconViewItem*)</signal>
+ <signal>returnPressed(TQIconViewItem*)</signal>
<receiver>NewFormBase</receiver>
<slot>accept()</slot>
</connection>
@@ -202,9 +202,9 @@
<tabstop>buttonOk</tabstop>
<tabstop>buttonCancel</tabstop>
</tabstops>
-<slots>
- <slot access="protected">itemChanged( QIconViewItem * )</slot>
+<Q_SLOTS>
+ <slot access="protected">itemChanged( TQIconViewItem * )</slot>
<slot access="protected">projectChanged( const QString &amp; )</slot>
-</slots>
-<layoutdefaults spacing="6" margin="11"/>
+</Q_SLOTS>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/editor/newformimpl.cpp b/kommander/editor/newformimpl.cpp
index ee623e48..e1ef5662 100644
--- a/kommander/editor/newformimpl.cpp
+++ b/kommander/editor/newformimpl.cpp
@@ -1,5 +1,5 @@
/**********************************************************************
- This file is based on Qt Designer, Copyright (C) 2000 Trolltech AS. �All rights reserved.
+ This file is based on TQt Designer, Copyright (C) 2000 Trolltech AS. �All rights reserved.
This file may be distributed and/or modified under the terms of the
GNU General Public License version 2 as published by the Free Software
@@ -57,7 +57,7 @@ void FormItem::insert()
FormWindow *fw = 0;
FormFile *ff = new FormFile(FormFile::createUnnamedFileName(), true);
fw = new FormWindow(ff, MainWindow::self, MainWindow::self->qWorkspace(), n);
- MetaDataBase::addEntry(fw);
+ MetaDataBase::addEntry(TQT_TQOBJECT(fw));
TQWidget *w = 0L;
if (fType == Dialog)
{
@@ -72,7 +72,7 @@ void FormItem::insert()
if (w)
{
w->setProperty("useInternalParser", true);
- MetaDataBase::setPropertyChanged(w, "useInternalParser", true);
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(w), "useInternalParser", true);
}
fw->setCaption(n);
fw->resize(600, 480);
@@ -81,7 +81,7 @@ void FormItem::insert()
// the wizard might have changed a lot, lets update everything
MainWindow::self->actioneditor()->setFormWindow(fw);
MainWindow::self->objectHierarchy()->setFormWindow(fw, fw);
- fw->killAccels(fw);
+ fw->killAccels(TQT_TQOBJECT(fw));
fw->setFocus();
}
@@ -100,12 +100,12 @@ static void unifyFormName(FormWindow *fw, TQWorkspace *qworkspace)
if (w != fw)
lst << w->name();
- if (lst.findIndex(fw->name()) == -1)
+ if (lst.tqfindIndex(fw->name()) == -1)
return;
TQString origName = fw->name();
TQString n = origName;
int i = 1;
- while (lst.findIndex(n) != -1)
+ while (lst.tqfindIndex(n) != -1)
n = origName + TQString::number(i++);
fw->setName(n);
fw->setCaption(n);
@@ -121,22 +121,22 @@ void CustomFormItem::insert()
if (!resource.load(ff))
{
TQMessageBox::information(MainWindow::self, i18n("Load Template"),
- i18n("Could not load form description from template '%1'").arg(filename));
+ i18n("Could not load form description from template '%1'").tqarg(filename));
delete ff;
return;
}
- ff->setFileName(TQString::null);
+ ff->setFileName(TQString());
if (MainWindow::self->formWindow())
{
- MainWindow::self->formWindow()->setFileName(TQString::null);
+ MainWindow::self->formWindow()->setFileName(TQString());
unifyFormName(MainWindow::self->formWindow(), MainWindow::self->qWorkspace());
}
}
}
-NewForm::NewForm(TQWidget *parent, const TQString &templatePath)
- : NewFormBase(parent, 0, true)
+NewForm::NewForm(TQWidget *tqparent, const TQString &templatePath)
+ : NewFormBase(tqparent, 0, true)
{
connect(helpButton, TQT_SIGNAL(clicked()), MainWindow::self, TQT_SLOT(showDialogHelp()));
@@ -165,15 +165,15 @@ NewForm::NewForm(TQWidget *parent, const TQString &templatePath)
if (!TQFile::exists(*it))
continue;
TQDir dir(*it);
- const QFileInfoList* fileList = dir.entryInfoList(TQDir::DefaultFilter, TQDir::DirsFirst | TQDir::Name);
+ const TQFileInfoList* fileList = dir.entryInfoList(TQDir::DefaultFilter, TQDir::DirsFirst | TQDir::Name);
if (fileList)
- for (QFileInfoListIterator fit(*fileList); fit.current(); ++fit)
+ for (TQFileInfoListIterator fit(*fileList); fit.current(); ++fit)
{
TQFileInfo* fi = fit.current();
if (!fi->isFile() || fi->extension() != "kmdr")
continue;
TQString name = fi->baseName();
- name = name.replace("_", " ");
+ name = name.tqreplace("_", " ");
CustomFormItem *ci = new CustomFormItem(templateView, name);
allItems.append(ci);
ci->setDragEnabled(false);
diff --git a/kommander/editor/newformimpl.h b/kommander/editor/newformimpl.h
index 9aad4155..6b28a631 100644
--- a/kommander/editor/newformimpl.h
+++ b/kommander/editor/newformimpl.h
@@ -1,5 +1,5 @@
/**********************************************************************
- This file is based on Qt Designer, Copyright (C) 2000 Trolltech AS.  All rights reserved.
+ This file is based on TQt Designer, Copyright (C) 2000 Trolltech AS.  All rights reserved.
This file may be distributed and/or modified under the terms of the
GNU General Public License version 2 as published by the Free Software
@@ -25,7 +25,7 @@
class FormFile;
-class NewItem : public QIconViewItem
+class NewItem : public TQIconViewItem
{
public:
enum Type {Form, CustomForm};
@@ -61,8 +61,9 @@ private:
class NewForm : public NewFormBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- NewForm( TQWidget *parent, const TQString &templatePath );
+ NewForm( TQWidget *tqparent, const TQString &templatePath );
void accept();
protected slots:
void itemChanged(TQIconViewItem *item);
diff --git a/kommander/editor/orderindicator.cpp b/kommander/editor/orderindicator.cpp
index fee29150..056601b8 100644
--- a/kommander/editor/orderindicator.cpp
+++ b/kommander/editor/orderindicator.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -63,7 +63,7 @@ void OrderIndicator::setOrder( int i, TQWidget* wid )
TQFont f( font() );
f.setBold( true );
setFont( f );
- resize( QMAX( w, h ), h );
+ resize( TQMAX( w, h ), h );
update(); // in case the size didn't change
reposition();
show();
@@ -72,7 +72,7 @@ void OrderIndicator::setOrder( int i, TQWidget* wid )
void OrderIndicator::reposition()
{
- TQPoint p =parentWidget()->mapFromGlobal( widget->mapToGlobal( widget->rect().topLeft() ) );
+ TQPoint p =tqparentWidget()->mapFromGlobal( widget->mapToGlobal( widget->rect().topLeft() ) );
move( p - TQPoint( width()/3, height()/3 ) );
}
diff --git a/kommander/editor/orderindicator.h b/kommander/editor/orderindicator.h
index 24cae185..ae696c95 100644
--- a/kommander/editor/orderindicator.h
+++ b/kommander/editor/orderindicator.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -25,9 +25,10 @@
class FormWindow;
-class OrderIndicator : public QWidget
+class OrderIndicator : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
OrderIndicator( int i, TQWidget* w, FormWindow* fw );
diff --git a/kommander/editor/paletteeditor.ui b/kommander/editor/paletteeditor.ui
index 31a4cd8a..814785dd 100644
--- a/kommander/editor/paletteeditor.ui
+++ b/kommander/editor/paletteeditor.ui
@@ -19,7 +19,7 @@
** not clear to you.
**
*********************************************************************</comment>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>PaletteEditorBase</cstring>
</property>
@@ -52,7 +52,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupAutoPalette</cstring>
</property>
@@ -67,7 +67,7 @@
<property name="title">
<string>Build Palette</string>
</property>
- <property name="alignment">
+ <property name="tqalignment">
<set>AlignAuto</set>
</property>
<hbox>
@@ -80,7 +80,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>labelMainColor</cstring>
</property>
@@ -92,7 +92,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>50</width>
<height>0</height>
@@ -110,7 +110,7 @@
<property name="text">
<string>&amp;3D effects:</string>
</property>
- <property name="alignment">
+ <property name="tqalignment">
<set>AlignVCenter</set>
</property>
<property name="buddy" stdset="0">
@@ -142,7 +142,7 @@
<string>Choose the effect-color for the generated palette.</string>
</property>
</widget>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>labelMainColor2</cstring>
</property>
@@ -154,7 +154,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>50</width>
<height>0</height>
@@ -172,7 +172,7 @@
<property name="text">
<string>Back&amp;ground:</string>
</property>
- <property name="alignment">
+ <property name="tqalignment">
<set>AlignVCenter</set>
</property>
<property name="buddy" stdset="0">
@@ -214,14 +214,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>btnAdvanced</cstring>
</property>
@@ -231,7 +231,7 @@
</widget>
</hbox>
</widget>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>GroupBox126</cstring>
</property>
@@ -256,7 +256,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout2</cstring>
</property>
@@ -270,7 +270,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -281,7 +281,7 @@
<cstring>paletteCombo</cstring>
</property>
</widget>
- <widget class="QComboBox">
+ <widget class="TQComboBox">
<item>
<property name="text">
<string>Active Palette</string>
@@ -318,7 +318,7 @@
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout3</cstring>
</property>
@@ -332,7 +332,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonHelp</cstring>
</property>
@@ -353,14 +353,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonOk</cstring>
</property>
@@ -377,7 +377,7 @@
<string>Close the dialog and apply all the changes.</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonCancel</cstring>
</property>
@@ -501,15 +501,15 @@
<tabstop>paletteCombo</tabstop>
<tabstop>buttonHelp</tabstop>
</tabstops>
-<slots>
+<Q_SLOTS>
<slot access="protected">init()</slot>
<slot access="protected">destroy()</slot>
<slot access="protected">onTune()</slot>
<slot access="protected">onChoose2ndMainColor()</slot>
<slot access="protected">onChooseMainColor()</slot>
<slot access="protected">paletteSelected(int)</slot>
-</slots>
-<layoutdefaults spacing="6" margin="11"/>
+</Q_SLOTS>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>styledbutton.h</includehint>
<includehint>styledbutton.h</includehint>
diff --git a/kommander/editor/paletteeditoradvanced.ui b/kommander/editor/paletteeditoradvanced.ui
index cf868b69..5d2c41af 100644
--- a/kommander/editor/paletteeditoradvanced.ui
+++ b/kommander/editor/paletteeditoradvanced.ui
@@ -19,7 +19,7 @@
** not clear to you.
**
*********************************************************************</comment>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>PaletteEditorAdvancedBase</cstring>
</property>
@@ -41,7 +41,7 @@
<bool>true</bool>
</property>
<property name="whatsThis" stdset="0">
- <string>&lt;b&gt;Edit Palette&lt;/b&gt;&lt;p&gt;Change the current widget or form's palette.&lt;/p&gt;&lt;p&gt;Use a generated palette or select colors for each color group and each color role.&lt;/p&gt;&lt;p&gt;The palette can be tested with different widget layouts in the preview section.&lt;/p&gt;</string>
+ <string>&lt;b&gt;Edit Palette&lt;/b&gt;&lt;p&gt;Change the current widget or form's palette.&lt;/p&gt;&lt;p&gt;Use a generated palette or select colors for each color group and each color role.&lt;/p&gt;&lt;p&gt;The palette can be tested with different widget tqlayouts in the preview section.&lt;/p&gt;</string>
</property>
<vbox>
<property name="name">
@@ -53,7 +53,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout14</cstring>
</property>
@@ -67,7 +67,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -84,7 +84,7 @@
<cstring>paletteCombo</cstring>
</property>
</widget>
- <widget class="QComboBox">
+ <widget class="TQComboBox">
<item>
<property name="text">
<string>Active Palette</string>
@@ -106,7 +106,7 @@
</widget>
</hbox>
</widget>
- <widget class="QButtonGroup">
+ <widget class="TQButtonGroup">
<property name="name">
<cstring>ButtonGroup1</cstring>
</property>
@@ -131,7 +131,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>checkBuildInactive</cstring>
</property>
@@ -142,7 +142,7 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>checkBuildDisabled</cstring>
</property>
@@ -155,7 +155,7 @@
</widget>
</vbox>
</widget>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupCentral</cstring>
</property>
@@ -172,7 +172,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QComboBox">
+ <widget class="TQComboBox">
<item>
<property name="text">
<string>Background</string>
@@ -238,7 +238,7 @@
<string>&lt;b&gt;Select a color role.&lt;/b&gt;&lt;p&gt;Available central color roles are: &lt;ul&gt; &lt;li&gt;Background - general background color.&lt;/li&gt; &lt;li&gt;Foreground - general foreground color. &lt;/li&gt; &lt;li&gt;Base - used as the background color for example, for text entry widgets; it is usually white or another light color. &lt;/li&gt; &lt;li&gt;Text - the forground color used with Base. Usually this is the same as the Foreground, in which case it must provide good contrast both with the Background and with the Base. &lt;/li&gt; &lt;li&gt;Button - general button background color; useful where buttons need a background different from Background, as in the Macintosh style. &lt;/li&gt; &lt;li&gt;ButtonText - a foreground color used with the Button color. &lt;/li&gt; &lt;li&gt;Highlight - a color used to indicate a selected or highlighted item. &lt;/li&gt; &lt;li&gt;HighlightedText - a text color that contrasts to Highlight. &lt;/li&gt; &lt;li&gt;BrightText - a text color that is very different from Foreground and contrasts well with, for example, black. &lt;/li&gt; &lt;/ul&gt; &lt;/p&gt;</string>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout32_2</cstring>
</property>
@@ -262,14 +262,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>labelPixmap</cstring>
</property>
@@ -313,7 +313,7 @@
<string>Choose a pixmap file for the selected central color role.</string>
</property>
</widget>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>labelCentral</cstring>
</property>
@@ -325,7 +325,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>0</width>
<height>0</height>
@@ -367,7 +367,7 @@
</widget>
</vbox>
</widget>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupEffect</cstring>
</property>
@@ -384,7 +384,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout32_3</cstring>
</property>
@@ -398,7 +398,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>checkBuildEffect</cstring>
</property>
@@ -415,7 +415,7 @@
<string>Check to let 3D-effect colors be calculated from the button-color.</string>
</property>
</widget>
- <widget class="QComboBox">
+ <widget class="TQComboBox">
<item>
<property name="text">
<string>Light</string>
@@ -453,7 +453,7 @@
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout31_2</cstring>
</property>
@@ -477,14 +477,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>labelEffect</cstring>
</property>
@@ -496,7 +496,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>0</width>
<height>0</height>
@@ -538,7 +538,7 @@
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout3</cstring>
</property>
@@ -552,7 +552,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonHelp</cstring>
</property>
@@ -573,14 +573,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonOk</cstring>
</property>
@@ -597,7 +597,7 @@
<string>Close the dialog and apply all the changes.</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonCancel</cstring>
</property>
@@ -743,7 +743,7 @@
<tabstop>buttonEffect</tabstop>
<tabstop>buttonHelp</tabstop>
</tabstops>
-<slots>
+<Q_SLOTS>
<slot access="protected">init()</slot>
<slot access="protected">destroy()</slot>
<slot access="protected">onToggleBuildDisabled(bool)</slot>
@@ -756,8 +756,8 @@
<slot access="protected">onToggleBuildInactive(bool)</slot>
<slot access="protected">paletteSelected(int)</slot>
<slot>showHelp()</slot>
-</slots>
-<layoutdefaults spacing="6" margin="11"/>
+</Q_SLOTS>
+<tqlayoutdefaults spacing="6" margin="11"/>
<includehints>
<includehint>styledbutton.h</includehint>
<includehint>styledbutton.h</includehint>
diff --git a/kommander/editor/paletteeditoradvancedimpl.cpp b/kommander/editor/paletteeditoradvancedimpl.cpp
index 69c90c33..243576c2 100644
--- a/kommander/editor/paletteeditoradvancedimpl.cpp
+++ b/kommander/editor/paletteeditoradvancedimpl.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -35,7 +35,7 @@
Class used by PaletteEditor for bold combobox items
*/
-class BoldListBoxText : public QListBoxText
+class BoldListBoxText : public TQListBoxText
{
public:
BoldListBoxText( TQString text, TQListBox* lb = 0 );
@@ -59,9 +59,9 @@ void BoldListBoxText::paint( TQPainter* painter )
TQListBoxText::paint( painter );
}
-PaletteEditorAdvanced::PaletteEditorAdvanced( FormWindow *fw, TQWidget * parent,
+PaletteEditorAdvanced::PaletteEditorAdvanced( FormWindow *fw, TQWidget * tqparent,
const char * name, bool modal, WFlags f )
- : PaletteEditorAdvancedBase( parent, name, modal, f ), formWindow( fw ), selectedPalette(0)
+ : PaletteEditorAdvancedBase( tqparent, name, modal, f ), formWindow( fw ), selectedPalette(0)
{
connect( buttonHelp, TQT_SIGNAL( clicked() ), MainWindow::self, TQT_SLOT( showDialogHelp() ) );
@@ -244,15 +244,15 @@ void PaletteEditorAdvanced::onCentral( int item )
case 0:
default:
c = editPalette.active().color( centralFromItem(item) );
- p = editPalette.active().brush( centralFromItem(item) ).pixmap();
+ p = editPalette.active().tqbrush( centralFromItem(item) ).pixmap();
break;
case 1:
c = editPalette.inactive().color( centralFromItem(item) );
- p = editPalette.inactive().brush( centralFromItem(item) ).pixmap();
+ p = editPalette.inactive().tqbrush( centralFromItem(item) ).pixmap();
break;
case 2:
c = editPalette.disabled().color( centralFromItem(item) );
- p = editPalette.disabled().brush( centralFromItem(item) ).pixmap();
+ p = editPalette.disabled().tqbrush( centralFromItem(item) ).pixmap();
break;
}
@@ -508,17 +508,17 @@ void PaletteEditorAdvanced::updateStyledButtons()
default:
central = editPalette.active().color( centralFromItem( comboCentral->currentItem() ) );
effect = editPalette.active().color( effectFromItem( comboEffect->currentItem() ) );
- pm = editPalette.active().brush( centralFromItem( comboCentral->currentItem() ) ).pixmap();
+ pm = editPalette.active().tqbrush( centralFromItem( comboCentral->currentItem() ) ).pixmap();
break;
case 1:
central = editPalette.inactive().color( centralFromItem( comboCentral->currentItem() ) );
effect = editPalette.inactive().color( effectFromItem( comboEffect->currentItem() ) );
- pm = editPalette.inactive().brush( centralFromItem( comboCentral->currentItem() ) ).pixmap();
+ pm = editPalette.inactive().tqbrush( centralFromItem( comboCentral->currentItem() ) ).pixmap();
break;
case 2:
central = editPalette.disabled().color( centralFromItem( comboCentral->currentItem() ) );
effect = editPalette.disabled().color( effectFromItem( comboEffect->currentItem() ) );
- pm = editPalette.disabled().brush( centralFromItem( comboCentral->currentItem() ) ).pixmap();
+ pm = editPalette.disabled().tqbrush( centralFromItem( comboCentral->currentItem() ) ).pixmap();
break;
}
@@ -613,10 +613,10 @@ void PaletteEditorAdvanced::setupBackgroundMode( BackgroundMode mode )
}
TQPalette PaletteEditorAdvanced::getPalette( bool *ok, const TQPalette &init,
- BackgroundMode mode, TQWidget* parent,
+ BackgroundMode mode, TQWidget* tqparent,
const char* name, FormWindow *fw )
{
- PaletteEditorAdvanced* dlg = new PaletteEditorAdvanced( fw, parent, name, true );
+ PaletteEditorAdvanced* dlg = new PaletteEditorAdvanced( fw, tqparent, name, true );
dlg->setupBackgroundMode( mode );
if ( init != TQPalette() )
diff --git a/kommander/editor/paletteeditoradvancedimpl.h b/kommander/editor/paletteeditoradvancedimpl.h
index b9c378dd..ed0bcc39 100644
--- a/kommander/editor/paletteeditoradvancedimpl.h
+++ b/kommander/editor/paletteeditoradvancedimpl.h
@@ -4,7 +4,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -28,13 +28,14 @@ class FormWindow;
class PaletteEditorAdvanced : public PaletteEditorAdvancedBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- PaletteEditorAdvanced( FormWindow *fw, TQWidget * parent=0, const char * name=0,
+ PaletteEditorAdvanced( FormWindow *fw, TQWidget * tqparent=0, const char * name=0,
bool modal=FALSE, WFlags f=0 );
~PaletteEditorAdvanced();
static TQPalette getPalette( bool *ok, const TQPalette &pal, BackgroundMode mode = PaletteBackground,
- TQWidget* parent = 0, const char* name = 0, FormWindow *fw = 0 );
+ TQWidget* tqparent = 0, const char* name = 0, FormWindow *fw = 0 );
protected slots:
void paletteSelected(int);
diff --git a/kommander/editor/paletteeditorimpl.cpp b/kommander/editor/paletteeditorimpl.cpp
index bc3877f4..89d1f624 100644
--- a/kommander/editor/paletteeditorimpl.cpp
+++ b/kommander/editor/paletteeditorimpl.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -30,8 +30,8 @@
#include <tqapplication.h>
#include <tqpushbutton.h>
-PaletteEditor::PaletteEditor( FormWindow *fw, TQWidget * parent, const char * name, bool modal, WFlags f )
- : PaletteEditorBase( parent, name, modal, f ), formWindow( fw )
+PaletteEditor::PaletteEditor( FormWindow *fw, TQWidget * tqparent, const char * name, bool modal, WFlags f )
+ : PaletteEditorBase( tqparent, name, modal, f ), formWindow( fw )
{
connect( buttonHelp, TQT_SIGNAL( clicked() ), MainWindow::self, TQT_SLOT( showDialogHelp() ) );
@@ -275,9 +275,9 @@ TQPalette PaletteEditor::pal() const
}
TQPalette PaletteEditor::getPalette( bool *ok, const TQPalette &init, BackgroundMode mode,
- TQWidget* parent, const char* name, FormWindow *fw )
+ TQWidget* tqparent, const char* name, FormWindow *fw )
{
- PaletteEditor* dlg = new PaletteEditor( fw, parent, name, true );
+ PaletteEditor* dlg = new PaletteEditor( fw, tqparent, name, true );
dlg->setupBackgroundMode( mode );
if ( init != TQPalette() )
diff --git a/kommander/editor/paletteeditorimpl.h b/kommander/editor/paletteeditorimpl.h
index abd68dfc..54e45612 100644
--- a/kommander/editor/paletteeditorimpl.h
+++ b/kommander/editor/paletteeditorimpl.h
@@ -4,7 +4,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -28,13 +28,14 @@ class FormWindow;
class PaletteEditor : public PaletteEditorBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- PaletteEditor( FormWindow *fw, TQWidget * parent=0, const char * name=0, bool modal=FALSE, WFlags f=0 );
+ PaletteEditor( FormWindow *fw, TQWidget * tqparent=0, const char * name=0, bool modal=FALSE, WFlags f=0 );
~PaletteEditor();
static TQPalette getPalette( bool *ok, const TQPalette &pal, BackgroundMode mode = PaletteBackground,
- TQWidget* parent = 0, const char* name = 0, FormWindow *fw = 0 );
+ TQWidget* tqparent = 0, const char* name = 0, FormWindow *fw = 0 );
protected slots:
void onChooseMainColor();
diff --git a/kommander/editor/parser.cpp b/kommander/editor/parser.cpp
index 15374aa5..cbd3946a 100644
--- a/kommander/editor/parser.cpp
+++ b/kommander/editor/parser.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -22,7 +22,7 @@
#include <tqobject.h>
#include <tqstringlist.h>
-class NormalizeObject : public QObject
+class NormalizeObject : public TQObject
{
public:
NormalizeObject() : TQObject() {}
@@ -32,9 +32,9 @@ public:
TQString Parser::cleanArgs( const TQString &func )
{
TQString slot( func );
- int begin = slot.find( "(" ) + 1;
+ int begin = slot.tqfind( "(" ) + 1;
TQString args = slot.mid( begin );
- args = args.left( args.find( ")" ) );
+ args = args.left( args.tqfind( ")" ) );
TQStringList lst = TQStringList::split( ',', args );
TQString res = slot.left( begin );
for ( TQStringList::Iterator it = lst.begin(); it != lst.end(); ++it ) {
@@ -42,13 +42,13 @@ TQString Parser::cleanArgs( const TQString &func )
res += ",";
TQString arg = *it;
int pos = 0;
- if ( ( pos = arg.find( "&" ) ) != -1 ) {
+ if ( ( pos = arg.tqfind( "&" ) ) != -1 ) {
arg = arg.left( pos + 1 );
- } else if ( ( pos = arg.find( "*" ) ) != -1 ) {
+ } else if ( ( pos = arg.tqfind( "*" ) ) != -1 ) {
arg = arg.left( pos + 1 );
} else {
arg = arg.simplifyWhiteSpace();
- if ( ( pos = arg.find( ':' ) ) != -1 )
+ if ( ( pos = arg.tqfind( ':' ) ) != -1 )
arg = arg.left( pos ).simplifyWhiteSpace() + ":" + arg.mid( pos + 1 ).simplifyWhiteSpace();
TQStringList l = TQStringList::split( ' ', arg );
if ( l.count() == 2 ) {
@@ -62,5 +62,5 @@ TQString Parser::cleanArgs( const TQString &func )
}
res += ")";
- return TQString::fromLatin1( NormalizeObject::normalizeSignalSlot( res.latin1() ) );
+ return TQString::tqfromLatin1( NormalizeObject::normalizeSignalSlot( res.latin1() ) );
}
diff --git a/kommander/editor/parser.h b/kommander/editor/parser.h
index ace96d9e..5fdbdc2b 100644
--- a/kommander/editor/parser.h
+++ b/kommander/editor/parser.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
diff --git a/kommander/editor/pics/images.h b/kommander/editor/pics/images.h
index 92094bdb..5850acd1 100644
--- a/kommander/editor/pics/images.h
+++ b/kommander/editor/pics/images.h
@@ -1,5 +1,5 @@
-#ifndef _QEMBED_1804289383
-#define _QEMBED_1804289383
+#ifndef _TQEMBED_1804289383
+#define _TQEMBED_1804289383
static const unsigned int arrow_xbm_len = 601;
static const unsigned char arrow_xbm_data[] = {
0x23,0x64,0x65,0x66,0x69,0x6e,0x65,0x20,0x61,0x72,0x72,0x6f,0x77,0x5f,
@@ -4717,8 +4717,8 @@ static const unsigned char small_editgrid_png_data[] = {
0x60,0x82
};
-static const unsigned int small_edithlayout_png_len = 706;
-static const unsigned char small_edithlayout_png_data[] = {
+static const unsigned int small_edithtqlayout_png_len = 706;
+static const unsigned char small_edithtqlayout_png_data[] = {
0x89,0x50,0x4e,0x47,0x0d,0x0a,0x1a,0x0a,0x00,0x00,0x00,0x0d,0x49,0x48,
0x44,0x52,0x00,0x00,0x00,0x16,0x00,0x00,0x00,0x16,0x08,0x06,0x00,0x00,
0x00,0xc4,0xb4,0x6c,0x3b,0x00,0x00,0x00,0x04,0x67,0x41,0x4d,0x41,0x00,
@@ -4772,8 +4772,8 @@ static const unsigned char small_edithlayout_png_data[] = {
0x4e,0x44,0xae,0x42,0x60,0x82
};
-static const unsigned int small_edithlayoutsplit_png_len = 809;
-static const unsigned char small_edithlayoutsplit_png_data[] = {
+static const unsigned int small_edithtqlayoutsplit_png_len = 809;
+static const unsigned char small_edithtqlayoutsplit_png_data[] = {
0x89,0x50,0x4e,0x47,0x0d,0x0a,0x1a,0x0a,0x00,0x00,0x00,0x0d,0x49,0x48,
0x44,0x52,0x00,0x00,0x00,0x16,0x00,0x00,0x00,0x16,0x08,0x06,0x00,0x00,
0x00,0xc4,0xb4,0x6c,0x3b,0x00,0x00,0x00,0x04,0x67,0x41,0x4d,0x41,0x00,
@@ -4957,8 +4957,8 @@ static const unsigned char small_editslots_png_data[] = {
0xae,0x42,0x60,0x82
};
-static const unsigned int small_editvlayout_png_len = 289;
-static const unsigned char small_editvlayout_png_data[] = {
+static const unsigned int small_editvtqlayout_png_len = 289;
+static const unsigned char small_editvtqlayout_png_data[] = {
0x89,0x50,0x4e,0x47,0x0d,0x0a,0x1a,0x0a,0x00,0x00,0x00,0x0d,0x49,0x48,
0x44,0x52,0x00,0x00,0x00,0x16,0x00,0x00,0x00,0x16,0x08,0x06,0x00,0x00,
0x00,0xc4,0xb4,0x6c,0x3b,0x00,0x00,0x00,0x04,0x67,0x41,0x4d,0x41,0x00,
@@ -4982,8 +4982,8 @@ static const unsigned char small_editvlayout_png_data[] = {
0x00,0x49,0x45,0x4e,0x44,0xae,0x42,0x60,0x82
};
-static const unsigned int small_editvlayoutsplit_png_len = 355;
-static const unsigned char small_editvlayoutsplit_png_data[] = {
+static const unsigned int small_editvtqlayoutsplit_png_len = 355;
+static const unsigned char small_editvtqlayoutsplit_png_data[] = {
0x89,0x50,0x4e,0x47,0x0d,0x0a,0x1a,0x0a,0x00,0x00,0x00,0x0d,0x49,0x48,
0x44,0x52,0x00,0x00,0x00,0x16,0x00,0x00,0x00,0x16,0x08,0x06,0x00,0x00,
0x00,0xc4,0xb4,0x6c,0x3b,0x00,0x00,0x00,0x04,0x67,0x41,0x4d,0x41,0x00,
@@ -7784,8 +7784,8 @@ static const unsigned char small_disabled_editgrid_png_data[] = {
0x45,0x4e,0x44,0xae,0x42,0x60,0x82
};
-static const unsigned int small_disabled_edithlayout_png_len = 601;
-static const unsigned char small_disabled_edithlayout_png_data[] = {
+static const unsigned int small_disabled_edithtqlayout_png_len = 601;
+static const unsigned char small_disabled_edithtqlayout_png_data[] = {
0x89,0x50,0x4e,0x47,0x0d,0x0a,0x1a,0x0a,0x00,0x00,0x00,0x0d,0x49,0x48,
0x44,0x52,0x00,0x00,0x00,0x16,0x00,0x00,0x00,0x16,0x08,0x06,0x00,0x00,
0x00,0xc4,0xb4,0x6c,0x3b,0x00,0x00,0x00,0x04,0x67,0x41,0x4d,0x41,0x00,
@@ -7831,8 +7831,8 @@ static const unsigned char small_disabled_edithlayout_png_data[] = {
0x35,0x00,0x00,0x00,0x00,0x49,0x45,0x4e,0x44,0xae,0x42,0x60,0x82
};
-static const unsigned int small_disabled_edithlayoutsplit_png_len = 754;
-static const unsigned char small_disabled_edithlayoutsplit_png_data[] = {
+static const unsigned int small_disabled_edithtqlayoutsplit_png_len = 754;
+static const unsigned char small_disabled_edithtqlayoutsplit_png_data[] = {
0x89,0x50,0x4e,0x47,0x0d,0x0a,0x1a,0x0a,0x00,0x00,0x00,0x0d,0x49,0x48,
0x44,0x52,0x00,0x00,0x00,0x16,0x00,0x00,0x00,0x16,0x08,0x06,0x00,0x00,
0x00,0xc4,0xb4,0x6c,0x3b,0x00,0x00,0x00,0x04,0x67,0x41,0x4d,0x41,0x00,
@@ -7958,8 +7958,8 @@ static const unsigned char small_disabled_editpaste_png_data[] = {
0x44,0xae,0x42,0x60,0x82
};
-static const unsigned int small_disabled_editvlayout_png_len = 617;
-static const unsigned char small_disabled_editvlayout_png_data[] = {
+static const unsigned int small_disabled_editvtqlayout_png_len = 617;
+static const unsigned char small_disabled_editvtqlayout_png_data[] = {
0x89,0x50,0x4e,0x47,0x0d,0x0a,0x1a,0x0a,0x00,0x00,0x00,0x0d,0x49,0x48,
0x44,0x52,0x00,0x00,0x00,0x16,0x00,0x00,0x00,0x16,0x08,0x06,0x00,0x00,
0x00,0xc4,0xb4,0x6c,0x3b,0x00,0x00,0x00,0x04,0x67,0x41,0x4d,0x41,0x00,
@@ -8007,8 +8007,8 @@ static const unsigned char small_disabled_editvlayout_png_data[] = {
0x82
};
-static const unsigned int small_disabled_editvlayoutsplit_png_len = 752;
-static const unsigned char small_disabled_editvlayoutsplit_png_data[] = {
+static const unsigned int small_disabled_editvtqlayoutsplit_png_len = 752;
+static const unsigned char small_disabled_editvtqlayoutsplit_png_data[] = {
0x89,0x50,0x4e,0x47,0x0d,0x0a,0x1a,0x0a,0x00,0x00,0x00,0x0d,0x49,0x48,
0x44,0x52,0x00,0x00,0x00,0x16,0x00,0x00,0x00,0x16,0x08,0x06,0x00,0x00,
0x00,0xc4,0xb4,0x6c,0x3b,0x00,0x00,0x00,0x04,0x67,0x41,0x4d,0x41,0x00,
@@ -10857,7 +10857,7 @@ static struct Embed {
{ 1483, small_form_xpm_data, "small/form.xpm" },
{ 3981, small_home_xpm_data, "small/home.xpm" },
{ 5406, small_image_xpm_data, "small/image.xpm" },
- { 3179, small_layout_xpm_data, "small/layout.xpm" },
+ { 3179, small_layout_xpm_data, "small/tqlayout.xpm" },
{ 3621, small_left_xpm_data, "small/left.xpm" },
{ 1131, small_newform_xpm_data, "small/newform.xpm" },
{ 2434, small_print_xpm_data, "small/print.xpm" },
@@ -10877,12 +10877,12 @@ static struct Embed {
{ 485, small_editcopy_png_data, "small/editcopy.png" },
{ 649, small_editcut_png_data, "small/editcut.png" },
{ 520, small_editgrid_png_data, "small/editgrid.png" },
- { 706, small_edithlayout_png_data, "small/edithlayout.png" },
- { 809, small_edithlayoutsplit_png_data, "small/edithlayoutsplit.png" },
+ { 706, small_edithtqlayout_png_data, "small/edithtqlayout.png" },
+ { 809, small_edithtqlayoutsplit_png_data, "small/edithtqlayoutsplit.png" },
{ 902, small_editpaste_png_data, "small/editpaste.png" },
{ 690, small_editslots_png_data, "small/editslots.png" },
- { 289, small_editvlayout_png_data, "small/editvlayout.png" },
- { 355, small_editvlayoutsplit_png_data, "small/editvlayoutsplit.png" },
+ { 289, small_editvtqlayout_png_data, "small/editvtqlayout.png" },
+ { 355, small_editvtqlayoutsplit_png_data, "small/editvtqlayoutsplit.png" },
{ 1408, small_exec_png_data, "small/exec.png" },
{ 313, small_filenew_png_data, "small/filenew.png" },
{ 681, small_fileopen_png_data, "small/fileopen.png" },
@@ -10925,7 +10925,7 @@ static struct Embed {
{ 572, small_undo_png_data, "small/undo.png" },
{ 733, small_disabled_editcut_xpm_data, "small/disabled/editcut.xpm" },
{ 899, small_disabled_editslots_xpm_data, "small/disabled/editslots.xpm" },
- { 931, small_disabled_layout_xpm_data, "small/disabled/layout.xpm" },
+ { 931, small_disabled_layout_xpm_data, "small/disabled/tqlayout.xpm" },
{ 733, small_disabled_left_xpm_data, "small/disabled/left.xpm" },
{ 733, small_disabled_right_xpm_data, "small/disabled/right.xpm" },
{ 659, small_disabled_adjustsize_png_data, "small/disabled/adjustsize.png" },
@@ -10933,11 +10933,11 @@ static struct Embed {
{ 1126, small_disabled_editbreaklayout_png_data, "small/disabled/editbreaklayout.png" },
{ 931, small_disabled_editcopy_png_data, "small/disabled/editcopy.png" },
{ 735, small_disabled_editgrid_png_data, "small/disabled/editgrid.png" },
- { 601, small_disabled_edithlayout_png_data, "small/disabled/edithlayout.png" },
- { 754, small_disabled_edithlayoutsplit_png_data, "small/disabled/edithlayoutsplit.png" },
+ { 601, small_disabled_edithtqlayout_png_data, "small/disabled/edithtqlayout.png" },
+ { 754, small_disabled_edithtqlayoutsplit_png_data, "small/disabled/edithtqlayoutsplit.png" },
{ 901, small_disabled_editpaste_png_data, "small/disabled/editpaste.png" },
- { 617, small_disabled_editvlayout_png_data, "small/disabled/editvlayout.png" },
- { 752, small_disabled_editvlayoutsplit_png_data, "small/disabled/editvlayoutsplit.png" },
+ { 617, small_disabled_editvtqlayout_png_data, "small/disabled/editvtqlayout.png" },
+ { 752, small_disabled_editvtqlayoutsplit_png_data, "small/disabled/editvtqlayoutsplit.png" },
{ 587, small_disabled_filesave_png_data, "small/disabled/filesave.png" },
{ 531, small_disabled_redo_png_data, "small/disabled/redo.png" },
{ 1013, small_disabled_searchfind_png_data, "small/disabled/searchfind.png" },
@@ -10957,7 +10957,7 @@ static struct Embed {
static const TQByteArray& qembed_findData( const char* name )
{
static TQDict<TQByteArray> dict;
- TQByteArray* ba = dict.find( name );
+ TQByteArray* ba = dict.tqfind( name );
if ( !ba ) {
for ( int i = 0; embed_vec[i].data; i++ ) {
if ( strcmp(embed_vec[i].name, name) == 0 ) {
diff --git a/kommander/editor/pixmapchooser.cpp b/kommander/editor/pixmapchooser.cpp
index 92512c68..f0e8ab3a 100644
--- a/kommander/editor/pixmapchooser.cpp
+++ b/kommander/editor/pixmapchooser.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000-2001 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -50,8 +50,8 @@
#if defined(DESIGNER)
#include "pics/images.h"
-#ifdef Q_WS_MACX
-//logo is 40x40 on the mac, if it changes - please notify the Qt/Mac team
+#ifdef TQ_WS_MACX
+//logo is 40x40 on the mac, if it changes - please notify the TQt/Mac team
static const char * const logo_xpm[] = {
"40 40 543 2",
" c None",
@@ -876,8 +876,8 @@ static ImageIconProvider *imageIconProvider = 0;
static PixmapChooser *pixmapChooser = 0;
#endif
-PixmapView::PixmapView( TQWidget *parent )
- : TQScrollView( parent )
+PixmapView::PixmapView( TQWidget *tqparent )
+ : TQScrollView( tqparent )
{
viewport()->setBackgroundMode( PaletteBase );
}
@@ -886,12 +886,12 @@ void PixmapView::setPixmap( const TQPixmap &pix )
{
pixmap = pix;
resizeContents( pixmap.size().width(), pixmap.size().height() );
- viewport()->repaint( false );
+ viewport()->tqrepaint( false );
}
void PixmapView::drawContents( TQPainter *p, int cx, int cy, int cw, int ch )
{
- p->fillRect( cx, cy, cw, ch, colorGroup().brush( TQColorGroup::Base ) );
+ p->fillRect( cx, cy, cw, ch, tqcolorGroup().brush( TQColorGroup::Base ) );
p->drawPixmap( 0, 0, pixmap );
}
@@ -907,36 +907,36 @@ void PixmapView::previewUrl( const TQUrl &u )
}
}
-TQStringList qChoosePixmaps( TQWidget *parent )
+TQStringList qChoosePixmaps( TQWidget *tqparent )
{
if ( !imageIconProvider && !TQFileDialog::iconProvider() )
TQFileDialog::setIconProvider( ( imageIconProvider = new ImageIconProvider ) );
TQString filter;
- TQString all = qApp->translate( "qChoosePixmap", "All Pixmaps (" );
+ TQString all = tqApp->translate( "qChoosePixmap", "All Pixmaps (" );
for ( uint i = 0; i < TQImageIO::outputFormats().count(); i++ ) {
- filter += qApp->translate( "qChoosePixmap", "%1-Pixmaps (%2)\n" ).
+ filter += tqApp->translate( "qChoosePixmap", "%1-Pixmaps (%2)\n" ).
arg( TQImageIO::outputFormats().at( i ) ).
arg( "*." + TQString( TQImageIO::outputFormats().at( i ) ).lower() );
all += "*." + TQString( TQImageIO::outputFormats().at( i ) ).lower() + ";";
}
- filter.prepend( all + qApp->translate( "qChoosePixmap", ")\n" ) );
- filter += qApp->translate( "qChoosePixmap", "All Files (*)" );
+ filter.prepend( all + tqApp->translate( "qChoosePixmap", ")\n" ) );
+ filter += tqApp->translate( "qChoosePixmap", "All Files (*)" );
- TQFileDialog fd( TQString::null, filter, parent, 0, true );
+ TQFileDialog fd( TQString(), filter, tqparent, 0, true );
fd.setMode( TQFileDialog::ExistingFiles );
fd.setContentsPreviewEnabled( true );
PixmapView *pw = new PixmapView( &fd );
fd.setContentsPreview( pw, pw );
fd.setViewMode( TQFileDialog::List );
fd.setPreviewMode( TQFileDialog::Contents );
- fd.setCaption( qApp->translate( "qChoosePixmap", "Choose Images" ) );
+ fd.setCaption( tqApp->translate( "qChoosePixmap", "Choose Images" ) );
if ( fd.exec() == TQDialog::Accepted )
return fd.selectedFiles();
return TQStringList();
}
-TQPixmap qChoosePixmap( TQWidget *parent, FormWindow *fw, const TQPixmap &old, TQString *fn )
+TQPixmap qChoosePixmap( TQWidget *tqparent, FormWindow *fw, const TQPixmap &old, TQString *fn )
{
#if defined(DESIGNER)
if ( !fw || fw->savePixmapInline() ) {
@@ -955,7 +955,7 @@ TQPixmap qChoosePixmap( TQWidget *parent, FormWindow *fw, const TQPixmap &old, T
filter.prepend( all + ")\n" );
filter += i18n( "All Files (*)" );
- TQFileDialog fd( TQString::null, filter, parent, 0, true );
+ TQFileDialog fd( TQString(), filter, tqparent, 0, true );
fd.setContentsPreviewEnabled( true );
PixmapView *pw = new PixmapView( &fd );
fd.setContentsPreview( pw, pw );
@@ -966,13 +966,13 @@ TQPixmap qChoosePixmap( TQWidget *parent, FormWindow *fw, const TQPixmap &old, T
TQPixmap pix( fd.selectedFile() );
if ( fn )
*fn = fd.selectedFile();
- MetaDataBase::setPixmapArgument( fw, pix.serialNumber(), fd.selectedFile() );
+ MetaDataBase::setPixmapArgument( TQT_TQOBJECT(fw), pix.serialNumber(), fd.selectedFile() );
return pix;
}
}
#ifndef KOMMANDER
else if ( fw && fw->savePixmapInProject() ) {
- PixmapCollectionEditor dia( parent, 0, true );
+ PixmapCollectionEditor dia( tqparent, 0, true );
dia.setProject( fw->project() );
dia.setChooserMode( true );
dia.setCurrentItem( MetaDataBase::pixmapKey( fw, old.serialNumber() ) );
@@ -984,27 +984,27 @@ TQPixmap qChoosePixmap( TQWidget *parent, FormWindow *fw, const TQPixmap &old, T
}
#endif
else {
- PixmapFunction dia( parent, 0, true );
+ PixmapFunction dia( tqparent, 0, true );
TQObject::connect( dia.helpButton, TQT_SIGNAL( clicked() ), MainWindow::self, TQT_SLOT( showDialogHelp() ) );
dia.labelFunction->setText( fw->pixmapLoaderFunction() + "(" );
- dia.editArguments->setText( MetaDataBase::pixmapArgument( fw, old.serialNumber() ) );
+ dia.editArguments->setText( MetaDataBase::pixmapArgument( TQT_TQOBJECT(fw), old.serialNumber() ) );
dia.editArguments->setFocus();
if ( dia.exec() == TQDialog::Accepted ) {
TQPixmap pix( PixmapChooser::loadPixmap( "image.xpm" ) );
- MetaDataBase::setPixmapArgument( fw, pix.serialNumber(), dia.editArguments->text() );
+ MetaDataBase::setPixmapArgument( TQT_TQOBJECT(fw), pix.serialNumber(), dia.editArguments->text() );
return pix;
}
}
#else
- Q_UNUSED( parent );
+ Q_UNUSED( tqparent );
Q_UNUSED( fw );
Q_UNUSED( old );
#endif
return TQPixmap();
}
-ImageIconProvider::ImageIconProvider( TQWidget *parent, const char *name )
- : TQFileIconProvider( parent, name ), imagepm( PixmapChooser::loadPixmap( "image.xpm", PixmapChooser::Mini ) )
+ImageIconProvider::ImageIconProvider( TQWidget *tqparent, const char *name )
+ : TQFileIconProvider( TQT_TQOBJECT(tqparent), name ), imagepm( PixmapChooser::loadPixmap( "image.xpm", PixmapChooser::Mini ) )
{
fmts = TQImage::inputFormats();
}
@@ -1016,7 +1016,7 @@ ImageIconProvider::~ImageIconProvider()
const TQPixmap * ImageIconProvider::pixmap( const TQFileInfo &fi )
{
TQString ext = fi.extension().upper();
- if ( fmts.contains( ext ) ) {
+ if ( fmts.tqcontains( ext ) ) {
return &imagepm;
} else {
return TQFileIconProvider::pixmap( fi );
diff --git a/kommander/editor/pixmapchooser.h b/kommander/editor/pixmapchooser.h
index fe54942e..48c947a7 100644
--- a/kommander/editor/pixmapchooser.h
+++ b/kommander/editor/pixmapchooser.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -29,12 +29,13 @@
class FormWindow;
class PixmapView : public TQScrollView,
- public QFilePreview
+ public TQFilePreview
{
Q_OBJECT
+ TQ_OBJECT
public:
- PixmapView( TQWidget *parent );
+ PixmapView( TQWidget *tqparent );
void setPixmap( const TQPixmap &pix );
void drawContents( TQPainter *p, int, int, int, int );
void previewUrl( const TQUrl &u );
@@ -44,12 +45,13 @@ private:
};
-class ImageIconProvider : public QFileIconProvider
+class ImageIconProvider : public TQFileIconProvider
{
Q_OBJECT
+ TQ_OBJECT
public:
- ImageIconProvider( TQWidget *parent = 0, const char *name = 0 );
+ ImageIconProvider( TQWidget *tqparent = 0, const char *name = 0 );
~ImageIconProvider();
const TQPixmap *pixmap( const TQFileInfo &fi );
@@ -60,8 +62,8 @@ private:
};
-TQPixmap qChoosePixmap( TQWidget *parent, FormWindow *fw = 0, const TQPixmap &old = TQPixmap(), TQString *fn = 0 );
-TQStringList qChoosePixmaps( TQWidget *parent );
+TQPixmap qChoosePixmap( TQWidget *tqparent, FormWindow *fw = 0, const TQPixmap &old = TQPixmap(), TQString *fn = 0 );
+TQStringList qChoosePixmaps( TQWidget *tqparent );
class PixmapChooser
diff --git a/kommander/editor/pixmapfunction.ui b/kommander/editor/pixmapfunction.ui
index a75869dc..fb2043d2 100644
--- a/kommander/editor/pixmapfunction.ui
+++ b/kommander/editor/pixmapfunction.ui
@@ -19,13 +19,13 @@
**
*********************************************************************</comment>
<widget>
- <class>QDialog</class>
+ <class>TQDialog</class>
<property stdset="1">
<name>name</name>
<cstring>PixmapFunction</cstring>
</property>
<property stdset="1">
- <name>geometry</name>
+ <name>tqgeometry</name>
<rect>
<x>0</x>
<y>0</y>
@@ -51,7 +51,7 @@
<number>6</number>
</property>
<widget>
- <class>QLabel</class>
+ <class>TQLabel</class>
<property stdset="1">
<name>name</name>
<cstring>TextLabel3</cstring>
@@ -66,7 +66,7 @@
</property>
</widget>
<widget>
- <class>QFrame</class>
+ <class>TQFrame</class>
<property stdset="1">
<name>name</name>
<cstring>Frame9</cstring>
@@ -84,10 +84,10 @@
<number>2</number>
</property>
<property>
- <name>layoutMargin</name>
+ <name>tqlayoutMargin</name>
</property>
<property>
- <name>layoutSpacing</name>
+ <name>tqlayoutSpacing</name>
</property>
<hbox>
<property stdset="1">
@@ -99,14 +99,14 @@
<number>0</number>
</property>
<widget>
- <class>QLabel</class>
+ <class>TQLabel</class>
<property stdset="1">
<name>name</name>
<cstring>labelFunction</cstring>
</property>
<property stdset="1">
<name>text</name>
- <string>QPixmap(</string>
+ <string>TQPixmap(</string>
</property>
<property stdset="1">
<name>palette</name>
@@ -331,7 +331,7 @@
</property>
</widget>
<widget>
- <class>QLineEdit</class>
+ <class>TQLineEdit</class>
<property stdset="1">
<name>name</name>
<cstring>editArguments</cstring>
@@ -563,7 +563,7 @@
</property>
</widget>
<widget>
- <class>QLabel</class>
+ <class>TQLabel</class>
<property stdset="1">
<name>name</name>
<cstring>TextLabel5</cstring>
@@ -810,7 +810,7 @@
<enum>Expanding</enum>
</property>
<property>
- <name>sizeHint</name>
+ <name>tqsizeHint</name>
<size>
<width>20</width>
<height>20</height>
@@ -818,7 +818,7 @@
</property>
</spacer>
<widget>
- <class>QLayoutWidget</class>
+ <class>TQLayoutWidget</class>
<property stdset="1">
<name>name</name>
<cstring>Layout3</cstring>
@@ -833,7 +833,7 @@
<number>6</number>
</property>
<widget>
- <class>QPushButton</class>
+ <class>TQPushButton</class>
<property stdset="1">
<name>name</name>
<cstring>helpButton</cstring>
@@ -861,7 +861,7 @@
<enum>Expanding</enum>
</property>
<property>
- <name>sizeHint</name>
+ <name>tqsizeHint</name>
<size>
<width>20</width>
<height>20</height>
@@ -869,7 +869,7 @@
</property>
</spacer>
<widget>
- <class>QPushButton</class>
+ <class>TQPushButton</class>
<property stdset="1">
<name>name</name>
<cstring>buttonOk</cstring>
@@ -888,7 +888,7 @@
</property>
</widget>
<widget>
- <class>QPushButton</class>
+ <class>TQPushButton</class>
<property stdset="1">
<name>name</name>
<cstring>buttonCancel</cstring>
diff --git a/kommander/editor/preferences.ui b/kommander/editor/preferences.ui
index 6bd5dac3..63ac1bb3 100644
--- a/kommander/editor/preferences.ui
+++ b/kommander/editor/preferences.ui
@@ -19,7 +19,7 @@
** not clear to you.
**
*********************************************************************</comment>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>Preferences</cstring>
</property>
@@ -50,11 +50,11 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QTabWidget">
+ <widget class="TQTabWidget">
<property name="name">
<cstring>tabWidget</cstring>
</property>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>pageGeneral</cstring>
</property>
@@ -71,7 +71,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QButtonGroup" row="0" column="0" rowspan="2" colspan="1">
+ <widget class="TQButtonGroup" row="0" column="0" rowspan="2" colspan="1">
<property name="name">
<cstring>ButtonGroup1</cstring>
</property>
@@ -114,7 +114,7 @@
<string>Select a color in the color dialog.</string>
</property>
</widget>
- <widget class="QRadioButton" row="0" column="0">
+ <widget class="TQRadioButton" row="0" column="0">
<property name="name">
<cstring>radioColor</cstring>
</property>
@@ -131,7 +131,7 @@
<string>Use a background color.</string>
</property>
</widget>
- <widget class="QRadioButton" row="1" column="0">
+ <widget class="TQRadioButton" row="1" column="0">
<property name="name">
<cstring>radioPixmap</cstring>
</property>
@@ -173,7 +173,7 @@
</widget>
</grid>
</widget>
- <widget class="QCheckBox" row="0" column="1">
+ <widget class="TQCheckBox" row="0" column="1">
<property name="name">
<cstring>checkBoxShowGrid</cstring>
</property>
@@ -190,7 +190,7 @@
<string>&lt;b&gt;Customize the grid appearance for all forms.&lt;/b&gt;&lt;p&gt;When &lt;b&gt;Show Grid&lt;/b&gt; is checked, all forms show a grid.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QGroupBox" row="1" column="1">
+ <widget class="TQGroupBox" row="1" column="1">
<property name="name">
<cstring>GroupBox1</cstring>
</property>
@@ -210,7 +210,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>checkBoxGrid</cstring>
</property>
@@ -227,7 +227,7 @@
<string>&lt;b&gt;Customize the grid-settings for all forms.&lt;/b&gt;&lt;p&gt;When &lt;b&gt;Snap to Grid&lt;/b&gt; is checked, the widgets snap to the grid using the the X/Y resolution.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout4</cstring>
</property>
@@ -241,7 +241,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QSpinBox" row="0" column="1">
+ <widget class="TQSpinBox" row="0" column="1">
<property name="name">
<cstring>spinGridX</cstring>
</property>
@@ -261,7 +261,7 @@
<string>&lt;b&gt;Customize the grid-settings for all forms.&lt;/b&gt;&lt;p&gt;When &lt;b&gt;Show Grid&lt;/b&gt; is checked, a grid is shown on all forms using the X/Y resolution.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QSpinBox" row="1" column="1">
+ <widget class="TQSpinBox" row="1" column="1">
<property name="name">
<cstring>spinGridY</cstring>
</property>
@@ -281,7 +281,7 @@
<string>&lt;b&gt;Customize the grid-settings for all forms.&lt;/b&gt;&lt;p&gt;When &lt;b&gt;Show Grid&lt;/b&gt; is checked, a grid is shown on all forms using the X/Y resolution.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>Label1</cstring>
</property>
@@ -292,7 +292,7 @@
<cstring>spinGridX</cstring>
</property>
</widget>
- <widget class="QLabel" row="1" column="0">
+ <widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>Label1_2</cstring>
</property>
@@ -317,7 +317,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
@@ -327,7 +327,7 @@
<string>A splash screen is displayed when starting Qt Designer if this option is checked.</string>
</property>
</spacer>
- <widget class="QGroupBox" row="2" column="0">
+ <widget class="TQGroupBox" row="2" column="0">
<property name="name">
<cstring>GroupBox5</cstring>
</property>
@@ -344,7 +344,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>checkBoxWorkspace</cstring>
</property>
@@ -361,7 +361,7 @@
<string>The current workspace settings will be restored the next time you start Qt Designer if this option is checked.</string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>checkBoxSplash</cstring>
</property>
@@ -378,7 +378,7 @@
<string>A splash screen is displayed when starting Qt Designer if this option is checked.</string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>checkAutoEdit</cstring>
</property>
@@ -389,7 +389,7 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>Label3</cstring>
</property>
@@ -400,7 +400,7 @@
<cstring>editDocPath</cstring>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout6</cstring>
</property>
@@ -414,7 +414,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLineEdit">
+ <widget class="TQLineEdit">
<property name="name">
<cstring>editDocPath</cstring>
</property>
@@ -422,7 +422,7 @@
<string>&lt;b&gt;Enter the path to the documentation.&lt;/b&gt;&lt;p&gt;You may provide an $environment variable as the first part of the pathname.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QToolButton">
+ <widget class="TQToolButton">
<property name="name">
<cstring>buttonDocPath</cstring>
</property>
@@ -443,7 +443,7 @@
</widget>
</vbox>
</widget>
- <widget class="QGroupBox" row="2" column="1">
+ <widget class="TQGroupBox" row="2" column="1">
<property name="name">
<cstring>GroupBox3</cstring>
</property>
@@ -460,7 +460,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>checkBoxBigIcons</cstring>
</property>
@@ -474,7 +474,7 @@
<string>Big icons will be used in the toolbars if this is checked.</string>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>checkBoxTextLabels</cstring>
</property>
@@ -493,7 +493,7 @@
</grid>
</widget>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout6</cstring>
</property>
@@ -507,7 +507,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>helpButton</cstring>
</property>
@@ -528,14 +528,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonOk</cstring>
</property>
@@ -552,7 +552,7 @@
<string>Close the dialog and apply all the changes.</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonCancel</cstring>
</property>
diff --git a/kommander/editor/previewframe.cpp b/kommander/editor/previewframe.cpp
index 3be0c2ae..53f35670 100644
--- a/kommander/editor/previewframe.cpp
+++ b/kommander/editor/previewframe.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -23,15 +23,15 @@
#include "previewframe.h"
-PreviewFrame::PreviewFrame( TQWidget *parent, const char *name )
- : TQVBox( parent, name )
+PreviewFrame::PreviewFrame( TQWidget *tqparent, const char *name )
+ : TQVBox( tqparent, name )
{
setMinimumSize(200, 200);
setFrameStyle(TQFrame::StyledPanel | TQFrame::Sunken);
setLineWidth(1);
PreviewWorkspace * w = new PreviewWorkspace( this );
- w->setEraseColor(colorGroup().dark());
+ w->setEraseColor(tqcolorGroup().dark());
previewWidget = new PreviewWidget( w );
previewWidget->move( 10, 10 );
}
diff --git a/kommander/editor/previewframe.h b/kommander/editor/previewframe.h
index 21ecd9a7..6447f005 100644
--- a/kommander/editor/previewframe.h
+++ b/kommander/editor/previewframe.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -26,24 +26,26 @@
#include "previewwidgetimpl.h"
-class PreviewWorkspace : public QWorkspace
+class PreviewWorkspace : public TQWorkspace
{
Q_OBJECT
+ TQ_OBJECT
public:
- PreviewWorkspace( TQWidget* parent = 0, const char* name = 0 )
- : TQWorkspace( parent, name ) {}
+ PreviewWorkspace( TQWidget* tqparent = 0, const char* name = 0 )
+ : TQWorkspace( tqparent, name ) {}
~PreviewWorkspace() {}
protected:
void paintEvent( TQPaintEvent* );
};
-class PreviewFrame : public QVBox
+class PreviewFrame : public TQVBox
{
Q_OBJECT
+ TQ_OBJECT
public:
- PreviewFrame( TQWidget *parent = 0, const char *name = 0 );
+ PreviewFrame( TQWidget *tqparent = 0, const char *name = 0 );
void setPreviewPalette(TQPalette);
private:
diff --git a/kommander/editor/previewwidget.ui b/kommander/editor/previewwidget.ui
index 317313cf..6c93d75d 100644
--- a/kommander/editor/previewwidget.ui
+++ b/kommander/editor/previewwidget.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.0" stdsetdef="1">
<class>PreviewWidgetBase</class>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>PreviewWidgetBase</cstring>
</property>
@@ -31,7 +31,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout6</cstring>
</property>
@@ -45,7 +45,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout17</cstring>
</property>
@@ -59,7 +59,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QButtonGroup">
+ <widget class="TQButtonGroup">
<property name="name">
<cstring>ButtonGroup1</cstring>
</property>
@@ -76,7 +76,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QRadioButton">
+ <widget class="TQRadioButton">
<property name="name">
<cstring>RadioButton1</cstring>
</property>
@@ -87,7 +87,7 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QRadioButton">
+ <widget class="TQRadioButton">
<property name="name">
<cstring>RadioButton2</cstring>
</property>
@@ -95,7 +95,7 @@
<string>RadioButton2</string>
</property>
</widget>
- <widget class="QRadioButton">
+ <widget class="TQRadioButton">
<property name="name">
<cstring>RadioButton3</cstring>
</property>
@@ -105,7 +105,7 @@
</widget>
</vbox>
</widget>
- <widget class="QButtonGroup">
+ <widget class="TQButtonGroup">
<property name="name">
<cstring>ButtonGroup2</cstring>
</property>
@@ -122,7 +122,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>CheckBox1</cstring>
</property>
@@ -133,7 +133,7 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QCheckBox">
+ <widget class="TQCheckBox">
<property name="name">
<cstring>CheckBox2</cstring>
</property>
@@ -143,7 +143,7 @@
</widget>
</vbox>
</widget>
- <widget class="QProgressBar">
+ <widget class="TQProgressBar">
<property name="name">
<cstring>ProgressBar1</cstring>
</property>
@@ -153,7 +153,7 @@
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout5</cstring>
</property>
@@ -167,7 +167,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLineEdit">
+ <widget class="TQLineEdit">
<property name="name">
<cstring>LineEdit1</cstring>
</property>
@@ -175,7 +175,7 @@
<string>LineEdit</string>
</property>
</widget>
- <widget class="QComboBox">
+ <widget class="TQComboBox">
<item>
<property name="text">
<string>ComboBox</string>
@@ -185,7 +185,7 @@
<cstring>ComboBox1</cstring>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout13</cstring>
</property>
@@ -199,12 +199,12 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QSpinBox">
+ <widget class="TQSpinBox">
<property name="name">
<cstring>SpinBox1</cstring>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>PushButton1</cstring>
</property>
@@ -214,7 +214,7 @@
</widget>
</hbox>
</widget>
- <widget class="QScrollBar">
+ <widget class="TQScrollBar">
<property name="name">
<cstring>ScrollBar1</cstring>
</property>
@@ -222,7 +222,7 @@
<enum>Horizontal</enum>
</property>
</widget>
- <widget class="QSlider">
+ <widget class="TQSlider">
<property name="name">
<cstring>Slider1</cstring>
</property>
@@ -230,11 +230,11 @@
<enum>Horizontal</enum>
</property>
</widget>
- <widget class="QTextView">
+ <widget class="TQTextView">
<property name="name">
<cstring>textView</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>32767</width>
<height>50</height>
@@ -263,7 +263,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
diff --git a/kommander/editor/previewwidgetimpl.cpp b/kommander/editor/previewwidgetimpl.cpp
index 6e9672be..1c6ab9cd 100644
--- a/kommander/editor/previewwidgetimpl.cpp
+++ b/kommander/editor/previewwidgetimpl.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -21,8 +21,8 @@
#include "tqobjectlist.h"
#include "previewwidgetimpl.h"
-PreviewWidget::PreviewWidget( TQWidget *parent, const char *name )
- : PreviewWidgetBase( parent, name )
+PreviewWidget::PreviewWidget( TQWidget *tqparent, const char *name )
+ : PreviewWidgetBase( tqparent, name )
{
// install event filter on child widgets
TQObjectList *l = queryList(TQWIDGET_OBJECT_NAME_STRING);
@@ -31,7 +31,7 @@ PreviewWidget::PreviewWidget( TQWidget *parent, const char *name )
while ((obj = it.current()) != 0) {
++it;
obj->installEventFilter(this);
- ((TQWidget*)obj)->setFocusPolicy(NoFocus);
+ ((TQWidget*)obj)->setFocusPolicy(TQ_NoFocus);
}
}
diff --git a/kommander/editor/previewwidgetimpl.h b/kommander/editor/previewwidgetimpl.h
index 37080916..a2b0ef7a 100644
--- a/kommander/editor/previewwidgetimpl.h
+++ b/kommander/editor/previewwidgetimpl.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -26,9 +26,10 @@
class PreviewWidget : public PreviewWidgetBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- PreviewWidget( TQWidget *parent = 0, const char *name = 0 );
+ PreviewWidget( TQWidget *tqparent = 0, const char *name = 0 );
void closeEvent(TQCloseEvent *);
bool eventFilter(TQObject *, TQEvent *);
diff --git a/kommander/editor/propertyeditor.cpp b/kommander/editor/propertyeditor.cpp
index aeeaecb1..b0c71147 100644
--- a/kommander/editor/propertyeditor.cpp
+++ b/kommander/editor/propertyeditor.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -105,11 +105,11 @@ static TQStringList getFontList()
fontDataBase = new TQFontDatabase;
qAddPostRoutine( cleanupFontDatabase );
}
- return fontDataBase->families();
+ return fontDataBase->tqfamilies();
}
-class PropertyWhatsThis : public QWhatsThis
+class PropertyWhatsThis : public TQWhatsThis
{
public:
PropertyWhatsThis( PropertyList *l );
@@ -155,7 +155,7 @@ bool PropertyWhatsThis::clicked( const TQString& href )
*/
/*! If this item should be a child of another property item, specify
- \a prop as the parent item.
+ \a prop as the tqparent item.
*/
PropertyItem::PropertyItem( PropertyList *l, PropertyItem *after, PropertyItem *prop, const TQString &propName )
@@ -172,7 +172,7 @@ PropertyItem::PropertyItem( PropertyList *l, PropertyItem *after, PropertyItem *
PropertyItem::~PropertyItem()
{
if ( resetButton )
- delete resetButton->parentWidget();
+ delete resetButton->tqparentWidget();
resetButton = 0;
}
@@ -222,8 +222,8 @@ void PropertyItem::paintCell( TQPainter *p, const TQColorGroup &cg, int column,
{
TQColorGroup g( cg );
g.setColor( TQColorGroup::Base, backgroundColor() );
- g.setColor( TQColorGroup::Foreground, Qt::black );
- g.setColor( TQColorGroup::Text, Qt::black );
+ g.setColor( TQColorGroup::Foreground, TQt::black );
+ g.setColor( TQColorGroup::Text, TQt::black );
int indent = 0;
if ( column == 0 ) {
indent = 20 + ( property ? 20 : 0 );
@@ -282,7 +282,7 @@ void PropertyItem::paintBranches( TQPainter * p, const TQColorGroup & cg,
void PropertyItem::paintFocus( TQPainter *p, const TQColorGroup &cg, const TQRect &r )
{
p->save();
- TQApplication::style().drawPrimitive(TQStyle::PE_Panel, p, r, cg,
+ TQApplication::tqstyle().tqdrawPrimitive(TQStyle::PE_Panel, p, r, cg,
TQStyle::Style_Sunken, TQStyleOption(1,1) );
p->restore();
}
@@ -296,7 +296,7 @@ bool PropertyItem::hasSubItems() const
return false;
}
-/*! Returns the parent property item here if this is a child or 0
+/*! Returns the tqparent property item here if this is a child or 0
otherwise.
*/
@@ -317,17 +317,17 @@ void PropertyItem::setOpen( bool b )
open = b;
if ( !open ) {
- children.setAutoDelete( true );
- children.clear();
- children.setAutoDelete( false );
- qApp->processEvents();
+ tqchildren.setAutoDelete( true );
+ tqchildren.clear();
+ tqchildren.setAutoDelete( false );
+ tqApp->processEvents();
listview->updateEditorSize();
return;
}
createChildren();
initChildren();
- qApp->processEvents();
+ tqApp->processEvents();
listview->updateEditorSize();
}
@@ -337,7 +337,7 @@ void PropertyItem::setOpen( bool b )
void PropertyItem::showEditor()
{
createResetButton();
- resetButton->parentWidget()->show();
+ resetButton->tqparentWidget()->show();
}
/*! Subclasses have to hide the editor of the item here
@@ -346,7 +346,7 @@ void PropertyItem::showEditor()
void PropertyItem::hideEditor()
{
createResetButton();
- resetButton->parentWidget()->hide();
+ resetButton->tqparentWidget()->hide();
}
/*! This is called to init the value of the item. Reimplement in
@@ -375,7 +375,7 @@ void PropertyItem::setChanged( bool b, bool updateDb )
if ( changed == b )
return;
changed = b;
- repaint();
+ tqrepaint();
if ( updateDb )
MetaDataBase::setPropertyChanged( listview->propertyEditor()->widget(), name(), changed );
updateResetButtonState();
@@ -389,7 +389,7 @@ TQString PropertyItem::name() const
void PropertyItem::createResetButton()
{
if ( resetButton ) {
- resetButton->parentWidget()->lower();
+ resetButton->tqparentWidget()->lower();
return;
}
TQHBox *hbox = new TQHBox( listview->viewport() );
@@ -397,8 +397,8 @@ void PropertyItem::createResetButton()
hbox->setLineWidth( 1 );
resetButton = new TQPushButton( hbox );
resetButton->setPixmap( PixmapChooser::loadPixmap( "resetproperty.xpm", PixmapChooser::Mini ) );
- resetButton->setFixedWidth( resetButton->sizeHint().width() );
- hbox->layout()->setAlignment( Qt::AlignRight );
+ resetButton->setFixedWidth( resetButton->tqsizeHint().width() );
+ hbox->tqlayout()->tqsetAlignment( TQt::AlignRight );
listview->addChild( hbox );
hbox->hide();
TQObject::connect( resetButton, TQT_SIGNAL( clicked() ),
@@ -425,13 +425,13 @@ void PropertyItem::updateResetButtonState()
void PropertyItem::placeEditor( TQWidget *w )
{
createResetButton();
- TQRect r = listview->itemRect( this );
+ TQRect r = listview->tqitemRect( this );
if ( !r.size().isValid() ) {
listview->ensureItemVisible( this );
-#if defined(Q_WS_WIN)
- listview->repaintContents( false );
+#if defined(TQ_WS_WIN)
+ listview->tqrepaintContents( false );
#endif
- r = listview->itemRect( this );
+ r = listview->tqitemRect( this );
}
r.setX( listview->header()->sectionPos( 1 ) );
r.setWidth( listview->header()->sectionSize( 1 ) - 1 );
@@ -439,8 +439,8 @@ void PropertyItem::placeEditor( TQWidget *w )
r = TQRect( listview->viewportToContents( r.topLeft() ), r.size() );
w->resize( r.size() );
listview->moveChild( w, r.x(), r.y() );
- resetButton->parentWidget()->resize( resetButton->sizeHint().width() + 10, r.height() );
- listview->moveChild( resetButton->parentWidget(), r.x() + r.width() - 8, r.y() );
+ resetButton->tqparentWidget()->resize( resetButton->tqsizeHint().width() + 10, r.height() );
+ listview->moveChild( resetButton->tqparentWidget(), r.x() + r.width() - 8, r.y() );
resetButton->setFixedHeight( r.height() - 3 );
}
@@ -475,18 +475,18 @@ void PropertyItem::childValueChanged( PropertyItem * )
void PropertyItem::addChild( PropertyItem *i )
{
- children.append( i );
+ tqchildren.append( i );
}
int PropertyItem::childCount() const
{
- return children.count();
+ return tqchildren.count();
}
PropertyItem *PropertyItem::child( int i ) const
{
// ARRRRRRRRG
- return ( (PropertyItem*)this )->children.at( i );
+ return ( (PropertyItem*)this )->tqchildren.at( i );
}
/*! If the contents of the item is not displayable with a text, but
@@ -509,7 +509,7 @@ void PropertyItem::drawCustomContents( TQPainter *, const TQRect & )
TQString PropertyItem::currentItem() const
{
- return TQString::null;
+ return TQString();
}
int PropertyItem::currentIntItem() const
@@ -532,15 +532,15 @@ int PropertyItem::currentIntItemFromObject() const
TQString PropertyItem::currentItemFromObject() const
{
- return TQString::null;
+ return TQString();
}
void PropertyItem::setFocus( TQWidget *w )
{
- if ( !qApp->focusWidget() ||
+ if ( !tqApp->tqfocusWidget() ||
listview->propertyEditor()->formWindow() &&
- ( !MainWindow::self->isAFormWindowChild( qApp->focusWidget() ) &&
- !qApp->focusWidget()->inherits( "Editor" ) ) )
+ ( !MainWindow::self->isAFormWindowChild( TQT_TQOBJECT(tqApp->tqfocusWidget()) ) &&
+ !tqApp->tqfocusWidget()->inherits( "Editor" ) ) )
w->setFocus();
}
@@ -548,7 +548,7 @@ void PropertyItem::setText( int col, const TQString &t )
{
TQString txt( t );
if ( col == 1 )
- txt = txt.replace( TQRegExp( "\n" ), " " );
+ txt = txt.tqreplace( TQRegExp( "\n" ), " " );
TQListViewItem::setText( col, txt );
}
@@ -582,13 +582,13 @@ TQLineEdit *PropertyTextItem::lined()
if ( asciiOnly ) {
if ( PropertyItem::name() == "name" )
- lin->setValidator( new AsciiValidator( lin, "ascii_validator" ) );
+ lin->setValidator( new AsciiValidator( TQT_TQOBJECT(lin), "ascii_validator" ) );
else
lin->setValidator( new AsciiValidator( TQString("!\"#$%&'()*+,-./:;<=>?@[\\]^_`{|}~"
"\xa1\xa2\xa3\xa4\xa5\xa6\xa7\xa8\xa9"
"\xaa\xab\xac\xad\xae\xaf\xb1\xb2\xb3"
"\xb4\xb5\xb6\xb7\xb8\xb9\xba\xbb\xbc"
- "\xbd\xbe\xbf"), lin, "ascii_validator" ) );
+ "\xbd\xbe\xbf"), TQT_TQOBJECT(lin), "ascii_validator" ) );
} if ( !hasMultiLines ) {
lin->hide();
} else {
@@ -762,7 +762,7 @@ TQLineEdit *PropertyDoubleItem::lined()
if ( lin )
return lin;
lin = new TQLineEdit( listview->viewport() );
- lin->setValidator( new TQDoubleValidator( lin, "double_validator" ) );
+ lin->setValidator( new TQDoubleValidator( TQT_TQOBJECT(lin), "double_validator" ) );
connect( lin, TQT_SIGNAL( returnPressed() ),
this, TQT_SLOT( setValue() ) );
@@ -837,11 +837,11 @@ PropertyDateItem::PropertyDateItem( PropertyList *l, PropertyItem *after, Proper
lin = 0;
}
-QDateEdit *PropertyDateItem::lined()
+TQDateEdit *PropertyDateItem::lined()
{
if ( lin )
return lin;
- lin = new QDateEdit( listview->viewport() );
+ lin = new TQDateEdit( listview->viewport() );
TQObjectList *l = lin->queryList( TQLINEEDIT_OBJECT_NAME_STRING );
for ( TQObject *o = l->first(); o; o = l->next() )
o->installEventFilter( listview );
@@ -853,7 +853,7 @@ QDateEdit *PropertyDateItem::lined()
PropertyDateItem::~PropertyDateItem()
{
- delete (QDateEdit*)lin;
+ delete (TQDateEdit*)lin;
lin = 0;
}
@@ -912,11 +912,11 @@ PropertyTimeItem::PropertyTimeItem( PropertyList *l, PropertyItem *after, Proper
lin = 0;
}
-QTimeEdit *PropertyTimeItem::lined()
+TQTimeEdit *PropertyTimeItem::lined()
{
if ( lin )
return lin;
- lin = new QTimeEdit( listview->viewport() );
+ lin = new TQTimeEdit( listview->viewport() );
connect( lin, TQT_SIGNAL( valueChanged( const TQTime & ) ),
this, TQT_SLOT( setValue() ) );
TQObjectList *l = lin->queryList( TQLINEEDIT_OBJECT_NAME_STRING );
@@ -928,7 +928,7 @@ QTimeEdit *PropertyTimeItem::lined()
PropertyTimeItem::~PropertyTimeItem()
{
- delete (QTimeEdit*)lin;
+ delete (TQTimeEdit*)lin;
lin = 0;
}
@@ -987,11 +987,11 @@ PropertyDateTimeItem::PropertyDateTimeItem( PropertyList *l, PropertyItem *after
lin = 0;
}
-QDateTimeEdit *PropertyDateTimeItem::lined()
+TQDateTimeEdit *PropertyDateTimeItem::lined()
{
if ( lin )
return lin;
- lin = new QDateTimeEdit( listview->viewport() );
+ lin = new TQDateTimeEdit( listview->viewport() );
connect( lin, TQT_SIGNAL( valueChanged( const TQDateTime & ) ),
this, TQT_SLOT( setValue() ) );
TQObjectList *l = lin->queryList( TQLINEEDIT_OBJECT_NAME_STRING );
@@ -1003,7 +1003,7 @@ QDateTimeEdit *PropertyDateTimeItem::lined()
PropertyDateTimeItem::~PropertyDateTimeItem()
{
- delete (QDateTimeEdit*)lin;
+ delete (TQDateTimeEdit*)lin;
lin = 0;
}
@@ -1540,8 +1540,8 @@ PropertyPixmapItem::PropertyPixmapItem( PropertyList *l, PropertyItem *after, Pr
box = new TQHBox( listview->viewport() );
box->hide();
pixPrev = new TQLabel( box );
- pixPrev->setSizePolicy( TQSizePolicy( TQSizePolicy::Preferred, TQSizePolicy::Minimum ) );
- pixPrev->setBackgroundColor( pixPrev->colorGroup().color( TQColorGroup::Base ) );
+ pixPrev->tqsetSizePolicy( TQSizePolicy( TQSizePolicy::Preferred, TQSizePolicy::Minimum ) );
+ pixPrev->setBackgroundColor( pixPrev->tqcolorGroup().color( TQColorGroup::Base ) );
button = new TQPushButton( "...", box );
button->setFixedWidth( 20 );
box->setFrameStyle( TQFrame::StyledPanel | TQFrame::Sunken );
@@ -1580,7 +1580,7 @@ void PropertyPixmapItem::setValue( const TQVariant &v )
else
pixPrev->setPixmap( v.toIconSet().pixmap() );
PropertyItem::setValue( v );
- repaint();
+ tqrepaint();
}
void PropertyPixmapItem::getPixmap()
@@ -1605,8 +1605,8 @@ void PropertyPixmapItem::drawCustomContents( TQPainter *p, const TQRect &r )
TQPixmap pix( (!iconSet ? value().toPixmap() : value().toIconSet().pixmap()) );
if ( !pix.isNull() ) {
p->save();
- p->setClipRect( TQRect( TQPoint( (int)(p->worldMatrix().dx() + r.x()),
- (int)(p->worldMatrix().dy() + r.y()) ),
+ p->setClipRect( TQRect( TQPoint( (int)(p->tqworldMatrix().dx() + r.x()),
+ (int)(p->tqworldMatrix().dy() + r.y()) ),
r.size() ) );
p->drawPixmap( r.x(), r.y() + ( r.height() - pix.height() ) / 2, pix );
p->restore();
@@ -1617,8 +1617,8 @@ void PropertyPixmapItem::drawCustomContents( TQPainter *p, const TQRect &r )
// --------------------------------------------------------------
PropertyColorItem::PropertyColorItem( PropertyList *l, PropertyItem *after, PropertyItem *prop,
- const TQString &propName, bool children )
- : PropertyItem( l, after, prop, propName ), withChildren( children )
+ const TQString &propName, bool tqchildren )
+ : PropertyItem( l, after, prop, propName ), withChildren( tqchildren )
{
box = new TQHBox( listview->viewport() );
box->hide();
@@ -1834,7 +1834,7 @@ void PropertyFontItem::setValue( const TQVariant &v )
void PropertyFontItem::getFont()
{
bool ok = false;
- TQFont f = QFontDialog::getFont( &ok, val.toFont(), listview );
+ TQFont f = TQFontDialog::getFont( &ok, val.toFont(), listview );
if ( ok && f != val.toFont() ) {
setValue( f );
notifyValueChange();
@@ -1901,7 +1901,7 @@ void PropertyDatabaseItem::createChildren()
void PropertyDatabaseItem::initChildren()
{
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
PropertyItem *item = 0;
TQStringList lst = value().toStringList();
TQString conn, table;
@@ -2003,7 +2003,7 @@ bool PropertyDatabaseItem::hasSubItems() const
void PropertyDatabaseItem::childValueChanged( PropertyItem *c )
{
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
TQStringList lst;
lst << ( (PropertyListItem*)PropertyItem::child( 0 ) )->currentItem()
<< ( (PropertyListItem*)PropertyItem::child( 1 ) )->currentItem();
@@ -2112,7 +2112,7 @@ void PropertySizePolicyItem::setValue( const TQVariant &v )
return;
TQString s = TQString( "%1/%2/%2/%2" );
- s = s.arg( size_type_to_string( v.toSizePolicy().horData() ) ).
+ s = s.tqarg( size_type_to_string( v.toSizePolicy().horData() ) ).
arg( size_type_to_string( v.toSizePolicy().verData() ) ).
arg( v.toSizePolicy().horStretch() ).
arg( v.toSizePolicy().verStretch() );
@@ -2185,7 +2185,7 @@ void PropertyPaletteItem::setValue( const TQVariant &v )
TQString s;
palettePrev->setPalette( v.toPalette() );
PropertyItem::setValue( v );
- repaint();
+ tqrepaint();
}
void PropertyPaletteItem::getPalette()
@@ -2197,8 +2197,8 @@ void PropertyPaletteItem::getPalette()
if ( w->inherits( TQSCROLLVIEW_OBJECT_NAME_STRING ) )
w = ( (TQScrollView*)w )->viewport();
TQPalette pal = PaletteEditor::getPalette( &ok, val.toPalette(),
-#if defined(QT_NON_COMMERCIAL)
- w->backgroundMode(), listview->topLevelWidget(),
+#if defined(TQT_NON_COMMERCIAL)
+ w->backgroundMode(), listview->tqtopLevelWidget(),
#else
w->backgroundMode(), listview,
#endif
@@ -2218,8 +2218,8 @@ void PropertyPaletteItem::drawCustomContents( TQPainter *p, const TQRect &r )
{
TQPalette pal( value().toPalette() );
p->save();
- p->setClipRect( TQRect( TQPoint( (int)(p->worldMatrix().dx() + r.x()),
- (int)(p->worldMatrix().dy() + r.y()) ),
+ p->setClipRect( TQRect( TQPoint( (int)(p->tqworldMatrix().dx() + r.x()),
+ (int)(p->tqworldMatrix().dy() + r.y()) ),
r.size() ) );
TQRect r2( r );
r2.setX( r2.x() + 2 );
@@ -2271,11 +2271,11 @@ TQComboBox *PropertyCursorItem::combo()
cur = TQBitmap(sizev_width, sizev_height, sizev_bits, true);
cur.setMask( cur );
- comb->insertItem( cur, i18n("Size Vertical"), TQObject::SizeVerCursor );
+ comb->insertItem( cur, i18n("SizeQt::Vertical"), TQObject::SizeVerCursor );
cur = TQBitmap(sizeh_width, sizeh_height, sizeh_bits, true);
cur.setMask( cur );
- comb->insertItem( cur, i18n("Size Horizontal"), TQObject::SizeHorCursor );
+ comb->insertItem( cur, i18n("SizeQt::Horizontal"), TQObject::SizeHorCursor );
cur = TQBitmap(sizef_width, sizef_height, sizef_bits, true);
cur.setMask( cur );
@@ -2295,11 +2295,11 @@ TQComboBox *PropertyCursorItem::combo()
cur = TQBitmap(vsplit_width, vsplit_height, vsplit_bits, true);
cur.setMask( cur );
- comb->insertItem( cur, i18n("Split Vertical"), TQObject::SplitVCursor );
+ comb->insertItem( cur, i18n("SplitQt::Vertical"), TQObject::SplitVCursor );
cur = TQBitmap(hsplit_width, hsplit_height, hsplit_bits, true);
cur.setMask( cur );
- comb->insertItem( cur, i18n("Split Horizontal"), TQObject::SplitHCursor );
+ comb->insertItem( cur, i18n("SplitQt::Horizontal"), TQObject::SplitHCursor );
cur = TQBitmap(hand_width, hand_height, hand_bits, true);
cur.setMask( cur );
@@ -2325,7 +2325,7 @@ void PropertyCursorItem::showEditor()
PropertyItem::showEditor();
if ( !comb ) {
combo()->blockSignals( true );
- combo()->setCurrentItem( (int)value().toCursor().shape() );
+ combo()->setCurrentItem( (int)value().toCursor().tqshape() );
combo()->blockSignals( false );
}
placeEditor( combo() );
@@ -2348,7 +2348,7 @@ void PropertyCursorItem::setValue( const TQVariant &v )
return;
combo()->blockSignals( true );
- combo()->setCurrentItem( (int)v.toCursor().shape() );
+ combo()->setCurrentItem( (int)v.toCursor().tqshape() );
combo()->blockSignals( false );
setText( 1, combo()->currentText() );
PropertyItem::setValue( v );
@@ -2461,9 +2461,9 @@ static TQVariant::Type type_to_variant( const TQString &s )
if ( s == "Palette" )
return TQVariant::Palette;
if ( s == "ColorGroup" )
- return TQVariant::ColorGroup;
+ return (QVariant::Type)TQVariant::ColorGroup;
if ( s == "IconSet" )
- return TQVariant::IconSet;
+ return (QVariant::Type)TQVariant::IconSet;
if ( s == "Point" )
return TQVariant::Point;
if ( s == "Image" )
@@ -2477,11 +2477,11 @@ static TQVariant::Type type_to_variant( const TQString &s )
if ( s == "Double" )
return TQVariant::Double;
if ( s == "CString" )
- return TQVariant::CString;
+ return (QVariant::Type)TQVariant::CString;
if ( s == "PointArray" )
- return TQVariant::PointArray;
+ return (QVariant::Type)TQVariant::PointArray;
if ( s == "Region" )
- return TQVariant::Region;
+ return (QVariant::Type)TQVariant::Region;
if ( s == "Bitmap" )
return TQVariant::Bitmap;
if ( s == "Cursor" )
@@ -2497,17 +2497,17 @@ static TQVariant::Type type_to_variant( const TQString &s )
return TQVariant::Invalid;
}
-#ifndef QT_NO_SQL
-static bool parent_is_data_aware( TQObject *o )
+#ifndef TQT_NO_SQL
+static bool tqparent_is_data_aware( TQObject *o )
{
if ( !o->inherits( TQWIDGET_OBJECT_NAME_STRING ) )
return false;
TQWidget *w = (TQWidget*)o;
- TQWidget *p = w->parentWidget();
+ TQWidget *p = w->tqparentWidget();
while ( p && !p->isTopLevel() ) {
- if ( p->inherits( "QDesignerDataBrowser" ) || p->inherits( "QDesignerDataView" ) )
+ if ( p->inherits( "TQDesignerDataBrowser" ) || p->inherits( "TQDesignerDataView" ) )
return true;
- p = p->parentWidget();
+ p = p->tqparentWidget();
}
return false;
}
@@ -2522,24 +2522,24 @@ void PropertyList::setupProperties()
if ( !editor->widget() )
return;
bool allProperties = !editor->widget()->inherits( "Spacer" );
- TQStrList lst = editor->widget()->metaObject()->propertyNames( allProperties );
+ TQStrList lst = editor->widget()->tqmetaObject()->propertyNames( allProperties );
PropertyItem *item = 0;
TQMap<TQString, bool> unique;
TQObject *w = editor->widget();
TQStringList valueSet;
- bool parentHasLayout =
+ bool tqparentHasLayout =
w->isWidgetType() &&
- !editor->formWindow()->isMainContainer( (TQWidget*)w ) && ( (TQWidget*)w )->parentWidget() &&
- WidgetFactory::layoutType( ( (TQWidget*)w )->parentWidget() ) != WidgetFactory::NoLayout;
+ !editor->formWindow()->isMainContainer( TQT_TQOBJECT((TQWidget*)w) ) && ( (TQWidget*)w )->tqparentWidget() &&
+ WidgetFactory::tqlayoutType( ( (TQWidget*)w )->tqparentWidget() ) != WidgetFactory::NoLayout;
for ( TQPtrListIterator<char> it( lst ); it.current(); ++it ) {
const TQMetaProperty* p =
- editor->widget()->metaObject()->
- property( editor->widget()->metaObject()->findProperty( it.current(), allProperties), allProperties );
+ editor->widget()->tqmetaObject()->
+ property( editor->widget()->tqmetaObject()->tqfindProperty( it.current(), allProperties), allProperties );
if ( !p )
continue;
- if ( unique.contains( TQString::fromLatin1( it.current() ) ) )
+ if ( unique.tqcontains( TQString::tqfromLatin1( it.current() ) ) )
continue;
- if ( editor->widget()->inherits( "QDesignerToolBar" ) || editor->widget()->inherits( "QDesignerMenuBar" ) ) {
+ if ( editor->widget()->inherits( "TQDesignerToolBar" ) || editor->widget()->inherits( "TQDesignerMenuBar" ) ) {
if ( qstrcmp( p->name(), "minimumHeight" ) == 0 )
continue;
if ( qstrcmp( p->name(), "minimumWidth" ) == 0 )
@@ -2552,14 +2552,14 @@ void PropertyList::setupProperties()
continue;
if ( qstrcmp( p->name(), "sizePolicy" ) == 0 )
continue;
- if ( qstrcmp( p->name(), "minimumSize" ) == 0 )
+ if ( qstrcmp( p->name(), "tqminimumSize" ) == 0 )
continue;
- if ( qstrcmp( p->name(), "maximumSize" ) == 0 )
+ if ( qstrcmp( p->name(), "tqmaximumSize" ) == 0 )
continue;
}
- unique.insert( TQString::fromLatin1( it.current() ), true );
+ unique.insert( TQString::tqfromLatin1( it.current() ), true );
if ( editor->widget()->isWidgetType() &&
- editor->formWindow()->isMainContainer( (TQWidget*)editor->widget() ) ) {
+ editor->formWindow()->isMainContainer( TQT_TQOBJECT((TQWidget*)editor->widget()) ) ) {
if ( qstrcmp( p->name(), "geometry" ) == 0 )
continue;
} else { // hide some toplevel-only stuff
@@ -2573,9 +2573,9 @@ void PropertyList::setupProperties()
continue;
if ( qstrcmp( p->name(), "baseSize" ) == 0 )
continue;
- if ( parentHasLayout && qstrcmp( p->name(), "geometry" ) == 0 )
+ if ( tqparentHasLayout && qstrcmp( p->name(), "geometry" ) == 0 )
continue;
- if ( w->inherits( "QLayoutWidget" ) || w->inherits( "Spacer" ) ) {
+ if ( w->inherits( TQLAYOUTWIDGET_OBJECT_NAME_STRING ) || w->inherits( "Spacer" ) ) {
if ( qstrcmp( p->name(), "sizePolicy" ) == 0 )
continue;
if ( qstrcmp( p->name(), "minimumHeight" ) == 0 )
@@ -2588,9 +2588,9 @@ void PropertyList::setupProperties()
continue;
if ( qstrcmp( p->name(), "geometry" ) == 0 )
continue;
- if ( qstrcmp( p->name(), "minimumSize" ) == 0 )
+ if ( qstrcmp( p->name(), "tqminimumSize" ) == 0 )
continue;
- if ( qstrcmp( p->name(), "maximumSize" ) == 0 )
+ if ( qstrcmp( p->name(), "tqmaximumSize" ) == 0 )
continue;
if ( qstrcmp( p->name(), "enabled" ) == 0 )
continue;
@@ -2632,17 +2632,17 @@ void PropertyList::setupProperties()
continue;
if ( qstrcmp( p->name(), "maximumWidth" ) == 0 )
continue;
- if ( qstrcmp( p->name(), "buttonGroupId" ) == 0 ) { // #### remove this when designable in Q_PROPERTY can take a function (isInButtonGroup() in this case)
+ if ( qstrcmp( p->name(), "buttonGroupId" ) == 0 ) { // #### remove this when designable in TQ_PROPERTY can take a function (isInButtonGroup() in this case)
if ( !editor->widget()->isWidgetType() ||
- !editor->widget()->parent() ||
- !editor->widget()->parent()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) )
+ !editor->widget()->tqparent() ||
+ !editor->widget()->tqparent()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) )
continue;
}
if ( p->designable(w) ) {
if ( p->isSetType() ) {
- if ( TQString( p->name() ) == "alignment" ) {
+ if ( TQString( p->name() ) == "tqalignment" ) {
TQStringList lst;
lst << p->valueToKey( AlignAuto )
<< p->valueToKey( AlignLeft )
@@ -2672,14 +2672,14 @@ void PropertyList::setupProperties()
item->setChanged( true, false );
}
} else {
- qWarning( "Sets except 'alignment' not supported yet.... %s.", p->name() );
+ qWarning( "Sets except 'tqalignment' not supported yet.... %s.", p->name() );
}
} else if ( p->isEnumType() ) {
TQStrList l = p->enumKeys();
TQStringList lst;
for ( uint i = 0; i < l.count(); ++i ) {
TQString k = l.at( i );
- // filter out enum-masks
+ // filter out enum-tqmasks
if ( k[0] == 'M' && k[1].category() == TQChar::Letter_Uppercase )
continue;
lst << l.at( i );
@@ -2693,7 +2693,7 @@ void PropertyList::setupProperties()
}
}
if ( item && !p->isSetType() ) {
- if ( valueSet.findIndex( item->name() ) == -1 ) {
+ if ( valueSet.tqfindIndex( item->name() ) == -1 ) {
setPropertyValue( item );
valueSet << item->name();
}
@@ -2702,19 +2702,19 @@ void PropertyList::setupProperties()
}
}
- if ( !w->inherits( TQSPLITTER_OBJECT_NAME_STRING ) && !w->inherits( "QDesignerMenuBar" ) && !w->inherits( "QDesignerToolBar" ) &&
- w->isWidgetType() && WidgetFactory::layoutType( (TQWidget*)w ) != WidgetFactory::NoLayout ) {
- item = new PropertyIntItem( this, item, 0, "layoutSpacing", true );
+ if ( !w->inherits( TQSPLITTER_OBJECT_NAME_STRING ) && !w->inherits( "TQDesignerMenuBar" ) && !w->inherits( "TQDesignerToolBar" ) &&
+ w->isWidgetType() && WidgetFactory::tqlayoutType( (TQWidget*)w ) != WidgetFactory::NoLayout ) {
+ item = new PropertyIntItem( this, item, 0, "tqlayoutSpacing", true );
setPropertyValue( item );
item->setChanged( true );
- item = new PropertyIntItem( this, item, 0, "layoutMargin", true );
+ item = new PropertyIntItem( this, item, 0, "tqlayoutMargin", true );
setPropertyValue( item );
item->setChanged( true );
}
- if ( !w->inherits( "Spacer" ) && !w->inherits( "QLayoutWidget" ) && !w->inherits( TQACTION_OBJECT_NAME_STRING ) &&
- !w->inherits( "QDesignerMenuBar" ) && !w->inherits( "QDesignerToolBar" ) ) {
+ if ( !w->inherits( "Spacer" ) && !w->inherits( TQLAYOUTWIDGET_OBJECT_NAME_STRING ) && !w->inherits( TQACTION_OBJECT_NAME_STRING ) &&
+ !w->inherits( "TQDesignerMenuBar" ) && !w->inherits( "TQDesignerToolBar" ) ) {
item = new PropertyTextItem( this, item, 0, "toolTip", true, false );
setPropertyValue( item );
if ( MetaDataBase::isPropertyChanged( editor->widget(), "toolTip" ) )
@@ -2725,9 +2725,9 @@ void PropertyList::setupProperties()
item->setChanged( true, false );
}
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
if ( !editor->widget()->inherits( TQDATATABLE_OBJECT_NAME_STRING ) && !editor->widget()->inherits( TQDATABROWSER_OBJECT_NAME_STRING ) &&
- !editor->widget()->inherits( TQDATAVIEW_OBJECT_NAME_STRING ) && parent_is_data_aware( editor->widget() ) ) {
+ !editor->widget()->inherits( TQDATAVIEW_OBJECT_NAME_STRING ) && tqparent_is_data_aware( editor->widget() ) ) {
item = new PropertyDatabaseItem( this, item, 0, "database", editor->formWindow()->mainContainer() != w );
setPropertyValue( item );
if ( MetaDataBase::isPropertyChanged( editor->widget(), "database" ) )
@@ -2750,7 +2750,7 @@ void PropertyList::setupProperties()
MetaDataBase::CustomWidget *cw = ( (CustomWidget*)w )->customWidget();
if ( cw ) {
for ( TQValueList<MetaDataBase::Property>::Iterator it = cw->lstProperties.begin(); it != cw->lstProperties.end(); ++it ) {
- if ( unique.contains( TQString( (*it).property ) ) )
+ if ( unique.tqcontains( TQString( (*it).property ) ) )
continue;
unique.insert( TQString( (*it).property ), true );
addPropertyItem( item, (*it).property, type_to_variant( (*it).type ) );
@@ -2768,7 +2768,7 @@ void PropertyList::setupProperties()
sort();
setSorting( -1 );
setCurrentItem( firstChild() );
- qApp->processEvents();
+ tqApp->processEvents();
}
updateEditorSize();
@@ -2785,7 +2785,7 @@ bool PropertyList::addPropertyItem( PropertyItem *&item, const TQCString &name,
case TQVariant::CString:
item = new PropertyTextItem( this, item, 0,
name, name == "name" &&
- editor->widget() == editor->formWindow()->mainContainer(),
+ TQT_BASE_OBJECT(editor->widget()) == TQT_BASE_OBJECT(editor->formWindow()->mainContainer()),
false, true );
break;
case TQVariant::Bool:
@@ -2882,7 +2882,7 @@ void PropertyList::valueChanged( PropertyItem *i )
{
if ( !editor->widget() )
return;
- TQString pn( i18n("Set '%1' of '%2'" ).arg( i->name() ).arg( editor->widget()->name() ) );
+ TQString pn( i18n("Set '%1' of '%2'" ).tqarg( i->name() ).tqarg( editor->widget()->name() ) );
SetPropertyCommand *cmd = new SetPropertyCommand( pn, editor->formWindow(),
editor->widget(), editor,
i->name(), WidgetFactory::property( editor->widget(), i->name() ),
@@ -2921,10 +2921,10 @@ bool PropertyList::eventFilter( TQObject *o, TQEvent *e )
return true;
PropertyItem *i = (PropertyItem*)currentItem();
- if ( o != this &&e->type() == TQEvent::KeyPress ) {
+ if ( TQT_BASE_OBJECT(o) != TQT_BASE_OBJECT(this) &&e->type() == TQEvent::KeyPress ) {
TQKeyEvent *ke = (TQKeyEvent*)e;
if ( ( ke->key() == Key_Up || ke->key() == Key_Down ) &&
- ( o != this || o != viewport() ) &&
+ ( TQT_BASE_OBJECT(o) != TQT_BASE_OBJECT(this) || TQT_BASE_OBJECT(o) != TQT_BASE_OBJECT(viewport()) ) &&
!( ke->state() & ControlButton ) ) {
TQApplication::sendEvent( this, (TQKeyEvent*)e );
return true;
@@ -2946,7 +2946,7 @@ bool PropertyList::eventFilter( TQObject *o, TQEvent *e )
}
} else if ( e->type() == TQEvent::FocusOut && o->inherits( TQLINEEDIT_OBJECT_NAME_STRING ) && editor->formWindow() ) {
TQTimer::singleShot( 100, editor->formWindow()->commandHistory(), TQT_SLOT( checkCompressedCommand() ) );
- } else if ( o == viewport() ) {
+ } else if ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(viewport()) ) {
TQMouseEvent *me;
PropertyListItem* i;
switch ( e->type() ) {
@@ -2961,7 +2961,7 @@ bool PropertyList::eventFilter( TQObject *o, TQEvent *e )
break;
case TQEvent::MouseMove:
me = (TQMouseEvent*)e;
- if ( me && me->state() & LeftButton && mousePressed) {
+ if ( me && me->state() & Qt::LeftButton && mousePressed) {
i = (PropertyListItem*) itemAt( me->pos() );
if( i && i == pressItem ) {
@@ -2996,7 +2996,7 @@ bool PropertyList::eventFilter( TQObject *o, TQEvent *e )
default:
break;
}
- } else if ( o == header() ) {
+ } else if ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(header()) ) {
if ( e->type() == TQEvent::ContextMenu ) {
((TQContextMenuEvent *)e)->accept();
TQPopupMenu menu( 0 );
@@ -3048,9 +3048,9 @@ static void clearAlignList( TQStrList &l )
{
if ( l.count() == 1 )
return;
- if ( l.find( "AlignAuto" ) != -1 )
+ if ( l.tqfind( "AlignAuto" ) != -1 )
l.remove( "AlignAuto" );
- if ( l.find( "WordBreak" ) != -1 )
+ if ( l.tqfind( "WordBreak" ) != -1 )
l.remove( "WordBreak" );
}
@@ -3061,33 +3061,33 @@ static void clearAlignList( TQStrList &l )
void PropertyList::setPropertyValue( PropertyItem *i )
{
const TQMetaProperty *p =
- editor->widget()->metaObject()->
- property( editor->widget()->metaObject()->findProperty( i->name(), true), true );
+ editor->widget()->tqmetaObject()->
+ property( editor->widget()->tqmetaObject()->tqfindProperty( i->name(), true), true );
if ( !p ) {
if ( i->name() == "hAlign" ) {
- int align = editor->widget()->property( "alignment" ).toInt();
- p = editor->widget()->metaObject()->
- property( editor->widget()->metaObject()->findProperty( "alignment", true ), true );
+ int align = editor->widget()->property( "tqalignment" ).toInt();
+ p = editor->widget()->tqmetaObject()->
+ property( editor->widget()->tqmetaObject()->tqfindProperty( "tqalignment", true ), true );
align &= ~AlignVertical_Mask;
TQStrList l = p->valueToKeys( align );
clearAlignList( l );
( (PropertyListItem*)i )->setCurrentItem( l.last() );
} else if ( i->name() == "vAlign" ) {
- int align = editor->widget()->property( "alignment" ).toInt();
- p = editor->widget()->metaObject()->
- property( editor->widget()->metaObject()->findProperty( "alignment", true ), true );
+ int align = editor->widget()->property( "tqalignment" ).toInt();
+ p = editor->widget()->tqmetaObject()->
+ property( editor->widget()->tqmetaObject()->tqfindProperty( "tqalignment", true ), true );
align &= ~AlignHorizontal_Mask;
( (PropertyListItem*)i )->setCurrentItem( p->valueToKeys( align ).last() );
} else if ( i->name() == "wordwrap" ) {
- int align = editor->widget()->property( "alignment" ).toInt();
+ int align = editor->widget()->property( "tqalignment" ).toInt();
if ( align & WordBreak )
i->setValue( TQVariant( true, 0 ) );
else
i->setValue( TQVariant( false, 0 ) );
- } else if ( i->name() == "layoutSpacing" ) {
- ( (PropertyIntItem*)i )->setValue( MetaDataBase::spacing( WidgetFactory::containerOfWidget( (TQWidget*)editor->widget() ) ) );
- } else if ( i->name() == "layoutMargin" ) {
- ( (PropertyIntItem*)i )->setValue( MetaDataBase::margin( WidgetFactory::containerOfWidget( (TQWidget*)editor->widget() ) ) );
+ } else if ( i->name() == "tqlayoutSpacing" ) {
+ ( (PropertyIntItem*)i )->setValue( MetaDataBase::spacing( TQT_TQOBJECT(WidgetFactory::containerOfWidget( (TQWidget*)editor->widget() )) ) );
+ } else if ( i->name() == "tqlayoutMargin" ) {
+ ( (PropertyIntItem*)i )->setValue( MetaDataBase::margin( TQT_TQOBJECT(WidgetFactory::containerOfWidget( (TQWidget*)editor->widget() )) ) );
} else if ( i->name() == "toolTip" || i->name() == "whatsThis" || i->name() == "database" || i->name() == "frameworkCode" ) {
i->setValue( MetaDataBase::fakeProperty( editor->widget(), i->name() ) );
} else if ( editor->widget()->inherits( "CustomWidget" ) ) {
@@ -3134,7 +3134,7 @@ void PropertyList::resetProperty()
PropertyItem *i = (PropertyItem*)currentItem();
if ( !MetaDataBase::isPropertyChanged( editor->widget(), i->PropertyItem::name() ) )
return;
- TQString pn( i18n("Reset '%1' of '%2'" ).arg( i->name() ).arg( editor->widget()->name() ) );
+ TQString pn( i18n("Reset '%1' of '%2'" ).tqarg( i->name() ).tqarg( editor->widget()->name() ) );
SetPropertyCommand *cmd = new SetPropertyCommand( pn, editor->formWindow(),
editor->widget(), editor,
i->name(), i->value(),
@@ -3224,24 +3224,24 @@ void PropertyList::showCurrentWhatsThis()
TQString PropertyList::whatsThisText( TQListViewItem *i )
{
if ( !i || !editor->widget() )
- return TQString::null;
+ return TQString();
readPropertyDocs();
if ( ( (PropertyItem*)i )->propertyParent() )
i = ( (PropertyItem*)i )->propertyParent();
- const TQMetaObject *mo = editor->widget()->metaObject();
+ const TQMetaObject *mo = editor->widget()->tqmetaObject();
TQString prop = ( (PropertyItem*)i )->name();
while ( mo ) {
TQString s;
s = TQString( mo->className() ) + "::" + prop;
TQMap<TQString, TQString>::Iterator it;
- if ( ( it = propertyDocs.find( s ) ) != propertyDocs.end() ) {
+ if ( ( it = propertyDocs.tqfind( s ) ) != propertyDocs.end() ) {
return *it;
}
- mo = mo->superClass();
+ mo = mo->tqsuperClass();
}
- return i18n("<p><b>TQWidget::%1</b></p><p>There is no documentation available for this property.</p>" ).arg( prop );
+ return i18n("<p><b>TQWidget::%1</b></p><p>There is no documentation available for this property.</p>" ).tqarg( prop );
}
void PropertyList::readPropertyDocs()
@@ -3278,8 +3278,8 @@ void PropertyList::readPropertyDocs()
// ------------------------------------------------------------
#ifndef KOMMANDER
-EventList::EventList( TQWidget *parent, FormWindow *fw, PropertyEditor *e )
- : HierarchyList( parent, fw, true ), editor( e )
+EventList::EventList( TQWidget *tqparent, FormWindow *fw, PropertyEditor *e )
+ : HierarchyList( tqparent, fw, true ), editor( e )
{
header()->hide();
removeColumn( 1 );
@@ -3307,7 +3307,7 @@ void EventList::setup()
return;
for ( TQValueList<MetaDataBase::EventDescription>::Iterator it = events.begin(); it != events.end(); ++it ) {
HierarchyItem *eventItem = new HierarchyItem( HierarchyItem::Event, this, (*it).name,
- TQString::null, TQString::null );
+ TQString(), TQString() );
eventItem->setOpen( true );
TQStringList funcs = MetaDataBase::eventFunctions( editor->widget(),
(*it).name,
@@ -3318,7 +3318,7 @@ void EventList::setup()
#endif
for ( TQStringList::Iterator fit = funcs.begin(); fit != funcs.end(); ++fit ) {
HierarchyItem *item = new HierarchyItem( HierarchyItem::EventFunction, eventItem,
- *fit, TQString::null, TQString::null );
+ *fit, TQString(), TQString() );
item->setPixmap( 0, PixmapChooser::loadPixmap( "editslots.xpm" ) );
}
#if 0 // ### for conversation from old to new
@@ -3327,12 +3327,12 @@ void EventList::setup()
#endif
}
} else {
- TQStrList sigs = editor->widget()->metaObject()->signalNames( true );
+ TQStrList sigs = editor->widget()->tqmetaObject()->signalNames( true );
sigs.remove( "destroyed()" );
TQStrListIterator it( sigs );
while ( it.current() ) {
HierarchyItem *eventItem = new HierarchyItem( HierarchyItem::Event, this,
- it.current(), TQString::null, TQString::null );
+ it.current(), TQString(), TQString() );
eventItem->setOpen( true );
TQValueList<MetaDataBase::Connection> conns =
MetaDataBase::connections( formWindow, editor->widget(), formWindow->mainContainer() );
@@ -3341,7 +3341,7 @@ void EventList::setup()
MetaDataBase::normalizeSlot( TQString( it.current() ) ) )
continue;
HierarchyItem *item = new HierarchyItem( HierarchyItem::EventFunction, eventItem,
- (*cit).slot, TQString::null, TQString::null );
+ (*cit).slot, TQString(), TQString() );
item->setPixmap( 0, PixmapChooser::loadPixmap( "editslots.xpm" ) );
}
++it;
@@ -3354,7 +3354,7 @@ extern TQListViewItem *newItem;
void EventList::contentsMouseDoubleClickEvent( TQMouseEvent *e )
{
TQListViewItem *i = itemAt( contentsToViewport( e->pos() ) );
- if ( !i || i->parent() )
+ if ( !i || i->tqparent() )
return;
TQString s;
#ifndef KOMMANDER
@@ -3363,7 +3363,7 @@ void EventList::contentsMouseDoubleClickEvent( TQMouseEvent *e )
if ( MetaDataBase::hasEvents( "C++" ) ) {
#endif
TQString s1 = i->text( 0 );
- int pt = s1.find( "(" );
+ int pt = s1.tqfind( "(" );
if ( pt != -1 )
s1 = s1.left( pt );
s = TQString( editor->widget()->name() ) + "_" + s1;
@@ -3380,7 +3380,7 @@ void EventList::setCurrent( TQWidget * )
void EventList::objectClicked( TQListViewItem *i )
{
- if ( !i || !i->parent() )
+ if ( !i || !i->tqparent() )
return;
formWindow->mainWindow()->editFunction( i->text( 0 ) );
}
@@ -3402,29 +3402,29 @@ void EventList::showRMBMenu( TQListViewItem *i, const TQPoint &pos )
#else
if ( MetaDataBase::hasEvents( "C++" ) ) {
#endif
- TQString s1 = ( i->parent() ? i->parent() : i )->text( 0 );
- int pt = s1.find( "(" );
+ TQString s1 = ( i->tqparent() ? i->tqparent() : i )->text( 0 );
+ int pt = s1.tqfind( "(" );
if ( pt != -1 )
s1 = s1.left( pt );
s = TQString( editor->widget()->name() ) + "_" + s1;
} else {
- s = TQString( editor->widget()->name() ) + "_" + ( i->parent() ? i->parent() : i )->text( 0 );
+ s = TQString( editor->widget()->name() ) + "_" + ( i->tqparent() ? i->tqparent() : i )->text( 0 );
}
- insertEntry( i->parent() ? i->parent() : i, PixmapChooser::loadPixmap( "editslots.xpm" ), s );
- } else if ( res == DEL_ITEM && i->parent() ) {
+ insertEntry( i->tqparent() ? i->tqparent() : i, PixmapChooser::loadPixmap( "editslots.xpm" ), s );
+ } else if ( res == DEL_ITEM && i->tqparent() ) {
#ifndef KOMMANDER
if ( MetaDataBase::hasEvents( formWindow->project()->language() ) ) {
#else
if ( MetaDataBase::hasEvents( "C++" ) ) {
#endif
- TQListViewItem *p = i->parent();
+ TQListViewItem *p = i->tqparent();
delete i;
save( p );
} else {
MetaDataBase::Connection conn;
conn.sender = editor->widget();
conn.receiver = formWindow->mainContainer();
- conn.signal = i->parent()->text( 0 );
+ conn.signal = i->tqparent()->text( 0 );
conn.slot = i->text( 0 );
delete i;
RemoveConnectionCommand *cmd = new RemoveConnectionCommand( i18n("Remove Connection" ),
@@ -3443,9 +3443,9 @@ void EventList::renamed( TQListViewItem *i )
{
if ( newItem == i )
newItem = 0;
- if ( !i->parent() )
+ if ( !i->tqparent() )
return;
- TQListViewItem *itm = i->parent()->firstChild();
+ TQListViewItem *itm = i->tqparent()->firstChild();
bool del = false;
while ( itm ) {
if ( itm != i && itm->text( 0 ) == i->text( 0 ) ) {
@@ -3464,7 +3464,7 @@ void EventList::renamed( TQListViewItem *i )
if ( MetaDataBase::hasEvents( "C++" ) ) {
#endif
- save( i->parent() );
+ save( i->tqparent() );
editor->formWindow()->mainWindow()->
#ifndef KOMMANDER
editFunction( i->text( 0 ), editor->formWindow()->project()->language(), true );
@@ -3475,7 +3475,7 @@ void EventList::renamed( TQListViewItem *i )
MetaDataBase::Connection conn;
conn.sender = editor->widget();
conn.receiver = formWindow->mainContainer();
- conn.signal = i->parent()->text( 0 );
+ conn.signal = i->tqparent()->text( 0 );
conn.slot = i->text( 0 );
AddConnectionCommand *cmd = new AddConnectionCommand( i18n("Add Connection" ),
formWindow,
@@ -3491,7 +3491,7 @@ void EventList::renamed( TQListViewItem *i )
"C++", "void" );
#endif
editor->formWindow()->mainWindow()->
- editFunction( i->text( 0 ).left( i->text( 0 ).find( "(" ) ),
+ editFunction( i->text( 0 ).left( i->text( 0 ).tqfind( "(" ) ),
#ifndef KOMMANDER
editor->formWindow()->project()->language(), true );
#else
@@ -3535,8 +3535,8 @@ void EventList::save( TQListViewItem *p )
listview for editing properties.
*/
-PropertyEditor::PropertyEditor( TQWidget *parent )
- : TQTabWidget( parent, 0, WStyle_Customize | WStyle_NormalBorder | WStyle_Title |
+PropertyEditor::PropertyEditor( TQWidget *tqparent )
+ : TQTabWidget( tqparent, 0, WStyle_Customize | WStyle_NormalBorder | WStyle_Title |
WStyle_StaysOnTop | WStyle_Tool |WStyle_MinMax | WStyle_SysMenu )
{
setCaption( i18n("Property Editor" ) );
@@ -3563,11 +3563,11 @@ void PropertyEditor::setWidget( TQObject *w, FormWindow *fw )
#endif
if ( w && w == wid ) {
bool ret = true;
- if ( wid->isWidgetType() && WidgetFactory::layoutType( (TQWidget*)wid ) != WidgetFactory::NoLayout ) {
+ if ( wid->isWidgetType() && WidgetFactory::tqlayoutType( (TQWidget*)wid ) != WidgetFactory::NoLayout ) {
TQListViewItemIterator it( listview );
ret = false;
while ( it.current() ) {
- if ( it.current()->text( 0 ) == "layoutSpacing" || it.current()->text( 0 ) == "layoutMargin" ) {
+ if ( it.current()->text( 0 ) == "tqlayoutSpacing" || it.current()->text( 0 ) == "tqlayoutMargin" ) {
ret = true;
break;
}
@@ -3588,7 +3588,7 @@ void PropertyEditor::setWidget( TQObject *w, FormWindow *fw )
wid = w;
formwindow = fw;
- setCaption( i18n("Property Editor (%1)" ).arg( formwindow->name() ) );
+ setCaption( i18n("Property Editor (%1)" ).tqarg( formwindow->name() ) );
listview->viewport()->setUpdatesEnabled( false );
listview->setUpdatesEnabled( false );
clear();
@@ -3662,7 +3662,7 @@ FormWindow *PropertyEditor::formWindow() const
TQString PropertyEditor::currentProperty() const
{
if ( !wid )
- return TQString::null;
+ return TQString();
if ( ( (PropertyItem*)listview->currentItem() )->propertyParent() )
return ( (PropertyItem*)listview->currentItem() )->propertyParent()->name();
return ( (PropertyItem*)listview->currentItem() )->name();
@@ -3671,24 +3671,24 @@ TQString PropertyEditor::currentProperty() const
TQString PropertyEditor::classOfCurrentProperty() const
{
if ( !wid )
- return TQString::null;
+ return TQString();
TQObject *o = wid;
TQString curr = currentProperty();
- TQMetaObject *mo = o->metaObject();
+ TQMetaObject *mo = o->tqmetaObject();
while ( mo ) {
TQStrList props = mo->propertyNames( false );
- if ( props.find( curr.latin1() ) != -1 )
+ if ( props.tqfind( curr.latin1() ) != -1 )
return mo->className();
- mo = mo->superClass();
+ mo = mo->tqsuperClass();
}
- return TQString::null;
+ return TQString();
}
-TQMetaObject* PropertyEditor::metaObjectOfCurrentProperty() const
+TQMetaObject* PropertyEditor::tqmetaObjectOfCurrentProperty() const
{
if ( !wid )
return 0;
- return wid->metaObject();
+ return wid->tqmetaObject();
}
void PropertyEditor::resetFocus()
diff --git a/kommander/editor/propertyeditor.h b/kommander/editor/propertyeditor.h
index 42e64e3e..262f0376 100644
--- a/kommander/editor/propertyeditor.h
+++ b/kommander/editor/propertyeditor.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -44,11 +44,11 @@ class FormWindow;
class TQCloseEvent;
class TQResizeEvent;
class PropertyWhatsThis;
-class QDateEdit;
-class QTimeEdit;
-class QDateTimeEdit;
+class TQDateEdit;
+class TQTimeEdit;
+class TQDateTimeEdit;
-class PropertyItem : public QListViewItem
+class PropertyItem : public TQListViewItem
{
public:
PropertyItem( PropertyList *l, PropertyItem *after, PropertyItem *prop, const TQString &propName );
@@ -118,7 +118,7 @@ private:
bool open, changed;
PropertyItem *property;
TQString propertyName;
- TQPtrList<PropertyItem> children;
+ TQPtrList<PropertyItem> tqchildren;
TQColor backColor;
TQPushButton *resetButton;
@@ -128,6 +128,7 @@ class PropertyTextItem : public TQObject,
public PropertyItem
{
Q_OBJECT
+ TQ_OBJECT
public:
PropertyTextItem( PropertyList *l, PropertyItem *after, PropertyItem *prop,
@@ -164,6 +165,7 @@ class PropertyBoolItem : public TQObject,
public PropertyItem
{
Q_OBJECT
+ TQ_OBJECT
public:
PropertyBoolItem( PropertyList *l, PropertyItem *after, PropertyItem *prop, const TQString &propName );
@@ -188,6 +190,7 @@ class PropertyIntItem : public TQObject,
public PropertyItem
{
Q_OBJECT
+ TQ_OBJECT
public:
PropertyIntItem( PropertyList *l, PropertyItem *after, PropertyItem *prop,
@@ -213,6 +216,7 @@ class PropertyDoubleItem : public TQObject,
public PropertyItem
{
Q_OBJECT
+ TQ_OBJECT
public:
PropertyDoubleItem( PropertyList *l, PropertyItem *after, PropertyItem *prop,
@@ -236,6 +240,7 @@ class PropertyListItem : public TQObject,
public PropertyItem
{
Q_OBJECT
+ TQ_OBJECT
public:
PropertyListItem( PropertyList *l, PropertyItem *after, PropertyItem *prop,
@@ -271,6 +276,7 @@ class PropertyFontItem : public TQObject,
public PropertyItem
{
Q_OBJECT
+ TQ_OBJECT
public:
PropertyFontItem( PropertyList *l, PropertyItem *after, PropertyItem *prop, const TQString &propName );
@@ -300,6 +306,7 @@ class PropertyCoordItem : public TQObject,
public PropertyItem
{
Q_OBJECT
+ TQ_OBJECT
public:
enum Type { Rect, Size, Point };
@@ -329,10 +336,11 @@ class PropertyColorItem : public TQObject,
public PropertyItem
{
Q_OBJECT
+ TQ_OBJECT
public:
PropertyColorItem( PropertyList *l, PropertyItem *after, PropertyItem *prop,
- const TQString &propName, bool children );
+ const TQString &propName, bool tqchildren );
~PropertyColorItem();
virtual void createChildren();
@@ -363,6 +371,7 @@ class PropertyPixmapItem : public TQObject,
public PropertyItem
{
Q_OBJECT
+ TQ_OBJECT
public:
PropertyPixmapItem( PropertyList *l, PropertyItem *after, PropertyItem *prop,
@@ -393,6 +402,7 @@ class PropertySizePolicyItem : public TQObject,
public PropertyItem
{
Q_OBJECT
+ TQ_OBJECT
public:
PropertySizePolicyItem( PropertyList *l, PropertyItem *after, PropertyItem *prop,
@@ -419,6 +429,7 @@ class PropertyPaletteItem : public TQObject,
public PropertyItem
{
Q_OBJECT
+ TQ_OBJECT
public:
PropertyPaletteItem( PropertyList *l, PropertyItem *after, PropertyItem *prop,
@@ -447,6 +458,7 @@ class PropertyCursorItem : public TQObject,
public PropertyItem
{
Q_OBJECT
+ TQ_OBJECT
public:
PropertyCursorItem( PropertyList *l, PropertyItem *after, PropertyItem *prop,
@@ -472,6 +484,7 @@ class PropertyDatabaseItem : public TQObject,
public PropertyItem
{
Q_OBJECT
+ TQ_OBJECT
public:
PropertyDatabaseItem( PropertyList *l, PropertyItem *after, PropertyItem *prop, const TQString &propName, bool wField );
@@ -495,9 +508,10 @@ private:
};
-class PropertyList : public QListView
+class PropertyList : public TQListView
{
Q_OBJECT
+ TQ_OBJECT
public:
PropertyList( PropertyEditor *e );
@@ -550,12 +564,13 @@ private:
};
-class PropertyEditor : public QTabWidget
+class PropertyEditor : public TQTabWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- PropertyEditor( TQWidget *parent );
+ PropertyEditor( TQWidget *tqparent );
TQObject *widget() const;
@@ -575,7 +590,7 @@ public:
TQString currentProperty() const;
TQString classOfCurrentProperty() const;
- TQMetaObject* metaObjectOfCurrentProperty() const;
+ TQMetaObject* tqmetaObjectOfCurrentProperty() const;
void resetFocus();
@@ -602,6 +617,7 @@ class PropertyDateItem : public TQObject,
public PropertyItem
{
Q_OBJECT
+ TQ_OBJECT
public:
PropertyDateItem( PropertyList *l, PropertyItem *after, PropertyItem *prop, const TQString &propName );
@@ -616,8 +632,8 @@ private slots:
void setValue();
private:
- QDateEdit *lined();
- TQGuardedPtr<QDateEdit> lin;
+ TQDateEdit *lined();
+ TQGuardedPtr<TQDateEdit> lin;
};
@@ -625,6 +641,7 @@ class PropertyTimeItem : public TQObject,
public PropertyItem
{
Q_OBJECT
+ TQ_OBJECT
public:
PropertyTimeItem( PropertyList *l, PropertyItem *after, PropertyItem *prop, const TQString &propName );
@@ -639,8 +656,8 @@ private slots:
void setValue();
private:
- QTimeEdit *lined();
- TQGuardedPtr<QTimeEdit> lin;
+ TQTimeEdit *lined();
+ TQGuardedPtr<TQTimeEdit> lin;
};
@@ -648,6 +665,7 @@ class PropertyDateTimeItem : public TQObject,
public PropertyItem
{
Q_OBJECT
+ TQ_OBJECT
public:
PropertyDateTimeItem( PropertyList *l, PropertyItem *after, PropertyItem *prop, const TQString &propName );
@@ -662,8 +680,8 @@ private slots:
void setValue();
private:
- QDateTimeEdit *lined();
- TQGuardedPtr<QDateTimeEdit> lin;
+ TQDateTimeEdit *lined();
+ TQGuardedPtr<TQDateTimeEdit> lin;
};
diff --git a/kommander/editor/qcompletionedit.cpp b/kommander/editor/qcompletionedit.cpp
index 4ba5e366..61d0407e 100644
--- a/kommander/editor/qcompletionedit.cpp
+++ b/kommander/editor/qcompletionedit.cpp
@@ -4,8 +4,8 @@
#include <tqapplication.h>
#include <tqvbox.h>
-QCompletionEdit::QCompletionEdit( TQWidget *parent, const char *name )
- : TQLineEdit( parent, name ), aAdd( false ), caseSensitive( false )
+QCompletionEdit::QCompletionEdit( TQWidget *tqparent, const char *name )
+ : TQLineEdit( tqparent, name ), aAdd( false ), caseSensitive( false )
{
popup = new TQVBox( 0, 0, WType_Popup );
popup->setFrameStyle( TQFrame::Box | TQFrame::Plain );
@@ -62,8 +62,8 @@ void QCompletionEdit::placeListBox()
return;
}
- popup->resize( QMAX( listbox->sizeHint().width() + listbox->verticalScrollBar()->width() + 4, width() ),
- listbox->sizeHint().height() + listbox->horizontalScrollBar()->height() + 4 );
+ popup->resize( TQMAX( listbox->tqsizeHint().width() + listbox->verticalScrollBar()->width() + 4, width() ),
+ listbox->tqsizeHint().height() + listbox->horizontalScrollBar()->height() + 4 );
TQPoint p( mapToGlobal( TQPoint( 0, 0 ) ) );
if ( p.y() + height() + popup->height() <= TQApplication::desktop()->height() )
@@ -90,7 +90,7 @@ void QCompletionEdit::updateListBox()
bool QCompletionEdit::eventFilter( TQObject *o, TQEvent *e )
{
- if ( o == popup || o == listbox || o == listbox->viewport() ) {
+ if ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(popup) || TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(listbox) || TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(listbox->viewport()) ) {
if ( e->type() == TQEvent::KeyPress ) {
TQKeyEvent *ke = (TQKeyEvent*)e;
if ( ke->key() == Key_Enter || ke->key() == Key_Return || ke->key() == Key_Tab ) {
@@ -133,7 +133,7 @@ bool QCompletionEdit::eventFilter( TQObject *o, TQEvent *e )
emit chosen( text() );
return true;
}
- } else if ( o == this ) {
+ } else if ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(this) ) {
if ( e->type() == TQEvent::KeyPress ) {
TQKeyEvent *ke = (TQKeyEvent*)e;
if ( ke->key() == Key_Up ||
@@ -154,7 +154,7 @@ bool QCompletionEdit::eventFilter( TQObject *o, TQEvent *e )
void QCompletionEdit::addCompletionEntry( const TQString &entry )
{
- if ( compList.find( entry ) == compList.end() ) {
+ if ( compList.tqfind( entry ) == compList.end() ) {
compList << entry;
compList.sort();
}
@@ -162,7 +162,7 @@ void QCompletionEdit::addCompletionEntry( const TQString &entry )
void QCompletionEdit::removeCompletionEntry( const TQString &entry )
{
- TQStringList::Iterator it = compList.find( entry );
+ TQStringList::Iterator it = compList.tqfind( entry );
if ( it != compList.end() )
compList.remove( it );
}
diff --git a/kommander/editor/qcompletionedit.h b/kommander/editor/qcompletionedit.h
index 169dacb5..4dee6ba5 100644
--- a/kommander/editor/qcompletionedit.h
+++ b/kommander/editor/qcompletionedit.h
@@ -1,5 +1,5 @@
-#ifndef QCOMPLETIONEDIT_H
-#define QCOMPLETIONEDIT_H
+#ifndef TQCOMPLETIONEDIT_H
+#define TQCOMPLETIONEDIT_H
#include <tqlineedit.h>
#include <tqstringlist.h>
@@ -7,14 +7,15 @@
class TQListBox;
class TQVBox;
-class QCompletionEdit : public QLineEdit
+class QCompletionEdit : public TQLineEdit
{
Q_OBJECT
- Q_PROPERTY( bool autoAdd READ autoAdd WRITE setAutoAdd )
- Q_PROPERTY( bool caseSensitive READ isCaseSensitive WRITE setCaseSensitive )
+ TQ_OBJECT
+ TQ_PROPERTY( bool autoAdd READ autoAdd WRITE setAutoAdd )
+ TQ_PROPERTY( bool caseSensitive READ isCaseSensitive WRITE setCaseSensitive )
public:
- QCompletionEdit( TQWidget *parent = 0, const char *name = 0 );
+ QCompletionEdit( TQWidget *tqparent = 0, const char *name = 0 );
bool autoAdd() const;
TQStringList completionList() const;
diff --git a/kommander/editor/resource.cpp b/kommander/editor/resource.cpp
index d1c93cea..02cd1eec 100644
--- a/kommander/editor/resource.cpp
+++ b/kommander/editor/resource.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -27,11 +27,11 @@
#include "tqdom.h"
#include "widgetdatabase.h"
#include "widgetfactory.h"
-#include "layout.h"
+#include "tqlayout.h"
#include "domtool.h"
#include "command.h"
#include "pixmapchooser.h"
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
#include "database.h"
#endif
#include "actiondnd.h"
@@ -68,7 +68,7 @@
#include <tqregexp.h>
#include <zlib.h>
#include <tqdatetime.h>
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
#include <tqtable.h>
#endif
@@ -84,12 +84,12 @@ static TQString makeIndent( int indent )
static TQString entitize( const TQString &s, bool attribute = false )
{
TQString s2 = s;
- s2 = s2.replace( TQRegExp( "&" ), "&amp;" );
- s2 = s2.replace( TQRegExp( ">" ), "&gt;" );
- s2 = s2.replace( TQRegExp( "<" ), "&lt;" );
+ s2 = s2.tqreplace( TQRegExp( "&" ), "&amp;" );
+ s2 = s2.tqreplace( TQRegExp( ">" ), "&gt;" );
+ s2 = s2.tqreplace( TQRegExp( "<" ), "&lt;" );
if ( attribute ) {
- s2 = s2.replace( TQRegExp( "\"" ), "&quot;" );
- s2 = s2.replace( TQRegExp( "'" ), "&apos;" );
+ s2 = s2.tqreplace( TQRegExp( "\"" ), "&quot;" );
+ s2 = s2.tqreplace( TQRegExp( "'" ), "&apos;" );
}
return s2;
}
@@ -166,7 +166,7 @@ bool Resource::load( FormFile *ff )
TQFile f( ff->absFileName() );
f.open( IO_ReadOnly );
- bool b = load( ff, &f );
+ bool b = load( ff, TQT_TQIODEVICE(&f) );
f.close();
return b;
@@ -181,7 +181,7 @@ bool Resource::load( FormFile *ff, TQIODevice* dev )
TQString content = stream.read();
if (content.startsWith("#!"))
{
- content = content.mid(content.find('\n'));
+ content = content.mid(content.tqfind('\n'));
}
if ( !doc.setContent( content) ) {
// qDebug( TQString("Parse error: ") + errMsg + TQString(" in line %d"), errLine );
@@ -195,7 +195,7 @@ bool Resource::load( FormFile *ff, TQIODevice* dev )
formwindow->setProject( MainWindow::self->currProject() );
#endif
formwindow->setMainWindow( mainwindow );
- MetaDataBase::addEntry( formwindow );
+ MetaDataBase::addEntry( TQT_TQOBJECT(formwindow) );
#ifndef KOMMANDER
if (!langIface) {
@@ -290,9 +290,9 @@ bool Resource::load( FormFile *ff, TQIODevice* dev )
metaInfo.license = e.firstChild().toText().data();
} else if ( e.tagName() == "exportmacro" ) {
exportMacro = e.firstChild().toText().data();
- } else if ( e.tagName() == "layoutdefaults" ) {
- formwindow->setLayoutDefaultSpacing( e.attribute( "spacing", TQString::number( formwindow->layoutDefaultSpacing() ) ).toInt() );
- formwindow->setLayoutDefaultMargin( e.attribute( "margin", TQString::number( formwindow->layoutDefaultMargin() ) ).toInt() );
+ } else if ( e.tagName() == "tqlayoutdefaults" ) {
+ formwindow->setLayoutDefaultSpacing( e.attribute( "spacing", TQString::number( formwindow->tqlayoutDefaultSpacing() ) ).toInt() );
+ formwindow->setLayoutDefaultMargin( e.attribute( "margin", TQString::number( formwindow->tqlayoutDefaultMargin() ) ).toInt() );
}
e = e.nextSibling().toElement();
@@ -303,13 +303,13 @@ bool Resource::load( FormFile *ff, TQIODevice* dev )
if ( !customWidgets.isNull() )
loadCustomWidgets( customWidgets, this );
-#if defined (QT_NON_COMMERCIAL)
+#if defined (TQT_NON_COMMERCIAL)
bool previewMode = MainWindow::self->isPreviewing();
TQWidget *w = (TQWidget*)createObject( widget, !previewMode ? (TQWidget*)formwindow : MainWindow::self);
if ( !w )
return false;
if ( previewMode )
- w->reparent( MainWindow::self, Qt::WType_TopLevel, w->pos(), true );
+ w->reparent( MainWindow::self, TQt::WType_TopLevel, w->pos(), true );
#else
if ( !createObject( widget, formwindow) )
return false;
@@ -364,11 +364,11 @@ bool Resource::load( FormFile *ff, TQIODevice* dev )
if ( slot.returnType.isEmpty() )
slot.returnType = "void";
slot.slot = n.firstChild().toText().data();
- if ( !MetaDataBase::hasSlot( formwindow, slot.slot, true ) )
- MetaDataBase::addSlot( formwindow, slot.slot, slot.specifier,
+ if ( !MetaDataBase::hasSlot( TQT_TQOBJECT(formwindow), slot.slot, true ) )
+ MetaDataBase::addSlot( TQT_TQOBJECT(formwindow), slot.slot, slot.specifier,
slot.access, slot.language, slot.returnType );
else
- MetaDataBase::changeSlotAttributes( formwindow, slot.slot,
+ MetaDataBase::changeSlotAttributes( TQT_TQOBJECT(formwindow), slot.slot,
slot.specifier, slot.access,
slot.language, slot.returnType );
}
@@ -386,11 +386,11 @@ bool Resource::load( FormFile *ff, TQIODevice* dev )
loadTabOrder( tabOrder );
if ( formwindow ) {
- MetaDataBase::setIncludes( formwindow, metaIncludes );
- MetaDataBase::setForwards( formwindow, metaForwards );
- MetaDataBase::setSignalList( formwindow, metaSignals );
- MetaDataBase::setMetaInfo( formwindow, metaInfo );
- MetaDataBase::setExportMacro( formwindow->mainContainer(), exportMacro );
+ MetaDataBase::setIncludes( TQT_TQOBJECT(formwindow), metaIncludes );
+ MetaDataBase::setForwards( TQT_TQOBJECT(formwindow), metaForwards );
+ MetaDataBase::setSignalList( TQT_TQOBJECT(formwindow), metaSignals );
+ MetaDataBase::setMetaInfo( TQT_TQOBJECT(formwindow), metaInfo );
+ MetaDataBase::setExportMacro( TQT_TQOBJECT(formwindow->mainContainer()), exportMacro );
}
@@ -400,14 +400,14 @@ bool Resource::load( FormFile *ff, TQIODevice* dev )
}
if ( formwindow ) {
- formwindow->killAccels( formwindow );
- if ( formwindow->layout() )
- formwindow->layout()->activate();
+ formwindow->killAccels( TQT_TQOBJECT(formwindow) );
+ if ( formwindow->tqlayout() )
+ formwindow->tqlayout()->activate();
if ( hadGeometry )
- formwindow->resize( formwindow->size().expandedTo( formwindow->minimumSize().
- expandedTo( formwindow->minimumSizeHint() ) ) );
+ formwindow->resize( formwindow->size().expandedTo( formwindow->tqminimumSize().
+ expandedTo( formwindow->tqminimumSizeHint() ) ) );
else
- formwindow->resize( formwindow->size().expandedTo( formwindow->sizeHint() ) );
+ formwindow->resize( formwindow->size().expandedTo( formwindow->tqsizeHint() ) );
}
return true;
@@ -422,7 +422,7 @@ bool Resource::save( const TQString& filename, bool formCodeOnly )
TQFile f( filename );
if ( !f.open( IO_WriteOnly | IO_Translate ) )
return false;
- bool b = save( &f );
+ bool b = save( TQT_TQIODEVICE(&f) );
f.close();
return b;
}
@@ -439,7 +439,7 @@ bool Resource::save( TQIODevice* dev )
ts << formwindow->mainContainer()->property("shebang").toString() << endl;
ts << "<!DOCTYPE UI><UI version=\"3.0\" stdsetdef=\"1\">" << endl;
saveMetaInfoBefore( ts, 0 );
- saveObject( formwindow->mainContainer(), 0, ts, 0 );
+ saveObject( TQT_TQOBJECT(formwindow->mainContainer()), 0, ts, 0 );
if ( formwindow->mainContainer()->inherits( TQMAINWINDOW_OBJECT_NAME_STRING ) ) {
saveMenuBar( (TQMainWindow*)formwindow->mainContainer(), ts, 0 );
saveToolBars( (TQMainWindow*)formwindow->mainContainer(), ts, 0 );
@@ -450,7 +450,7 @@ bool Resource::save( TQIODevice* dev )
saveActions( formwindow->actionList(), ts, 0 );
if ( !images.isEmpty() )
saveImageCollection( ts, 0 );
- if ( !MetaDataBase::connections( formwindow ).isEmpty() || !MetaDataBase::slotList( formwindow ).isEmpty() )
+ if ( !MetaDataBase::connections( TQT_TQOBJECT(formwindow) ).isEmpty() || !MetaDataBase::slotList( TQT_TQOBJECT(formwindow) ).isEmpty() )
saveConnections( ts, 0 );
saveTabOrder( ts, 0 );
saveMetaInfoAfter( ts, 0 );
@@ -463,7 +463,7 @@ bool Resource::save( TQIODevice* dev )
TQString Resource::copy()
{
if ( !formwindow )
- return TQString::null;
+ return TQString();
copying = true;
TQString s;
@@ -473,17 +473,17 @@ TQString Resource::copy()
TQWidgetList widgets = formwindow->selectedWidgets();
TQWidgetList tmp( widgets );
for ( TQWidget *w = widgets.first(); w; w = widgets.next() ) {
- TQWidget *p = w->parentWidget();
+ TQWidget *p = w->tqparentWidget();
bool save = true;
while ( p ) {
- if ( tmp.findRef( p ) != -1 ) {
+ if ( tmp.tqfindRef( p ) != -1 ) {
save = false;
break;
}
- p = p->parentWidget();
+ p = p->tqparentWidget();
}
if ( save )
- saveObject( w, 0, ts, 0 );
+ saveObject( TQT_TQOBJECT(w), 0, ts, 0 );
}
if ( !MetaDataBase::customWidgets()->isEmpty() && !usedCustomWidgets.isEmpty() )
saveCustomWidgets( ts, 0 );
@@ -495,7 +495,7 @@ TQString Resource::copy()
}
-void Resource::paste( const TQString &cb, TQWidget *parent )
+void Resource::paste( const TQString &cb, TQWidget *tqparent )
{
if ( !formwindow )
return;
@@ -533,33 +533,33 @@ void Resource::paste( const TQString &cb, TQWidget *parent )
formwindow->clearSelection( false );
while ( !firstWidget.isNull() ) {
if ( firstWidget.tagName() == "widget" ) {
- TQWidget *w = (TQWidget*)createObject( firstWidget, parent, 0 );
+ TQWidget *w = (TQWidget*)createObject( firstWidget, tqparent, 0 );
if ( !w )
continue;
widgets.append( w );
int x = w->x() + formwindow->grid().x();
int y = w->y() + formwindow->grid().y();
- if ( w->x() + w->width() > parent->width() )
- x = QMAX( 0, parent->width() - w->width() );
- if ( w->y() + w->height() > parent->height() )
- y = QMAX( 0, parent->height() - w->height() );
+ if ( w->x() + w->width() > tqparent->width() )
+ x = TQMAX( 0, tqparent->width() - w->width() );
+ if ( w->y() + w->height() > tqparent->height() )
+ y = TQMAX( 0, tqparent->height() - w->height() );
if ( x != w->x() || y != w->y() )
w->move( x, y );
- formwindow->selectWidget( w );
+ formwindow->selectWidget( TQT_TQOBJECT(w) );
} else if ( firstWidget.tagName() == "spacer" ) {
- TQWidget *w = createSpacer( firstWidget, parent, 0, firstWidget.tagName() == "vspacer" ? Qt::Vertical : Qt::Horizontal );
+ TQWidget *w = createSpacer( firstWidget, tqparent, 0, firstWidget.tagName() == "vspacer" ? Qt::Vertical : Qt::Horizontal );
if ( !w )
continue;
widgets.append( w );
int x = w->x() + formwindow->grid().x();
int y = w->y() + formwindow->grid().y();
- if ( w->x() + w->width() > parent->width() )
- x = QMAX( 0, parent->width() - w->width() );
- if ( w->y() + w->height() > parent->height() )
- y = QMAX( 0, parent->height() - w->height() );
+ if ( w->x() + w->width() > tqparent->width() )
+ x = TQMAX( 0, tqparent->width() - w->width() );
+ if ( w->y() + w->height() > tqparent->height() )
+ y = TQMAX( 0, tqparent->height() - w->height() );
if ( x != w->x() || y != w->y() )
w->move( x, y );
- formwindow->selectWidget( w );
+ formwindow->selectWidget( TQT_TQOBJECT(w) );
}
firstWidget = firstWidget.nextSibling().toElement();
}
@@ -571,7 +571,7 @@ void Resource::paste( const TQString &cb, TQWidget *parent )
formwindow->commandHistory()->addCommand( cmd );
}
-void Resource::saveObject( TQObject *obj, QDesignerGridLayout* grid, TQTextStream &ts, int indent )
+void Resource::saveObject( TQObject *obj, TQDesignerGridLayout* grid, TQTextStream &ts, int indent )
{
if ( obj && obj->isWidgetType() && ( (TQWidget*)obj )->isHidden() && !(obj->isA("ScriptObject")) )
return;
@@ -580,12 +580,12 @@ void Resource::saveObject( TQObject *obj, QDesignerGridLayout* grid, TQTextStrea
const char* className = WidgetFactory::classNameOf( obj );
if ( obj->isA( "CustomWidget" ) )
usedCustomWidgets << TQString( className );
- if ( obj != formwindow && !formwindow->widgets()->find( (TQWidget*)obj ) )
+ if ( TQT_BASE_OBJECT(obj) != TQT_BASE_OBJECT(formwindow) && !formwindow->widgets()->tqfind( (TQWidget*)obj ) )
return; // we don't know anything about this thing
TQString attributes;
if ( grid ) {
- QDesignerGridLayout::Item item = grid->items[ (TQWidget*)obj ];
+ TQDesignerGridLayout::Item item = grid->items[ (TQWidget*)obj ];
attributes += TQString(" row=\"") + TQString::number(item.row) + "\"";
attributes += TQString(" column=\"") + TQString::number(item.column) + "\"";
if ( item.rowspan * item.colspan != 1 ) {
@@ -601,7 +601,7 @@ void Resource::saveObject( TQObject *obj, QDesignerGridLayout* grid, TQTextStrea
} else {
closeTag = makeIndent( indent ) + "</widget>\n";
if ( qstrcmp( className, "KmdrMainWindow" ) == 0 ) {
- ts << makeIndent( indent ) << "<widget class=\"QMainWindow\"" << attributes << ">" << endl;
+ ts << makeIndent( indent ) << "<widget class=\"TQMainWindow\"" << attributes << ">" << endl;
} else {
ts << makeIndent( indent ) << "<widget class=\"" << className << "\"" << attributes << ">" << endl;
}
@@ -619,7 +619,7 @@ void Resource::saveObject( TQObject *obj, QDesignerGridLayout* grid, TQTextStrea
TQTabWidget* tw = (TQTabWidget*) obj;
TQObjectList* tmpl = tw->queryList( TQWIDGETSTACK_OBJECT_NAME_STRING );
TQWidgetStack *ws = (TQWidgetStack*)tmpl->first();
- TQTabBar *tb = ( (QDesignerTabWidget*)obj )->tabBar();
+ TQTabBar *tb = ( (TQDesignerTabWidget*)obj )->tabBar();
for ( int i = 0; i < tb->count(); ++i ) {
TQTab *t = tb->tabAt( i );
if ( !t )
@@ -627,9 +627,9 @@ void Resource::saveObject( TQObject *obj, QDesignerGridLayout* grid, TQTextStrea
TQWidget *w = ws->widget( t->identifier() );
if ( !w )
continue;
- if ( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( w ) ) == -1 )
+ if ( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( TQT_TQOBJECT(w) ) ) == -1 )
continue; // we don't know this widget
- ts << makeIndent( indent ) << "<widget class=\"QWidget\">" << endl;
+ ts << makeIndent( indent ) << "<widget class=\"TQWidget\">" << endl;
++indent;
ts << makeIndent( indent ) << "<property name=\"name\">" << endl;
indent++;
@@ -642,21 +642,21 @@ void Resource::saveObject( TQObject *obj, QDesignerGridLayout* grid, TQTextStrea
ts << makeIndent( indent ) << "<string>" << entitize( t->text() ) << "</string>" << endl;
indent--;
ts << makeIndent( indent ) << "</attribute>" << endl;
- saveChildrenOf( w, ts, indent );
+ saveChildrenOf( TQT_TQOBJECT(w), ts, indent );
--indent;
ts << makeIndent( indent ) << "</widget>" << endl;
}
delete tmpl;
} else
- if ( ::qt_cast<TQToolBox*>(obj) ) {
+ if ( ::tqqt_cast<TQToolBox*>(obj) ) {
TQToolBox* tb = (TQToolBox*)obj;
for ( int i = 0; i < tb->count(); ++i ) {
TQWidget *w = tb->item( i );
if ( !w )
continue;
- if ( WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(w)) == -1 )
+ if ( WidgetDatabase::idFromClassName(WidgetFactory::classNameOf(TQT_TQOBJECT(w))) == -1 )
continue; // we don't know this widget
- ts << makeIndent( indent ) << "<widget class=\"QWidget\">" << endl;
+ ts << makeIndent( indent ) << "<widget class=\"TQWidget\">" << endl;
++indent;
ts << makeIndent( indent ) << "<property name=\"name\">" << endl;
indent++;
@@ -665,7 +665,7 @@ void Resource::saveObject( TQObject *obj, QDesignerGridLayout* grid, TQTextStrea
ts << makeIndent( indent ) << "</property>" << endl;
ts << makeIndent( indent ) << "<property name=\"backgroundMode\">" << endl;
indent++;
- saveEnumProperty( w, "backgroundMode", TQVariant::Invalid, ts, indent );
+ saveEnumProperty( TQT_TQOBJECT(w), "backgroundMode", TQVariant::Invalid, ts, indent );
indent--;
ts << makeIndent( indent ) << "</property>" << endl;
ts << makeIndent( indent ) << "<attribute name=\"label\">" << endl;
@@ -673,7 +673,7 @@ void Resource::saveObject( TQObject *obj, QDesignerGridLayout* grid, TQTextStrea
ts << makeIndent( indent ) << "<string>" << entitize( tb->itemLabel( tb->indexOf(w) ) ) << "</string>" << endl;
indent--;
ts << makeIndent( indent ) << "</attribute>" << endl;
- saveChildrenOf( w, ts, indent );
+ saveChildrenOf( TQT_TQOBJECT(w), ts, indent );
--indent;
ts << makeIndent( indent ) << "</widget>" << endl;
}
@@ -683,9 +683,9 @@ void Resource::saveObject( TQObject *obj, QDesignerGridLayout* grid, TQTextStrea
TQWidget *w = wiz->page( i );
if ( !w )
continue;
- if ( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( w ) ) == -1 )
+ if ( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( TQT_TQOBJECT(w) ) ) == -1 )
continue; // we don't know this widget
- ts << makeIndent( indent ) << "<widget class=\"QWidget\">" << endl;
+ ts << makeIndent( indent ) << "<widget class=\"TQWidget\">" << endl;
++indent;
ts << makeIndent( indent ) << "<property name=\"name\">" << endl;
indent++;
@@ -698,12 +698,12 @@ void Resource::saveObject( TQObject *obj, QDesignerGridLayout* grid, TQTextStrea
ts << makeIndent( indent ) << "<string>" << entitize( wiz->title( w ) ) << "</string>" << endl;
indent--;
ts << makeIndent( indent ) << "</attribute>" << endl;
- saveChildrenOf( w, ts, indent );
+ saveChildrenOf( TQT_TQOBJECT(w), ts, indent );
--indent;
ts << makeIndent( indent ) << "</widget>" << endl;
}
} else if ( obj->inherits( TQMAINWINDOW_OBJECT_NAME_STRING ) ) {
- saveChildrenOf( ( (TQMainWindow*)obj )->centralWidget(), ts, indent );
+ saveChildrenOf( TQT_TQOBJECT(( (TQMainWindow*)obj )->centralWidget()), ts, indent );
} else {
saveChildrenOf( obj, ts, indent );
}
@@ -778,11 +778,11 @@ void Resource::saveItems( TQObject *obj, TQTextStream &ts, int indent )
}
saveItem( lv->firstChild(), ts, indent - 1 );
}
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
else if ( obj->inherits( TQTABLE_OBJECT_NAME_STRING ) ) {
TQTable *table = (TQTable*)obj;
int i;
- TQMap<TQString, TQString> columnFields = MetaDataBase::columnFields( table );
+ TQMap<TQString, TQString> columnFields = MetaDataBase::columnFields( TQT_TQOBJECT(table) );
bool isDataTable = table->inherits( TQDATATABLE_OBJECT_NAME_STRING );
for ( i = 0; i < table->horizontalHeader()->count(); ++i ) {
if ( !table->horizontalHeader()->label( i ).isNull() &&
@@ -801,7 +801,7 @@ void Resource::saveItems( TQObject *obj, TQTextStream &ts, int indent )
if ( table->inherits( TQDATATABLE_OBJECT_NAME_STRING ) && !columnFields.isEmpty() ) {
ts << makeIndent( indent ) << "<property name=\"field\">" << endl;
indent++;
- ts << makeIndent( indent ) << "<string>" << entitize( *columnFields.find( l[ 0 ] ) ) << "</string>" << endl;
+ ts << makeIndent( indent ) << "<string>" << entitize( *columnFields.tqfind( l[ 0 ] ) ) << "</string>" << endl;
indent--;
ts << makeIndent( indent ) << "</property>" << endl;
}
@@ -865,11 +865,11 @@ void Resource::savePixmap( const TQPixmap &p, TQTextStream &ts, int indent, cons
ts << makeIndent( indent ) << "<" + tagname + ">" << saveInCollection( p ) << "</" + tagname + ">" << endl;
#ifndef KOMMANDER
else if ( formwindow && formwindow->savePixmapInProject() )
- ts << makeIndent( indent ) << "<" + tagname + ">" << MetaDataBase::pixmapKey( formwindow, p.serialNumber() )
+ ts << makeIndent( indent ) << "<" + tagname + ">" << MetaDataBase::pixmapKey( TQT_TQOBJECT(formwindow), p.serialNumber() )
<< "</" + tagname + ">" << endl;
#endif
else
- ts << makeIndent( indent ) << "<" + tagname + ">" << MetaDataBase::pixmapArgument( formwindow, p.serialNumber() )
+ ts << makeIndent( indent ) << "<" + tagname + ">" << MetaDataBase::pixmapArgument( TQT_TQOBJECT(formwindow), p.serialNumber() )
<< "</" + tagname + ">" << endl;
}
@@ -881,7 +881,7 @@ TQPixmap Resource::loadPixmap( const TQDomElement &e, const TQString &/*tagname*
TQImage img = loadFromCollection( arg );
TQPixmap pix;
pix.convertFromImage( img );
- MetaDataBase::setPixmapArgument( formwindow, pix.serialNumber(), arg );
+ MetaDataBase::setPixmapArgument( TQT_TQOBJECT(formwindow), pix.serialNumber(), arg );
return pix;
}
#ifndef KOMMANDER
@@ -895,11 +895,11 @@ TQPixmap Resource::loadPixmap( const TQDomElement &e, const TQString &/*tagname*
{
TQPixmap pix;
pix = PixmapChooser::loadPixmap( "image.xpm" );
- MetaDataBase::setPixmapKey( formwindow, pix.serialNumber(), arg );
+ MetaDataBase::setPixmapKey( TQT_TQOBJECT(formwindow), pix.serialNumber(), arg );
return pix;
}
TQPixmap pix = PixmapChooser::loadPixmap( "image.xpm" );
- MetaDataBase::setPixmapArgument( formwindow, pix.serialNumber(), arg );
+ MetaDataBase::setPixmapArgument( TQT_TQOBJECT(formwindow), pix.serialNumber(), arg );
return pix;
}
@@ -929,19 +929,19 @@ void Resource::saveItem( const TQStringList &text, const TQPtrList<TQPixmap> &pi
void Resource::saveChildrenOf( TQObject* obj, TQTextStream &ts, int indent )
{
- const TQObjectList *l = obj->children();
- if ( !l )
- return; // no children to save
+ const TQObjectList l = obj->childrenListObject();
+ if ( l.isEmpty() )
+ return; // no tqchildren to save
TQString closeTag;
- // if the widget has a layout we pretend that all widget's childs are childs of the layout - makes the structure nicer
- TQLayout *layout = 0;
- QDesignerGridLayout* grid = 0;
+ // if the widget has a tqlayout we pretend that all widget's childs are childs of the tqlayout - makes the structure nicer
+ TQLayout *tqlayout = 0;
+ TQDesignerGridLayout* grid = 0;
if ( !obj->inherits( TQSPLITTER_OBJECT_NAME_STRING ) &&
WidgetDatabase::isContainer( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( obj ) ) ) &&
obj->isWidgetType() &&
- WidgetFactory::layoutType( (TQWidget*)obj, layout ) != WidgetFactory::NoLayout ) {
- WidgetFactory::LayoutType lay = WidgetFactory::layoutType( (TQWidget*)obj, layout );
+ WidgetFactory::tqlayoutType( (TQWidget*)obj, tqlayout ) != WidgetFactory::NoLayout ) {
+ WidgetFactory::LayoutType lay = WidgetFactory::tqlayoutType( (TQWidget*)obj, tqlayout );
switch ( lay ) {
case WidgetFactory::HBox:
closeTag = makeIndent( indent ) + "</hbox>";
@@ -957,19 +957,19 @@ void Resource::saveChildrenOf( TQObject* obj, TQTextStream &ts, int indent )
closeTag = makeIndent( indent ) + "</grid>";
ts << makeIndent( indent ) << "<grid>" << endl;
++indent;
- grid = (QDesignerGridLayout*) layout;
+ grid = (TQDesignerGridLayout*) tqlayout;
break;
default:
break;
}
- // save properties of layout
+ // save properties of tqlayout
if ( lay != WidgetFactory::NoLayout )
- saveObjectProperties( layout, ts, indent );
+ saveObjectProperties( TQT_TQOBJECT(tqlayout), ts, indent );
}
- for ( TQPtrListIterator<TQObject> it ( *l ); it.current(); ++it )
+ for ( TQPtrListIterator<TQObject> it ( l ); it.current(); ++it )
saveObject( it.current(), grid, ts, indent );
if ( !closeTag.isEmpty() ) {
indent--;
@@ -984,43 +984,43 @@ void Resource::saveObjectProperties( TQObject *w, TQTextStream &ts, int indent )
changed = MetaDataBase::changedProperties( w );
if ( w->isWidgetType() ) {
if ( w->inherits( "Spacer" ) ) {
- if ( !changed.contains( "sizeHint" ) )
- changed << "sizeHint";
- if ( !changed.contains( "geometry" ) )
+ if ( !changed.tqcontains( "tqsizeHint" ) )
+ changed << "tqsizeHint";
+ if ( !changed.tqcontains( "geometry" ) )
changed << "geometry";
}
} else if ( w->inherits( TQLAYOUT_OBJECT_NAME_STRING ) ) { // #### should be cleaner (RS)
changed << "margin" << "spacing";
}
- if ( w == formwindow->mainContainer() ) {
- if ( changed.findIndex( "geometry" ) == -1 )
+ if ( TQT_BASE_OBJECT(w) == TQT_BASE_OBJECT(formwindow->mainContainer()) ) {
+ if ( changed.tqfindIndex( "geometry" ) == -1 )
changed << "geometry";
- if ( changed.findIndex( "caption" ) == -1 )
+ if ( changed.tqfindIndex( "caption" ) == -1 )
changed << "caption";
}
if ( changed.isEmpty() )
return;
- bool inLayout = w != formwindow->mainContainer() && !copying && w->isWidgetType() && ( (TQWidget*)w )->parentWidget() &&
- WidgetFactory::layoutType( ( (TQWidget*)w )->parentWidget() ) != WidgetFactory::NoLayout;
+ bool inLayout = TQT_BASE_OBJECT(w) != TQT_BASE_OBJECT(formwindow->mainContainer()) && !copying && w->isWidgetType() && ( (TQWidget*)w )->tqparentWidget() &&
+ WidgetFactory::tqlayoutType( ( (TQWidget*)w )->tqparentWidget() ) != WidgetFactory::NoLayout;
- TQStrList lst = w->metaObject()->propertyNames( !w->inherits( "Spacer" ) );
+ TQStrList lst = w->tqmetaObject()->propertyNames( !w->inherits( "Spacer" ) );
for ( TQPtrListIterator<char> it( lst ); it.current(); ++it ) {
- if ( changed.find( TQString::fromLatin1( it.current() ) ) == changed.end() )
+ if ( changed.tqfind( TQString::tqfromLatin1( it.current() ) ) == changed.end() )
continue;
- if ( saved.find( TQString::fromLatin1( it.current() ) ) != saved.end() )
+ if ( saved.tqfind( TQString::tqfromLatin1( it.current() ) ) != saved.end() )
continue;
- saved << TQString::fromLatin1( it.current() );
- const TQMetaProperty* p = w->metaObject()->
- property( w->metaObject()->findProperty( it.current(), true ), true );
+ saved << TQString::tqfromLatin1( it.current() );
+ const TQMetaProperty* p = w->tqmetaObject()->
+ property( w->tqmetaObject()->tqfindProperty( it.current(), true ), true );
if ( !p || !p->stored( w ) || ( inLayout && qstrcmp( p->name(), "geometry" ) == 0 ) )
continue;
if ( w->inherits( TQLABEL_OBJECT_NAME_STRING ) && qstrcmp( p->name(), "pixmap" ) == 0 &&
( !( (TQLabel*)w )->pixmap() || ( (TQLabel*)w )->pixmap()->isNull() ) )
continue;
- if ( w->inherits( "QDesignerMenuBar" ) &&
+ if ( w->inherits( "TQDesignerMenuBar" ) &&
( qstrcmp( p->name(), "itemName" ) == 0 || qstrcmp( p->name(), "itemNumber" ) == 0 ||
qstrcmp( p->name(), "itemText" ) == 0 ) )
continue;
@@ -1066,7 +1066,7 @@ void Resource::saveObjectProperties( TQObject *w, TQTextStream &ts, int indent )
void Resource::saveSetProperty( TQObject *w, const TQString &name, TQVariant::Type, TQTextStream &ts, int indent )
{
- const TQMetaProperty *p = w->metaObject()->property( w->metaObject()->findProperty( name, true ), true );
+ const TQMetaProperty *p = w->tqmetaObject()->property( w->tqmetaObject()->tqfindProperty( name, true ), true );
TQStrList l( p->valueToKeys( w->property( name ).toInt() ) );
TQString v;
for ( uint i = 0; i < l.count(); ++i ) {
@@ -1079,18 +1079,18 @@ void Resource::saveSetProperty( TQObject *w, const TQString &name, TQVariant::Ty
void Resource::saveEnumProperty( TQObject *w, const TQString &name, TQVariant::Type, TQTextStream &ts, int indent )
{
- const TQMetaProperty *p = w->metaObject()->property( w->metaObject()->findProperty( name, true ), true );
+ const TQMetaProperty *p = w->tqmetaObject()->property( w->tqmetaObject()->tqfindProperty( name, true ), true );
ts << makeIndent( indent ) << "<enum>" << p->valueToKey( w->property( name ).toInt() ) << "</enum>" << endl;
}
void Resource::saveProperty( TQObject *w, const TQString &name, const TQVariant &value, TQVariant::Type t, TQTextStream &ts, int indent )
{
- if ( name == "hAlign" || name =="vAlign" || name == "wordwrap" || name == "layoutMargin" || name =="layoutSpacing" )
+ if ( name == "hAlign" || name =="vAlign" || name == "wordwrap" || name == "tqlayoutMargin" || name =="tqlayoutSpacing" )
return;
int num, unum;
double dob;
TQString comment;
- if ( w && formwindow->widgets()->find( (TQWidget*)w ) )
+ if ( w && formwindow->widgets()->tqfind( (TQWidget*)w ) )
comment = MetaDataBase::propertyComment( w, name );
switch ( t ) {
case TQVariant::String:
@@ -1108,9 +1108,9 @@ void Resource::saveProperty( TQObject *w, const TQString &name, const TQVariant
num = value.toInt();
if ( w && w->inherits( TQLAYOUT_OBJECT_NAME_STRING ) ) {
if ( name == "spacing" )
- num = MetaDataBase::spacing( WidgetFactory::containerOfWidget( WidgetFactory::layoutParent( (TQLayout*)w ) ) );
+ num = MetaDataBase::spacing( TQT_TQOBJECT(WidgetFactory::containerOfWidget( WidgetFactory::tqlayoutParent( TQT_TQLAYOUT(TQT_BASE_OBJECT(w)) ) )) );
else if ( name == "margin" )
- num = MetaDataBase::margin( WidgetFactory::containerOfWidget( WidgetFactory::layoutParent( (TQLayout*)w ) ) );
+ num = MetaDataBase::margin( TQT_TQOBJECT(WidgetFactory::containerOfWidget( WidgetFactory::tqlayoutParent( TQT_TQLAYOUT(TQT_BASE_OBJECT(w)) ) )) );
}
ts << makeIndent( indent ) << "<number>" << TQString::number( num ) << "</number>" << endl;
break;
@@ -1126,9 +1126,9 @@ void Resource::saveProperty( TQObject *w, const TQString &name, const TQVariant
unum = value.toUInt();
if ( w && w->inherits( TQLAYOUT_OBJECT_NAME_STRING ) ) {
if ( name == "spacing" )
- num = MetaDataBase::spacing( WidgetFactory::layoutParent( (TQLayout*)w ) );
+ num = MetaDataBase::spacing( TQT_TQOBJECT(WidgetFactory::tqlayoutParent( TQT_TQLAYOUT(TQT_BASE_OBJECT(w)) )) );
else if ( name == "margin" )
- num = MetaDataBase::margin( WidgetFactory::layoutParent( (TQLayout*)w ) );
+ num = MetaDataBase::margin( TQT_TQOBJECT(WidgetFactory::tqlayoutParent( TQT_TQLAYOUT(TQT_BASE_OBJECT(w)) )) );
}
ts << makeIndent( indent ) << "<number>" << TQString::number( unum ) << "</number>" << endl;
break;
@@ -1172,9 +1172,9 @@ void Resource::saveProperty( TQObject *w, const TQString &name, const TQVariant
case TQVariant::Font: {
TQVariant v( value );
ts << makeIndent( indent ) << "<font>" << endl;
- TQFont f( qApp->font() );
- if ( w && w->isWidgetType() && ((TQWidget*)w)->parentWidget() )
- f = ((TQWidget*)w)->parentWidget()->font();
+ TQFont f( tqApp->font() );
+ if ( w && w->isWidgetType() && ((TQWidget*)w)->tqparentWidget() )
+ f = ((TQWidget*)w)->tqparentWidget()->font();
TQFont f2( v.toFont() );
indent++;
if ( f.family() != f2.family() )
@@ -1240,7 +1240,7 @@ void Resource::saveProperty( TQObject *w, const TQString &name, const TQVariant
ts << makeIndent( indent ) << "</palette>" << endl;
} break;
case TQVariant::Cursor:
- ts << makeIndent( indent ) << "<cursor>" << value.toCursor().shape() << "</cursor>" << endl;
+ ts << makeIndent( indent ) << "<cursor>" << value.toCursor().tqshape() << "</cursor>" << endl;
break;
case TQVariant::StringList: {
TQStringList lst = value.toStringList();
@@ -1303,7 +1303,7 @@ void Resource::saveColorGroup( TQTextStream &ts, int indent, const TQColorGroup
saveColor( ts, indent, cg.color( (TQColorGroup::ColorRole)r ) );
indent--;
ts << makeIndent( indent ) << "</color>" << endl;
- TQPixmap* pm = cg.brush( (TQColorGroup::ColorRole)r ).pixmap();
+ TQPixmap* pm = cg.tqbrush( (TQColorGroup::ColorRole)r ).pixmap();
if ( pm && !pm->isNull() )
savePixmap( *pm, ts, indent );
}
@@ -1316,7 +1316,7 @@ void Resource::saveColor( TQTextStream &ts, int indent, const TQColor &c )
ts << makeIndent( indent ) << "<blue>" << TQString::number( c.blue() ) << "</blue>" << endl;
}
-TQObject *Resource::createObject( const TQDomElement &e, TQWidget *parent, TQLayout* layout )
+TQObject *Resource::createObject( const TQDomElement &e, TQWidget *tqparent, TQLayout* tqlayout )
{
lastItem = 0;
TQDomElement n = e.firstChild().toElement();
@@ -1335,7 +1335,7 @@ TQObject *Resource::createObject( const TQDomElement &e, TQWidget *parent, TQLay
TQString className = e.attribute( "class", TQWIDGET_OBJECT_NAME_STRING );
if ( !className.isNull() ) {
- obj = WidgetFactory::create( WidgetDatabase::idFromClassName( className ), parent, 0, false );
+ obj = TQT_TQOBJECT(WidgetFactory::create( WidgetDatabase::idFromClassName( className ), tqparent, 0, false ));
if ( !obj )
return 0;
if ( !mainContainerSet ) {
@@ -1346,16 +1346,16 @@ TQObject *Resource::createObject( const TQDomElement &e, TQWidget *parent, TQLay
w = (TQWidget*)obj;
if ( w->inherits( TQMAINWINDOW_OBJECT_NAME_STRING ) )
w = ( (TQMainWindow*)w )->centralWidget();
- if ( layout ) {
- switch ( WidgetFactory::layoutType( layout ) ) {
+ if ( tqlayout ) {
+ switch ( WidgetFactory::tqlayoutType( tqlayout ) ) {
case WidgetFactory::HBox:
- ( (TQHBoxLayout*)layout )->addWidget( w );
+ ( (TQHBoxLayout*)tqlayout )->addWidget( w );
break;
case WidgetFactory::VBox:
- ( (TQVBoxLayout*)layout )->addWidget( w );
+ ( (TQVBoxLayout*)tqlayout )->addWidget( w );
break;
case WidgetFactory::Grid:
- ( (QDesignerGridLayout*)layout )->addMultiCellWidget( w, row, row + rowspan - 1,
+ ( (TQDesignerGridLayout*)tqlayout )->addMultiCellWidget( w, row, row + rowspan - 1,
col, col + colspan - 1 );
break;
default:
@@ -1365,13 +1365,13 @@ TQObject *Resource::createObject( const TQDomElement &e, TQWidget *parent, TQLay
if ( !toplevel )
toplevel = w;
- layout = 0;
+ tqlayout = 0;
if ( w && formwindow ) {
- if ( !parent || ( !parent->inherits( TQTOOLBOX_OBJECT_NAME_STRING ) && !parent->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) && !parent->inherits( TQWIZARD_OBJECT_NAME_STRING ) ) )
+ if ( !tqparent || ( !tqparent->inherits( TQTOOLBOX_OBJECT_NAME_STRING ) && !tqparent->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) && !tqparent->inherits( TQWIZARD_OBJECT_NAME_STRING ) ) )
formwindow->insertWidget( w, pasting );
- else if ( parent && ( parent->inherits( TQTOOLBOX_OBJECT_NAME_STRING ) || parent->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) || parent->inherits( TQWIZARD_OBJECT_NAME_STRING ) ) )
- MetaDataBase::addEntry( w );
+ else if ( tqparent && ( tqparent->inherits( TQTOOLBOX_OBJECT_NAME_STRING ) || tqparent->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) || tqparent->inherits( TQWIZARD_OBJECT_NAME_STRING ) ) )
+ MetaDataBase::addEntry( TQT_TQOBJECT(w) );
if (w->inherits("Dialog"))
dynamic_cast<Dialog*>(w)->setUseInternalParser(false);
}
@@ -1379,22 +1379,22 @@ TQObject *Resource::createObject( const TQDomElement &e, TQWidget *parent, TQLay
while ( !n.isNull() ) {
if ( n.tagName() == "spacer" ) {
- createSpacer( n, w, layout, Qt::Horizontal );
+ createSpacer( n, w, tqlayout, Qt::Horizontal );
} else if ( n.tagName() == "widget" ) {
- createObject( n, w, layout );
+ createObject( n, w, tqlayout );
} else if ( n.tagName() == "hbox" ) {
- layout = WidgetFactory::createLayout( w, layout, WidgetFactory::HBox );
- obj = layout;
+ tqlayout = WidgetFactory::createLayout( w, tqlayout, WidgetFactory::HBox );
+ obj = TQT_TQOBJECT(tqlayout);
n = n.firstChild().toElement();
continue;
} else if ( n.tagName() == "grid" ) {
- layout = WidgetFactory::createLayout( w, layout, WidgetFactory::Grid );
- obj = layout;
+ tqlayout = WidgetFactory::createLayout( w, tqlayout, WidgetFactory::Grid );
+ obj = TQT_TQOBJECT(tqlayout);
n = n.firstChild().toElement();
continue;
} else if ( n.tagName() == "vbox" ) {
- layout = WidgetFactory::createLayout( w, layout, WidgetFactory::VBox );
- obj = layout;
+ tqlayout = WidgetFactory::createLayout( w, tqlayout, WidgetFactory::VBox );
+ obj = TQT_TQOBJECT(tqlayout);
n = n.firstChild().toElement();
continue;
} else if ( n.tagName() == "property" && obj ) {
@@ -1402,16 +1402,16 @@ TQObject *Resource::createObject( const TQDomElement &e, TQWidget *parent, TQLay
} else if ( n.tagName() == "attribute" && w ) {
TQString attrib = n.attribute( "name" );
TQVariant v = DomTool::elementToVariant( n.firstChild().toElement(), TQVariant() );
- if ( parent->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) ) {
+ if ( tqparent->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) ) {
if ( attrib == "title" )
- ( (TQTabWidget*)parent )->insertTab( w, v.toString() );
+ ( (TQTabWidget*)tqparent )->insertTab( w, v.toString() );
} else
- if ( parent->inherits( TQTOOLBOX_OBJECT_NAME_STRING ) ) {
+ if ( tqparent->inherits( TQTOOLBOX_OBJECT_NAME_STRING ) ) {
if ( attrib == "label" )
- ( (TQToolBox*)parent )->addItem( w, v.toString() );
- } else if ( parent->inherits( TQWIZARD_OBJECT_NAME_STRING ) ) {
+ ( (TQToolBox*)tqparent )->addItem( w, v.toString() );
+ } else if ( tqparent->inherits( TQWIZARD_OBJECT_NAME_STRING ) ) {
if ( attrib == "title" )
- ( (TQWizard*)parent )->addPage( w, v.toString() );
+ ( (TQWizard*)tqparent )->addPage( w, v.toString() );
}
} else if ( n.tagName() == "item" ) {
createItem( n, w );
@@ -1428,7 +1428,7 @@ TQObject *Resource::createObject( const TQDomElement &e, TQWidget *parent, TQLay
n = n.nextSibling().toElement();
}
- return w;
+ return TQT_TQOBJECT(w);
}
void Resource::createColumn( const TQDomElement &e, TQWidget *widget )
@@ -1469,7 +1469,7 @@ void Resource::createColumn( const TQDomElement &e, TQWidget *widget )
if ( !resizeable )
lv->header()->setResizeEnabled( resizeable, i );
}
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
else if ( widget->inherits( TQTABLE_OBJECT_NAME_STRING ) ) {
TQTable *table = (TQTable*)widget;
bool isRow;
@@ -1483,7 +1483,7 @@ void Resource::createColumn( const TQDomElement &e, TQWidget *widget )
bool hasPixmap = false;
TQString txt;
TQString field;
- TQMap<TQString, TQString> fieldMap = MetaDataBase::columnFields( table );
+ TQMap<TQString, TQString> fieldMap = MetaDataBase::columnFields( TQT_TQOBJECT(table) );
while ( !n.isNull() ) {
if ( n.tagName() == "property" ) {
TQString attrib = n.attribute( "name" );
@@ -1508,7 +1508,7 @@ void Resource::createColumn( const TQDomElement &e, TQWidget *widget )
h->setLabel( i, txt );
if ( !isRow && !field.isEmpty() )
fieldMap.insert( txt, field );
- MetaDataBase::setColumnFields( table, fieldMap );
+ MetaDataBase::setColumnFields( TQT_TQOBJECT(table), fieldMap );
}
#endif
}
@@ -1534,7 +1534,7 @@ void Resource::loadItem( const TQDomElement &e, TQPixmap &pix, TQString &txt, bo
void Resource::createItem( const TQDomElement &e, TQWidget *widget, TQListViewItem *i )
{
- if ( !widget || !WidgetFactory::hasItems( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( widget ) ) ) )
+ if ( !widget || !WidgetFactory::hasItems( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( TQT_TQOBJECT(widget) ) ) ) )
return;
if ( widget->inherits( TQLISTBOX_OBJECT_NAME_STRING ) || widget->inherits( TQCOMBOBOX_OBJECT_NAME_STRING ) ) {
@@ -1605,7 +1605,7 @@ void Resource::createItem( const TQDomElement &e, TQWidget *widget, TQListViewIt
}
}
-TQWidget *Resource::createSpacer( const TQDomElement &e, TQWidget *parent, TQLayout *layout, Qt::Orientation o )
+TQWidget *Resource::createSpacer( const TQDomElement &e, TQWidget *tqparent, TQLayout *tqlayout, Qt::Orientation o )
{
TQDomElement n = e.firstChild().toElement();
int row = e.attribute( "row" ).toInt();
@@ -1618,23 +1618,23 @@ TQWidget *Resource::createSpacer( const TQDomElement &e, TQWidget *parent, TQLay
colspan = 1;
Spacer *spacer = (Spacer*) WidgetFactory::create( WidgetDatabase::idFromClassName("Spacer"),
- parent, "spacer", false);
+ tqparent, "spacer", false);
spacer->setOrientation( o );
spacer->setInteraciveMode( false );
while ( !n.isNull() ) {
if ( n.tagName() == "property" )
- setObjectProperty( spacer, n.attribute( "name" ), n.firstChild().toElement() );
+ setObjectProperty( TQT_TQOBJECT(spacer), n.attribute( "name" ), n.firstChild().toElement() );
n = n.nextSibling().toElement();
}
spacer->setInteraciveMode( true );
if ( formwindow )
formwindow->insertWidget( spacer, pasting );
- if ( layout ) {
- if ( layout->inherits( TQBOXLAYOUT_OBJECT_NAME_STRING ) )
- ( (TQBoxLayout*)layout )->addWidget( spacer, 0, spacer->alignment() );
+ if ( tqlayout ) {
+ if ( tqlayout->inherits( TQBOXLAYOUT_OBJECT_NAME_STRING ) )
+ ( (TQBoxLayout*)tqlayout )->addWidget( spacer, 0, spacer->tqalignment() );
else
- ( (QDesignerGridLayout*)layout )->addMultiCellWidget( spacer, row, row + rowspan - 1, col, col + colspan - 1,
- spacer->alignment() );
+ ( (TQDesignerGridLayout*)tqlayout )->addMultiCellWidget( spacer, row, row + rowspan - 1, col, col + colspan - 1,
+ spacer->tqalignment() );
}
return spacer;
}
@@ -1644,9 +1644,9 @@ TQWidget *Resource::createSpacer( const TQDomElement &e, TQWidget *parent, TQLay
*/
void Resource::setObjectProperty( TQObject* obj, const TQString &prop, const TQDomElement &e )
{
- const TQMetaProperty *p = obj->metaObject()->property( obj->metaObject()->findProperty( prop, true ), true );
+ const TQMetaProperty *p = obj->tqmetaObject()->property( obj->tqmetaObject()->tqfindProperty( prop, true ), true );
- if ( !obj->inherits( TQLAYOUT_OBJECT_NAME_STRING ) ) {// no layouts in metadatabase... (RS)
+ if ( !obj->inherits( TQLAYOUT_OBJECT_NAME_STRING ) ) {// no tqlayouts in metadatabase... (RS)
if ( obj->inherits( "CustomWidget" ) ) {
MetaDataBase::CustomWidget *cw = ( (CustomWidget*)obj )->customWidget();
if ( cw && !cw->hasProperty( prop.latin1() ) && !p && prop != "toolTip" && prop != "whatsThis" )
@@ -1657,9 +1657,9 @@ void Resource::setObjectProperty( TQObject* obj, const TQString &prop, const TQD
TQVariant defVarient;
if ( e.tagName() == "font" ) {
- TQFont f( qApp->font() );
- if ( obj->isWidgetType() && ( (TQWidget*)obj )->parentWidget() )
- f = ( (TQWidget*)obj )->parentWidget()->font();
+ TQFont f( tqApp->font() );
+ if ( obj->isWidgetType() && ( (TQWidget*)obj )->tqparentWidget() )
+ f = ( (TQWidget*)obj )->tqparentWidget()->font();
defVarient = TQVariant( f );
}
@@ -1688,7 +1688,7 @@ void Resource::setObjectProperty( TQObject* obj, const TQString &prop, const TQD
if ( !p ) {
MetaDataBase::setFakeProperty( obj, prop, v );
if ( obj->isWidgetType() ) {
- if ( prop == "database" && obj != toplevel ) {
+ if ( prop == "database" && TQT_BASE_OBJECT(obj) != TQT_BASE_OBJECT(toplevel) ) {
TQStringList lst = MetaDataBase::fakeProperty( obj, "database" ).toStringList();
if ( lst.count() > 2 )
dbControls.insert( obj->name(), lst[ 2 ] );
@@ -1743,11 +1743,11 @@ void Resource::setObjectProperty( TQObject* obj, const TQString &prop, const TQD
}
if ( prop == "geometry" ) {
- if ( obj == toplevel ) {
+ if ( TQT_BASE_OBJECT(obj) == toplevel ) {
hadGeometry = true;
toplevel->resize( v.toRect().size() );
return;
- } else if ( obj == formwindow->mainContainer() ) {
+ } else if ( TQT_BASE_OBJECT(obj) == formwindow->mainContainer() ) {
hadGeometry = true;
formwindow->resize( v.toRect().size() );
return;
@@ -1756,11 +1756,11 @@ void Resource::setObjectProperty( TQObject* obj, const TQString &prop, const TQD
if ( obj->inherits( TQLAYOUT_OBJECT_NAME_STRING ) ) {
if ( prop == "spacing" ) {
- MetaDataBase::setSpacing( WidgetFactory::containerOfWidget( WidgetFactory::layoutParent( (TQLayout*)obj ) ), v.toInt() );
+ MetaDataBase::setSpacing( TQT_TQOBJECT(WidgetFactory::containerOfWidget( WidgetFactory::tqlayoutParent( (TQLayout*)obj ) )), v.toInt() );
return;
}
if ( prop == "margin" ) {
- MetaDataBase::setMargin( WidgetFactory::containerOfWidget( WidgetFactory::layoutParent( (TQLayout*)obj ) ), v.toInt() );
+ MetaDataBase::setMargin( TQT_TQOBJECT(WidgetFactory::containerOfWidget( WidgetFactory::tqlayoutParent( (TQLayout*)obj ) )), v.toInt() );
return;
}
}
@@ -1768,10 +1768,10 @@ void Resource::setObjectProperty( TQObject* obj, const TQString &prop, const TQD
if ( prop == "name" ) {
if ( pasting ) {
TQString s = v.toString();
- formwindow->unify( (TQWidget*)obj, s, true );
+ formwindow->unify( TQT_TQOBJECT(obj), s, true );
obj->setName( s );
return;
- } else if ( formwindow && obj == formwindow->mainContainer() ) {
+ } else if ( formwindow && TQT_BASE_OBJECT(obj) == formwindow->mainContainer() ) {
formwindow->setName( v.toCString() );
}
}
@@ -1916,17 +1916,17 @@ void Resource::saveConnections( TQTextStream &ts, int indent )
{
ts << makeIndent( indent ) << "<connections>" << endl;
indent++;
- TQValueList<MetaDataBase::Connection> connections = MetaDataBase::connections( formwindow );
+ TQValueList<MetaDataBase::Connection> connections = MetaDataBase::connections( TQT_TQOBJECT(formwindow) );
TQValueList<MetaDataBase::Connection>::Iterator it = connections.begin();
for ( ; it != connections.end(); ++it ) {
MetaDataBase::Connection conn = *it;
- if ( ( knownNames.findIndex( TQString( conn.sender->name() ) ) == -1 &&
+ if ( ( knownNames.tqfindIndex( TQString( conn.sender->name() ) ) == -1 &&
qstrcmp( conn.sender->name(), "this" ) != 0 ) ||
- ( knownNames.findIndex( TQString( conn.receiver->name() ) ) == -1 &&
+ ( knownNames.tqfindIndex( TQString( conn.receiver->name() ) ) == -1 &&
qstrcmp( conn.receiver->name(), "this" ) != 0 ) )
continue;
- if ( formwindow->isMainContainer( (TQWidget*)(*it).receiver ) &&
- !MetaDataBase::hasSlot( formwindow, MetaDataBase::normalizeSlot( (*it).slot ).latin1() ) )
+ if ( formwindow->isMainContainer( TQT_TQOBJECT((*it).receiver) ) &&
+ !MetaDataBase::hasSlot( TQT_TQOBJECT(formwindow), MetaDataBase::normalizeSlot( (*it).slot ).latin1() ) )
continue;
if ( conn.sender->inherits( "CustomWidget" ) ) {
@@ -1995,7 +1995,7 @@ void Resource::loadConnections( const TQDomElement &e )
conn.sender = 0;
TQString name = n2.firstChild().toText().data();
if ( name == "this" || qstrcmp( toplevel->name(), name ) == 0 ) {
- conn.sender = toplevel;
+ conn.sender = TQT_TQOBJECT(toplevel);
} else {
if ( name == "this" )
name = toplevel->name();
@@ -2013,7 +2013,7 @@ void Resource::loadConnections( const TQDomElement &e )
} else if ( n2.tagName() == "receiver" ) {
TQString name = n2.firstChild().toText().data();
if ( name == "this" || qstrcmp( toplevel->name(), name ) == 0 ) {
- conn.receiver = toplevel;
+ conn.receiver = TQT_TQOBJECT(toplevel);
} else {
TQObjectList *l = toplevel->queryList( 0, name, false );
if ( l ) {
@@ -2028,10 +2028,10 @@ void Resource::loadConnections( const TQDomElement &e )
n2 = n2.nextSibling().toElement();
}
if ( formwindow ) {
- if ( conn.sender == formwindow )
- conn.sender = formwindow->mainContainer();
- if ( conn.receiver == formwindow )
- conn.receiver = formwindow->mainContainer();
+ if ( TQT_BASE_OBJECT(conn.sender) == TQT_BASE_OBJECT(formwindow) )
+ conn.sender = TQT_TQOBJECT(formwindow->mainContainer());
+ if ( TQT_BASE_OBJECT(conn.receiver) == TQT_BASE_OBJECT(formwindow) )
+ conn.receiver = TQT_TQOBJECT(formwindow->mainContainer());
}
if ( conn.sender && conn.receiver ) {
#ifndef KOMMANDER
@@ -2044,7 +2044,7 @@ void Resource::loadConnections( const TQDomElement &e )
TQStringList::split( ',', conn.slot ), false );
}
#else
- MetaDataBase::addConnection( formwindow ? formwindow : toplevel,
+ MetaDataBase::addConnection( formwindow ? TQT_TQOBJECT(formwindow) : TQT_TQOBJECT(toplevel),
conn.sender, conn.signal, conn.receiver, conn.slot );
#endif
}
@@ -2061,11 +2061,11 @@ void Resource::loadConnections( const TQDomElement &e )
if ( slot.returnType.isEmpty() )
slot.returnType = "void";
slot.slot = n.firstChild().toText().data();
- if ( !MetaDataBase::hasSlot( formwindow, slot.slot, true ) )
- MetaDataBase::addSlot( formwindow, slot.slot, slot.specifier,
+ if ( !MetaDataBase::hasSlot( TQT_TQOBJECT(formwindow), slot.slot, true ) )
+ MetaDataBase::addSlot( TQT_TQOBJECT(formwindow), slot.slot, slot.specifier,
slot.access, slot.language, slot.returnType );
else
- MetaDataBase::changeSlotAttributes( formwindow, slot.slot,
+ MetaDataBase::changeSlotAttributes( TQT_TQOBJECT(formwindow), slot.slot,
slot.specifier, slot.access,
slot.language, slot.returnType );
}
@@ -2080,7 +2080,7 @@ void Resource::saveCustomWidgets( TQTextStream &ts, int indent )
TQPtrList<MetaDataBase::CustomWidget> *lst = MetaDataBase::customWidgets();
for ( MetaDataBase::CustomWidget *w = lst->first(); w; w = lst->next() ) {
- if ( usedCustomWidgets.findIndex( w->className ) == -1 )
+ if ( usedCustomWidgets.tqfindIndex( w->className ) == -1 )
continue;
ts << makeIndent( indent ) << "<customwidget>" << endl;
indent++;
@@ -2090,8 +2090,8 @@ void Resource::saveCustomWidgets( TQTextStream &ts, int indent )
<< "\">" << w->includeFile << "</header>" << endl;
ts << makeIndent( indent ) << "<sizehint>" << endl;
indent++;
- ts << makeIndent( indent ) << "<width>" << w->sizeHint.width() << "</width>" << endl;
- ts << makeIndent( indent ) << "<height>" << w->sizeHint.height() << "</height>" << endl;
+ ts << makeIndent( indent ) << "<width>" << w->tqsizeHint.width() << "</width>" << endl;
+ ts << makeIndent( indent ) << "<height>" << w->tqsizeHint.height() << "</height>" << endl;
indent--;
ts << makeIndent( indent ) << "</sizehint>" << endl;
ts << makeIndent( indent ) << "<container>" << (int)w->isContainer << "</container>" << endl;
@@ -2147,9 +2147,9 @@ void Resource::loadCustomWidgets( const TQDomElement &e, Resource *r )
TQDomElement n3 = n2.firstChild().toElement();
while ( !n3.isNull() ) {
if ( n3.tagName() == "width" )
- w->sizeHint.setWidth( n3.firstChild().toText().data().toInt() );
+ w->tqsizeHint.setWidth( n3.firstChild().toText().data().toInt() );
else if ( n3.tagName() == "height" )
- w->sizeHint.setHeight( n3.firstChild().toText().data().toInt() );
+ w->tqsizeHint.setHeight( n3.firstChild().toText().data().toInt() );
n3 = n3.nextSibling().toElement();
}
} else if ( n2.tagName() == "sizepolicy" ) {
@@ -2214,7 +2214,7 @@ void Resource::saveTabOrder( TQTextStream &ts, int indent )
indent++;
for ( TQWidget *w = l.first(); w; w = l.next() ) {
- if ( w->testWState( Qt::WState_ForceHide ) || knownNames.findIndex( w->name() ) == -1 )
+ if ( w->testWState( TQt::WState_ForceHide ) || knownNames.tqfindIndex( w->name() ) == -1 )
continue;
ts << makeIndent( indent ) << "<tabstop>" << w->name() << "</tabstop>" << endl;
}
@@ -2254,7 +2254,7 @@ void Resource::loadTabOrder( const TQDomElement &e )
void Resource::saveMetaInfoBefore( TQTextStream &ts, int indent )
{
- MetaDataBase::MetaInfo info = MetaDataBase::metaInfo(formwindow);
+ MetaDataBase::MetaInfo info = MetaDataBase::metaInfo(TQT_TQOBJECT(formwindow));
TQString cn = formwindow->name();
ts << makeIndent(indent) << "<class>" << entitize(cn) << "</class>" << endl;
if (!info.comment.isEmpty())
@@ -2269,8 +2269,8 @@ void Resource::saveMetaInfoBefore( TQTextStream &ts, int indent )
void Resource::saveMetaInfoAfter( TQTextStream &ts, int indent )
{
- MetaDataBase::MetaInfo info = MetaDataBase::metaInfo( formwindow );
- TQValueList<MetaDataBase::Include> includes = MetaDataBase::includes( formwindow );
+ MetaDataBase::MetaInfo info = MetaDataBase::metaInfo( TQT_TQOBJECT(formwindow) );
+ TQValueList<MetaDataBase::Include> includes = MetaDataBase::includes( TQT_TQOBJECT(formwindow) );
TQString extensionInclude;
bool needExtensionInclude = false;
if ( !includes.isEmpty() || needExtensionInclude ) {
@@ -2291,7 +2291,7 @@ void Resource::saveMetaInfoAfter( TQTextStream &ts, int indent )
ts << makeIndent( indent ) << "</includes>" << endl;
}
- TQStringList forwards = MetaDataBase::forwards( formwindow );
+ TQStringList forwards = MetaDataBase::forwards( TQT_TQOBJECT(formwindow) );
if ( !forwards.isEmpty() ) {
ts << makeIndent( indent ) << "<forwards>" << endl;
indent++;
@@ -2300,7 +2300,7 @@ void Resource::saveMetaInfoAfter( TQTextStream &ts, int indent )
indent--;
ts << makeIndent( indent ) << "</forwards>" << endl;
}
- TQStringList sigs = MetaDataBase::signalList( formwindow );
+ TQStringList sigs = MetaDataBase::signalList( TQT_TQOBJECT(formwindow) );
if ( !sigs.isEmpty() ) {
ts << makeIndent( indent ) << "<signals>" << endl;
indent++;
@@ -2309,7 +2309,7 @@ void Resource::saveMetaInfoAfter( TQTextStream &ts, int indent )
indent--;
ts << makeIndent( indent ) << "</signals>" << endl;
- TQValueList<MetaDataBase::Slot> slotList = MetaDataBase::slotList( formwindow );
+ TQValueList<MetaDataBase::Slot> slotList = MetaDataBase::slotList( TQT_TQOBJECT(formwindow) );
if ( !slotList.isEmpty() ) {
ts << makeIndent( indent ) << "<slots>" << endl;
indent++;
@@ -2339,11 +2339,11 @@ void Resource::saveMetaInfoAfter( TQTextStream &ts, int indent )
;
else
ts << makeIndent( indent ) << "<pixmapfunction>" << formwindow->pixmapLoaderFunction() << "</pixmapfunction>" << endl;
- if ( !( exportMacro = MetaDataBase::exportMacro( formwindow->mainContainer() ) ).isEmpty() )
+ if ( !( exportMacro = MetaDataBase::exportMacro( TQT_TQOBJECT(formwindow->mainContainer()) ) ).isEmpty() )
ts << makeIndent( indent ) << "<exportmacro>" << exportMacro << "</exportmacro>" << endl;
if ( formwindow )
- ts << makeIndent( indent ) << "<layoutdefaults spacing=\"" << formwindow->layoutDefaultSpacing()
- << "\" margin=\"" << formwindow->layoutDefaultMargin() << "\"/>" << endl;
+ ts << makeIndent( indent ) << "<tqlayoutdefaults spacing=\"" << formwindow->tqlayoutDefaultSpacing()
+ << "\" margin=\"" << formwindow->tqlayoutDefaultMargin() << "\"/>" << endl;
}
TQColorGroup Resource::loadColorGroup( const TQDomElement &e )
@@ -2367,9 +2367,10 @@ TQColorGroup Resource::loadColorGroup( const TQDomElement &e )
void Resource::saveChildActions( TQAction *a, TQTextStream &ts, int indent )
{
- if ( !a->children() )
+ TQObjectList clo = a->childrenListObject();
+ if ( clo.isEmpty() )
return;
- TQObjectListIt it( *a->children() );
+ TQObjectListIt it( clo );
while ( it.current() ) {
TQObject *o = it.current();
++it;
@@ -2428,12 +2429,12 @@ void Resource::saveActions( const TQPtrList<TQAction> &actions, TQTextStream &ts
ts << makeIndent( indent ) << "</actions>" << endl;
}
-void Resource::loadChildAction( TQObject *parent, const TQDomElement &e )
+void Resource::loadChildAction( TQObject *tqparent, const TQDomElement &e )
{
TQDomElement n = e;
TQAction *a = 0;
if ( n.tagName() == "action" ) {
- a = new QDesignerAction( parent );
+ a = new TQDesignerAction( tqparent );
MetaDataBase::addEntry( a );
TQDomElement n2 = n.firstChild().toElement();
while ( !n2.isNull() ) {
@@ -2449,10 +2450,10 @@ void Resource::loadChildAction( TQObject *parent, const TQDomElement &e )
}
n2 = n2.nextSibling().toElement();
}
- if ( !parent->inherits( TQACTION_OBJECT_NAME_STRING ) )
+ if ( !tqparent->inherits( TQACTION_OBJECT_NAME_STRING ) )
formwindow->actionList().append( a );
} else if ( n.tagName() == "actiongroup" ) {
- a = new QDesignerActionGroup( parent );
+ a = new TQDesignerActionGroup( tqparent );
MetaDataBase::addEntry( a );
TQDomElement n2 = n.firstChild().toElement();
while ( !n2.isNull() ) {
@@ -2471,7 +2472,7 @@ void Resource::loadChildAction( TQObject *parent, const TQDomElement &e )
}
n2 = n2.nextSibling().toElement();
}
- if ( !parent->inherits( TQACTION_OBJECT_NAME_STRING ) )
+ if ( !tqparent->inherits( TQACTION_OBJECT_NAME_STRING ) )
formwindow->actionList().append( a );
}
}
@@ -2481,9 +2482,9 @@ void Resource::loadActions( const TQDomElement &e )
TQDomElement n = e.firstChild().toElement();
while ( !n.isNull() ) {
if ( n.tagName() == "action" ) {
- loadChildAction( formwindow, n );
+ loadChildAction( TQT_TQOBJECT(formwindow), n );
} else if ( n.tagName() == "actiongroup" ) {
- loadChildAction( formwindow, n );
+ loadChildAction( TQT_TQOBJECT(formwindow), n );
}
n = n.nextSibling().toElement();
}
@@ -2495,8 +2496,8 @@ void Resource::saveToolBars( TQMainWindow *mw, TQTextStream &ts, int indent )
indent++;
TQPtrList<TQToolBar> tbList;
- for ( int i = 0; i <= (int)Qt::DockMinimized; ++i ) {
- tbList = mw->toolBars( (Qt::Dock)i );
+ for ( int i = 0; i <= (int)TQt::DockMinimized; ++i ) {
+ tbList = mw->toolBars( (TQt::Dock)i );
if ( tbList.isEmpty() )
continue;
for ( TQToolBar *tb = tbList.first(); tb; tb = tbList.next() ) {
@@ -2504,23 +2505,23 @@ void Resource::saveToolBars( TQMainWindow *mw, TQTextStream &ts, int indent )
continue;
ts << makeIndent( indent ) << "<toolbar dock=\"" << i << "\">" << endl;
indent++;
- saveObjectProperties( tb, ts, indent );
- TQPtrList<TQAction> actionList = ( (QDesignerToolBar*)tb )->insertedActions();
+ saveObjectProperties( TQT_TQOBJECT(tb), ts, indent );
+ TQPtrList<TQAction> actionList = ( (TQDesignerToolBar*)tb )->insertedActions();
for ( TQAction *a = actionList.first(); a; a = actionList.next() ) {
- if ( a->inherits( "QSeparatorAction" ) ) {
+ if ( a->inherits( "TQSeparatorAction" ) ) {
ts << makeIndent( indent ) << "<separator/>" << endl;
} else {
- if ( a->inherits( "QDesignerAction" ) && !( (QDesignerAction*)a )->supportsMenu() ) {
- TQWidget *w = ( (QDesignerAction*)a )->widget();
+ if ( a->inherits( "TQDesignerAction" ) && !( (TQDesignerAction*)a )->supportsMenu() ) {
+ TQWidget *w = ( (TQDesignerAction*)a )->widget();
ts << makeIndent( indent ) << "<widget class=\""
- << WidgetFactory::classNameOf( w ) << "\">" << endl;
+ << WidgetFactory::classNameOf( TQT_TQOBJECT(w) ) << "\">" << endl;
indent++;
- saveObjectProperties( w, ts, indent );
- const char *className = WidgetFactory::classNameOf( w );
+ saveObjectProperties( TQT_TQOBJECT(w), ts, indent );
+ const char *className = WidgetFactory::classNameOf( TQT_TQOBJECT(w) );
if ( w->isA( "CustomWidget" ) )
usedCustomWidgets << TQString( className );
- if ( WidgetFactory::hasItems( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( w ) ) ) )
- saveItems( w, ts, indent );
+ if ( WidgetFactory::hasItems( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( TQT_TQOBJECT(w) ) ) ) )
+ saveItems( TQT_TQOBJECT(w), ts, indent );
indent--;
ts << makeIndent( indent ) << "</widget>" << endl;
} else {
@@ -2542,18 +2543,18 @@ void Resource::saveMenuBar( TQMainWindow *mw, TQTextStream &ts, int indent )
return;
ts << makeIndent( indent ) << "<menubar>" << endl;
indent++;
- saveObjectProperties( mw->menuBar(), ts, indent );
+ saveObjectProperties( TQT_TQOBJECT(mw->menuBar()), ts, indent );
for ( int i = 0; i < (int)mw->menuBar()->count(); ++i ) {
ts << makeIndent( indent ) << "<item text=\"" << entitize( mw->menuBar()->text( mw->menuBar()->idAt( i ) ) )
- << "\" name=\"" << entitize( mw->menuBar()->findItem( mw->menuBar()->idAt( i ) )->popup()->name() ) << "\">" << endl;
+ << "\" name=\"" << entitize( mw->menuBar()->tqfindItem( mw->menuBar()->idAt( i ) )->popup()->name() ) << "\">" << endl;
indent++;
- TQMenuItem *m = mw->menuBar()->findItem( mw->menuBar()->idAt( i ) );
+ TQMenuItem *m = mw->menuBar()->tqfindItem( mw->menuBar()->idAt( i ) );
if ( !m )
continue;
- TQPtrList<TQAction> actionList = ( (QDesignerPopupMenu*)m->popup() )->insertedActions();
+ TQPtrList<TQAction> actionList = ( (TQDesignerPopupMenu*)m->popup() )->insertedActions();
for ( TQAction *a = actionList.first(); a; a = actionList.next() ) {
- if ( a->inherits( "QSeparatorAction" ) )
+ if ( a->inherits( "TQSeparatorAction" ) )
ts << makeIndent( indent ) << "<separator/>" << endl;
else
ts << makeIndent( indent ) << "<action name=\"" << a->name() << "\"/>" << endl;
@@ -2569,11 +2570,11 @@ void Resource::loadToolBars( const TQDomElement &e )
{
TQDomElement n = e.firstChild().toElement();
TQMainWindow *mw = ( (TQMainWindow*)formwindow->mainContainer() );
- QDesignerToolBar *tb = 0;
+ TQDesignerToolBar *tb = 0;
while ( !n.isNull() ) {
if ( n.tagName() == "toolbar" ) {
- Qt::Dock dock = (Qt::Dock)n.attribute( "dock" ).toInt();
- tb = new QDesignerToolBar( mw, dock );
+ TQt::Dock dock = (TQt::Dock)n.attribute( "dock" ).toInt();
+ tb = new TQDesignerToolBar( mw, dock );
TQDomElement n2 = n.firstChild().toElement();
while ( !n2.isNull() ) {
if ( n2.tagName() == "action" ) {
@@ -2583,17 +2584,17 @@ void Resource::loadToolBars( const TQDomElement &e )
tb->addAction( a );
}
} else if ( n2.tagName() == "separator" ) {
- TQAction *a = new QSeparatorAction( 0 );
+ TQAction *a = new TQSeparatorAction( 0 );
a->addTo( tb );
tb->addAction( a );
} else if ( n2.tagName() == "widget" ) {
TQWidget *w = (TQWidget*)createObject( n2, tb );
- QDesignerAction *a = new QDesignerAction( w, tb );
+ TQDesignerAction *a = new TQDesignerAction( w, TQT_TQOBJECT(tb) );
a->addTo( tb );
tb->addAction( a );
tb->installEventFilters( w );
} else if ( n2.tagName() == "property" ) {
- setObjectProperty( tb, n2.attribute( "name" ), n2.firstChild().toElement() );
+ setObjectProperty( TQT_TQOBJECT(tb), n2.attribute( "name" ), n2.firstChild().toElement() );
}
n2 = n2.nextSibling().toElement();
}
@@ -2606,10 +2607,10 @@ void Resource::loadMenuBar( const TQDomElement &e )
{
TQDomElement n = e.firstChild().toElement();
TQMainWindow *mw = ( (TQMainWindow*)formwindow->mainContainer() );
- QDesignerMenuBar *mb = new QDesignerMenuBar( mw );
+ TQDesignerMenuBar *mb = new TQDesignerMenuBar( mw );
while ( !n.isNull() ) {
if ( n.tagName() == "item" ) {
- QDesignerPopupMenu *popup = new QDesignerPopupMenu( mw );
+ TQDesignerPopupMenu *popup = new TQDesignerPopupMenu( mw );
popup->setName( n.attribute( "name" ) );
TQDomElement n2 = n.firstChild().toElement();
while ( !n2.isNull() ) {
@@ -2620,7 +2621,7 @@ void Resource::loadMenuBar( const TQDomElement &e )
popup->addAction( a );
}
} else if ( n2.tagName() == "separator" ) {
- TQAction *a = new QSeparatorAction( 0 );
+ TQAction *a = new TQSeparatorAction( 0 );
a->addTo( popup );
popup->addAction( a );
}
@@ -2628,7 +2629,7 @@ void Resource::loadMenuBar( const TQDomElement &e )
}
mb->insertItem( n.attribute( "text" ), popup );
} else if ( n.tagName() == "property" ) {
- setObjectProperty( mb, n.attribute( "name" ), n.firstChild().toElement() );
+ setObjectProperty( TQT_TQOBJECT(mb), n.attribute( "name" ), n.firstChild().toElement() );
}
n = n.nextSibling().toElement();
}
@@ -2667,11 +2668,11 @@ void Resource::saveFormCode()
for ( ; sit != slotList.end(); ++sit ) {
MetaDataBase::Slot slot = *sit;
TQMap<TQString, TQString>::Iterator it =
- functionBodies.find( MetaDataBase::normalizeSlot( (*sit).slot ) );
+ functionBodies.tqfind( MetaDataBase::normalizeSlot( (*sit).slot ) );
LanguageInterface::Function func;
func.name = slot.slot;
func.body = *it;
- func.comments = MetaDataBase::functionComments( formwindow, func.name );
+ func.comments = MetaDataBase::functionComments( TQT_TQOBJECT(formwindow), func.name );
func.returnType = slot.returnType;
funcs.append( func );
}
@@ -2699,14 +2700,14 @@ void Resource::saveFormCode()
static TQString make_function_pretty( const TQString &s )
{
TQString res = s;
- if ( res.find( ")" ) - res.find( "(" ) == 1 )
+ if ( res.tqfind( ")" ) - res.tqfind( "(" ) == 1 )
return res;
- res.replace( TQRegExp( "[(]" ), "( " );
- res.replace( TQRegExp( "[)]" ), " )" );
- res.replace( TQRegExp( "&" ), " &" );
- res.replace( TQRegExp( "[*]" ), " *" );
- res.replace( TQRegExp( "," ), ", " );
- res.replace( TQRegExp( ":" ), " : " );
+ res.tqreplace( TQRegExp( "[(]" ), "( " );
+ res.tqreplace( TQRegExp( "[)]" ), " )" );
+ res.tqreplace( TQRegExp( "&" ), " &" );
+ res.tqreplace( TQRegExp( "[*]" ), " *" );
+ res.tqreplace( TQRegExp( "," ), ", " );
+ res.tqreplace( TQRegExp( ":" ), " : " );
res = res.simplifyWhiteSpace();
return res;
}
@@ -2724,7 +2725,7 @@ void Resource::loadFunctions( const TQDomElement &e )
}
n = n.nextSibling().toElement();
}
- MetaDataBase::setFunctionBodies( formwindow, bodies, TQString::null, TQString::null );
+ MetaDataBase::setFunctionBodies( TQT_TQOBJECT(formwindow), bodies, TQString(), TQString() );
if ( !bodies.isEmpty() ) {
LanguageInterface *iface = langIface;
if ( !iface )
@@ -2739,14 +2740,14 @@ void Resource::loadFunctions( const TQDomElement &e )
#endif
continue;
TQString sl( (*it).slot );
- TQString comments = MetaDataBase::functionComments( formwindow, sl );
+ TQString comments = MetaDataBase::functionComments( TQT_TQOBJECT(formwindow), sl );
if ( !comments.isEmpty() )
code += comments + "\n";
code += iface->createFunctionStart( formwindow->name(), make_function_pretty( sl ),
( (*it).returnType.isEmpty() ?
TQString( "void" ) :
(*it).returnType ) );
- TQMap<TQString, TQString>::Iterator bit = bodies.find( MetaDataBase::normalizeSlot( (*it).slot ) );
+ TQMap<TQString, TQString>::Iterator bit = bodies.tqfind( MetaDataBase::normalizeSlot( (*it).slot ) );
if ( bit != bodies.end() )
code += "\n" + *bit + "\n\n";
else
@@ -2820,25 +2821,25 @@ void Resource::loadExtraSource()
for ( TQValueList<LanguageInterface::Function>::Iterator fit = functions.begin();
fit != functions.end(); ++fit ) {
- if ( MetaDataBase::hasSlot( formwindow, (*fit).name.latin1() ) )
- MetaDataBase::changeSlot( formwindow, (*fit).name.latin1(), (*fit).name.latin1() );
+ if ( MetaDataBase::hasSlot( TQT_TQOBJECT(formwindow), (*fit).name.latin1() ) )
+ MetaDataBase::changeSlot( TQT_TQOBJECT(formwindow), (*fit).name.latin1(), (*fit).name.latin1() );
else
- MetaDataBase::addSlot( formwindow, (*fit).name.latin1(), "virtual", "public", lang, (*fit).returnType );
- MetaDataBase::setFunctionComments( formwindow, (*fit).name, (*fit).comments );
+ MetaDataBase::addSlot( TQT_TQOBJECT(formwindow), (*fit).name.latin1(), "virtual", "public", lang, (*fit).returnType );
+ MetaDataBase::setFunctionComments( TQT_TQOBJECT(formwindow), (*fit).name, (*fit).comments );
bodies.insert( MetaDataBase::normalizeSlot( (*fit).name ), (*fit).body );
}
- MetaDataBase::setFunctionBodies( formwindow, bodies, TQString::null, TQString::null );
+ MetaDataBase::setFunctionBodies( TQT_TQOBJECT(formwindow), bodies, TQString(), TQString() );
TQStringList v = MetaDataBase::variables( formwindow );
TQStringList::Iterator vit;
for ( vit = vars.begin(); vit != vars.end(); ++vit )
v << *vit;
- MetaDataBase::setVariables( formwindow, v );
+ MetaDataBase::setVariables( TQT_TQOBJECT(formwindow), v );
TQStringList f = MetaDataBase::forwards( formwindow );
for ( vit = forwards.begin(); vit != forwards.end(); ++vit )
f << *vit;
- MetaDataBase::setForwards( formwindow, f );
+ MetaDataBase::setForwards( TQT_TQOBJECT(formwindow), f );
TQValueList<MetaDataBase::Include> incls = MetaDataBase::includes( formwindow );
for ( vit = includesImpl.begin(); vit != includesImpl.end(); ++vit ) {
@@ -2853,6 +2854,6 @@ void Resource::loadExtraSource()
inc.location = "in declaration";
incls << inc;
}
- MetaDataBase::setIncludes( formwindow, incls );
+ MetaDataBase::setIncludes( TQT_TQOBJECT(formwindow), incls );
}
#endif
diff --git a/kommander/editor/resource.h b/kommander/editor/resource.h
index b01bd233..1684df20 100644
--- a/kommander/editor/resource.h
+++ b/kommander/editor/resource.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -38,7 +38,7 @@ class TQPalette;
class FormWindow;
class MainWindow;
class TQDomElement;
-class QDesignerGridLayout;
+class TQDesignerGridLayout;
class TQListViewItem;
class TQMainWindow;
#ifndef KOMMANDER
@@ -71,13 +71,13 @@ public:
bool save( const TQString& filename, bool formCodeOnly = FALSE);
bool save( TQIODevice* );
- void paste( const TQString &cb, TQWidget *parent );
+ void paste( const TQString &cb, TQWidget *tqparent );
static void saveImageData( const TQImage &img, TQTextStream &ts, int indent );
static void loadCustomWidgets( const TQDomElement &e, Resource *r );
private:
- void saveObject( TQObject *obj, QDesignerGridLayout* grid, TQTextStream &ts, int indent );
+ void saveObject( TQObject *obj, TQDesignerGridLayout* grid, TQTextStream &ts, int indent );
void saveChildrenOf( TQObject* obj, TQTextStream &ts, int indent );
void saveObjectProperties( TQObject *w, TQTextStream &ts, int indent );
void saveSetProperty( TQObject *w, const TQString &name, TQVariant::Type t, TQTextStream &ts, int indent );
@@ -103,8 +103,8 @@ private:
// void saveFormCode();
#endif
- TQObject *createObject( const TQDomElement &e, TQWidget *parent, TQLayout* layout = 0 );
- TQWidget *createSpacer( const TQDomElement &e, TQWidget *parent, TQLayout *layout, Qt::Orientation o );
+ TQObject *createObject( const TQDomElement &e, TQWidget *tqparent, TQLayout* tqlayout = 0 );
+ TQWidget *createSpacer( const TQDomElement &e, TQWidget *tqparent, TQLayout *tqlayout, Qt::Orientation o );
void createItem( const TQDomElement &e, TQWidget *widget, TQListViewItem *i = 0 );
void createColumn( const TQDomElement &e, TQWidget *widget );
void setObjectProperty( TQObject* widget, const TQString &prop, const TQDomElement &e);
@@ -117,7 +117,7 @@ private:
void loadTabOrder( const TQDomElement &e );
void loadItem( const TQDomElement &n, TQPixmap &pix, TQString &txt, bool &hasPixmap );
void loadActions( const TQDomElement &n );
- void loadChildAction( TQObject *parent, const TQDomElement &e );
+ void loadChildAction( TQObject *tqparent, const TQDomElement &e );
void loadToolBars( const TQDomElement &n );
void loadMenuBar( const TQDomElement &n );
TQColorGroup loadColorGroup( const TQDomElement &e );
diff --git a/kommander/editor/sizehandle.cpp b/kommander/editor/sizehandle.cpp
index a5ebe0ec..af5efea9 100644
--- a/kommander/editor/sizehandle.cpp
+++ b/kommander/editor/sizehandle.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -30,8 +30,8 @@
#include <klocale.h>
-SizeHandle::SizeHandle( FormWindow *parent, Direction d, WidgetSelection *s )
- : TQWidget( parent )
+SizeHandle::SizeHandle( FormWindow *tqparent, Direction d, WidgetSelection *s )
+ : TQWidget( tqparent )
{
active = true;
setBackgroundMode( active ? PaletteText : PaletteDark );
@@ -39,7 +39,7 @@ SizeHandle::SizeHandle( FormWindow *parent, Direction d, WidgetSelection *s )
widget = 0;
dir =d ;
setMouseTracking( false );
- formWindow = parent;
+ formWindow = tqparent;
sel = s;
updateCursor();
}
@@ -93,7 +93,7 @@ void SizeHandle::setWidget( TQWidget *w )
void SizeHandle::paintEvent( TQPaintEvent * )
{
- if ( ( (FormWindow*)parentWidget() )->currentWidget() != widget )
+ if ( ( (FormWindow*)tqparentWidget() )->currentWidget() != widget )
return;
TQPainter p( this );
p.setPen( blue );
@@ -102,7 +102,7 @@ void SizeHandle::paintEvent( TQPaintEvent * )
void SizeHandle::mousePressEvent( TQMouseEvent *e )
{
- if ( !widget || e->button() != LeftButton || !active )
+ if ( !widget || e->button() != Qt::LeftButton || !active )
return;
oldPressPos = e->pos();
geom = origGeom = TQRect( widget->pos(), widget->size() );
@@ -110,13 +110,13 @@ void SizeHandle::mousePressEvent( TQMouseEvent *e )
void SizeHandle::mouseMoveEvent( TQMouseEvent *e )
{
- if ( !widget || ( e->state() & LeftButton ) != LeftButton || !active )
+ if ( !widget || ( e->state() & Qt::LeftButton ) != Qt::LeftButton || !active )
return;
TQPoint rp = mapFromGlobal( e->globalPos() );
TQPoint d = oldPressPos - rp;
oldPressPos = rp;
- TQPoint checkPos = widget->parentWidget()->mapFromGlobal( e->globalPos() );
- TQRect pr = widget->parentWidget()->rect();
+ TQPoint checkPos = widget->tqparentWidget()->mapFromGlobal( e->globalPos() );
+ TQRect pr = widget->tqparentWidget()->rect();
// ##### move code around a bit to reduce duplicated code here
switch ( dir ) {
@@ -208,7 +208,7 @@ void SizeHandle::mouseMoveEvent( TQMouseEvent *e )
sel->updateGeometry();
oldPressPos += ( p - pos() );
- formWindow->sizePreview()->setText( TQString( "%1/%2" ).arg( widget->width() ).arg( widget->height() ) );
+ formWindow->sizePreview()->setText( TQString( "%1/%2" ).tqarg( widget->width() ).tqarg( widget->height() ) );
formWindow->sizePreview()->adjustSize();
TQRect lg( formWindow->mapFromGlobal( e->globalPos() ) + TQPoint( 16, 16 ),
formWindow->sizePreview()->size() );
@@ -216,55 +216,55 @@ void SizeHandle::mouseMoveEvent( TQMouseEvent *e )
formWindow->sizePreview()->setGeometry( lg );
formWindow->sizePreview()->show();
formWindow->sizePreview()->raise();
- if ( WidgetFactory::layoutType( widget ) != WidgetFactory::NoLayout )
+ if ( WidgetFactory::tqlayoutType( widget ) != WidgetFactory::NoLayout )
formWindow->updateChildSelections( widget );
}
void SizeHandle::mouseReleaseEvent( TQMouseEvent *e )
{
- if ( e->button() != LeftButton || !active )
+ if ( e->button() != Qt::LeftButton || !active )
return;
formWindow->sizePreview()->hide();
- if ( geom != widget->geometry() )
+ if ( geom != widget->tqgeometry() )
formWindow->commandHistory()->addCommand( new ResizeCommand( i18n("Resize" ),
formWindow,
widget, origGeom,
- widget->geometry() ) );
- formWindow->emitUpdateProperties( widget );
+ widget->tqgeometry() ) );
+ formWindow->emitUpdateProperties( TQT_TQOBJECT(widget) );
}
void SizeHandle::trySetGeometry( TQWidget *w, int x, int y, int width, int height )
{
- int minw = QMAX( w->minimumSizeHint().width(), w->minimumSize().width() );
- minw = QMAX( minw, 2 * formWindow->grid().x() );
- int minh = QMAX( w->minimumSizeHint().height(), w->minimumSize().height() );
- minh = QMAX( minh, 2 * formWindow->grid().y() );
- if ( QMAX( minw, width ) > w->maximumWidth() ||
- QMAX( minh, height ) > w->maximumHeight() )
+ int minw = TQMAX( w->tqminimumSizeHint().width(), w->tqminimumSize().width() );
+ minw = TQMAX( minw, 2 * formWindow->grid().x() );
+ int minh = TQMAX( w->tqminimumSizeHint().height(), w->tqminimumSize().height() );
+ minh = TQMAX( minh, 2 * formWindow->grid().y() );
+ if ( TQMAX( minw, width ) > w->maximumWidth() ||
+ TQMAX( minh, height ) > w->maximumHeight() )
return;
if ( width < minw && x != w->x() )
x -= minw - width;
if ( height < minh && y != w->y() )
y -= minh - height;
- w->setGeometry( x, y, QMAX( minw, width ), QMAX( minh, height ) );
+ w->setGeometry( x, y, TQMAX( minw, width ), TQMAX( minh, height ) );
}
void SizeHandle::tryResize( TQWidget *w, int width, int height )
{
- int minw = QMAX( w->minimumSizeHint().width(), w->minimumSize().width() );
- minw = QMAX( minw, 16 );
- int minh = QMAX( w->minimumSizeHint().height(), w->minimumSize().height() );
- minh = QMAX( minh, 16 );
- w->resize( QMAX( minw, width ), QMAX( minh, height ) );
+ int minw = TQMAX( w->tqminimumSizeHint().width(), w->tqminimumSize().width() );
+ minw = TQMAX( minw, 16 );
+ int minh = TQMAX( w->tqminimumSizeHint().height(), w->tqminimumSize().height() );
+ minh = TQMAX( minh, 16 );
+ w->resize( TQMAX( minw, width ), TQMAX( minh, height ) );
}
// ------------------------------------------------------------------------
-WidgetSelection::WidgetSelection( FormWindow *parent, TQPtrDict<WidgetSelection> *selDict )
+WidgetSelection::WidgetSelection( FormWindow *tqparent, TQPtrDict<WidgetSelection> *selDict )
: selectionDict( selDict )
{
- formWindow = parent;
+ formWindow = tqparent;
for ( int i = SizeHandle::LeftTop; i <= SizeHandle::Left; ++i ) {
handles.insert( i, new SizeHandle( formWindow, (SizeHandle::Direction)i, this ) );
}
@@ -282,7 +282,7 @@ void WidgetSelection::setWidget( TQWidget *w, bool updateDict )
}
wid = w;
- bool active = !wid->parentWidget() || WidgetFactory::layoutType( wid->parentWidget() ) == WidgetFactory::NoLayout;
+ bool active = !wid->tqparentWidget() || WidgetFactory::tqlayoutType( wid->tqparentWidget() ) == WidgetFactory::NoLayout;
for ( int i = SizeHandle::LeftTop; i <= SizeHandle::Left; ++i ) {
SizeHandle *h = handles[ i ];
if ( h ) {
@@ -306,7 +306,7 @@ void WidgetSelection::updateGeometry()
if ( !wid )
return;
- TQPoint p = wid->parentWidget()->mapToGlobal( wid->pos() );
+ TQPoint p = wid->tqparentWidget()->mapToGlobal( wid->pos() );
p = formWindow->mapFromGlobal( p );
TQRect r( p, wid->size() );
diff --git a/kommander/editor/sizehandle.h b/kommander/editor/sizehandle.h
index 50d3ea1c..4def5429 100644
--- a/kommander/editor/sizehandle.h
+++ b/kommander/editor/sizehandle.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -30,14 +30,15 @@ class FormWindow;
class WidgetSelection;
class TQPaintEvent;
-class SizeHandle : public QWidget
+class SizeHandle : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
enum Direction { LeftTop, Top, RightTop, Right, RightBottom, Bottom, LeftBottom, Left };
- SizeHandle( FormWindow *parent, Direction d, WidgetSelection *s );
+ SizeHandle( FormWindow *tqparent, Direction d, WidgetSelection *s );
void setWidget( TQWidget *w );
void setActive( bool a );
void updateCursor();
@@ -68,7 +69,7 @@ private:
class WidgetSelection
{
public:
- WidgetSelection( FormWindow *parent, TQPtrDict<WidgetSelection> *selDict );
+ WidgetSelection( FormWindow *tqparent, TQPtrDict<WidgetSelection> *selDict );
void setWidget( TQWidget *w, bool updateDict = TRUE );
bool isUsed() const;
diff --git a/kommander/editor/styledbutton.cpp b/kommander/editor/styledbutton.cpp
index 4502b2a3..95f57d39 100644
--- a/kommander/editor/styledbutton.cpp
+++ b/kommander/editor/styledbutton.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -32,10 +32,10 @@
#include <tqdragobject.h>
#include <tqstyle.h>
-StyledButton::StyledButton(TQWidget* parent, const char* name)
- : TQButton( parent, name ), pix( 0 ), spix( 0 ), s( 0 ), formWindow( 0 ), mousePressed( false )
+StyledButton::StyledButton(TQWidget* tqparent, const char* name)
+ : TQButton( tqparent, name ), pix( 0 ), spix( 0 ), s( 0 ), formWindow( 0 ), mousePressed( false )
{
- setMinimumSize( minimumSizeHint() );
+ setMinimumSize( tqminimumSizeHint() );
setAcceptDrops( true );
connect( this, TQT_SIGNAL(clicked()), TQT_SLOT(onEditor()));
@@ -43,12 +43,12 @@ StyledButton::StyledButton(TQWidget* parent, const char* name)
setEditor( ColorEditor );
}
-StyledButton::StyledButton( const TQBrush& b, TQWidget* parent, const char* name, WFlags f )
- : TQButton( parent, name, f ), spix( 0 ), s( 0 ), formWindow( 0 )
+StyledButton::StyledButton( const TQBrush& b, TQWidget* tqparent, const char* name, WFlags f )
+ : TQButton( tqparent, name, f ), spix( 0 ), s( 0 ), formWindow( 0 )
{
col = b.color();
pix = b.pixmap();
- setMinimumSize( minimumSizeHint() );
+ setMinimumSize( tqminimumSizeHint() );
}
StyledButton::~StyledButton()
@@ -111,12 +111,12 @@ void StyledButton::setScale( bool on )
scalePixmap();
}
-TQSize StyledButton::sizeHint() const
+TQSize StyledButton::tqsizeHint() const
{
return TQSize( 50, 25 );
}
-TQSize StyledButton::minimumSizeHint() const
+TQSize StyledButton::tqminimumSizeHint() const
{
return TQSize( 50, 25 );
}
@@ -145,25 +145,25 @@ void StyledButton::resizeEvent( TQResizeEvent* e )
void StyledButton::drawButton( TQPainter *paint )
{
- style().drawPrimitive(TQStyle::PE_ButtonBevel, paint, rect(), colorGroup(),
+ tqstyle().tqdrawPrimitive(TQStyle::PE_ButtonBevel, paint, rect(), tqcolorGroup(),
isDown() ? TQStyle::Style_Sunken : TQStyle::Style_Raised);
drawButtonLabel(paint);
if (hasFocus())
- style().drawPrimitive(TQStyle::PE_FocusRect, paint,
- style().subRect(TQStyle::SR_PushButtonFocusRect, this),
- colorGroup(), TQStyle::Style_Default);
+ tqstyle().tqdrawPrimitive(TQStyle::PE_FocusRect, paint,
+ tqstyle().subRect(TQStyle::SR_PushButtonFocusRect, this),
+ tqcolorGroup(), TQStyle::Style_Default);
}
void StyledButton::drawButtonLabel( TQPainter *paint )
{
TQColor pen = isEnabled() ?
- hasFocus() ? palette().active().buttonText() : palette().inactive().buttonText()
- : palette().disabled().buttonText();
+ hasFocus() ? tqpalette().active().buttonText() : tqpalette().inactive().buttonText()
+ : tqpalette().disabled().buttonText();
paint->setPen( pen );
if(!isEnabled()) {
- paint->setBrush( TQBrush( colorGroup().button() ) );
+ paint->setBrush( TQBrush( tqcolorGroup().button() ) );
}
else if ( edit == PixmapEditor && spix ) {
paint->setBrush( TQBrush( col, *spix ) );
@@ -178,7 +178,7 @@ void StyledButton::onEditor()
{
switch (edit) {
case ColorEditor: {
- TQColor c = palette().active().background();
+ TQColor c = tqpalette().active().background();
if ( KColorDialog::getColor( c, this ) == TQDialog::Accepted ) {
setColor( c );
emit changed();
@@ -210,7 +210,7 @@ void StyledButton::mousePressEvent(TQMouseEvent* e)
void StyledButton::mouseMoveEvent(TQMouseEvent* e)
{
TQButton::mouseMoveEvent( e );
-#ifndef QT_NO_DRAGANDDROP
+#ifndef TQT_NO_DRAGANDDROP
if ( !mousePressed )
return;
if ( ( pressPos - e->pos() ).manhattanLength() > TQApplication::startDragDistance() ) {
@@ -237,7 +237,7 @@ void StyledButton::mouseMoveEvent(TQMouseEvent* e)
#endif
}
-#ifndef QT_NO_DRAGANDDROP
+#ifndef TQT_NO_DRAGANDDROP
void StyledButton::dragEnterEvent( TQDragEnterEvent *e )
{
setFocus();
@@ -252,7 +252,7 @@ void StyledButton::dragEnterEvent( TQDragEnterEvent *e )
void StyledButton::dragLeaveEvent( TQDragLeaveEvent * )
{
if ( hasFocus() )
- parentWidget()->setFocus();
+ tqparentWidget()->setFocus();
}
void StyledButton::dragMoveEvent( TQDragMoveEvent *e )
@@ -286,5 +286,5 @@ void StyledButton::dropEvent( TQDropEvent *e )
e->ignore();
}
}
-#endif // QT_NO_DRAGANDDROP
+#endif // TQT_NO_DRAGANDDROP
#include "styledbutton.moc"
diff --git a/kommander/editor/styledbutton.h b/kommander/editor/styledbutton.h
index cb5f4e92..a8daca52 100644
--- a/kommander/editor/styledbutton.h
+++ b/kommander/editor/styledbutton.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -28,22 +28,23 @@ class TQColor;
class TQBrush;
class FormWindow;
-class StyledButton : public QButton
+class StyledButton : public TQButton
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY( TQColor color READ color WRITE setColor )
- Q_PROPERTY( TQPixmap pixmap READ pixmap WRITE setPixmap )
- Q_PROPERTY( EditorType editor READ editor WRITE setEditor )
- Q_PROPERTY( bool scale READ scale WRITE setScale )
+ TQ_PROPERTY( TQColor color READ color WRITE setColor )
+ TQ_PROPERTY( TQPixmap pixmap READ pixmap WRITE setPixmap )
+ TQ_PROPERTY( EditorType editor READ editor WRITE setEditor )
+ TQ_PROPERTY( bool scale READ scale WRITE setScale )
Q_ENUMS( EditorType )
public:
enum EditorType { ColorEditor, PixmapEditor };
- StyledButton( TQWidget* parent = 0, const char* name = 0 );
- StyledButton( const TQBrush& b, TQWidget* parent = 0, const char* name = 0, WFlags f = 0 );
+ StyledButton( TQWidget* tqparent = 0, const char* name = 0 );
+ StyledButton( const TQBrush& b, TQWidget* tqparent = 0, const char* name = 0, WFlags f = 0 );
~StyledButton();
void setEditor( EditorType );
@@ -58,8 +59,8 @@ public:
void setScale( bool );
bool scale() const;
- TQSize sizeHint() const;
- TQSize minimumSizeHint() const;
+ TQSize tqsizeHint() const;
+ TQSize tqminimumSizeHint() const;
void setFormWindow( FormWindow *fw ) { formWindow = fw; }
@@ -72,12 +73,12 @@ signals:
protected:
void mousePressEvent(TQMouseEvent*);
void mouseMoveEvent(TQMouseEvent*);
-#ifndef QT_NO_DRAGANDDROP
+#ifndef TQT_NO_DRAGANDDROP
void dragEnterEvent ( TQDragEnterEvent * );
void dragMoveEvent ( TQDragMoveEvent * );
void dragLeaveEvent ( TQDragLeaveEvent * );
void dropEvent ( TQDropEvent * );
-#endif // QT_NO_DRAGANDDROP
+#endif // TQT_NO_DRAGANDDROP
void drawButton( TQPainter* );
void drawButtonLabel( TQPainter* );
void resizeEvent( TQResizeEvent* );
diff --git a/kommander/editor/tableeditor.ui b/kommander/editor/tableeditor.ui
index 26345a3f..b3331a98 100644
--- a/kommander/editor/tableeditor.ui
+++ b/kommander/editor/tableeditor.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.0" stdsetdef="1">
<class>TableEditorBase</class>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>TableEditorBase</cstring>
</property>
@@ -28,7 +28,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QTable" row="0" column="0">
+ <widget class="TQTable" row="0" column="0">
<column>
<property name="text">
<string>1</string>
@@ -52,7 +52,7 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QLayoutWidget" row="1" column="0" rowspan="1" colspan="2">
+ <widget class="TQLayoutWidget" row="1" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>Layout11</cstring>
</property>
@@ -66,7 +66,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonHelp</cstring>
</property>
@@ -87,14 +87,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonOk</cstring>
</property>
@@ -111,7 +111,7 @@
<string>Close the dialog and apply all the changes.</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonApply</cstring>
</property>
@@ -125,7 +125,7 @@
<string>Apply all changes.</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonCancel</cstring>
</property>
@@ -141,11 +141,11 @@
</widget>
</hbox>
</widget>
- <widget class="QTabWidget" row="0" column="1">
+ <widget class="TQTabWidget" row="0" column="1">
<property name="name">
<cstring>TabWidget</cstring>
</property>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>columns_tab</cstring>
</property>
@@ -172,14 +172,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QListBox" row="0" column="0" rowspan="6" colspan="1">
+ <widget class="TQListBox" row="0" column="0" rowspan="6" colspan="1">
<property name="name">
<cstring>listColumns</cstring>
</property>
@@ -194,14 +194,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton" row="4" column="1">
+ <widget class="TQPushButton" row="4" column="1">
<property name="name">
<cstring>buttonColumnUp</cstring>
</property>
@@ -218,7 +218,7 @@
<string>&lt;b&gt;Move the selected item up.&lt;/b&gt;&lt;p&gt;The top-most column will be the first column of the list.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QPushButton" row="5" column="1">
+ <widget class="TQPushButton" row="5" column="1">
<property name="name">
<cstring>buttonColumnDown</cstring>
</property>
@@ -235,7 +235,7 @@
<string>&lt;b&gt;Move the selected item down.&lt;/b&gt;&lt;p&gt;The top-most column will be the first column of the list.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QPushButton" row="1" column="1">
+ <widget class="TQPushButton" row="1" column="1">
<property name="name">
<cstring>buttonDeleteColumn</cstring>
</property>
@@ -243,7 +243,7 @@
<string>&amp;Delete Column</string>
</property>
</widget>
- <widget class="QPushButton" row="0" column="1">
+ <widget class="TQPushButton" row="0" column="1">
<property name="name">
<cstring>buttonNewColumn</cstring>
</property>
@@ -251,7 +251,7 @@
<string>&amp;New Column</string>
</property>
</widget>
- <widget class="QLayoutWidget" row="2" column="1" rowspan="1" colspan="2">
+ <widget class="TQLayoutWidget" row="2" column="1" rowspan="1" colspan="2">
<property name="name">
<cstring>Layout6</cstring>
</property>
@@ -265,7 +265,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>labelTable</cstring>
</property>
@@ -273,7 +273,7 @@
<string>Table:</string>
</property>
</widget>
- <widget class="QLayoutWidget" row="3" column="1">
+ <widget class="TQLayoutWidget" row="3" column="1">
<property name="name">
<cstring>Layout2</cstring>
</property>
@@ -287,7 +287,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>labelColumnPixmap</cstring>
</property>
@@ -295,11 +295,11 @@
<string>Label4</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonDeleteColPixmap</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>30</width>
<height>22</height>
@@ -318,11 +318,11 @@
<string>&lt;b&gt;Delete the selected item's pixmap.&lt;/b&gt;&lt;p&gt;The pixmap in the current column of the selected item will be deleted.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonChooseColPixmap</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>30</width>
<height>22</height>
@@ -340,7 +340,7 @@
</widget>
</hbox>
</widget>
- <widget class="QLabel" row="2" column="0">
+ <widget class="TQLabel" row="2" column="0">
<property name="name">
<cstring>TextLabel2</cstring>
</property>
@@ -351,7 +351,7 @@
<cstring>editColumnText</cstring>
</property>
</widget>
- <widget class="QLabel" row="3" column="0">
+ <widget class="TQLabel" row="3" column="0">
<property name="name">
<cstring>Label2</cstring>
</property>
@@ -362,7 +362,7 @@
<cstring>itemChoosePixmap</cstring>
</property>
</widget>
- <widget class="QLabel" row="1" column="0">
+ <widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>labelFields</cstring>
</property>
@@ -373,12 +373,12 @@
<cstring>comboFields</cstring>
</property>
</widget>
- <widget class="QLineEdit" row="2" column="1">
+ <widget class="TQLineEdit" row="2" column="1">
<property name="name">
<cstring>editColumnText</cstring>
</property>
</widget>
- <widget class="QComboBox" row="1" column="1">
+ <widget class="TQComboBox" row="1" column="1">
<property name="name">
<cstring>comboFields</cstring>
</property>
@@ -386,7 +386,7 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QLabel" row="0" column="1">
+ <widget class="TQLabel" row="0" column="1">
<property name="name">
<cstring>labelTableValue</cstring>
</property>
@@ -398,7 +398,7 @@
</widget>
</grid>
</widget>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>rows_tab</cstring>
</property>
@@ -425,14 +425,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton" row="4" column="1">
+ <widget class="TQPushButton" row="4" column="1">
<property name="name">
<cstring>buttonRowUp</cstring>
</property>
@@ -449,12 +449,12 @@
<string>&lt;b&gt;Move the selected item up.&lt;/b&gt;&lt;p&gt;The top-most column will be the first column of the list.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QListBox" row="0" column="0" rowspan="6" colspan="1">
+ <widget class="TQListBox" row="0" column="0" rowspan="6" colspan="1">
<property name="name">
<cstring>listRows</cstring>
</property>
</widget>
- <widget class="QPushButton" row="5" column="1">
+ <widget class="TQPushButton" row="5" column="1">
<property name="name">
<cstring>buttonRowDown</cstring>
</property>
@@ -481,14 +481,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton" row="0" column="1">
+ <widget class="TQPushButton" row="0" column="1">
<property name="name">
<cstring>buttonNewRow</cstring>
</property>
@@ -496,7 +496,7 @@
<string>&amp;New Row</string>
</property>
</widget>
- <widget class="QPushButton" row="1" column="1">
+ <widget class="TQPushButton" row="1" column="1">
<property name="name">
<cstring>buttonDeleteRow</cstring>
</property>
@@ -504,7 +504,7 @@
<string>&amp;Delete Row</string>
</property>
</widget>
- <widget class="QLayoutWidget" row="2" column="1" rowspan="1" colspan="2">
+ <widget class="TQLayoutWidget" row="2" column="1" rowspan="1" colspan="2">
<property name="name">
<cstring>Layout7_2</cstring>
</property>
@@ -518,7 +518,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>TextLabel2_3</cstring>
</property>
@@ -529,7 +529,7 @@
<cstring>editRowText</cstring>
</property>
</widget>
- <widget class="QLabel" row="1" column="0">
+ <widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>Label2_2</cstring>
</property>
@@ -540,7 +540,7 @@
<cstring>itemChoosePixmap</cstring>
</property>
</widget>
- <widget class="QLayoutWidget" row="1" column="1">
+ <widget class="TQLayoutWidget" row="1" column="1">
<property name="name">
<cstring>Layout2_2</cstring>
</property>
@@ -554,7 +554,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>labelRowPixmap</cstring>
</property>
@@ -562,11 +562,11 @@
<string>Label4</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonDeleteRowPixmap</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>30</width>
<height>22</height>
@@ -585,11 +585,11 @@
<string>&lt;b&gt;Delete the selected item's pixmap.&lt;/b&gt;&lt;p&gt;The pixmap in the current column of the selected item will be deleted.&lt;/p&gt;</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonChooseRowPixmap</cstring>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>30</width>
<height>22</height>
@@ -607,7 +607,7 @@
</widget>
</hbox>
</widget>
- <widget class="QLineEdit" row="0" column="1">
+ <widget class="TQLineEdit" row="0" column="1">
<property name="name">
<cstring>editRowText</cstring>
</property>
@@ -645,15 +645,15 @@
</connection>
<connection>
<sender>listColumns</sender>
- <signal>currentChanged(QListBoxItem*)</signal>
+ <signal>currentChanged(TQListBoxItem*)</signal>
<receiver>TableEditorBase</receiver>
- <slot>currentColumnChanged(QListBoxItem*)</slot>
+ <slot>currentColumnChanged(TQListBoxItem*)</slot>
</connection>
<connection>
<sender>listColumns</sender>
- <signal>selectionChanged(QListBoxItem*)</signal>
+ <signal>selectionChanged(TQListBoxItem*)</signal>
<receiver>TableEditorBase</receiver>
- <slot>currentColumnChanged(QListBoxItem*)</slot>
+ <slot>currentColumnChanged(TQListBoxItem*)</slot>
</connection>
<connection>
<sender>editColumnText</sender>
@@ -693,15 +693,15 @@
</connection>
<connection>
<sender>listRows</sender>
- <signal>selectionChanged(QListBoxItem*)</signal>
+ <signal>selectionChanged(TQListBoxItem*)</signal>
<receiver>TableEditorBase</receiver>
- <slot>currentRowChanged(QListBoxItem*)</slot>
+ <slot>currentRowChanged(TQListBoxItem*)</slot>
</connection>
<connection>
<sender>listRows</sender>
- <signal>currentChanged(QListBoxItem*)</signal>
+ <signal>currentChanged(TQListBoxItem*)</signal>
<receiver>TableEditorBase</receiver>
- <slot>currentRowChanged(QListBoxItem*)</slot>
+ <slot>currentRowChanged(TQListBoxItem*)</slot>
</connection>
<connection>
<sender>buttonNewRow</sender>
@@ -769,9 +769,9 @@
<slot access="protected" language="C++" returnType="void">chooseRowPixmapClicked()</slot>
<slot access="protected" language="C++" returnType="void">columnTextChanged( const QString &amp; )</slot>
<slot access="protected" language="C++" returnType="void">columnUpClicked()</slot>
- <slot access="protected" language="C++" returnType="void">currentColumnChanged( QListBoxItem * )</slot>
+ <slot access="protected" language="C++" returnType="void">currentColumnChanged( TQListBoxItem * )</slot>
<slot access="protected" language="C++" returnType="void">currentFieldChanged( const QString &amp; )</slot>
- <slot access="protected" language="C++" returnType="void">currentRowChanged( QListBoxItem * )</slot>
+ <slot access="protected" language="C++" returnType="void">currentRowChanged( TQListBoxItem * )</slot>
<slot access="protected" language="C++" returnType="void">deleteColPixmapClicked()</slot>
<slot access="protected" language="C++" returnType="void">deleteColumnClicked()</slot>
<slot access="protected" language="C++" returnType="void">deleteRowClicked()</slot>
diff --git a/kommander/editor/tableeditorimpl.cpp b/kommander/editor/tableeditorimpl.cpp
index 58cc554d..e5b39340 100644
--- a/kommander/editor/tableeditorimpl.cpp
+++ b/kommander/editor/tableeditorimpl.cpp
@@ -1,5 +1,5 @@
#include "tableeditorimpl.h"
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
#include <tqtable.h>
#endif
#include "formwindow.h"
@@ -21,15 +21,15 @@
#include <klocale.h>
-TableEditor::TableEditor( TQWidget* parent, TQWidget *editWidget, FormWindow *fw, const char* name, bool modal, WFlags fl )
- : TableEditorBase( parent, name, modal, fl ),
-#ifndef QT_NO_TABLE
+TableEditor::TableEditor( TQWidget* tqparent, TQWidget *editWidget, FormWindow *fw, const char* name, bool modal, WFlags fl )
+ : TableEditorBase( tqparent, name, modal, fl ),
+#ifndef TQT_NO_TABLE
editTable( (TQTable*)editWidget ),
#endif
formWindow( fw )
{
connect( buttonHelp, TQT_SIGNAL( clicked() ), MainWindow::self, TQT_SLOT( showDialogHelp() ) );
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
labelColumnPixmap->setText( "" );
labelRowPixmap->setText( "" );
@@ -39,7 +39,7 @@ TableEditor::TableEditor( TQWidget* parent, TQWidget *editWidget, FormWindow *f
labelTable->hide();
labelTableValue->hide();
}
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
if ( editTable->inherits( TQDATATABLE_OBJECT_NAME_STRING ) ) {
// ## why does this behave weird?
// TabWidget->removePage( rows_tab );
@@ -93,7 +93,7 @@ void TableEditor::columnTextChanged( const TQString &s )
listColumns->blockSignals( true );
listColumns->changeItem( s, listColumns->currentItem() );
listColumns->blockSignals( false );
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
if ( table->horizontalHeader()->iconSet( listColumns->currentItem() ) )
table->horizontalHeader()->setLabel( listColumns->currentItem(),
*table->horizontalHeader()->iconSet( listColumns->currentItem() ), s );
@@ -130,13 +130,13 @@ void TableEditor::currentColumnChanged( TQListBoxItem *i )
labelColumnPixmap->setText( "" );
editColumnText->blockSignals( false );
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
if ( editTable->inherits( TQDATATABLE_OBJECT_NAME_STRING ) ) {
- TQString s = *fieldMap.find( listColumns->index( i ) );
+ TQString s = *fieldMap.tqfind( listColumns->index( i ) );
if ( s.isEmpty() )
comboFields->setCurrentItem( 0 );
- else if ( comboFields->listBox()->findItem( s ) )
- comboFields->setCurrentItem( comboFields->listBox()->index( comboFields->listBox()->findItem( s ) ) );
+ else if ( comboFields->listBox()->tqfindItem( s ) )
+ comboFields->setCurrentItem( comboFields->listBox()->index( comboFields->listBox()->tqfindItem( s ) ) );
else
comboFields->lineEdit()->setText( s );
}
@@ -173,7 +173,7 @@ void TableEditor::deleteColumnClicked()
{
if ( listColumns->currentItem() == -1 )
return;
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
table->setNumCols( table->numCols() - 1 );
delete listColumns->item( listColumns->currentItem() );
readColumns();
@@ -188,7 +188,7 @@ void TableEditor::deleteRowClicked()
{
if ( listRows->currentItem() == -1 )
return;
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
table->setNumRows( table->numRows() - 1 );
delete listRows->item( listRows->currentItem() );
readRows();
@@ -201,14 +201,14 @@ void TableEditor::deleteRowClicked()
void TableEditor::newColumnClicked()
{
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
table->setNumCols( table->numCols() + 1 );
TQMap<TQString, bool> m;
for ( int i = 0; i < table->numCols() - 1; ++i )
m.insert( table->horizontalHeader()->label( i ), true );
int n = table->numCols() - 1;
TQString t = TQString::number( n );
- while ( m.find( t ) != m.end() )
+ while ( m.tqfind( t ) != m.end() )
t = TQString::number( ++n );
table->horizontalHeader()->setLabel( table->numCols() - 1, t );
listColumns->insertItem( t );
@@ -226,14 +226,14 @@ void TableEditor::newColumnClicked()
void TableEditor::newRowClicked()
{
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
table->setNumRows( table->numRows() + 1 );
TQMap<TQString, bool> m;
for ( int i = 0; i < table->numRows() - 1; ++i )
m.insert( table->verticalHeader()->label( i ), true );
int n = table->numRows() - 1;
TQString t = TQString::number( n );
- while ( m.find( t ) != m.end() )
+ while ( m.tqfind( t ) != m.end() )
t = TQString::number( ++n );
table->verticalHeader()->setLabel( table->numRows() - 1, t );
listRows->insertItem( t );
@@ -267,7 +267,7 @@ void TableEditor::rowTextChanged( const TQString &s )
{
if ( listRows->currentItem() == -1 )
return;
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
listRows->changeItem( s, listRows->currentItem() );
if ( table->verticalHeader()->iconSet( listRows->currentItem() ) )
table->verticalHeader()->setLabel( listRows->currentItem(),
@@ -296,13 +296,13 @@ void TableEditor::applyClicked()
TQValueList<PopulateTableCommand::Column> cols;
int i = 0;
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
for ( i = 0; i < table->horizontalHeader()->count(); ++i ) {
PopulateTableCommand::Column col;
col.text = table->horizontalHeader()->label( i );
if ( table->horizontalHeader()->iconSet( i ) )
col.pix = table->horizontalHeader()->iconSet( i )->pixmap();
- col.field = *fieldMap.find( i );
+ col.field = *fieldMap.tqfind( i );
cols.append( col );
}
for ( i = 0; i < table->verticalHeader()->count(); ++i ) {
@@ -312,7 +312,7 @@ void TableEditor::applyClicked()
row.pix = table->verticalHeader()->iconSet( i )->pixmap();
rows.append( row );
}
- PopulateTableCommand *cmd = new PopulateTableCommand( i18n("Edit Rows and Columns of '%1' " ).arg( editTable->name() ),
+ PopulateTableCommand *cmd = new PopulateTableCommand( i18n("Edit Rows and Columns of '%1' " ).tqarg( editTable->name() ),
formWindow, editTable, rows, cols );
cmd->execute();
formWindow->commandHistory()->addCommand( cmd );
@@ -332,7 +332,7 @@ void TableEditor::chooseRowPixmapClicked()
if ( pix.isNull() )
return;
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
table->verticalHeader()->setLabel( listRows->currentItem(), pix, table->verticalHeader()->label( listRows->currentItem() ) );
listRows->changeItem( pix, listRows->currentText(), listRows->currentItem() );
#endif
@@ -342,7 +342,7 @@ void TableEditor::deleteRowPixmapClicked()
{
if ( listRows->currentItem() == -1 )
return;
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
table->verticalHeader()->setLabel( listRows->currentItem(), TQPixmap(), table->verticalHeader()->label( listRows->currentItem() ) );
listRows->changeItem( listRows->currentText(), listRows->currentItem() );
#endif
@@ -360,7 +360,7 @@ void TableEditor::chooseColPixmapClicked()
if ( pix.isNull() )
return;
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
table->horizontalHeader()->setLabel( listColumns->currentItem(), pix, table->horizontalHeader()->label( listColumns->currentItem() ) );
listColumns->changeItem( pix, listColumns->currentText(), listColumns->currentItem() );
#endif
@@ -370,7 +370,7 @@ void TableEditor::deleteColPixmapClicked()
{
if ( listColumns->currentItem() == -1 )
return;
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
table->horizontalHeader()->setLabel( listColumns->currentItem(), TQPixmap(), table->horizontalHeader()->label( listColumns->currentItem() ) );
listColumns->changeItem( listColumns->currentText(), listColumns->currentItem() );
#endif
@@ -378,10 +378,10 @@ void TableEditor::deleteColPixmapClicked()
void TableEditor::readFromTable()
{
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
TQHeader *cols = editTable->horizontalHeader();
table->setNumCols( cols->count() );
- TQMap<TQString, TQString> columnFields = MetaDataBase::columnFields( editTable );
+ TQMap<TQString, TQString> columnFields = MetaDataBase::columnFields( TQT_TQOBJECT(editTable) );
for ( int i = 0; i < cols->count(); ++i ) {
if ( editTable->horizontalHeader()->iconSet( i ) ) {
table->horizontalHeader()->setLabel( i, *editTable->horizontalHeader()->iconSet( i ),
@@ -392,7 +392,7 @@ void TableEditor::readFromTable()
table->horizontalHeader()->setLabel( i, editTable->horizontalHeader()->label( i ) );
listColumns->insertItem( editTable->horizontalHeader()->label( i ) );
}
- TQString cf = *columnFields.find( editTable->horizontalHeader()->label( i ) );
+ TQString cf = *columnFields.tqfind( editTable->horizontalHeader()->label( i ) );
fieldMap.insert( i, cf );
}
@@ -425,7 +425,7 @@ void TableEditor::readFromTable()
void TableEditor::readColumns()
{
int j = 0;
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
for ( TQListBoxItem *i = listColumns->firstItem(); i; i = i->next(), ++j ) {
if ( i->pixmap() )
table->horizontalHeader()->setLabel( j, *i->pixmap(), i->text() );
@@ -438,7 +438,7 @@ void TableEditor::readColumns()
void TableEditor::readRows()
{
int j = 0;
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
for ( TQListBoxItem *i = listRows->firstItem(); i; i = i->next(), ++j ) {
if ( i->pixmap() )
table->verticalHeader()->setLabel( j, *i->pixmap(), i->text() );
diff --git a/kommander/editor/tableeditorimpl.h b/kommander/editor/tableeditorimpl.h
index 5fb1ccc4..c0b8ce85 100644
--- a/kommander/editor/tableeditorimpl.h
+++ b/kommander/editor/tableeditorimpl.h
@@ -11,9 +11,10 @@ class FormWindow;
class TableEditor : public TableEditorBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- TableEditor( TQWidget* parent = 0, TQWidget *editWidget = 0, FormWindow *fw = 0,
+ TableEditor( TQWidget* tqparent = 0, TQWidget *editWidget = 0, FormWindow *fw = 0,
const char* name = 0, bool modal = FALSE, WFlags fl = 0 );
~TableEditor();
diff --git a/kommander/editor/templates/Configuration_Dialog.ui b/kommander/editor/templates/Configuration_Dialog.ui
index 199f5b90..4724398b 100644
--- a/kommander/editor/templates/Configuration_Dialog.ui
+++ b/kommander/editor/templates/Configuration_Dialog.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.1" stdsetdef="1">
<class>MyDialog2</class>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>MyDialog2</cstring>
</property>
@@ -25,7 +25,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QListBox" row="0" column="0">
+ <widget class="TQListBox" row="0" column="0">
<item>
<property name="text">
<string>New Item</string>
@@ -43,11 +43,11 @@
</sizepolicy>
</property>
</widget>
- <widget class="QTabWidget" row="0" column="1">
+ <widget class="TQTabWidget" row="0" column="1">
<property name="name">
<cstring>tabWidget</cstring>
</property>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>Widget2</cstring>
</property>
@@ -55,7 +55,7 @@
<string>Tab</string>
</attribute>
</widget>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>Widget3</cstring>
</property>
@@ -64,7 +64,7 @@
</attribute>
</widget>
</widget>
- <widget class="QLayoutWidget" row="1" column="0" rowspan="1" colspan="2">
+ <widget class="TQLayoutWidget" row="1" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -78,7 +78,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonHelp</cstring>
</property>
@@ -102,14 +102,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonOk</cstring>
</property>
@@ -123,7 +123,7 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonCancel</cstring>
</property>
@@ -152,5 +152,5 @@
<slot>reject()</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/editor/templates/Dialog_with_Buttons_(Bottom).ui b/kommander/editor/templates/Dialog_with_Buttons_(Bottom).ui
index 77d77cb3..6d9edca0 100644
--- a/kommander/editor/templates/Dialog_with_Buttons_(Bottom).ui
+++ b/kommander/editor/templates/Dialog_with_Buttons_(Bottom).ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.1" stdsetdef="1">
<class>MyDialog</class>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>MyDialog</cstring>
</property>
@@ -15,7 +15,7 @@
<property name="sizeGripEnabled">
<bool>true</bool>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -37,7 +37,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonHelp</cstring>
</property>
@@ -61,14 +61,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonOk</cstring>
</property>
@@ -82,7 +82,7 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonCancel</cstring>
</property>
@@ -110,5 +110,5 @@
<slot>reject()</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/editor/templates/Dialog_with_Buttons_(Right).ui b/kommander/editor/templates/Dialog_with_Buttons_(Right).ui
index fd2c01f0..93650a87 100644
--- a/kommander/editor/templates/Dialog_with_Buttons_(Right).ui
+++ b/kommander/editor/templates/Dialog_with_Buttons_(Right).ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.1" stdsetdef="1">
<class>MyDialog</class>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>MyDialog</cstring>
</property>
@@ -15,7 +15,7 @@
<property name="sizeGripEnabled">
<bool>true</bool>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout5</cstring>
</property>
@@ -37,7 +37,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonOk</cstring>
</property>
@@ -51,7 +51,7 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonCancel</cstring>
</property>
@@ -62,7 +62,7 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonHelp</cstring>
</property>
@@ -86,7 +86,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
@@ -110,5 +110,5 @@
<slot>reject()</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/editor/templates/Tab_Dialog.ui b/kommander/editor/templates/Tab_Dialog.ui
index a2ad9315..4e0a7124 100644
--- a/kommander/editor/templates/Tab_Dialog.ui
+++ b/kommander/editor/templates/Tab_Dialog.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.1" stdsetdef="1">
<class>MyDialog1</class>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>MyDialog1</cstring>
</property>
@@ -25,11 +25,11 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QTabWidget">
+ <widget class="TQTabWidget">
<property name="name">
<cstring>tabWidget</cstring>
</property>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>Widget8</cstring>
</property>
@@ -37,7 +37,7 @@
<string>Tab</string>
</attribute>
</widget>
- <widget class="QWidget">
+ <widget class="TQWidget">
<property name="name">
<cstring>Widget9</cstring>
</property>
@@ -46,7 +46,7 @@
</attribute>
</widget>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -60,7 +60,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonHelp</cstring>
</property>
@@ -84,14 +84,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonOk</cstring>
</property>
@@ -105,7 +105,7 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonCancel</cstring>
</property>
@@ -134,5 +134,5 @@
<slot>reject()</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/editor/timestamp.cpp b/kommander/editor/timestamp.cpp
index e92fc78f..62cac72d 100644
--- a/kommander/editor/timestamp.cpp
+++ b/kommander/editor/timestamp.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -24,8 +24,8 @@
class TQTimer;
-TimeStamp::TimeStamp( TQObject *parent, const TQString &f )
- : TQObject( parent ), filename( f ), autoCheck( false )
+TimeStamp::TimeStamp( TQObject *tqparent, const TQString &f )
+ : TQObject( tqparent ), filename( f ), autoCheck( false )
{
timer = new TQTimer( this );
connect( timer, TQT_SIGNAL( timeout() ), this, TQT_SLOT( autoCheckTimeStamp() ) );
diff --git a/kommander/editor/timestamp.h b/kommander/editor/timestamp.h
index d3e061f9..1df9f916 100644
--- a/kommander/editor/timestamp.h
+++ b/kommander/editor/timestamp.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -25,12 +25,13 @@
#include <tqdatetime.h>
#include <tqtimer.h>
-class TimeStamp : public QObject
+class TimeStamp : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
- TimeStamp( TQObject *parent, const TQString &f );
+ TimeStamp( TQObject *tqparent, const TQString &f );
void setFileName( const TQString &f );
TQString fileName() const;
diff --git a/kommander/editor/widgetdatabase.cpp b/kommander/editor/widgetdatabase.cpp
index 3661f700..73349c3b 100644
--- a/kommander/editor/widgetdatabase.cpp
+++ b/kommander/editor/widgetdatabase.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -53,13 +53,13 @@ static TQStrList *wGroups;
static TQStrList *invisibleGroups;
static bool whatsThisLoaded = false;
#ifndef KOMMANDER
-static QPluginManager<WidgetInterface> *widgetPluginManager = 0;
+static TQPluginManager<WidgetInterface> *widgetPluginManager = 0;
#endif
static bool plugins_set_up = false;
static bool was_in_setup = false;
#ifndef KOMMANDER
-TQCleanupHandler<QPluginManager<WidgetInterface> > cleanup_manager;
+TQCleanupHandler<TQPluginManager<WidgetInterface> > cleanup_manager;
#endif
WidgetDatabaseRecord::WidgetDatabaseRecord()
@@ -89,7 +89,7 @@ WidgetDatabaseRecord::~WidgetDatabaseRecord()
one application doesn't make sense anyway and so you don't need more
than an instance of the widgetdatabase.
- For creating widgets, layouts, etc. see WidgetFactory.
+ For creating widgets, tqlayouts, etc. see WidgetFactory.
*/
/*!
@@ -134,35 +134,35 @@ void WidgetDatabase::setupDataBase( int id )
/* Designer widgets */
r = new WidgetDatabaseRecord;
r->iconName = "pushbutton.xpm";
- r->name = "TQPushButton";
+ r->name = TQPUSHBUTTON_OBJECT_NAME_STRING;
r->group = widgetGroup("Buttons");
r->toolTip = i18n("Push Button");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "toolbutton.xpm";
- r->name = "TQToolButton";
+ r->name = TQTOOLBUTTON_OBJECT_NAME_STRING;
r->group = widgetGroup("Buttons");
r->toolTip = i18n("Tool Button");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "radiobutton.xpm";
- r->name = "TQRadioButton";
+ r->name = TQRADIOBUTTON_OBJECT_NAME_STRING;
r->group = widgetGroup("Buttons");
r->toolTip = i18n("Radio Button");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "checkbox.xpm";
- r->name = "TQCheckBox";
+ r->name = TQCHECKBOX_OBJECT_NAME_STRING;
r->group = widgetGroup("Buttons");
r->toolTip = i18n("Check Box");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "groupbox.xpm";
- r->name = "TQGroupBox";
+ r->name = TQGROUPBOX_OBJECT_NAME_STRING;
r->group = widgetGroup("Containers");
r->toolTip = i18n("Group Box");
r->isContainer = true;
@@ -170,7 +170,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconName = "buttongroup.xpm";
- r->name = "TQButtonGroup";
+ r->name = TQBUTTONGROUP_OBJECT_NAME_STRING;
r->group = widgetGroup("Containers");
r->toolTip = i18n("Button Group");
r->isContainer = true;
@@ -178,7 +178,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconName = "frame.xpm";
- r->name = "TQFrame";
+ r->name = TQFRAME_OBJECT_NAME_STRING;
r->group = widgetGroup("Containers");
r->toolTip = i18n("Frame");
r->isContainer = true;
@@ -186,7 +186,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconName = "tabwidget.xpm";
- r->name = "TQTabWidget";
+ r->name = TQTABWIDGET_OBJECT_NAME_STRING;
r->group = widgetGroup("Containers");
r->toolTip = i18n("Tabwidget");
r->isContainer = true;
@@ -194,41 +194,41 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconName = "listbox.xpm";
- r->name = "TQListBox";
+ r->name = TQLISTBOX_OBJECT_NAME_STRING;
r->group = widgetGroup("Views");
r->toolTip = i18n("List Box");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "listview.xpm";
- r->name = "TQListView";
+ r->name = TQLISTVIEW_OBJECT_NAME_STRING;
r->group = widgetGroup("Views");
r->toolTip = i18n("List View");
append(r);
-#if !defined(QT_NO_ICONVIEW) || defined(UIC)
+#if !defined(TQT_NO_ICONVIEW) || defined(UIC)
r = new WidgetDatabaseRecord;
r->iconName = "iconview.xpm";
- r->name = "TQIconView";
+ r->name = TQICONVIEW_OBJECT_NAME_STRING;
r->group = widgetGroup("Views");
r->toolTip = i18n("Icon View");
append(r);
#endif
-#if !defined(QT_NO_TABLE)
+#if !defined(TQT_NO_TABLE)
r = new WidgetDatabaseRecord;
r->iconName = "table.xpm";
- r->name = "TQTable";
+ r->name = TQTABLE_OBJECT_NAME_STRING;
r->group = widgetGroup("Views");
r->toolTip = i18n("Table");
append(r);
#endif
-#if !defined(QT_NO_SQL)
+#if !defined(TQT_NO_SQL)
r = new WidgetDatabaseRecord;
r->iconName = "datatable.xpm";
r->includeFile = "tqdatatable.h";
- r->name = "TQDataTable";
+ r->name = TQDATATABLE_OBJECT_NAME_STRING;
r->group = widgetGroup("Database");
r->toolTip = i18n("Data Table");
append(r);
@@ -236,21 +236,21 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconName = "lineedit.xpm";
- r->name = "TQLineEdit";
+ r->name = TQLINEEDIT_OBJECT_NAME_STRING;
r->group = widgetGroup("Input");
r->toolTip = i18n("Line Edit");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "spinbox.xpm";
- r->name = "TQSpinBox";
+ r->name = TQSPINBOX_OBJECT_NAME_STRING;
r->group = widgetGroup("Input");
r->toolTip = i18n("Spin Box");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "dateedit.xpm";
- r->name = "QDateEdit";
+ r->name = TQDATEEDIT_OBJECT_NAME_STRING;
r->group = widgetGroup("Input");
r->toolTip = i18n("Date Edit");
r->includeFile = "tqdatetimeedit.h";
@@ -258,7 +258,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconName = "timeedit.xpm";
- r->name = "QTimeEdit";
+ r->name = TQTIMEEDIT_OBJECT_NAME_STRING;
r->group = widgetGroup("Input");
r->toolTip = i18n("Time Edit");
r->includeFile = "tqdatetimeedit.h";
@@ -266,7 +266,7 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconName = "datetimeedit.xpm";
- r->name = "QDateTimeEdit";
+ r->name = TQDATETIMEEDIT_OBJECT_NAME_STRING;
r->group = widgetGroup("Input");
r->toolTip = i18n("Date-Time Edit");
r->includeFile = "tqdatetimeedit.h";
@@ -274,77 +274,77 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconName = "multilineedit.xpm";
- r->name = "TQMultiLineEdit";
+ r->name = TQMULTILINEEDIT_OBJECT_NAME_STRING;
r->group = widgetGroup("Temp");
r->toolTip = i18n("Multi Line Edit");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "richtextedit.xpm";
- r->name = "TQTextEdit";
+ r->name = TQTEXTEDIT_OBJECT_NAME_STRING;
r->group = widgetGroup("Input");
r->toolTip = i18n("Rich Text Edit");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "combobox.xpm";
- r->name = "TQComboBox";
+ r->name = TQCOMBOBOX_OBJECT_NAME_STRING;
r->group = widgetGroup("Input");
r->toolTip = i18n("Combo Box");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "slider.xpm";
- r->name = "TQSlider";
+ r->name = TQSLIDER_OBJECT_NAME_STRING;
r->group = widgetGroup("Input");
r->toolTip = i18n("Slider");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "scrollbar.xpm";
- r->name = "TQScrollBar";
+ r->name = TQSCROLLBAR_OBJECT_NAME_STRING;
r->group = widgetGroup("Input");
r->toolTip = i18n("Scrollbar");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "dial.xpm";
- r->name = "TQDial";
+ r->name = TQDIAL_OBJECT_NAME_STRING;
r->group = widgetGroup("Input");
r->toolTip = i18n("Dial");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "label.xpm";
- r->name = "TQLabel";
+ r->name = TQLABEL_OBJECT_NAME_STRING;
r->group = widgetGroup("Temp");
r->toolTip = i18n("Label");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "lcdnumber.xpm";
- r->name = "TQLCDNumber";
+ r->name = TQLCDNUMBER_OBJECT_NAME_STRING;
r->group = widgetGroup("Display");
r->toolTip = i18n("LCD Number");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "progress.xpm";
- r->name = "TQProgressBar";
+ r->name = TQPROGRESSBAR_OBJECT_NAME_STRING;
r->group = widgetGroup("Display");
r->toolTip = i18n("Progress Bar");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "textview.xpm";
- r->name = "TQTextView";
+ r->name = TQTEXTVIEW_OBJECT_NAME_STRING;
r->group = widgetGroup("Temp");
r->toolTip = i18n("Text View");
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "textbrowser.xpm";
- r->name = "TQTextBrowser";
+ r->name = TQTEXTBROWSER_OBJECT_NAME_STRING;
r->group = widgetGroup("Display");
r->toolTip = i18n("Text Browser");
append(r);
@@ -355,42 +355,42 @@ void WidgetDatabase::setupDataBase( int id )
r->group = widgetGroup("Temp");
r->toolTip = i18n("Spacer");
r->whatsThis =
- i18n("The Spacer provides horizontal and vertical spacing to be able to manipulate the behaviour of layouts.");
+ i18n("The Spacer provides horizontal and vertical spacing to be able to manipulate the behaviour of tqlayouts.");
append(r);
r = new WidgetDatabaseRecord;
- r->name = "TQWidget";
+ r->name = TQWIDGET_OBJECT_NAME_STRING;
r->isForm = true;
r->group = widgetGroup("Forms");
append(r);
r = new WidgetDatabaseRecord;
- r->name = "TQDialog";
+ r->name = TQDIALOG_OBJECT_NAME_STRING;
r->group = widgetGroup("Forms");
r->isForm = true;
append(r);
r = new WidgetDatabaseRecord;
- r->name = "TQWizard";
+ r->name = TQWIZARD_OBJECT_NAME_STRING;
r->group = widgetGroup("Forms");
r->isContainer = true;
append(r);
r = new WidgetDatabaseRecord;
- r->name = "QDesignerWizard";
+ r->name = "TQDesignerWizard";
r->group = widgetGroup("Forms");
r->isContainer = true;
append(r);
r = new WidgetDatabaseRecord;
- r->name = "QLayoutWidget";
+ r->name = TQLAYOUTWIDGET_OBJECT_NAME_STRING;
r->group = widgetGroup("Temp");
r->includeFile = "";
r->isContainer = true;
append(r);
r = new WidgetDatabaseRecord;
- r->name = "TQSplitter";
+ r->name = TQSPLITTER_OBJECT_NAME_STRING;
r->group = widgetGroup("Temp");
r->includeFile = "tqsplitter.h";
r->isContainer = true;
@@ -398,36 +398,36 @@ void WidgetDatabase::setupDataBase( int id )
r = new WidgetDatabaseRecord;
r->iconName = "tabwidget.xpm";
- r->name = "QDesignerTabWidget";
+ r->name = "TQDesignerTabWidget";
r->group = widgetGroup("Temp");
r->isContainer = true;
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "tabwidget.xpm";
- r->name = "QDesignerWidget";
+ r->name = "TQDesignerWidget";
r->group = widgetGroup("Temp");
r->isContainer = true;
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "tabwidget.xpm";
- r->name = "QDesignerDialog";
+ r->name = "TQDesignerDialog";
r->group = widgetGroup("Temp");
r->isContainer = true;
append(r);
r = new WidgetDatabaseRecord;
r->iconName = "";
- r->name = "TQMainWindow";
+ r->name = TQMAINWINDOW_OBJECT_NAME_STRING;
r->includeFile = "tqmainwindow.h";
r->group = widgetGroup("Temp");
r->isContainer = true;
append(r);
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
r = new WidgetDatabaseRecord;
- r->name = "TQDataBrowser";
+ r->name = TQDATABROWSER_OBJECT_NAME_STRING;
r->includeFile = "tqdatabrowser.h";
r->group = widgetGroup("Database");
r->toolTip = "Data Browser";
@@ -436,7 +436,7 @@ void WidgetDatabase::setupDataBase( int id )
append(r);
r = new WidgetDatabaseRecord;
- r->name = "TQDataView";
+ r->name = TQDATAVIEW_OBJECT_NAME_STRING;
r->includeFile = "tqdataview.h";
r->group = widgetGroup("Database");
r->toolTip = "Data View";
@@ -764,7 +764,7 @@ TQString WidgetDatabase::className( int id )
setupDataBase( id );
WidgetDatabaseRecord *r = at( id );
if ( !r )
- return TQString::null;
+ return TQString();
return r->name;
}
@@ -777,7 +777,7 @@ TQString WidgetDatabase::group( int id )
setupDataBase( id );
WidgetDatabaseRecord *r = at( id );
if ( !r )
- return TQString::null;
+ return TQString();
return r->group;
}
@@ -790,7 +790,7 @@ TQString WidgetDatabase::toolTip( int id )
setupDataBase( id );
WidgetDatabaseRecord *r = at( id );
if ( !r )
- return TQString::null;
+ return TQString();
return r->toolTip;
}
@@ -803,7 +803,7 @@ TQString WidgetDatabase::whatsThis( int id )
setupDataBase( id );
WidgetDatabaseRecord *r = at( id );
if ( !r )
- return TQString::null;
+ return TQString();
return r->whatsThis;
}
@@ -816,7 +816,7 @@ TQString WidgetDatabase::includeFile( int id )
setupDataBase( id );
WidgetDatabaseRecord *r = at( id );
if ( !r )
- return TQString::null;
+ return TQString();
if ( r->includeFile.isNull() )
return r->name.lower() + ".h";
return r->includeFile;
@@ -833,7 +833,7 @@ bool WidgetDatabase::isForm( int id )
return r->isForm;
}
-/*! Returns whether the widget registered as \a id can have children.
+/*! Returns whether the widget registered as \a id can have tqchildren.
*/
bool WidgetDatabase::isContainer( int id )
@@ -849,7 +849,7 @@ TQString WidgetDatabase::createWidgetName( int id )
{
setupDataBase( id );
TQString n = className( id );
- if ( n == "QLayoutWidget" )
+ if ( n == TQLAYOUTWIDGET_OBJECT_NAME_STRING )
n = "Layout";
if ( n[ 0 ] == 'Q' )
n = n.mid( 1 );
@@ -867,14 +867,14 @@ int WidgetDatabase::idFromClassName( const TQString &name )
setupDataBase( -1 );
if ( name.isEmpty() )
return 0;
- int *i = className2Id->find( name );
+ int *i = className2Id->tqfind( name );
if ( i )
return *i;
if ( name == "FormWindow" )
- return idFromClassName( "QLayoutWidget" );
+ return idFromClassName( TQLAYOUTWIDGET_OBJECT_NAME_STRING );
#ifdef UIC
setupDataBase( -2 );
- i = className2Id->find( name );
+ i = className2Id->tqfind( name );
if ( i )
return *i;
#endif
@@ -883,7 +883,7 @@ int WidgetDatabase::idFromClassName( const TQString &name )
bool WidgetDatabase::hasWidget( const TQString &name )
{
- return className2Id->find( name ) != 0;
+ return className2Id->tqfind( name ) != 0;
}
WidgetDatabaseRecord *WidgetDatabase::at( int index )
@@ -904,7 +904,7 @@ void WidgetDatabase::insert( int index, WidgetDatabaseRecord *r )
widget_db[ index ] = r;
className2Id->insert( r->name, new int( index ) );
if ( index < dbcustom )
- dbcount = QMAX( dbcount, index );
+ dbcount = TQMAX( dbcount, index );
}
void WidgetDatabase::append( WidgetDatabaseRecord *r )
@@ -916,7 +916,7 @@ void WidgetDatabase::append( WidgetDatabaseRecord *r )
TQString WidgetDatabase::widgetGroup( const TQString &g )
{
- if ( wGroups->find( g ) == -1 )
+ if ( wGroups->tqfind( g ) == -1 )
wGroups->append( g );
return g;
}
@@ -945,7 +945,7 @@ TQString WidgetDatabase::widgetGroup( int i )
setupDataBase( -1 );
if ( i >= 0 && i < (int)wGroups->count() )
return wGroups->at( i );
- return TQString::null;
+ return TQString();
}
int WidgetDatabase::numWidgetGroups()
@@ -957,7 +957,7 @@ int WidgetDatabase::numWidgetGroups()
bool WidgetDatabase::isGroupVisible( const TQString &g )
{
setupDataBase( -1 );
- return invisibleGroups->find( g ) == -1;
+ return invisibleGroups->tqfind( g ) == -1;
}
int WidgetDatabase::addCustomWidget( WidgetDatabaseRecord *r )
@@ -997,20 +997,20 @@ void WidgetDatabase::loadWhatsThis( const TQString &docPath )
}
-// ### Qt 3.1: make these publically accessible via QWidgetDatabase API
+// ### TQt 3.1: make these publically accessible via TQWidgetDatabase API
#ifndef KOMMANDER
#if defined(UIC)
bool dbnounload = false;
TQStringList *dbpaths = 0;
#endif
-QPluginManager<WidgetInterface> *widgetManager()
+TQPluginManager<WidgetInterface> *widgetManager()
{
if ( !widgetPluginManager ) {
#ifndef KOMMANDER
- widgetPluginManager = new QPluginManager<WidgetInterface>( IID_Widget, TQApplication::libraryPaths(), "/designer" );
+ widgetPluginManager = new TQPluginManager<WidgetInterface>( IID_Widget, TQApplication::libraryPaths(), "/designer" );
#else
- widgetPluginManager = new QPluginManager<WidgetInterface>( IID_Widget, TQApplication::libraryPaths(), "" );
+ widgetPluginManager = new TQPluginManager<WidgetInterface>( IID_Widget, TQApplication::libraryPaths(), "" );
#endif
cleanup_manager.add( &widgetPluginManager );
diff --git a/kommander/editor/widgetdatabase.h b/kommander/editor/widgetdatabase.h
index 3e4078c5..24b14530 100644
--- a/kommander/editor/widgetdatabase.h
+++ b/kommander/editor/widgetdatabase.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -25,10 +25,10 @@
#include <tqstring.h>
#ifndef KOMMANDER
#include "widgetinterface.h" // up here for GCC 2.7.* compatibility
-#include <private/qpluginmanager_p.h>
+#include <private/tqpluginmanager_p.h>
-extern QPluginManager<WidgetInterface> *widgetManager();
+extern TQPluginManager<WidgetInterface> *widgetManager();
#endif
struct WidgetDatabaseRecord
@@ -42,7 +42,7 @@ struct WidgetDatabaseRecord
int nameCounter;
};
-class WidgetDatabase : public Qt
+class WidgetDatabase : public TQt
{
public:
WidgetDatabase();
diff --git a/kommander/editor/widgetfactory.cpp b/kommander/editor/widgetfactory.cpp
index 2becbd33..920a3605 100644
--- a/kommander/editor/widgetfactory.cpp
+++ b/kommander/editor/widgetfactory.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -29,7 +29,7 @@
#include "mainwindow.h"
#include "formwindow.h"
#include "pixmapchooser.h"
-#include "layout.h"
+#include "tqlayout.h"
#include "listboxeditorimpl.h"
#include "listvieweditorimpl.h"
#include "iconvieweditorimpl.h"
@@ -37,7 +37,7 @@
#ifndef KOMMANDER
#include "widgetinterface.h"
#endif
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
#include "tableeditorimpl.h"
#endif
@@ -46,10 +46,10 @@
#include <tqpixmap.h>
#include <tqgroupbox.h>
#include <tqiconview.h>
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
#include <tqtable.h>
#endif
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
#include <tqdatatable.h>
#endif
#include <tqdatetimeedit.h>
@@ -81,7 +81,7 @@
#include <tqmenubar.h>
#include <tqapplication.h>
#include <tqsplitter.h>
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
#include "database.h"
#endif
@@ -123,13 +123,13 @@ FormWindow *find_formwindow( TQWidget *w )
for (;;) {
if ( w->inherits( "FormWindow" ) )
return (FormWindow*)w;
- if ( !w->parentWidget() )
+ if ( !w->tqparentWidget() )
return 0;
- w = w->parentWidget();
+ w = w->tqparentWidget();
}
}
-void QLayoutWidget::paintEvent( TQPaintEvent* )
+void TQLayoutWidget::paintEvent( TQPaintEvent* )
{
TQPainter p ( this );
p.setPen( red );
@@ -137,54 +137,54 @@ void QLayoutWidget::paintEvent( TQPaintEvent* )
}
-QDesignerTabWidget::QDesignerTabWidget( TQWidget *parent, const char *name )
- : TQTabWidget( parent, name ), dropIndicator( 0 ), dragPage( 0 ), mousePressed( false )
+TQDesignerTabWidget::TQDesignerTabWidget( TQWidget *tqparent, const char *name )
+ : TQTabWidget( tqparent, name ), dropIndicator( 0 ), dragPage( 0 ), mousePressed( false )
{
tabBar()->setAcceptDrops( true );
tabBar()->installEventFilter( this );
}
-int QDesignerTabWidget::currentPage() const
+int TQDesignerTabWidget::currentPage() const
{
return tabBar()->currentTab();
}
-void QDesignerTabWidget::setCurrentPage( int i )
+void TQDesignerTabWidget::setCurrentPage( int i )
{
tabBar()->setCurrentTab( i );
}
-TQString QDesignerTabWidget::pageTitle() const
+TQString TQDesignerTabWidget::pageTitle() const
{
return ((TQTabWidget*)this)->tabLabel( TQTabWidget::currentPage() );
}
-void QDesignerTabWidget::setPageTitle( const TQString& title )
+void TQDesignerTabWidget::setPageTitle( const TQString& title )
{
changeTab( TQTabWidget::currentPage(), title );
}
-void QDesignerTabWidget::setPageName( const TQCString& name )
+void TQDesignerTabWidget::setPageName( const TQCString& name )
{
if ( TQTabWidget::currentPage() )
TQTabWidget::currentPage()->setName( name );
}
-TQCString QDesignerTabWidget::pageName() const
+TQCString TQDesignerTabWidget::pageName() const
{
if ( !TQTabWidget::currentPage() )
return 0;
return TQTabWidget::currentPage()->name();
}
-int QDesignerTabWidget::count() const
+int TQDesignerTabWidget::count() const
{
return tabBar()->count();
}
-bool QDesignerTabWidget::eventFilter( TQObject *o, TQEvent *e )
+bool TQDesignerTabWidget::eventFilter( TQObject *o, TQEvent *e )
{
- if ( o != tabBar() ) return false;
+ if ( TQT_BASE_OBJECT(o) != TQT_BASE_OBJECT(tabBar()) ) return false;
switch ( e->type() ) {
case TQEvent::MouseButtonPress: {
@@ -232,7 +232,7 @@ bool QDesignerTabWidget::eventFilter( TQObject *o, TQEvent *e )
int index = 0;
TQRect rect;
for ( ; index < tabBar()->count(); index++ ) {
- if ( tabBar()->tabAt( index )->rect().contains( de->pos() ) ) {
+ if ( tabBar()->tabAt( index )->rect().tqcontains( de->pos() ) ) {
rect = tabBar()->tabAt( index )->rect();
break;
}
@@ -241,7 +241,7 @@ bool QDesignerTabWidget::eventFilter( TQObject *o, TQEvent *e )
if ( index == tabBar()->count() -1 ) {
TQRect rect2 = rect;
rect2.setLeft( rect2.left() + rect2.width() / 2 );
- if ( rect2.contains( de->pos() ) )
+ if ( rect2.tqcontains( de->pos() ) )
index++;
}
@@ -269,20 +269,20 @@ bool QDesignerTabWidget::eventFilter( TQObject *o, TQEvent *e )
int newIndex = 0;
for ( ; newIndex < tabBar()->count(); newIndex++ ) {
- if ( tabBar()->tabAt( newIndex )->rect().contains( de->pos() ) )
+ if ( tabBar()->tabAt( newIndex )->rect().tqcontains( de->pos() ) )
break;
}
if ( newIndex == tabBar()->count() -1 ) {
TQRect rect2 = tabBar()->tabAt( newIndex )->rect();
rect2.setLeft( rect2.left() + rect2.width() / 2 );
- if ( rect2.contains( de->pos() ) )
+ if ( rect2.tqcontains( de->pos() ) )
newIndex++;
}
int oldIndex = 0;
for ( ; oldIndex < tabBar()->count(); oldIndex++ ) {
- if ( tabBar()->tabAt( oldIndex )->rect().contains( pressPoint ) )
+ if ( tabBar()->tabAt( oldIndex )->rect().tqcontains( pressPoint ) )
break;
}
@@ -303,7 +303,7 @@ bool QDesignerTabWidget::eventFilter( TQObject *o, TQEvent *e )
return false;
}
-int QDesignerWizard::currentPageNum() const
+int TQDesignerWizard::currentPageNum() const
{
for ( int i = 0; i < pageCount(); ++i ) {
if ( page( i ) == currentPage() )
@@ -312,7 +312,7 @@ int QDesignerWizard::currentPageNum() const
return 0;
}
-void QDesignerWizard::setCurrentPage( int i )
+void TQDesignerWizard::setCurrentPage( int i )
{
if ( i < currentPageNum() ) {
while ( i < currentPageNum() ) {
@@ -330,30 +330,30 @@ void QDesignerWizard::setCurrentPage( int i )
}
}
-TQString QDesignerWizard::pageTitle() const
+TQString TQDesignerWizard::pageTitle() const
{
return title( currentPage() );
}
-void QDesignerWizard::setPageTitle( const TQString& title )
+void TQDesignerWizard::setPageTitle( const TQString& title )
{
setTitle( currentPage(), title );
}
-void QDesignerWizard::setPageName( const TQCString& name )
+void TQDesignerWizard::setPageName( const TQCString& name )
{
if ( TQWizard::currentPage() )
TQWizard::currentPage()->setName( name );
}
-TQCString QDesignerWizard::pageName() const
+TQCString TQDesignerWizard::pageName() const
{
if ( !TQWizard::currentPage() )
return 0;
return TQWizard::currentPage()->name();
}
-int QDesignerWizard::pageNum( TQWidget *p )
+int TQDesignerWizard::pageNum( TQWidget *p )
{
for ( int i = 0; i < pageCount(); ++i ) {
if ( page( i ) == p )
@@ -362,23 +362,23 @@ int QDesignerWizard::pageNum( TQWidget *p )
return -1;
}
-void QDesignerWizard::addPage( TQWidget *p, const TQString &t )
+void TQDesignerWizard::addPage( TQWidget *p, const TQString &t )
{
TQWizard::addPage( p, t );
- if ( removedPages.find( p ) )
+ if ( removedPages.tqfind( p ) )
removedPages.remove( p );
}
-void QDesignerWizard::removePage( TQWidget *p )
+void TQDesignerWizard::removePage( TQWidget *p )
{
TQWizard::removePage( p );
removedPages.insert( p, p );
}
-void QDesignerWizard::insertPage( TQWidget *p, const TQString &t, int index )
+void TQDesignerWizard::insertPage( TQWidget *p, const TQString &t, int index )
{
TQWizard::insertPage( p, t, index );
- if ( removedPages.find( p ) )
+ if ( removedPages.tqfind( p ) )
removedPages.remove( p );
}
@@ -387,10 +387,10 @@ TQMap< int, TQStringList > *changedProperties = 0;
/*!
\class WidgetFactory widgetfactory.h
- \brief Set of static functions for creating widgets, layouts and do other stuff
+ \brief Set of static functions for creating widgets, tqlayouts and do other stuff
The widget factory offers functions to create widgets, create and
- delete layouts find out other details - all based on the
+ delete tqlayouts find out other details - all based on the
WidgetDatabase's data. So the functions that use ids use the same
ids as in the WidgetDatabase.
*/
@@ -399,26 +399,26 @@ TQMap< int, TQStringList > *changedProperties = 0;
void WidgetFactory::saveDefaultProperties( TQWidget *w, int id )
{
TQMap< TQString, TQVariant> propMap;
- TQStrList lst = w->metaObject()->propertyNames( true );
+ TQStrList lst = w->tqmetaObject()->propertyNames( true );
for ( uint i = 0; i < lst.count(); ++i ) {
TQVariant var = w->property( lst.at( i ) );
if ( !var.isValid() && qstrcmp( "pixmap", lst.at( i ) ) == 0 )
var = TQVariant( TQPixmap() );
else if ( !var.isValid() && qstrcmp( "iconSet", lst.at( i ) ) == 0 )
var = TQVariant( TQIconSet() );
- propMap.replace( lst.at( i ), var );
+ propMap.tqreplace( lst.at( i ), var );
}
- defaultProperties->replace( id, propMap );
+ defaultProperties->tqreplace( id, propMap );
}
static void saveChangedProperties( TQWidget *w, int id )
{
- TQStringList l = MetaDataBase::changedProperties( w );
+ TQStringList l = MetaDataBase::changedProperties( TQT_TQOBJECT(w) );
changedProperties->insert( id, l );
}
-EditorTabWidget::EditorTabWidget( TQWidget *parent, const char *name )
- : TabWidget( parent, name ), dropIndicator( 0 ), dragPage( 0 ), mousePressed( false )
+EditorTabWidget::EditorTabWidget( TQWidget *tqparent, const char *name )
+ : TabWidget( tqparent, name ), dropIndicator( 0 ), dragPage( 0 ), mousePressed( false )
{
tabBar()->setAcceptDrops( true );
tabBar()->installEventFilter( this );
@@ -464,7 +464,7 @@ int EditorTabWidget::count() const
bool EditorTabWidget::eventFilter( TQObject *o, TQEvent *e )
{
- if ( o != tabBar() ) return false;
+ if ( TQT_BASE_OBJECT(o) != TQT_BASE_OBJECT(tabBar()) ) return false;
switch ( e->type() ) {
case TQEvent::MouseButtonPress: {
@@ -512,7 +512,7 @@ bool EditorTabWidget::eventFilter( TQObject *o, TQEvent *e )
int index = 0;
TQRect rect;
for ( ; index < tabBar()->count(); index++ ) {
- if ( tabBar()->tabAt( index )->rect().contains( de->pos() ) ) {
+ if ( tabBar()->tabAt( index )->rect().tqcontains( de->pos() ) ) {
rect = tabBar()->tabAt( index )->rect();
break;
}
@@ -521,7 +521,7 @@ bool EditorTabWidget::eventFilter( TQObject *o, TQEvent *e )
if ( index == tabBar()->count() -1 ) {
TQRect rect2 = rect;
rect2.setLeft( rect2.left() + rect2.width() / 2 );
- if ( rect2.contains( de->pos() ) )
+ if ( rect2.tqcontains( de->pos() ) )
index++;
}
@@ -549,20 +549,20 @@ bool EditorTabWidget::eventFilter( TQObject *o, TQEvent *e )
int newIndex = 0;
for ( ; newIndex < tabBar()->count(); newIndex++ ) {
- if ( tabBar()->tabAt( newIndex )->rect().contains( de->pos() ) )
+ if ( tabBar()->tabAt( newIndex )->rect().tqcontains( de->pos() ) )
break;
}
if ( newIndex == tabBar()->count() -1 ) {
TQRect rect2 = tabBar()->tabAt( newIndex )->rect();
rect2.setLeft( rect2.left() + rect2.width() / 2 );
- if ( rect2.contains( de->pos() ) )
+ if ( rect2.tqcontains( de->pos() ) )
newIndex++;
}
int oldIndex = 0;
for ( ; oldIndex < tabBar()->count(); oldIndex++ ) {
- if ( tabBar()->tabAt( oldIndex )->rect().contains( pressPoint ) )
+ if ( tabBar()->tabAt( oldIndex )->rect().tqcontains( pressPoint ) )
break;
}
@@ -584,8 +584,8 @@ bool EditorTabWidget::eventFilter( TQObject *o, TQEvent *e )
}
-EditorToolBox::EditorToolBox( TQWidget *parent, const char *name )
- : ToolBox( parent, name )
+EditorToolBox::EditorToolBox( TQWidget *tqparent, const char *name )
+ : ToolBox( tqparent, name )
{
setAcceptDrops( true );
}
@@ -631,12 +631,12 @@ int EditorToolBox::count() const
/*! Creates a widget of the type which is registered as \a id as
- child of \a parent. The \a name is optional. If \a init is true, the
+ child of \a tqparent. The \a name is optional. If \a init is true, the
widget is initialized with some defaults, else the plain widget is
created.
*/
-TQWidget *WidgetFactory::create( int id, TQWidget *parent, const char *name, bool init, const TQRect *r, Qt::Orientation orient )
+TQWidget *WidgetFactory::create( int id, TQWidget *tqparent, const char *name, bool init, const TQRect *r, Qt::Orientation orient )
{
TQString n = WidgetDatabase::className(id);
//qDebug("Trying to create '%s'", n.latin1());
@@ -652,108 +652,108 @@ TQWidget *WidgetFactory::create( int id, TQWidget *parent, const char *name, boo
TQWidget *w = 0;
TQString str = WidgetDatabase::createWidgetName(id);
const char *s = str.latin1();
- w = createWidget(n, parent, name ? name : s, init, r, orient);
+ w = createWidget(n, tqparent, name ? name : s, init, r, orient);
//qDebug("Trying to create '%s', widget (id=%d) - %s", s, id, w ? "successful" : "failure");
if (!w && WidgetDatabase::isCustomWidget(id))
- w = createCustomWidget(parent, name ? name : s, MetaDataBase::customWidget(id));
+ w = createCustomWidget(tqparent, name ? name : s, MetaDataBase::customWidget(id));
if (!w)
return 0;
- MetaDataBase::addEntry(w);
+ MetaDataBase::addEntry(TQT_TQOBJECT(w));
- if (!defaultProperties->contains(id))
+ if (!defaultProperties->tqcontains(id))
saveDefaultProperties(w, id);
- if (!changedProperties->contains(id))
+ if (!changedProperties->tqcontains(id))
saveChangedProperties(w, id);
return w;
}
-/*! Creates a layout on the widget \a widget of the type \a type
+/*! Creates a tqlayout on the widget \a widget of the type \a type
which can be \c HBox, \c VBox or \c Grid.
*/
-TQLayout *WidgetFactory::createLayout( TQWidget *widget, TQLayout *layout, LayoutType type )
+TQLayout *WidgetFactory::createLayout( TQWidget *widget, TQLayout *tqlayout, LayoutType type )
{
int spacing = MainWindow::self->currentLayoutDefaultSpacing();
int margin = 0;
if ( widget && !widget->inherits( TQLAYOUTWIDGET_OBJECT_NAME_STRING ) &&
- ( WidgetDatabase::isContainer( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( widget ) ) ) ||
- widget && widget->parentWidget() && widget->parentWidget()->inherits( "FormWindow" ) ) )
+ ( WidgetDatabase::isContainer( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( TQT_TQOBJECT(widget) ) ) ) ||
+ widget && widget->tqparentWidget() && widget->tqparentWidget()->inherits( "FormWindow" ) ) )
margin = MainWindow::self->currentLayoutDefaultMargin();
- if ( !layout && widget && widget->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) )
+ if ( !tqlayout && widget && widget->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) )
widget = ((TQTabWidget*)widget)->currentPage();
- if ( !layout && widget && widget->inherits( TQTOOLBOX_OBJECT_NAME_STRING ) )
+ if ( !tqlayout && widget && widget->inherits( TQTOOLBOX_OBJECT_NAME_STRING ) )
widget = ((TQToolBox*)widget)->currentItem();
- if ( !layout && widget && widget->inherits( TQWIZARD_OBJECT_NAME_STRING ) )
+ if ( !tqlayout && widget && widget->inherits( TQWIZARD_OBJECT_NAME_STRING ) )
widget = ((TQWizard*)widget)->currentPage();
- if ( !layout && widget && widget->inherits( TQMAINWINDOW_OBJECT_NAME_STRING ) )
+ if ( !tqlayout && widget && widget->inherits( TQMAINWINDOW_OBJECT_NAME_STRING ) )
widget = ((TQMainWindow*)widget)->centralWidget();
- if ( !layout && widget && widget->inherits( TQWIDGETSTACK_OBJECT_NAME_STRING ) )
+ if ( !tqlayout && widget && widget->inherits( TQWIDGETSTACK_OBJECT_NAME_STRING ) )
widget = ((TQWidgetStack*)widget)->visibleWidget();
- MetaDataBase::addEntry( widget );
+ MetaDataBase::addEntry( TQT_TQOBJECT(widget) );
- if ( !layout && widget && widget->inherits( TQGROUPBOX_OBJECT_NAME_STRING ) ) {
+ if ( !tqlayout && widget && widget->inherits( TQGROUPBOX_OBJECT_NAME_STRING ) ) {
TQGroupBox *gb = (TQGroupBox*)widget;
gb->setColumnLayout( 0, Qt::Vertical );
- gb->layout()->setMargin( 0 );
- gb->layout()->setSpacing( 0 );
+ gb->tqlayout()->setMargin( 0 );
+ gb->tqlayout()->setSpacing( 0 );
TQLayout *l;
switch ( type ) {
case HBox:
- l = new TQHBoxLayout( gb->layout() );
- MetaDataBase::setMargin( gb, margin );
- MetaDataBase::setSpacing( gb, spacing );
- l->setAlignment( AlignTop );
- MetaDataBase::addEntry( l );
+ l = new TQHBoxLayout( gb->tqlayout() );
+ MetaDataBase::setMargin( TQT_TQOBJECT(gb), margin );
+ MetaDataBase::setSpacing( TQT_TQOBJECT(gb), spacing );
+ l->tqsetAlignment( AlignTop );
+ MetaDataBase::addEntry( TQT_TQOBJECT(l) );
return l;
case VBox:
- l = new TQVBoxLayout( gb->layout(), spacing );
- MetaDataBase::setMargin( gb, margin );
- MetaDataBase::setSpacing( gb, spacing );
- l->setAlignment( AlignTop );
- MetaDataBase::addEntry( l );
+ l = new TQVBoxLayout( gb->tqlayout(), spacing );
+ MetaDataBase::setMargin( TQT_TQOBJECT(gb), margin );
+ MetaDataBase::setSpacing( TQT_TQOBJECT(gb), spacing );
+ l->tqsetAlignment( AlignTop );
+ MetaDataBase::addEntry( TQT_TQOBJECT(l) );
return l;
case Grid:
- l = new QDesignerGridLayout( gb->layout() );
- MetaDataBase::setMargin( gb, margin );
- MetaDataBase::setSpacing( gb, spacing );
- l->setAlignment( AlignTop );
- MetaDataBase::addEntry( l );
+ l = new TQDesignerGridLayout( gb->tqlayout() );
+ MetaDataBase::setMargin( TQT_TQOBJECT(gb), margin );
+ MetaDataBase::setSpacing( TQT_TQOBJECT(gb), spacing );
+ l->tqsetAlignment( AlignTop );
+ MetaDataBase::addEntry( TQT_TQOBJECT(l) );
return l;
default:
return 0;
}
} else {
- if ( layout ) {
+ if ( tqlayout ) {
TQLayout *l;
switch ( type ) {
case HBox:
- l = new TQHBoxLayout( layout );
- MetaDataBase::addEntry( l );
+ l = new TQHBoxLayout( tqlayout );
+ MetaDataBase::addEntry( TQT_TQOBJECT(l) );
l->setSpacing( spacing );
l->setMargin( margin );
- MetaDataBase::addEntry( l );
+ MetaDataBase::addEntry( TQT_TQOBJECT(l) );
return l;
case VBox:
- l = new TQVBoxLayout( layout );
- MetaDataBase::addEntry( l );
+ l = new TQVBoxLayout( tqlayout );
+ MetaDataBase::addEntry( TQT_TQOBJECT(l) );
l->setSpacing( spacing );
l->setMargin( margin );
- MetaDataBase::addEntry( l );
+ MetaDataBase::addEntry( TQT_TQOBJECT(l) );
return l;
case Grid: {
- l = new QDesignerGridLayout( layout );
- MetaDataBase::addEntry( l );
+ l = new TQDesignerGridLayout( tqlayout );
+ MetaDataBase::addEntry( TQT_TQOBJECT(l) );
l->setSpacing( spacing );
l->setMargin( margin );
- MetaDataBase::addEntry( l );
+ MetaDataBase::addEntry( TQT_TQOBJECT(l) );
return l;
}
default:
@@ -764,39 +764,39 @@ TQLayout *WidgetFactory::createLayout( TQWidget *widget, TQLayout *layout, Layou
switch ( type ) {
case HBox:
l = new TQHBoxLayout( widget );
- MetaDataBase::addEntry( l );
+ MetaDataBase::addEntry( TQT_TQOBJECT(l) );
if ( widget ) {
- MetaDataBase::setMargin( widget, margin );
- MetaDataBase::setSpacing( widget, spacing );
+ MetaDataBase::setMargin( TQT_TQOBJECT(widget), margin );
+ MetaDataBase::setSpacing( TQT_TQOBJECT(widget), spacing );
} else {
l->setMargin( margin );
l->setSpacing( margin );
}
- MetaDataBase::addEntry( l );
+ MetaDataBase::addEntry( TQT_TQOBJECT(l) );
return l;
case VBox:
l = new TQVBoxLayout( widget );
- MetaDataBase::addEntry( l );
+ MetaDataBase::addEntry( TQT_TQOBJECT(l) );
if ( widget ) {
- MetaDataBase::setMargin( widget, margin );
- MetaDataBase::setSpacing( widget, spacing );
+ MetaDataBase::setMargin( TQT_TQOBJECT(widget), margin );
+ MetaDataBase::setSpacing( TQT_TQOBJECT(widget), spacing );
} else {
l->setMargin( margin );
l->setSpacing( margin );
}
- MetaDataBase::addEntry( l );
+ MetaDataBase::addEntry( TQT_TQOBJECT(l) );
return l;
case Grid: {
- l = new QDesignerGridLayout( widget );
- MetaDataBase::addEntry( l );
+ l = new TQDesignerGridLayout( widget );
+ MetaDataBase::addEntry( TQT_TQOBJECT(l) );
if ( widget ) {
- MetaDataBase::setMargin( widget, margin );
- MetaDataBase::setSpacing( widget, spacing );
+ MetaDataBase::setMargin( TQT_TQOBJECT(widget), margin );
+ MetaDataBase::setSpacing( TQT_TQOBJECT(widget), spacing );
} else {
l->setMargin( margin );
l->setSpacing( margin );
}
- MetaDataBase::addEntry( l );
+ MetaDataBase::addEntry( TQT_TQOBJECT(l) );
return l;
}
default:
@@ -819,17 +819,17 @@ void WidgetFactory::deleteLayout( TQWidget *widget )
widget = ((TQMainWindow*)widget)->centralWidget();
if ( widget->inherits( TQWIDGETSTACK_OBJECT_NAME_STRING ) )
widget = ((TQWidgetStack*)widget)->visibleWidget();
- delete widget->layout();
+ delete widget->tqlayout();
}
/*! Factory functions for creating a widget of the type \a className
- as child of \a parent with the name \a name.
+ as child of \a tqparent with the name \a name.
If \a init is true, some initial default properties are set. This
has to be in sync with the initChangedProperties() function!
*/
-TQWidget *WidgetFactory::createWidget( const TQString &className, TQWidget *parent, const char *name, bool init,
+TQWidget *WidgetFactory::createWidget( const TQString &className, TQWidget *tqparent, const char *name, bool init,
const TQRect *r, Qt::Orientation orient )
{
if (className == TQPUSHBUTTON_OBJECT_NAME_STRING)
@@ -837,11 +837,11 @@ TQWidget *WidgetFactory::createWidget( const TQString &className, TQWidget *pare
TQPushButton *b = 0;
if (init)
{
- b = new QDesignerPushButton(parent, name);
- b->setText(TQString::fromLatin1(name));
+ b = new TQDesignerPushButton(tqparent, name);
+ b->setText(TQString::tqfromLatin1(name));
} else
{
- b = new QDesignerPushButton(parent, name);
+ b = new TQDesignerPushButton(tqparent, name);
}
TQWidget *w = find_formwindow(b);
b->setAutoDefault(w && ((FormWindow *) w)->mainContainer()->inherits(TQDIALOG_OBJECT_NAME_STRING));
@@ -850,43 +850,43 @@ TQWidget *WidgetFactory::createWidget( const TQString &className, TQWidget *pare
{
if (init)
{
- QDesignerToolButton *tb = new QDesignerToolButton(parent, name);
+ TQDesignerToolButton *tb = new TQDesignerToolButton(tqparent, name);
tb->setText("...");
return tb;
}
- return new QDesignerToolButton(parent, name);
+ return new TQDesignerToolButton(tqparent, name);
} else if (className == TQCHECKBOX_OBJECT_NAME_STRING)
{
if (init)
{
- QDesignerCheckBox *cb = new QDesignerCheckBox(parent, name);
- cb->setText(TQString::fromLatin1(name));
+ TQDesignerCheckBox *cb = new TQDesignerCheckBox(tqparent, name);
+ cb->setText(TQString::tqfromLatin1(name));
return cb;
}
- return new QDesignerCheckBox(parent, name);
+ return new TQDesignerCheckBox(tqparent, name);
} else if (className == TQRADIOBUTTON_OBJECT_NAME_STRING)
{
if (init)
{
- QDesignerRadioButton *rb = new QDesignerRadioButton(parent, name);
- rb->setText(TQString::fromLatin1(name));
+ TQDesignerRadioButton *rb = new TQDesignerRadioButton(tqparent, name);
+ rb->setText(TQString::tqfromLatin1(name));
return rb;
}
- return new QDesignerRadioButton(parent, name);
+ return new TQDesignerRadioButton(tqparent, name);
} else if (className == TQGROUPBOX_OBJECT_NAME_STRING)
{
if (init)
- return new TQGroupBox(TQString::fromLatin1(name), parent, name);
- return new TQGroupBox(parent, name);
+ return new TQGroupBox(TQString::tqfromLatin1(name), tqparent, name);
+ return new TQGroupBox(tqparent, name);
} else if (className == TQBUTTONGROUP_OBJECT_NAME_STRING)
{
if (init)
- return new TQButtonGroup(TQString::fromLatin1(name), parent, name);
- return new TQButtonGroup(parent, name);
+ return new TQButtonGroup(TQString::tqfromLatin1(name), tqparent, name);
+ return new TQButtonGroup(tqparent, name);
} else if (className == TQICONVIEW_OBJECT_NAME_STRING)
{
-#if !defined(QT_NO_ICONVIEW)
- TQIconView *iv = new TQIconView(parent, name);
+#if !defined(TQT_NO_ICONVIEW)
+ TQIconView *iv = new TQIconView(tqparent, name);
if (init)
(void) new TQIconViewItem(iv, i18n("New Item"));
return iv;
@@ -895,30 +895,30 @@ TQWidget *WidgetFactory::createWidget( const TQString &className, TQWidget *pare
#endif
} else if (className == TQTABLE_OBJECT_NAME_STRING)
{
-#if !defined(QT_NO_TABLE)
+#if !defined(TQT_NO_TABLE)
if (init)
- return new TQTable(3, 3, parent, name);
- return new TQTable(parent, name);
+ return new TQTable(3, 3, tqparent, name);
+ return new TQTable(tqparent, name);
#else
return 0;
#endif
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
} else if (className == TQDATATABLE_OBJECT_NAME_STRING)
{
- return new TQDataTable(parent, name);
-#endif //QT_NO_SQL
+ return new TQDataTable(tqparent, name);
+#endif //TQT_NO_SQL
} else if (className == TQDATEEDIT_OBJECT_NAME_STRING)
{
- return new QDateEdit(parent, name);
+ return new TQDateEdit(tqparent, name);
} else if (className == TQTIMEEDIT_OBJECT_NAME_STRING)
{
- return new QTimeEdit(parent, name);
+ return new TQTimeEdit(tqparent, name);
} else if (className == TQDATETIMEEDIT_OBJECT_NAME_STRING)
{
- return new QDateTimeEdit(parent, name);
+ return new TQDateTimeEdit(tqparent, name);
} else if (className == TQLISTBOX_OBJECT_NAME_STRING)
{
- TQListBox *lb = new TQListBox(parent, name);
+ TQListBox *lb = new TQListBox(tqparent, name);
if (init)
{
lb->insertItem(i18n("New Item"));
@@ -927,7 +927,7 @@ TQWidget *WidgetFactory::createWidget( const TQString &className, TQWidget *pare
return lb;
} else if (className == TQLISTVIEW_OBJECT_NAME_STRING)
{
- TQListView *lv = new TQListView(parent, name);
+ TQListView *lv = new TQListView(tqparent, name);
lv->setSorting(-1);
if (init)
{
@@ -936,91 +936,91 @@ TQWidget *WidgetFactory::createWidget( const TQString &className, TQWidget *pare
}
return lv;
} else if (className == TQLINEEDIT_OBJECT_NAME_STRING)
- return new TQLineEdit(parent, name);
+ return new TQLineEdit(tqparent, name);
else if (className == TQSPINBOX_OBJECT_NAME_STRING)
- return new TQSpinBox(parent, name);
+ return new TQSpinBox(tqparent, name);
else if (className == TQSPLITTER_OBJECT_NAME_STRING)
- return new TQSplitter(parent, name);
+ return new TQSplitter(tqparent, name);
else if (className == TQMULTILINEEDIT_OBJECT_NAME_STRING)
- return new TQMultiLineEdit(parent, name);
+ return new TQMultiLineEdit(tqparent, name);
else if (className == TQTEXTEDIT_OBJECT_NAME_STRING)
- return new TQTextEdit(parent, name);
+ return new TQTextEdit(tqparent, name);
else if (className == TQLABEL_OBJECT_NAME_STRING)
{
- QDesignerLabel *l = new QDesignerLabel(parent, name);
+ TQDesignerLabel *l = new TQDesignerLabel(tqparent, name);
if (init)
{
- l->setText(TQString::fromLatin1(name));
- MetaDataBase::addEntry(l);
- MetaDataBase::setPropertyChanged(l, "text", true);
+ l->setText(TQString::tqfromLatin1(name));
+ MetaDataBase::addEntry(TQT_TQOBJECT(l));
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(l), "text", true);
}
return l;
} else if (className == TQLAYOUTWIDGET_OBJECT_NAME_STRING)
- return new QLayoutWidget(parent, name);
+ return new TQLayoutWidget(tqparent, name);
else if (className == TQTABWIDGET_OBJECT_NAME_STRING)
{
- TQTabWidget *tw = new QDesignerTabWidget(parent, name);
+ TQTabWidget *tw = new TQDesignerTabWidget(tqparent, name);
if (init)
{
- FormWindow *fw = find_formwindow(parent);
- TQWidget *w = fw ? new QDesignerWidget(fw, tw, "tab") : new TQWidget(tw, "tab");
+ FormWindow *fw = find_formwindow(tqparent);
+ TQWidget *w = fw ? new TQDesignerWidget(fw, tw, "tab") : new TQWidget(tw, "tab");
tw->addTab(w, i18n("Tab 1"));
- MetaDataBase::addEntry(w);
- w = fw ? new QDesignerWidget(fw, tw, "tab") : new TQWidget(tw, "tab");
+ MetaDataBase::addEntry(TQT_TQOBJECT(w));
+ w = fw ? new TQDesignerWidget(fw, tw, "tab") : new TQWidget(tw, "tab");
tw->addTab(w, i18n("Tab 2"));
- MetaDataBase::addEntry(tw);
- MetaDataBase::addEntry(w);
+ MetaDataBase::addEntry(TQT_TQOBJECT(tw));
+ MetaDataBase::addEntry(TQT_TQOBJECT(w));
}
return tw;
} else if (className == TQCOMBOBOX_OBJECT_NAME_STRING)
{
- return new TQComboBox(false, parent, name);
+ return new TQComboBox(false, tqparent, name);
} else if (className == TQWIDGET_OBJECT_NAME_STRING)
{
- if (parent &&
- (parent->inherits("FormWindow") || parent->inherits(TQWIZARD_OBJECT_NAME_STRING)
- || parent->inherits(TQTABWIDGET_OBJECT_NAME_STRING) || parent->inherits(TQTOOLBOX_OBJECT_NAME_STRING) || parent->inherits(TQMAINWINDOW_OBJECT_NAME_STRING)))
+ if (tqparent &&
+ (tqparent->inherits("FormWindow") || tqparent->inherits(TQWIZARD_OBJECT_NAME_STRING)
+ || tqparent->inherits(TQTABWIDGET_OBJECT_NAME_STRING) || tqparent->inherits(TQTOOLBOX_OBJECT_NAME_STRING) || tqparent->inherits(TQMAINWINDOW_OBJECT_NAME_STRING)))
{
- FormWindow *fw = find_formwindow(parent);
+ FormWindow *fw = find_formwindow(tqparent);
if (fw)
{
- QDesignerWidget *dw = new QDesignerWidget(fw, parent, name);
- MetaDataBase::addEntry(dw);
+ TQDesignerWidget *dw = new TQDesignerWidget(fw, tqparent, name);
+ MetaDataBase::addEntry(TQT_TQOBJECT(dw));
return dw;
}
}
- return new TQWidget(parent, name);
+ return new TQWidget(tqparent, name);
} else if (className == TQDIALOG_OBJECT_NAME_STRING)
{
TQDialog *dia = 0;
- if (parent && parent->inherits("FormWindow"))
- dia = new QDesignerDialog((FormWindow *) parent, parent, name);
+ if (tqparent && tqparent->inherits("FormWindow"))
+ dia = new TQDesignerDialog((FormWindow *) tqparent, tqparent, name);
else
- dia = new TQDialog(parent, name);
- if (parent && !parent->inherits("MainWindow"))
- dia->reparent(parent, TQPoint(0, 0), true);
+ dia = new TQDialog(tqparent, name);
+ if (tqparent && !tqparent->inherits("MainWindow"))
+ dia->reparent(tqparent, TQPoint(0, 0), true);
return dia;
} else if (className == TQWIZARD_OBJECT_NAME_STRING)
{
- TQWizard *wiz = new QDesignerWizard(parent, name);
- if (parent && !parent->inherits("MainWindow"))
+ TQWizard *wiz = new TQDesignerWizard(tqparent, name);
+ if (tqparent && !tqparent->inherits("MainWindow"))
{
- wiz->reparent(parent, TQPoint(0, 0), true);
+ wiz->reparent(tqparent, TQPoint(0, 0), true);
}
- if (init && parent && parent->inherits("FormWindow"))
+ if (init && tqparent && tqparent->inherits("FormWindow"))
{
- QDesignerWidget *dw = new QDesignerWidget((FormWindow *) parent, wiz, "page");
- MetaDataBase::addEntry(dw);
+ TQDesignerWidget *dw = new TQDesignerWidget((FormWindow *) tqparent, wiz, "page");
+ MetaDataBase::addEntry(TQT_TQOBJECT(dw));
wiz->addPage(dw, i18n("Page"));
TQTimer::singleShot(0, wiz, TQT_SLOT(next()));
}
return wiz;
} else if (className == "Spacer")
{
- Spacer *s = new Spacer(parent, name);
- MetaDataBase::addEntry(s);
- MetaDataBase::setPropertyChanged(s, "orientation", true);
- MetaDataBase::setPropertyChanged(s, "sizeType", true);
+ Spacer *s = new Spacer(tqparent, name);
+ MetaDataBase::addEntry(TQT_TQOBJECT(s));
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(s), "orientation", true);
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(s), "sizeType", true);
if (!r)
return s;
if (!r->isValid() || r->width() < 2 && r->height() < 2)
@@ -1031,53 +1031,53 @@ TQWidget *WidgetFactory::createWidget( const TQString &className, TQWidget *pare
s->setOrientation(Qt::Horizontal);
return s;
} else if (className == TQLCDNUMBER_OBJECT_NAME_STRING)
- return new TQLCDNumber(parent, name);
+ return new TQLCDNumber(tqparent, name);
else if (className == TQPROGRESSBAR_OBJECT_NAME_STRING)
- return new TQProgressBar(parent, name);
+ return new TQProgressBar(tqparent, name);
else if (className == TQTEXTVIEW_OBJECT_NAME_STRING)
- return new TQTextView(parent, name);
+ return new TQTextView(tqparent, name);
else if (className == TQTEXTBROWSER_OBJECT_NAME_STRING)
- return new TQTextBrowser(parent, name);
+ return new TQTextBrowser(tqparent, name);
else if (className == TQDIAL_OBJECT_NAME_STRING)
- return new TQDial(parent, name);
+ return new TQDial(tqparent, name);
else if (className == TQSLIDER_OBJECT_NAME_STRING)
{
- TQSlider *s = new TQSlider(parent, name);
+ TQSlider *s = new TQSlider(tqparent, name);
if (!r)
return s;
if (!r->isValid() || r->width() < 2 && r->height() < 2)
s->setOrientation(orient);
else if (r->width() > r->height())
s->setOrientation(Qt::Horizontal);
- MetaDataBase::addEntry(s);
- MetaDataBase::setPropertyChanged(s, "orientation", true);
+ MetaDataBase::addEntry(TQT_TQOBJECT(s));
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(s), "orientation", true);
return s;
} else if (className == TQSCROLLBAR_OBJECT_NAME_STRING)
{
- TQScrollBar *s = new TQScrollBar(parent, name);
+ TQScrollBar *s = new TQScrollBar(tqparent, name);
if (!r)
return s;
if (!r->isValid() || r->width() < 2 && r->height() < 2)
s->setOrientation(orient);
else if (r->width() > r->height())
s->setOrientation(Qt::Horizontal);
- MetaDataBase::addEntry(s);
- MetaDataBase::setPropertyChanged(s, "orientation", true);
+ MetaDataBase::addEntry(TQT_TQOBJECT(s));
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(s), "orientation", true);
return s;
} else if (className == TQFRAME_OBJECT_NAME_STRING)
{
if (!init)
- return new TQFrame(parent, name);
- TQFrame *f = new TQFrame(parent, name);
+ return new TQFrame(tqparent, name);
+ TQFrame *f = new TQFrame(tqparent, name);
f->setFrameStyle(TQFrame::StyledPanel | TQFrame::Raised);
return f;
} else if (className == "Line")
{
- Line *l = new Line(parent, name);
- MetaDataBase::addEntry(l);
- MetaDataBase::setPropertyChanged(l, "orientation", true);
- MetaDataBase::setPropertyChanged(l, "frameShadow", true);
- MetaDataBase::setPropertyChanged(l, "frameShape", true);
+ Line *l = new Line(tqparent, name);
+ MetaDataBase::addEntry(TQT_TQOBJECT(l));
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(l), "orientation", true);
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(l), "frameShadow", true);
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(l), "frameShape", true);
if (!r)
return l;
if (!r->isValid() || r->width() < 2 && r->height() < 2)
@@ -1087,38 +1087,38 @@ TQWidget *WidgetFactory::createWidget( const TQString &className, TQWidget *pare
return l;
} else if (className == TQMAINWINDOW_OBJECT_NAME_STRING)
{
- TQMainWindow *mw = new KmdrMainWindow(parent, name, 0);
- mw->setDockEnabled(Qt::DockMinimized, false);
- QDesignerWidget *dw = new QDesignerWidget((FormWindow *) parent, mw, "central widget");
+ TQMainWindow *mw = new KmdrMainWindow(tqparent, name, 0);
+ mw->setDockEnabled(TQt::DockMinimized, false);
+ TQDesignerWidget *dw = new TQDesignerWidget((FormWindow *) tqparent, mw, "central widget");
mw->setDockMenuEnabled(false);
- MetaDataBase::addEntry(dw);
+ MetaDataBase::addEntry(TQT_TQOBJECT(dw));
mw->setCentralWidget(dw);
(void) mw->statusBar();
dw->show();
return mw;
}
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
else if (className == TQDATABROWSER_OBJECT_NAME_STRING)
{
- TQWidget *w = new QDesignerDataBrowser(parent, name);
- if (parent)
- w->reparent(parent, TQPoint(0, 0), true);
+ TQWidget *w = new TQDesignerDataBrowser(tqparent, name);
+ if (tqparent)
+ w->reparent(tqparent, TQPoint(0, 0), true);
return w;
} else if (className == TQDATAVIEW_OBJECT_NAME_STRING)
{
- TQWidget *w = new QDesignerDataView(parent, name);
- if (parent)
- w->reparent(parent, TQPoint(0, 0), true);
+ TQWidget *w = new TQDesignerDataView(tqparent, name);
+ if (tqparent)
+ w->reparent(tqparent, TQPoint(0, 0), true);
return w;
}
#endif
#ifdef KOMMANDER
if (className == "LineEdit")
- return new LineEdit(parent, name);
+ return new LineEdit(tqparent, name);
else if (className == "ListView")
{
- TQListView *lv = new TQListView(parent, name);
+ TQListView *lv = new TQListView(tqparent, name);
lv->setSorting(-1);
if (init)
{
@@ -1130,29 +1130,29 @@ TQWidget *WidgetFactory::createWidget( const TQString &className, TQWidget *pare
else if (className == "Dialog")
{
TQDialog *dia = 0;
- if (parent && parent->inherits("FormWindow"))
- dia = new EditorDialog((FormWindow *) parent, parent, name);
+ if (tqparent && tqparent->inherits("FormWindow"))
+ dia = new EditorDialog((FormWindow *) tqparent, tqparent, name);
else
- dia = new Dialog(parent, name, false);
+ dia = new Dialog(tqparent, name, false);
- if (parent)
- dia->reparent(parent, TQPoint(0, 0), true);
+ if (tqparent)
+ dia->reparent(tqparent, TQPoint(0, 0), true);
return dia;
}
else if (className == "Wizard")
{
//qDebug("Creating Wizard...");
TQWizard *wiz;
- if (parent && parent->inherits("FormWindow"))
- wiz = new QDesignerWizard(parent, name);
+ if (tqparent && tqparent->inherits("FormWindow"))
+ wiz = new TQDesignerWizard(tqparent, name);
else
- wiz = new Wizard(parent, name);
- if (parent)
- wiz->reparent(parent, TQPoint(0, 0), true);
- if (init && parent && parent->inherits("FormWindow"))
+ wiz = new Wizard(tqparent, name);
+ if (tqparent)
+ wiz->reparent(tqparent, TQPoint(0, 0), true);
+ if (init && tqparent && tqparent->inherits("FormWindow"))
{
- QDesignerWidget *dw = new QDesignerWidget((FormWindow *) parent, wiz, "page");
- MetaDataBase::addEntry(dw);
+ TQDesignerWidget *dw = new TQDesignerWidget((FormWindow *) tqparent, wiz, "page");
+ MetaDataBase::addEntry(TQT_TQOBJECT(dw));
wiz->addPage(dw, i18n("Page 1"));
wiz->addPage(dw, i18n("Page 2"));
TQTimer::singleShot(0, wiz, TQT_SLOT(next()));
@@ -1161,74 +1161,74 @@ TQWidget *WidgetFactory::createWidget( const TQString &className, TQWidget *pare
}
else if (className == "TabWidget")
{
- TQTabWidget *tw = new EditorTabWidget(parent, name);
+ TQTabWidget *tw = new EditorTabWidget(tqparent, name);
if (init)
{
- FormWindow *fw = find_formwindow(parent);
- TQWidget *w = fw ? new QDesignerWidget(fw, tw, "tab") : new TQWidget(tw, "tab");
+ FormWindow *fw = find_formwindow(tqparent);
+ TQWidget *w = fw ? new TQDesignerWidget(fw, tw, "tab") : new TQWidget(tw, "tab");
tw->addTab(w, i18n("Tab 1"));
- MetaDataBase::addEntry(w);
- w = fw ? new QDesignerWidget(fw, tw, "tab") : new TQWidget(tw, "tab");
+ MetaDataBase::addEntry(TQT_TQOBJECT(w));
+ w = fw ? new TQDesignerWidget(fw, tw, "tab") : new TQWidget(tw, "tab");
tw->addTab(w, i18n("Tab 2"));
- MetaDataBase::addEntry(tw);
- MetaDataBase::addEntry(w);
+ MetaDataBase::addEntry(TQT_TQOBJECT(tw));
+ MetaDataBase::addEntry(TQT_TQOBJECT(w));
}
return tw;
} else if (className == "ToolBox")
{
- TQToolBox *tw = new EditorToolBox(parent, name);
+ TQToolBox *tw = new EditorToolBox(tqparent, name);
if (init)
{
- FormWindow *fw = find_formwindow(parent);
- TQWidget *w = fw ? new QDesignerWidget(fw, tw, "toolbox") : new TQWidget(tw, "toolbox");
+ FormWindow *fw = find_formwindow(tqparent);
+ TQWidget *w = fw ? new TQDesignerWidget(fw, tw, "toolbox") : new TQWidget(tw, "toolbox");
tw->addItem(w, i18n("Page 1"));
- MetaDataBase::addEntry(w);
- w = fw ? new QDesignerWidget(fw, tw, "toolbox") : new TQWidget(tw, "toolbox");
+ MetaDataBase::addEntry(TQT_TQOBJECT(w));
+ w = fw ? new TQDesignerWidget(fw, tw, "toolbox") : new TQWidget(tw, "toolbox");
tw->addItem(w, i18n("Page 2"));
- MetaDataBase::addEntry(tw);
- MetaDataBase::addEntry(w);
+ MetaDataBase::addEntry(TQT_TQOBJECT(tw));
+ MetaDataBase::addEntry(TQT_TQOBJECT(w));
}
return tw;
}
else if (className == "ExecButton")
- return new ExecButton(parent, name);
+ return new ExecButton(tqparent, name);
else if (className == "CloseButton")
- return new CloseButton(parent, name);
+ return new CloseButton(tqparent, name);
else if (className == "SubDialog")
- return new SubDialog(parent, name);
+ return new SubDialog(tqparent, name);
else if (className == "FileSelector")
- return new FileSelector(parent, name);
+ return new FileSelector(tqparent, name);
else if (className == "TextEdit")
- return new TextEdit(parent, name);
+ return new TextEdit(tqparent, name);
else if (className == "RadioButton")
- return new RadioButton(parent, name);
+ return new RadioButton(tqparent, name);
else if (className == "ButtonGroup")
- return new ButtonGroup(parent, name);
+ return new ButtonGroup(tqparent, name);
else if (className == "GroupBox")
- return new GroupBox(parent, name);
+ return new GroupBox(tqparent, name);
else if (className == "CheckBox")
- return new CheckBox(parent, name);
+ return new CheckBox(tqparent, name);
else if (className == "ComboBox")
- return new ComboBox(parent, name);
+ return new ComboBox(tqparent, name);
else if (className == "SpinBoxInt")
- return new SpinBoxInt(parent, name);
+ return new SpinBoxInt(tqparent, name);
else if (className == "ListBox")
- return new ListBox(parent, name);
+ return new ListBox(tqparent, name);
else if (className == "ScriptObject")
- return new ScriptObject(parent, name);
+ return new ScriptObject(tqparent, name);
else if (className == "RichTextEditor")
- return new RichTextEditor(parent, name);
+ return new RichTextEditor(tqparent, name);
else if (className == "DatePicker")
- return new DatePicker(parent, name);
+ return new DatePicker(tqparent, name);
else if (className == "PopupMenu")
- return new PopupMenu(parent, name);
+ return new PopupMenu(tqparent, name);
else if (className == "FontDialog")
- return new FontDialog(parent, name);
+ return new FontDialog(tqparent, name);
else if (className == "AboutDialog")
- return new AboutDialog(parent, name);
+ return new AboutDialog(tqparent, name);
else if (className == "TreeWidget")
{
- TQListView *lv = new TreeWidget(parent, name);
+ TQListView *lv = new TreeWidget(tqparent, name);
lv->setSorting(-1);
if (init)
{
@@ -1238,33 +1238,33 @@ TQWidget *WidgetFactory::createWidget( const TQString &className, TQWidget *pare
return lv;
} else if (className == "Slider")
{
- Slider *s = new Slider(parent, name);
+ Slider *s = new Slider(tqparent, name);
if (!r)
return s;
if (!r->isValid() || r->width() < 2 && r->height() < 2)
s->setOrientation(orient);
else if (r->width() > r->height())
s->setOrientation(Qt::Horizontal);
- MetaDataBase::addEntry(s);
- MetaDataBase::setPropertyChanged(s, "orientation", true);
+ MetaDataBase::addEntry(TQT_TQOBJECT(s));
+ MetaDataBase::setPropertyChanged(TQT_TQOBJECT(s), "orientation", true);
return s;
}
#endif
- TQWidget *w = KommanderFactory::createWidget(className, parent, name);
+ TQWidget *w = KommanderFactory::createWidget(className, tqparent, name);
return w;
}
-/*! Find out which type the layout of the widget is. Returns \c HBox,
- \c VBox, \c Grid or \c NoLayout. \a layout points to this
- TQWidget::layout() of \a w or to 0 after the function call.
+/*! Find out which type the tqlayout of the widget is. Returns \c HBox,
+ \c VBox, \c Grid or \c NoLayout. \a tqlayout points to this
+ TQWidget::tqlayout() of \a w or to 0 after the function call.
*/
-WidgetFactory::LayoutType WidgetFactory::layoutType( TQWidget *w, TQLayout *&layout )
+WidgetFactory::LayoutType WidgetFactory::tqlayoutType( TQWidget *w, TQLayout *&tqlayout )
{
- layout = 0;
+ tqlayout = 0;
if ( w && w->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) )
w = ((TQTabWidget*)w)->currentPage();
@@ -1278,19 +1278,19 @@ WidgetFactory::LayoutType WidgetFactory::layoutType( TQWidget *w, TQLayout *&lay
w = ((TQWidgetStack*)w)->visibleWidget();
if ( w && w->inherits( TQSPLITTER_OBJECT_NAME_STRING ) )
- return ( (TQSplitter*)w )->orientation() == Horizontal ? HBox : VBox;
+ return ( (TQSplitter*)w )->orientation() ==Qt::Horizontal ? HBox : VBox;
- if ( !w || !w->layout() )
+ if ( !w || !w->tqlayout() )
return NoLayout;
- TQLayout *lay = w->layout();
+ TQLayout *lay = w->tqlayout();
if ( w->inherits( TQGROUPBOX_OBJECT_NAME_STRING ) ) {
- TQObjectList *l = lay->queryList( TQLAYOUT_OBJECT_NAME_STRING );
+ TQObjectList *l = TQT_TQOBJECT(lay)->queryList( TQLAYOUT_OBJECT_NAME_STRING );
if ( l && l->first() )
lay = (TQLayout*)l->first();
delete l;
}
- layout = lay;
+ tqlayout = lay;
if ( lay->inherits( TQHBOXLAYOUT_OBJECT_NAME_STRING ) )
return HBox;
@@ -1304,13 +1304,13 @@ WidgetFactory::LayoutType WidgetFactory::layoutType( TQWidget *w, TQLayout *&lay
/*!
\overload
*/
-WidgetFactory::LayoutType WidgetFactory::layoutType( TQLayout *layout )
+WidgetFactory::LayoutType WidgetFactory::tqlayoutType( TQLayout *tqlayout )
{
- if ( layout->inherits( TQHBOXLAYOUT_OBJECT_NAME_STRING ) )
+ if ( tqlayout->inherits( TQHBOXLAYOUT_OBJECT_NAME_STRING ) )
return HBox;
- else if ( layout->inherits( TQVBOXLAYOUT_OBJECT_NAME_STRING ) )
+ else if ( tqlayout->inherits( TQVBOXLAYOUT_OBJECT_NAME_STRING ) )
return VBox;
- else if ( layout->inherits( TQGRIDLAYOUT_OBJECT_NAME_STRING ) )
+ else if ( tqlayout->inherits( TQGRIDLAYOUT_OBJECT_NAME_STRING ) )
return Grid;
return NoLayout;
}
@@ -1318,25 +1318,25 @@ WidgetFactory::LayoutType WidgetFactory::layoutType( TQLayout *layout )
/*!
\overload
*/
-WidgetFactory::LayoutType WidgetFactory::layoutType( TQWidget *w )
+WidgetFactory::LayoutType WidgetFactory::tqlayoutType( TQWidget *w )
{
TQLayout *l = 0;
- return layoutType( w, l );
+ return tqlayoutType( w, l );
}
-TQWidget *WidgetFactory::layoutParent( TQLayout *layout )
+TQWidget *WidgetFactory::tqlayoutParent( TQLayout *tqlayout )
{
- TQObject *o = layout;
+ TQObject *o = TQT_TQOBJECT(tqlayout);
while ( o ) {
if ( o->isWidgetType() )
return (TQWidget*)o;
- o = o->parent();
+ o = o->tqparent();
}
return 0;
}
-/*! Returns the widget into which children should be inserted when \a
+/*! Returns the widget into which tqchildren should be inserted when \a
w is a container known to the designer.
Usually that is \a w itself, sometimes it is different (e.g. a
@@ -1363,22 +1363,22 @@ TQWidget* WidgetFactory::containerOfWidget( TQWidget *w )
}
/*! Returns the actual designer widget of the container \a w. This is
- normally \a w itself, but might be a parent or grand parent of \a w
+ normally \a w itself, but might be a tqparent or grand tqparent of \a w
(e.g. when working with a tabwidget and \a w is the container which
- contains and layouts childs, but the actual widget known to the
- designer is the tabwidget which is the parent of \a w. So this
+ contains and tqlayouts childs, but the actual widget known to the
+ designer is the tabwidget which is the tqparent of \a w. So this
function returns the tabwidget then.)
*/
TQWidget* WidgetFactory::widgetOfContainer( TQWidget *w )
{
- if ( w->parentWidget() && w->parentWidget()->inherits( TQWIDGETSTACK_OBJECT_NAME_STRING ) )
- w = w->parentWidget();
+ if ( w->tqparentWidget() && w->tqparentWidget()->inherits( TQWIDGETSTACK_OBJECT_NAME_STRING ) )
+ w = w->tqparentWidget();
while ( w ) {
- if ( WidgetDatabase::isContainer( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( w ) ) ) ||
- w && w->parentWidget() && w->parentWidget()->inherits( "FormWindow" ) )
+ if ( WidgetDatabase::isContainer( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( TQT_TQOBJECT(w) ) ) ) ||
+ w && w->tqparentWidget() && w->tqparentWidget()->inherits( "FormWindow" ) )
return w;
- w = w->parentWidget();
+ w = w->tqparentWidget();
}
return w;
}
@@ -1391,15 +1391,15 @@ bool WidgetFactory::isPassiveInteractor( TQObject* o )
if ( TQApplication::activePopupWidget() ) // if a popup is open, we have to make sure that this one is closed, else X might do funny things
return true;
- if ( o->inherits( TQTABBAR_OBJECT_NAME_STRING ) || ::qt_cast<TQToolBox*>(o->parent()) )
+ if ( o->inherits( TQTABBAR_OBJECT_NAME_STRING ) || ::tqqt_cast<TQToolBox*>(o->tqparent()) )
return true;
else if ( o->inherits( TQSIZEGRIP_OBJECT_NAME_STRING ) )
return true;
- else if ( o->inherits( TQTOOLBUTTON_OBJECT_NAME_STRING ) && o->parent() && o->parent()->inherits( TQTABBAR_OBJECT_NAME_STRING ) )
+ else if ( o->inherits( TQTOOLBUTTON_OBJECT_NAME_STRING ) && o->tqparent() && o->tqparent()->inherits( TQTABBAR_OBJECT_NAME_STRING ) )
return true;
- else if ( o->parent() && o->parent()->inherits( TQWIZARD_OBJECT_NAME_STRING ) && o->inherits( TQPUSHBUTTON_OBJECT_NAME_STRING ) )
+ else if ( o->tqparent() && o->tqparent()->inherits( TQWIZARD_OBJECT_NAME_STRING ) && o->inherits( TQPUSHBUTTON_OBJECT_NAME_STRING ) )
return true;
- else if ( o->parent() && o->parent()->inherits( TQMAINWINDOW_OBJECT_NAME_STRING ) && o->inherits( TQMENUBAR_OBJECT_NAME_STRING ) )
+ else if ( o->tqparent() && o->tqparent()->inherits( TQMAINWINDOW_OBJECT_NAME_STRING ) && o->inherits( TQMENUBAR_OBJECT_NAME_STRING ) )
return true;
else if ( o->inherits( TQDOCKWINDOWHANDLE_OBJECT_NAME_STRING ) )
return true;
@@ -1415,43 +1415,43 @@ bool WidgetFactory::isPassiveInteractor( TQObject* o )
*/
const char* WidgetFactory::classNameOf( TQObject* o )
{
- if (o->inherits("QDesignerTabWidget"))
- return "TQTabWidget";
+ if (o->inherits("TQDesignerTabWidget"))
+ return TQTABWIDGET_OBJECT_NAME_STRING;
#ifdef KOMMANDER
else if (o->inherits("EditorTabWidget"))
return "TabWidget";
else if (o->inherits("EditorToolBox"))
return "ToolBox";
#endif
- else if (o->inherits("QDesignerDialog"))
- return "TQDialog";
- else if (o->inherits("QDesignerWidget"))
- return "TQWidget";
+ else if (o->inherits("TQDesignerDialog"))
+ return TQDIALOG_OBJECT_NAME_STRING;
+ else if (o->inherits("TQDesignerWidget"))
+ return TQWIDGET_OBJECT_NAME_STRING;
else if (o->inherits("CustomWidget"))
return ((CustomWidget *) o)->realClassName().latin1();
- else if (o->inherits("QDesignerLabel"))
- return "TQLabel";
- else if (o->inherits("QDesignerWizard"))
- return "TQWizard";
+ else if (o->inherits("TQDesignerLabel"))
+ return TQLABEL_OBJECT_NAME_STRING;
+ else if (o->inherits("TQDesignerWizard"))
+ return TQWIZARD_OBJECT_NAME_STRING;
else if (o->inherits("EditorWizard"))
return "Wizard";
- else if (o->inherits("QDesignerPushButton"))
- return "TQPushButton";
- else if (o->inherits("QDesignerToolButton"))
- return "TQToolButton";
- else if (o->inherits("QDesignerRadioButton"))
- return "TQRadioButton";
- else if (o->inherits("QDesignerCheckBox"))
- return "TQCheckBox";
- else if (o->inherits("QDesignerMenuBar"))
- return "TQMenuBar";
- else if (o->inherits("QDesignerToolBar"))
- return "TQToolBar";
-#ifndef QT_NO_SQL
- else if (o->inherits("QDesignerDataBrowser"))
- return "TQDataBrowser";
- else if (o->inherits("QDesignerDataView"))
- return "TQDataView";
+ else if (o->inherits("TQDesignerPushButton"))
+ return TQPUSHBUTTON_OBJECT_NAME_STRING;
+ else if (o->inherits("TQDesignerToolButton"))
+ return TQTOOLBUTTON_OBJECT_NAME_STRING;
+ else if (o->inherits("TQDesignerRadioButton"))
+ return TQRADIOBUTTON_OBJECT_NAME_STRING;
+ else if (o->inherits("TQDesignerCheckBox"))
+ return TQCHECKBOX_OBJECT_NAME_STRING;
+ else if (o->inherits("TQDesignerMenuBar"))
+ return TQMENUBAR_OBJECT_NAME_STRING;
+ else if (o->inherits("TQDesignerToolBar"))
+ return TQTOOLBAR_OBJECT_NAME_STRING;
+#ifndef TQT_NO_SQL
+ else if (o->inherits("TQDesignerDataBrowser"))
+ return TQDATABROWSER_OBJECT_NAME_STRING;
+ else if (o->inherits("TQDesignerDataView"))
+ return TQDATAVIEW_OBJECT_NAME_STRING;
#endif
else if (o->inherits("EditorDialog"))
return "Dialog";
@@ -1466,12 +1466,12 @@ const char* WidgetFactory::classNameOf( TQObject* o )
void WidgetFactory::initChangedProperties( TQObject *o )
{
MetaDataBase::setPropertyChanged( o, "name", true );
- if ( !o->inherits( "QDesignerToolBar" ) && !o->inherits( "QDesignerMenuBar" ) )
+ if ( !o->inherits( "TQDesignerToolBar" ) && !o->inherits( "TQDesignerMenuBar" ) )
MetaDataBase::setPropertyChanged( o, "geometry", true );
if ( o->inherits( TQPUSHBUTTON_OBJECT_NAME_STRING ) || o->inherits(TQRADIOBUTTON_OBJECT_NAME_STRING) || o->inherits( TQCHECKBOX_OBJECT_NAME_STRING ) || o->inherits( TQTOOLBUTTON_OBJECT_NAME_STRING ) )
MetaDataBase::setPropertyChanged( o, "text", true );
- else if (::qt_cast<TQToolButton*>(o) && ::qt_cast<TQToolBox*>(widgetOfContainer((TQWidget*)o->parent()))) {
+ else if (::tqqt_cast<TQToolButton*>(o) && ::tqqt_cast<TQToolBox*>(widgetOfContainer((TQWidget*)o->tqparent()))) {
MetaDataBase::setPropertyChanged( o, "usesTextLabel", TRUE );
MetaDataBase::setPropertyChanged( o, "textLabel", TRUE );
MetaDataBase::setPropertyChanged( o, "autoRaise", TRUE );
@@ -1484,7 +1484,7 @@ void WidgetFactory::initChangedProperties( TQObject *o )
} else if ( o->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) || o->inherits( TQWIZARD_OBJECT_NAME_STRING ) ) {
MetaDataBase::setPropertyChanged( o, "pageTitle", true );
MetaDataBase::setPropertyChanged( o, "pageName", true );
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
} else if ( o->inherits( TQTABLE_OBJECT_NAME_STRING ) && !o->inherits( TQDATATABLE_OBJECT_NAME_STRING ) ) {
MetaDataBase::setPropertyChanged( o, "numRows", true );
MetaDataBase::setPropertyChanged( o, "numCols", true );
@@ -1494,7 +1494,7 @@ void WidgetFactory::initChangedProperties( TQObject *o )
t->verticalHeader()->setLabel( i, TQString::number( i + 1 ) );
}
#endif
- } else if ( ::qt_cast<TQToolBox*>(o) ) {
+ } else if ( ::tqqt_cast<TQToolBox*>(o) ) {
MetaDataBase::setPropertyChanged( o, "currentIndex", true );
MetaDataBase::setPropertyChanged( o, "itemName", true );
MetaDataBase::setPropertyChanged( o, "itemLabel", true );
@@ -1503,9 +1503,9 @@ void WidgetFactory::initChangedProperties( TQObject *o )
MetaDataBase::setPropertyChanged( o, "itemBackgroundMode", true );
} else if ( o->inherits( TQSPLITTER_OBJECT_NAME_STRING ) ) {
MetaDataBase::setPropertyChanged( o, "orientation", true );
- } else if ( o->inherits( "QDesignerToolBar" ) ) {
+ } else if ( o->inherits( "TQDesignerToolBar" ) ) {
MetaDataBase::setPropertyChanged( o, "label", true );
- } else if ( o->inherits( "QDesignerMenuBar" ) ) {
+ } else if ( o->inherits( "TQDesignerMenuBar" ) ) {
MetaDataBase::setPropertyChanged( o, "itemName", true );
MetaDataBase::setPropertyChanged( o, "itemNumber", true );
MetaDataBase::setPropertyChanged( o, "itemText", true );
@@ -1530,7 +1530,7 @@ bool WidgetFactory::hasSpecialEditor( int id )
return true;
if (className == TQTEXTEDIT_OBJECT_NAME_STRING || className == TQMULTILINEEDIT_OBJECT_NAME_STRING)
return true;
- if (className.contains("Table"))
+ if (className.tqcontains("Table"))
return true;
return false;
@@ -1544,13 +1544,13 @@ bool WidgetFactory::hasItems( int id )
return true;
if (className.mid(1) == "ListBox" || className.mid(1) == "ListView" ||
className.mid(1) == "IconView" || className.mid(1) == "ComboBox" ||
- className.contains("Table"))
+ className.tqcontains("Table"))
return true;
return false;
}
-void WidgetFactory::editWidget( int id, TQWidget *parent, TQWidget *editWidget, FormWindow *fw )
+void WidgetFactory::editWidget( int id, TQWidget *tqparent, TQWidget *editWidget, FormWindow *fw )
{
TQString className = WidgetDatabase::className(id);
@@ -1562,7 +1562,7 @@ void WidgetFactory::editWidget( int id, TQWidget *parent, TQWidget *editWidget,
TQComboBox *cb = (TQComboBox *) editWidget;
- ListBoxEditor *e = new ListBoxEditor(parent, cb->listBox(), fw);
+ ListBoxEditor *e = new ListBoxEditor(tqparent, cb->listBox(), fw);
e->exec();
delete e;
@@ -1572,7 +1572,7 @@ void WidgetFactory::editWidget( int id, TQWidget *parent, TQWidget *editWidget,
}
if (className == "TextEdit" || className == "TextBrowser")
{
- MultiLineEditor *e = new MultiLineEditor(parent, editWidget, fw);
+ MultiLineEditor *e = new MultiLineEditor(tqparent, editWidget, fw);
e->exec();
delete e;
return;
@@ -1582,7 +1582,7 @@ void WidgetFactory::editWidget( int id, TQWidget *parent, TQWidget *editWidget,
if (!editWidget->inherits(TQLISTVIEW_OBJECT_NAME_STRING))
return;
TQListView *lv = (TQListView *) editWidget;
- ListViewEditor *e = new ListViewEditor(parent, lv, fw);
+ ListViewEditor *e = new ListViewEditor(tqparent, lv, fw);
e->exec();
delete e;
return;
@@ -1591,7 +1591,7 @@ void WidgetFactory::editWidget( int id, TQWidget *parent, TQWidget *editWidget,
{
if (!editWidget->inherits(TQLISTBOX_OBJECT_NAME_STRING))
return;
- ListBoxEditor *e = new ListBoxEditor(parent, editWidget, fw);
+ ListBoxEditor *e = new ListBoxEditor(tqparent, editWidget, fw);
e->exec();
delete e;
return;
@@ -1601,7 +1601,7 @@ void WidgetFactory::editWidget( int id, TQWidget *parent, TQWidget *editWidget,
{
if (!editWidget->inherits(TQLISTBOX_OBJECT_NAME_STRING))
return;
- ListBoxEditor *e = new ListBoxEditor(parent, editWidget, fw);
+ ListBoxEditor *e = new ListBoxEditor(tqparent, editWidget, fw);
e->exec();
delete e;
return;
@@ -1612,7 +1612,7 @@ void WidgetFactory::editWidget( int id, TQWidget *parent, TQWidget *editWidget,
if (!editWidget->inherits(TQCOMBOBOX_OBJECT_NAME_STRING))
return;
TQComboBox *cb = (TQComboBox *) editWidget;
- ListBoxEditor *e = new ListBoxEditor(parent, cb->listBox(), fw);
+ ListBoxEditor *e = new ListBoxEditor(tqparent, cb->listBox(), fw);
e->exec();
delete e;
cb->update();
@@ -1624,7 +1624,7 @@ void WidgetFactory::editWidget( int id, TQWidget *parent, TQWidget *editWidget,
if (!editWidget->inherits(TQLISTVIEW_OBJECT_NAME_STRING))
return;
TQListView *lv = (TQListView *) editWidget;
- ListViewEditor *e = new ListViewEditor(parent, lv, fw);
+ ListViewEditor *e = new ListViewEditor(tqparent, lv, fw);
e->exec();
delete e;
return;
@@ -1634,7 +1634,7 @@ void WidgetFactory::editWidget( int id, TQWidget *parent, TQWidget *editWidget,
{
if (!editWidget->inherits(TQICONVIEW_OBJECT_NAME_STRING))
return;
- IconViewEditor *e = new IconViewEditor(parent, editWidget, fw);
+ IconViewEditor *e = new IconViewEditor(tqparent, editWidget, fw);
e->exec();
delete e;
return;
@@ -1642,15 +1642,15 @@ void WidgetFactory::editWidget( int id, TQWidget *parent, TQWidget *editWidget,
if (className == TQMULTILINEEDIT_OBJECT_NAME_STRING || className == TQTEXTEDIT_OBJECT_NAME_STRING)
{
- MultiLineEditor *e = new MultiLineEditor(parent, editWidget, fw);
+ MultiLineEditor *e = new MultiLineEditor(tqparent, editWidget, fw);
e->exec();
delete e;
return;
}
-#ifndef QT_NO_TABLE
- if (className.contains("Table"))
+#ifndef TQT_NO_TABLE
+ if (className.tqcontains("Table"))
{
- TableEditor *e = new TableEditor(parent, editWidget, fw);
+ TableEditor *e = new TableEditor(tqparent, editWidget, fw);
e->exec();
delete e;
return;
@@ -1662,14 +1662,14 @@ bool WidgetFactory::canResetProperty( TQObject *w, const TQString &propName )
{
if ( propName == "name" || propName == "geometry" )
return false;
- TQStringList l = *changedProperties->find( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( w ) ) );
- return l.findIndex( propName ) == -1;
+ TQStringList l = *changedProperties->tqfind( WidgetDatabase::idFromClassName( WidgetFactory::classNameOf( w ) ) );
+ return l.tqfindIndex( propName ) == -1;
}
bool WidgetFactory::resetProperty( TQObject *w, const TQString &propName )
{
- const TQMetaProperty *p = w->metaObject()->property( w->metaObject()->
- findProperty( propName, true ), true );
+ const TQMetaProperty *p = w->tqmetaObject()->property( w->tqmetaObject()->
+ tqfindProperty( propName, true ), true );
if (!p )
return false;
return p->reset( w );
@@ -1678,33 +1678,33 @@ bool WidgetFactory::resetProperty( TQObject *w, const TQString &propName )
TQVariant WidgetFactory::defaultValue( TQObject *w, const TQString &propName )
{
if ( propName == "wordwrap" ) {
- int v = defaultValue( w, "alignment" ).toInt();
+ int v = defaultValue( w, "tqalignment" ).toInt();
return TQVariant( ( v & WordBreak ) == WordBreak, 0 );
} else if ( propName == "toolTip" || propName == "whatsThis" ) {
- return TQVariant( TQString::fromLatin1( "" ) );
+ return TQVariant( TQString::tqfromLatin1( "" ) );
} else if ( w->inherits( "CustomWidget" ) ) {
return TQVariant();
} else if ( propName == "frameworkCode" ) {
return TQVariant( true, 0 );
- } else if ( propName == "layoutMargin" ) {
- if ( w->inherits( "QLayoutWidget" ) )
+ } else if ( propName == "tqlayoutMargin" ) {
+ if ( w->inherits( TQLAYOUTWIDGET_OBJECT_NAME_STRING ) )
return TQVariant( 0 );
else if ( MainWindow::self->formWindow() )
- return TQVariant( MainWindow::self->formWindow()->layoutDefaultMargin() );
- } else if ( propName == "layoutSpacing" ) {
+ return TQVariant( MainWindow::self->formWindow()->tqlayoutDefaultMargin() );
+ } else if ( propName == "tqlayoutSpacing" ) {
if ( MainWindow::self->formWindow() )
- return TQVariant( MainWindow::self->formWindow()->layoutDefaultSpacing() );
+ return TQVariant( MainWindow::self->formWindow()->tqlayoutDefaultSpacing() );
}
- return *( *defaultProperties->find( WidgetDatabase::idFromClassName( classNameOf( w ) ) ) ).find( propName );
+ return *( *defaultProperties->tqfind( WidgetDatabase::idFromClassName( classNameOf( w ) ) ) ).tqfind( propName );
}
TQString WidgetFactory::defaultCurrentItem( TQObject *w, const TQString &propName )
{
- const TQMetaProperty *p = w->metaObject()->
- property( w->metaObject()->findProperty( propName, true ), true );
+ const TQMetaProperty *p = w->tqmetaObject()->
+ property( w->tqmetaObject()->tqfindProperty( propName, true ), true );
if ( !p ) {
- int v = defaultValue( w, "alignment" ).toInt();
+ int v = defaultValue( w, "tqalignment" ).toInt();
if ( propName == "hAlign" ) {
if ( ( v & AlignAuto ) == AlignAuto )
return "AlignAuto";
@@ -1724,17 +1724,17 @@ TQString WidgetFactory::defaultCurrentItem( TQObject *w, const TQString &propNam
if ( ( v & AlignBottom ) == AlignBottom )
return "AlignBottom";
}
- return TQString::null;
+ return TQString();
}
return p->valueToKey( defaultValue( w, propName ).toInt() );
}
-TQWidget *WidgetFactory::createCustomWidget( TQWidget *parent, const char *name, MetaDataBase::CustomWidget *w )
+TQWidget *WidgetFactory::createCustomWidget( TQWidget *tqparent, const char *name, MetaDataBase::CustomWidget *w )
{
if ( !w )
return 0;
- return new CustomWidget( parent, name, w );
+ return new CustomWidget( tqparent, name, w );
}
TQVariant WidgetFactory::property( TQObject *w, const char *name )
@@ -1745,13 +1745,13 @@ TQVariant WidgetFactory::property( TQObject *w, const char *name )
return MetaDataBase::fakeProperty( w, name );
}
-void QDesignerLabel::updateBuddy()
+void TQDesignerLabel::updateBuddy()
{
if ( myBuddy.isEmpty() )
return;
- TQObjectList *l = topLevelWidget()->queryList( TQWIDGET_OBJECT_NAME_STRING, myBuddy, false, true );
+ TQObjectList *l = tqtopLevelWidget()->queryList( TQWIDGET_OBJECT_NAME_STRING, myBuddy, false, true );
if ( !l || !l->first() ) {
delete l;
return;
@@ -1761,12 +1761,12 @@ void QDesignerLabel::updateBuddy()
delete l;
}
-void QDesignerWidget::paintEvent( TQPaintEvent *e )
+void TQDesignerWidget::paintEvent( TQPaintEvent *e )
{
formwindow->paintGrid( this, e );
}
-void QDesignerDialog::paintEvent( TQPaintEvent *e )
+void TQDesignerDialog::paintEvent( TQPaintEvent *e )
{
formwindow->paintGrid( this, e );
}
@@ -1776,12 +1776,12 @@ void EditorDialog::paintEvent( TQPaintEvent *e )
formwindow->paintGrid( this, e );
}
-TQSizePolicy QLayoutWidget::sizePolicy() const
+TQSizePolicy TQLayoutWidget::sizePolicy() const
{
return sp;
}
-bool QLayoutWidget::event( TQEvent *e )
+bool TQLayoutWidget::event( TQEvent *e )
{
if ( e && ( e->type() == TQEvent::ChildInserted ||
e->type() == TQEvent::ChildRemoved ||
@@ -1792,14 +1792,15 @@ bool QLayoutWidget::event( TQEvent *e )
}
/*
- This function must be called on QLayoutWidget creation and whenever
- the QLayoutWidget's parent layout changes (e.g., from a QHBoxLayout
- to a TQVBoxLayout), because of the (illogical) way layouting works.
+ This function must be called on TQLayoutWidget creation and whenever
+ the TQLayoutWidget's tqparent tqlayout changes (e.g., from a TQHBoxLayout
+ to a TQVBoxLayout), because of the (illogical) way tqlayouting works.
*/
-void QLayoutWidget::updateSizePolicy()
+void TQLayoutWidget::updateSizePolicy()
{
- if ( !children() || children()->count() == 0 ) {
- sp = TQWidget::sizePolicy();
+ TQObjectList clo = childrenListObject();
+ if ( clo.isEmpty() || clo.count() == 0 ) {
+ sp = TQWidget::tqsizePolicy();
return;
}
@@ -1816,23 +1817,23 @@ void QLayoutWidget::updateSizePolicy()
int ht = (int) TQSizePolicy::Preferred;
int vt = (int) TQSizePolicy::Preferred;
- if ( layout() ) {
+ if ( tqlayout() ) {
/*
- parentLayout is set to the parent layout if there is one and if it is
- top level, in which case layouting is illogical.
+ tqparentLayout is set to the tqparent tqlayout if there is one and if it is
+ top level, in which case tqlayouting is illogical.
*/
- TQLayout *parentLayout = 0;
- if ( parent() && parent()->isWidgetType() ) {
- parentLayout = ((TQWidget *)parent())->layout();
- if ( parentLayout && parentLayout->mainWidget()->inherits("QLayoutWidget") )
- parentLayout = 0;
+ TQLayout *tqparentLayout = 0;
+ if ( tqparent() && tqparent()->isWidgetType() ) {
+ tqparentLayout = ((TQWidget *)tqparent())->tqlayout();
+ if ( tqparentLayout && tqparentLayout->mainWidget()->inherits(TQLAYOUTWIDGET_OBJECT_NAME_STRING) )
+ tqparentLayout = 0;
}
- TQObjectListIt it( *children() );
+ TQObjectListIt it( childrenListObject() );
TQObject *o;
- if ( layout()->inherits(TQVBOXLAYOUT_OBJECT_NAME_STRING) ) {
- if ( parentLayout && parentLayout->inherits(TQHBOXLAYOUT_OBJECT_NAME_STRING) )
+ if ( tqlayout()->inherits(TQVBOXLAYOUT_OBJECT_NAME_STRING) ) {
+ if ( tqparentLayout && tqparentLayout->inherits(TQHBOXLAYOUT_OBJECT_NAME_STRING) )
vt = TQSizePolicy::Minimum;
else
vt = TQSizePolicy::Fixed;
@@ -1843,17 +1844,17 @@ void QLayoutWidget::updateSizePolicy()
continue;
TQWidget *w = (TQWidget*)o;
- if ( !w->sizePolicy().mayGrowHorizontally() )
+ if ( !w->tqsizePolicy().mayGrowHorizontally() )
ht &= ~TQSizePolicy::Minimum;
- if ( !w->sizePolicy().mayShrinkHorizontally() )
+ if ( !w->tqsizePolicy().mayShrinkHorizontally() )
ht &= ~TQSizePolicy::Maximum;
- if ( w->sizePolicy().mayGrowVertically() )
+ if ( w->tqsizePolicy().mayGrowVertically() )
vt |= TQSizePolicy::Minimum;
- if ( w->sizePolicy().mayShrinkVertically() )
+ if ( w->tqsizePolicy().mayShrinkVertically() )
vt |= TQSizePolicy::Maximum;
}
- } else if ( layout()->inherits(TQHBOXLAYOUT_OBJECT_NAME_STRING) ) {
- if ( parentLayout && parentLayout->inherits(TQVBOXLAYOUT_OBJECT_NAME_STRING) )
+ } else if ( tqlayout()->inherits(TQHBOXLAYOUT_OBJECT_NAME_STRING) ) {
+ if ( tqparentLayout && tqparentLayout->inherits(TQVBOXLAYOUT_OBJECT_NAME_STRING) )
ht = TQSizePolicy::Minimum;
else
ht = TQSizePolicy::Fixed;
@@ -1864,22 +1865,22 @@ void QLayoutWidget::updateSizePolicy()
continue;
TQWidget *w = (TQWidget*)o;
- if ( w->sizePolicy().mayGrowHorizontally() )
+ if ( w->tqsizePolicy().mayGrowHorizontally() )
ht |= TQSizePolicy::Minimum;
- if ( w->sizePolicy().mayShrinkHorizontally() )
+ if ( w->tqsizePolicy().mayShrinkHorizontally() )
ht |= TQSizePolicy::Maximum;
- if ( !w->sizePolicy().mayGrowVertically() )
+ if ( !w->tqsizePolicy().mayGrowVertically() )
vt &= ~TQSizePolicy::Minimum;
- if ( !w->sizePolicy().mayShrinkVertically() )
+ if ( !w->tqsizePolicy().mayShrinkVertically() )
vt &= ~TQSizePolicy::Maximum;
}
- } else if ( layout()->inherits(TQGRIDLAYOUT_OBJECT_NAME_STRING) ) {
+ } else if ( tqlayout()->inherits(TQGRIDLAYOUT_OBJECT_NAME_STRING) ) {
ht = TQSizePolicy::Fixed;
vt = TQSizePolicy::Fixed;
- if ( parentLayout ) {
- if ( parentLayout->inherits(TQVBOXLAYOUT_OBJECT_NAME_STRING) )
+ if ( tqparentLayout ) {
+ if ( tqparentLayout->inherits(TQVBOXLAYOUT_OBJECT_NAME_STRING) )
ht = TQSizePolicy::Minimum;
- else if ( parentLayout->inherits(TQHBOXLAYOUT_OBJECT_NAME_STRING) )
+ else if ( tqparentLayout->inherits(TQHBOXLAYOUT_OBJECT_NAME_STRING) )
vt = TQSizePolicy::Minimum;
}
@@ -1889,22 +1890,29 @@ void QLayoutWidget::updateSizePolicy()
continue;
TQWidget *w = (TQWidget*)o;
- if ( w->sizePolicy().mayGrowHorizontally() )
+ if ( w->tqsizePolicy().mayGrowHorizontally() )
ht |= TQSizePolicy::Minimum;
- if ( w->sizePolicy().mayShrinkHorizontally() )
+ if ( w->tqsizePolicy().mayShrinkHorizontally() )
ht |= TQSizePolicy::Maximum;
- if ( w->sizePolicy().mayGrowVertically() )
+ if ( w->tqsizePolicy().mayGrowVertically() )
vt |= TQSizePolicy::Minimum;
- if ( w->sizePolicy().mayShrinkVertically() )
+ if ( w->tqsizePolicy().mayShrinkVertically() )
vt |= TQSizePolicy::Maximum;
}
}
- if ( layout()->expanding() & TQSizePolicy::Horizontally )
+#ifdef USE_QT4
+ if ( tqlayout()->expandingDirections() & TQSizePolicy::Horizontally )
ht = TQSizePolicy::Expanding;
- if ( layout()->expanding() & TQSizePolicy::Vertically )
+ if ( tqlayout()->expandingDirections() & TQSizePolicy::Vertically )
vt = TQSizePolicy::Expanding;
+#else // USE_QT4
+ if ( tqlayout()->expanding() & TQSizePolicy::Horizontally )
+ ht = TQSizePolicy::Expanding;
+ if ( tqlayout()->expanding() & TQSizePolicy::Vertically )
+ vt = TQSizePolicy::Expanding;
+#endif // USE_QT4
- layout()->invalidate();
+ tqlayout()->tqinvalidate();
}
sp = TQSizePolicy( (TQSizePolicy::SizeType) ht, (TQSizePolicy::SizeType) vt );
@@ -1913,11 +1921,11 @@ void QLayoutWidget::updateSizePolicy()
void CustomWidget::paintEvent( TQPaintEvent *e )
{
- if ( parentWidget() && parentWidget()->inherits( "FormWindow" ) ) {
- ( (FormWindow*)parentWidget() )->paintGrid( this, e );
+ if ( tqparentWidget() && tqparentWidget()->inherits( "FormWindow" ) ) {
+ ( (FormWindow*)tqparentWidget() )->paintGrid( this, e );
} else {
TQPainter p( this );
- p.fillRect( rect(), colorGroup().dark() );
+ p.fillRect( rect(), tqcolorGroup().dark() );
p.drawPixmap( ( width() - cusw->pixmap->width() ) / 2,
( height() - cusw->pixmap->height() ) / 2,
*cusw->pixmap );
diff --git a/kommander/editor/widgetfactory.h b/kommander/editor/widgetfactory.h
index 74713544..bfde50ec 100644
--- a/kommander/editor/widgetfactory.h
+++ b/kommander/editor/widgetfactory.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -58,7 +58,7 @@ class TQWidget;
class TQLayout;
class FormWindow;
-class WidgetFactory : public Qt
+class WidgetFactory : public TQt
{
friend class CustomWidgetFactory;
@@ -70,15 +70,15 @@ public:
NoLayout
};
- static TQWidget *create( int id, TQWidget *parent, const char *name = 0, bool init = TRUE,
+ static TQWidget *create( int id, TQWidget *tqparent, const char *name = 0, bool init = TRUE,
const TQRect *rect = 0, Qt::Orientation orient = Qt::Horizontal );
- static TQLayout *createLayout( TQWidget *widget, TQLayout* layout, LayoutType type );
+ static TQLayout *createLayout( TQWidget *widget, TQLayout* tqlayout, LayoutType type );
static void deleteLayout( TQWidget *widget );
- static LayoutType layoutType( TQWidget *w );
- static LayoutType layoutType( TQWidget *w, TQLayout *&layout );
- static LayoutType layoutType( TQLayout *layout );
- static TQWidget *layoutParent( TQLayout *layout );
+ static LayoutType tqlayoutType( TQWidget *w );
+ static LayoutType tqlayoutType( TQWidget *w, TQLayout *&tqlayout );
+ static LayoutType tqlayoutType( TQLayout *tqlayout );
+ static TQWidget *tqlayoutParent( TQLayout *tqlayout );
static TQWidget* containerOfWidget( TQWidget *w );
static TQWidget* widgetOfContainer( TQWidget *w );
@@ -90,7 +90,7 @@ public:
static bool hasSpecialEditor( int id );
static bool hasItems( int id );
- static void editWidget( int id, TQWidget *parent, TQWidget *editWidget, FormWindow *fw );
+ static void editWidget( int id, TQWidget *tqparent, TQWidget *editWidget, FormWindow *fw );
static bool canResetProperty( TQObject *w, const TQString &propName );
static bool resetProperty( TQObject *w, const TQString &propName );
@@ -101,21 +101,22 @@ public:
static void saveDefaultProperties( TQWidget *w, int id );
private:
- static TQWidget *createWidget( const TQString &className, TQWidget *parent, const char *name, bool init,
+ static TQWidget *createWidget( const TQString &className, TQWidget *tqparent, const char *name, bool init,
const TQRect *r = 0, Qt::Orientation orient = Qt::Horizontal );
- static TQWidget *createCustomWidget( TQWidget *parent, const char *name, MetaDataBase::CustomWidget *w );
+ static TQWidget *createCustomWidget( TQWidget *tqparent, const char *name, MetaDataBase::CustomWidget *w );
};
-class QDesignerTabWidget : public QTabWidget
+class TQDesignerTabWidget : public TQTabWidget
{
Q_OBJECT
- Q_PROPERTY( int currentPage READ currentPage WRITE setCurrentPage STORED false DESIGNABLE true )
- Q_PROPERTY( TQString pageTitle READ pageTitle WRITE setPageTitle STORED false DESIGNABLE true )
- Q_PROPERTY( TQCString pageName READ pageName WRITE setPageName STORED false DESIGNABLE true )
+ TQ_OBJECT
+ TQ_PROPERTY( int currentPage READ currentPage WRITE setCurrentPage STORED false DESIGNABLE true )
+ TQ_PROPERTY( TQString pageTitle READ pageTitle WRITE setPageTitle STORED false DESIGNABLE true )
+ TQ_PROPERTY( TQCString pageName READ pageName WRITE setPageName STORED false DESIGNABLE true )
public:
- QDesignerTabWidget( TQWidget *parent, const char *name );
+ TQDesignerTabWidget( TQWidget *tqparent, const char *name );
int currentPage() const;
void setCurrentPage( int i );
@@ -140,11 +141,12 @@ private:
class EditorTabWidget : public TabWidget
{
Q_OBJECT
- Q_PROPERTY( int currentPage READ currentPage WRITE setCurrentPage STORED false DESIGNABLE true )
- Q_PROPERTY( TQString pageTitle READ pageTitle WRITE setPageTitle STORED false DESIGNABLE true )
- Q_PROPERTY( TQCString pageName READ pageName WRITE setPageName STORED false DESIGNABLE true )
+ TQ_OBJECT
+ TQ_PROPERTY( int currentPage READ currentPage WRITE setCurrentPage STORED false DESIGNABLE true )
+ TQ_PROPERTY( TQString pageTitle READ pageTitle WRITE setPageTitle STORED false DESIGNABLE true )
+ TQ_PROPERTY( TQCString pageName READ pageName WRITE setPageName STORED false DESIGNABLE true )
public:
- EditorTabWidget( TQWidget *parent, const char *name );
+ EditorTabWidget( TQWidget *tqparent, const char *name );
int currentPage() const;
void setCurrentPage( int i );
@@ -169,11 +171,12 @@ private:
class EditorToolBox : public ToolBox
{
Q_OBJECT
- Q_PROPERTY( int currentPage READ currentPage WRITE setCurrentPage STORED false DESIGNABLE true )
- Q_PROPERTY( TQString pageTitle READ pageTitle WRITE setPageTitle STORED false DESIGNABLE true )
- Q_PROPERTY( TQCString pageName READ pageName WRITE setPageName STORED false DESIGNABLE true )
+ TQ_OBJECT
+ TQ_PROPERTY( int currentPage READ currentPage WRITE setCurrentPage STORED false DESIGNABLE true )
+ TQ_PROPERTY( TQString pageTitle READ pageTitle WRITE setPageTitle STORED false DESIGNABLE true )
+ TQ_PROPERTY( TQCString pageName READ pageName WRITE setPageName STORED false DESIGNABLE true )
public:
- EditorToolBox( TQWidget *parent, const char *name );
+ EditorToolBox( TQWidget *tqparent, const char *name );
int currentPage() const;
void setCurrentPage( int i );
@@ -185,14 +188,15 @@ public:
int count() const;
};
-class QDesignerWizard : public QWizard
+class TQDesignerWizard : public TQWizard
{
Q_OBJECT
- Q_PROPERTY( int currentPage READ currentPageNum WRITE setCurrentPage STORED false DESIGNABLE true )
- Q_PROPERTY( TQString pageTitle READ pageTitle WRITE setPageTitle STORED false DESIGNABLE true )
- Q_PROPERTY( TQCString pageName READ pageName WRITE setPageName STORED false DESIGNABLE true )
+ TQ_OBJECT
+ TQ_PROPERTY( int currentPage READ currentPageNum WRITE setCurrentPage STORED false DESIGNABLE true )
+ TQ_PROPERTY( TQString pageTitle READ pageTitle WRITE setPageTitle STORED false DESIGNABLE true )
+ TQ_PROPERTY( TQCString pageName READ pageName WRITE setPageName STORED false DESIGNABLE true )
public:
- QDesignerWizard( TQWidget *parent, const char *name ) : TQWizard( parent, name ) {}
+ TQDesignerWizard( TQWidget *tqparent, const char *name ) : TQWizard( tqparent, name ) {}
int currentPageNum() const;
void setCurrentPage( int i );
@@ -204,7 +208,7 @@ public:
void addPage( TQWidget *p, const TQString & );
void removePage( TQWidget *p );
void insertPage( TQWidget *p, const TQString &t, int index );
- bool isPageRemoved( TQWidget *p ) { return (removedPages.find( p ) != 0); }
+ bool isPageRemoved( TQWidget *p ) { return (removedPages.tqfind( p ) != 0); }
void reject() {}
@@ -212,7 +216,7 @@ private:
struct Page
{
Page( TQWidget *a, const TQString &b ) : p( a ), t( b ) {}
- Page() : p( 0 ), t( TQString::null ) {}
+ Page() : p( 0 ), t( TQString() ) {}
TQWidget *p;
TQString t;
};
@@ -220,12 +224,13 @@ private:
};
-class QLayoutWidget : public QWidget
+class TQLayoutWidget : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- QLayoutWidget( TQWidget *parent, const char *name ) : TQWidget( parent, name ), sp( TQWidget::sizePolicy() ) {}
+ TQLayoutWidget( TQWidget *tqparent, const char *name ) : TQWidget( tqparent, name ), sp( TQWidget::tqsizePolicy() ) {}
TQSizePolicy sizePolicy() const;
void updateSizePolicy();
@@ -238,24 +243,25 @@ protected:
};
-class CustomWidget : public QWidget
+class CustomWidget : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- CustomWidget( TQWidget *parent, const char *name, MetaDataBase::CustomWidget *cw )
- : TQWidget( parent, name ), cusw( cw ) {
- alwaysExpand = parentWidget() && parentWidget()->inherits( "FormWindow" );
- setSizePolicy( cw->sizePolicy );
+ CustomWidget( TQWidget *tqparent, const char *name, MetaDataBase::CustomWidget *cw )
+ : TQWidget( tqparent, name ), cusw( cw ) {
+ alwaysExpand = tqparentWidget() && tqparentWidget()->inherits( "FormWindow" );
+ tqsetSizePolicy( cw->sizePolicy );
if ( !alwaysExpand )
setBackgroundMode( PaletteDark );
}
- TQSize sizeHint() const {
- TQSize sh = cusw->sizeHint;
+ TQSize tqsizeHint() const {
+ TQSize sh = cusw->tqsizeHint;
if ( sh.isValid() )
return sh;
- return TQWidget::sizeHint();
+ return TQWidget::tqsizeHint();
}
TQString realClassName() { return cusw->className; }
@@ -270,41 +276,43 @@ protected:
};
-class Line : public QFrame
+class Line : public TQFrame
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY( Orientation orientation READ orientation WRITE setOrientation )
- Q_OVERRIDE( int frameWidth DESIGNABLE false )
- Q_OVERRIDE( Shape frameShape DESIGNABLE false )
- Q_OVERRIDE( TQRect frameRect DESIGNABLE false )
- Q_OVERRIDE( TQRect contentsRect DESIGNABLE false )
+ TQ_PROPERTY( Qt::Orientation orientation READ orientation WRITE setOrientation )
+ TQ_OVERRIDE( int frameWidth DESIGNABLE false )
+ TQ_OVERRIDE( Shape frameShape DESIGNABLE false )
+ TQ_OVERRIDE( TQRect frameRect DESIGNABLE false )
+ TQ_OVERRIDE( TQRect contentsRect DESIGNABLE false )
public:
- Line( TQWidget *parent, const char *name )
- : TQFrame( parent, name, WMouseNoMask ) {
+ Line( TQWidget *tqparent, const char *name )
+ : TQFrame( tqparent, name, WMouseNoMask ) {
setFrameStyle( HLine | Sunken );
}
- void setOrientation( Orientation orient ) {
- if ( orient == Horizontal )
+ void setOrientation( Qt::Orientation orient ) {
+ if ( orient ==Qt::Horizontal )
setFrameShape( HLine );
else
setFrameShape( VLine );
}
- Orientation orientation() const {
- return frameShape() == HLine ? Horizontal : Vertical;
+ Qt::Orientation orientation() const {
+ return frameShape() == HLine ?Qt::Horizontal :Qt::Vertical;
}
};
-class QDesignerLabel : public QLabel
+class TQDesignerLabel : public TQLabel
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY( TQCString buddy READ buddyWidget WRITE setBuddyWidget )
+ TQ_PROPERTY( TQCString buddy READ buddyWidget WRITE setBuddyWidget )
public:
- QDesignerLabel( TQWidget *parent = 0, const char *name = 0 )
- : TQLabel( parent, name ) { myBuddy = 0; }
+ TQDesignerLabel( TQWidget *tqparent = 0, const char *name = 0 )
+ : TQLabel( tqparent, name ) { myBuddy = 0; }
void setBuddyWidget( const TQCString &b ) {
myBuddy = b;
@@ -328,13 +336,14 @@ private:
};
-class QDesignerWidget : public QWidget
+class TQDesignerWidget : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- QDesignerWidget( FormWindow *fw, TQWidget *parent, const char *name )
- : TQWidget( parent, name, WResizeNoErase ), formwindow( fw ) {}
+ TQDesignerWidget( FormWindow *fw, TQWidget *tqparent, const char *name )
+ : TQWidget( tqparent, name, WResizeNoErase ), formwindow( fw ) {}
protected:
void paintEvent( TQPaintEvent *e );
@@ -344,13 +353,14 @@ private:
};
-class QDesignerDialog : public QDialog
+class TQDesignerDialog : public TQDialog
{
Q_OBJECT
+ TQ_OBJECT
public:
- QDesignerDialog( FormWindow *fw, TQWidget *parent, const char *name )
- : TQDialog( parent, name, FALSE, WResizeNoErase ), formwindow( fw ) {}
+ TQDesignerDialog( FormWindow *fw, TQWidget *tqparent, const char *name )
+ : TQDialog( tqparent, name, FALSE, WResizeNoErase ), formwindow( fw ) {}
protected:
void paintEvent( TQPaintEvent *e );
@@ -360,96 +370,100 @@ private:
};
-class QDesignerToolButton : public QToolButton
+class TQDesignerToolButton : public TQToolButton
{
Q_OBJECT
- Q_PROPERTY( int buttonGroupId READ buttonGroupId WRITE setButtonGroupId )
+ TQ_OBJECT
+ TQ_PROPERTY( int buttonGroupId READ buttonGroupId WRITE setButtonGroupId )
public:
- QDesignerToolButton( TQWidget *parent, const char *name )
- : TQToolButton( parent, name ) {}
+ TQDesignerToolButton( TQWidget *tqparent, const char *name )
+ : TQToolButton( tqparent, name ) {}
bool isInButtonGroup() const {
- return parentWidget() && parentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING );
+ return tqparentWidget() && tqparentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING );
}
int buttonGroupId() const {
- return parentWidget() && parentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) ? ( (TQButtonGroup*)parentWidget() )->id( (TQButton*)this ) : -1;
+ return tqparentWidget() && tqparentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) ? ( (TQButtonGroup*)tqparentWidget() )->id( (TQButton*)this ) : -1;
}
void setButtonGroupId( int id ) {
- if ( parentWidget() && parentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) ) {
- ( (TQButtonGroup*)parentWidget() )->remove( this );
- ( (TQButtonGroup*)parentWidget() )->insert( this, id );
+ if ( tqparentWidget() && tqparentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) ) {
+ ( (TQButtonGroup*)tqparentWidget() )->remove( this );
+ ( (TQButtonGroup*)tqparentWidget() )->insert( this, id );
}
}
};
-class QDesignerRadioButton : public QRadioButton
+class TQDesignerRadioButton : public TQRadioButton
{
Q_OBJECT
- Q_PROPERTY( int buttonGroupId READ buttonGroupId WRITE setButtonGroupId )
+ TQ_OBJECT
+ TQ_PROPERTY( int buttonGroupId READ buttonGroupId WRITE setButtonGroupId )
public:
- QDesignerRadioButton( TQWidget *parent, const char *name )
- : TQRadioButton( parent, name ) {}
+ TQDesignerRadioButton( TQWidget *tqparent, const char *name )
+ : TQRadioButton( tqparent, name ) {}
bool isInButtonGroup() const {
- return parentWidget() && parentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING );
+ return tqparentWidget() && tqparentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING );
}
int buttonGroupId() const {
- return parentWidget() && parentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) ? ( (TQButtonGroup*)parentWidget() )->id( (TQButton*)this ) : -1;
+ return tqparentWidget() && tqparentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) ? ( (TQButtonGroup*)tqparentWidget() )->id( (TQButton*)this ) : -1;
}
void setButtonGroupId( int id ) {
- if ( parentWidget() && parentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) ) {
- ( (TQButtonGroup*)parentWidget() )->remove( this );
- ( (TQButtonGroup*)parentWidget() )->insert( this, id );
+ if ( tqparentWidget() && tqparentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) ) {
+ ( (TQButtonGroup*)tqparentWidget() )->remove( this );
+ ( (TQButtonGroup*)tqparentWidget() )->insert( this, id );
}
}
};
-class QDesignerPushButton : public QPushButton
+class TQDesignerPushButton : public TQPushButton
{
Q_OBJECT
- Q_PROPERTY( int buttonGroupId READ buttonGroupId WRITE setButtonGroupId )
+ TQ_OBJECT
+ TQ_PROPERTY( int buttonGroupId READ buttonGroupId WRITE setButtonGroupId )
public:
- QDesignerPushButton( TQWidget *parent, const char *name )
- : TQPushButton( parent, name ) {}
+ TQDesignerPushButton( TQWidget *tqparent, const char *name )
+ : TQPushButton( tqparent, name ) {}
bool isInButtonGroup() const {
- return parentWidget() && parentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING );
+ return tqparentWidget() && tqparentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING );
}
int buttonGroupId() const {
- return parentWidget() && parentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) ? ( (TQButtonGroup*)parentWidget() )->id( (TQButton*)this ) : -1;
+ return tqparentWidget() && tqparentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) ? ( (TQButtonGroup*)tqparentWidget() )->id( (TQButton*)this ) : -1;
}
void setButtonGroupId( int id ) {
- if ( parentWidget() && parentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) ) {
- ( (TQButtonGroup*)parentWidget() )->remove( this );
- ( (TQButtonGroup*)parentWidget() )->insert( this, id );
+ if ( tqparentWidget() && tqparentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) ) {
+ ( (TQButtonGroup*)tqparentWidget() )->remove( this );
+ ( (TQButtonGroup*)tqparentWidget() )->insert( this, id );
}
}
};
-class QDesignerCheckBox : public QCheckBox
+class TQDesignerCheckBox : public TQCheckBox
{
Q_OBJECT
- Q_PROPERTY( int buttonGroupId READ buttonGroupId WRITE setButtonGroupId )
+ TQ_OBJECT
+ TQ_PROPERTY( int buttonGroupId READ buttonGroupId WRITE setButtonGroupId )
public:
- QDesignerCheckBox( TQWidget *parent, const char *name )
- : TQCheckBox( parent, name ) {}
+ TQDesignerCheckBox( TQWidget *tqparent, const char *name )
+ : TQCheckBox( tqparent, name ) {}
bool isInButtonGroup() const {
- return parentWidget() && parentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING );
+ return tqparentWidget() && tqparentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING );
}
int buttonGroupId() const {
- return parentWidget() && parentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) ? ( (TQButtonGroup*)parentWidget() )->id( (TQButton*)this ) : -1;
+ return tqparentWidget() && tqparentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) ? ( (TQButtonGroup*)tqparentWidget() )->id( (TQButton*)this ) : -1;
}
void setButtonGroupId( int id ) {
- if ( parentWidget() && parentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) ) {
- ( (TQButtonGroup*)parentWidget() )->remove( this );
- ( (TQButtonGroup*)parentWidget() )->insert( this, id );
+ if ( tqparentWidget() && tqparentWidget()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) ) {
+ ( (TQButtonGroup*)tqparentWidget() )->remove( this );
+ ( (TQButtonGroup*)tqparentWidget() )->insert( this, id );
}
}
@@ -458,10 +472,11 @@ public:
class EditorDialog : public Dialog
{
Q_OBJECT
+ TQ_OBJECT
public:
- EditorDialog( FormWindow *fw, TQWidget *parent, const char *name )
- : Dialog( parent, name, FALSE, WResizeNoErase ), formwindow( fw ) { }
+ EditorDialog( FormWindow *fw, TQWidget *tqparent, const char *name )
+ : Dialog( tqparent, name, FALSE, WResizeNoErase ), formwindow( fw ) { }
protected:
void paintEvent( TQPaintEvent *e );
diff --git a/kommander/editor/widgetinterface.h b/kommander/editor/widgetinterface.h
index bf6bcd55..364e9871 100644
--- a/kommander/editor/widgetinterface.h
+++ b/kommander/editor/widgetinterface.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000-2001 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -21,9 +21,9 @@
#ifndef WIDGETINTERFACE_H
#define WIDGETINTERFACE_H
-#include <private/qwidgetinterface_p.h>
+#include <private/tqwidgetinterface_p.h>
-#define WidgetInterface QWidgetFactoryInterface
-#define IID_Widget IID_QWidgetFactory
+#define WidgetInterface TQWidgetFactoryInterface
+#define IID_Widget IID_TQWidgetFactory
#endif
diff --git a/kommander/editor/wizardeditor.ui b/kommander/editor/wizardeditor.ui
index c73e2628..f575a13a 100644
--- a/kommander/editor/wizardeditor.ui
+++ b/kommander/editor/wizardeditor.ui
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.0" stdsetdef="1">
<class>WizardEditorBase</class>
-<widget class="QDialog">
+<widget class="TQDialog">
<property name="name">
<cstring>WizardEditorBase</cstring>
</property>
@@ -25,7 +25,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout19</cstring>
</property>
@@ -39,7 +39,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout14</cstring>
</property>
@@ -53,7 +53,7 @@
<property name="spacing">
<number>2</number>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>pagesLabel</cstring>
</property>
@@ -61,14 +61,14 @@
<string>Wizard pages:</string>
</property>
</widget>
- <widget class="QListBox">
+ <widget class="TQListBox">
<property name="name">
<cstring>listBox</cstring>
</property>
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout18</cstring>
</property>
@@ -82,7 +82,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonAdd</cstring>
</property>
@@ -90,7 +90,7 @@
<string>&amp;Add</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonRemove</cstring>
</property>
@@ -108,14 +108,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonUp</cstring>
</property>
@@ -126,7 +126,7 @@
<pixmap>image0</pixmap>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonDown</cstring>
</property>
@@ -141,7 +141,7 @@
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -155,7 +155,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonHelp</cstring>
</property>
@@ -176,14 +176,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
</size>
</property>
</spacer>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonOk</cstring>
</property>
@@ -200,7 +200,7 @@
<string>Close the dialog and apply all the changes.</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonApply</cstring>
</property>
@@ -214,7 +214,7 @@
<string>Apply all changes.</string>
</property>
</widget>
- <widget class="QPushButton">
+ <widget class="TQPushButton">
<property name="name">
<cstring>buttonCancel</cstring>
</property>
@@ -302,7 +302,7 @@
<slot>cancelClicked()</slot>
</connection>
</connections>
-<slots>
+<Q_SLOTS>
<slot access="protected">init()</slot>
<slot access="protected">destroy()</slot>
<slot access="protected">addClicked()</slot>
@@ -315,6 +315,6 @@
<slot access="protected">okClicked()</slot>
<slot access="protected">removeClicked()</slot>
<slot access="protected">upClicked()</slot>
-</slots>
-<layoutdefaults spacing="6" margin="11"/>
+</Q_SLOTS>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/editor/wizardeditorimpl.cpp b/kommander/editor/wizardeditorimpl.cpp
index dfed9a2f..602f8376 100644
--- a/kommander/editor/wizardeditorimpl.cpp
+++ b/kommander/editor/wizardeditorimpl.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -31,8 +31,8 @@
#include <klocale.h>
-WizardEditor::WizardEditor( TQWidget *parent, TQWizard *w, FormWindow *fw )
- : WizardEditorBase( parent, 0 ), formwindow( fw ), wizard( w )
+WizardEditor::WizardEditor( TQWidget *tqparent, TQWizard *w, FormWindow *fw )
+ : WizardEditorBase( tqparent, 0 ), formwindow( fw ), wizard( w )
{
connect( buttonHelp, TQT_SIGNAL( clicked() ), MainWindow::self, TQT_SLOT( showDialogHelp() ) );
fillListBox();
@@ -109,7 +109,7 @@ void WizardEditor::addClicked()
listBox->insertItem( i18n( "Page" ), index );
// schedule add command
- AddWizardPageCommand *cmd = new AddWizardPageCommand( i18n("Add Page to %1" ).arg( wizard->name() ),
+ AddWizardPageCommand *cmd = new AddWizardPageCommand( i18n("Add Page to %1" ).tqarg( wizard->name() ),
formwindow, wizard, "Page", index, false);
commands.append( cmd );
@@ -128,7 +128,7 @@ void WizardEditor::removeClicked()
// schedule remove command
DeleteWizardPageCommand *cmd = new DeleteWizardPageCommand( i18n("Delete Page %1 of %2" )
- .arg( listBox->text( index ) ).arg( wizard->name() ),
+ .tqarg( listBox->text( index ) ).tqarg( wizard->name() ),
formwindow, wizard, index, false );
commands.append( cmd );
@@ -148,8 +148,8 @@ void WizardEditor::upClicked()
listBox->setCurrentItem( index2 );
// schedule swap command
- SwapWizardPagesCommand *cmd = new SwapWizardPagesCommand( i18n("Swap Pages %1 and %2 of %3" ).arg( index1 ).arg( index2 )
- .arg( wizard->name() ), formwindow, wizard, index1, index2);
+ SwapWizardPagesCommand *cmd = new SwapWizardPagesCommand( i18n("Swap Pages %1 and %2 of %3" ).tqarg( index1 ).tqarg( index2 )
+ .tqarg( wizard->name() ), formwindow, wizard, index1, index2);
commands.append( cmd );
// update buttons
@@ -168,8 +168,8 @@ void WizardEditor::downClicked()
listBox->setCurrentItem( index2 );
// schedule swap command
- SwapWizardPagesCommand *cmd = new SwapWizardPagesCommand( i18n("Swap Pages %1 and %2 of %3" ).arg( index1 ).arg( index2 )
- .arg( wizard->name() ), formwindow, wizard, index2, index1);
+ SwapWizardPagesCommand *cmd = new SwapWizardPagesCommand( i18n("Swap Pages %1 and %2 of %3" ).tqarg( index1 ).tqarg( index2 )
+ .tqarg( wizard->name() ), formwindow, wizard, index2, index1);
commands.append( cmd );
// update buttons
@@ -199,7 +199,7 @@ void WizardEditor::itemSelected( int index )
bool ok = false;
TQString text = KInputDialog::getText( i18n("Page Title"), i18n("New page title:" ), listBox->text( index ), &ok, this );
if ( ok ) {
- TQString pn( i18n("Rename page %1 of %2" ).arg( listBox->text( index ) ).arg( wizard->name() ) );
+ TQString pn( i18n("Rename page %1 of %2" ).tqarg( listBox->text( index ) ).tqarg( wizard->name() ) );
RenameWizardPageCommand *cmd = new RenameWizardPageCommand( pn, formwindow, wizard, index, text );
commands.append( cmd );
listBox->changeItem( text, index );
diff --git a/kommander/editor/wizardeditorimpl.h b/kommander/editor/wizardeditorimpl.h
index 128aa467..bc5f68bf 100644
--- a/kommander/editor/wizardeditorimpl.h
+++ b/kommander/editor/wizardeditorimpl.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -32,9 +32,10 @@ class FormWindow;
class WizardEditor : public WizardEditorBase
{
Q_OBJECT
+ TQ_OBJECT
public:
- WizardEditor( TQWidget *parent, TQWizard *wizard, FormWindow *fw );
+ WizardEditor( TQWidget *tqparent, TQWizard *wizard, FormWindow *fw );
~WizardEditor();
protected slots:
diff --git a/kommander/editor/workspace.cpp b/kommander/editor/workspace.cpp
index 90f0891d..ecccce3d 100644
--- a/kommander/editor/workspace.cpp
+++ b/kommander/editor/workspace.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000-2001 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -102,11 +102,11 @@ static TQPixmap *filePixmap = 0;
static TQPixmap* formPixmap = 0;
#ifndef KOMMANDER
-WorkspaceItem::WorkspaceItem( TQListView *parent, Project* p )
+WorkspaceItem::WorkspaceItem( TQListView *tqparent, Project* p )
#else
-WorkspaceItem::WorkspaceItem( TQListView *parent )
+WorkspaceItem::WorkspaceItem( TQListView *tqparent )
#endif
- : TQListViewItem( parent )
+ : TQListViewItem( tqparent )
{
init();
#ifndef KOMMANDER
@@ -118,8 +118,8 @@ WorkspaceItem::WorkspaceItem( TQListView *parent )
}
#ifndef KOMMANDER
-WorkspaceItem::WorkspaceItem( TQListViewItem *parent, SourceFile* sf )
- : TQListViewItem( parent )
+WorkspaceItem::WorkspaceItem( TQListViewItem *tqparent, SourceFile* sf )
+ : TQListViewItem( tqparent )
{
init();
sourceFile = sf;
@@ -128,8 +128,8 @@ WorkspaceItem::WorkspaceItem( TQListViewItem *parent, SourceFile* sf )
}
#endif
-WorkspaceItem::WorkspaceItem( TQListViewItem *parent, FormFile* ff, Type type )
- : TQListViewItem( parent )
+WorkspaceItem::WorkspaceItem( TQListViewItem *tqparent, FormFile* ff, Type type )
+ : TQListViewItem( tqparent )
{
init();
formFile = ff;
@@ -146,8 +146,8 @@ WorkspaceItem::WorkspaceItem( TQListViewItem *parent, FormFile* ff, Type type )
}
}
-WorkspaceItem::WorkspaceItem( TQListView *parent, FormFile* ff, Type type )
- : TQListViewItem( parent )
+WorkspaceItem::WorkspaceItem( TQListView *tqparent, FormFile* ff, Type type )
+ : TQListViewItem( tqparent )
{
init();
formFile = ff;
@@ -180,7 +180,7 @@ void WorkspaceItem::paintCell( TQPainter *p, const TQColorGroup &cg, int column,
{
TQColorGroup g( cg );
g.setColor( TQColorGroup::Base, backgroundColor() );
- g.setColor( TQColorGroup::Foreground, Qt::black );
+ g.setColor( TQColorGroup::Foreground, TQt::black );
#ifndef KOMMANDER
if ( type() == FormSourceType && !formFile->hasFormCode() ) {
@@ -188,7 +188,7 @@ void WorkspaceItem::paintCell( TQPainter *p, const TQColorGroup &cg, int column,
g.setColor( TQColorGroup::HighlightedText, listView()->palette().disabled().color( TQColorGroup::Text) );
} else {
#endif
- g.setColor( TQColorGroup::Text, Qt::black );
+ g.setColor( TQColorGroup::Text, TQt::black );
#ifndef KOMMANDER
}
#endif
@@ -236,7 +236,7 @@ TQString WorkspaceItem::text( int column ) const
#endif
}
- return TQString::null; // shut up compiler
+ return TQString(); // shut up compiler
}
void WorkspaceItem::fillCompletionList( TQStringList& completion )
@@ -310,8 +310,8 @@ TQString WorkspaceItem::key( int column, bool ) const
TQColor WorkspaceItem::backgroundColor()
{
bool b = useOddColor;
- if ( t == FormSourceType && parent() )
- b = ( ( WorkspaceItem*)parent() )->useOddColor;
+ if ( t == FormSourceType && tqparent() )
+ b = ( ( WorkspaceItem*)tqparent() )->useOddColor;
return b ? *backColor2 : *backColor1;
}
@@ -328,8 +328,8 @@ void WorkspaceItem::setAutoOpen( bool b )
autoOpen = b;
}
-Workspace::Workspace( TQWidget *parent, MainWindow *mw )
- : TQListView( parent, 0, WStyle_Customize | WStyle_NormalBorder | WStyle_Title |
+Workspace::Workspace( TQWidget *tqparent, MainWindow *mw )
+ : TQListView( tqparent, 0, WStyle_Customize | WStyle_NormalBorder | WStyle_Title |
WStyle_Tool | WStyle_MinMax | WStyle_SysMenu ), mainWindow( mw ),
#ifndef KOMMANDER
project( 0 ), completionDirty( false )
@@ -485,9 +485,9 @@ void Workspace::update( FormFile* ff )
{
TQListViewItem* i = findItem( ff );
if ( i ) {
- i->repaint();
+ i->tqrepaint();
if ( (i = i->firstChild()) )
- i->repaint();
+ i->tqrepaint();
}
}
@@ -559,7 +559,7 @@ void Workspace::closeAutoOpenItems()
TQListViewItemIterator it( this );
for ( ; it.current(); ++it ) {
WorkspaceItem* i = (WorkspaceItem*) it.current();
- WorkspaceItem* ip = (WorkspaceItem*) i->parent();
+ WorkspaceItem* ip = (WorkspaceItem*) i->tqparent();
if ( i->type() == WorkspaceItem::FormSourceType ) {
if ( !i->isSelected() && !ip->isSelected()
&& ip->isAutoOpen() ) {
@@ -583,7 +583,7 @@ void Workspace::itemDoubleClicked( TQListViewItem *i )
void Workspace::itemClicked( int button, TQListViewItem *i, const TQPoint& )
{
- if ( !i || button != LeftButton )
+ if ( !i || button != Qt::LeftButton )
return;
closeAutoOpenItems();
@@ -699,7 +699,7 @@ void Workspace::rmbClicked( TQListViewItem *i, const TQPoint& pos )
break;
#endif
case OPEN_SOURCE:
- itemClicked( LeftButton, i, pos );
+ itemClicked( Qt::LeftButton, i, pos );
break;
#ifndef KOMMANDER
case REMOVE_FORM: // FIXME
@@ -707,10 +707,10 @@ void Workspace::rmbClicked( TQListViewItem *i, const TQPoint& pos )
break;
#endif
case OPEN_FORM:
- itemClicked( LeftButton, i, pos );
+ itemClicked( Qt::LeftButton, i, pos );
break;
case OPEN_FORM_SOURCE:
- itemClicked( LeftButton, i, pos );
+ itemClicked( Qt::LeftButton, i, pos );
break;
default:
break;
@@ -720,7 +720,7 @@ void Workspace::rmbClicked( TQListViewItem *i, const TQPoint& pos )
bool Workspace::eventFilter( TQObject *o, TQEvent * e )
{
// Reggie, on what type of events do we have to execute updateBufferEdit()
- if ( o ==bufferEdit && e->type() != TQEvent::ChildRemoved )
+ if ( TQT_BASE_OBJECT(o) == TQT_BASE_OBJECT(bufferEdit) && e->type() != TQEvent::ChildRemoved )
updateBufferEdit();
return TQListView::eventFilter( o, e );
}
@@ -755,7 +755,7 @@ void Workspace::bufferChosen( const TQString &buffer )
bufferEdit->setText( "" );
#ifndef KOMMANDER
- if ( MainWindow::self->projectFileNames().contains( buffer ) ) {
+ if ( MainWindow::self->projectFileNames().tqcontains( buffer ) ) {
MainWindow::self->setCurrentProjectByFilename( buffer );
return;
}
@@ -764,7 +764,7 @@ void Workspace::bufferChosen( const TQString &buffer )
TQListViewItemIterator it( this );
while ( it.current() ) {
if ( ( (WorkspaceItem*)it.current())->checkCompletion( buffer ) ) {
- itemClicked( LeftButton, it.current(), TQPoint() );
+ itemClicked( Qt::LeftButton, it.current(), TQPoint() );
break;
}
++it;
diff --git a/kommander/editor/workspace.h b/kommander/editor/workspace.h
index 61f772dd..99470207 100644
--- a/kommander/editor/workspace.h
+++ b/kommander/editor/workspace.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -40,21 +40,21 @@ class QCompletionEdit;
class SourceEditor;
#endif
-class WorkspaceItem : public QListViewItem
+class WorkspaceItem : public TQListViewItem
{
public:
enum Type { ProjectType, FormFileType, FormSourceType, SourceFileType };
#ifndef KOMMANDER
- //WorkspaceItem( TQListView *parent, Project* p );
+ //WorkspaceItem( TQListView *tqparent, Project* p );
#else
- WorkspaceItem(TQListView *parent);
+ WorkspaceItem(TQListView *tqparent);
#endif
#ifndef KOMMANDER
-// WorkspaceItem( TQListViewItem *parent, SourceFile* sf );
+// WorkspaceItem( TQListViewItem *tqparent, SourceFile* sf );
#endif
- WorkspaceItem( TQListViewItem *parent, FormFile* ff, Type t = FormFileType );
- WorkspaceItem( TQListView *parent, FormFile* ff, Type t = FormFileType );
+ WorkspaceItem( TQListViewItem *tqparent, FormFile* ff, Type t = FormFileType );
+ WorkspaceItem( TQListView *tqparent, FormFile* ff, Type t = FormFileType );
void paintCell( TQPainter *p, const TQColorGroup &cg, int column, int width, int align );
@@ -91,12 +91,13 @@ private:
Type t;
};
-class Workspace : public QListView
+class Workspace : public TQListView
{
Q_OBJECT
+ TQ_OBJECT
public:
- Workspace( TQWidget *parent , MainWindow *mw );
+ Workspace( TQWidget *tqparent , MainWindow *mw );
#ifndef KOMMANDER
void setCurrentProject( Project *pro );
diff --git a/kommander/examples/current/a1.kmdr b/kommander/examples/current/a1.kmdr
index e8b99ac3..7399bc73 100755
--- a/kommander/examples/current/a1.kmdr
+++ b/kommander/examples/current/a1.kmdr
@@ -49,7 +49,7 @@ debug("pid="+pid)</string>
<cstring>StatusBar8</cstring>
</property>
</widget>
- <widget class="QLayoutWidget" row="3" column="0" rowspan="1" colspan="2">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="3" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>Layout37</cstring>
</property>
@@ -121,7 +121,7 @@ debug("pid="+pid)</string>
<string>and again</string>
</property>
</widget>
- <widget class="QLayoutWidget" row="4" column="0" rowspan="1" colspan="2">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="4" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>Layout83</cstring>
</property>
@@ -145,7 +145,7 @@ debug("pid="+pid)</string>
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>40</width>
<height>0</height>
@@ -176,7 +176,7 @@ StatusBar8.setText("Returned: "+b)</string>
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>46</width>
<height>0</height>
@@ -185,7 +185,7 @@ StatusBar8.setText("Returned: "+b)</string>
</spacer>
</hbox>
</widget>
- <widget class="QLayoutWidget" row="2" column="0" rowspan="1" colspan="2">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="2" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>Layout84</cstring>
</property>
@@ -209,7 +209,7 @@ StatusBar8.setText("Returned: "+b)</string>
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>80</width>
<height>0</height>
@@ -243,7 +243,7 @@ StatusBar8.setText("Returned: "+b)</string>
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>60</width>
<height>0</height>
@@ -254,5 +254,5 @@ StatusBar8.setText("Returned: "+b)</string>
</widget>
</grid>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/current/b1.kmdr b/kommander/examples/current/b1.kmdr
index 09725243..bc02ab80 100755
--- a/kommander/examples/current/b1.kmdr
+++ b/kommander/examples/current/b1.kmdr
@@ -26,7 +26,7 @@ else
StatusBar9.insertItem("ARG1="+_ARG1, 1)
StatusBar9.insertItem("ARG2="+_ARG2, 2)
endif
-//message_info(parentPid)</string>
+//message_info(tqparentPid)</string>
<string></string>
</stringlist>
</property>
@@ -82,7 +82,7 @@ endif
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>111</width>
<height>0</height>
@@ -104,7 +104,7 @@ endif
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>50</width>
<height>0</height>
@@ -120,8 +120,8 @@ endif
</property>
<property name="associations" stdset="0">
<stringlist>
- <string>//message_info("parentPid = "+parentPid+"\npid = "+pid)
-dcop("kmdr-executor-"+parentPid, "KommanderIf", "setText(QString,QString)", "StatusBar8", "Hello")
+ <string>//message_info("tqparentPid = "+tqparentPid+"\npid = "+pid)
+dcop("kmdr-executor-"+tqparentPid, "KommanderIf", "setText(QString,QString)", "StatusBar8", "Hello")
</string>
</stringlist>
</property>
@@ -131,5 +131,5 @@ dcop("kmdr-executor-"+parentPid, "KommanderIf", "setText(QString,QString)", "Sta
</widget>
</grid>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/current/editor-poc.kmdr b/kommander/examples/current/editor-poc.kmdr
index d9b14fd1..6a084397 100755
--- a/kommander/examples/current/editor-poc.kmdr
+++ b/kommander/examples/current/editor-poc.kmdr
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.0" stdsetdef="1">
<class>KEdemo</class>
-<widget class="QMainWindow">
+<widget class=TQMAINWINDOW_OBJECT_NAME_STRING>
<property name="name">
<cstring>KEdemo</cstring>
</property>
@@ -73,7 +73,7 @@ _file["dirty"] = true</string>
</property>
<property name="associations" stdset="0">
<stringlist>
- <string>@Input.text("Kommander Edit", "Text to find", "")</string>
+ <string>@Input.text("Kommander Edit", "Text to tqfind", "")</string>
</stringlist>
</property>
</widget>
@@ -179,16 +179,16 @@ while chrs &lt; maxc do
//debug("link test = "+str_mid(a, ch, 2)+" pos="+ch)
if str_mid(a, ch, 2) == "&lt;a" then
inlink = true
- lb = str_toint(str_find(a, "\"", ch)+1)
- le = str_toint(str_find(a, "\"", lb))
+ lb = str_toint(str_tqfind(a, "\"", ch)+1)
+ le = str_toint(str_tqfind(a, "\"", lb))
linkscript = str_mid(a, lb, le-lb)
//debug("link data - "+lb+" "+le+" "+linkscript)
elseif str_mid(a, ch, 3) == "&lt;p&gt;" then
lc = lc + 1
cc = 0
endif
- ck1 = str_toint(str_find(a, "&gt;", ch))+1
- ck2 = str_find(a, "&lt;", ck1)
+ ck1 = str_toint(str_tqfind(a, "&gt;", ch))+1
+ ck2 = str_tqfind(a, "&lt;", ck1)
if ck1 == -1 || ck2 == -1 then
break
endif
@@ -303,9 +303,9 @@ debug("Clicked at: "+Self.Item(0)+" "+Self.Item(1))
&lt;stringlist&gt;
&lt;string&gt;&lt;/string&gt;
&lt;string&gt;@Array.setValue(help, "Proof of concept", "&amp;lt;center&amp;gt;&amp;lt;h2&amp;gt;Kommander MainWindow frames!&amp;lt;/h2&amp;gt;&amp;lt;/center&amp;gt;&amp;lt;p&amp;gt;As Kommander took on functionality an attempt was made to make a MainWindow Kommander widget. Sadly it was a huge time loss for two developers who both gave up after days of trying. The problem was with the editor. However you can use a Qt Designer generated UI file renamed to a *.kmdr file. Into this frame you can place your widgets and make a working application where nearly everything works.&amp;lt;/p&amp;gt;")
-@Array.setValue(help, "Known limitations", "&amp;lt;center&amp;gt;&amp;lt;h2&amp;gt;Known limitations&amp;lt;/h2&amp;gt;&amp;lt;/center&amp;gt;&amp;lt;p&amp;gt;As of this writing what is known not to work on the Kommander side is the settings read and write. There is no Initialize or Destroy section as there is no Kommander Text, however there are signals for this on the window, so the functionality is intact. On the MainWindow side it is not possible to talk to any Actions as these are QActions from Designer and KActions are not derived from QActions in KDE 3x. This means a DCOP call to list actions or set states will not work. It is also not possible to talk to the Statusbar. Also submenus on the menubar and dropdown actions on the Toolbar will not work. Given that this is an unsupported use of Kommander it everything that does work makes it suitable for probably most small application uses.. &amp;lt;/p&amp;gt;")
+@Array.setValue(help, "Known limitations", "&amp;lt;center&amp;gt;&amp;lt;h2&amp;gt;Known limitations&amp;lt;/h2&amp;gt;&amp;lt;/center&amp;gt;&amp;lt;p&amp;gt;As of this writing what is known not to work on the Kommander side is the settings read and write. There is no Initialize or Destroy section as there is no Kommander Text, however there are Q_SIGNALS for this on the window, so the functionality is intact. On the MainWindow side it is not possible to talk to any Actions as these are QActions from Designer and KActions are not derived from QActions in KDE 3x. This means a DCOP call to list actions or set states will not work. It is also not possible to talk to the Statusbar. Also submenus on the menubar and dropdown actions on the Toolbar will not work. Given that this is an unsupported use of Kommander it everything that does work makes it suitable for probably most small application uses.. &amp;lt;/p&amp;gt;")
@Array.setValue(help, "Rolling your own", "&amp;lt;center&amp;gt;&amp;lt;h2&amp;gt;Rolling your own&amp;lt;/h2&amp;gt;&amp;lt;/center&amp;gt;&amp;lt;p&amp;gt;It is our intention to have a template in the 1.3 release of a MainWindow, but if you have Qt Designer for Qt 3x you can easily start a window design, save it, rename to *.kmdr and open in Kommander. Remember not to add widgets in Designer as Kommander will not recognize them.&amp;lt;/p&amp;gt;")
-@Array.setValue(help, "Using Actions", "&amp;lt;center&amp;gt;&amp;lt;h2&amp;gt;Using Actions&amp;lt;/h2&amp;gt;&amp;lt;/center&amp;gt;&amp;lt;p&amp;gt;If you want to get the goodies, menus, toolbars and accelerator keys, you need to use actions. Kommander has an Action editor on the window menu under Views. There you can add actions and there is a shortcut to connecting them with signals and slots. To get everything working select an Action and look in the properties menu for settings like name, text and icon. For menus and toolbars try right clicking on them for context menus. Now from the Action View drag an Action to the menu or toolbar. See the visual feedback? Just connect your Action to a script and you have three different ways to call it.&amp;lt;/p&amp;gt;
+@Array.setValue(help, "Using Actions", "&amp;lt;center&amp;gt;&amp;lt;h2&amp;gt;Using Actions&amp;lt;/h2&amp;gt;&amp;lt;/center&amp;gt;&amp;lt;p&amp;gt;If you want to get the goodies, menus, toolbars and accelerator keys, you need to use actions. Kommander has an Action editor on the window menu under Views. There you can add actions and there is a shortcut to connecting them with Q_SIGNALS and Q_SLOTS. To get everything working select an Action and look in the properties menu for settings like name, text and icon. For menus and toolbars try right clicking on them for context menus. Now from the Action View drag an Action to the menu or toolbar. See the visual feedback? Just connect your Action to a script and you have three different ways to call it.&amp;lt;/p&amp;gt;
")
@Array.setValue(help, "Link examples", "&amp;lt;center&amp;gt;&amp;lt;h2&amp;gt;Link examples&amp;lt;/h2&amp;gt;&amp;lt;/center&amp;gt;&amp;lt;p&amp;gt;This demo shows examples of linking. Links will show in the TextEdit widget, but they don't do anything. In the TextBrowser they open web pages and email links, but of course you can't edit in the TextBrowser. If you don't mind writing some script you can set up your own link handling, which I've done here. Note that it will follow links anywhere in the editor. If the link is a widget name it assumes it to be a script and calls it. If not it looks to see if it is a web link and calls that&amp;lt;/p&amp;gt;&amp;lt;p&amp;gt;It would be easy to extend this script to accept link parameters and process emails. You could also make a reference to other text objects, tab widget tabs, pretty much anything you can think of.&amp;lt;/p&amp;gt;")
@Array.setValue(help, "How this help works", "&amp;lt;center&amp;gt;&amp;lt;h2&amp;gt;How this help works&amp;lt;/h2&amp;gt;&amp;lt;/center&amp;gt;&amp;lt;p&amp;gt;Do you wonder where this help came from? It is possible to use KDE help if you write DocBook, make it and install it. This quick help is fast and can contain &amp;lt;i&amp;gt;rich text&amp;lt;/i&amp;gt;. To look at the dialog copy the text in the hidden TextEdit (set to text mode so as not to muck things up with rich text interperting XML) and paste it to a text editor like KWrite. Save it as a Kommander file and open it in the Kommander Editor.&amp;lt;/p&amp;gt;")
@@ -331,7 +331,7 @@ debug("Clicked at: "+Self.Item(0)+" "+Self.Item(1))
&lt;property name="spacing"&gt;
&lt;number&gt;6&lt;/number&gt;
&lt;/property&gt;
- &lt;widget class="QSplitter" row="0" column="0" rowspan="2" colspan="2"&gt;
+ &lt;widget class=TQSPLITTER_OBJECT_NAME_STRING row="0" column="0" rowspan="2" colspan="2"&gt;
&lt;property name="name"&gt;
&lt;cstring&gt;Splitter5&lt;/cstring&gt;
&lt;/property&gt;
@@ -428,7 +428,7 @@ debug("Clicked at: "+Self.Item(0)+" "+Self.Item(1))
&lt;slot&gt;execute()&lt;/slot&gt;
&lt;/connection&gt;
&lt;/connections&gt;
-&lt;layoutdefaults spacing="6" margin="11"/&gt;
+&lt;tqlayoutdefaults spacing="6" margin="11"/&gt;
&lt;/UI&gt;
</string>
</property>
@@ -1064,5 +1064,5 @@ TextEdit5.setColor(color)</string>
<slot>setChecked(bool)</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/current/keyvaluecombo.kmdr b/kommander/examples/current/keyvaluecombo.kmdr
index 9815c333..b4a35126 100644
--- a/kommander/examples/current/keyvaluecombo.kmdr
+++ b/kommander/examples/current/keyvaluecombo.kmdr
@@ -63,7 +63,7 @@ PopupMenu1.insertMenuItem("Help About", "PopupMenu1", 10)
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget" row="1" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="1" column="0">
<property name="name">
<cstring>Layout27</cstring>
</property>
@@ -100,7 +100,7 @@ PopupMenu1.insertMenuItem("Help About", "PopupMenu1", 10)
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget" row="0" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="0" column="0">
<property name="name">
<cstring>Layout30</cstring>
</property>
@@ -122,7 +122,7 @@ PopupMenu1.insertMenuItem("Help About", "PopupMenu1", 10)
<string>Right click for menu</string>
</property>
</widget>
- <widget class="QLayoutWidget" row="0" column="2">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="0" column="2">
<property name="name">
<cstring>Layout24</cstring>
</property>
@@ -164,7 +164,7 @@ PopupMenu1.insertMenuItem("Help About", "PopupMenu1", 10)
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget" row="0" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="0" column="0">
<property name="name">
<cstring>Layout23</cstring>
</property>
@@ -227,7 +227,7 @@ PopupMenu1.insertMenuItem("Help About", "PopupMenu1", 10)
</widget>
</grid>
</widget>
- <widget class="QLayoutWidget" row="2" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="2" column="0">
<property name="name">
<cstring>Layout31</cstring>
</property>
@@ -384,5 +384,5 @@ endif</string>
<tabstop>ComboBox10</tabstop>
<tabstop>ListBox1</tabstop>
</tabstops>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/current/kpartmwframe.kmdr b/kommander/examples/current/kpartmwframe.kmdr
index 134f28af..6e334aa6 100755
--- a/kommander/examples/current/kpartmwframe.kmdr
+++ b/kommander/examples/current/kpartmwframe.kmdr
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.0" stdsetdef="1">
<class>KKPdemo</class>
-<widget class="QMainWindow">
+<widget class=TQMAINWINDOW_OBJECT_NAME_STRING>
<property name="name">
<cstring>KKPdemo</cstring>
</property>
@@ -58,7 +58,7 @@
</sizepolicy>
</property>
</widget>
- <widget class="QLayoutWidget" row="1" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="1" column="0">
<property name="name">
<cstring>Layout5</cstring>
</property>
@@ -95,7 +95,7 @@ _loadup = 2
<stringlist>
<string>#!kommander
if widgetExists("ScriptObject13") then
- TextBrowser1.setText("This text was written by a script on the parent frame window. It could have been a dialog, but we chose to illustrate with a MainWindow for this demo.")
+ TextBrowser1.setText("This text was written by a script on the tqparent frame window. It could have been a dialog, but we chose to illustrate with a MainWindow for this demo.")
ScriptObject13.execute
else
message_error("You do not have the KPart child dialog loaded")
@@ -614,5 +614,5 @@ endif</string>
<slot>execute()</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/current/kpartpart.kmdr b/kommander/examples/current/kpartpart.kmdr
index 928ecdc6..0763fada 100755
--- a/kommander/examples/current/kpartpart.kmdr
+++ b/kommander/examples/current/kpartpart.kmdr
@@ -42,16 +42,16 @@
</property>
<property name="text">
<string>You can click the test button to insert text
-If you are loaded in the parent frame you can click the rocket icon on the toolbar or use the function menu to select "Talk to KPart".
+If you are loaded in the tqparent frame you can click the rocket icon on the toolbar or use the function menu to select "Talk to KPart".
-Any Kommander program can be run as a KPart. You need the KPart plugin to load KParts. Note that running Kommander programs as KParts is not without risks. For one thing you loose DCOP in the parent and the old parser ceases to work. Additionally since all widgets are accecssible from the parent and duplicate widget name can cause a Kommander lock up.
+Any Kommander program can be run as a KPart. You need the KPart plugin to load KParts. Note that running Kommander programs as KParts is not without risks. For one thing you loose DCOP in the tqparent and the old parser ceases to work. Additionally since all widgets are accecssible from the tqparent and duplicate widget name can cause a Kommander lock up.
-Because of all this and the fact that the Actions on the unsupported MainWindow are incompatible it is impossible for the child to talk with the parent. On this dialog we use a timer on the parent polling the child for requests every 100 ms. It's a crude hack but it does yield acceptable behavior.
+Because of all this and the fact that the Actions on the unsupported MainWindow are incompatible it is impossible for the child to talk with the tqparent. On this dialog we use a timer on the tqparent polling the child for requests every 100 ms. It's a crude hack but it does yield acceptable behavior.
This demo is intended to run both kpartwmframe.kmdr and kpartpart.kmdr. </string>
</property>
</widget>
- <widget class="QLayoutWidget" row="1" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="1" column="0">
<property name="name">
<cstring>Layout70</cstring>
</property>
@@ -75,7 +75,7 @@ This demo is intended to run both kpartwmframe.kmdr and kpartpart.kmdr. </string
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>75</width>
<height>0</height>
@@ -97,7 +97,7 @@ endif
if _LOADED == true then
kpmessage.setText("You have mail")
else
- message_info("this only works when loaded as a KPart in it's parent window")
+ message_info("this only works when loaded as a KPart in it's tqparent window")
endif
</string>
</stringlist>
@@ -122,7 +122,7 @@ endif
</property>
<property name="associations" stdset="0">
<stringlist>
- <string>message_info("We just got a message from our parent frame!", "Parent called Child")</string>
+ <string>message_info("We just got a message from our tqparent frame!", "Parent called Child")</string>
</stringlist>
</property>
</widget>
@@ -156,7 +156,7 @@ endif
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>40</width>
<height>0</height>
@@ -167,5 +167,5 @@ endif
</widget>
</grid>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/current/passvariables.kmdr b/kommander/examples/current/passvariables.kmdr
index 2d3b9e03..95270a83 100644
--- a/kommander/examples/current/passvariables.kmdr
+++ b/kommander/examples/current/passvariables.kmdr
@@ -90,7 +90,7 @@ LineEdit6.setText(ret)</string>
<property name="text">
<string>Set</string>
</property>
- <property name="alignment">
+ <property name="tqalignment">
<set>AlignVCenter|AlignRight</set>
</property>
</widget>
@@ -101,7 +101,7 @@ LineEdit6.setText(ret)</string>
<property name="text">
<string>Pass back</string>
</property>
- <property name="alignment">
+ <property name="tqalignment">
<set>AlignVCenter|AlignRight</set>
</property>
</widget>
@@ -124,7 +124,7 @@ LineEdit6.setText(ret)</string>
<stringlist>
<string>// test for PHP
pt = exec("php --version")
-if str_contains(pt, "Zend") then
+if str_tqcontains(pt, "Zend") then
php = ScriptObjectPHP.execute(LineEdit7.text,LineEdit1.text,LineEdit2.text)
LineEdit4.setText(php)
else
@@ -140,7 +140,7 @@ endif</string>
<property name="text">
<string>Pass back</string>
</property>
- <property name="alignment">
+ <property name="tqalignment">
<set>AlignVCenter|AlignRight</set>
</property>
</widget>
@@ -151,7 +151,7 @@ endif</string>
<property name="text">
<string>Set with @</string>
</property>
- <property name="alignment">
+ <property name="tqalignment">
<set>AlignVCenter|AlignRight</set>
</property>
</widget>
@@ -162,7 +162,7 @@ endif</string>
<property name="text">
<string>Return</string>
</property>
- <property name="alignment">
+ <property name="tqalignment">
<set>AlignVCenter|AlignRight</set>
</property>
</widget>
@@ -178,7 +178,7 @@ endif</string>
<property name="text">
<string>Return</string>
</property>
- <property name="alignment">
+ <property name="tqalignment">
<set>AlignVCenter|AlignRight</set>
</property>
</widget>
@@ -272,14 +272,14 @@ echo round(@Self.Item(1)/@Self.Item(2),5)
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>108</width>
<height>0</height>
</size>
</property>
</spacer>
- <widget class="QLayoutWidget" row="1" column="0" rowspan="1" colspan="7">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="1" column="0" rowspan="1" colspan="7">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -303,7 +303,7 @@ echo round(@Self.Item(1)/@Self.Item(2),5)
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>71</width>
<height>0</height>
@@ -368,7 +368,7 @@ echo round(@Self.Item(1)/@Self.Item(2),5)
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>71</width>
<height>0</height>
@@ -412,5 +412,5 @@ echo round(@Self.Item(1)/@Self.Item(2),5)
<slot>popup(int,int)</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/current/tableselect.kmdr b/kommander/examples/current/tableselect.kmdr
index 09dd6cd8..a8617103 100755
--- a/kommander/examples/current/tableselect.kmdr
+++ b/kommander/examples/current/tableselect.kmdr
@@ -51,7 +51,7 @@ AboutDialog9.setBugAddress("eric@kdewebdev.org")</string>
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget" row="1" column="3" rowspan="1" colspan="2">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="1" column="3" rowspan="1" colspan="2">
<property name="name">
<cstring>Layout2</cstring>
</property>
@@ -99,7 +99,7 @@ AboutDialog9.setBugAddress("eric@kdewebdev.org")</string>
</widget>
</grid>
</widget>
- <widget class="QLayoutWidget" row="1" column="0" rowspan="1" colspan="2">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="1" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -348,7 +348,7 @@ TextBrowser1.setText(result)
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>24</width>
<height>24</height>
@@ -407,7 +407,7 @@ end
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>24</width>
<height>24</height>
@@ -498,5 +498,5 @@ end
<slot>popup(int,int)</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/checkmail.kmdr b/kommander/examples/old/checkmail.kmdr
index d4fda432..75aff6d0 100644
--- a/kommander/examples/old/checkmail.kmdr
+++ b/kommander/examples/old/checkmail.kmdr
@@ -40,5 +40,5 @@
</property>
</widget>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/ex1.kmdr b/kommander/examples/old/ex1.kmdr
index a916ee22..f2c53005 100644
--- a/kommander/examples/old/ex1.kmdr
+++ b/kommander/examples/old/ex1.kmdr
@@ -101,5 +101,5 @@
</widget>
</vbox>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/execprogram.kmdr b/kommander/examples/old/execprogram.kmdr
index 1149a3e2..7dc9a07b 100644
--- a/kommander/examples/old/execprogram.kmdr
+++ b/kommander/examples/old/execprogram.kmdr
@@ -35,7 +35,7 @@
</stringlist>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout2</cstring>
</property>
@@ -59,7 +59,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -89,7 +89,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -100,5 +100,5 @@
</widget>
</vbox>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/firstform.kmdr.kmdr b/kommander/examples/old/firstform.kmdr.kmdr
index 68993392..e01c228e 100644
--- a/kommander/examples/old/firstform.kmdr.kmdr
+++ b/kommander/examples/old/firstform.kmdr.kmdr
@@ -35,7 +35,7 @@
</stringlist>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -84,5 +84,5 @@
</widget>
</vbox>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/form1.kmdr b/kommander/examples/old/form1.kmdr
index e44b1e14..1d75334d 100644
--- a/kommander/examples/old/form1.kmdr
+++ b/kommander/examples/old/form1.kmdr
@@ -92,5 +92,5 @@
</widget>
</vbox>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/form2.kmdr b/kommander/examples/old/form2.kmdr
index 060fda56..fa488f56 100644
--- a/kommander/examples/old/form2.kmdr
+++ b/kommander/examples/old/form2.kmdr
@@ -25,7 +25,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout3</cstring>
</property>
@@ -73,7 +73,7 @@
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -114,5 +114,5 @@
</widget>
</vbox>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/form3.kmdr b/kommander/examples/old/form3.kmdr
index 2b1ffbb2..18eb8bae 100644
--- a/kommander/examples/old/form3.kmdr
+++ b/kommander/examples/old/form3.kmdr
@@ -58,5 +58,5 @@
</widget>
</vbox>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/form4.kmdr b/kommander/examples/old/form4.kmdr
index 831c2878..672dbb51 100644
--- a/kommander/examples/old/form4.kmdr
+++ b/kommander/examples/old/form4.kmdr
@@ -25,7 +25,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -84,5 +84,5 @@
<slot>setWidgetText(const QString&amp;)</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/form5.kmdr b/kommander/examples/old/form5.kmdr
index 7efeafda..fd71919e 100644
--- a/kommander/examples/old/form5.kmdr
+++ b/kommander/examples/old/form5.kmdr
@@ -64,7 +64,7 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -152,7 +152,7 @@
<bool>true</bool>
</property>
</widget>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel1_2</cstring>
</property>
@@ -342,5 +342,5 @@ Ha ha. We got it all with Kommander!</string>
<slot>setText(const QString&amp;)</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/newfile.kmdr b/kommander/examples/old/newfile.kmdr
index f02ca8e8..e753c6c0 100644
--- a/kommander/examples/old/newfile.kmdr
+++ b/kommander/examples/old/newfile.kmdr
@@ -15,7 +15,7 @@
<property name="caption">
<string>Quick Start</string>
</property>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel2</cstring>
</property>
@@ -31,7 +31,7 @@
<string>Title:</string>
</property>
</widget>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -930,5 +930,5 @@
<slot>setEnabled(bool)</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/populate.kmdr b/kommander/examples/old/populate.kmdr
index a5c5090d..71b9cd3d 100644
--- a/kommander/examples/old/populate.kmdr
+++ b/kommander/examples/old/populate.kmdr
@@ -25,7 +25,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout2</cstring>
</property>
@@ -39,7 +39,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -107,5 +107,5 @@
<slot>populate()</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/resize.kmdr b/kommander/examples/old/resize.kmdr
index 27ff5309..869cce3b 100644
--- a/kommander/examples/old/resize.kmdr
+++ b/kommander/examples/old/resize.kmdr
@@ -25,7 +25,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout2</cstring>
</property>
@@ -65,7 +65,7 @@
<enum>Directory</enum>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class=TQLABEL_OBJECT_NAME_STRING row="0" column="0">
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -73,7 +73,7 @@
<string>Source directory:</string>
</property>
</widget>
- <widget class="QLabel" row="1" column="0">
+ <widget class=TQLABEL_OBJECT_NAME_STRING row="1" column="0">
<property name="name">
<cstring>TextLabel2</cstring>
</property>
@@ -83,7 +83,7 @@
</widget>
</grid>
</widget>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout3</cstring>
</property>
@@ -97,7 +97,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel3</cstring>
</property>
@@ -115,7 +115,7 @@
</stringlist>
</property>
</widget>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel4</cstring>
</property>
@@ -143,7 +143,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>141</width>
<height>0</height>
@@ -152,7 +152,7 @@
</spacer>
</hbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout4</cstring>
</property>
@@ -176,7 +176,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>251</width>
<height>0</height>
@@ -213,5 +213,5 @@ done
</widget>
</vbox>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/selectedwidgettext.kmdr b/kommander/examples/old/selectedwidgettext.kmdr
index 058b6d86..60711066 100644
--- a/kommander/examples/old/selectedwidgettext.kmdr
+++ b/kommander/examples/old/selectedwidgettext.kmdr
@@ -50,7 +50,7 @@
</stringlist>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -90,7 +90,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>0</width>
<height>30</height>
@@ -101,5 +101,5 @@
</widget>
</hbox>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/settings.kmdr b/kommander/examples/old/settings.kmdr
index 1e028434..f336d645 100644
--- a/kommander/examples/old/settings.kmdr
+++ b/kommander/examples/old/settings.kmdr
@@ -35,7 +35,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout7</cstring>
</property>
@@ -49,7 +49,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -83,7 +83,7 @@
</stringlist>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout6</cstring>
</property>
@@ -97,7 +97,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout5</cstring>
</property>
@@ -158,7 +158,7 @@ Items")
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout2</cstring>
</property>
@@ -182,7 +182,7 @@ Items")
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -215,7 +215,7 @@ Items")
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -260,5 +260,5 @@ Items")
<slot>populate()</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/simplelist.kmdr b/kommander/examples/old/simplelist.kmdr
index 42a32323..2bb27af7 100644
--- a/kommander/examples/old/simplelist.kmdr
+++ b/kommander/examples/old/simplelist.kmdr
@@ -15,7 +15,7 @@
<property name="caption">
<string>Form1</string>
</property>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -210,5 +210,5 @@
</property>
</widget>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/tar.kmdr b/kommander/examples/old/tar.kmdr
index 37fcd10d..35922292 100644
--- a/kommander/examples/old/tar.kmdr
+++ b/kommander/examples/old/tar.kmdr
@@ -131,7 +131,7 @@
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout9</cstring>
</property>
@@ -281,14 +281,14 @@
<property name="sizeType">
<enum>Fixed</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>16</height>
</size>
</property>
</spacer>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout7</cstring>
</property>
@@ -329,7 +329,7 @@
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout5</cstring>
</property>
@@ -343,7 +343,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -358,7 +358,7 @@
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout6</cstring>
</property>
@@ -372,7 +372,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel2</cstring>
</property>
@@ -390,7 +390,7 @@
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout7</cstring>
</property>
@@ -414,7 +414,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>103</width>
<height>0</height>
@@ -439,7 +439,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>104</width>
<height>0</height>
@@ -464,7 +464,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>103</width>
<height>0</height>
@@ -475,5 +475,5 @@
</widget>
</vbox>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/tidy.kmdr b/kommander/examples/old/tidy.kmdr
index 096dec40..a96f5119 100644
--- a/kommander/examples/old/tidy.kmdr
+++ b/kommander/examples/old/tidy.kmdr
@@ -29,7 +29,7 @@
<property name="name">
<cstring>TabWidget1</cstring>
</property>
- <widget class="QWidget">
+ <widget class=TQWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>tab</cstring>
</property>
@@ -51,7 +51,7 @@
<property name="title">
<string>Non Tidy Option</string>
</property>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel4</cstring>
</property>
@@ -119,7 +119,7 @@ instances of Quanta running.</string>
</stringlist>
</property>
</widget>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -356,7 +356,7 @@ instances of Quanta running.</string>
</property>
</widget>
</widget>
- <widget class="QWidget">
+ <widget class=TQWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>tab</cstring>
</property>
@@ -373,7 +373,7 @@ instances of Quanta running.</string>
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget" row="0" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="0" column="0">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -477,7 +477,7 @@ instances of Quanta running.</string>
</stringlist>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class=TQLABEL_OBJECT_NAME_STRING row="0" column="0">
<property name="name">
<cstring>TextLabel1_2</cstring>
</property>
@@ -541,7 +541,7 @@ instances of Quanta running.</string>
</stringlist>
</property>
</widget>
- <widget class="QLabel" row="1" column="0">
+ <widget class=TQLABEL_OBJECT_NAME_STRING row="1" column="0">
<property name="name">
<cstring>TextLabel2</cstring>
</property>
@@ -613,7 +613,7 @@ instances of Quanta running.</string>
</widget>
</grid>
</widget>
- <widget class="QWidget">
+ <widget class=TQWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>tab</cstring>
</property>
@@ -889,7 +889,7 @@ instances of Quanta running.</string>
</widget>
</grid>
</widget>
- <widget class="QWidget">
+ <widget class=TQWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>tab</cstring>
</property>
@@ -1012,7 +1012,7 @@ escape-cdata Boolean y/n, yes/no, t/f, true/false, 1/0
language String -
ncr Boolean y/n, yes/no, t/f, true/false, 1/0
output-bom AutoBool auto, y/n, yes/no, t/f, true/false, 1/0
-replace-color Boolean y/n, yes/no, t/f, true/false, 1/0
+tqreplace-color Boolean y/n, yes/no, t/f, true/false, 1/0
css-prefix Name CSS1 selector
new-inline-tags Tag names tagX, tagY, ...
new-blocklevel-tags Tag names tagX, tagY, ...
@@ -1091,7 +1091,7 @@ fi
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>131</width>
<height>0</height>
@@ -1108,7 +1108,7 @@ fi
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>121</width>
<height>0</height>
@@ -1155,5 +1155,5 @@ fi
<slot>setWidgetText(const QString&amp;)</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/widgetgenerator.kmdr b/kommander/examples/old/widgetgenerator.kmdr
index 00ef6262..0c8da2e6 100644
--- a/kommander/examples/old/widgetgenerator.kmdr
+++ b/kommander/examples/old/widgetgenerator.kmdr
@@ -25,7 +25,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget" row="1" column="0" rowspan="1" colspan="2">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="1" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>Layout12</cstring>
</property>
@@ -49,7 +49,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -125,10 +125,10 @@ public:
virtual QString populationText() const;
virtual void setPopulationText(QString);
-public slots:
+public Q_SLOTS:
virtual void setWidgetText(const QString &amp;);
virtual void populate();
-signals:
+Q_SIGNALS:
void widgetOpened();
void widgetTextChanged(const QString &amp;);
protected:
@@ -236,7 +236,7 @@ void @className::showEvent( QShowEvent *e )
emit widgetOpened();
}
-#include \"$classNameLower.moc\"
+#include \"$classNameLower.tqmoc\"
"
echo "$headerContent" &gt; @directory/$classNameLower.h
@@ -265,7 +265,7 @@ echo "$cppContent" &gt; @directory/$classNameLower.cpp</string>
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -274,7 +274,7 @@ echo "$cppContent" &gt; @directory/$classNameLower.cpp</string>
</spacer>
</hbox>
</widget>
- <widget class="QLayoutWidget" row="0" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="0" column="0">
<property name="name">
<cstring>Layout37</cstring>
</property>
@@ -288,7 +288,7 @@ echo "$cppContent" &gt; @directory/$classNameLower.cpp</string>
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -296,7 +296,7 @@ echo "$cppContent" &gt; @directory/$classNameLower.cpp</string>
<string>Author:</string>
</property>
</widget>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel6</cstring>
</property>
@@ -304,7 +304,7 @@ echo "$cppContent" &gt; @directory/$classNameLower.cpp</string>
<string>Email:</string>
</property>
</widget>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel2</cstring>
</property>
@@ -312,7 +312,7 @@ echo "$cppContent" &gt; @directory/$classNameLower.cpp</string>
<string>Description:</string>
</property>
</widget>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel3</cstring>
</property>
@@ -320,7 +320,7 @@ echo "$cppContent" &gt; @directory/$classNameLower.cpp</string>
<string>Date started:</string>
</property>
</widget>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel4</cstring>
</property>
@@ -328,7 +328,7 @@ echo "$cppContent" &gt; @directory/$classNameLower.cpp</string>
<string>Class name:</string>
</property>
</widget>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel7</cstring>
</property>
@@ -336,7 +336,7 @@ echo "$cppContent" &gt; @directory/$classNameLower.cpp</string>
<string>Base class name:</string>
</property>
</widget>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel5</cstring>
</property>
@@ -346,7 +346,7 @@ echo "$cppContent" &gt; @directory/$classNameLower.cpp</string>
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget" row="0" column="1">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="0" column="1">
<property name="name">
<cstring>Layout36</cstring>
</property>
@@ -434,5 +434,5 @@ echo "$cppContent" &gt; @directory/$classNameLower.cpp</string>
</widget>
</grid>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/old/wizard.kmdr b/kommander/examples/old/wizard.kmdr
index 87f50c38..052cfc3a 100755
--- a/kommander/examples/old/wizard.kmdr
+++ b/kommander/examples/old/wizard.kmdr
@@ -1,6 +1,6 @@
<!DOCTYPE UI><UI version="3.0" stdsetdef="1">
<class>Wizard1</class>
-<widget class="QWizard">
+<widget class=TQWIZARD_OBJECT_NAME_STRING>
<property name="name">
<cstring>Wizard1</cstring>
</property>
@@ -15,7 +15,7 @@
<property name="caption">
<string>Demo Wizard</string>
</property>
- <widget class="QWidget">
+ <widget class=TQWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>page</cstring>
</property>
@@ -132,7 +132,7 @@
</property>
</widget>
</widget>
- <widget class="QWidget">
+ <widget class=TQWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>page</cstring>
</property>
@@ -189,7 +189,7 @@
</property>
</widget>
</widget>
- <widget class="QWidget">
+ <widget class=TQWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>page</cstring>
</property>
@@ -297,5 +297,5 @@
<slot>execute()</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/append.kmdr b/kommander/examples/tutorial/append.kmdr
index fe22a4c3..51b24cde 100644
--- a/kommander/examples/tutorial/append.kmdr
+++ b/kommander/examples/tutorial/append.kmdr
@@ -40,7 +40,7 @@
</stringlist>
</property>
</widget>
- <widget class="QLayoutWidget" row="1" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="1" column="0">
<property name="name">
<cstring>Layout2</cstring>
</property>
@@ -64,7 +64,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -100,7 +100,7 @@ dcop @dcopid KommanderIf changeWidgetText TextEdit1 "$TEXT"
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -111,5 +111,5 @@ dcop @dcopid KommanderIf changeWidgetText TextEdit1 "$TEXT"
</widget>
</grid>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/arrays.kmdr b/kommander/examples/tutorial/arrays.kmdr
index dd4b18c6..b884affc 100644
--- a/kommander/examples/tutorial/arrays.kmdr
+++ b/kommander/examples/tutorial/arrays.kmdr
@@ -36,7 +36,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel" row="0" column="0">
+ <widget class=TQLABEL_OBJECT_NAME_STRING row="0" column="0">
<property name="name">
<cstring>TextLabel2</cstring>
</property>
@@ -93,7 +93,7 @@
</stringlist>
</property>
</widget>
- <widget class="QLayoutWidget" row="3" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="3" column="0">
<property name="name">
<cstring>Layout4</cstring>
</property>
@@ -117,7 +117,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -181,7 +181,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -200,5 +200,5 @@
<slot>populate()</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/calc.kmdr b/kommander/examples/tutorial/calc.kmdr
index 5e0082f4..21bddb4e 100644
--- a/kommander/examples/tutorial/calc.kmdr
+++ b/kommander/examples/tutorial/calc.kmdr
@@ -32,7 +32,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget" row="0" column="1">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="0" column="1">
<property name="name">
<cstring>Layout7</cstring>
</property>
@@ -46,7 +46,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -66,13 +66,13 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>200</width>
<height>0</height>
</size>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>250</width>
<height>32767</height>
@@ -91,7 +91,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>250</width>
<height>32767</height>
@@ -124,7 +124,7 @@
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget" row="0" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="0" column="0">
<property name="name">
<cstring>Layout4</cstring>
</property>
@@ -138,7 +138,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel" row="2" column="0">
+ <widget class=TQLABEL_OBJECT_NAME_STRING row="2" column="0">
<property name="name">
<cstring>TextLabel2</cstring>
</property>
@@ -146,7 +146,7 @@
<string>Expression:</string>
</property>
</widget>
- <widget class="QLayoutWidget" row="4" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="4" column="0">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -170,7 +170,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -194,7 +194,7 @@
<stringlist>
<string>@ListBox1.insertItem(@expr(@LineEdit1.text), -1)
@LineEdit1.clear
-@LineEdit2.setText("Sum: @expr(@String.replace(@ListBox1.text, "\n", "+"))")
+@LineEdit2.setText("Sum: @expr(@String.tqreplace(@ListBox1.text, "\n", "+"))")
</string>
</stringlist>
</property>
@@ -209,7 +209,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -233,7 +233,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>0</width>
<height>91</height>
@@ -250,7 +250,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>0</width>
<height>91</height>
@@ -267,5 +267,5 @@
<tabstop>ExecButton2</tabstop>
<tabstop>ListBox1</tabstop>
</tabstops>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/cmdline.kmdr b/kommander/examples/tutorial/cmdline.kmdr
index 0db801d2..6d0cbbe1 100644
--- a/kommander/examples/tutorial/cmdline.kmdr
+++ b/kommander/examples/tutorial/cmdline.kmdr
@@ -50,7 +50,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>149</width>
<height>0</height>
@@ -95,7 +95,7 @@ fi</string>
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>148</width>
<height>0</height>
@@ -104,5 +104,5 @@ fi</string>
</spacer>
</grid>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/dcop.kmdr b/kommander/examples/tutorial/dcop.kmdr
index 9ceae259..739bdae6 100644
--- a/kommander/examples/tutorial/dcop.kmdr
+++ b/kommander/examples/tutorial/dcop.kmdr
@@ -35,7 +35,7 @@
</stringlist>
</property>
</widget>
- <widget class="QLayoutWidget" row="1" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="1" column="0">
<property name="name">
<cstring>Layout2</cstring>
</property>
@@ -59,7 +59,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -124,7 +124,7 @@ dcop kmail KMailIface checkAccount @AccountListBox</string>
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -135,5 +135,5 @@ dcop kmail KMailIface checkAccount @AccountListBox</string>
</widget>
</grid>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/dialogs.kmdr b/kommander/examples/tutorial/dialogs.kmdr
index 62c97bc0..421f0607 100644
--- a/kommander/examples/tutorial/dialogs.kmdr
+++ b/kommander/examples/tutorial/dialogs.kmdr
@@ -85,7 +85,7 @@ ListBox1.setText(a)
</stringlist>
</property>
</widget>
- <widget class="QLayoutWidget" row="0" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="0" column="0">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -194,5 +194,5 @@ ListBox1.setText(a)
</widget>
</grid>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/globals.kmdr b/kommander/examples/tutorial/globals.kmdr
index 71cfad17..131c3a2a 100644
--- a/kommander/examples/tutorial/globals.kmdr
+++ b/kommander/examples/tutorial/globals.kmdr
@@ -32,7 +32,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget" row="0" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="0" column="0">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -92,5 +92,5 @@
</widget>
</grid>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/initialize.kmdr b/kommander/examples/tutorial/initialize.kmdr
index 16ed360d..5ca6bbc9 100644
--- a/kommander/examples/tutorial/initialize.kmdr
+++ b/kommander/examples/tutorial/initialize.kmdr
@@ -35,7 +35,7 @@ dcop @dcopid KommanderIf changeWidgetText CloseLabel "$CLOSE"
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget" row="2" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="2" column="0">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -59,7 +59,7 @@ dcop @dcopid KommanderIf changeWidgetText CloseLabel "$CLOSE"
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -89,7 +89,7 @@ dcop @dcopid KommanderIf changeWidgetText CloseLabel "$CLOSE"
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -98,7 +98,7 @@ dcop @dcopid KommanderIf changeWidgetText CloseLabel "$CLOSE"
</spacer>
</hbox>
</widget>
- <widget class="QLabel" row="1" column="0">
+ <widget class=TQLABEL_OBJECT_NAME_STRING row="1" column="0">
<property name="name">
<cstring>OpenLabel</cstring>
</property>
@@ -106,7 +106,7 @@ dcop @dcopid KommanderIf changeWidgetText CloseLabel "$CLOSE"
<string>Opened:</string>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class=TQLABEL_OBJECT_NAME_STRING row="0" column="0">
<property name="name">
<cstring>CloseLabel</cstring>
</property>
@@ -116,5 +116,5 @@ dcop @dcopid KommanderIf changeWidgetText CloseLabel "$CLOSE"
</widget>
</grid>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/loop.kmdr b/kommander/examples/tutorial/loop.kmdr
index 4aa799f1..998fe1d0 100644
--- a/kommander/examples/tutorial/loop.kmdr
+++ b/kommander/examples/tutorial/loop.kmdr
@@ -79,7 +79,7 @@
</stringlist>
</property>
</widget>
- <widget class="QLayoutWidget" row="0" column="1">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="0" column="1">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -93,7 +93,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -110,5 +110,5 @@
</widget>
</grid>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/picview.kmdr b/kommander/examples/tutorial/picview.kmdr
index be75af7b..bc1f923a 100644
--- a/kommander/examples/tutorial/picview.kmdr
+++ b/kommander/examples/tutorial/picview.kmdr
@@ -52,7 +52,7 @@
<enum>Directory</enum>
</property>
</widget>
- <widget class="QLayoutWidget" row="2" column="0" rowspan="1" colspan="2">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="2" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>Layout2</cstring>
</property>
@@ -78,20 +78,20 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>200</width>
<height>0</height>
</size>
</property>
- <property name="maximumSize">
+ <property name="tqmaximumSize">
<size>
<width>200</width>
<height>32767</height>
</size>
</property>
<property name="populationText">
- <string>@exec(cd @FileSelector1.text &amp;&amp; find * -name "*.jpg" -o -name "*.png" -o -name "*.gif" -o -name "*.bmp")</string>
+ <string>@exec(cd @FileSelector1.text &amp;&amp; tqfind * -name "*.jpg" -o -name "*.png" -o -name "*.gif" -o -name "*.bmp")</string>
</property>
<property name="associations" stdset="0">
<stringlist>
@@ -144,5 +144,5 @@
<slot>populate()</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/progressbar.kmdr b/kommander/examples/tutorial/progressbar.kmdr
index 397410cb..9e624b78 100644
--- a/kommander/examples/tutorial/progressbar.kmdr
+++ b/kommander/examples/tutorial/progressbar.kmdr
@@ -106,7 +106,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>191</width>
<height>0</height>
@@ -123,7 +123,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>191</width>
<height>0</height>
@@ -137,12 +137,12 @@
<property name="associations" stdset="0">
<stringlist>
<string>@# set up a loop using loop variable named "file"
-@forEach(file, @exec(cd @FileSelector1.text &amp;&amp; find * -maxdepth 0))
+@forEach(file, @exec(cd @FileSelector1.text &amp;&amp; tqfind * -maxdepth 0))
@# set the scale using the generated @[loopvar]_count
@ProgressBar1.setMaximum(@file_count)
@# show file name in statusbar
@StatusBar1.setText(@file)
- @TreeWidget1.insertItems(@exec(cd @FileSelector1.text &amp;&amp; find @file -name "*"), -1)
+ @TreeWidget1.insertItems(@exec(cd @FileSelector1.text &amp;&amp; tqfind @file -name "*"), -1)
@# use the generated @[loopvar]_index to update progressbar
@ProgressBar1.setText(@file_index)
@end
@@ -188,5 +188,5 @@
</widget>
</grid>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/settings.kmdr b/kommander/examples/tutorial/settings.kmdr
index 3079d6f9..a280dff2 100644
--- a/kommander/examples/tutorial/settings.kmdr
+++ b/kommander/examples/tutorial/settings.kmdr
@@ -32,7 +32,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget" row="0" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="0" column="0">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -46,7 +46,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -69,7 +69,7 @@
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget" row="1" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="1" column="0">
<property name="name">
<cstring>Layout5</cstring>
</property>
@@ -93,7 +93,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -104,7 +104,7 @@
<property name="name">
<cstring>ExecButton1</cstring>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>60</width>
<height>0</height>
@@ -129,7 +129,7 @@
<property name="name">
<cstring>CloseButton1</cstring>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>60</width>
<height>0</height>
@@ -154,7 +154,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -173,5 +173,5 @@
<slot>populate()</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/slots.kmdr b/kommander/examples/tutorial/slots.kmdr
index 23ab2d09..ce54a3ba 100644
--- a/kommander/examples/tutorial/slots.kmdr
+++ b/kommander/examples/tutorial/slots.kmdr
@@ -30,7 +30,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget" row="0" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="0" column="0">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -44,7 +44,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -68,7 +68,7 @@
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget" row="1" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="1" column="0">
<property name="name">
<cstring>Layout2</cstring>
</property>
@@ -82,7 +82,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel2</cstring>
</property>
@@ -105,7 +105,7 @@
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget" row="2" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="2" column="0">
<property name="name">
<cstring>Layout3</cstring>
</property>
@@ -129,7 +129,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -171,7 +171,7 @@ fi
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -196,5 +196,5 @@ fi
<slot>startProcess()</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/statusbar.kmdr b/kommander/examples/tutorial/statusbar.kmdr
index d4f96e05..8dd2b897 100644
--- a/kommander/examples/tutorial/statusbar.kmdr
+++ b/kommander/examples/tutorial/statusbar.kmdr
@@ -95,5 +95,5 @@
<slot>populate()</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/strings.kmdr b/kommander/examples/tutorial/strings.kmdr
index 1ef6a953..464f84ae 100644
--- a/kommander/examples/tutorial/strings.kmdr
+++ b/kommander/examples/tutorial/strings.kmdr
@@ -49,13 +49,13 @@
&lt;b&gt;Last 5 chars:&lt;/b&gt; @String.right("@LineEdit1", 5)&lt;br&gt;
&lt;b&gt;Chars from 6th to 10th:&lt;/b&gt; @String.mid("@LineEdit1", 6, 5)&lt;br&gt;
&lt;b&gt;Remove spaces:&lt;/b&gt; @String.remove("@LineEdit1", " ")&lt;br&gt;
-&lt;b&gt;Replace spaces with *&lt;/b&gt;: @String.replace("@LineEdit1", " ", *)&lt;br&gt;
+&lt;b&gt;Replace spaces with *&lt;/b&gt;: @String.tqreplace("@LineEdit1", " ", *)&lt;br&gt;
&lt;b&gt;Uppercase:&lt;/b&gt; @String.upper("@LineEdit1")&lt;br&gt;
&lt;b&gt;Lowercase:&lt;/b&gt; @String.lower("@LineEdit1")&lt;br&gt;
&lt;b&gt;Is a number?:&lt;/b&gt; @Array.value(Bool, @String.isNumber("@LineEdit1"))&lt;br&gt;
&lt;b&gt;Is empty?&lt;/b&gt; @Array.value(Bool, @String.isEmpty("@LineEdit1"))&lt;br&gt;
-&lt;b&gt;Contains "Kommander"?:&lt;/b&gt; @String.contains("@LineEdit1", "Kommander")&lt;br&gt;
-&lt;b&gt;Position of "Kommander":&lt;/b&gt; @String.find("@LineEdit1", "Kommander")&lt;br&gt;
+&lt;b&gt;Contains "Kommander"?:&lt;/b&gt; @String.tqcontains("@LineEdit1", "Kommander")&lt;br&gt;
+&lt;b&gt;Position of "Kommander":&lt;/b&gt; @String.tqfind("@LineEdit1", "Kommander")&lt;br&gt;
&lt;b&gt;Compare with "Kommander":&lt;/b&gt;
@execBegin
if [ @String.compare("@LineEdit1", "Kommander") -lt 0 ];then
@@ -81,7 +81,7 @@ fi
</stringlist>
</property>
</widget>
- <widget class="QLayoutWidget" row="0" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="0" column="0">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -95,7 +95,7 @@ fi
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -121,7 +121,7 @@ fi
</widget>
</hbox>
</widget>
- <widget class="QLayoutWidget" row="2" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="2" column="0">
<property name="name">
<cstring>Layout2</cstring>
</property>
@@ -145,7 +145,7 @@ fi
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -178,7 +178,7 @@ fi
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>30</width>
<height>0</height>
@@ -202,5 +202,5 @@ fi
<tabstop>ExecButton1</tabstop>
<tabstop>TextEdit1</tabstop>
</tabstops>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/table.kmdr b/kommander/examples/tutorial/table.kmdr
index a2c5986b..d7ed3461 100644
--- a/kommander/examples/tutorial/table.kmdr
+++ b/kommander/examples/tutorial/table.kmdr
@@ -77,7 +77,7 @@
</stringlist>
</property>
</widget>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout3</cstring>
</property>
@@ -161,7 +161,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>0</width>
<height>30</height>
@@ -170,7 +170,7 @@
</spacer>
</vbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout4</cstring>
</property>
@@ -254,5 +254,5 @@
</hbox>
</widget>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/tree.kmdr b/kommander/examples/tutorial/tree.kmdr
index bed87709..fcde8a28 100644
--- a/kommander/examples/tutorial/tree.kmdr
+++ b/kommander/examples/tutorial/tree.kmdr
@@ -33,7 +33,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLayoutWidget" row="2" column="0" rowspan="1" colspan="2">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="2" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -60,7 +60,7 @@
<property name="associations" stdset="0">
<stringlist>
<string>@TreeWidget1.clear
-@TreeWidget1.insertItems(@exec(cd @FileSelector1.text &amp;&amp; find * -name "*.kmdr"), -1)</string>
+@TreeWidget1.insertItems(@exec(cd @FileSelector1.text &amp;&amp; tqfind * -name "*.kmdr"), -1)</string>
</stringlist>
</property>
</widget>
@@ -109,7 +109,7 @@
</stringlist>
</property>
</widget>
- <widget class="QLabel" row="1" column="0">
+ <widget class=TQLABEL_OBJECT_NAME_STRING row="1" column="0">
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -130,7 +130,7 @@
<enum>Directory</enum>
</property>
</widget>
- <widget class="QLayoutWidget" row="3" column="0" rowspan="1" colspan="2">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="3" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>Layout3</cstring>
</property>
@@ -166,5 +166,5 @@
</widget>
</grid>
</widget>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/examples/tutorial/widgets.kmdr b/kommander/examples/tutorial/widgets.kmdr
index 9e6781c6..912cded0 100644
--- a/kommander/examples/tutorial/widgets.kmdr
+++ b/kommander/examples/tutorial/widgets.kmdr
@@ -68,7 +68,7 @@
</property>
<property name="associations" stdset="0">
<stringlist>
- <string>@WidgetList.setText(@Form1.children(true))</string>
+ <string>@WidgetList.setText(@Form1.tqchildren(true))</string>
</stringlist>
</property>
</widget>
@@ -82,7 +82,7 @@
</stringlist>
</property>
</widget>
- <widget class="QLayoutWidget" row="1" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="1" column="0">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -96,7 +96,7 @@
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel1</cstring>
</property>
@@ -129,5 +129,5 @@
<slot>populate()</slot>
</connection>
</connections>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/executor/dcopkommanderif.h b/kommander/executor/dcopkommanderif.h
index 1ba67cbb..c756b059 100644
--- a/kommander/executor/dcopkommanderif.h
+++ b/kommander/executor/dcopkommanderif.h
@@ -58,7 +58,7 @@ virtual void setChecked(const TQString &widgetName, bool checked) = 0;
virtual void setAssociatedText(const TQString &widgetName, const TQString &text) = 0;
virtual TQStringList associatedText(const TQString &widgetName) = 0;
virtual TQString type(const TQString& widget) = 0;
-virtual TQStringList children(const TQString& parent, bool recursive) = 0;
+virtual TQStringList tqchildren(const TQString& tqparent, bool recursive) = 0;
virtual TQString global(const TQString& variableName) = 0;
virtual void setGlobal(const TQString& variableName, const TQString& value) = 0;
virtual void setMaximum(const TQString &widgetName, int value) = 0;
diff --git a/kommander/executor/instance.cpp b/kommander/executor/instance.cpp
index a8ff3400..d24e856a 100644
--- a/kommander/executor/instance.cpp
+++ b/kommander/executor/instance.cpp
@@ -67,7 +67,7 @@ void Instance::addCmdlineArguments(const TQStringList& args)
TQStringList stdArgs;
for (TQStringList::ConstIterator it = args.begin(); it != args.end(); ++it)
{
- int pos = (*it).find('=');
+ int pos = (*it).tqfind('=');
if (pos != -1)
m_textInstance->setGlobal((*it).left(pos), (*it).mid(pos+1));
else
@@ -75,7 +75,7 @@ void Instance::addCmdlineArguments(const TQStringList& args)
}
int i = 0;
for (TQStringList::ConstIterator it = stdArgs.begin(); it != stdArgs.end(); ++it)
- m_textInstance->setGlobal(TQString("_ARG%1").arg(++i), *it);
+ m_textInstance->setGlobal(TQString("_ARG%1").tqarg(++i), *it);
m_textInstance->setGlobal("_ARGS", stdArgs.join(" "));
m_textInstance->setGlobal("_ARGCOUNT", TQString::number(stdArgs.count()));
}
@@ -97,16 +97,16 @@ bool Instance::build(const KURL& fname)
if (!fname.isValid() || !isFileValid(fname))
return false; // Check if file is correct
- // create the main instance, must inherit QDialog
+ // create the main instance, must inherit TQDialog
KommanderFactory::loadPlugins();
if (fname.isValid())
- m_instance = KommanderFactory::create(fname.path(), 0L, dynamic_cast<TQWidget*>(parent()));
+ m_instance = KommanderFactory::create(fname.path(), 0L, dynamic_cast<TQWidget*>(tqparent()));
else
{
TQFile inputFile;
inputFile.open(IO_ReadOnly, stdin);
- m_instance = KommanderFactory::create(&inputFile);
+ m_instance = KommanderFactory::create(TQT_TQIODEVICE(&inputFile));
}
// check if build was successful
@@ -121,7 +121,7 @@ bool Instance::build(const KURL& fname)
window->setFileName(fname.path().local8Bit());
// FIXME : Should verify that all of the widgets in the dialog derive from KommanderWidget
- m_textInstance = kommanderWidget(m_instance);
+ m_textInstance = kommanderWidget(TQT_TQOBJECT(m_instance));
if (!m_textInstance) // Main dialog/window is not a Kommander widget - look for one
{
@@ -185,7 +185,7 @@ bool Instance::isFileValid(const KURL& fname) const
if (!TQFileInfo(fname.path()).exists())
{
KMessageBox::sorry(0, i18n("<qt>Kommander file<br><b>%1</b><br>does not "
- "exist.</qt>").arg(fname.path()));
+ "exist.</qt>").tqarg(fname.path()));
return false;
}
@@ -220,7 +220,7 @@ bool Instance::isFileValid(const KURL& fname) const
}
if (!TQFileInfo(fname.path()).isExecutable())
{
- if (KMessageBox::warningContinueCancel(0, i18n("<qt>The Kommander file <i>%1</i> does not have the <b>executable attribute</b> set and could possibly contain dangerous exploits.<p>If you trust the scripting (viewable in kmdr-editor) in this program, make it executable to get rid of this warning.<p>Are you sure you want to continue?</qt>").arg(fname.pathOrURL()), TQString(), i18n("Run Nevertheless")) == KMessageBox::Cancel)
+ if (KMessageBox::warningContinueCancel(0, i18n("<qt>The Kommander file <i>%1</i> does not have the <b>executable attribute</b> set and could possibly contain dangerous exploits.<p>If you trust the scripting (viewable in kmdr-editor) in this program, make it executable to get rid of this warning.<p>Are you sure you want to continue?</qt>").tqarg(fname.pathOrURL()), TQString(), i18n("Run Nevertheless")) == KMessageBox::Cancel)
return false;
}
return true;
@@ -431,13 +431,13 @@ TQString Instance::type(const TQString& widget)
return TQString();
}
-TQStringList Instance::children(const TQString& parent, bool recursive)
+TQStringList Instance::tqchildren(const TQString& tqparent, bool recursive)
{
TQStringList matching;
- TQObject* child = stringToWidget(parent);
+ TQObject* child = stringToWidget(tqparent);
TQObjectList* widgets;
if (!child)
- child = m_instance;
+ child = TQT_TQOBJECT(m_instance);
if (child->inherits(TQWIDGET_OBJECT_NAME_STRING))
{
widgets = child->queryList(TQWIDGET_OBJECT_NAME_STRING, 0, false, recursive);
@@ -674,9 +674,9 @@ int Instance::getWinID()
void Instance::setBusyCursor(bool busy)
{
if (busy)
- m_instance->setCursor(TQCursor(Qt::WaitCursor));
+ m_instance->setCursor(TQCursor(TQt::WaitCursor));
else
- m_instance->setCursor(TQCursor(Qt::ArrowCursor));
+ m_instance->setCursor(TQCursor(TQt::ArrowCursor));
}
diff --git a/kommander/executor/instance.h b/kommander/executor/instance.h
index 95b52ead..469d7202 100644
--- a/kommander/executor/instance.h
+++ b/kommander/executor/instance.h
@@ -43,6 +43,7 @@ class KommanderWidget;
class Instance : public TQObject, virtual public DCOPKommanderIf
{
Q_OBJECT
+ TQ_OBJECT
public:
Instance();
@@ -89,7 +90,7 @@ public:
virtual void setAssociatedText(const TQString &widgetName, const TQString &text);
virtual TQStringList associatedText(const TQString &widgetName);
virtual TQString type(const TQString& widget);
- virtual TQStringList children(const TQString& parent, bool recursive);
+ virtual TQStringList tqchildren(const TQString& tqparent, bool recursive);
virtual TQString global(const TQString& variableName);
virtual void setGlobal(const TQString& variableName, const TQString& value);
virtual void setMaximum(const TQString &widgetName, int value);
@@ -111,7 +112,7 @@ public:
TQWidget *widget() { return m_instance;}
public slots:
- /** Sets the instance's parent */
+ /** Sets the instance's tqparent */
void setParent(TQWidget*);
/** Returns whether the instance is built */
bool isBuilt() const;
@@ -126,7 +127,7 @@ private:
TQGuardedPtr<TQWidget> m_instance;
/* Associated Text Instance */
KommanderWidget *m_textInstance;
- /** The parent widget */
+ /** The tqparent widget */
TQWidget *m_parent;
/* Get object by name */
TQObject* stringToWidget(const TQString& name);
diff --git a/kommander/executor/main.cpp b/kommander/executor/main.cpp
index 00d7e509..d49dd373 100644
--- a/kommander/executor/main.cpp
+++ b/kommander/executor/main.cpp
@@ -71,7 +71,7 @@ int main(int argc, char *argv[])
{
char buf[200];
TQString baseFile = args->url(0).fileName();
- int ext = baseFile.findRev('.');
+ int ext = baseFile.tqfindRev('.');
if (ext != -1)
baseFile = baseFile.left(ext);
strcpy(buf, baseFile.latin1());
diff --git a/kommander/executor/register.cpp b/kommander/executor/register.cpp
index db794e25..f3d33799 100644
--- a/kommander/executor/register.cpp
+++ b/kommander/executor/register.cpp
@@ -49,7 +49,7 @@ void Instance::registerSpecials()
SpecialInformation::insert("null", 0, 0);
SpecialInformation::insert("pid", 0, 0);
SpecialInformation::insert("dcopid", 0, 0);
- SpecialInformation::insert("parentPid", 0, 0);
+ SpecialInformation::insert("tqparentPid", 0, 0);
SpecialInformation::insert("execBegin", 0, 1);
SpecialInformation::insert("env", 1, 1);
SpecialInformation::insert("exec", 1, 1);
@@ -80,15 +80,15 @@ void Instance::registerSpecials()
SpecialInformation::setCurrentObject("String");
SpecialInformation::insert("length", 1, 1, i18n( "Return number of chars in the string.") );
- SpecialInformation::insert("contains", 2, 2, i18n( "Check if the string contains given substring.") );
- SpecialInformation::insert("find", 2, 2, i18n( "Return position of a substring in the string, "
+ SpecialInformation::insert("tqcontains", 2, 2, i18n( "Check if the string contains given substring.") );
+ SpecialInformation::insert("tqfind", 2, 2, i18n( "Return position of a substring in the string, "
"or -1 if it isn't found.") );
SpecialInformation::insert("left", 2, 2, i18n( "Return first n chars of the string.") );
SpecialInformation::insert("right", 2, 2, i18n( "Return last n chars of the string.") );
SpecialInformation::insert("mid", 3, 3, i18n( "Return substring of the string, starting from "
"given position.") );
SpecialInformation::insert("remove", 2, 2, i18n( "Replace all occurencies of given substring.") );
- SpecialInformation::insert("replace", 3, 3, i18n( "Replace all occurencies of given substring "
+ SpecialInformation::insert("tqreplace", 3, 3, i18n( "Replace all occurencies of given substring "
"with given replacement.") );
SpecialInformation::insert("upper", 1, 1, i18n( "Convert the string to uppercase.") );
SpecialInformation::insert("lower", 1, 1, i18n( "Convert the string to lowercase.") );
diff --git a/kommander/factory/domtool.cpp b/kommander/factory/domtool.cpp
index 0bd7088c..e532dc10 100644
--- a/kommander/factory/domtool.cpp
+++ b/kommander/factory/domtool.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -328,7 +328,7 @@ static bool toBool( const TQString& s )
}
/*!
- Convert Qt 2.x format to Qt 3.0 format if necessary
+ Convert TQt 2.x format to TQt 3.0 format if necessary
*/
void DomTool::fixDocument( TQDomDocument& doc )
{
@@ -360,9 +360,9 @@ void DomTool::fixDocument( TQDomDocument& doc )
bool stdset = toBool( e.attribute( "stdset" ) );
if ( stdset || name == "toolTip" || name == "whatsThis" ||
name == "buddy" ||
- e.parentNode().toElement().tagName() == "item" ||
- e.parentNode().toElement().tagName() == "spacer" ||
- e.parentNode().toElement().tagName() == "column"
+ e.tqparentNode().toElement().tagName() == "item" ||
+ e.tqparentNode().toElement().tagName() == "spacer" ||
+ e.tqparentNode().toElement().tagName() == "column"
)
e.removeAttribute( "stdset" );
else
diff --git a/kommander/factory/domtool.h b/kommander/factory/domtool.h
index 034cb98e..30f26b51 100644
--- a/kommander/factory/domtool.h
+++ b/kommander/factory/domtool.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -27,7 +27,7 @@
class TQDomElement;
class TQDomDocument;
-class DomTool : public Qt
+class DomTool : public TQt
{
public:
static TQVariant readProperty( const TQDomElement& e, const TQString& name, const TQVariant& defValue );
diff --git a/kommander/factory/kommanderfactory.cpp b/kommander/factory/kommanderfactory.cpp
index ecfcb8cd..d5713bd0 100644
--- a/kommander/factory/kommanderfactory.cpp
+++ b/kommander/factory/kommanderfactory.cpp
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000-2002 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -25,10 +25,13 @@
#include "kommanderfactory.h"
#include <kommanderplugin.h>
+#ifdef QT_NO_SQL
+#define TQT_NO_SQL
+#endif // QT_NO_SQL
#include <tqfeatures.h>
#include "config.h"
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
#include "database2.h"
#endif
#include <tqdom.h>
@@ -40,18 +43,18 @@
#include <tqtooltip.h>
#include <tqwhatsthis.h>
#include <tqobjectlist.h>
-#include <private/qpluginmanager_p.h>
+#include <private/tqpluginmanager_p.h>
#include <tqmime.h>
#include <tqdragobject.h>
#include <zlib.h>
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
#include <tqsqlrecord.h>
#include <tqsqldatabase.h>
#include <tqdatatable.h>
#endif
-// include all Qt widgets we support
+// include all TQt widgets we support
#include <tqpushbutton.h>
#include <tqtoolbutton.h>
#include <tqcheckbox.h>
@@ -60,7 +63,7 @@
#include <tqbuttongroup.h>
#include <tqiconview.h>
#include <tqheader.h>
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
#include <tqtable.h>
#endif
#include <tqlistbox.h>
@@ -123,7 +126,7 @@ KommanderFactory::~KommanderFactory()
qwf_currFileName = 0L;
}
-TQWidget *KommanderFactory::create( const TQString &uiFile, TQObject *connector, TQWidget *parent, const char *name )
+TQWidget *KommanderFactory::create( const TQString &uiFile, TQObject *connector, TQWidget *tqparent, const char *name )
{
TQFile f( uiFile );
if ( !f.open( IO_ReadOnly ) )
@@ -132,14 +135,14 @@ TQWidget *KommanderFactory::create( const TQString &uiFile, TQObject *connector,
if (!qwf_currFileName)
qwf_currFileName = new TQString();
*qwf_currFileName = uiFile;
- TQWidget *w = KommanderFactory::create( &f, connector, parent, name );
+ TQWidget *w = KommanderFactory::create( TQT_TQIODEVICE(&f), connector, tqparent, name );
if ( !qwf_forms )
qwf_forms = new TQMap<TQWidget*, TQString>;
qwf_forms->insert( w, uiFile );
return w;
}
-TQWidget *KommanderFactory::create( TQIODevice *dev, TQObject *connector, TQWidget *parent, const char *name )
+TQWidget *KommanderFactory::create( TQIODevice *dev, TQObject *connector, TQWidget *tqparent, const char *name )
{
TQDomDocument doc;
TQString errMsg;
@@ -147,7 +150,7 @@ TQWidget *KommanderFactory::create( TQIODevice *dev, TQObject *connector, TQWidg
TQTextStream stream(dev);
TQString content = stream.read();
if (content.startsWith("#!"))
- content = content.mid(content.find('\n'));
+ content = content.mid(content.tqfind('\n'));
if ( !doc.setContent( content ) ) {
// qDebug( TQString("Parse error: ") + errMsg + TQString(" in line %d"), errLine );
return 0;
@@ -204,7 +207,7 @@ TQWidget *KommanderFactory::create( TQIODevice *dev, TQObject *connector, TQWidg
widgetFactory->variables << e.firstChild().toText().data();
} else if ( e.tagName() == "pixmapinproject" ) {
widgetFactory->usePixmapCollection = true;
- } else if ( e.tagName() == "layoutdefaults" ) {
+ } else if ( e.tagName() == "tqlayoutdefaults" ) {
widgetFactory->defSpacing = e.attribute( "spacing", TQString::number( widgetFactory->defSpacing ) ).toInt();
widgetFactory->defMargin = e.attribute( "margin", TQString::number( widgetFactory->defMargin ) ).toInt();
}
@@ -214,7 +217,7 @@ TQWidget *KommanderFactory::create( TQIODevice *dev, TQObject *connector, TQWidg
if ( !imageCollection.isNull() )
widgetFactory->loadImageCollection( imageCollection );
- widgetFactory->createWidgetInternal( widget, parent, 0, widget.attribute("class", TQWIDGET_OBJECT_NAME_STRING) );
+ widgetFactory->createWidgetInternal( widget, tqparent, 0, widget.attribute("class", TQWIDGET_OBJECT_NAME_STRING) );
TQWidget *w = widgetFactory->toplevel;
if ( !w ) {
delete widgetFactory;
@@ -230,7 +233,7 @@ TQWidget *KommanderFactory::create( TQIODevice *dev, TQObject *connector, TQWidg
for ( TQDomElement n = eltSlots.firstChild().toElement(); !n.isNull(); n = n.nextSibling().toElement() )
if ( n.tagName() == "slot" ) {
TQString s = n.firstChild().toText().data();
- widgetFactory->languageSlots.insert( s.left( s.find( "(" ) ) , n.attribute( "language", "C++" ) );
+ widgetFactory->languageSlots.insert( s.left( s.tqfind( "(" ) ) , n.attribute( "language", "C++" ) );
}
}
@@ -243,7 +246,7 @@ TQWidget *KommanderFactory::create( TQIODevice *dev, TQObject *connector, TQWidg
if ( !connections.isNull() )
widgetFactory->loadConnections( connections, connector );
- if ( w && name && qstrlen( name ) > 0 )
+ if ( w && name && tqstrlen( name ) > 0 )
w->setName( name );
if ( !tabOrder.isNull() )
@@ -251,24 +254,24 @@ TQWidget *KommanderFactory::create( TQIODevice *dev, TQObject *connector, TQWidg
if ( widgetFactory->toplevel ) {
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
TQMap<TQWidget*, SqlWidgetConnection>::Iterator cit = widgetFactory->sqlWidgetConnections.begin();
for( ; cit != widgetFactory->sqlWidgetConnections.end(); ++cit ) {
- if ( widgetFactory->noDatabaseWidgets.find( cit.key()->name() ) != widgetFactory->noDatabaseWidgets.end() )
+ if ( widgetFactory->noDatabaseWidgets.tqfind( cit.key()->name() ) != widgetFactory->noDatabaseWidgets.end() )
continue;
- if ( cit.key()->inherits( "QDesignerDataBrowser2" ) )
- ( (QDesignerDataBrowser2*)cit.key() )->initPreview( (*cit).conn, (*cit).table, cit.key(), *(*cit).dbControls );
- else if ( cit.key()->inherits( "QDesignerDataView2" ) )
- ( (QDesignerDataView2*)cit.key() )->initPreview( (*cit).conn, (*cit).table, cit.key(), *(*cit).dbControls );
+ if ( cit.key()->inherits( "TQDesignerDataBrowser2" ) )
+ ( (TQDesignerDataBrowser2*)cit.key() )->initPreview( (*cit).conn, (*cit).table, cit.key(), *(*cit).dbControls );
+ else if ( cit.key()->inherits( "TQDesignerDataView2" ) )
+ ( (TQDesignerDataView2*)cit.key() )->initPreview( (*cit).conn, (*cit).table, cit.key(), *(*cit).dbControls );
}
for ( TQMap<TQString, TQStringList>::Iterator it = widgetFactory->dbTables.begin(); it != widgetFactory->dbTables.end(); ++it ) {
TQDataTable *table = (TQDataTable*)widgetFactory->toplevel->child( it.key(), TQDATATABLE_OBJECT_NAME_STRING );
if ( !table )
continue;
- if ( widgetFactory->noDatabaseWidgets.find( table->name() ) != widgetFactory->noDatabaseWidgets.end() )
+ if ( widgetFactory->noDatabaseWidgets.tqfind( table->name() ) != widgetFactory->noDatabaseWidgets.end() )
continue;
- TQValueList<Field> fieldMap = *widgetFactory->fieldMaps.find( table );
+ TQValueList<Field> fieldMap = *widgetFactory->fieldMaps.tqfind( table );
TQString conn = (*it)[ 0 ];
TQSqlCursor* c = 0;
TQSqlDatabase *db = 0;
@@ -307,129 +310,129 @@ void KommanderFactory::addPlugin( KommanderPlugin *plugin )
widgetPlugins.append( plugin );
}
-TQWidget *KommanderFactory::createWidget( const TQString &literalClassName, TQWidget *parent, const char *name )
+TQWidget *KommanderFactory::createWidget( const TQString &literalClassName, TQWidget *tqparent, const char *name )
{
TQString className = literalClassName;
// create widgets we know
if (className == TQPUSHBUTTON_OBJECT_NAME_STRING)
- return new TQPushButton(parent, name);
+ return new TQPushButton(tqparent, name);
else if (className == TQTOOLBUTTON_OBJECT_NAME_STRING)
- return new TQToolButton(parent, name);
+ return new TQToolButton(tqparent, name);
else if (className == TQCHECKBOX_OBJECT_NAME_STRING)
- return new TQCheckBox(parent, name);
+ return new TQCheckBox(tqparent, name);
else if (className == TQRADIOBUTTON_OBJECT_NAME_STRING)
- return new TQRadioButton(parent, name);
+ return new TQRadioButton(tqparent, name);
else if (className == TQGROUPBOX_OBJECT_NAME_STRING)
- return new TQGroupBox(parent, name);
+ return new TQGroupBox(tqparent, name);
else if (className == TQBUTTONGROUP_OBJECT_NAME_STRING)
- return new TQButtonGroup(parent, name);
+ return new TQButtonGroup(tqparent, name);
else if (className == TQICONVIEW_OBJECT_NAME_STRING)
{
-#if !defined(QT_NO_ICONVIEW)
- return new TQIconView(parent, name);
+#if !defined(TQT_NO_ICONVIEW)
+ return new TQIconView(tqparent, name);
#endif
}
else if (className == TQTABLE_OBJECT_NAME_STRING)
{
-#if !defined(QT_NO_TABLE)
- return new TQTable(parent, name);
+#if !defined(TQT_NO_TABLE)
+ return new TQTable(tqparent, name);
#endif
}
else if (className == TQLISTBOX_OBJECT_NAME_STRING)
- return new TQListBox(parent, name);
+ return new TQListBox(tqparent, name);
else if (className == TQLISTVIEW_OBJECT_NAME_STRING)
- return new TQListView(parent, name);
+ return new TQListView(tqparent, name);
else if (className == TQLINEEDIT_OBJECT_NAME_STRING)
- return new TQLineEdit(parent, name);
+ return new TQLineEdit(tqparent, name);
else if (className == TQSPINBOX_OBJECT_NAME_STRING)
- return new TQSpinBox(parent, name);
+ return new TQSpinBox(tqparent, name);
else if (className == TQMULTILINEEDIT_OBJECT_NAME_STRING)
- return new TQMultiLineEdit(parent, name);
+ return new TQMultiLineEdit(tqparent, name);
else if (className == TQLABEL_OBJECT_NAME_STRING)
- return new TQLabel(parent, name);
+ return new TQLabel(tqparent, name);
else if (className == TQLAYOUTWIDGET_OBJECT_NAME_STRING)
- return new TQWidget(parent, name);
+ return new TQWidget(tqparent, name);
else if (className == TQTABWIDGET_OBJECT_NAME_STRING)
- return new TQTabWidget(parent, name);
+ return new TQTabWidget(tqparent, name);
else if (className == TQCOMBOBOX_OBJECT_NAME_STRING)
- return new TQComboBox(false, parent, name);
+ return new TQComboBox(false, tqparent, name);
else if (className == TQWIDGET_OBJECT_NAME_STRING)
{
if (!qwf_stays_on_top)
- return new TQWidget(parent, name);
- return new TQWidget(parent, name, Qt::WStyle_StaysOnTop);
+ return new TQWidget(tqparent, name);
+ return new TQWidget(tqparent, name, TQt::WStyle_StaysOnTop);
}
else if (className == TQDIALOG_OBJECT_NAME_STRING)
{
if (!qwf_stays_on_top)
- return new TQDialog(parent, name);
- return new TQDialog(parent, name, false, Qt::WStyle_StaysOnTop);
+ return new TQDialog(tqparent, name);
+ return new TQDialog(tqparent, name, false, TQt::WStyle_StaysOnTop);
}
else if (className == TQWIZARD_OBJECT_NAME_STRING)
- return new TQWizard(parent, name);
+ return new TQWizard(tqparent, name);
else if (className == TQLCDNUMBER_OBJECT_NAME_STRING)
- return new TQLCDNumber(parent, name);
+ return new TQLCDNumber(tqparent, name);
else if (className == TQPROGRESSBAR_OBJECT_NAME_STRING)
- return new TQProgressBar(parent, name);
+ return new TQProgressBar(tqparent, name);
else if (className == TQTEXTVIEW_OBJECT_NAME_STRING)
- return new TQTextView(parent, name);
+ return new TQTextView(tqparent, name);
else if (className == TQTEXTBROWSER_OBJECT_NAME_STRING)
- return new TQTextBrowser(parent, name);
+ return new TQTextBrowser(tqparent, name);
else if (className == TQDIAL_OBJECT_NAME_STRING)
- return new TQDial(parent, name);
+ return new TQDial(tqparent, name);
else if (className == TQSLIDER_OBJECT_NAME_STRING)
- return new TQSlider(parent, name);
+ return new TQSlider(tqparent, name);
else if (className == TQFRAME_OBJECT_NAME_STRING)
- return new TQFrame(parent, name);
+ return new TQFrame(tqparent, name);
else if (className == TQSPLITTER_OBJECT_NAME_STRING)
- return new TQSplitter(parent, name);
+ return new TQSplitter(tqparent, name);
else if (className == "Line")
{
- TQFrame *f = new TQFrame(parent, name);
+ TQFrame *f = new TQFrame(tqparent, name);
f->setFrameStyle(TQFrame::HLine | TQFrame::Sunken);
return f;
}
else if (className == TQTEXTEDIT_OBJECT_NAME_STRING)
- return new TQTextEdit(parent, name);
+ return new TQTextEdit(tqparent, name);
else if (className == TQDATEEDIT_OBJECT_NAME_STRING)
- return new QDateEdit(parent, name);
+ return new TQDateEdit(tqparent, name);
else if (className == TQTIMEEDIT_OBJECT_NAME_STRING)
- return new QTimeEdit(parent, name);
+ return new TQTimeEdit(tqparent, name);
else if (className == TQDATETIMEEDIT_OBJECT_NAME_STRING)
- return new QDateTimeEdit(parent, name);
+ return new TQDateTimeEdit(tqparent, name);
else if (className == TQSCROLLBAR_OBJECT_NAME_STRING)
- return new TQScrollBar(parent, name);
+ return new TQScrollBar(tqparent, name);
else if (className == TQPOPUPMENU_OBJECT_NAME_STRING)
- return new TQPopupMenu(parent, name);
+ return new TQPopupMenu(tqparent, name);
else if (className == TQWIDGETSTACK_OBJECT_NAME_STRING)
- return new TQWidgetStack(parent, name);
+ return new TQWidgetStack(tqparent, name);
else if (className == TQMAINWINDOW_OBJECT_NAME_STRING)
{
TQMainWindow *mw = 0;
if (!qwf_stays_on_top)
- mw = new KmdrMainWindow(parent, name);
+ mw = new KmdrMainWindow(tqparent, name);
else
- mw = new KmdrMainWindow(parent, name, Qt::WType_TopLevel | Qt::WStyle_StaysOnTop);
+ mw = new KmdrMainWindow(tqparent, name, TQt::WType_TopLevel | TQt::WStyle_StaysOnTop);
mw->setCentralWidget(new TQWidget(mw, "qt_central_widget"));
mw->centralWidget()->show();
(void) mw->statusBar();
return mw;
}
-#if !defined(QT_NO_SQL)
+#if !defined(TQT_NO_SQL)
else if (className == TQDATATABLE_OBJECT_NAME_STRING)
- return new TQDataTable(parent, name);
+ return new TQDataTable(tqparent, name);
else if (className == TQDATABROWSER_OBJECT_NAME_STRING)
- return new QDesignerDataBrowser2(parent, name);
+ return new TQDesignerDataBrowser2(tqparent, name);
else if (className == TQDATAVIEW_OBJECT_NAME_STRING)
- return new QDesignerDataView2(parent, name);
+ return new TQDesignerDataView2(tqparent, name);
#endif
// try to create it using the loaded kommander widget plugins
//find the widget plugin which can create className
for (KommanderPlugin * p = widgetPlugins.first(); p; p = widgetPlugins.next())
{
- TQWidget *w = p->create(className, parent, name);
+ TQWidget *w = p->create(className, tqparent, name);
if (w)
return w;
}
@@ -494,7 +497,7 @@ FeatureList KommanderFactory::featureList()
//iterate through widgetPlugins, appending KommanderPlugin::widgets() to features
}
-TQWidget *KommanderFactory::createWidgetInternal( const TQDomElement &e, TQWidget *parent, TQLayout* layout, const TQString &classNameArg )
+TQWidget *KommanderFactory::createWidgetInternal( const TQDomElement &e, TQWidget *tqparent, TQLayout* tqlayout, const TQString &classNameArg )
{
lastItem = 0;
TQDomElement n = e.firstChild().toElement();
@@ -512,13 +515,13 @@ TQWidget *KommanderFactory::createWidgetInternal( const TQDomElement &e, TQWidge
if ( colspan < 1 )
colspan = 1;
if ( !className.isEmpty() ) {
- if ( !layout && className == TQLAYOUTWIDGET_OBJECT_NAME_STRING )
+ if ( !tqlayout && className == TQLAYOUTWIDGET_OBJECT_NAME_STRING )
className = TQWIDGET_OBJECT_NAME_STRING;
- if ( layout && className == TQLAYOUTWIDGET_OBJECT_NAME_STRING ) {
- // hide layout widgets
- w = parent;
+ if ( tqlayout && className == TQLAYOUTWIDGET_OBJECT_NAME_STRING ) {
+ // hide tqlayout widgets
+ w = tqparent;
} else {
- obj = KommanderFactory::createWidget( className, parent, 0 );
+ obj = TQT_TQOBJECT(KommanderFactory::createWidget( className, tqparent, 0 ));
if ( !obj )
{
return 0;
@@ -528,16 +531,16 @@ TQWidget *KommanderFactory::createWidgetInternal( const TQDomElement &e, TQWidge
toplevel = w;
if ( w->inherits( TQMAINWINDOW_OBJECT_NAME_STRING ) )
w = ( (TQMainWindow*)w )->centralWidget();
- if ( layout ) {
- switch( layoutType( layout ) ) {
+ if ( tqlayout ) {
+ switch( tqlayoutType( tqlayout ) ) {
case HBox:
- ( (TQHBoxLayout*)layout )->addWidget( w );
+ ( (TQHBoxLayout*)tqlayout )->addWidget( w );
break;
case VBox:
- ( (TQVBoxLayout*)layout )->addWidget( w );
+ ( (TQVBoxLayout*)tqlayout )->addWidget( w );
break;
case Grid:
- ( (TQGridLayout*)layout )->addMultiCellWidget( w, row, row + rowspan - 1,
+ ( (TQGridLayout*)tqlayout )->addMultiCellWidget( w, row, row + rowspan - 1,
col, col + colspan - 1 );
break;
default:
@@ -545,7 +548,7 @@ TQWidget *KommanderFactory::createWidgetInternal( const TQDomElement &e, TQWidge
}
}
- layout = 0;
+ tqlayout = 0;
}
}
if (className == "Dialog")
@@ -553,59 +556,59 @@ TQWidget *KommanderFactory::createWidgetInternal( const TQDomElement &e, TQWidge
while ( !n.isNull() ) {
if ( n.tagName() == "spacer" ) {
- createSpacer( n, layout );
+ createSpacer( n, tqlayout );
} else if ( n.tagName() == "widget" ) {
TQMap< TQString, TQString> *oldDbControls = dbControls;
- createWidgetInternal( n, w, layout, n.attribute( "class", TQWIDGET_OBJECT_NAME_STRING ) );
+ createWidgetInternal( n, w, tqlayout, n.attribute( "class", TQWIDGET_OBJECT_NAME_STRING ) );
dbControls = oldDbControls;
} else if ( n.tagName() == "hbox" ) {
- TQLayout *parentLayout = layout;
- if ( layout && layout->inherits( TQGRIDLAYOUT_OBJECT_NAME_STRING ) )
- layout = createLayout( 0, 0, KommanderFactory::HBox );
+ TQLayout *tqparentLayout = tqlayout;
+ if ( tqlayout && tqlayout->inherits( TQGRIDLAYOUT_OBJECT_NAME_STRING ) )
+ tqlayout = createLayout( 0, 0, KommanderFactory::HBox );
else
- layout = createLayout( w, layout, KommanderFactory::HBox );
- obj = layout;
+ tqlayout = createLayout( w, tqlayout, KommanderFactory::HBox );
+ obj = TQT_TQOBJECT(tqlayout);
n = n.firstChild().toElement();
- if ( parentLayout && parentLayout->inherits( TQGRIDLAYOUT_OBJECT_NAME_STRING ) )
- ( (TQGridLayout*)parentLayout )->addMultiCellLayout( layout, row, row + rowspan - 1, col, col + colspan - 1 );
+ if ( tqparentLayout && tqparentLayout->inherits( TQGRIDLAYOUT_OBJECT_NAME_STRING ) )
+ ( (TQGridLayout*)tqparentLayout )->addMultiCellLayout( tqlayout, row, row + rowspan - 1, col, col + colspan - 1 );
continue;
} else if ( n.tagName() == "grid" ) {
- TQLayout *parentLayout = layout;
- if ( layout && layout->inherits( TQGRIDLAYOUT_OBJECT_NAME_STRING ) )
- layout = createLayout( 0, 0, KommanderFactory::Grid );
+ TQLayout *tqparentLayout = tqlayout;
+ if ( tqlayout && tqlayout->inherits( TQGRIDLAYOUT_OBJECT_NAME_STRING ) )
+ tqlayout = createLayout( 0, 0, KommanderFactory::Grid );
else
- layout = createLayout( w, layout, KommanderFactory::Grid );
- obj = layout;
+ tqlayout = createLayout( w, tqlayout, KommanderFactory::Grid );
+ obj = TQT_TQOBJECT(tqlayout);
n = n.firstChild().toElement();
- if ( parentLayout && parentLayout->inherits( TQGRIDLAYOUT_OBJECT_NAME_STRING ) )
- ( (TQGridLayout*)parentLayout )->addMultiCellLayout( layout, row, row + rowspan - 1, col, col + colspan - 1 );
+ if ( tqparentLayout && tqparentLayout->inherits( TQGRIDLAYOUT_OBJECT_NAME_STRING ) )
+ ( (TQGridLayout*)tqparentLayout )->addMultiCellLayout( tqlayout, row, row + rowspan - 1, col, col + colspan - 1 );
continue;
} else if ( n.tagName() == "vbox" ) {
- TQLayout *parentLayout = layout;
- if ( layout && layout->inherits( TQGRIDLAYOUT_OBJECT_NAME_STRING ) )
- layout = createLayout( 0, 0, KommanderFactory::VBox );
+ TQLayout *tqparentLayout = tqlayout;
+ if ( tqlayout && tqlayout->inherits( TQGRIDLAYOUT_OBJECT_NAME_STRING ) )
+ tqlayout = createLayout( 0, 0, KommanderFactory::VBox );
else
- layout = createLayout( w, layout, KommanderFactory::VBox );
- obj = layout;
+ tqlayout = createLayout( w, tqlayout, KommanderFactory::VBox );
+ obj = TQT_TQOBJECT(tqlayout);
n = n.firstChild().toElement();
- if ( parentLayout && parentLayout->inherits( TQGRIDLAYOUT_OBJECT_NAME_STRING ) )
- ( (TQGridLayout*)parentLayout )->addMultiCellLayout( layout, row, row + rowspan - 1, col, col + colspan - 1 );
+ if ( tqparentLayout && tqparentLayout->inherits( TQGRIDLAYOUT_OBJECT_NAME_STRING ) )
+ ( (TQGridLayout*)tqparentLayout )->addMultiCellLayout( tqlayout, row, row + rowspan - 1, col, col + colspan - 1 );
continue;
} else if ( n.tagName() == "property" && obj ) {
setProperty( obj, n.attribute( "name" ), n.firstChild().toElement() );
} else if ( n.tagName() == "attribute" && w ) {
TQString attrib = n.attribute( "name" );
TQVariant v = DomTool::elementToVariant( n.firstChild().toElement(), TQVariant() );
- if ( parent->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) ) {
+ if ( tqparent->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) ) {
if ( attrib == "title" )
- ( (TQTabWidget*)parent )->insertTab( w, translate(v.toString()) );
+ ( (TQTabWidget*)tqparent )->insertTab( w, translate(v.toString()) );
} else
- if ( parent->inherits( TQTOOLBOX_OBJECT_NAME_STRING ) ) {
+ if ( tqparent->inherits( TQTOOLBOX_OBJECT_NAME_STRING ) ) {
if ( attrib == "label" )
- ( (TQToolBox*)parent )->addItem( w, translate(v.toString()) );
- }else if ( parent->inherits( TQWIZARD_OBJECT_NAME_STRING ) ) {
+ ( (TQToolBox*)tqparent )->addItem( w, translate(v.toString()) );
+ }else if ( tqparent->inherits( TQWIZARD_OBJECT_NAME_STRING ) ) {
if ( attrib == "title" )
- ( (TQWizard*)parent )->addPage( w, translate(v.toString()) );
+ ( (TQWizard*)tqparent )->addPage( w, translate(v.toString()) );
}
} else if ( n.tagName() == "item" ) {
createItem( n, w );
@@ -619,60 +622,60 @@ TQWidget *KommanderFactory::createWidgetInternal( const TQDomElement &e, TQWidge
return w;
}
-TQLayout *KommanderFactory::createLayout( TQWidget *widget, TQLayout* layout, LayoutType type )
+TQLayout *KommanderFactory::createLayout( TQWidget *widget, TQLayout* tqlayout, LayoutType type )
{
int spacing = defSpacing;
int margin = defMargin;
- if ( !layout && widget && widget->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) )
+ if ( !tqlayout && widget && widget->inherits( TQTABWIDGET_OBJECT_NAME_STRING ) )
widget = ((TQTabWidget*)widget)->currentPage();
- if ( !layout && widget && widget->inherits( TQTOOLBOX_OBJECT_NAME_STRING ) )
+ if ( !tqlayout && widget && widget->inherits( TQTOOLBOX_OBJECT_NAME_STRING ) )
widget = ((TQToolBox*)widget)->currentItem();
- if ( !layout && widget && widget->inherits( TQWIZARD_OBJECT_NAME_STRING ) )
+ if ( !tqlayout && widget && widget->inherits( TQWIZARD_OBJECT_NAME_STRING ) )
widget = ((TQWizard*)widget)->currentPage();
- if ( !layout && widget && widget->inherits( TQWIDGETSTACK_OBJECT_NAME_STRING ) )
+ if ( !tqlayout && widget && widget->inherits( TQWIDGETSTACK_OBJECT_NAME_STRING ) )
widget = ((TQWidgetStack*)widget)->visibleWidget();
- if ( !layout && widget && widget->inherits( TQGROUPBOX_OBJECT_NAME_STRING ) ) {
+ if ( !tqlayout && widget && widget->inherits( TQGROUPBOX_OBJECT_NAME_STRING ) ) {
TQGroupBox *gb = (TQGroupBox*)widget;
gb->setColumnLayout( 0, Qt::Vertical );
- gb->layout()->setMargin( 0 );
- gb->layout()->setSpacing( 0 );
+ gb->tqlayout()->setMargin( 0 );
+ gb->tqlayout()->setSpacing( 0 );
TQLayout *l;
switch ( type ) {
case HBox:
- l = new TQHBoxLayout( gb->layout() );
- l->setAlignment( Qt::AlignTop );
+ l = new TQHBoxLayout( gb->tqlayout() );
+ l->tqsetAlignment( TQt::AlignTop );
return l;
case VBox:
- l = new TQVBoxLayout( gb->layout(), spacing );
- l->setAlignment( Qt::AlignTop );
+ l = new TQVBoxLayout( gb->tqlayout(), spacing );
+ l->tqsetAlignment( TQt::AlignTop );
return l;
case Grid:
- l = new TQGridLayout( gb->layout() );
- l->setAlignment( Qt::AlignTop );
+ l = new TQGridLayout( gb->tqlayout() );
+ l->tqsetAlignment( TQt::AlignTop );
return l;
default:
return 0;
}
} else {
- if ( layout ) {
+ if ( tqlayout ) {
TQLayout *l;
switch ( type ) {
case HBox:
- l = new TQHBoxLayout( layout );
+ l = new TQHBoxLayout( tqlayout );
l->setSpacing( spacing );
l->setMargin( margin );
return l;
case VBox:
- l = new TQVBoxLayout( layout );
+ l = new TQVBoxLayout( tqlayout );
l->setSpacing( spacing );
l->setMargin( margin );
return l;
case Grid: {
- l = new TQGridLayout( layout );
+ l = new TQGridLayout( tqlayout );
l->setSpacing( spacing );
l->setMargin( margin );
return l;
@@ -712,26 +715,26 @@ TQLayout *KommanderFactory::createLayout( TQWidget *widget, TQLayout* layout, L
}
}
-KommanderFactory::LayoutType KommanderFactory::layoutType( TQLayout *layout ) const
+KommanderFactory::LayoutType KommanderFactory::tqlayoutType( TQLayout *tqlayout ) const
{
- if ( layout->inherits( TQHBOXLAYOUT_OBJECT_NAME_STRING ) )
+ if ( tqlayout->inherits( TQHBOXLAYOUT_OBJECT_NAME_STRING ) )
return HBox;
- else if ( layout->inherits( TQVBOXLAYOUT_OBJECT_NAME_STRING ) )
+ else if ( tqlayout->inherits( TQVBOXLAYOUT_OBJECT_NAME_STRING ) )
return VBox;
- else if ( layout->inherits( TQGRIDLAYOUT_OBJECT_NAME_STRING ) )
+ else if ( tqlayout->inherits( TQGRIDLAYOUT_OBJECT_NAME_STRING ) )
return Grid;
return NoLayout;
}
void KommanderFactory::setProperty( TQObject* obj, const TQString &prop, const TQDomElement &e )
{
- const TQMetaProperty *p = obj->metaObject()->property( obj->metaObject()->findProperty( prop, true ), true );
+ const TQMetaProperty *p = obj->tqmetaObject()->property( obj->tqmetaObject()->tqfindProperty( prop, true ), true );
TQVariant defVariant;
if ( e.tagName() == "font" ) {
- TQFont f( qApp->font() );
- if ( obj->isWidgetType() && ( (TQWidget*)obj )->parentWidget() )
- f = ( (TQWidget*)obj )->parentWidget()->font();
+ TQFont f( tqApp->font() );
+ if ( obj->isWidgetType() && ( (TQWidget*)obj )->tqparentWidget() )
+ f = ( (TQWidget*)obj )->tqparentWidget()->font();
defVariant = TQVariant( f );
}
@@ -763,7 +766,7 @@ void KommanderFactory::setProperty( TQObject* obj, const TQString &prop, const T
if ( !v.toString().isEmpty() )
TQWhatsThis::add( (TQWidget*)obj, translate(v.toString()) );
}
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
if ( prop == "database" && !obj->inherits( TQDATAVIEW_OBJECT_NAME_STRING )
&& !obj->inherits( TQDATABROWSER_OBJECT_NAME_STRING ) ) {
TQStringList lst = DomTool::elementToVariant( e, TQVariant( TQStringList() ) ).toStringList();
@@ -789,8 +792,8 @@ void KommanderFactory::setProperty( TQObject* obj, const TQString &prop, const T
noDatabaseWidgets << obj->name();
}
} else if ( prop == "buttonGroupId" ) {
- if ( obj->inherits( TQBUTTON_OBJECT_NAME_STRING ) && obj->parent()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) )
- ( (TQButtonGroup*)obj->parent() )->insert( (TQButton*)obj, v.toInt() );
+ if ( obj->inherits( TQBUTTON_OBJECT_NAME_STRING ) && obj->tqparent()->inherits( TQBUTTONGROUP_OBJECT_NAME_STRING ) )
+ ( (TQButtonGroup*)obj->tqparent() )->insert( (TQButton*)obj, v.toInt() );
}
return;
@@ -828,7 +831,7 @@ void KommanderFactory::setProperty( TQObject* obj, const TQString &prop, const T
}
if ( prop == "geometry" ) {
- if ( obj == toplevel ) {
+ if ( TQT_BASE_OBJECT(obj) == TQT_BASE_OBJECT(toplevel) ) {
toplevel->resize( v.toRect().size() );
return;
}
@@ -837,7 +840,7 @@ void KommanderFactory::setProperty( TQObject* obj, const TQString &prop, const T
obj->setProperty( prop, v );
}
-void KommanderFactory::createSpacer( const TQDomElement &e, TQLayout *layout )
+void KommanderFactory::createSpacer( const TQDomElement &e, TQLayout *tqlayout )
{
TQDomElement n = e.firstChild().toElement();
int row = e.attribute( "row" ).toInt();
@@ -869,7 +872,7 @@ void KommanderFactory::createSpacer( const TQDomElement &e, TQLayout *layout )
sizeType = TQSizePolicy::MinimumExpanding;
else if ( n.firstChild().firstChild().toText().data() == "Expanding" )
sizeType = TQSizePolicy::Expanding;
- } else if ( prop == "sizeHint" ) {
+ } else if ( prop == "tqsizeHint" ) {
w = n.firstChild().firstChild().firstChild().toText().data().toInt();
h = n.firstChild().firstChild().nextSibling().firstChild().toText().data().toInt();
}
@@ -883,12 +886,12 @@ void KommanderFactory::createSpacer( const TQDomElement &e, TQLayout *layout )
colspan = 1;
TQSpacerItem *item = new TQSpacerItem( w, h, orient == Qt::Horizontal ? sizeType : TQSizePolicy::Minimum,
orient == Qt::Vertical ? sizeType : TQSizePolicy::Minimum );
- if ( layout ) {
- if ( layout->inherits( TQBOXLAYOUT_OBJECT_NAME_STRING ) )
- ( (TQBoxLayout*)layout )->addItem( item );
+ if ( tqlayout ) {
+ if ( tqlayout->inherits( TQBOXLAYOUT_OBJECT_NAME_STRING ) )
+ ( (TQBoxLayout*)tqlayout )->addItem( item );
else
- ( (TQGridLayout*)layout )->addMultiCell( item, row, row + rowspan - 1, col, col + colspan - 1,
- orient == Qt::Horizontal ? Qt::AlignVCenter : Qt::AlignHCenter );
+ ( (TQGridLayout*)tqlayout )->addMultiCell( item, row, row + rowspan - 1, col, col + colspan - 1,
+ orient == Qt::Horizontal ? TQt::AlignVCenter : TQt::AlignHCenter );
}
}
@@ -1004,7 +1007,7 @@ struct Connection
}
};
-class NormalizeObject : public QObject
+class NormalizeObject : public TQObject
{
public:
NormalizeObject() : TQObject() {}
@@ -1023,7 +1026,7 @@ void KommanderFactory::loadConnections( const TQDomElement &e, TQObject *connect
if ( n2.tagName() == "sender" ) {
TQString name = n2.firstChild().toText().data();
if ( name == "this" || qstrcmp( toplevel->name(), name ) == 0 ) {
- conn.sender = toplevel;
+ conn.sender = TQT_TQOBJECT(toplevel);
} else {
if ( name == "this" )
name = toplevel->name();
@@ -1041,7 +1044,7 @@ void KommanderFactory::loadConnections( const TQDomElement &e, TQObject *connect
} else if ( n2.tagName() == "receiver" ) {
TQString name = n2.firstChild().toText().data();
if ( name == "this" || qstrcmp( toplevel->name(), name ) == 0 ) {
- conn.receiver = toplevel;
+ conn.receiver = TQT_TQOBJECT(toplevel);
} else {
TQObjectList *l = toplevel->queryList( 0, name, false );
if ( l ) {
@@ -1062,7 +1065,7 @@ void KommanderFactory::loadConnections( const TQDomElement &e, TQObject *connect
TQObject *sender = 0, *receiver = 0;
TQObjectList *l = toplevel->queryList( 0, conn.sender->name(), false );
if ( qstrcmp( conn.sender->name(), toplevel->name() ) == 0 ) {
- sender = toplevel;
+ sender = TQT_TQOBJECT(toplevel);
} else {
if ( !l || !l->first() ) {
delete l;
@@ -1076,7 +1079,7 @@ void KommanderFactory::loadConnections( const TQDomElement &e, TQObject *connect
sender = findAction( conn.sender->name() );
if ( qstrcmp( conn.receiver->name(), toplevel->name() ) == 0 ) {
- receiver = toplevel;
+ receiver = TQT_TQOBJECT(toplevel);
} else {
l = toplevel->queryList( 0, conn.receiver->name(), false );
if ( !l || !l->first() ) {
@@ -1090,22 +1093,22 @@ void KommanderFactory::loadConnections( const TQDomElement &e, TQObject *connect
if ( lang == "C++" ) {
TQString s = "2""%1";
- s = s.arg( conn.signal );
+ s = s.tqarg( conn.signal.data() );
TQString s2 = "1""%1";
- s2 = s2.arg( conn.slot );
+ s2 = s2.tqarg( conn.slot.data() );
- TQStrList signalList = sender->metaObject()->signalNames( true );
- TQStrList slotList = receiver->metaObject()->slotNames( true );
+ TQStrList signalList = sender->tqmetaObject()->signalNames( true );
+ TQStrList slotList = receiver->tqmetaObject()->slotNames( true );
// if this is a connection to a custom slot and we have a connector, try this as receiver
- if ( slotList.find( conn.slot ) == -1 && receiver == toplevel && connector ) {
- slotList = connector->metaObject()->slotNames( true );
+ if ( slotList.tqfind( conn.slot ) == -1 && TQT_BASE_OBJECT(receiver) == TQT_BASE_OBJECT(toplevel) && connector ) {
+ slotList = connector->tqmetaObject()->slotNames( true );
receiver = connector;
}
// avoid warnings
- if ( signalList.find( conn.signal ) == -1 ||
- slotList.find( conn.slot ) == -1 ) {
+ if ( signalList.tqfind( conn.signal ) == -1 ||
+ slotList.tqfind( conn.slot ) == -1 ) {
n = n.nextSibling().toElement();
continue;
}
@@ -1114,11 +1117,11 @@ void KommanderFactory::loadConnections( const TQDomElement &e, TQObject *connect
EventFunction ef = eventMap[ conn.sender ];
ef.events.append( conn.signal );
ef.functions.append( TQStringList::split( ',', conn.slot ) );
- eventMap.replace( conn.sender, ef );
+ eventMap.tqreplace( conn.sender, ef );
}
} else if ( n.tagName() == "slot" ) {
TQString s = n.firstChild().toText().data();
- languageSlots.insert( s.left( s.find( "(" ) ) , n.attribute( "language" ) );
+ languageSlots.insert( s.left( s.tqfind( "(" ) ) , n.attribute( "language" ) );
}
n = n.nextSibling().toElement();
}
@@ -1181,17 +1184,17 @@ void KommanderFactory::createColumn( const TQDomElement &e, TQWidget *widget )
if ( !resizeable )
lv->header()->setResizeEnabled( resizeable, i );
}
-#ifndef QT_NO_TABLE
+#ifndef TQT_NO_TABLE
else if ( widget->inherits( TQTABLE_OBJECT_NAME_STRING ) ) {
TQTable *table = (TQTable*)widget;
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
bool isSql = (widget->inherits( TQDATATABLE_OBJECT_NAME_STRING ));
#endif
bool isRow;
if ( ( isRow = e.tagName() == "row" ) )
table->setNumRows( table->numRows() + 1 );
else {
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
if ( !isSql )
#endif
table->setNumCols( table->numCols() + 1 );
@@ -1203,8 +1206,8 @@ void KommanderFactory::createColumn( const TQDomElement &e, TQWidget *widget )
TQString txt;
TQString field;
TQValueList<Field> fieldMap;
- if ( fieldMaps.find( table ) != fieldMaps.end() ) {
- fieldMap = *fieldMaps.find( table );
+ if ( fieldMaps.tqfind( table ) != fieldMaps.end() ) {
+ fieldMap = *fieldMaps.tqfind( table );
fieldMaps.remove( table );
}
while ( !n.isNull() ) {
@@ -1226,14 +1229,14 @@ void KommanderFactory::createColumn( const TQDomElement &e, TQWidget *widget )
int i = isRow ? table->numRows() - 1 : table->numCols() - 1;
TQHeader *h = !isRow ? table->horizontalHeader() : table->verticalHeader();
if ( hasPixmap ) {
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
if ( isSql )
((TQDataTable*)table)->addColumn( field, txt, -1, pix );
else
#endif
h->setLabel( i, pix, txt );
} else {
-#ifndef QT_NO_SQL
+#ifndef TQT_NO_SQL
if ( isSql ) {
((TQDataTable*)table)->addColumn( field, txt );
}
@@ -1286,7 +1289,7 @@ void KommanderFactory::createItem( const TQDomElement &e, TQWidget *widget, TQLi
} else {
new TQListBoxText( lb, txt );
}
-#ifndef QT_NO_ICONVIEW
+#ifndef TQT_NO_ICONVIEW
} else if ( widget->inherits( TQICONVIEW_OBJECT_NAME_STRING ) ) {
TQDomElement n = e.firstChild().toElement();
TQPixmap pix;
@@ -1341,13 +1344,13 @@ void KommanderFactory::createItem( const TQDomElement &e, TQWidget *widget, TQLi
-void KommanderFactory::loadChildAction( TQObject *parent, const TQDomElement &e )
+void KommanderFactory::loadChildAction( TQObject *tqparent, const TQDomElement &e )
{
TQDomElement n = e;
TQAction *a = 0;
EventFunction ef;
if ( n.tagName() == "action" ) {
- a = new TQAction( parent );
+ a = new TQAction( tqparent );
TQDomElement n2 = n.firstChild().toElement();
while ( !n2.isNull() ) {
if ( n2.tagName() == "property" ) {
@@ -1358,10 +1361,10 @@ void KommanderFactory::loadChildAction( TQObject *parent, const TQDomElement &e
}
n2 = n2.nextSibling().toElement();
}
- if ( !parent->inherits( TQACTION_OBJECT_NAME_STRING ) )
+ if ( !tqparent->inherits( TQACTION_OBJECT_NAME_STRING ) )
actionList.append( a );
} else if ( n.tagName() == "actiongroup" ) {
- a = new TQActionGroup( parent );
+ a = new TQActionGroup( tqparent );
TQDomElement n2 = n.firstChild().toElement();
while ( !n2.isNull() ) {
if ( n2.tagName() == "property" ) {
@@ -1375,7 +1378,7 @@ void KommanderFactory::loadChildAction( TQObject *parent, const TQDomElement &e
}
n2 = n2.nextSibling().toElement();
}
- if ( !parent->inherits( TQACTION_OBJECT_NAME_STRING ) )
+ if ( !tqparent->inherits( TQACTION_OBJECT_NAME_STRING ) )
actionList.append( a );
}
if ( a )
@@ -1387,9 +1390,9 @@ void KommanderFactory::loadActions( const TQDomElement &e )
TQDomElement n = e.firstChild().toElement();
while ( !n.isNull() ) {
if ( n.tagName() == "action" ) {
- loadChildAction( toplevel, n );
+ loadChildAction( TQT_TQOBJECT(toplevel), n );
} else if ( n.tagName() == "actiongroup" ) {
- loadChildAction( toplevel, n );
+ loadChildAction( TQT_TQOBJECT(toplevel), n );
}
n = n.nextSibling().toElement();
}
@@ -1402,8 +1405,8 @@ void KommanderFactory::loadToolBars( const TQDomElement &e )
TQToolBar *tb = 0;
while ( !n.isNull() ) {
if ( n.tagName() == "toolbar" ) {
- Qt::Dock dock = (Qt::Dock)n.attribute( "dock" ).toInt();
- tb = new TQToolBar( TQString::null, mw, dock );
+ TQt::Dock dock = (TQt::Dock)n.attribute( "dock" ).toInt();
+ tb = new TQToolBar( TQString(), mw, dock );
tb->setLabel( n.attribute( "label" ) );
tb->setName( n.attribute( "name" ) );
TQDomElement n2 = n.firstChild().toElement();
@@ -1417,7 +1420,7 @@ void KommanderFactory::loadToolBars( const TQDomElement &e )
} else if ( n2.tagName() == "widget" ) {
(void)createWidgetInternal( n2, tb, 0, n2.attribute( "class", TQWIDGET_OBJECT_NAME_STRING ) );
} else if ( n2.tagName() == "property" ) {
- setProperty( tb, n2.attribute( "name" ), n2.firstChild().toElement() );
+ setProperty( TQT_TQOBJECT(tb), n2.attribute( "name" ), n2.firstChild().toElement() );
}
n2 = n2.nextSibling().toElement();
}
@@ -1448,7 +1451,7 @@ void KommanderFactory::loadMenuBar( const TQDomElement &e )
}
mb->insertItem( translate( n.attribute( "text" ) ), popup );
} else if ( n.tagName() == "property" ) {
- setProperty( mb, n.attribute( "name" ), n.firstChild().toElement() );
+ setProperty( TQT_TQOBJECT(mb), n.attribute( "name" ), n.firstChild().toElement() );
}
n = n.nextSibling().toElement();
}
diff --git a/kommander/factory/kommanderfactory.h b/kommander/factory/kommanderfactory.h
index ba3d7744..147749c2 100644
--- a/kommander/factory/kommanderfactory.h
+++ b/kommander/factory/kommanderfactory.h
@@ -1,7 +1,7 @@
/**********************************************************************
** Copyright (C) 2000 Trolltech AS. All rights reserved.
**
-** This file is part of Qt Designer.
+** This file is part of TQt Designer.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
@@ -42,7 +42,7 @@ class KommanderPlugin;
struct KommanderWidgetInfo
{
KommanderWidgetInfo() {}
- KommanderWidgetInfo( const TQString &g, const TQString &t, TQIconSet *i, const TQString &w = TQString::null, bool c = FALSE )
+ KommanderWidgetInfo( const TQString &g, const TQString &t, TQIconSet *i, const TQString &w = TQString(), bool c = FALSE )
: group( g ), toolTip( t ), iconSet(i), whatsThis( w ), isContainer( c )
{
}
@@ -60,13 +60,13 @@ public:
KommanderFactory();
virtual ~KommanderFactory();
- static TQWidget *create( const TQString &uiFile, TQObject *connector = 0, TQWidget *parent = 0, const char *name = 0 );
- static TQWidget *create( TQIODevice *dev, TQObject *connector = 0, TQWidget *parent = 0, const char *name = 0 );
+ static TQWidget *create( const TQString &uiFile, TQObject *connector = 0, TQWidget *tqparent = 0, const char *name = 0 );
+ static TQWidget *create( TQIODevice *dev, TQObject *connector = 0, TQWidget *tqparent = 0, const char *name = 0 );
static int loadPlugins( bool force = FALSE );
static void addPlugin( KommanderPlugin *plugin );
static void loadImages( const TQString &dir );
- static TQWidget *createWidget( const TQString &className, TQWidget *parent, const char *name );
+ static TQWidget *createWidget( const TQString &className, TQWidget *tqparent, const char *name );
static FeatureList featureList();
private:
@@ -74,18 +74,18 @@ private:
void loadImageCollection( const TQDomElement &e );
void loadConnections( const TQDomElement &e, TQObject *connector );
void loadTabOrder( const TQDomElement &e );
- TQWidget *createWidgetInternal( const TQDomElement &e, TQWidget *parent, TQLayout* layout, const TQString &classNameArg );
- TQLayout *createLayout( TQWidget *widget, TQLayout* layout, LayoutType type );
- LayoutType layoutType( TQLayout *l ) const;
+ TQWidget *createWidgetInternal( const TQDomElement &e, TQWidget *tqparent, TQLayout* tqlayout, const TQString &classNameArg );
+ TQLayout *createLayout( TQWidget *widget, TQLayout* tqlayout, LayoutType type );
+ LayoutType tqlayoutType( TQLayout *l ) const;
void setProperty( TQObject* widget, const TQString &prop, const TQDomElement &e );
- void createSpacer( const TQDomElement &e, TQLayout *layout );
+ void createSpacer( const TQDomElement &e, TQLayout *tqlayout );
TQImage loadFromCollection( const TQString &name );
TQPixmap loadPixmap( const TQDomElement &e );
TQColorGroup loadColorGroup( const TQDomElement &e );
void createColumn( const TQDomElement &e, TQWidget *widget );
void loadItem( const TQDomElement &e, TQPixmap &pix, TQString &txt, bool &hasPixmap );
void createItem( const TQDomElement &e, TQWidget *widget, TQListViewItem *i = 0 );
- void loadChildAction( TQObject *parent, const TQDomElement &e );
+ void loadChildAction( TQObject *tqparent, const TQDomElement &e );
void loadActions( const TQDomElement &e );
void loadToolBars( const TQDomElement &e );
void loadMenuBar( const TQDomElement &e );
@@ -109,7 +109,7 @@ private:
TQString name;
TQPixmap pix;
TQString field;
-#if defined(Q_FULL_TEMPLATE_INSTANTIATION)
+#if defined(TQ_FULL_TEMPLATE_INSTANTIATION)
bool operator==( const Field& ) const { return FALSE; }
#endif
};
diff --git a/kommander/kmdrtools/dcoptool-oldparser.kmdr b/kommander/kmdrtools/dcoptool-oldparser.kmdr
index e6a8ec54..0cbf0f5d 100755
--- a/kommander/kmdrtools/dcoptool-oldparser.kmdr
+++ b/kommander/kmdrtools/dcoptool-oldparser.kmdr
@@ -61,7 +61,7 @@ openfiles(QString,QString,QString)")
associatedText(QString)
cellText(QString,int,int)
checked(QString)
-children(QString,bool)
+tqchildren(QString,bool)
clear(QString)
count(QString)
currentColumn(QString)
@@ -105,14 +105,14 @@ append(QString,QString)")
@setGlobal(KommanderMessage,"")
@setGlobal(String,"length(QString)
-contains(QString,QString)
-find(QString,QString,int)
-findRev(QString,QString,int)
+tqcontains(QString,QString)
+tqfind(QString,QString,int)
+tqfindRev(QString,QString,int)
left(QString,int)
right(QString,int)
mid(QString,int,int)
remove(QString,QString)
-replace(QString,QString,QString)
+tqreplace(QString,QString,QString)
upper(QString)
lower(QString)
compare(QString,QString)
@@ -131,7 +131,7 @@ args(QString,QString,QString,QString)")
<string></string>
</stringlist>
</property>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout9</cstring>
</property>
@@ -224,7 +224,7 @@ args(QString,QString,QString,QString)")
</stringlist>
</property>
</widget>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel4</cstring>
</property>
@@ -247,7 +247,7 @@ args(QString,QString,QString,QString)")
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout10</cstring>
</property>
@@ -269,7 +269,7 @@ args(QString,QString,QString,QString)")
<property name="spacing">
<number>6</number>
</property>
- <widget class="QLabel">
+ <widget class=TQLABEL_OBJECT_NAME_STRING>
<property name="name">
<cstring>TextLabel3</cstring>
</property>
@@ -326,7 +326,7 @@ args(QString,QString,QString,QString)")
</widget>
</vbox>
</widget>
- <widget class="QLayoutWidget">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING>
<property name="name">
<cstring>Layout11</cstring>
</property>
@@ -382,7 +382,7 @@ args(QString,QString,QString,QString)")
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>80</width>
<height>0</height>
@@ -400,9 +400,9 @@ args(QString,QString,QString,QString)")
<stringlist>
<string>@switch(@String.mid(@dcopstr.selection, 1, 4))
@case(dcop)
- @setGlobal("outstring","@dcopstr.selection @window.selection, @branch.selection, "@proto.selection", @String.mid(@wname.selection, 0, @String.find(@wname.selection, " ", ))@param1@param2@param3@param4)")
+ @setGlobal("outstring","@dcopstr.selection @window.selection, @branch.selection, "@proto.selection", @String.mid(@wname.selection, 0, @String.tqfind(@wname.selection, " ", ))@param1@param2@param3@param4)")
@case(cop)
- @setGlobal("outstring","@dcopstr.selection @window.selection @branch.selection @global(short) @String.mid(@wname.selection, 0, @String.find(@wname.selection, " ", ))@param1@param2@param3@param4")
+ @setGlobal("outstring","@dcopstr.selection @window.selection @branch.selection @global(short) @String.mid(@wname.selection, 0, @String.tqfind(@wname.selection, " ", ))@param1@param2@param3@param4")
@case(*)
@setGlobal("outstring","@dcopstr.selection - not found")
@end
@@ -443,7 +443,7 @@ args(QString,QString,QString,QString)")
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>120</width>
<height>0</height>
@@ -578,7 +578,7 @@ fi
</stringlist>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class=TQLABEL_OBJECT_NAME_STRING row="0" column="0">
<property name="name">
<cstring>TextLabel2</cstring>
</property>
@@ -594,7 +594,7 @@ fi
</item>
<item>
<property name="text">
- <string>"kmdr-executor-"+parentPid</string>
+ <string>"kmdr-executor-"+tqparentPid</string>
</property>
</item>
<property name="name">
@@ -645,9 +645,9 @@ fi
@end
@setGlobal(pdlg,@exec(kdialog --menu "Select a dialog other than pid @pid to parse" @global(kdlg)))
@#@exec(kdialog --msgbox "@global(_KDDIR)\n")
-@# dcop kmdr-executor-32730 KommanderIf children kmdr-executor-32730 1
+@# dcop kmdr-executor-32730 KommanderIf tqchildren kmdr-executor-32730 1
@wname.clear
-@setGlobal(items,@dcop(@global(pdlg), KommanderIf, "children(QString,bool)", @global(pdlg), 1 ))
+@setGlobal(items,@dcop(@global(pdlg), KommanderIf, "tqchildren(QString,bool)", @global(pdlg), 1 ))
@setGlobal(iwd,"")
@forEach(i, @global(items))
@setGlobal(iwd, "@global(iwd)@i (@dcop(@global(pdlg), KommanderIf, "type(QString)", @i))\n")
@@ -731,7 +731,7 @@ fi
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>111</width>
<height>0</height>
@@ -789,14 +789,14 @@ fi
@setGlobal(PARM4,"")
@setGlobal(short,checked)
@setGlobal(DESC,"Returns 1 for checked boxes, 0 for unchecked.")
-@case(DCOP::children(QString,bool))
+@case(DCOP::tqchildren(QString,bool))
@setGlobal(enWidget,1)
@setGlobal(PARM1,"recursive")
@setGlobal(PARM2,"")
@setGlobal(PARM3,"")
@setGlobal(PARM4,"")
- @setGlobal(short,children)
- @setGlobal(DESC,"Returns the list of child widgets contained in the parent widget. Set the &lt;i&gt;recursive&lt;/i&gt; parameter to &lt;i&gt;true&lt;/i&gt; to include widgets contained by child widgets.")
+ @setGlobal(short,tqchildren)
+ @setGlobal(DESC,"Returns the list of child widgets contained in the tqparent widget. Set the &lt;i&gt;recursive&lt;/i&gt; parameter to &lt;i&gt;true&lt;/i&gt; to include widgets contained by child widgets.")
@case(DCOP::clear(QString))
@setGlobal(enWidget,1)
@setGlobal(PARM1,"")
@@ -1117,14 +1117,14 @@ fi
@setGlobal(PARM4,"")
@setGlobal(short,dcopid)
@setGlobal(DESC,"Returns DCOP identifier of current process. This is shorthand for &lt;i&gt;kmdr-executor-&amp;#064;pid&lt;/i&gt;.")
-@case(Kommander::parentPid(QString,bool))
+@case(Kommander::tqparentPid(QString,bool))
@setGlobal(enWidget,1)
@setGlobal(PARM1,"editable")
@setGlobal(PARM2,"")
@setGlobal(PARM3,"")
@setGlobal(PARM4,"")
- @setGlobal(short,parentPid)
- @setGlobal(DESC,"Returns the pid of the parent Kommander window.")
+ @setGlobal(short,tqparentPid)
+ @setGlobal(DESC,"Returns the pid of the tqparent Kommander window.")
@case(Kommander::debug(QString))
@setGlobal(enWidget,0)
@setGlobal(PARM1,"text")
@@ -1276,7 +1276,7 @@ fi
@setGlobal(PARM3,"function")
@setGlobal(PARM4,"args")
@setGlobal(short,dcop)
- @setGlobal(DESC,"Creates a new widget with the specified type and as the child of parent.")
+ @setGlobal(DESC,"Creates a new widget with the specified type and as the child of tqparent.")
@case(Kommander::dcop(QString,QString,QString,QString))
@setGlobal(enWidget,0)
@setGlobal(PARM1,"id")
@@ -1445,29 +1445,29 @@ fi
@setGlobal(PARM4,"")
@setGlobal(short,length)
@setGlobal(DESC,"Returns number of chars in the string.")
-@case(String::contains(QString,QString))
+@case(String::tqcontains(QString,QString))
@setGlobal(enWidget,0)
@setGlobal(PARM1,"string")
@setGlobal(PARM2,"substring")
@setGlobal(PARM3,"")
@setGlobal(PARM4,"")
- @setGlobal(short,contains)
+ @setGlobal(short,tqcontains)
@setGlobal(DESC,"Checks if the the string contains the given substring.")
-@case(String::find(QString,QString,int))
+@case(String::tqfind(QString,QString,int))
@setGlobal(enWidget,0)
@setGlobal(PARM1,"string")
@setGlobal(PARM2,"sought")
@setGlobal(PARM3,"index")
@setGlobal(PARM4,"")
- @setGlobal(short,find)
+ @setGlobal(short,tqfind)
@setGlobal(DESC,"Returns the position of a substring in the string, or -1 if it is not found.")
-@case(String::findRev(QString,QString,int))
+@case(String::tqfindRev(QString,QString,int))
@setGlobal(enWidget,0)
@setGlobal(PARM1,"string")
@setGlobal(PARM2,"sought")
@setGlobal(PARM3,"index")
@setGlobal(PARM4,"")
- @setGlobal(short,findRev)
+ @setGlobal(short,tqfindRev)
@setGlobal(DESC,"Returns the position of a substring in the string, or -1 if it is not found. String is searched backwards")
@case(String::left(QString,int))
@setGlobal(enWidget,0)
@@ -1501,13 +1501,13 @@ fi
@setGlobal(PARM4,"")
@setGlobal(short,remove)
@setGlobal(DESC,"Removes all occurrences of given substring.")
-@case(String::replace(QString,QString,QString))
+@case(String::tqreplace(QString,QString,QString))
@setGlobal(enWidget,0)
@setGlobal(PARM1,"string")
@setGlobal(PARM2,"substring")
@setGlobal(PARM3,"replacement")
@setGlobal(PARM4,"")
- @setGlobal(short,replace)
+ @setGlobal(short,tqreplace)
@setGlobal(DESC,"Replaces all occurrences of the given substring with the given replacement.")
@case(String::upper(QString))
@setGlobal(enWidget,0)
@@ -1820,7 +1820,7 @@ fi
associatedText(QString)
cellText(QString,int,int)
checked(QString)
-children(QString,bool)
+tqchildren(QString,bool)
clear(QString)
count(QString)
currentColumn(QString)
@@ -1879,7 +1879,7 @@ setEditable(QString,bool)")
<property name="associations" stdset="0">
<stringlist>
<string>@##### put the following in @wfilter checked #########
-@setGlobal(start,@expr(@String.find("@wname.selection", " ")+2))
+@setGlobal(start,@expr(@String.tqfind("@wname.selection", " ")+2))
@setGlobal(stop,@expr(@String.length("@wname.selection")-1))
@setGlobal(length,@expr(@global(stop)-@global(start)))
@setGlobal(teststr, @String.lower(@String.mid("@wname.selection", @global(start), @global(length))))
@@ -2121,5 +2121,5 @@ setColumnCaption(QString,int,QString)")
<tabstop>window</tabstop>
<tabstop>widgetName</tabstop>
</tabstops>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/kmdrtools/examples.kmdr b/kommander/kmdrtools/examples.kmdr
index 4e63e80f..5d32d858 100755
--- a/kommander/kmdrtools/examples.kmdr
+++ b/kommander/kmdrtools/examples.kmdr
@@ -75,7 +75,7 @@ end
<number>0</number>
</property>
</widget>
- <widget class="QLayoutWidget" row="1" column="0">
+ <widget class=TQLAYOUTWIDGET_OBJECT_NAME_STRING row="1" column="0">
<property name="name">
<cstring>Layout90</cstring>
</property>
@@ -99,7 +99,7 @@ end
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>71</width>
<height>0</height>
@@ -134,7 +134,7 @@ endif</string>
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>71</width>
<height>0</height>
@@ -150,5 +150,5 @@ endif</string>
<data format="XPM.GZ" length="6350">789ca598d94f1fc911c7dff7af40db6faba877a667baa747511e8c01e3030c06cc11e5a1aa7a86cbdc603051fef734f5ad9fed5d2952a4f521fba3beeaae1a7eff6de9606b63e9b7df7fb9bba7fb53599213ba5dfaad3c5c5c7cfbe7bffef1ef5f7e0d61a9fee9425e0abffeed975fb7ef976469f3ea727a013f56708dfe7a61597069b372068729f6cabbe0dcc8acbc622c4599c1a10dad72f1ca5d1370bfc77d5dcb01e70770176252de51eebb1c21df96720c6d87f51edcd3202fec5e29a7c01dee3b541e43dfa9b2ee4699dbd88e2a0f2997861a5d97040ed441dfa83c776d8ff5a3176e9b466cff6be5b6ded7aabe07ca5d37f6f4c2f400ee1bc84f1f95fb2859d7654f39a6766495c729a7b66d3a5dc77d431fa2ca2b9f9573ecb2ae975999dafa80ae5f1a0f0df6ef83fb79507bf927701e65d0f39372b507cef3837102fb2be3a1d1fd1efb4b65f87f193c3454f4fcaaf294a3e8ba6b5e3834ed88f3a528b72d352a0fef1b33e4f5df9443655d776aefd02d582e94fb568c3be3b9813ddf2a577b6695df6d1bf3a8f662514eed64fa7c521e6a38ea79867c39b48dfa9f8e95c705fb1f0c79d55f8142d7a8feee1a9cbaacfafb013c24d8c7df29f398912fee8db2c431e17d562ea137ff41be52eda9f2ca15784c05f10e7da7ba5fe5e3afc6b1d1789333f0200cff6e2acf21415f4fc643837cd5f8ace99971de6bfe756d65bc770aee52d0f8e77be550d7555efe0c4e09f1e95ae52e8c382fe7e0ae4680aeef832345e4eb2a788cd08f351fbb18b8d1fc70deb858bee1be983bc67b9aef55ba453c6d1b4b8b7a73094e7d823d37c15944f575b7ca43985ae4f7163813d6f98b71417c7bd82b6766c8ff9d8bbe479a9fdd1826e8ef173c9bfc199c02e4f167e09c08f1fb4e9916e749c0718c6a0f817e9ce70279b5fe75656c0bce6bfdeea6b1401e79569ec750903fa7c65dd1f749fdd7b75d84bd68cf3899bc1d38ce51f7b3c64f1f6a81837f37c0fdd4e9fb45e3b9efbb01f6a457c6638bf7efc07966c4eb9a721c09fef7e0347403de3b048f52501fd51ffdd091f94beb479fc75c50bfb5fef463c7886f5f8ca5457d5a07f78dc973021e479ca76cccd6dfde1897a2f92cd7df19f9f200e66e02639d3a8b57ff15cc11eb1c94b9ea83fc1fc1d4a27ffa4730e709f9a9fda697b117f873dd7886bd44fb5b5f16e759e3a79faa01105ff7604eb8af683cf573df427fd27c8c4ddfc05ea2fe8b6dead0cfbcde17bb61863fc4836998d05fb53ebdb4e309f5f69371467cb1d6c318fb8c7940b41fc594ad3e8bda230ebdc59fc3f9816982fce7606967f85bf329e6aa2fcedf1a0f93dadbad19cf13f255e3258e6326f81ffa513fb6e89fc7600a45f38b5be3cee23119cf13ea9dc67be47a5edff747e034637e21cdafda0c09eb0c798426d88b36c1dc9a7c9067ea6dde7207e03a5ea01fdc1bd714d3f31a4f351bfb80fe7e011ed3a8f672cf606a102facf1949a7ec67d740fe61efef26aff3a8d7419f553e33d853a70a1bf6b7ca5eaff84fa7c09e63a10eafe689c2dbe351f534fc4e87f9b6066cb8ff7c613e291d4be29d6fc80fe97c684fda4fd28a52a0fe6870b70951ff1a5f99e061a11ffe2c0dfe5db302e33fa81ceaf29c7087bf30c1e53863c03b8ca83fa087dc6d8e37dbf0c669970df0765926646bdd478484c05eb0c7b72f537e261c738435fdf8317e77d671c26d85ffb7d7a891f5d27e823d59ee8075a8f53a9fae2fd2be31efa5334a609fd17f217e9cc7eda4fd2944a07be06d7fbd0efcf8c05e7a9372e789fb51ea5991bab072acfd04446fcc83b6369e1ff67e3a9457e9d825313109f5bc66d40fdd1fe31b4291beb7b43a8e7f57eeac0d2c05e148c5bc48fcbc619f6259d67872ece013c82ebf8827ab307ce92d45fa4fd63e853ead01fb51e0fb1be8f7e7108ce39a1be607fa49170ff07f0c29feec27898314f6bbd1952b4fc746aef614813be47dc399832a17edc81a5b7fcb9361e511f59fd33e4dabe21df93710c88e7b7e0fa3ee4d37a338ca9833dbc185bbde1c9389abd9e8d5340fdb835ce01f322de1f47ca8807cdf781d380fa4f2b0b0e88cf2fe03aeec1deb65fac5f11e247aaffd01fb4df0ea59e473eed826b3d417d867da6349a7c37c6847ac94fc605eb04f9a76a3fdc8ff89917e769d7d8ced3155826f88f35bf7293d8d64f8ca780786fc143d3a17e1b2fdea31b63863f44e325b7f53eb59fc77dede2bc4ce04c09f6d57a9043ae21a8f2ec81ab3de0ff75b0c80c7be1fe2e31fce1ee8d05f9e4eec0436bf1cee05a2f50ff347e725fc73bc4db7be301f2b947b044f467a7f37dfd9a317b91379e218f837e491af45fa7f3681eaaff11af3a0fe43c04c4179f82c5fa0d69bdafd3fae23eed8f99eb38827eb40c9638213ebf804b67fb35de6b3a0c01f543f3af0e2f09f586b51ee56960e4a3877c53e94d9fcbef8cefd7c138ce9897609f3a3d05f8e7192cd6df58e51fdb41ccde6b6059f40fad7f6390d1ea19f6f7b9ef313fbc06978cf748eb6ffd5a0ce66f9d6fea746cf313a93feab8dbf69837b57fd66c8df6f31331ce3df245fd33723d8ff96ad378b07eba62cc33ea95c6d72839a19ed2b231c11f74042ec9eedb3266c8ef57bf33ecadf5b54ebb56df48e38b9a2c3de637adb7d48e8dfdfca50117abaf7edf58709f68fda0900bf4753be0ba8efea7f580fa3ce1e73f746e3cf78897042ec5f455fd292e5834fe285579b05ffb130d63077fc9a371847d49e7833abd14bcef3e1acf33fa81e63351b507f24feb35f1d4d8bafabf7eac36789f35bfa88cf58341d7b57ed15426bb7f024f2dce93f6a33add2e58e781fa315d2750dd1fc153b0f7745eaa5f3b61c63ca1f5f4659a34d678abd3d382757eaa5f1fc6dbf7ffffefbfb6df3b4ffa2f7bf1c54ff57fb33ffe5ffbfdb13ff1a7fecc9ffb2ffec25ffa2b7fed6ffcadbff3f7fec17ff58ffee90ffbbff967ffca2ffbd77ec5affa35ffc6affbb7fe9d7fef3ff80dbfe93ffaadc57ebfed3ff91dbfebf7fc67bfef0ffca13ff28d6f7df09def7df4c90f3efb11fb9d77ce916327aeb8c9cdeed89db85377e6cedd1777e12edd95bb76377e5cc8ef6edd9dbb770feeab7b744fee5bfdfbec5eb965f7daadb855b7e6deb875f7f6677ddd3bf7de7d701b6eb3defed16db96df7c9edb85db7e73ebb7d77e00eddd18ffdae71ad0bae73bd8b2eb9c1e55a1e3cd5982426a15207cb998e7feca7133aa5333aa72f7441977445d77443b77447f7f4405fe9919ee81b3dd3abeffb97e935add02aadd11b5aa7b7f48eded307daa04dfa485bb44d9f68877669effbfecfb44f07744847d4504b813aea2952a297196964cf8e8999e587beb5384d3cf3319ff0299ff1397fe10bbee42bbee61bbee53bbee7871ff2f3577ee427fec6cffc8a97f935aff02aaff11b5ee7b7fc8edff307dee0cd9ff67fe42ddee64fbcc3bbbcc79f799f0ff8908fea44d372e08e7bae9f873fdb9f07ae9fbfe2c509098b4891496639961339953339972f72f1f37eb9942bb9961bb9953bb99707f92a8ff224dfe4595ed513cbf2fa8ff12c2bb22a6bf246d6e52d277927efe5836cc8a67c942dd9964fb2f3a7fdbbb2279f655f0ee4508ea491568274527bb8241924cbf8e77cf1a31f8b2faed40c2b5c84e652eaffa632ffa5fcfdcfdf7ff92f64b3cec5</data>
</image>
</images>
-<layoutdefaults spacing="6" margin="11"/>
+<tqlayoutdefaults spacing="6" margin="11"/>
</UI>
diff --git a/kommander/part/kommander_part.cpp b/kommander/part/kommander_part.cpp
index d8645bc9..58912dd9 100644
--- a/kommander/part/kommander_part.cpp
+++ b/kommander/part/kommander_part.cpp
@@ -33,13 +33,13 @@ typedef KParts::GenericFactory<KommanderPart> KommanderPartFactory;
K_EXPORT_COMPONENT_FACTORY( libkommander_part, KommanderPartFactory )
-KommanderPart::KommanderPart( TQWidget *parentWidget, const char * /*widgetName*/,
- TQObject *parent, const char *name, const TQStringList & /*args*/ )
- : KParts::ReadOnlyPart(parent, name)
+KommanderPart::KommanderPart( TQWidget *tqparentWidget, const char * /*widgetName*/,
+ TQObject *tqparent, const char *name, const TQStringList & /*args*/ )
+ : KParts::ReadOnlyPart(tqparent, name)
{
setInstance( KommanderPartFactory::instance() );
m_instance = 0L;
- m_widget = new TQWidget(parentWidget);
+ m_widget = new TQWidget(tqparentWidget);
setWidget(m_widget);
m_layout = new TQGridLayout(m_widget);
}
@@ -79,7 +79,7 @@ void KommanderPart::slotRun()
{
w->reparent(m_widget, 0, TQPoint(0,0));
m_layout->addWidget(w, 0, 0);
- w->show(); //show, not execute, so it doesn't block the parent
+ w->show(); //show, not execute, so it doesn't block the tqparent
}
}
diff --git a/kommander/part/kommander_part.h b/kommander/part/kommander_part.h
index 1519f6c3..5e9fc4f5 100644
--- a/kommander/part/kommander_part.h
+++ b/kommander/part/kommander_part.h
@@ -24,9 +24,10 @@ class TQGridLayout;
class KommanderPart : public KParts::ReadOnlyPart
{
Q_OBJECT
+ TQ_OBJECT
public:
- KommanderPart(TQWidget *parentWidget, const char *widgetName,
- TQObject *parent, const char *name, const TQStringList &args);
+ KommanderPart(TQWidget *tqparentWidget, const char *widgetName,
+ TQObject *tqparent, const char *name, const TQStringList &args);
virtual ~KommanderPart();
diff --git a/kommander/plugin/kommanderplugin.h b/kommander/plugin/kommanderplugin.h
index d74abaa4..ae06fdc0 100644
--- a/kommander/plugin/kommanderplugin.h
+++ b/kommander/plugin/kommanderplugin.h
@@ -1,29 +1,29 @@
/****************************************************************************
- ** kommanderplugin.h - KommanderPlugin class definition created from QWidgetPlugin
+ ** kommanderplugin.h - KommanderPlugin class definition created from TQWidgetPlugin
** Copyright (C) 2001 Trolltech AS. All rights reserved.
** Copyright (C) 2003 Marc Britton
**
- ** This file is part of the widgets module of the Qt GUI Toolkit.
+ ** This file is part of the widgets module of the TQt GUI Toolkit.
**
** This file may be distributed under the terms of the Q Public License
** as defined by Trolltech AS of Norway and appearing in the file
- ** LICENSE.QPL included in the packaging of this file.
+ ** LICENSE.TQPL included in the packaging of this file.
**
** This file may be distributed and/or modified under the terms of the
** GNU General Public License version 2 as published by the Free Software
** Foundation and appearing in the file LICENSE.GPL included in the
** packaging of this file.
**
- ** Licensees holding valid Qt Enterprise Edition or Qt Professional Edition
- ** licenses may use this file in accordance with the Qt Commercial License
+ ** Licensees holding valid TQt Enterprise Edition or TQt Professional Edition
+ ** licenses may use this file in accordance with the TQt Commercial License
** Agreement provided with the Software.
**
** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** See http://www.trolltech.com/pricing.html or email sales@trolltech.com for
- ** information about Qt Commercial License Agreements.
- ** See http://www.trolltech.com/qpl/ for QPL licensing information.
+ ** information about TQt Commercial License Agreements.
+ ** See http://www.trolltech.com/qpl/ for TQPL licensing information.
** See http://www.trolltech.com/gpl/ for GPL licensing information.
**
** Contact info@trolltech.com if any conditions of this licensing are
@@ -45,15 +45,16 @@ class TQIconSet;
class KOMMANDER_EXPORT KommanderPlugin : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
KommanderPlugin();
~KommanderPlugin();
- virtual void addWidget( const TQString &name, const TQString &group, const TQString &toolTip, TQIconSet *iconSet, const TQString &whatsThis = TQString::null, bool isContainer = false);
+ virtual void addWidget( const TQString &name, const TQString &group, const TQString &toolTip, TQIconSet *iconSet, const TQString &whatsThis = TQString(), bool isContainer = false);
virtual void removeWidget( const TQString &name );
virtual TQStringList widgets() const;
- virtual TQWidget *create( const TQString &key, TQWidget *parent = 0, const char *name = 0 ) = 0;
+ virtual TQWidget *create( const TQString &key, TQWidget *tqparent = 0, const char *name = 0 ) = 0;
virtual TQString group( const TQString &key ) const;
virtual TQString toolTip( const TQString &key ) const;
virtual TQString whatsThis( const TQString &key ) const;
@@ -75,7 +76,7 @@ class KOMMANDER_EXPORT KommanderPlugin : public TQObject
* @param maxArgs maximum number of accepted arguments
* @return true if registration was successful
*/
- static bool registerFunction(int id, const TQString& function, const TQString description = TQString::null,
+ static bool registerFunction(int id, const TQString& function, const TQString description = TQString(),
int minArgs = -1, int maxArgs = -1);
@@ -84,7 +85,7 @@ private:
struct WidgetInfo
{
WidgetInfo() { }
- WidgetInfo( const TQString &g, const TQString &t, TQIconSet *i, const TQString &w = TQString::null, bool c = false)
+ WidgetInfo( const TQString &g, const TQString &t, TQIconSet *i, const TQString &w = TQString(), bool c = false)
: group( g ), toolTip( t ), iconSet(i), whatsThis( w ), isContainer( c )
{}
diff --git a/kommander/plugin/specialinformation.cpp b/kommander/plugin/specialinformation.cpp
index d6ed318b..bbfe308e 100644
--- a/kommander/plugin/specialinformation.cpp
+++ b/kommander/plugin/specialinformation.cpp
@@ -22,8 +22,8 @@ SpecialFunction::SpecialFunction(const TQString& name, const TQString& descripti
int minArgs, int maxArgs)
{
m_parserTypes = AllParsers;
- int lbracket = name.find('(');
- int rbracket = name.find(')');
+ int lbracket = name.tqfind('(');
+ int rbracket = name.tqfind(')');
m_function = (lbracket != -1) ? name.left(lbracket) : name;
m_description = description;
if (lbracket != -1 && rbracket != -1)
@@ -44,8 +44,8 @@ SpecialFunction::SpecialFunction(ParserType p, const TQString& name, const TQStr
int minArgs, int maxArgs)
{
m_parserTypes = p;
- int lbracket = name.find('(');
- int rbracket = name.find(')');
+ int lbracket = name.tqfind('(');
+ int rbracket = name.tqfind(')');
m_function = (lbracket != -1) ? name.left(lbracket) : name;
m_description = description;
if (lbracket != -1 && rbracket != -1)
@@ -71,15 +71,15 @@ TQString SpecialFunction::prototype(uint prototypeFlags) const
TQStringList params;
for (uint i=start; i<m_types.count(); i++)
if (prototypeFlags & ShowArgumentNames)
- params.append(TQString("%1 %2").arg(m_types[i]).arg(m_args[i]));
+ params.append(TQString("%1 %2").tqarg(m_types[i]).tqarg(m_args[i]));
else
params.append(m_types[i]);
if (!params.count())
return m_function;
else if (prototypeFlags & NoSpaces)
- return TQString("%1(%2)").arg(m_function).arg(params.join(","));
+ return TQString("%1(%2)").tqarg(m_function).tqarg(params.join(","));
else
- return TQString("%1(%2)").arg(m_function).arg(params.join(", "));
+ return TQString("%1(%2)").tqarg(m_function).tqarg(params.join(", "));
}
TQString SpecialFunction::argumentName(uint i) const
@@ -107,9 +107,9 @@ int SpecialFunction::argumentCount() const
int SpecialInformation::function(int group, const TQString& fname)
{
TQString f = fname.lower();
- if (m_functions.contains(group) && m_functions[group].contains(f))
+ if (m_functions.tqcontains(group) && m_functions[group].tqcontains(f))
return m_functions[group][f];
- else if (m_aliases.contains(group) && m_aliases[group].contains(f))
+ else if (m_aliases.tqcontains(group) && m_aliases[group].tqcontains(f))
return m_aliases[group][f];
return -1;
}
@@ -122,14 +122,14 @@ SpecialFunction SpecialInformation::functionObject(const TQString& gname, const
int SpecialInformation::group(const TQString& gname)
{
- if (m_groups.contains(gname))
+ if (m_groups.tqcontains(gname))
return m_groups[gname];
return -1;
}
bool SpecialInformation::isValid(int gname, int fname)
{
- return m_specials.contains(gname) && m_specials[gname].contains(fname);
+ return m_specials.tqcontains(gname) && m_specials[gname].tqcontains(fname);
}
bool SpecialInformation::isValid(const TQString& gname, const TQString& fname)
@@ -139,7 +139,7 @@ bool SpecialInformation::isValid(const TQString& gname, const TQString& fname)
bool SpecialInformation::isValid(int gname, int fname, SpecialFunction::ParserType p)
{
- return m_specials.contains(gname) && m_specials[gname].contains(fname)
+ return m_specials.tqcontains(gname) && m_specials[gname].tqcontains(fname)
&& m_specials[gname][fname].isSupported(p);
}
@@ -198,9 +198,9 @@ bool SpecialInformation::insert(int id, const TQString& function, const TQString
{
if (isValid(m_defaultGroup, id)) /* function already defined */
return false;
- if (m_functions[m_defaultGroup].contains(function.lower()))
+ if (m_functions[m_defaultGroup].tqcontains(function.lower()))
return false; /* function name already in use */
- if (m_aliases[m_defaultGroup].contains(function.lower()))
+ if (m_aliases[m_defaultGroup].tqcontains(function.lower()))
return false; /* function name already in use */
SpecialFunction sf(pType, function, description, minArgs, maxArgs);
m_specials[m_defaultGroup][id] = sf;
@@ -224,9 +224,9 @@ bool SpecialInformation::insertAlias(int id, const TQString& alias)
{
if (!isValid(m_defaultGroup, id)) /* function doesn't exists */
return false;
- if (m_functions[m_defaultGroup].contains(alias.lower()))
+ if (m_functions[m_defaultGroup].tqcontains(alias.lower()))
return false;
- if (m_aliases[m_defaultGroup].contains(alias.lower()))
+ if (m_aliases[m_defaultGroup].tqcontains(alias.lower()))
return false;
m_aliases[m_defaultGroup][alias] = id;
return true;
@@ -248,7 +248,7 @@ void SpecialInformation::insertGroup(int id, const TQString& name, const TQStrin
TQString SpecialInformation::parserGroupName(const TQString& name)
{
- if (m_parserGroups.contains(name))
+ if (m_parserGroups.tqcontains(name))
return m_parserGroups[name];
else
return name;
@@ -291,8 +291,8 @@ void SpecialInformation::registerSpecials()
i18n("Returns text of a cell in a table."), 3);
insert(DCOP::checked, "checked(TQString widget)",
i18n("Returns 1 for checked boxes, 0 for unchecked."), 1);
- insert(DCOP::children, "children(TQString widget, bool recursive)",
- i18n("Returns the list of child widgets contained in the parent widget. Set the <i>recursive</i> parameter to <i>true</i> to include widgets contained by child widgets."), 2);
+ insert(DCOP::tqchildren, "tqchildren(TQString widget, bool recursive)",
+ i18n("Returns the list of child widgets contained in the tqparent widget. Set the <i>recursive</i> parameter to <i>true</i> to include widgets contained by child widgets."), 2);
insert(DCOP::clear, "clear(TQString widget)",
i18n("Removes all content from the widget."), 1);
insertAlias(DCOP::clear, "clearList");
@@ -375,8 +375,8 @@ void SpecialInformation::registerSpecials()
i18n("Returns type(class) of widget."), 1);
insert(DCOP::setEditable, "setEditable(TQString widget, bool editable)",
i18n("Makes the widget editable or read only, depending on the editable argument."), 2);
- insertInternal(DCOP::geometry, "geometry(TQString widget)",
- i18n("Return the widget's geometry as <i>x y w h</i>. This is useful for positioning a created widget."), 1);
+ insertInternal(DCOP::tqgeometry, "tqgeometry(TQString widget)",
+ i18n("Return the widget's tqgeometry as <i>x y w h</i>. This is useful for positioning a created widget."), 1);
insertInternal(DCOP::hasFocus, "hasFocus(TQString widget)",
i18n("Returns true if the widget has focus."), 1);
insertInternal(DCOP::getBackgroundColor, "getBackgroundColor(TQString widget)",
@@ -400,8 +400,8 @@ void SpecialInformation::registerSpecials()
insert(Kommander::dcopid, "dcopid",
i18n("Returns DCOP identifier of current process. This is shorthand for <i>kmdr-executor-@pid</i>."),
0);
- insert(Kommander::parentPid, "parentPid",
- i18n("Returns the pid of the parent Kommander window."), 0);
+ insert(Kommander::tqparentPid, "tqparentPid",
+ i18n("Returns the pid of the tqparent Kommander window."), 0);
insert(Kommander::debug, "debug(TQString text)",
i18n("Writes <i>text</i> on stderr."), 1);
insert(Kommander::echo, "echo(TQString text)",
@@ -440,8 +440,8 @@ void SpecialInformation::registerSpecials()
i18n("Executes an external DCOP call."), 3, 9);
insertMacro(Kommander::comment, "#",
i18n("Adds a comment to EOL that Kommander will not parse"), 0);
- insertInternal(Kommander::createWidget, "createWidget(TQString widgetName, TQString widgetType, TQString parent)",
- i18n("Creates a new widget with the specified type and as the child of parent."), 3);
+ insertInternal(Kommander::createWidget, "createWidget(TQString widgetName, TQString widgetType, TQString tqparent)",
+ i18n("Creates a new widget with the specified type and as the child of tqparent."), 3);
insertInternal(Kommander::widgetExists, "widgetExists(TQString widgetName)",
i18n("Returns true if there is a widget with the passed name, false otherwise."), 1);
insertInternal(Kommander::connect, "connect(TQString sender, TQString signal, TQString receiver, TQString slot)",
@@ -524,11 +524,11 @@ void SpecialInformation::registerSpecials()
insertGroup(Group::String, "String", "str");
insert(String::length, "length(TQString string)",
i18n("Returns number of chars in the string."), 1);
- insert(String::contains, "contains(TQString string, TQString substring)",
+ insert(String::tqcontains, "tqcontains(TQString string, TQString substring)",
i18n("Checks if the the string contains the given substring."), 2);
- insert(String::find, "find(TQString string, TQString sought, int index)",
+ insert(String::tqfind, "tqfind(TQString string, TQString sought, int index)",
i18n("Returns the position of a substring in the string, or -1 if it is not found."), 2);
- insert(String::findRev, "findRev(TQString string, TQString sought, int index)",
+ insert(String::tqfindRev, "tqfindRev(TQString string, TQString sought, int index)",
i18n("Returns the position of a substring in the string, or -1 if it is not found. String is searched backwards"), 2);
insertInternal(String::count, "count(TQString String, TQString substring)",
i18n("Returns the count of a given substring in the given string."), 2);
@@ -540,7 +540,7 @@ void SpecialInformation::registerSpecials()
i18n("Returns <i>n</i> chars of the string, starting from <i>start</i>."), 3);
insert(String::remove, "remove(TQString string, TQString substring)",
i18n("Removes all occurrences of given substring."), 2);
- insert(String::replace, "replace(TQString string, TQString substring, TQString replacement)",
+ insert(String::tqreplace, "tqreplace(TQString string, TQString substring, TQString replacement)",
i18n("Replaces all occurrences of the given substring with the given replacement."), 3);
insert(String::upper, "upper(TQString string)",
i18n("Converts the string to uppercase."), 1);
diff --git a/kommander/plugin/specialinformation.h b/kommander/plugin/specialinformation.h
index fa898620..1ff00a6c 100644
--- a/kommander/plugin/specialinformation.h
+++ b/kommander/plugin/specialinformation.h
@@ -36,9 +36,9 @@ public:
/* Flags describing which parser supports the function */
enum ParserType {MacroParser = 1, InternalParser = 2, AllParsers = 3};
SpecialFunction(const TQString& function, const TQString& description
- = TQString::null, int minArgs = -1, int maxArgs = -1);
+ = TQString(), int minArgs = -1, int maxArgs = -1);
SpecialFunction(ParserType p, const TQString& function, const TQString& description
- = TQString::null, int minArgs = -1, int maxArgs = -1);
+ = TQString(), int minArgs = -1, int maxArgs = -1);
SpecialFunction() {m_minArgs = m_maxArgs = 0;}
/* minimum number of arguments */
int minArg() const {return m_minArgs;}
@@ -90,13 +90,13 @@ public:
static TQString description(int gname, int fname);
static TQString prototype(int gname, int fname, uint prototypeFlags = 0);
/* Insert function supported by all parsers */
- static bool insert(int id, const TQString& function, const TQString description = TQString::null,
+ static bool insert(int id, const TQString& function, const TQString description = TQString(),
int minArgs = -1, int maxArgs = -1, SpecialFunction::ParserType = SpecialFunction::AllParsers);
/* Insert function supported by (old) macro parser */
- static bool insertMacro(int id, const TQString& function, const TQString description = TQString::null,
+ static bool insertMacro(int id, const TQString& function, const TQString description = TQString(),
int minArgs = -1, int maxArgs = -1);
/* Insert function supported by (new) internal parser */
- static bool insertInternal(int id, const TQString& function, const TQString description = TQString::null,
+ static bool insertInternal(int id, const TQString& function, const TQString description = TQString(),
int minArgs = -1, int maxArgs = -1);
static bool insertAlias(int id, const TQString& alias);
static void insertGroup(int id, const TQString& name, const TQString& parserName);
diff --git a/kommander/plugin/specials.h b/kommander/plugin/specials.h
index 2d46200a..f7db7b6d 100644
--- a/kommander/plugin/specials.h
+++ b/kommander/plugin/specials.h
@@ -28,19 +28,19 @@ namespace Group
namespace DCOP
{
- enum {addUniqueItem, associatedText, cancel, cellText, clear, checked, children, columnCount, count, currentColumn,
+ enum {addUniqueItem, associatedText, cancel, cellText, clear, checked, tqchildren, columnCount, count, currentColumn,
currentItem, currentRow, execute, findItem, global, insertColumn, insertItem, insertItems, insertRow,
item, itemDepth, itemPath, removeColumn, removeItem, removeRow, selection, setAssociatedText, setChecked,
setCellText, setCurrentItem, insertTab, setColumnCaption, setEnabled, setGlobal, setMaximum, setPixmap,
setRowCaption, setSelection, setText, getBackgroundColor, setBackgroundColor,
- setVisible, text, type, setCellWidget, cellWidget, setEditable, geometry, hasFocus, isModified};
+ setVisible, text, type, setCellWidget, cellWidget, setEditable, tqgeometry, hasFocus, isModified};
}
namespace Kommander
{
- enum {widgetText, selectedWidgetText, null, pid, dcopid, parentPid, debug,
+ enum {widgetText, selectedWidgetText, null, pid, dcopid, tqparentPid, debug,
echo, env, exec, expr, global, i18n, dialog, readSetting, setGlobal, writeSetting, dcop,
- switchBlock, execBegin, forBlock, forEachBlock, ifBlock, comment, createWidget, connect, disconnect, widgetExists, exit, Break, Continue, Return, execBackground, switchInternal}; //, focusWidget};
+ switchBlock, execBegin, forBlock, forEachBlock, ifBlock, comment, createWidget, connect, disconnect, widgetExists, exit, Break, Continue, Return, execBackground, switchInternal}; //, tqfocusWidget};
}
namespace Array
@@ -55,7 +55,7 @@ namespace Matrix
namespace String
{
- enum {length, contains, find, findRev, left, right, mid, remove, replace, upper, lower,
+ enum {length, tqcontains, tqfind, tqfindRev, left, right, mid, remove, tqreplace, upper, lower,
compare, isEmpty, isNumber, section, args, toInt, toDouble, round, sort, trim, padLeft, padRight, count};
}
diff --git a/kommander/pluginmanager/main.cpp b/kommander/pluginmanager/main.cpp
index 74561925..0e663476 100644
--- a/kommander/pluginmanager/main.cpp
+++ b/kommander/pluginmanager/main.cpp
@@ -77,18 +77,18 @@ int main(int argc, char *argv[])
QCStringList items = args->getOptionList("add");
for (QCStringList::ConstIterator it = items.begin(); it != items.end(); ++it)
if (!P.add(*it))
- cerr << i18n("Error adding plugin '%1'").arg(*it).local8Bit();
+ cerr << i18n("Error adding plugin '%1'").tqarg((*it).data()).local8Bit().data();
items = args->getOptionList("remove");
for (QCStringList::ConstIterator it = items.begin(); it != items.end(); ++it)
if (!P.remove(*it))
- cerr << i18n("Error removing plugin '%1'").arg(*it).local8Bit();
+ cerr << i18n("Error removing plugin '%1'").tqarg((*it).data()).local8Bit().data();
if (args->isSet("list"))
{
TQStringList plugins = P.items();
for (TQStringList::ConstIterator it = plugins.begin(); it != plugins.end(); ++it)
- cout << (*it).local8Bit() << "\n";
+ cout << (*it).local8Bit().data() << "\n";
}
}
else
diff --git a/kommander/pluginmanager/mainwindow.cpp b/kommander/pluginmanager/mainwindow.cpp
index 94d365f5..c2947c5b 100644
--- a/kommander/pluginmanager/mainwindow.cpp
+++ b/kommander/pluginmanager/mainwindow.cpp
@@ -28,8 +28,8 @@
#include <kglobal.h>
#include <kstandarddirs.h>
-MainWindow::MainWindow( TQWidget* parent, const char *name, WFlags f )
- : KMainWindow( parent, name, f )
+MainWindow::MainWindow( TQWidget* tqparent, const char *name, WFlags f )
+ : KMainWindow( tqparent, name, f )
{
KToolBar *toolBar = new KToolBar( this );
toolBar->insertButton("fileopen", Add, true, i18n("Add") );
@@ -77,7 +77,7 @@ void MainWindow::add(const TQString &plugin)
{
if (!m_pluginManager->add(plugin))
{
- TQString errMsg = i18n("<qt>Unable to load Kommander plugin<br><b>%1</b></qt>").arg(plugin);
+ TQString errMsg = i18n("<qt>Unable to load Kommander plugin<br><b>%1</b></qt>").tqarg(plugin);
KMessageBox::error(this, errMsg, i18n("Cannot add plugin"));
}
else
diff --git a/kommander/pluginmanager/mainwindow.h b/kommander/pluginmanager/mainwindow.h
index c774832f..ffc59ace 100644
--- a/kommander/pluginmanager/mainwindow.h
+++ b/kommander/pluginmanager/mainwindow.h
@@ -26,8 +26,9 @@ class PluginManager;
class MainWindow : public KMainWindow
{
Q_OBJECT
+ TQ_OBJECT
public:
- MainWindow( TQWidget* parent = 0, const char *name = 0, WFlags f = WType_TopLevel | WDestructiveClose );
+ MainWindow( TQWidget* tqparent = 0, const char *name = 0, WFlags f = WType_TopLevel | WDestructiveClose );
~MainWindow();
protected slots:
diff --git a/kommander/pluginmanager/pluginmanager.cpp b/kommander/pluginmanager/pluginmanager.cpp
index 79da4d81..2bfbab89 100644
--- a/kommander/pluginmanager/pluginmanager.cpp
+++ b/kommander/pluginmanager/pluginmanager.cpp
@@ -47,7 +47,7 @@ bool PluginManager::add(const TQString& plugin, bool)
TQString plugName= libraryName(plugin);
if (plugName.isNull())
return false;
- if (m_list->contains(plugName))
+ if (m_list->tqcontains(plugName))
return false;
m_list->append(plugName);
return true;
@@ -55,7 +55,7 @@ bool PluginManager::add(const TQString& plugin, bool)
bool PluginManager::remove(const TQString& plugin)
{
- if (!m_list->contains(plugin))
+ if (!m_list->tqcontains(plugin))
return false;
m_list->remove(plugin);
return true;
diff --git a/kommander/widget/expression.cpp b/kommander/widget/expression.cpp
index d29d94e8..350646e1 100644
--- a/kommander/widget/expression.cpp
+++ b/kommander/widget/expression.cpp
@@ -57,7 +57,7 @@ Expression& Expression::operator=(const TQString& s)
m_parts.append(TQVariant(s.mid(start, i - start).toDouble()));
else
m_parts.append(TQVariant(s.mid(start, i - start).toInt()));
- } else if (single.contains(s[i]))
+ } else if (single.tqcontains(s[i]))
m_parts.append(TQVariant(TQString(s[i++])));
else if (s[i] == '\"')
{
diff --git a/kommander/widget/functionlib.cpp b/kommander/widget/functionlib.cpp
index 416207b7..81613785 100644
--- a/kommander/widget/functionlib.cpp
+++ b/kommander/widget/functionlib.cpp
@@ -52,7 +52,7 @@ static ParseNode f_stringLength(Parser*, const ParameterList& params)
static ParseNode f_stringContains(Parser*, const ParameterList& params)
{
- return params[0].toString().contains(params[1].toString());
+ return params[0].toString().tqcontains(params[1].toString());
}
static ParseNode f_stringCompare(Parser*, const ParameterList& params)
@@ -71,12 +71,12 @@ static ParseNode f_stringCompare(Parser*, const ParameterList& params)
static ParseNode f_stringFind(Parser*, const ParameterList& params)
{
- return params[0].toString().find(params[1].toString(), params.count() == 3 ? params[2].toInt() : 0);
+ return params[0].toString().tqfind(params[1].toString(), params.count() == 3 ? params[2].toInt() : 0);
}
static ParseNode f_stringFindRev(Parser*, const ParameterList& params)
{
- return params[0].toString().findRev(params[1].toString(),
+ return params[0].toString().tqfindRev(params[1].toString(),
params.count() == 3 ? params[2].toInt() : params[0].toString().length());
}
@@ -102,7 +102,7 @@ static ParseNode f_stringRemove(Parser*, const ParameterList& params)
static ParseNode f_stringReplace(Parser*, const ParameterList& params)
{
- return params[0].toString().replace(params[1].toString(), params[2].toString());
+ return params[0].toString().tqreplace(params[1].toString(), params[2].toString());
}
static ParseNode f_stringLower(Parser*, const ParameterList& params)
@@ -129,11 +129,11 @@ static ParseNode f_stringSection(Parser*, const ParameterList& params)
static ParseNode f_stringArgs(Parser*, const ParameterList& params)
{
if (params.count() == 2)
- return params[0].toString().arg(params[1].toString());
+ return params[0].toString().tqarg(params[1].toString());
else if (params.count() == 3)
- return params[0].toString().arg(params[1].toString()).arg(params[2].toString());
+ return params[0].toString().tqarg(params[1].toString()).tqarg(params[2].toString());
else
- return params[0].toString().arg(params[1].toString()).arg(params[2].toString()).arg(params[3].toString());
+ return params[0].toString().tqarg(params[1].toString()).tqarg(params[2].toString()).tqarg(params[3].toString());
}
static ParseNode f_stringIsNumber(Parser*, const ParameterList& params)
@@ -250,7 +250,7 @@ static ParseNode f_executeSlot(Parser* parser, const ParameterList& params)
TQObject *object = widget->object();
if (!object)
return ParseNode::error("unknown widget");
- TQStrList slotSignatures = object->metaObject()->slotNames(true);
+ TQStrList slotSignatures = object->tqmetaObject()->slotNames(true);
TQStringList slotNames = TQStringList::fromStrList(slotSignatures);
int slotNum = -1;
uint i = 0;
@@ -353,15 +353,15 @@ static ParseNode f_dcop(Parser*, const ParameterList& params)
byteDataStream << params[i++].toDouble();
else if (*it == "bool")
byteDataStream << (bool)params[i++].toInt();
- else if (*it == "TQStringList")
- if (params[i].toString().find('\n') != -1)
+ else if (*it == TQSTRINGLIST_OBJECT_NAME_STRING)
+ if (params[i].toString().tqfind('\n') != -1)
byteDataStream << TQStringList::split("\n", params[i++].toString(), true);
else
byteDataStream << TQStringList::split("\\n", params[i++].toString(), true);
else
byteDataStream << params[i++].toString();
}
- function.append(TQString("(%1)").arg(items.join(",")));
+ function.append(TQString("(%1)").tqarg(items.join(",")));
TQCString replyType, byteReply;
DCOPClient* cl = KApplication::dcopClient();
if (!cl || !cl->call(appId, object, function.latin1(),
@@ -371,7 +371,7 @@ static ParseNode f_dcop(Parser*, const ParameterList& params)
return ParseNode();
}
TQDataStream byteReplyStream(byteReply, IO_ReadOnly);
- if (replyType == "TQString")
+ if (replyType == TQSTRING_OBJECT_NAME_STRING)
{
TQString text;
byteReplyStream >> text;
@@ -389,7 +389,7 @@ static ParseNode f_dcop(Parser*, const ParameterList& params)
byteReplyStream >> b;
return b;
}
- else if (replyType == "TQStringList")
+ else if (replyType == TQSTRINGLIST_OBJECT_NAME_STRING)
{
TQStringList text;
byteReplyStream >> text;
@@ -397,7 +397,7 @@ static ParseNode f_dcop(Parser*, const ParameterList& params)
}
else if(replyType != "void")
{
- qDebug("%s", TQString("DCOP return type %1 is not yet implemented.").arg(replyType.data()).latin1());
+ qDebug("%s", TQString("DCOP return type %1 is not yet implemented.").tqarg(replyType.data()).latin1());
}
return ParseNode();
@@ -407,12 +407,12 @@ static ParseNode f_createWidget(Parser* p, const ParameterList& params)
{
TQString widgetName = params[0].toString();
TQString widgetType = params[1].toString();
- TQString parentName = params[2].toString();
- KommanderWidget *widget = p->currentWidget()->widgetByName(parentName);
+ TQString tqparentName = params[2].toString();
+ KommanderWidget *widget = p->currentWidget()->widgetByName(tqparentName);
if (!widget)
return ParseNode::error("unknown widget");
- TQWidget *parent = dynamic_cast<TQWidget*>(widget->object());
- TQWidget *w = KommanderFactory::createWidget(widgetType, parent, widgetName.latin1());
+ TQWidget *tqparent = dynamic_cast<TQWidget*>(widget->object());
+ TQWidget *w = KommanderFactory::createWidget(widgetType, tqparent, widgetName.latin1());
if (w)
w->adjustSize();
return ParseNode();
@@ -429,9 +429,9 @@ static ParseNode f_widgetExists(Parser* p, const ParameterList& params)
static ParseNode f_connect(Parser* p, const ParameterList& params)
{
TQString sender = params[0].toString();
- TQString signal = TQString::number(QSIGNAL_CODE) + params[1].toString();
+ TQString signal = TQString::number(TQSIGNAL_CODE) + params[1].toString();
TQString receiver = params[2].toString();
- TQString slot = TQString::number(QSLOT_CODE) + params[3].toString();
+ TQString slot = TQString::number(TQSLOT_CODE) + params[3].toString();
KommanderWidget *senderW = p->currentWidget()->widgetByName(sender);
if (!senderW)
return ParseNode::error("unknown widget");
@@ -445,9 +445,9 @@ static ParseNode f_connect(Parser* p, const ParameterList& params)
static ParseNode f_disconnect(Parser* p, const ParameterList& params)
{
TQString sender = params[0].toString();
- TQString signal = TQString::number(QSIGNAL_CODE) + params[1].toString();
+ TQString signal = TQString::number(TQSIGNAL_CODE) + params[1].toString();
TQString receiver = params[2].toString();
- TQString slot = TQString::number(QSLOT_CODE) + params[3].toString();
+ TQString slot = TQString::number(TQSLOT_CODE) + params[3].toString();
KommanderWidget *senderW = p->currentWidget()->widgetByName(sender);
if (!senderW)
return ParseNode::error("unknown widget");
@@ -499,7 +499,7 @@ static ParseNode f_dialog(Parser* P, const ParameterList& params)
return TQString();
}
TQString cmd = TQString("kmdr-executor %1 %2 _PARENTPID=%3 _PARENTDCOPID=kmdr-executor-%4")
- .arg(pFileName).arg(a_params).arg(getpid()).arg(getpid());
+ .tqarg(pFileName).tqarg(a_params).tqarg(getpid()).tqarg(getpid());
MyProcess proc(P->currentWidget());
TQString text;
@@ -571,7 +571,7 @@ static ParseNode f_arrayToString(Parser* P, const ParameterList& params)
TQValueList<ParseNode>::Iterator itval = values.begin();
while (*it)
{
- array += TQString("%1\t%2\n").arg(*it).arg((*itval).toString());
+ array += TQString("%1\t%2\n").tqarg(*it).tqarg((*itval).toString());
++it;
++itval;
}
@@ -648,7 +648,7 @@ static ParseNode f_arrayIndexedRemoveElements(Parser* P, const ParameterList& pa
return ParseNode(); //out of index range
for (int i = 0; i < count; i++)
{
- if (keys.contains(TQString::number(i)) != 1)
+ if (keys.tqcontains(TQString::number(i)) != 1)
return ParseNode(); //array is not indexed
}
for (int i = key; i <= key + num; i++)
@@ -704,7 +704,7 @@ static ParseNode f_inputColor(Parser*, const ParameterList& params)
if (params.count())
color.setNamedColor(params[0].toString());
KColorDialog::getColor(color);
- return color.name();
+ return TQString(color.name());
}
static ParseNode f_inputText(Parser*, const ParameterList& params)
@@ -721,7 +721,7 @@ static ParseNode f_inputPassword(Parser*, const ParameterList& params)
if (params.count() > 1)
value = params[1].toString().local8Bit();
KPasswordDialog::getPassword(value, params[0].toString());
- return TQString::fromLocal8Bit(value);
+ return TQString(TQString::fromLocal8Bit(value));
}
static ParseNode f_inputValue(Parser*, const ParameterList& params)
@@ -910,15 +910,15 @@ static ParseNode f_write_setting(Parser* parser, const ParameterList& params)
void ParserData::registerStandardFunctions()
{
registerFunction("str_length", Function(&f_stringLength, ValueInt, ValueString));
- registerFunction("str_contains", Function(&f_stringContains, ValueInt, ValueString, ValueString));
+ registerFunction("str_tqcontains", Function(&f_stringContains, ValueInt, ValueString, ValueString));
registerFunction("str_compare", Function(&f_stringCompare, ValueInt, ValueString, ValueString));
- registerFunction("str_find", Function(&f_stringFind, ValueInt, ValueString, ValueString, ValueInt, 2));
+ registerFunction("str_tqfind", Function(&f_stringFind, ValueInt, ValueString, ValueString, ValueInt, 2));
registerFunction("str_findrev", Function(&f_stringFindRev, ValueInt, ValueString, ValueString, ValueInt, 2));
registerFunction("str_left", Function(&f_stringLeft, ValueString, ValueString, ValueInt));
registerFunction("str_right", Function(&f_stringRight, ValueString, ValueString, ValueInt));
registerFunction("str_mid", Function(&f_stringMid, ValueString, ValueString, ValueInt, ValueInt, 2));
registerFunction("str_remove", Function(&f_stringRemove, ValueString, ValueString, ValueString));
- registerFunction("str_replace", Function(&f_stringReplace, ValueString, ValueString, ValueString, ValueString));
+ registerFunction("str_tqreplace", Function(&f_stringReplace, ValueString, ValueString, ValueString, ValueString));
registerFunction("str_lower", Function(&f_stringLower, ValueString, ValueString));
registerFunction("str_upper", Function(&f_stringUpper, ValueString, ValueString));
registerFunction("str_section", Function(&f_stringSection, ValueString, ValueString, ValueString, ValueInt, ValueInt, 3));
@@ -944,7 +944,7 @@ void ParserData::registerStandardFunctions()
registerFunction("dcop", Function(&f_dcop, ValueString, ValueString, ValueString, 3, 100));
registerFunction("dcopid", Function(&f_dcopid, ValueString, ValueNone, 0, 0));
registerFunction("pid", Function(&f_pid, ValueString, ValueNone, 0, 0));
- registerFunction("parentPid", Function(&f_parentPid, ValueString, ValueNone, 0, 0));
+ registerFunction("tqparentPid", Function(&f_parentPid, ValueString, ValueNone, 0, 0));
registerFunction("dialog", Function(&f_dialog, ValueString, ValueString, ValueString, 1, 2));
registerFunction("exec", Function(&f_exec, ValueString, ValueString, ValueString, 1, 2));
registerFunction("execBackground", Function(&f_execBackground, ValueString, ValueString, ValueString, 1, 2));
diff --git a/kommander/widget/invokeclass.cpp b/kommander/widget/invokeclass.cpp
index 866f629b..ec08dfff 100644
--- a/kommander/widget/invokeclass.cpp
+++ b/kommander/widget/invokeclass.cpp
@@ -15,7 +15,7 @@
#include <tqcolor.h>
#include <tqregexp.h>
-InvokeClass::InvokeClass(TQObject *parent):TQObject(parent)
+InvokeClass::InvokeClass(TQObject *tqparent):TQObject(tqparent)
{
m_acceptedSlots = acceptedSlots();
}
@@ -23,9 +23,9 @@ InvokeClass::InvokeClass(TQObject *parent):TQObject(parent)
void InvokeClass::invokeSlot(TQObject *object, const TQString& slot, TQStringList args)
{
TQString invokeName = slot;
- invokeName = invokeName.mid(invokeName.find('('));
- invokeName.prepend(TQString::number(QSIGNAL_CODE) + "invoke");
- TQString slotName = TQString::number(QSLOT_CODE) + slot;
+ invokeName = invokeName.mid(invokeName.tqfind('('));
+ invokeName.prepend(TQString::number(TQSIGNAL_CODE) + "invoke");
+ TQString slotName = TQString::number(TQSLOT_CODE) + slot;
connect(this, invokeName.ascii(), object, slotName.ascii());
if (args.count() == 0)
@@ -33,7 +33,7 @@ void InvokeClass::invokeSlot(TQObject *object, const TQString& slot, TQStringLis
else
{
TQString slotArgStr = slot.section(TQRegExp("\\(|\\)"), 1);
- uint argNum = slotArgStr.contains(',') + 1;
+ uint argNum = slotArgStr.tqcontains(',') + 1;
for (uint i = args.count(); i < argNum; i++)
args << "";
//poor man's invokeMetaObject
diff --git a/kommander/widget/invokeclass.h b/kommander/widget/invokeclass.h
index 4b1a8c0b..043ba73b 100644
--- a/kommander/widget/invokeclass.h
+++ b/kommander/widget/invokeclass.h
@@ -18,8 +18,9 @@
class InvokeClass : public TQObject {
Q_OBJECT
+ TQ_OBJECT
public:
- InvokeClass(TQObject *parent);
+ InvokeClass(TQObject *tqparent);
void invokeSlot(TQObject *object, const TQString& slot, TQStringList args);
static TQStringList acceptedSlots()
diff --git a/kommander/widget/kmdrmainwindow.cpp b/kommander/widget/kmdrmainwindow.cpp
index e123a035..603c1326 100644
--- a/kommander/widget/kmdrmainwindow.cpp
+++ b/kommander/widget/kmdrmainwindow.cpp
@@ -13,8 +13,8 @@
#include <tqtimer.h>
-KmdrMainWindow::KmdrMainWindow(TQWidget *parent, const char *name, WFlags f)
- : KMainWindow(parent, name, f)
+KmdrMainWindow::KmdrMainWindow(TQWidget *tqparent, const char *name, WFlags f)
+ : KMainWindow(tqparent, name, f)
{
TQTimer::singleShot(10, this, TQT_SIGNAL(initialize()));
}
diff --git a/kommander/widget/kmdrmainwindow.h b/kommander/widget/kmdrmainwindow.h
index 6637ffc8..4896db2b 100644
--- a/kommander/widget/kmdrmainwindow.h
+++ b/kommander/widget/kmdrmainwindow.h
@@ -20,8 +20,9 @@
class KmdrMainWindow : public KMainWindow
{
Q_OBJECT
+ TQ_OBJECT
public:
- KmdrMainWindow(TQWidget *parent = 0, const char *name = 0, WFlags f = WType_TopLevel | WDestructiveClose);
+ KmdrMainWindow(TQWidget *tqparent = 0, const char *name = 0, WFlags f = WType_TopLevel | WDestructiveClose);
~KmdrMainWindow();
diff --git a/kommander/widget/kommanderfunctions.cpp b/kommander/widget/kommanderfunctions.cpp
index 6ef6e6f0..7efe5b27 100644
--- a/kommander/widget/kommanderfunctions.cpp
+++ b/kommander/widget/kommanderfunctions.cpp
@@ -52,7 +52,7 @@ TQString KommanderWidget::evalFunction(const TQString& function, const TQStringL
return execCommand(args[0]);
case Kommander::dcop:
return DCOPQuery(args);
- case Kommander::parentPid:
+ case Kommander::tqparentPid:
return global("_PARENTPID").isEmpty() ? TQString().setNum(getppid()) : global("_PARENTPID");
case Kommander::env:
return TQString(getenv(args[0].latin1()));
@@ -66,12 +66,12 @@ TQString KommanderWidget::evalFunction(const TQString& function, const TQStringL
case Kommander::debug:
qDebug("%s", args[0].latin1());
fflush(stderr);
- return TQString::null;
+ return TQString();
case Kommander::echo:
for (uint i=0; i<args.count(); i++)
std::cout << args[i].latin1();
fflush(stdout);
- return TQString::null;
+ return TQString();
case Kommander::readSetting:
{
TQString fname = fileName();
@@ -81,7 +81,7 @@ TQString KommanderWidget::evalFunction(const TQString& function, const TQStringL
cfg.setGroup(fname);
return cfg.readEntry(args[0], args[1]);
}
- return TQString::null;
+ return TQString();
}
case Kommander::writeSetting:
{
@@ -92,7 +92,7 @@ TQString KommanderWidget::evalFunction(const TQString& function, const TQStringL
cfg.setGroup(fname);
cfg.writeEntry(args[0], args[1]);
}
- return TQString::null;
+ return TQString();
}
case Kommander::dialog:
if (args.count() > 1)
@@ -114,7 +114,7 @@ TQString KommanderWidget::evalFunction(const TQString& function, const TQStringL
TQString KommanderWidget::evalExecBlock(const TQStringList& args, const TQString& s, int& pos)
{
- int f = s.find("@execEnd", pos);
+ int f = s.tqfind("@execEnd", pos);
if (f == -1)
{
printError(i18n("Unterminated @execBegin ... @execEnd block."));
@@ -131,7 +131,7 @@ TQString KommanderWidget::evalExecBlock(const TQStringList& args, const TQString
TQString KommanderWidget::evalForEachBlock(const TQStringList& args, const TQString& s, int& pos)
{
- int f = s.find("@end", pos);
+ int f = s.tqfind("@end", pos);
//FIXME: better detection of block boundaries
if (f == -1)
{
@@ -145,9 +145,9 @@ TQString KommanderWidget::evalForEachBlock(const TQStringList& args, const TQStr
TQString var = args[0];
TQStringList loop = TQStringList::split("\n", args[1]);
TQString output;
- TQString block = substituteVariable(s.mid(start, f - start), TQString("%1_count").arg(var),
+ TQString block = substituteVariable(s.mid(start, f - start), TQString("%1_count").tqarg(var),
TQString::number(loop.count()));
- TQString varidx = TQString("%1_index").arg(var);
+ TQString varidx = TQString("%1_index").tqarg(var);
for (uint i=0; i<loop.count(); i++)
output += evalAssociatedText(substituteVariable(substituteVariable(block, varidx, TQString::number(i+1)),
var, loop[i]));
@@ -157,7 +157,7 @@ TQString KommanderWidget::evalForEachBlock(const TQStringList& args, const TQStr
TQString KommanderWidget::evalForBlock(const TQStringList& args, const TQString& s, int& pos)
{
- int f = s.find("@end", pos);
+ int f = s.tqfind("@end", pos);
//FIXME: better detection of block boundaries
if (f == -1)
{
@@ -193,7 +193,7 @@ TQString KommanderWidget::evalForBlock(const TQStringList& args, const TQString&
TQString KommanderWidget::evalIfBlock(const TQStringList& args, const TQString& s, int& pos)
{
- int f = s.find("@endif", pos);
+ int f = s.tqfind("@endif", pos);
//FIXME: better detection of block boundaries; add error message
if (f == -1)
{
@@ -214,7 +214,7 @@ TQString KommanderWidget::evalIfBlock(const TQStringList& args, const TQString&
TQString KommanderWidget::evalSwitchBlock(const TQStringList& args, const TQString& s, int& pos)
{
- int f = s.find("@end", pos);
+ int f = s.tqfind("@end", pos);
//FIXME: better detection of block boundaries; add error message
if (f == -1)
{
@@ -302,7 +302,7 @@ TQString KommanderWidget::evalArrayFunction(const TQString& function, const TQSt
const TQMap<TQString, ParseNode> map = parser.array(array);
TQString arraystring;
for (TQMap<TQString, ParseNode>::ConstIterator it = map.begin(); it != map.end(); ++it)
- arraystring += TQString("%1\t%2\n").arg(it.key()).arg(it.data().toString());
+ arraystring += TQString("%1\t%2\n").tqarg(it.key()).tqarg(it.data().toString());
return arraystring;
}
default:
@@ -317,7 +317,7 @@ TQString KommanderWidget::evalWidgetFunction(const TQString& identifier, const T
KommanderWidget* pWidget = parseWidget(identifier);
if (!pWidget)
{
- printError(i18n("Unknown widget: @%1.").arg(identifier));
+ printError(i18n("Unknown widget: @%1.").tqarg(identifier));
return TQString();
}
if (s[pos] == '.')
@@ -335,13 +335,13 @@ TQString KommanderWidget::evalWidgetFunction(const TQString& identifier, const T
}
else if (pWidget == this)
{
- printError(i18n("Infinite loop: @%1 called inside @%2.").arg(pWidget->widgetName())
- .arg(pWidget->widgetName()));
+ printError(i18n("Infinite loop: @%1 called inside @%2.").tqarg(pWidget->widgetName())
+ .tqarg(pWidget->widgetName()));
return TQString();
}
else if (!pWidget->hasAssociatedText())
{
- printError(i18n("Script for @%1 is empty.").arg(pWidget->widgetName()));
+ printError(i18n("Script for @%1 is empty.").tqarg(pWidget->widgetName()));
return TQString();
}
return pWidget->evalAssociatedText();
diff --git a/kommander/widget/kommanderwidget.cpp b/kommander/widget/kommanderwidget.cpp
index 8f880c40..2fc867f7 100644
--- a/kommander/widget/kommanderwidget.cpp
+++ b/kommander/widget/kommanderwidget.cpp
@@ -74,7 +74,7 @@ TQStringList KommanderWidget::associatedText() const
bool KommanderWidget::hasAssociatedText()
{
- int index = states().findIndex(currentState());
+ int index = states().tqfindIndex(currentState());
if (index == -1 || m_associatedText[index].isEmpty())
return false;
return true;
@@ -113,7 +113,7 @@ void KommanderWidget::setDisplayStates(const TQStringList& a_displayStates)
TQString KommanderWidget::evalAssociatedText() // expands and returns associated text as a string
{
- int index = ( states().findIndex( currentState()) );
+ int index = ( states().tqfindIndex( currentState()) );
if (index == -1)
{
printError(i18n("Invalid state for associated text."));
@@ -131,7 +131,7 @@ TQString KommanderWidget::evalAssociatedText(const TQString& a_text)
p.setWidget(this);
p.setString(a_text);
if (!p.setString(a_text) || !p.parse())
- printError(i18n("Line %1: %2.\n").arg(p.errorLine()+1).arg(p.errorMessage()));
+ printError(i18n("Line %1: %2.\n").tqarg(p.errorLine()+1).tqarg(p.errorMessage()));
return TQString();
}
/* Old macro-only parser is implemented below */
@@ -143,7 +143,7 @@ TQString KommanderWidget::evalAssociatedText(const TQString& a_text)
int pos = 0, baseTextLength = a_text.length();
while (pos < baseTextLength)
{
- int ident = a_text.find(ESCCHAR, pos);
+ int ident = a_text.tqfind(ESCCHAR, pos);
if (ident == -1) {
evalText += a_text.mid(pos);
break;
@@ -164,7 +164,7 @@ TQString KommanderWidget::evalAssociatedText(const TQString& a_text)
if (identifier.isEmpty())
{
if (pos < baseTextLength && a_text[pos] == '#') { // comment
- int newpos = a_text.find('\n', pos+1);
+ int newpos = a_text.tqfind('\n', pos+1);
if (newpos == -1)
newpos = a_text.length();
if (pos > 1 && a_text[pos-2] == '\n')
@@ -241,7 +241,7 @@ TQString KommanderWidget::evalAssociatedText(const TQString& a_text)
}
else
{
- printError(i18n("Unknown special: \'%1\'.").arg(identifier));
+ printError(i18n("Unknown special: \'%1\'.").tqarg(identifier));
return TQString();
}
}
@@ -260,7 +260,7 @@ TQString KommanderWidget::DCOPQuery(const TQStringList& a_query)
// parse function arguments
TQString function = a_query[2], pTypes;
function.remove(' ');
- int start = function.find('(');
+ int start = function.tqfind('(');
bool ok = false;
if (start != -1)
pTypes = parseBrackets(function, start, ok);
@@ -271,13 +271,13 @@ TQString KommanderWidget::DCOPQuery(const TQStringList& a_query)
}
if (!ok)
{
- printError(i18n("Unmatched parenthesis in DCOP call \'%1\'.").arg(a_query[2]));
+ printError(i18n("Unmatched tqparenthesis in DCOP call \'%1\'.").tqarg(a_query[2]));
return TQString();
}
const TQStringList argTypes = parseArgs(pTypes, ok);
if (!ok || argTypes.count() != a_query.count() - 3)
{
- printError(i18n("Incorrect arguments in DCOP call \'%1\'.").arg(a_query[2]));
+ printError(i18n("Incorrect arguments in DCOP call \'%1\'.").tqarg(a_query[2]));
return TQString();
}
@@ -295,8 +295,8 @@ TQString KommanderWidget::DCOPQuery(const TQStringList& a_query)
byteDataStream << a_query[i+3].toDouble();
else if (argTypes[i] == "bool")
byteDataStream << (bool)(a_query[i+3] != "false" && a_query[i+3] != "false" && a_query[i+3] != "0");
- else if (argTypes[i] == "TQStringList")
- if (a_query[i+3].find('\n') != -1)
+ else if (argTypes[i] == TQSTRINGLIST_OBJECT_NAME_STRING)
+ if (a_query[i+3].tqfind('\n') != -1)
byteDataStream << TQStringList::split("\n", a_query[i+3], true);
else
byteDataStream << TQStringList::split("\\n", a_query[i+3], true);
@@ -312,7 +312,7 @@ TQString KommanderWidget::DCOPQuery(const TQStringList& a_query)
}
TQDataStream byteReplyStream(byteReply, IO_ReadOnly);
- if (replyType == "TQString")
+ if (replyType == TQSTRING_OBJECT_NAME_STRING)
{
TQString text;
byteReplyStream >> text;
@@ -330,7 +330,7 @@ TQString KommanderWidget::DCOPQuery(const TQStringList& a_query)
byteReplyStream >> b;
return TQString::number(b);
}
- else if (replyType == "TQStringList")
+ else if (replyType == TQSTRINGLIST_OBJECT_NAME_STRING)
{
TQStringList text;
byteReplyStream >> text;
@@ -338,7 +338,7 @@ TQString KommanderWidget::DCOPQuery(const TQStringList& a_query)
}
else if(replyType != "void")
{
- printError(i18n("DCOP return type %1 is not yet implemented.").arg(replyType.data()));
+ printError(i18n("DCOP return type %1 is not yet implemented.").tqarg(replyType.data()));
}
return TQString();
@@ -392,7 +392,7 @@ TQString KommanderWidget::runDialog(const TQString& a_dialog, const TQString& a_
return TQString();
}
TQString cmd = TQString("kmdr-executor %1 %2 _PARENTPID=%3 _PARENTDCOPID=kmdr-executor-%4")
- .arg(pFileName).arg(a_params).arg(getpid()).arg(getpid());
+ .tqarg(pFileName).tqarg(a_params).tqarg(getpid()).tqarg(getpid());
return execCommand(cmd);
}
@@ -405,26 +405,26 @@ void KommanderWidget::printError(const TQString& a_error) const
KDialogBase::Yes, KDialogBase::No, 0, 0, true, false,
i18n("Continue"), i18n("Continue && Ignore Next Errors"), i18n("Stop"));
switch (KMessageBox::createKMessageBox(dialog, TQMessageBox::Warning,
- i18n("<qt>Error in widget <b>%1</b>:<p><i>%2</i></qt>").arg(TQString(m_thisObject->name()))
- .arg(a_error), TQStringList(), TQString(), 0, 0))
+ i18n("<qt>Error in widget <b>%1</b>:<p><i>%2</i></qt>").tqarg(TQString(m_thisObject->name()))
+ .tqarg(a_error), TQStringList(), TQString(), 0, 0))
{
case KDialogBase::No:
showErrors = false;
case KDialogBase::Yes:
break;
case KDialogBase::Cancel:
- if (parentDialog()->inherits(TQDIALOG_OBJECT_NAME_STRING))
+ if (tqparentDialog()->inherits(TQDIALOG_OBJECT_NAME_STRING))
{
- parentDialog()->close();
+ tqparentDialog()->close();
exit(-1);
}
- else if (parentDialog()->inherits(TQMAINWINDOW_OBJECT_NAME_STRING))
+ else if (tqparentDialog()->inherits(TQMAINWINDOW_OBJECT_NAME_STRING))
kapp->quit();
}
}
else
{
- kdError() << i18n("Error in widget %1:\n %2\n").arg(m_thisObject->name()).arg(a_error);
+ kdError() << i18n("Error in widget %1:\n %2\n").tqarg(m_thisObject->name()).tqarg(a_error);
}
}
@@ -557,16 +557,16 @@ KommanderWidget* KommanderWidget::widgetByName(const TQString& a_name) const
KommanderWidget* KommanderWidget::parseWidget(const TQString& widgetName) const
{
- if (TQString(parentDialog()->name()) == widgetName)
- return dynamic_cast <KommanderWidget*>(parentDialog());
+ if (TQString(tqparentDialog()->name()) == widgetName)
+ return dynamic_cast <KommanderWidget*>(tqparentDialog());
TQCString s = widgetName.lower() == "self" ? m_thisObject->name() : widgetName.latin1();
- TQObject* childObj = parentDialog()->child(s);
+ TQObject* childObj = tqparentDialog()->child(s);
/* if (!childObj)
{
Parser parser(internalParserData());
TQString variableValue = parser.variable(widgetName).toString();
s = variableValue.lower() == "self" ? m_thisObject->name() : variableValue.latin1();
- childObj = parentDialog()->child(s);
+ childObj = tqparentDialog()->child(s);
}*/
return dynamic_cast <KommanderWidget*>(childObj);
}
@@ -579,7 +579,7 @@ TQStringList KommanderWidget::parseFunction(const TQString& group, const TQStrin
TQString arg = parseBrackets(s, from, ok);
if (!ok)
{
- printError(i18n("Unmatched parenthesis after \'%1\'.").arg(function));
+ printError(i18n("Unmatched tqparenthesis after \'%1\'.").tqarg(function));
return TQString();
}
const TQStringList args = parseArgs(arg, ok);
@@ -588,23 +588,23 @@ TQStringList KommanderWidget::parseFunction(const TQString& group, const TQStrin
bool extraArg = gname == Group::DCOP;
if (!ok)
- printError(i18n("Unmatched quotes in argument of \'%1\'.").arg(function));
+ printError(i18n("Unmatched quotes in argument of \'%1\'.").tqarg(function));
else if (gname == -1)
- printError(i18n("Unknown function group: \'%1\'.").arg(group));
+ printError(i18n("Unknown function group: \'%1\'.").tqarg(group));
else if (fname == -1 && !extraArg)
- printError(i18n("Unknown function: \'%1\' in group '%2'.").arg(function).arg(group));
+ printError(i18n("Unknown function: \'%1\' in group '%2'.").tqarg(function).tqarg(group));
else if (fname == -1 && extraArg)
- printError(i18n("Unknown widget function: \'%1\'.").arg(function));
+ printError(i18n("Unknown widget function: \'%1\'.").tqarg(function));
else if ((int)args.count() + extraArg < SpecialInformation::minArg(gname, fname))
printError(i18n("Not enough arguments for \'%1\' (%2 instead of %3).<p>"
"Correct syntax is: %4")
- .arg(function).arg(args.count() + extraArg).arg(SpecialInformation::minArg(gname, fname))
- .arg(SpecialInformation::prototype(gname, fname, SpecialFunction::ShowArgumentNames)));
+ .tqarg(function).tqarg(args.count() + extraArg).tqarg(SpecialInformation::minArg(gname, fname))
+ .tqarg(SpecialInformation::prototype(gname, fname, SpecialFunction::ShowArgumentNames)));
else if ((int)args.count() + extraArg > SpecialInformation::maxArg(gname, fname))
printError(i18n("Too many arguments for \'%1\' (%2 instead of %3).<p>"
"Correct syntax is: %4")
- .arg(function).arg(args.count() + extraArg).arg(SpecialInformation::maxArg(gname, fname))
- .arg(SpecialInformation::prototype(gname, fname, SpecialFunction::ShowArgumentNames)));
+ .tqarg(function).tqarg(args.count() + extraArg).tqarg(SpecialInformation::maxArg(gname, fname))
+ .tqarg(SpecialInformation::prototype(gname, fname, SpecialFunction::ShowArgumentNames)));
else
success = true;
ok = success;
@@ -616,7 +616,7 @@ int KommanderWidget::parseBlockBoundary(const TQString& s, int from, const TQStr
int shortest = -1;
for (uint i=0; i<args.count(); i++)
{
- int match = s.find(args[i], from);
+ int match = s.tqfind(args[i], from);
if (shortest > match || shortest == -1)
shortest = match;
}
@@ -627,12 +627,12 @@ int KommanderWidget::parseBlockBoundary(const TQString& s, int from, const TQStr
TQString KommanderWidget::substituteVariable(TQString text, TQString variable, TQString value) const
{
- TQString var = TQString("@%1").arg(variable);
+ TQString var = TQString("@%1").tqarg(variable);
TQString newtext;
int newpos, pos = 0;
while (true)
{
- newpos = text.find(var, pos);
+ newpos = text.tqfind(var, pos);
if (newpos != -1)
{
newtext += text.mid(pos, newpos-pos);
@@ -649,12 +649,12 @@ TQString KommanderWidget::substituteVariable(TQString text, TQString variable, T
-TQWidget* KommanderWidget::parentDialog() const
+TQWidget* KommanderWidget::tqparentDialog() const
{
TQObject *superParent = m_thisObject;
- while (superParent->parent())
+ while (superParent->tqparent())
{
- superParent = superParent->parent();
+ superParent = superParent->tqparent();
if (superParent->inherits(TQDIALOG_OBJECT_NAME_STRING) || superParent->inherits(TQMAINWINDOW_OBJECT_NAME_STRING))
break;
}
@@ -692,7 +692,7 @@ TQString KommanderWidget::handleDCOP(const int function, const TQStringList& arg
break;
case DCOP::type:
return current->className();
- case DCOP::children:
+ case DCOP::tqchildren:
{
TQStringList matching;
TQObjectList* widgets = current->queryList(TQWIDGET_OBJECT_NAME_STRING, 0, false, args.count() == 0 || args[0] != "false");
@@ -707,12 +707,12 @@ TQString KommanderWidget::handleDCOP(const int function, const TQStringList& arg
bool KommanderWidget::isFunctionSupported(int f)
{
- return f == DCOP::setEnabled || f == DCOP::setVisible || f == DCOP::children || f == DCOP::type;
+ return f == DCOP::setEnabled || f == DCOP::setVisible || f == DCOP::tqchildren || f == DCOP::type;
}
bool KommanderWidget::isCommonFunction(int f)
{
- return f == DCOP::setEnabled || f == DCOP::setVisible || f == DCOP::children || f == DCOP::type;
+ return f == DCOP::setEnabled || f == DCOP::setVisible || f == DCOP::tqchildren || f == DCOP::type;
}
ParserData* KommanderWidget::internalParserData() const
@@ -722,7 +722,7 @@ ParserData* KommanderWidget::internalParserData() const
TQString KommanderWidget::fileName()
{
- KommanderWindow* window = dynamic_cast<KommanderWindow*>(parentDialog());
+ KommanderWindow* window = dynamic_cast<KommanderWindow*>(tqparentDialog());
if (window)
return TQString(window->fileName());
else
@@ -732,7 +732,7 @@ TQString KommanderWidget::fileName()
TQString KommanderWidget::widgetName() const
{
if (m_thisObject)
- return TQString::fromLatin1(m_thisObject->name());
+ return TQString::tqfromLatin1(m_thisObject->name());
else
return TQString();
}
diff --git a/kommander/widget/kommanderwidget.h b/kommander/widget/kommanderwidget.h
index c9576010..2087d086 100644
--- a/kommander/widget/kommanderwidget.h
+++ b/kommander/widget/kommanderwidget.h
@@ -115,12 +115,12 @@ protected:
TQString DCOPQuery(const TQStringList& args);
TQString localDCOPQuery(const TQString function, const TQStringList& args = TQStringList());
TQString localDCOPQuery(const TQString function, const TQString& arg1,
- const TQString& arg2, const TQString& arg3 = TQString::null,
- const TQString& arg4 = TQString::null);
+ const TQString& arg2, const TQString& arg3 = TQString(),
+ const TQString& arg4 = TQString());
// Execute given command, return its result
- TQString execCommand(const TQString& a_command, const TQString& a_shell = TQString::null) const;
+ TQString execCommand(const TQString& a_command, const TQString& a_shell = TQString()) const;
// Find and run dialog (with optional parameters)
- TQString runDialog(const TQString& a_dialog, const TQString& a_params = TQString::null);
+ TQString runDialog(const TQString& a_dialog, const TQString& a_params = TQString());
// Display error message a_error; display current class name if no other is given
void printError(const TQString& a_error) const;
// Auxiliary functions for parser
@@ -140,8 +140,8 @@ protected:
// Parse given identifier as widget name
KommanderWidget* parseWidget(const TQString& name) const;
- // Return parent dialog of this widget
- TQWidget* parentDialog() const;
+ // Return tqparent dialog of this widget
+ TQWidget* tqparentDialog() const;
TQString substituteVariable(TQString text, TQString variable, TQString value) const;
ParserData* internalParserData() const;
diff --git a/kommander/widget/myprocess.cpp b/kommander/widget/myprocess.cpp
index 59eb67fb..4914a95a 100644
--- a/kommander/widget/myprocess.cpp
+++ b/kommander/widget/myprocess.cpp
@@ -74,7 +74,7 @@ TQString MyProcess::run(const TQString& a_command, const TQString& a_shell)
// Look for shell
if (at.startsWith("#!")) {
- int eol = at.find("\n");
+ int eol = at.tqfind("\n");
if (eol == -1)
eol = at.length();
shellName = at.mid(2, eol-1).stripWhiteSpace();
@@ -91,7 +91,7 @@ TQString MyProcess::run(const TQString& a_command, const TQString& a_shell)
if(!mProcess->start(KProcess::NotifyOnExit, KProcess::All))
{
- m_atw->printError(i18n("<qt>Failed to start shell process<br><b>%1</b></qt>").arg(shellName));
+ m_atw->printError(i18n("<qt>Failed to start shell process<br><b>%1</b></qt>").tqarg(shellName));
return TQString();
}
mProcess->writeStdin(m_input, m_input.length());
@@ -102,10 +102,10 @@ TQString MyProcess::run(const TQString& a_command, const TQString& a_shell)
else
{
TQWidget dummy(0, 0, WType_Dialog | WShowModal);
- dummy.setFocusPolicy(TQWidget::NoFocus);
+ dummy.setFocusPolicy(TQ_NoFocus);
m_loopStarted = true;
qt_enter_modal(&dummy);
- qApp->enter_loop();
+ tqApp->enter_loop();
qt_leave_modal(&dummy);
if (!m_output.isEmpty() && m_output[m_output.length()-1] == '\n')
@@ -125,7 +125,7 @@ void MyProcess::slotProcessExited(KProcess* process)
{
if (m_loopStarted)
{
- qApp->exit_loop();
+ tqApp->exit_loop();
m_loopStarted = false;
}
delete process;
diff --git a/kommander/widget/myprocess.h b/kommander/widget/myprocess.h
index 36af1b48..c22aa810 100644
--- a/kommander/widget/myprocess.h
+++ b/kommander/widget/myprocess.h
@@ -26,9 +26,10 @@
class KommanderWidget;
-class KOMMANDER_EXPORT MyProcess : public QObject
+class KOMMANDER_EXPORT MyProcess : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
MyProcess(const KommanderWidget *);
// Run given command, using a_shell as a shell (this can be overridden by shebang in the first line)
diff --git a/kommander/widget/parsenode.cpp b/kommander/widget/parsenode.cpp
index 492c00fb..407e0987 100644
--- a/kommander/widget/parsenode.cpp
+++ b/kommander/widget/parsenode.cpp
@@ -38,13 +38,13 @@ ParseNode::ParseNode(double d) : m_type(ValueDouble), m_double(d), m_context(-1)
{
}
-ParseNode::ParseNode(Keyword k) : m_type(ValueKeyword), m_keyword(k), m_string(TQString::null), m_context(-1)
+ParseNode::ParseNode(Keyword k) : m_type(ValueKeyword), m_keyword(k), m_string(TQString()), m_context(-1)
{
}
ParseNode::ParseNode(Keyword k, const TQString& name) : m_type(ValueKeyword), m_keyword(k), m_context(-1)
{
- m_string = (k == Variable) ? name : TQString::null;
+ m_string = (k == Variable) ? name : TQString();
}
ParseNode ParseNode::error(const TQString& s)
diff --git a/kommander/widget/parser.cpp b/kommander/widget/parser.cpp
index 04748e45..07ffb88c 100644
--- a/kommander/widget/parser.cpp
+++ b/kommander/widget/parser.cpp
@@ -24,16 +24,16 @@ using namespace Parse;
TQString unescape(TQString s)
{
- return s.replace("\\\"", "\"").replace("\\t", "\t").replace("\\n", "\n").replace("\\\\", "\\");
+ return s.tqreplace("\\\"", "\"").tqreplace("\\t", "\t").tqreplace("\\n", "\n").tqreplace("\\\\", "\\");
}
-Parser::Parser(ParserData* pData) : m_data(pData), m_start(0), m_error(TQString::null), m_errorPosition(0),
+Parser::Parser(ParserData* pData) : m_data(pData), m_start(0), m_error(TQString()), m_errorPosition(0),
m_widget(0)
{
}
Parser::Parser(ParserData* pData, const TQString& expr) : m_data(pData), m_start(0),
- m_error(TQString::null), m_errorPosition(0), m_widget(0)
+ m_error(TQString()), m_errorPosition(0), m_widget(0)
{
setString(expr);
}
@@ -113,7 +113,7 @@ bool Parser::setString(const TQString& s)
else // Bad character
{
insertNode(s.mid(start, 1), lines);
- setError(i18n("Invalid character: '%1'").arg(s[start]), m_parts.count()-1);
+ setError(i18n("Invalid character: '%1'").tqarg(s[start]), m_parts.count()-1);
return false;
}
}
@@ -220,7 +220,7 @@ ParseNode Parser::parseValue(Mode mode)
return parseWidget(mode, value);
}else if (mode == Execute)
{
- setError(i18n("'%1' (%2) is not a widget").arg(p.variableName()).arg(variable(p.variableName()).toString()));
+ setError(i18n("'%1' (%2) is not a widget").tqarg(p.variableName()).tqarg(variable(p.variableName()).toString()));
return ParseNode();
} else
{
@@ -232,7 +232,7 @@ ParseNode Parser::parseValue(Mode mode)
}
else if (tryKeyword(LeftParenthesis, CheckOnly))
{
- setError(i18n("'%1' is not a function").arg(p.variableName()));
+ setError(i18n("'%1' is not a function").tqarg(p.variableName()));
return ParseNode();
}
else
@@ -423,15 +423,15 @@ ParseNode Parser::parseFunction(Mode mode)
tryKeyword(RightParenthesis);
}
if (f.minArgs() > params.count())
- setError(i18n("in function '%1': %2").arg(name).arg(i18n("too few parameters")), pos);
+ setError(i18n("in function '%1': %2").tqarg(name).tqarg(i18n("too few parameters")), pos);
else if (f.maxArgs() < params.count())
- setError(i18n("in function '%1': %2").arg(name).arg(i18n("too many parameters")), pos);
+ setError(i18n("in function '%1': %2").tqarg(name).tqarg(i18n("too many parameters")), pos);
else if (mode == Execute)
{
ParseNode p = f.execute(this, params);
if (!p.isValid())
{
- setError(i18n("in function '%1': %2").arg(name).arg(p.errorMessage()), pos);
+ setError(i18n("in function '%1': %2").tqarg(name).tqarg(p.errorMessage()), pos);
return ParseNode();
}
else
@@ -471,7 +471,7 @@ ParseNode Parser::parseWidget(Mode mode, const TQString &widgetName)
ParseNode p = f.execute(this, params);
if (!p.isValid())
{
- setError(i18n("in widget function '%1.%2': %3").arg(widget).arg(var).arg(p.errorMessage()), pos);
+ setError(i18n("in widget function '%1.%2': %3").tqarg(widget).tqarg(var).tqarg(p.errorMessage()), pos);
return ParseNode();
}
else
@@ -514,12 +514,12 @@ ParseNode Parser::parseAssignment(Mode mode)
m_start = m_start - 2;
return parseWidget(mode);
} else
- setError(i18n("'%1' is not a widget").arg(var));
+ setError(i18n("'%1' is not a widget").tqarg(var));
}
else if (tryKeyword(LeftParenthesis, CheckOnly))
- setError(i18n("'%1' is not a function").arg(var));
+ setError(i18n("'%1' is not a function").tqarg(var));
else
- setError(i18n("Unexpected symbol after variable '%1'").arg(var));
+ setError(i18n("Unexpected symbol after variable '%1'").tqarg(var));
return ParseNode();
}
@@ -738,9 +738,9 @@ bool Parser::tryKeyword(Keyword k, Mode mode)
if (mode == Execute)
{
if (k == Dot)
- setError(i18n("Expected '%1'<br><br>Possible cause of the error is having a variable with the same name as a widget").arg(m_data->keywordToString(k)));
+ setError(i18n("Expected '%1'<br><br>Possible cause of the error is having a variable with the same name as a widget").tqarg(m_data->keywordToString(k)));
else
- setError(i18n("Expected '%1'").arg(m_data->keywordToString(k)));
+ setError(i18n("Expected '%1'").tqarg(m_data->keywordToString(k)));
}
return false;
}
@@ -785,7 +785,7 @@ bool Parser::isWidget() const
void Parser::reset()
{
m_start = 0;
- m_error = TQString::null;
+ m_error = TQString();
m_errorPosition = 0;
}
@@ -814,9 +814,9 @@ void Parser::setVariable(const TQString& name, ParseNode value)
ParseNode Parser::variable(const TQString& name) const
{
if (isGlobal(name))
- return m_globalVariables.contains(name) ? m_globalVariables[name] : ParseNode();
+ return m_globalVariables.tqcontains(name) ? m_globalVariables[name] : ParseNode();
else
- return m_variables.contains(name) ? m_variables[name] : ParseNode();
+ return m_variables.tqcontains(name) ? m_variables[name] : ParseNode();
}
bool Parser::isGlobal(const TQString& name) const
@@ -826,7 +826,7 @@ bool Parser::isGlobal(const TQString& name) const
bool Parser::isVariable(const TQString& name) const
{
- return m_variables.contains(name) || m_globalVariables.contains(name);
+ return m_variables.tqcontains(name) || m_globalVariables.tqcontains(name);
}
void Parser::unsetVariable(const TQString& key)
@@ -847,7 +847,7 @@ const TQMap<TQString, ParseNode>& Parser::array(const TQString& name) const
bool Parser::isArray(const TQString& name) const
{
- return m_arrays.contains(name) || m_globalArrays.contains(name);
+ return m_arrays.tqcontains(name) || m_globalArrays.tqcontains(name);
}
void Parser::setArray(const TQString& name, const TQString& key, ParseNode value)
@@ -881,9 +881,9 @@ ParseNode Parser::arrayValue(const TQString& name, const TQString& key) const
if (!isArray(name))
return ParseNode();
if (isGlobal(name))
- return m_globalArrays[name].contains(key) ? m_globalArrays[name][key] : ParseNode();
+ return m_globalArrays[name].tqcontains(key) ? m_globalArrays[name][key] : ParseNode();
else
- return m_arrays[name].contains(key) ? m_arrays[name][key] : ParseNode();
+ return m_arrays[name].tqcontains(key) ? m_arrays[name][key] : ParseNode();
}
diff --git a/kommander/widget/parser.h b/kommander/widget/parser.h
index 3ad7d59c..b82188d2 100644
--- a/kommander/widget/parser.h
+++ b/kommander/widget/parser.h
@@ -65,7 +65,7 @@ public:
// set array key
void setArray(const TQString& name, const TQString& key, ParseNode value);
// unset array key or whole array
- void unsetArray(const TQString& name, const TQString& key = TQString::null);
+ void unsetArray(const TQString& name, const TQString& key = TQString());
// array value
ParseNode arrayValue(const TQString& name, const TQString& key) const;
// get associated widget
@@ -110,7 +110,7 @@ private:
// parse parameters
ParseNode parseFunction(Parse::Mode mode = Parse::Execute);
// parse widget function
- ParseNode parseWidget(Parse::Mode mode = Parse::Execute, const TQString &widgetName = TQString::null);
+ ParseNode parseWidget(Parse::Mode mode = Parse::Execute, const TQString &widgetName = TQString());
// parse assignment
ParseNode parseAssignment(Parse::Mode mode = Parse::Execute);
diff --git a/kommander/widget/parserdata.cpp b/kommander/widget/parserdata.cpp
index 274d7220..b5346fd4 100644
--- a/kommander/widget/parserdata.cpp
+++ b/kommander/widget/parserdata.cpp
@@ -19,7 +19,7 @@ using namespace Parse;
KeywordGroup ParserData::keywordGroup(Keyword k) const
{
- if (m_groups.contains(k))
+ if (m_groups.tqcontains(k))
return m_groups[k];
else
return GroupMisc;
@@ -28,7 +28,7 @@ KeywordGroup ParserData::keywordGroup(Keyword k) const
Keyword ParserData::stringToKeyword(const TQString& s) const
{
TQString k = s.lower();
- if (m_keywords.contains(k))
+ if (m_keywords.tqcontains(k))
return m_keywords[k];
else
return Variable;
@@ -116,7 +116,7 @@ ParserData::ParserData()
bool ParserData::isFunction(const TQString& name) const
{
- return m_functions.contains(name.lower());
+ return m_functions.tqcontains(name.lower());
}
const Function& ParserData::function(const TQString& name) const
diff --git a/kommander/widgets/aboutdialog.cpp b/kommander/widgets/aboutdialog.cpp
index 9377b377..4425412c 100644
--- a/kommander/widgets/aboutdialog.cpp
+++ b/kommander/widgets/aboutdialog.cpp
@@ -36,8 +36,8 @@ enum Functions {
LastFunction
};
-AboutDialog::AboutDialog(TQWidget *parent, const char *name)
- : TQLabel(parent, name), KommanderWidget(this)
+AboutDialog::AboutDialog(TQWidget *tqparent, const char *name)
+ : TQLabel(tqparent, name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
diff --git a/kommander/widgets/aboutdialog.h b/kommander/widgets/aboutdialog.h
index 64d6c9ab..5837f355 100644
--- a/kommander/widgets/aboutdialog.h
+++ b/kommander/widgets/aboutdialog.h
@@ -24,11 +24,12 @@ class KAboutData;
class AboutDialog : public TQLabel, public KommanderWidget
{
Q_OBJECT
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_OBJECT
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
public:
- AboutDialog(TQWidget *parent = 0, const char *name = 0);
+ AboutDialog(TQWidget *tqparent = 0, const char *name = 0);
~AboutDialog();
diff --git a/kommander/widgets/buttongroup.cpp b/kommander/widgets/buttongroup.cpp
index 751c8e5c..6b0feef3 100644
--- a/kommander/widgets/buttongroup.cpp
+++ b/kommander/widgets/buttongroup.cpp
@@ -39,7 +39,7 @@ enum Functions {
};
ButtonGroup::ButtonGroup(TQWidget *a_parent, const char *a_name)
- : TQButtonGroup(a_parent, a_name), KommanderWidget(this)
+ : TQButtonGroup(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "checked";
@@ -109,7 +109,7 @@ void ButtonGroup::contextMenuEvent( TQContextMenuEvent * e )
bool ButtonGroup::isFunctionSupported(int f)
{
- return f == DCOP::text || f == DCOP::checked || f == DCOP::setChecked || f == DCOP::geometry || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor || (f >= FirstFunction && f <= LastFunction);
+ return f == DCOP::text || f == DCOP::checked || f == DCOP::setChecked || f == DCOP::tqgeometry || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor || (f >= FirstFunction && f <= LastFunction);
}
@@ -120,8 +120,8 @@ TQString ButtonGroup::handleDCOP(int function, const TQStringList& args)
{
TQString text;
for (int i = 0; i < count(); i++)
- if (dynamic_cast<KommanderWidget*>(find(i)))
- text += (dynamic_cast<KommanderWidget*>(find(i)))->evalAssociatedText();
+ if (dynamic_cast<KommanderWidget*>(tqfind(i)))
+ text += (dynamic_cast<KommanderWidget*>(tqfind(i)))->evalAssociatedText();
return text;
}
case DCOP::checked:
@@ -133,7 +133,7 @@ TQString ButtonGroup::handleDCOP(int function, const TQStringList& args)
case BG_selectedId:
return TQString::number(this->selectedId() );
break;
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/buttongroup.h b/kommander/widgets/buttongroup.h
index 67252a5c..ff7d5edb 100644
--- a/kommander/widgets/buttongroup.h
+++ b/kommander/widgets/buttongroup.h
@@ -34,10 +34,11 @@ class TQShowEvent;
class KOMMANDER_EXPORT ButtonGroup : public TQButtonGroup, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget DESIGNABLE false)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget DESIGNABLE false)
public:
ButtonGroup(TQWidget *a_parent, const char *a_name);
~ButtonGroup();
diff --git a/kommander/widgets/checkbox.cpp b/kommander/widgets/checkbox.cpp
index f7fe20be..696a9b2b 100644
--- a/kommander/widgets/checkbox.cpp
+++ b/kommander/widgets/checkbox.cpp
@@ -29,7 +29,7 @@
#include "checkbox.h"
CheckBox::CheckBox(TQWidget *a_parent, const char *a_name)
- : TQCheckBox(a_parent, a_name), KommanderWidget(this)
+ : TQCheckBox(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "unchecked";
@@ -102,7 +102,7 @@ void CheckBox::showEvent(TQShowEvent* e)
bool CheckBox::isFunctionSupported(int f)
{
- return f == DCOP::text || f == DCOP::setText || f == DCOP::checked || f == DCOP::setChecked || f == DCOP::geometry || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor;
+ return f == DCOP::text || f == DCOP::setText || f == DCOP::checked || f == DCOP::setChecked || f == DCOP::tqgeometry || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor;
}
void CheckBox::contextMenuEvent( TQContextMenuEvent * e )
@@ -125,7 +125,7 @@ TQString CheckBox::handleDCOP(int function, const TQStringList& args)
case DCOP::setChecked:
setChecked(args[0] != "false" && args[0] != "0");
break;
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/checkbox.h b/kommander/widgets/checkbox.h
index 4dde80de..acd2144f 100644
--- a/kommander/widgets/checkbox.h
+++ b/kommander/widgets/checkbox.h
@@ -34,10 +34,11 @@ class TQShowEvent;
class KOMMANDER_EXPORT CheckBox : public TQCheckBox, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
CheckBox(TQWidget *a_parent, const char *a_name);
~CheckBox();
diff --git a/kommander/widgets/closebutton.cpp b/kommander/widgets/closebutton.cpp
index 9a9aa4f8..a8892d13 100644
--- a/kommander/widgets/closebutton.cpp
+++ b/kommander/widgets/closebutton.cpp
@@ -31,7 +31,7 @@
#include "closebutton.h"
CloseButton::CloseButton(TQWidget* a_parent, const char* a_name)
- : KPushButton(a_parent, a_name), KommanderWidget(this)
+ : KPushButton(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -41,14 +41,14 @@ CloseButton::CloseButton(TQWidget* a_parent, const char* a_name)
connect(this, TQT_SIGNAL(clicked()), this, TQT_SLOT(startProcess()));
- TQObject *parent = this;
- while (parent->parent() != 0)
+ TQObject *tqparent = TQT_TQOBJECT(this);
+ while (tqparent->tqparent() != 0)
{
- parent = parent->parent();
- if (parent->inherits(TQDIALOG_OBJECT_NAME_STRING))
+ tqparent = tqparent->tqparent();
+ if (tqparent->inherits(TQDIALOG_OBJECT_NAME_STRING))
break;
}
- connect(this, TQT_SIGNAL(clicked()), parent, TQT_SLOT(reject()));
+ connect(this, TQT_SIGNAL(clicked()), tqparent, TQT_SLOT(reject()));
}
CloseButton::~CloseButton()
diff --git a/kommander/widgets/closebutton.h b/kommander/widgets/closebutton.h
index 42ff3627..c1971588 100644
--- a/kommander/widgets/closebutton.h
+++ b/kommander/widgets/closebutton.h
@@ -33,11 +33,12 @@ class TQShowEvent;
class KOMMANDER_EXPORT CloseButton : public KPushButton, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
- Q_PROPERTY(bool writeStdout READ writeStdout WRITE setWriteStdout)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(bool writeStdout READ writeStdout WRITE setWriteStdout)
public:
CloseButton(TQWidget* a_parent, const char* a_name);
~CloseButton();
diff --git a/kommander/widgets/combobox.cpp b/kommander/widgets/combobox.cpp
index cab29337..4efa3a2c 100644
--- a/kommander/widgets/combobox.cpp
+++ b/kommander/widgets/combobox.cpp
@@ -30,14 +30,14 @@
#include "combobox.h"
enum Functions {
- FirstFunction = 353, //CHANGE THIS NUMBER TO AN UNIQUE ONE!!!
+ FirstFunction = 353, //CHANGE THIS NUMBER TO AN UNITQUE ONE!!!
popupList,
LastFunction
};
ComboBox::ComboBox(TQWidget *a_parent, const char *a_name)
- : KComboBox(a_parent, a_name), KommanderWidget(this)
+ : KComboBox(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -121,7 +121,7 @@ bool ComboBox::isFunctionSupported(int f)
return f == DCOP::text || f == DCOP::selection || f == DCOP::setSelection ||
f == DCOP::currentItem || f == DCOP::setCurrentItem || f == DCOP::item ||
f == DCOP::removeItem || f == DCOP::insertItem || f == DCOP::insertItems ||
- f == DCOP::addUniqueItem || f == DCOP::clear || f == DCOP::count || f == DCOP::setEditable || f == DCOP::geometry || f == DCOP::hasFocus || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor || (f >= FirstFunction && f <= LastFunction);
+ f == DCOP::addUniqueItem || f == DCOP::clear || f == DCOP::count || f == DCOP::setEditable || f == DCOP::tqgeometry || f == DCOP::hasFocus || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor || (f >= FirstFunction && f <= LastFunction);
}
TQString ComboBox::handleDCOP(int function, const TQStringList& args)
@@ -192,7 +192,7 @@ TQString ComboBox::handleDCOP(int function, const TQStringList& args)
case popupList:
TQComboBox::popup();
break;
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/combobox.h b/kommander/widgets/combobox.h
index 5fb5306d..4ba5393b 100644
--- a/kommander/widgets/combobox.h
+++ b/kommander/widgets/combobox.h
@@ -34,10 +34,11 @@ class TQShowEvent;
class KOMMANDER_EXPORT ComboBox : public KComboBox, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
ComboBox(TQWidget *a_parent, const char *a_name);
diff --git a/kommander/widgets/datepicker.cpp b/kommander/widgets/datepicker.cpp
index 928e1b81..1e321ed5 100644
--- a/kommander/widgets/datepicker.cpp
+++ b/kommander/widgets/datepicker.cpp
@@ -27,7 +27,7 @@
#include "datepicker.h"
DatePicker::DatePicker(TQWidget *a_parent, const char *a_name)
- : KDatePicker(a_parent, a_name), KommanderWidget(this)
+ : KDatePicker(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -101,7 +101,7 @@ void DatePicker::contextMenuEvent( TQContextMenuEvent * e )
bool DatePicker::isFunctionSupported(int f)
{
- return f == DCOP::text || f == DCOP::setText || f == DCOP::geometry || f == DCOP::hasFocus ;
+ return f == DCOP::text || f == DCOP::setText || f == DCOP::tqgeometry || f == DCOP::hasFocus ;
}
TQString DatePicker::handleDCOP(int function, const TQStringList& args)
@@ -112,7 +112,7 @@ TQString DatePicker::handleDCOP(int function, const TQStringList& args)
case DCOP::setText:
setDate(TQDate::fromString(args[0], Qt::ISODate));
break;
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/datepicker.h b/kommander/widgets/datepicker.h
index 61644f92..ebf3a7da 100644
--- a/kommander/widgets/datepicker.h
+++ b/kommander/widgets/datepicker.h
@@ -34,10 +34,11 @@ class TQShowEvent;
class KOMMANDER_EXPORT DatePicker : public KDatePicker, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
DatePicker(TQWidget *a_parent, const char *a_name);
diff --git a/kommander/widgets/dialog.cpp b/kommander/widgets/dialog.cpp
index fd3b0b27..15dd7e30 100644
--- a/kommander/widgets/dialog.cpp
+++ b/kommander/widgets/dialog.cpp
@@ -34,14 +34,14 @@
enum Functions {
FirstFunction = 185,
- D_focusWidget,
+ D_tqfocusWidget,
D_waitCursor,
D_restoreCursor,
LastFunction
};
Dialog::Dialog(TQWidget *a_parent, const char *a_name, bool a_modal, int a_flags)
- : TQDialog(a_parent, a_name, a_modal, a_flags), KommanderWindow(this)
+ : TQDialog(a_parent, a_name, a_modal, a_flags), KommanderWindow(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -53,7 +53,7 @@ Dialog::Dialog(TQWidget *a_parent, const char *a_name, bool a_modal, int a_flags
m_shebang = "#!/usr/bin/kmdr-executor";
m_firstShow = true;
KommanderPlugin::setDefaultGroup(Group::DCOP);
- KommanderPlugin::registerFunction(D_focusWidget, "focusWidget(TQString widget)", i18n("The name of the widget having focus"), 1);
+ KommanderPlugin::registerFunction(D_tqfocusWidget, "tqfocusWidget(TQString widget)", i18n("The name of the widget having focus"), 1);
KommanderPlugin::registerFunction(D_waitCursor, "waitCursor(TQString widget)", i18n("Set a wait cursor. CAUTION: if set more than once an equal number of calls to restore must be made to clear it."), 1);
KommanderPlugin::registerFunction(D_restoreCursor, "restoreCursor(TQString widget)", i18n("Restore normal curser. NOTE: must be called as many times as wait was."), 1);
}
@@ -148,7 +148,7 @@ void Dialog::show()
{
//if the dialog is embedded in a KPart, the show can be called many times.
//to avoid re-init and sending signals we don't want, in that case call only the
-//QWidget's show method to show the widgets, but don't do any TQDialog specific
+//TQWidget's show method to show the widgets, but don't do any TQDialog specific
//task
if (!m_firstShow)
{
@@ -193,7 +193,7 @@ void Dialog::contextMenuEvent( TQContextMenuEvent * e )
bool Dialog::isFunctionSupported(int f)
{
- return f == DCOP::text || f == DCOP::setText || f == DCOP::geometry || (f > FirstFunction && f < LastFunction);
+ return f == DCOP::text || f == DCOP::setText || f == DCOP::tqgeometry || (f > FirstFunction && f < LastFunction);
}
TQString Dialog::handleDCOP(int function, const TQStringList& args)
@@ -204,14 +204,14 @@ TQString Dialog::handleDCOP(int function, const TQStringList& args)
case DCOP::setText:
setWidgetText(args[0]);
break;
- case DCOP::geometry:
+ case DCOP::tqgeometry:
return TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
break;
- case D_focusWidget:
- return focusWidget()->name();
+ case D_tqfocusWidget:
+ return tqfocusWidget()->name();
break;
case D_waitCursor:
- TQApplication::setOverrideCursor(TQCursor(Qt::WaitCursor));
+ TQApplication::setOverrideCursor(TQCursor(TQt::WaitCursor));
break;
case D_restoreCursor:
TQApplication::restoreOverrideCursor();
diff --git a/kommander/widgets/dialog.h b/kommander/widgets/dialog.h
index 90fa11c1..1c8cf5d6 100644
--- a/kommander/widgets/dialog.h
+++ b/kommander/widgets/dialog.h
@@ -29,14 +29,15 @@ class TQShowEvent;
class KOMMANDER_EXPORT Dialog : public TQDialog, public KommanderWindow
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
- Q_PROPERTY(bool useInternalParser READ useInternalParser WRITE setUseInternalParser)
- Q_PROPERTY(bool useShebang READ useShebang WRITE setUseShebang DESIGNABLE true)
- Q_PROPERTY(TQString shebang READ Shebang WRITE setShebang DESIGNABLE true)
- Q_OVERRIDE(bool modal DESIGNABLE false)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(bool useInternalParser READ useInternalParser WRITE setUseInternalParser)
+ TQ_PROPERTY(bool useShebang READ useShebang WRITE setUseShebang DESIGNABLE true)
+ TQ_PROPERTY(TQString shebang READ Shebang WRITE setShebang DESIGNABLE true)
+ TQ_OVERRIDE(bool modal DESIGNABLE false)
public:
Dialog(TQWidget *, const char *, bool = true, int=0);
diff --git a/kommander/widgets/execbutton.cpp b/kommander/widgets/execbutton.cpp
index eccfe306..be8f109d 100644
--- a/kommander/widgets/execbutton.cpp
+++ b/kommander/widgets/execbutton.cpp
@@ -40,7 +40,7 @@
using namespace std;
enum Functions {
- FirstFunction = 260, //CHANGE THIS NUMBER TO AN UNIQUE ONE!!!
+ FirstFunction = 260, //CHANGE THIS NUMBER TO AN UNITQUE ONE!!!
EB_isOn,
EB_setPopup,
EB_setButtonText,
@@ -48,7 +48,7 @@ enum Functions {
};
ExecButton::ExecButton(TQWidget* a_parent, const char* a_name)
- : KPushButton(a_parent, a_name), KommanderWidget(this)
+ : KPushButton(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -113,11 +113,11 @@ void ExecButton::setWidgetText(const TQString& a_text)
void ExecButton::startProcess()
{
TQString at = evalAssociatedText().stripWhiteSpace();
- bool enabledStatus = isEnabled();
+ bool enabledtqStatus = isEnabled();
if (m_blockGUI != None)
setEnabled(false);
if (m_blockGUI == GUI)
- KApplication::setOverrideCursor(TQCursor(Qt::WaitCursor));
+ KApplication::setOverrideCursor(TQCursor(TQt::WaitCursor));
MyProcess* process = new MyProcess(this);
process->setBlocking(m_blockGUI == GUI);
connect(process, TQT_SIGNAL(processExited(MyProcess*)), TQT_SLOT(processExited(MyProcess*)));
@@ -128,7 +128,7 @@ void ExecButton::startProcess()
if (writeStdout())
cout << m_output << flush;
}
- setEnabled(enabledStatus);
+ setEnabled(enabledtqStatus);
}
@@ -180,7 +180,7 @@ void ExecButton::contextMenuEvent( TQContextMenuEvent * e )
bool ExecButton::isFunctionSupported(int f)
{
- return f == DCOP::text || f == DCOP::setText || f == DCOP::execute || f == DCOP::geometry || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor || (f >= FirstFunction && f <= LastFunction);
+ return f == DCOP::text || f == DCOP::setText || f == DCOP::execute || f == DCOP::tqgeometry || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor || (f >= FirstFunction && f <= LastFunction);
}
TQString ExecButton::handleDCOP(int function, const TQStringList& args)
@@ -202,7 +202,7 @@ TQString ExecButton::handleDCOP(int function, const TQStringList& args)
break;
case EB_setPopup:
{
- TQWidgetList *list = TQApplication::allWidgets();
+ TQWidgetList *list = TQApplication::tqallWidgets();
TQWidgetListIt it( *list );
TQWidget * w;
while ( (w=it.current()) != 0 ) { // for each widget...
@@ -215,7 +215,7 @@ TQString ExecButton::handleDCOP(int function, const TQStringList& args)
}
break;
}
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/execbutton.h b/kommander/widgets/execbutton.h
index b646e5e7..6e8c478f 100644
--- a/kommander/widgets/execbutton.h
+++ b/kommander/widgets/execbutton.h
@@ -36,13 +36,14 @@ class TQShowEvent;
class KOMMANDER_EXPORT ExecButton : public KPushButton, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
Q_ENUMS(Blocking)
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
- Q_PROPERTY(bool writeStdout READ writeStdout WRITE setWriteStdout)
- Q_PROPERTY(Blocking blockGUI READ blockGUI WRITE setBlockGUI)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(bool writeStdout READ writeStdout WRITE setWriteStdout)
+ TQ_PROPERTY(Blocking blockGUI READ blockGUI WRITE setBlockGUI)
public:
ExecButton(TQWidget *a_parent, const char *a_name);
diff --git a/kommander/widgets/fileselector.cpp b/kommander/widgets/fileselector.cpp
index a7c29673..f6806e5b 100644
--- a/kommander/widgets/fileselector.cpp
+++ b/kommander/widgets/fileselector.cpp
@@ -35,7 +35,7 @@
#include "fileselector.h"
FileSelector::FileSelector(TQWidget * a_parent, const char *a_name)
- : TQWidget(a_parent, a_name), KommanderWidget(this)
+ : TQWidget(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -50,9 +50,9 @@ FileSelector::FileSelector(TQWidget * a_parent, const char *a_name)
m_boxLayout->addWidget(m_lineEdit);
m_boxLayout->addWidget(m_selectButton);
- setSizePolicy(m_lineEdit->sizePolicy());
- m_lineEdit->setSizePolicy(TQSizePolicy(TQSizePolicy::Expanding, TQSizePolicy::Expanding));
- m_selectButton->setSizePolicy(TQSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Expanding));
+ tqsetSizePolicy(m_lineEdit->sizePolicy());
+ m_lineEdit->tqsetSizePolicy(TQSizePolicy(TQSizePolicy::Expanding, TQSizePolicy::Expanding));
+ m_selectButton->tqsetSizePolicy(TQSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Expanding));
connect(m_selectButton, TQT_SIGNAL(clicked()), this, TQT_SLOT(makeSelection()));
@@ -222,13 +222,13 @@ TQString FileSelector::handleDCOP(int function, const TQStringList& args)
return m_lineEdit->selectedText();
case DCOP::setSelection:
{
- int f = m_lineEdit->text().find(args[0]);
+ int f = m_lineEdit->text().tqfind(args[0]);
if (f != -1)
m_lineEdit->setSelection(f, args[0].length());
break;
}
case DCOP::clear:
- setWidgetText(TQString::null);
+ setWidgetText(TQString());
break;
default:
return KommanderWidget::handleDCOP(function, args);
diff --git a/kommander/widgets/fileselector.h b/kommander/widgets/fileselector.h
index 44758131..fd254fd6 100644
--- a/kommander/widgets/fileselector.h
+++ b/kommander/widgets/fileselector.h
@@ -36,17 +36,18 @@ class TQShowEvent;
class KOMMANDER_EXPORT FileSelector : public TQWidget, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
- Q_PROPERTY(bool showEditor READ showEditor WRITE setShowEditor)
- Q_PROPERTY(TQString buttonCaption READ caption WRITE setCaption)
- Q_PROPERTY(TQString selectionFilter READ selectionFilter WRITE setSelectionFilter)
- Q_PROPERTY(TQString selectionCaption READ selectionCaption WRITE setSelectionCaption)
- Q_PROPERTY(SelectionType selectionType READ selectionType WRITE setSelectionType)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(bool showEditor READ showEditor WRITE setShowEditor)
+ TQ_PROPERTY(TQString buttonCaption READ caption WRITE setCaption)
+ TQ_PROPERTY(TQString selectionFilter READ selectionFilter WRITE setSelectionFilter)
+ TQ_PROPERTY(TQString selectionCaption READ selectionCaption WRITE setSelectionCaption)
+ TQ_PROPERTY(SelectionType selectionType READ selectionType WRITE setSelectionType)
Q_ENUMS(SelectionType)
- Q_PROPERTY(bool selectionOpenMultiple READ selectionOpenMultiple WRITE setSelectionOpenMultiple)
+ TQ_PROPERTY(bool selectionOpenMultiple READ selectionOpenMultiple WRITE setSelectionOpenMultiple)
public:
FileSelector(TQWidget *a_parent, const char *a_name);
diff --git a/kommander/widgets/fontdialog.cpp b/kommander/widgets/fontdialog.cpp
index 5fc17edc..3efde0f4 100644
--- a/kommander/widgets/fontdialog.cpp
+++ b/kommander/widgets/fontdialog.cpp
@@ -28,8 +28,8 @@ enum Functions {
LastFunction
};
-FontDialog::FontDialog(TQWidget *parent, const char *name)
- : TQLabel(parent, name), KommanderWidget(this)
+FontDialog::FontDialog(TQWidget *tqparent, const char *name)
+ : TQLabel(tqparent, name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
diff --git a/kommander/widgets/fontdialog.h b/kommander/widgets/fontdialog.h
index f7ccdf0f..46c828e2 100644
--- a/kommander/widgets/fontdialog.h
+++ b/kommander/widgets/fontdialog.h
@@ -23,11 +23,12 @@
class FontDialog : public TQLabel, public KommanderWidget
{
Q_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_OBJECT
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
- FontDialog(TQWidget *parent = 0, const char *name = 0);
+ FontDialog(TQWidget *tqparent = 0, const char *name = 0);
~FontDialog();
@@ -44,6 +45,7 @@ public slots:
virtual void setWidgetText(const TQString &);
virtual void populate();
+public:
TQFont m_font;
};
diff --git a/kommander/widgets/groupbox.cpp b/kommander/widgets/groupbox.cpp
index 7ca1c199..aef8042d 100644
--- a/kommander/widgets/groupbox.cpp
+++ b/kommander/widgets/groupbox.cpp
@@ -32,7 +32,7 @@
GroupBox::GroupBox(TQWidget *a_parent, const char *a_name)
- : TQGroupBox(a_parent, a_name), KommanderWidget(this)
+ : TQGroupBox(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -84,13 +84,13 @@ void GroupBox::populate()
void GroupBox::insertChild(TQObject *a_child)
{
m_childList.append(a_child);
- TQObject::insertChild(a_child);
+ TQT_TQOBJECT(this)->TQObject::insertChild(a_child);
}
void GroupBox::removeChild(TQObject *a_child)
{
m_childList.remove(a_child);
- TQObject::removeChild(a_child);
+ TQT_TQOBJECT(this)->TQObject::removeChild(a_child);
}
void GroupBox::showEvent( TQShowEvent *e )
@@ -108,7 +108,7 @@ void GroupBox::contextMenuEvent( TQContextMenuEvent * e )
bool GroupBox::isFunctionSupported(int f)
{
- return f == DCOP::text || f == DCOP::setText || f == DCOP::geometry || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor;
+ return f == DCOP::text || f == DCOP::setText || f == DCOP::tqgeometry || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor;
// || (f >= FirstFunction && f <= LastFunction);
}
@@ -126,7 +126,7 @@ TQString GroupBox::handleDCOP(int function, const TQStringList& args)
case DCOP::setText:
setTitle(args[0]);
break;
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/groupbox.h b/kommander/widgets/groupbox.h
index b624cd15..ebfd9a74 100644
--- a/kommander/widgets/groupbox.h
+++ b/kommander/widgets/groupbox.h
@@ -34,10 +34,11 @@ class TQShowEvent;
class KOMMANDER_EXPORT GroupBox : public TQGroupBox, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
GroupBox(TQWidget *a_parent, const char *a_name);
~GroupBox();
diff --git a/kommander/widgets/konsole.cpp b/kommander/widgets/konsole.cpp
index c27cb8fe..728d9b1f 100644
--- a/kommander/widgets/konsole.cpp
+++ b/kommander/widgets/konsole.cpp
@@ -26,7 +26,7 @@
#include <myprocess.h>
Konsole::Konsole(TQWidget* a_parent, const char* a_name)
- : KTextEdit(a_parent, a_name), KommanderWidget(this), mSeenEOL(false), mProcess(false)
+ : KTextEdit(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this)), mSeenEOL(false), mProcess(false)
{
TQStringList states;
states << "default";
@@ -89,7 +89,7 @@ void Konsole::execute()
mProcess->setBlocking(false);
connect(mProcess, TQT_SIGNAL(processExited(MyProcess*)), TQT_SLOT(processExited(MyProcess*)));
connect(mProcess, TQT_SIGNAL(processReceivedStdout(MyProcess*, char*, int)), TQT_SLOT(processReceivedStdout(MyProcess*, char*, int)));
- setCursor(TQCursor(Qt::WaitCursor));
+ setCursor(TQCursor(TQt::WaitCursor));
mProcess->run(at);
}
diff --git a/kommander/widgets/konsole.h b/kommander/widgets/konsole.h
index 894060f9..efd34042 100644
--- a/kommander/widgets/konsole.h
+++ b/kommander/widgets/konsole.h
@@ -32,11 +32,12 @@ class MyProcess;
class KOMMANDER_EXPORT Konsole : public KTextEdit, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_OVERRIDE(bool readOnly DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_OVERRIDE(bool readOnly DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
Konsole(TQWidget *a_parent, const char *a_name);
diff --git a/kommander/widgets/label.cpp b/kommander/widgets/label.cpp
index ee422325..ce56b3c4 100644
--- a/kommander/widgets/label.cpp
+++ b/kommander/widgets/label.cpp
@@ -26,7 +26,7 @@
#include "label.h"
Label::Label(TQWidget *a_parent, const char *a_name)
- : TQLabel(a_parent, a_name), KommanderWidget(this)
+ : TQLabel(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -88,7 +88,7 @@ void Label::showEvent(TQShowEvent *e)
bool Label::isFunctionSupported(int f)
{
- return f == DCOP::text || f == DCOP::setText || f == DCOP::clear || f == DCOP::geometry || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor;
+ return f == DCOP::text || f == DCOP::setText || f == DCOP::clear || f == DCOP::tqgeometry || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor;
}
TQString Label::handleDCOP(int function, const TQStringList& args)
@@ -102,7 +102,7 @@ TQString Label::handleDCOP(int function, const TQStringList& args)
case DCOP::clear:
setWidgetText("");
break;
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/label.h b/kommander/widgets/label.h
index 70b8b248..31a25198 100644
--- a/kommander/widgets/label.h
+++ b/kommander/widgets/label.h
@@ -33,10 +33,11 @@ class TQShowEvent;
class KOMMANDER_EXPORT Label : public TQLabel, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
Label(TQWidget *a_parent, const char *a_name);
~Label();
diff --git a/kommander/widgets/lineedit.cpp b/kommander/widgets/lineedit.cpp
index 08913b4e..2f4f9de6 100644
--- a/kommander/widgets/lineedit.cpp
+++ b/kommander/widgets/lineedit.cpp
@@ -31,7 +31,7 @@ enum functions {
};
LineEdit::LineEdit(TQWidget *a_parent, const char *a_name)
- : KLineEdit(a_parent, a_name), KommanderWidget((TQObject *)this)
+ : KLineEdit(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -124,7 +124,7 @@ void LineEdit::contextMenuEvent( TQContextMenuEvent * e )
bool LineEdit::isFunctionSupported(int f)
{
return f == DCOP::text || f == DCOP::setText || f == DCOP::selection || f == DCOP::setSelection ||
- f == DCOP::clear || f == DCOP::setEditable || f == DCOP::geometry || f == DCOP::hasFocus || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor || f == DCOP::isModified || (f >= FirstFunction && f <= LastFunction) ;
+ f == DCOP::clear || f == DCOP::setEditable || f == DCOP::tqgeometry || f == DCOP::hasFocus || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor || f == DCOP::isModified || (f >= FirstFunction && f <= LastFunction) ;
}
TQString LineEdit::handleDCOP(int function, const TQStringList& args)
@@ -146,7 +146,7 @@ TQString LineEdit::handleDCOP(int function, const TQStringList& args)
case DCOP::setEditable:
setReadOnly(args[0] == "false" || args[0] == "0");
break;
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/lineedit.h b/kommander/widgets/lineedit.h
index d0ee32f5..654ff4dc 100644
--- a/kommander/widgets/lineedit.h
+++ b/kommander/widgets/lineedit.h
@@ -34,10 +34,11 @@ class TQShowEvent;
class KOMMANDER_EXPORT LineEdit : public KLineEdit, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
LineEdit(TQWidget *, const char *);
virtual ~LineEdit();
diff --git a/kommander/widgets/listbox.cpp b/kommander/widgets/listbox.cpp
index 3dd36357..1135a540 100644
--- a/kommander/widgets/listbox.cpp
+++ b/kommander/widgets/listbox.cpp
@@ -30,7 +30,7 @@
#include "listbox.h"
ListBox::ListBox(TQWidget *a_parent, const char *a_name)
- : KListBox(a_parent, a_name), KommanderWidget(this)
+ : KListBox(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -96,7 +96,7 @@ bool ListBox::isFunctionSupported(int f)
return f == DCOP::text || f == DCOP::setText || f == DCOP::selection || f == DCOP::setSelection ||
f == DCOP::insertItems || f == DCOP::insertItem || f == DCOP::removeItem || f == DCOP::clear ||
f == DCOP::currentItem || f == DCOP::setCurrentItem || f == DCOP::item || f == DCOP::addUniqueItem ||
- f == DCOP::findItem || f == DCOP::setPixmap || f == DCOP::count || f == DCOP::geometry || f == DCOP::hasFocus || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor;
+ f == DCOP::findItem || f == DCOP::setPixmap || f == DCOP::count || f == DCOP::tqgeometry || f == DCOP::hasFocus || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor;
}
void ListBox::contextMenuEvent( TQContextMenuEvent * e )
@@ -125,7 +125,7 @@ TQString ListBox::handleDCOP(int function, const TQStringList& args)
}
case DCOP::setSelection:
{
- TQListBoxItem* found = findItem(args[0], Qt::ExactMatch);
+ TQListBoxItem* found = tqfindItem(args[0], TQt::ExactMatch);
if (found)
setCurrentItem(index(found));
break;
@@ -162,14 +162,14 @@ TQString ListBox::handleDCOP(int function, const TQStringList& args)
return TQString();
}
case DCOP::addUniqueItem:
- if (!findItem(args[0], Qt::ExactMatch))
+ if (!tqfindItem(args[0], TQt::ExactMatch))
insertItem(args[0]);
break;
case DCOP::findItem:
{
- TQListBoxItem* found = findItem(args[0], Qt::ExactMatch);
- if (!found) found = findItem(args[0], Qt::BeginsWith);
- if (!found) found = findItem(args[0], Qt::Contains);
+ TQListBoxItem* found = tqfindItem(args[0], TQt::ExactMatch);
+ if (!found) found = tqfindItem(args[0], TQt::BeginsWith);
+ if (!found) found = tqfindItem(args[0], TQt::Contains);
if (found)
return TQString::number(index(found));
else return TQString::number(-1);
@@ -197,7 +197,7 @@ TQString ListBox::handleDCOP(int function, const TQStringList& args)
strings += item(i)->text();
return strings.join("\n");
}
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/listbox.h b/kommander/widgets/listbox.h
index dd59bc3b..84fff290 100644
--- a/kommander/widgets/listbox.h
+++ b/kommander/widgets/listbox.h
@@ -34,10 +34,11 @@ class TQShowEvent;
class KOMMANDER_EXPORT ListBox : public KListBox, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
ListBox(TQWidget *a_parent, const char *a_name);
~ListBox();
diff --git a/kommander/widgets/pixmaplabel.cpp b/kommander/widgets/pixmaplabel.cpp
index 78077c5c..e8b013db 100644
--- a/kommander/widgets/pixmaplabel.cpp
+++ b/kommander/widgets/pixmaplabel.cpp
@@ -31,7 +31,7 @@
#include "pixmaplabel.h"
PixmapLabel::PixmapLabel(TQWidget *a_parent, const char *a_name)
- : TQLabel(a_parent, a_name), KommanderWidget(this)
+ : TQLabel(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -103,7 +103,7 @@ void PixmapLabel::contextMenuEvent( TQContextMenuEvent * e )
bool PixmapLabel::isFunctionSupported(int f)
{
- return f == DCOP::text || f == DCOP::setText || f == DCOP::clear || f == DCOP::geometry;
+ return f == DCOP::text || f == DCOP::setText || f == DCOP::clear || f == DCOP::tqgeometry;
}
TQString PixmapLabel::handleDCOP(int function, const TQStringList& args)
@@ -117,7 +117,7 @@ TQString PixmapLabel::handleDCOP(int function, const TQStringList& args)
break;
case DCOP::text:
return text();
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/pixmaplabel.h b/kommander/widgets/pixmaplabel.h
index dbc3e113..72f66077 100644
--- a/kommander/widgets/pixmaplabel.h
+++ b/kommander/widgets/pixmaplabel.h
@@ -34,9 +34,10 @@ class TQShowEvent;
class KOMMANDER_EXPORT PixmapLabel : public TQLabel, public KommanderWidget
{
Q_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_OBJECT
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
PixmapLabel(TQWidget *a_parent, const char *a_name);
~PixmapLabel();
diff --git a/kommander/widgets/plugin.cpp b/kommander/widgets/plugin.cpp
index 020ae6da..009da398 100644
--- a/kommander/widgets/plugin.cpp
+++ b/kommander/widgets/plugin.cpp
@@ -57,7 +57,7 @@ class KomStdPlugin : public KommanderPlugin
{
public:
KomStdPlugin();
- virtual TQWidget *create( const TQString &key, TQWidget *parent = 0, const char *name = 0 );
+ virtual TQWidget *create( const TQString &key, TQWidget *tqparent = 0, const char *name = 0 );
};
KomStdPlugin::KomStdPlugin()
@@ -97,41 +97,41 @@ KomStdPlugin::KomStdPlugin()
addWidget("AboutDialog", group, "", new TQIconSet(KGlobal::iconLoader()->loadIcon("kommander", KIcon::NoGroup, KIcon::SizeMedium)));
}
-TQWidget *KomStdPlugin::create( const TQString &key, TQWidget *parent, const char *name )
+TQWidget *KomStdPlugin::create( const TQString &key, TQWidget *tqparent, const char *name )
{
- if (key == "ButtonGroup") return new ButtonGroup(parent, name);
- else if (key == "CheckBox") return new CheckBox(parent, name);
- else if (key == "CloseButton") return new CloseButton(parent, name);
- else if (key == "ComboBox") return new ComboBox(parent, name);
- else if (key == "Dialog") return new Dialog(parent, name);
- else if (key == "ExecButton") return new ExecButton(parent, name);
- else if (key == "FileSelector") return new FileSelector(parent, name);
- else if (key == "GroupBox") return new GroupBox(parent, name);
- else if (key == "Konsole") return new Konsole(parent, name);
- else if (key == "Label") return new Label(parent, name);
- else if (key == "LineEdit") return new LineEdit(parent, name);
- else if (key == "ListBox") return new ListBox(parent, name);
- else if (key == "PixmapLabel") return new PixmapLabel(parent, name);
- else if (key == "ProgressBar") return new ProgressBar(parent, name);
- else if (key == "RadioButton") return new RadioButton(parent, name);
- else if (key == "RichTextEditor") return new RichTextEditor(parent, name);
- else if (key == "ScriptObject") return new ScriptObject(parent, name);
- else if (key == "Slider") return new Slider(parent, name);
- else if (key == "SpinBoxInt") return new SpinBoxInt(parent, name);
- else if (key == "StatusBar") return new StatusBar(parent, name);
- else if (key == "SubDialog") return new SubDialog(parent, name);
- else if (key == "Table") return new Table(parent, name);
- else if (key == "TabWidget") return new TabWidget(parent, name);
- else if (key == "ToolBox") return new ToolBox(parent, name);
- else if (key == "TextBrowser") return new TextBrowser(parent, name);
- else if (key == "TextEdit") return new TextEdit(parent, name);
- else if (key == "Timer") return new Timer(parent, name);
- else if (key == "TreeWidget") return new TreeWidget(parent, name);
- else if (key == "Wizard") return new Wizard(parent, name);
- else if (key == "DatePicker") return new DatePicker(parent, name);
- else if (key == "PopupMenu") return new PopupMenu(parent, name);
- else if (key == "FontDialog") return new FontDialog(parent, name);
- else if (key == "AboutDialog") return new AboutDialog(parent, name);
+ if (key == "ButtonGroup") return new ButtonGroup(tqparent, name);
+ else if (key == "CheckBox") return new CheckBox(tqparent, name);
+ else if (key == "CloseButton") return new CloseButton(tqparent, name);
+ else if (key == "ComboBox") return new ComboBox(tqparent, name);
+ else if (key == "Dialog") return new Dialog(tqparent, name);
+ else if (key == "ExecButton") return new ExecButton(tqparent, name);
+ else if (key == "FileSelector") return new FileSelector(tqparent, name);
+ else if (key == "GroupBox") return new GroupBox(tqparent, name);
+ else if (key == "Konsole") return new Konsole(tqparent, name);
+ else if (key == "Label") return new Label(tqparent, name);
+ else if (key == "LineEdit") return new LineEdit(tqparent, name);
+ else if (key == "ListBox") return new ListBox(tqparent, name);
+ else if (key == "PixmapLabel") return new PixmapLabel(tqparent, name);
+ else if (key == "ProgressBar") return new ProgressBar(tqparent, name);
+ else if (key == "RadioButton") return new RadioButton(tqparent, name);
+ else if (key == "RichTextEditor") return new RichTextEditor(tqparent, name);
+ else if (key == "ScriptObject") return new ScriptObject(tqparent, name);
+ else if (key == "Slider") return new Slider(tqparent, name);
+ else if (key == "SpinBoxInt") return new SpinBoxInt(tqparent, name);
+ else if (key == "StatusBar") return new StatusBar(tqparent, name);
+ else if (key == "SubDialog") return new SubDialog(tqparent, name);
+ else if (key == "Table") return new Table(tqparent, name);
+ else if (key == "TabWidget") return new TabWidget(tqparent, name);
+ else if (key == "ToolBox") return new ToolBox(tqparent, name);
+ else if (key == "TextBrowser") return new TextBrowser(tqparent, name);
+ else if (key == "TextEdit") return new TextEdit(tqparent, name);
+ else if (key == "Timer") return new Timer(tqparent, name);
+ else if (key == "TreeWidget") return new TreeWidget(tqparent, name);
+ else if (key == "Wizard") return new Wizard(tqparent, name);
+ else if (key == "DatePicker") return new DatePicker(tqparent, name);
+ else if (key == "PopupMenu") return new PopupMenu(tqparent, name);
+ else if (key == "FontDialog") return new FontDialog(tqparent, name);
+ else if (key == "AboutDialog") return new AboutDialog(tqparent, name);
else return 0;
}
diff --git a/kommander/widgets/popupmenu.cpp b/kommander/widgets/popupmenu.cpp
index 48bb4474..e00ee485 100644
--- a/kommander/widgets/popupmenu.cpp
+++ b/kommander/widgets/popupmenu.cpp
@@ -32,8 +32,8 @@
#define INSERTSUBMENU 109
#define LAST_FUNCTION INSERTSUBMENU
-PopupMenu::PopupMenu(TQWidget *parent, const char *name)
- : TQLabel(parent, name), KommanderWidget(this)
+PopupMenu::PopupMenu(TQWidget *tqparent, const char *name)
+ : TQLabel(tqparent, name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -114,7 +114,7 @@ void PopupMenu::popup(int x, int y)
void PopupMenu::slotMenuItemActivated(int id)
{
TQString widget = m_associations[id];
- KommanderWidget::evalAssociatedText(TQString("#!kommander\n%1.execute(%2)").arg(widget).arg(id));
+ KommanderWidget::evalAssociatedText(TQString("#!kommander\n%1.execute(%2)").tqarg(widget).tqarg(id));
}
void PopupMenu::populate()
@@ -138,7 +138,7 @@ TQString PopupMenu::insertSubmenu(const TQString& title, const TQString &menuWid
bool PopupMenu::isFunctionSupported(int f)
{
- return f == DCOP::clear || f == DCOP::execute || f == DCOP::item || (f >= INSERTMENUITEM && f <= LAST_FUNCTION) || f == DCOP::count || f == DCOP::geometry;
+ return f == DCOP::clear || f == DCOP::execute || f == DCOP::item || (f >= INSERTMENUITEM && f <= LAST_FUNCTION) || f == DCOP::count || f == DCOP::tqgeometry;
}
TQString PopupMenu::handleDCOP(int function, const TQStringList& args)
@@ -223,13 +223,13 @@ TQString PopupMenu::handleDCOP(int function, const TQStringList& args)
case DCOP::item:
{
uint index = args[0].toInt();
- return index < m_params.count() ? m_params[index] : TQString::null;
+ return index < m_params.count() ? m_params[index] : TQString();
break;
}
case DCOP::count:
return TQString::number(m_menu->count());
break;
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/popupmenu.h b/kommander/widgets/popupmenu.h
index dff28a86..9a0dc925 100644
--- a/kommander/widgets/popupmenu.h
+++ b/kommander/widgets/popupmenu.h
@@ -25,11 +25,12 @@ class KPopupMenu;
class PopupMenu : public TQLabel, public KommanderWidget
{
Q_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_OBJECT
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
- PopupMenu(TQWidget *parent = 0, const char *name = 0);
+ PopupMenu(TQWidget *tqparent = 0, const char *name = 0);
~PopupMenu();
virtual bool isKommanderWidget() const;
diff --git a/kommander/widgets/progressbar.cpp b/kommander/widgets/progressbar.cpp
index 30d4f329..b010af91 100644
--- a/kommander/widgets/progressbar.cpp
+++ b/kommander/widgets/progressbar.cpp
@@ -36,7 +36,7 @@ enum Functions {
};
ProgressBar::ProgressBar(TQWidget *a_parent, const char *a_name)
- : KProgress(a_parent, a_name), KommanderWidget(this)
+ : KProgress(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -94,7 +94,7 @@ void ProgressBar::showEvent(TQShowEvent *e)
bool ProgressBar::isFunctionSupported(int f)
{
- return f == DCOP::text || f == DCOP::setText || f == DCOP::clear || f == DCOP::setMaximum || f == DCOP::geometry || (f > FirstFunction && f < LastFunction);
+ return f == DCOP::text || f == DCOP::setText || f == DCOP::clear || f == DCOP::setMaximum || f == DCOP::tqgeometry || (f > FirstFunction && f < LastFunction);
}
TQString ProgressBar::handleDCOP(int function, const TQStringList& args)
@@ -111,7 +111,7 @@ TQString ProgressBar::handleDCOP(int function, const TQStringList& args)
case DCOP::setMaximum:
setTotalSteps(args[0].toUInt());
break;
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
@@ -123,7 +123,7 @@ TQString ProgressBar::handleDCOP(int function, const TQStringList& args)
color.setNamedColor(args[0]);
TQPalette p = this->palette();
p.setColor(TQPalette::Active, TQColorGroup::Highlight, color);
- this->setPalette( p, TRUE );
+ this->tqsetPalette( p, TRUE );
break;
}
case PB_setHightlightTextColor:
@@ -132,7 +132,7 @@ TQString ProgressBar::handleDCOP(int function, const TQStringList& args)
color.setNamedColor(args[0]);
TQPalette p = this->palette();
p.setColor(TQPalette::Active, TQColorGroup::HighlightedText, color);
- this->setPalette( p, TRUE );
+ this->tqsetPalette( p, TRUE );
break;
}
default:
diff --git a/kommander/widgets/progressbar.h b/kommander/widgets/progressbar.h
index ca5daf8c..182a2faa 100644
--- a/kommander/widgets/progressbar.h
+++ b/kommander/widgets/progressbar.h
@@ -33,10 +33,11 @@ class TQShowEvent;
class KOMMANDER_EXPORT ProgressBar: public KProgress, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
ProgressBar(TQWidget *a_parent, const char *a_name);
diff --git a/kommander/widgets/radiobutton.cpp b/kommander/widgets/radiobutton.cpp
index ba46248d..317263e4 100644
--- a/kommander/widgets/radiobutton.cpp
+++ b/kommander/widgets/radiobutton.cpp
@@ -28,7 +28,7 @@
#include "radiobutton.h"
RadioButton::RadioButton(TQWidget *a_parent, const char *a_name)
- : TQRadioButton(a_parent, a_name), KommanderWidget(this)
+ : TQRadioButton(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "unchecked";
@@ -101,7 +101,7 @@ void RadioButton::contextMenuEvent( TQContextMenuEvent * e )
bool RadioButton::isFunctionSupported(int f)
{
- return f == DCOP::text || f == DCOP::setText || f == DCOP::setChecked || f == DCOP::checked || f == DCOP::geometry || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor;
+ return f == DCOP::text || f == DCOP::setText || f == DCOP::setChecked || f == DCOP::checked || f == DCOP::tqgeometry || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor;
}
TQString RadioButton::handleDCOP(int function, const TQStringList& args)
@@ -117,7 +117,7 @@ TQString RadioButton::handleDCOP(int function, const TQStringList& args)
break;
case DCOP::checked:
return TQString::number(isOn());
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/radiobutton.h b/kommander/widgets/radiobutton.h
index e93a96af..328cb853 100644
--- a/kommander/widgets/radiobutton.h
+++ b/kommander/widgets/radiobutton.h
@@ -33,10 +33,11 @@ class TQShowEvent;
class KOMMANDER_EXPORT RadioButton : public TQRadioButton, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
RadioButton(TQWidget *a_parent, const char *a_name);
~RadioButton();
diff --git a/kommander/widgets/richtexteditor.cpp b/kommander/widgets/richtexteditor.cpp
index 9e54f07c..e5de817b 100644
--- a/kommander/widgets/richtexteditor.cpp
+++ b/kommander/widgets/richtexteditor.cpp
@@ -43,7 +43,7 @@
#include "pixmaps/textright.xpm"
RichTextEditor::RichTextEditor(TQWidget *a_parent, const char *a_name)
- : TQWidget(a_parent, a_name), KommanderWidget((TQObject *)this)
+ : TQWidget(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
@@ -61,11 +61,11 @@ RichTextEditor::RichTextEditor(TQWidget *a_parent, const char *a_name)
m_textedit = new TQTextEdit(this, "editor");
m_textedit->setTextFormat(RichText);
- // layout the widgets
- TQVBoxLayout *layout = new TQVBoxLayout(this);
- layout->addWidget(m_toolbar);
- layout->addWidget(m_textedit);
- layout->setSpacing(1);
+ // tqlayout the widgets
+ TQVBoxLayout *tqlayout = new TQVBoxLayout(this);
+ tqlayout->addWidget(m_toolbar);
+ tqlayout->addWidget(m_textedit);
+ tqlayout->setSpacing(1);
// setup buttons
TQHBoxLayout *tbLayout = new TQHBoxLayout(m_toolbar);
@@ -106,7 +106,7 @@ RichTextEditor::RichTextEditor(TQWidget *a_parent, const char *a_name)
connect(m_alignGroup, TQT_SIGNAL(clicked(int)), this, TQT_SLOT(textAlign(int)));
connect(m_textedit, TQT_SIGNAL(currentFontChanged(const TQFont &)), this, TQT_SLOT(fontChanged(const TQFont &)));
- connect(m_textedit, TQT_SIGNAL(currentAlignmentChanged(int)), this, TQT_SLOT(alignmentChanged(int)));
+ connect(m_textedit, TQT_SIGNAL(currentAlignmentChanged(int)), this, TQT_SLOT(tqalignmentChanged(int)));
connect(m_textedit, TQT_SIGNAL(textChanged()), this, TQT_SLOT(setTextChanged()));
@@ -180,13 +180,13 @@ void RichTextEditor::textItalic(bool a_isOn)
void RichTextEditor::textAlign(int a_id)
{
- TQToolButton *b = (TQToolButton *)m_alignGroup->find(a_id);
+ TQToolButton *b = (TQToolButton *)m_alignGroup->tqfind(a_id);
if(b == m_buttonTextLeft)
- m_textedit->setAlignment(Qt::AlignLeft);
+ m_textedit->tqsetAlignment(TQt::AlignLeft);
else if(b == m_buttonTextCenter)
- m_textedit->setAlignment(Qt::AlignCenter);
+ m_textedit->tqsetAlignment(TQt::AlignCenter);
else if(b == m_buttonTextRight)
- m_textedit->setAlignment(Qt::AlignRight);
+ m_textedit->tqsetAlignment(TQt::AlignRight);
}
void RichTextEditor::fontChanged(const TQFont &a_font)
@@ -196,13 +196,13 @@ void RichTextEditor::fontChanged(const TQFont &a_font)
m_buttonTextUnder->setOn(a_font.underline());
}
-void RichTextEditor::alignmentChanged(int a_alignment)
+void RichTextEditor::tqalignmentChanged(int a_tqalignment)
{
- if((a_alignment == AlignAuto) || (a_alignment & AlignLeft))
+ if((a_tqalignment == AlignAuto) || (a_tqalignment & AlignLeft))
m_buttonTextLeft->setOn(true);
- else if(a_alignment & AlignHCenter)
+ else if(a_tqalignment & AlignHCenter)
m_buttonTextCenter->setOn(true);
- else if(a_alignment & AlignRight)
+ else if(a_tqalignment & AlignRight)
m_buttonTextRight->setOn(true);
}
diff --git a/kommander/widgets/richtexteditor.h b/kommander/widgets/richtexteditor.h
index 17faf6b5..31347e96 100644
--- a/kommander/widgets/richtexteditor.h
+++ b/kommander/widgets/richtexteditor.h
@@ -37,10 +37,11 @@ class TQShowEvent;
class KOMMANDER_EXPORT RichTextEditor : public TQWidget, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
RichTextEditor(TQWidget *, const char *);
virtual ~RichTextEditor();
@@ -62,7 +63,7 @@ public slots:
void textUnder(bool);
void textItalic(bool);
void fontChanged(const TQFont &);
- void alignmentChanged(int);
+ void tqalignmentChanged(int);
virtual void populate();
signals:
void widgetOpened();
diff --git a/kommander/widgets/scriptobject.cpp b/kommander/widgets/scriptobject.cpp
index 2824d81f..472bb98c 100644
--- a/kommander/widgets/scriptobject.cpp
+++ b/kommander/widgets/scriptobject.cpp
@@ -30,7 +30,7 @@
#include <specials.h>
ScriptObject::ScriptObject(TQWidget *a_parent, const char *a_name)
- : TQLabel(a_parent, a_name), KommanderWidget(this)
+ : TQLabel(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -93,7 +93,7 @@ void ScriptObject::populate()
TQString ScriptObject::executeProcess(bool blocking)
{
- int index = ( states().findIndex( currentState()) );
+ int index = ( states().tqfindIndex( currentState()) );
if (index == -1)
{
printError(i18n("Invalid state for associated text."));
@@ -169,7 +169,7 @@ TQString ScriptObject::handleDCOP(int function, const TQStringList& args)
setAssociatedText(args[0]);
break;
case DCOP::clear:
- setAssociatedText(TQString::null);
+ setAssociatedText(TQString());
break;
case DCOP::execute:
m_params = args;
@@ -178,7 +178,7 @@ TQString ScriptObject::handleDCOP(int function, const TQStringList& args)
case DCOP::item:
{
uint index = args[0].toInt();
- return index < m_params.count() ? m_params[index] : TQString::null;
+ return index < m_params.count() ? m_params[index] : TQString();
}
case DCOP::count:
return TQString::number(m_params.count());
diff --git a/kommander/widgets/scriptobject.h b/kommander/widgets/scriptobject.h
index 325903cc..8a50f97e 100644
--- a/kommander/widgets/scriptobject.h
+++ b/kommander/widgets/scriptobject.h
@@ -29,10 +29,11 @@
class KOMMANDER_EXPORT ScriptObject : public TQLabel, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
ScriptObject(TQWidget *a_parent, const char *a_name);
diff --git a/kommander/widgets/slider.cpp b/kommander/widgets/slider.cpp
index b3bef6fc..b8068ede 100644
--- a/kommander/widgets/slider.cpp
+++ b/kommander/widgets/slider.cpp
@@ -23,7 +23,7 @@
#include "slider.h"
Slider::Slider(TQWidget * a_parent, const char *a_name)
- : TQSlider(a_parent, a_name), KommanderWidget((TQObject *) this)
+ : TQSlider(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
diff --git a/kommander/widgets/slider.h b/kommander/widgets/slider.h
index 1ed39a8b..e6324d50 100644
--- a/kommander/widgets/slider.h
+++ b/kommander/widgets/slider.h
@@ -29,9 +29,11 @@
class TQShowEvent;
class KOMMANDER_EXPORT Slider: public TQSlider, public KommanderWidget
{
- Q_OBJECT Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ Q_OBJECT
+ TQ_OBJECT
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
Slider(TQWidget*, const char*);
virtual ~Slider();
diff --git a/kommander/widgets/spinboxint.cpp b/kommander/widgets/spinboxint.cpp
index a2b9af6a..cc264f34 100644
--- a/kommander/widgets/spinboxint.cpp
+++ b/kommander/widgets/spinboxint.cpp
@@ -28,7 +28,7 @@
#include "spinboxint.h"
SpinBoxInt::SpinBoxInt(TQWidget *a_parent, const char *a_name)
- : TQSpinBox(a_parent, a_name), KommanderWidget(this)
+ : TQSpinBox(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -101,7 +101,7 @@ void SpinBoxInt::focusInEvent( TQFocusEvent * e)
bool SpinBoxInt::isFunctionSupported(int f)
{
- return f == DCOP::text || f == DCOP::setText || f == DCOP::setMaximum || f == DCOP::geometry|| f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor;
+ return f == DCOP::text || f == DCOP::setText || f == DCOP::setMaximum || f == DCOP::tqgeometry|| f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor;
}
TQString SpinBoxInt::handleDCOP(int function, const TQStringList& args)
@@ -115,7 +115,7 @@ TQString SpinBoxInt::handleDCOP(int function, const TQStringList& args)
case DCOP::setMaximum:
setMaxValue(args[0].toUInt());
break;
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/spinboxint.h b/kommander/widgets/spinboxint.h
index 214692fe..c92489c3 100644
--- a/kommander/widgets/spinboxint.h
+++ b/kommander/widgets/spinboxint.h
@@ -33,10 +33,11 @@ class TQShowEvent;
class KOMMANDER_EXPORT SpinBoxInt : public TQSpinBox, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
SpinBoxInt(TQWidget *a_parent, const char *a_name);
~SpinBoxInt();
diff --git a/kommander/widgets/statusbar.cpp b/kommander/widgets/statusbar.cpp
index 59070884..3c5e76f5 100644
--- a/kommander/widgets/statusbar.cpp
+++ b/kommander/widgets/statusbar.cpp
@@ -27,14 +27,14 @@
#include "statusbar.h"
StatusBar::StatusBar(TQWidget *a_parent, const char *a_name)
- : KStatusBar(a_parent, a_name), KommanderWidget(this)
+ : KStatusBar(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
setStates(states);
setDisplayStates(states);
- insertItem(TQString::null, 0, 1);
- setItemAlignment(0, Qt::AlignLeft);
+ insertItem(TQString(), 0, 1);
+ setItemAlignment(0, TQt::AlignLeft);
}
StatusBar::~StatusBar()
diff --git a/kommander/widgets/statusbar.h b/kommander/widgets/statusbar.h
index 0971b1ce..616283fd 100644
--- a/kommander/widgets/statusbar.h
+++ b/kommander/widgets/statusbar.h
@@ -33,10 +33,11 @@ class TQShowEvent;
class KOMMANDER_EXPORT StatusBar : public KStatusBar, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
StatusBar(TQWidget *a_parent, const char *a_name);
diff --git a/kommander/widgets/subdialog.cpp b/kommander/widgets/subdialog.cpp
index 292ac541..47e4ec69 100644
--- a/kommander/widgets/subdialog.cpp
+++ b/kommander/widgets/subdialog.cpp
@@ -32,7 +32,7 @@
#include "subdialog.h"
SubDialog::SubDialog(TQWidget *a_parent, const char *a_name)
- : TQPushButton(a_parent, a_name), KommanderWidget(this), m_dialog(0)
+ : TQPushButton(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this)), m_dialog(0)
{
TQStringList states;
states << "default";
diff --git a/kommander/widgets/subdialog.h b/kommander/widgets/subdialog.h
index c61eda15..2e1120a3 100644
--- a/kommander/widgets/subdialog.h
+++ b/kommander/widgets/subdialog.h
@@ -34,11 +34,12 @@ class TQShowEvent;
class KOMMANDER_EXPORT SubDialog : public TQPushButton, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQString kmdrFile READ kmdrFile WRITE setKmdrFile)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQString kmdrFile READ kmdrFile WRITE setKmdrFile)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
SubDialog(TQWidget *a_parent, const char *a_name);
~SubDialog();
diff --git a/kommander/widgets/table.cpp b/kommander/widgets/table.cpp
index b7e2d68a..4056431e 100644
--- a/kommander/widgets/table.cpp
+++ b/kommander/widgets/table.cpp
@@ -48,7 +48,7 @@ enum Functions {
Table::Table(TQWidget *a_parent, const char *a_name)
- : TQTable(a_parent, a_name), KommanderWidget(this)
+ : TQTable(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -114,7 +114,7 @@ void Table::setWidgetText(const TQString&)
TQString Table::selectedArea()
{
TQTableSelection sel = selection(currentSelection());
- return TQString("%1,%2,%3,%4").arg(sel.topRow()).arg(sel.leftCol()).arg(sel.bottomRow()).arg(sel.rightCol());
+ return TQString("%1,%2,%3,%4").tqarg(sel.topRow()).tqarg(sel.leftCol()).tqarg(sel.bottomRow()).tqarg(sel.rightCol());
}
@@ -123,7 +123,7 @@ bool Table::isFunctionSupported(int f)
return f == DCOP::currentColumn || f == DCOP::currentRow || f == DCOP::insertColumn ||
f == DCOP::insertRow || f == DCOP::cellText || f == DCOP::setCellText || f == DCOP::setCellWidget || f == DCOP::cellWidget || f == DCOP::columnCount ||
f == DCOP::removeRow || f == DCOP::removeColumn || f == DCOP::setColumnCaption ||
- f == DCOP::setRowCaption || f == DCOP::text || f == DCOP::setText || f == DCOP::selection || f == DCOP::geometry || f == DCOP::hasFocus || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor || (f >= FirstFunction && f <= LastFunction);
+ f == DCOP::setRowCaption || f == DCOP::text || f == DCOP::setText || f == DCOP::selection || f == DCOP::tqgeometry || f == DCOP::hasFocus || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor || (f >= FirstFunction && f <= LastFunction);
}
void Table::setCellWidget(int row, int col, const TQString & _widgetName)
@@ -131,7 +131,7 @@ void Table::setCellWidget(int row, int col, const TQString & _widgetName)
KommanderWidget *w = widgetByName(_widgetName);
if (w)
{
- TQWidget *widget = static_cast<TQWidget*>(w->object());
+ TQWidget *widget = TQT_TQWIDGET(w->object());
if (TQTable::cellWidget(row, col) != widget)
{
setCurrentCell(-1, -1); //hack to not delete the cellwidget after clicking away to another cell.
@@ -167,7 +167,7 @@ void Table::setCellText(int row, int col, const TQString& text)
{
KommanderWidget *w = widgetByName(widget->name());
if (w)
- widget->reparent(parentDialog(), TQPoint(0,0));
+ widget->reparent(tqparentDialog(), TQPoint(0,0));
}
setText(row, col, text);
endEdit(row, col, false, false);
@@ -354,7 +354,7 @@ TQString Table::handleDCOP(int function, const TQStringList& args)
return "No row at index "+args[0];
break;
}
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/table.h b/kommander/widgets/table.h
index 1539597d..38cb9a33 100644
--- a/kommander/widgets/table.h
+++ b/kommander/widgets/table.h
@@ -31,11 +31,12 @@ class TQWidget;
class KOMMANDER_EXPORT Table : public TQTable, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_OVERRIDE(bool readOnly DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_OVERRIDE(bool readOnly DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
Table(TQWidget *a_parent, const char *a_name);
diff --git a/kommander/widgets/tabwidget.cpp b/kommander/widgets/tabwidget.cpp
index 8ffc95b1..1574ba9e 100644
--- a/kommander/widgets/tabwidget.cpp
+++ b/kommander/widgets/tabwidget.cpp
@@ -44,7 +44,7 @@ enum Functions {
};
TabWidget::TabWidget(TQWidget *a_parent, const char *a_name, int a_flags)
- : TQTabWidget(a_parent, a_name, a_flags), KommanderWidget(this)
+ : TQTabWidget(a_parent, a_name, a_flags), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
diff --git a/kommander/widgets/tabwidget.h b/kommander/widgets/tabwidget.h
index 3bae4d0a..e848f402 100644
--- a/kommander/widgets/tabwidget.h
+++ b/kommander/widgets/tabwidget.h
@@ -28,10 +28,11 @@ class TQShowEvent;
class KOMMANDER_EXPORT TabWidget : public TQTabWidget, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
TabWidget(TQWidget *, const char *, int=0);
~TabWidget();
diff --git a/kommander/widgets/textbrowser.cpp b/kommander/widgets/textbrowser.cpp
index a2f9e744..f6b1330e 100644
--- a/kommander/widgets/textbrowser.cpp
+++ b/kommander/widgets/textbrowser.cpp
@@ -35,7 +35,7 @@ enum Functions {
};
TextBrowser::TextBrowser(TQWidget * a_parent, const char *a_name)
- : KTextBrowser(a_parent, a_name), KommanderWidget((TQObject *) this)
+ : KTextBrowser(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
diff --git a/kommander/widgets/textbrowser.h b/kommander/widgets/textbrowser.h
index 3a106fcf..27a5b1e2 100644
--- a/kommander/widgets/textbrowser.h
+++ b/kommander/widgets/textbrowser.h
@@ -30,9 +30,10 @@ class TQShowEvent;
class KOMMANDER_EXPORT TextBrowser: public KTextBrowser, public KommanderWidget
{
Q_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_OBJECT
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
TextBrowser(TQWidget*, const char*);
virtual ~TextBrowser();
diff --git a/kommander/widgets/textedit.cpp b/kommander/widgets/textedit.cpp
index 72f8c754..1ca2e167 100644
--- a/kommander/widgets/textedit.cpp
+++ b/kommander/widgets/textedit.cpp
@@ -28,7 +28,7 @@
#include <kommanderplugin.h>
enum Functions {
- FirstFunction = 450, //CHANGE THIS NUMBER TO AN UNIQUE ONE!!!
+ FirstFunction = 450, //CHANGE THIS NUMBER TO AN UNITQUE ONE!!!
TE_setModified,
TE_selectText,
TE_paragraphs,
@@ -43,7 +43,7 @@ enum Functions {
};
TextEdit::TextEdit(TQWidget * a_parent, const char *a_name):KTextEdit(a_parent, a_name),
-KommanderWidget((TQObject *) this)
+KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -143,7 +143,7 @@ void TextEdit::contextMenuEvent( TQContextMenuEvent * e )
bool TextEdit::isFunctionSupported(int f)
{
- return f == DCOP::text || f == DCOP::setText || f == DCOP::selection || f == DCOP::setSelection || f == DCOP::clear || f == DCOP::setEditable || f == DCOP::geometry || f == DCOP::hasFocus || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor || f == DCOP::isModified || (f >= FirstFunction && f <= LastFunction);
+ return f == DCOP::text || f == DCOP::setText || f == DCOP::selection || f == DCOP::setSelection || f == DCOP::clear || f == DCOP::setEditable || f == DCOP::tqgeometry || f == DCOP::hasFocus || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor || f == DCOP::isModified || (f >= FirstFunction && f <= LastFunction);
}
TQString TextEdit::handleDCOP(int function, const TQStringList& args)
@@ -200,8 +200,8 @@ TQString TextEdit::handleDCOP(int function, const TQStringList& args)
{
// int para = args[3].toInt();
// int idx = args[4].toInt();
-// return TQString::number(TQTextEdit::find(args[0], args[1].toUInt(), false, args[2].toUInt(), para, idx ));
- return TQString::number(TQTextEdit::find(args[0], args[1].toUInt(), false ));
+// return TQString::number(TQTextEdit::tqfind(args[0], args[1].toUInt(), false, args[2].toUInt(), para, idx ));
+ return TQString::number(TQTextEdit::tqfind(args[0], args[1].toUInt(), false ));
break;
}
case TE_VAsuperScript:
@@ -210,7 +210,7 @@ TQString TextEdit::handleDCOP(int function, const TQStringList& args)
case TE_VAnormalScript:
TQTextEdit::setVerticalAlignment(AlignNormal);
break;
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/textedit.h b/kommander/widgets/textedit.h
index 3132e315..de040391 100644
--- a/kommander/widgets/textedit.h
+++ b/kommander/widgets/textedit.h
@@ -31,9 +31,11 @@
class TQShowEvent;
class KOMMANDER_EXPORT TextEdit: public KTextEdit, public KommanderWidget
{
- Q_OBJECT Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ Q_OBJECT
+ TQ_OBJECT
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
TextEdit(TQWidget *, const char *);
virtual ~TextEdit();
diff --git a/kommander/widgets/timer.cpp b/kommander/widgets/timer.cpp
index 5a7251f1..2bc934b0 100644
--- a/kommander/widgets/timer.cpp
+++ b/kommander/widgets/timer.cpp
@@ -38,7 +38,7 @@ enum Functions {
};
Timer::Timer(TQWidget *a_parent, const char *a_name)
- : TQLabel(a_parent, a_name), KommanderWidget(this)
+ : TQLabel(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
diff --git a/kommander/widgets/timer.h b/kommander/widgets/timer.h
index 095c7dac..6d14452d 100644
--- a/kommander/widgets/timer.h
+++ b/kommander/widgets/timer.h
@@ -27,12 +27,13 @@ class TQTimer;
class KOMMANDER_EXPORT Timer : public TQLabel, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
- Q_PROPERTY(int interval READ interval WRITE setInterval)
- Q_PROPERTY(bool singleShot READ singleShot WRITE setSingleShot)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(int interval READ interval WRITE setInterval)
+ TQ_PROPERTY(bool singleShot READ singleShot WRITE setSingleShot)
public:
Timer(TQWidget *a_parent, const char *a_name);
diff --git a/kommander/widgets/toolbox.cpp b/kommander/widgets/toolbox.cpp
index a6340098..b2b57748 100644
--- a/kommander/widgets/toolbox.cpp
+++ b/kommander/widgets/toolbox.cpp
@@ -27,8 +27,8 @@
#define FIRST_FUNCTION ADDWIDGET
#define LAST_FUNCTION INDEXOF
-ToolBox::ToolBox(TQWidget *parent, const char *name)
- : TQToolBox(parent, name), KommanderWidget(this)
+ToolBox::ToolBox(TQWidget *tqparent, const char *name)
+ : TQToolBox(tqparent, name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -121,7 +121,7 @@ void ToolBox::contextMenuEvent( TQContextMenuEvent * e )
bool ToolBox::isFunctionSupported(int f)
{
- return f == DCOP::count || f == DCOP::geometry || (f >= FIRST_FUNCTION && f <= LAST_FUNCTION) ;
+ return f == DCOP::count || f == DCOP::tqgeometry || (f >= FIRST_FUNCTION && f <= LAST_FUNCTION) ;
}
TQString ToolBox::handleDCOP(int function, const TQStringList& args)
@@ -176,7 +176,7 @@ TQString ToolBox::handleDCOP(int function, const TQStringList& args)
}
case DCOP::count:
return TQString::number(count());
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/toolbox.h b/kommander/widgets/toolbox.h
index 12761df0..ab5375b0 100644
--- a/kommander/widgets/toolbox.h
+++ b/kommander/widgets/toolbox.h
@@ -21,11 +21,12 @@
class ToolBox : public TQToolBox, public KommanderWidget
{
Q_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_OBJECT
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
- ToolBox(TQWidget *parent = 0, const char *name = 0);
+ ToolBox(TQWidget *tqparent = 0, const char *name = 0);
~ToolBox();
diff --git a/kommander/widgets/treewidget.cpp b/kommander/widgets/treewidget.cpp
index ef3b7e65..e04fe41d 100644
--- a/kommander/widgets/treewidget.cpp
+++ b/kommander/widgets/treewidget.cpp
@@ -55,7 +55,7 @@ enum Functions {
};
TreeWidget::TreeWidget(TQWidget *a_parent, const char *a_name)
- : KListView(a_parent, a_name), KommanderWidget(this)
+ : KListView(a_parent, a_name), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
@@ -95,7 +95,7 @@ void TreeWidget::addItemFromString(const TQString& s)
TQStringList elements = TQStringList::split(m_pathSeparator, s, true);
if (elements.count() > 1)
setRootIsDecorated(true);
- TQListViewItem* parent = 0;
+ TQListViewItem* tqparent = 0;
if (m_lastPath.size() < elements.count())
m_lastPath.resize(elements.count());
uint i = 0;
@@ -103,13 +103,13 @@ void TreeWidget::addItemFromString(const TQString& s)
{
if (m_lastPath[i] && m_lastPath[i]->text(0) == elements[i])
{
- parent = m_lastPath[i];
+ tqparent = m_lastPath[i];
i++;
continue;
}
else
{
- TQListViewItem* item = (i>0) ? parent->firstChild() : firstChild();
+ TQListViewItem* item = (i>0) ? tqparent->firstChild() : firstChild();
while (item)
{
if (item->text(0) == *it)
@@ -117,19 +117,19 @@ void TreeWidget::addItemFromString(const TQString& s)
item = item->nextSibling();
}
if (item)
- parent = item;
+ tqparent = item;
else
- parent = itemFromString(parent, *it);
- m_lastPath.insert(i, parent);
+ tqparent = itemFromString(tqparent, *it);
+ m_lastPath.insert(i, tqparent);
i++;
}
}
}
-TQListViewItem* TreeWidget::itemFromString(TQListViewItem* parent, const TQString& s)
+TQListViewItem* TreeWidget::itemFromString(TQListViewItem* tqparent, const TQString& s)
{
TQStringList elements;
- if (s.contains("\t"))
+ if (s.tqcontains("\t"))
elements = TQStringList::split("\t", s, true);
else
elements = TQStringList::split("\\t", s, true);
@@ -137,8 +137,8 @@ TQListViewItem* TreeWidget::itemFromString(TQListViewItem* parent, const TQStrin
if (cols >= columns())
cols = columns();
TQListViewItem* item;
- if (parent)
- item = new TQListViewItem(parent);
+ if (tqparent)
+ item = new TQListViewItem(tqparent);
else
item = new TQListViewItem(this);
int i = 0;
@@ -208,8 +208,8 @@ TQString TreeWidget::itemsText()
if (path.isEmpty())
items.append(itemText(it.current()));
else
- items.append(TQString("%1%2%3").arg(path).arg(m_pathSeparator)
- .arg(itemText(it.current())));
+ items.append(TQString("%1%2%3").tqarg(path).tqarg(m_pathSeparator)
+ .tqarg(itemText(it.current())));
++it;
}
return items.join("\n");
@@ -219,14 +219,14 @@ TQString TreeWidget::itemPath(TQListViewItem* item) const
{
if (!item)
return TQString();
- item = item->parent();
+ item = item->tqparent();
if (!item)
return TQString();
TQStringList path;
while (item)
{
path.prepend(item->text(0));
- item = item->parent();
+ item = item->tqparent();
}
return path.join(m_pathSeparator);
}
@@ -295,11 +295,11 @@ void TreeWidget::contextMenuEvent( TQContextMenuEvent * e )
void TreeWidget::setColAlign(int column, const TQString& align)
{
if (align.lower() == "left")
- setColumnAlignment (column, Qt::AlignLeft);
+ setColumnAlignment (column, TQt::AlignLeft);
else if (align.lower() == "right")
- setColumnAlignment (column, Qt::AlignRight);
+ setColumnAlignment (column, TQt::AlignRight);
else if (align.lower() == "center")
- setColumnAlignment (column, Qt::AlignCenter);
+ setColumnAlignment (column, TQt::AlignCenter);
}
bool TreeWidget::isFunctionSupported(int f)
@@ -307,7 +307,7 @@ bool TreeWidget::isFunctionSupported(int f)
return f == DCOP::insertItem || f == DCOP::text || f == DCOP::setText || f == DCOP::insertItems ||
f == DCOP::selection || f == DCOP::setSelection || f == DCOP::clear || f == DCOP::removeItem ||
f == DCOP::currentItem || f == DCOP::setCurrentItem || f == DCOP::findItem || f == DCOP::item ||
- f == DCOP::itemPath || f == DCOP::itemDepth || f == DCOP::setPixmap || f == DCOP::setColumnCaption || f == DCOP::removeColumn || f == DCOP::columnCount || f == DCOP::geometry || f == DCOP::hasFocus || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor || (f > FirstFunction && f < LastFunction) || (f >= TW_FUNCTION && f <= TW_LAST_FUNCTION);
+ f == DCOP::itemPath || f == DCOP::itemDepth || f == DCOP::setPixmap || f == DCOP::setColumnCaption || f == DCOP::removeColumn || f == DCOP::columnCount || f == DCOP::tqgeometry || f == DCOP::hasFocus || f == DCOP::getBackgroundColor || f == DCOP::setBackgroundColor || (f > FirstFunction && f < LastFunction) || (f >= TW_FUNCTION && f <= TW_LAST_FUNCTION);
}
TQString TreeWidget::handleDCOP(int function, const TQStringList& args)
@@ -342,7 +342,7 @@ TQString TreeWidget::handleDCOP(int function, const TQStringList& args)
{
if (it.current()->isSelected())
{
- selection.append(TQString("%1\n").arg(itemToIndexSafe(it.current())));
+ selection.append(TQString("%1\n").tqarg(itemToIndexSafe(it.current())));
}
++it;
}
@@ -368,14 +368,14 @@ TQString TreeWidget::handleDCOP(int function, const TQStringList& args)
}
case DCOP::setSelection:
if (selectionModeExt() == Single || selectionModeExt() == NoSelection)
- setCurrentItem(findItem(args[0], 0));
+ setCurrentItem(tqfindItem(args[0], 0));
else
{
clearSelection();
TQStringList items(TQStringList::split("\n", args[0]));
for (TQStringList::ConstIterator it = items.begin(); it != items.end(); ++it)
{
- TQListViewItem* item = findItem(*it, 0);
+ TQListViewItem* item = tqfindItem(*it, 0);
if (item)
{
item->setSelected(true);
@@ -405,17 +405,17 @@ TQString TreeWidget::handleDCOP(int function, const TQStringList& args)
break;
case DCOP::findItem:
if (!args[1])
- return TQString::number(itemToIndexSafe(findItem(args[0], 0)));
+ return TQString::number(itemToIndexSafe(tqfindItem(args[0], 0)));
else
{
if (args[2].toUInt() && args[3].toUInt())
- return TQString::number(itemToIndexSafe(findItem(args[0], args[1].toInt())));
+ return TQString::number(itemToIndexSafe(tqfindItem(args[0], args[1].toInt())));
else if (args[2].toUInt())
- return TQString::number(itemToIndexSafe(findItem(args[0], args[1].toInt(), Qt::CaseSensitive | Qt::Contains)));
+ return TQString::number(itemToIndexSafe(tqfindItem(args[0], args[1].toInt(), TQt::CaseSensitive | TQt::Contains)));
else if (args[3].toUInt())
- return TQString::number(itemToIndexSafe(findItem(args[0], args[1].toInt(), Qt::ExactMatch)));
+ return TQString::number(itemToIndexSafe(tqfindItem(args[0], args[1].toInt(), TQt::ExactMatch)));
else
- return TQString::number(itemToIndexSafe(findItem(args[0], args[1].toInt(), Qt::Contains)));
+ return TQString::number(itemToIndexSafe(tqfindItem(args[0], args[1].toInt(), TQt::Contains)));
}
break;
case DCOP::item:
@@ -494,7 +494,7 @@ TQString TreeWidget::handleDCOP(int function, const TQStringList& args)
case TW_childCount:
return TQString::number(childCount());
break;
- case DCOP::geometry:
+ case DCOP::tqgeometry:
{
TQString geo = TQString::number(this->x())+" "+TQString::number(this->y())+" "+TQString::number(this->width())+" "+TQString::number(this->height());
return geo;
diff --git a/kommander/widgets/treewidget.h b/kommander/widgets/treewidget.h
index 3988c9a8..df7440b1 100644
--- a/kommander/widgets/treewidget.h
+++ b/kommander/widgets/treewidget.h
@@ -35,11 +35,12 @@ class TQShowEvent;
class KOMMANDER_EXPORT TreeWidget : public KListView, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
- Q_PROPERTY(TQString pathSeparator READ pathSeparator WRITE setPathSeparator)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString pathSeparator READ pathSeparator WRITE setPathSeparator)
public:
TreeWidget(TQWidget *a_parent, const char *a_name);
@@ -75,7 +76,7 @@ protected:
TQString itemPath(TQListViewItem* item) const;
private:
void addItemFromString(const TQString& s);
- TQListViewItem* itemFromString(TQListViewItem* parent, const TQString& s);
+ TQListViewItem* itemFromString(TQListViewItem* tqparent, const TQString& s);
TQPtrVector<TQListViewItem> m_lastPath;
TQString m_pathSeparator;
int addColumnTree(const TQString & label, int width = -1 );
diff --git a/kommander/widgets/wizard.cpp b/kommander/widgets/wizard.cpp
index 8cc16933..b5fabc20 100644
--- a/kommander/widgets/wizard.cpp
+++ b/kommander/widgets/wizard.cpp
@@ -32,7 +32,7 @@
Wizard::Wizard(TQWidget *a_parent, const char *a_name, bool a_modal, int a_flags)
- : TQWizard(a_parent, a_name, a_modal, a_flags), KommanderWidget(this)
+ : TQWizard(a_parent, a_name, a_modal, a_flags), KommanderWidget(TQT_TQOBJECT(this))
{
TQStringList states;
states << "default";
diff --git a/kommander/widgets/wizard.h b/kommander/widgets/wizard.h
index 6852fc77..5104af9a 100644
--- a/kommander/widgets/wizard.h
+++ b/kommander/widgets/wizard.h
@@ -30,13 +30,14 @@ class TQShowEvent;
class KOMMANDER_EXPORT Wizard : public TQWizard, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
- Q_PROPERTY(HelpAction helpAction READ helpAction WRITE setHelpAction)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(HelpAction helpAction READ helpAction WRITE setHelpAction)
Q_ENUMS(HelpAction)
- Q_PROPERTY(TQString helpActionText READ helpActionText WRITE setHelpActionText)
+ TQ_PROPERTY(TQString helpActionText READ helpActionText WRITE setHelpActionText)
public:
Wizard(TQWidget *, const char *, bool = true, int = 0);
diff --git a/kommander/working/plugintemplate/plugin.cpp b/kommander/working/plugintemplate/plugin.cpp
index b6e1a0a0..bad414aa 100644
--- a/kommander/working/plugintemplate/plugin.cpp
+++ b/kommander/working/plugintemplate/plugin.cpp
@@ -11,7 +11,7 @@ class %{APPNAME}Plugin : public KommanderPlugin
{
public:
%{APPNAME}Plugin();
- virtual TQWidget *create( const TQString &className, TQWidget *parent = 0, const char *name = 0);
+ virtual TQWidget *create( const TQString &className, TQWidget *tqparent = 0, const char *name = 0);
};
%{APPNAME}Plugin::%{APPNAME}Plugin()
@@ -19,10 +19,10 @@ public:
addWidget( "%{APPNAME}", "Custom", i18n("Kommander %{APPNAME} plugin."), new TQIconSet(KGlobal::iconLoader()->loadIcon("%{APPNAMELC}", KIcon::NoGroup, KIcon::SizeMedium)) );
}
-TQWidget *%{APPNAME}Plugin::create( const TQString &className, TQWidget *parent, const char *name)
+TQWidget *%{APPNAME}Plugin::create( const TQString &className, TQWidget *tqparent, const char *name)
{
if (className == "%{APPNAME}")
- return new %{APPNAME}(parent, name);
+ return new %{APPNAME}(tqparent, name);
return 0;
}
diff --git a/kommander/working/plugintemplate/src-Makefile.am b/kommander/working/plugintemplate/src-Makefile.am
index eb7dbe9d..a7b2ee01 100644
--- a/kommander/working/plugintemplate/src-Makefile.am
+++ b/kommander/working/plugintemplate/src-Makefile.am
@@ -13,7 +13,7 @@ libkmdr%{APPNAMELC}_la_SOURCES = %{APPNAMELC}.cpp %{APPNAMELC}plugin.cpp
# these are the headers for your project that won't be installed
-# let automoc handle all of the meta source files (moc)
+# let autotqmoc handle all of the meta source files (tqmoc)
METASOURCES = AUTO
AM_CXXFLAGS= -DHAVE_SSTREAM
AM_CPPFLAGS= $(all_includes)
diff --git a/kommander/working/plugintemplate/widget.cpp b/kommander/working/plugintemplate/widget.cpp
index 2378e87a..7efd8526 100644
--- a/kommander/working/plugintemplate/widget.cpp
+++ b/kommander/working/plugintemplate/widget.cpp
@@ -10,14 +10,14 @@
enum Functions {
- FirstFunction = 11001, //CHANGE THIS NUMBE TO AN UNIQUE ONE!!!
+ FirstFunction = 11001, //CHANGE THIS NUMBE TO AN UNITQUE ONE!!!
Function1,
Function2,
LastFunction
};
-%{APPNAME}::%{APPNAME}(TQWidget *parent, const char *name)
- : TQWidget(parent, name), KommanderWidget(this)
+%{APPNAME}::%{APPNAME}(TQWidget *tqparent, const char *name)
+ : TQWidget(tqparent, name), KommanderWidget(this)
{
TQStringList states;
states << "default";
@@ -31,7 +31,7 @@ enum Functions {
setPixmap(KGlobal::iconLoader()->loadIcon("%{APPNAMELC}", KIcon::NoGroup, KIcon::SizeMedium));
setFrameStyle(TQFrame::Box | TQFrame::Plain);
setLineWidth(1);
- setAlignment(Qt::AlignCenter);
+ tqsetAlignment(TQt::AlignCenter);
}
else
setHidden(true);
@@ -110,7 +110,7 @@ TQString %{APPNAME}::handleDCOP(int function, const TQStringList& args)
default:
return KommanderWidget::handleDCOP(function, args);
}
- return TQString::null;
+ return TQString();
}
#include "%{APPNAMELC}.moc"
diff --git a/kommander/working/plugintemplate/widget.h b/kommander/working/plugintemplate/widget.h
index 22638875..ab6f042f 100644
--- a/kommander/working/plugintemplate/widget.h
+++ b/kommander/working/plugintemplate/widget.h
@@ -15,13 +15,14 @@ class TQStringList;
class %{APPNAME}: public TQWidget, public KommanderWidget
{
Q_OBJECT
+ TQ_OBJECT
- Q_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
- Q_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
- Q_PROPERTY(bool KommanderWidget READ isKommanderWidget)
+ TQ_PROPERTY(TQString populationText READ populationText WRITE setPopulationText DESIGNABLE false)
+ TQ_PROPERTY(TQStringList associations READ associatedText WRITE setAssociatedText DESIGNABLE false)
+ TQ_PROPERTY(bool KommanderWidget READ isKommanderWidget)
public:
- %{APPNAME}(TQWidget *parent, const char* name);
+ %{APPNAME}(TQWidget *tqparent, const char* name);
~%{APPNAME}();
virtual bool isKommanderWidget() const;