diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-23 01:42:07 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-23 01:42:07 +0000 |
commit | a2277b6bc715464e83882b90c2a058139b8a6b54 (patch) | |
tree | ab09b14014f59b4d8e2ddd12226aa0b22e4dfc5d /kcalc | |
parent | d3f79e04b34bd1f70a458b81b28fc8799498c8dc (diff) | |
download | tdeutils-a2277b6bc715464e83882b90c2a058139b8a6b54.tar.gz tdeutils-a2277b6bc715464e83882b90c2a058139b8a6b54.zip |
TQt4 port kdeutils
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdeutils@1238125 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kcalc')
-rw-r--r-- | kcalc/colors.ui | 30 | ||||
-rw-r--r-- | kcalc/constants.ui | 68 | ||||
-rw-r--r-- | kcalc/dlabel.cpp | 6 | ||||
-rw-r--r-- | kcalc/dlabel.h | 3 | ||||
-rw-r--r-- | kcalc/general.ui | 30 | ||||
-rw-r--r-- | kcalc/kcalc.cpp | 188 | ||||
-rw-r--r-- | kcalc/kcalc.h | 17 | ||||
-rw-r--r-- | kcalc/kcalc_button.cpp | 20 | ||||
-rw-r--r-- | kcalc/kcalc_button.h | 16 | ||||
-rw-r--r-- | kcalc/kcalc_const_button.cpp | 8 | ||||
-rw-r--r-- | kcalc/kcalc_const_button.h | 7 | ||||
-rw-r--r-- | kcalc/kcalc_const_menu.cpp | 4 | ||||
-rw-r--r-- | kcalc/kcalc_const_menu.h | 8 | ||||
-rw-r--r-- | kcalc/kcalc_core.cpp | 4 | ||||
-rw-r--r-- | kcalc/kcalc_core.h | 2 | ||||
-rw-r--r-- | kcalc/kcalcdisplay.cpp | 36 | ||||
-rw-r--r-- | kcalc/kcalcdisplay.h | 7 | ||||
-rw-r--r-- | kcalc/kcalctype.h | 2 | ||||
-rw-r--r-- | kcalc/knumber/knumber.cpp | 16 | ||||
-rw-r--r-- | kcalc/knumber/knumber.h | 8 | ||||
-rw-r--r-- | kcalc/knumber/knumber_priv.cpp | 2 | ||||
-rw-r--r-- | kcalc/knumber/tests/knumbertest.cpp | 4 | ||||
-rw-r--r-- | kcalc/stats.cpp | 2 | ||||
-rw-r--r-- | kcalc/stats.h | 2 |
24 files changed, 248 insertions, 242 deletions
diff --git a/kcalc/colors.ui b/kcalc/colors.ui index 26f4b28..e6b4513 100644 --- a/kcalc/colors.ui +++ b/kcalc/colors.ui @@ -1,6 +1,6 @@ <!DOCTYPE UI><UI version="3.2" stdsetdef="1"> <class>Colors</class> -<widget class="QWidget"> +<widget class="TQWidget"> <property name="name"> <cstring>Colors</cstring> </property> @@ -19,7 +19,7 @@ <property name="margin"> <number>0</number> </property> - <widget class="QGroupBox"> + <widget class="TQGroupBox"> <property name="name"> <cstring>groupBox3</cstring> </property> @@ -30,7 +30,7 @@ <property name="name"> <cstring>unnamed</cstring> </property> - <widget class="QLabel" row="0" column="0"> + <widget class="TQLabel" row="0" column="0"> <property name="name"> <cstring>textLabel3</cstring> </property> @@ -41,7 +41,7 @@ <cstring>kcfg_ForeColor</cstring> </property> </widget> - <widget class="QLabel" row="1" column="0"> + <widget class="TQLabel" row="1" column="0"> <property name="name"> <cstring>textLabel4</cstring> </property> @@ -62,7 +62,7 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>110</width> <height>20</height> @@ -101,7 +101,7 @@ </widget> </grid> </widget> - <widget class="QGroupBox"> + <widget class="TQGroupBox"> <property name="name"> <cstring>groupBox4</cstring> </property> @@ -112,7 +112,7 @@ <property name="name"> <cstring>unnamed</cstring> </property> - <widget class="QLabel" row="0" column="0" rowspan="1" colspan="2"> + <widget class="TQLabel" row="0" column="0" rowspan="1" colspan="2"> <property name="name"> <cstring>textLabel5</cstring> </property> @@ -123,7 +123,7 @@ <cstring>kcfg_FunctionButtonsColor</cstring> </property> </widget> - <widget class="QLabel" row="2" column="0" rowspan="1" colspan="2"> + <widget class="TQLabel" row="2" column="0" rowspan="1" colspan="2"> <property name="name"> <cstring>textLabel7</cstring> </property> @@ -134,7 +134,7 @@ <cstring>kcfg_HexButtonsColor</cstring> </property> </widget> - <widget class="QLabel" row="5" column="0" rowspan="1" colspan="2"> + <widget class="TQLabel" row="5" column="0" rowspan="1" colspan="2"> <property name="name"> <cstring>textLabel10</cstring> </property> @@ -179,7 +179,7 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>41</width> <height>20</height> @@ -202,7 +202,7 @@ <string></string> </property> </widget> - <widget class="QLabel" row="3" column="0"> + <widget class="TQLabel" row="3" column="0"> <property name="name"> <cstring>textLabel8</cstring> </property> @@ -221,7 +221,7 @@ <string></string> </property> </widget> - <widget class="QLabel" row="1" column="0"> + <widget class="TQLabel" row="1" column="0"> <property name="name"> <cstring>textLabel6</cstring> </property> @@ -232,7 +232,7 @@ <cstring>kcfg_StatButtonsColor</cstring> </property> </widget> - <widget class="QLabel" row="4" column="0" rowspan="1" colspan="2"> + <widget class="TQLabel" row="4" column="0" rowspan="1" colspan="2"> <property name="name"> <cstring>textLabel9</cstring> </property> @@ -255,7 +255,7 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>20</width> <height>0</height> @@ -274,5 +274,5 @@ <tabstop>kcfg_MemoryButtonsColor</tabstop> <tabstop>kcfg_OperationButtonsColor</tabstop> </tabstops> -<layoutdefaults spacing="6" margin="11"/> +<tqlayoutdefaults spacing="6" margin="11"/> </UI> diff --git a/kcalc/constants.ui b/kcalc/constants.ui index f7c734e..82fe7d2 100644 --- a/kcalc/constants.ui +++ b/kcalc/constants.ui @@ -1,6 +1,6 @@ <!DOCTYPE UI><UI version="3.3" stdsetdef="1"> <class>Constants</class> -<widget class="QWidget"> +<widget class="TQWidget"> <property name="name"> <cstring>Constants</cstring> </property> @@ -19,7 +19,7 @@ <property name="name"> <cstring>unnamed</cstring> </property> - <widget class="QGroupBox"> + <widget class="TQGroupBox"> <property name="name"> <cstring>mainGroupBox</cstring> </property> @@ -30,7 +30,7 @@ <property name="name"> <cstring>unnamed</cstring> </property> - <widget class="QGroupBox"> + <widget class="TQGroupBox"> <property name="name"> <cstring>groupBox0</cstring> </property> @@ -41,7 +41,7 @@ <property name="name"> <cstring>unnamed</cstring> </property> - <widget class="QLineEdit"> + <widget class="TQLineEdit"> <property name="name"> <cstring>kcfg_nameConstant0</cstring> </property> @@ -59,14 +59,14 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>70</width> <height>21</height> </size> </property> </spacer> - <widget class="QLineEdit"> + <widget class="TQLineEdit"> <property name="name"> <cstring>kcfg_valueConstant0</cstring> </property> @@ -84,7 +84,7 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>80</width> <height>21</height> @@ -101,7 +101,7 @@ </widget> </hbox> </widget> - <widget class="QGroupBox"> + <widget class="TQGroupBox"> <property name="name"> <cstring>groupBox1</cstring> </property> @@ -112,7 +112,7 @@ <property name="name"> <cstring>unnamed</cstring> </property> - <widget class="QLineEdit"> + <widget class="TQLineEdit"> <property name="name"> <cstring>kcfg_nameConstant1</cstring> </property> @@ -130,14 +130,14 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>70</width> <height>21</height> </size> </property> </spacer> - <widget class="QLineEdit"> + <widget class="TQLineEdit"> <property name="name"> <cstring>kcfg_valueConstant1</cstring> </property> @@ -155,7 +155,7 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>80</width> <height>21</height> @@ -172,7 +172,7 @@ </widget> </hbox> </widget> - <widget class="QGroupBox"> + <widget class="TQGroupBox"> <property name="name"> <cstring>groupBox2</cstring> </property> @@ -183,7 +183,7 @@ <property name="name"> <cstring>unnamed</cstring> </property> - <widget class="QLineEdit"> + <widget class="TQLineEdit"> <property name="name"> <cstring>kcfg_nameConstant2</cstring> </property> @@ -201,14 +201,14 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>70</width> <height>21</height> </size> </property> </spacer> - <widget class="QLineEdit"> + <widget class="TQLineEdit"> <property name="name"> <cstring>kcfg_valueConstant2</cstring> </property> @@ -226,7 +226,7 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>80</width> <height>21</height> @@ -243,7 +243,7 @@ </widget> </hbox> </widget> - <widget class="QGroupBox"> + <widget class="TQGroupBox"> <property name="name"> <cstring>groupBox3</cstring> </property> @@ -254,7 +254,7 @@ <property name="name"> <cstring>unnamed</cstring> </property> - <widget class="QLineEdit"> + <widget class="TQLineEdit"> <property name="name"> <cstring>kcfg_nameConstant3</cstring> </property> @@ -272,14 +272,14 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>70</width> <height>21</height> </size> </property> </spacer> - <widget class="QLineEdit"> + <widget class="TQLineEdit"> <property name="name"> <cstring>kcfg_valueConstant3</cstring> </property> @@ -297,7 +297,7 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>80</width> <height>21</height> @@ -314,7 +314,7 @@ </widget> </hbox> </widget> - <widget class="QGroupBox"> + <widget class="TQGroupBox"> <property name="name"> <cstring>groupBox4</cstring> </property> @@ -325,7 +325,7 @@ <property name="name"> <cstring>unnamed</cstring> </property> - <widget class="QLineEdit"> + <widget class="TQLineEdit"> <property name="name"> <cstring>kcfg_nameConstant4</cstring> </property> @@ -343,14 +343,14 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>70</width> <height>21</height> </size> </property> </spacer> - <widget class="QLineEdit"> + <widget class="TQLineEdit"> <property name="name"> <cstring>kcfg_valueConstant4</cstring> </property> @@ -368,7 +368,7 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>80</width> <height>21</height> @@ -385,7 +385,7 @@ </widget> </hbox> </widget> - <widget class="QGroupBox"> + <widget class="TQGroupBox"> <property name="name"> <cstring>groupBox5</cstring> </property> @@ -396,7 +396,7 @@ <property name="name"> <cstring>unnamed</cstring> </property> - <widget class="QLineEdit"> + <widget class="TQLineEdit"> <property name="name"> <cstring>kcfg_nameConstant5</cstring> </property> @@ -414,14 +414,14 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>70</width> <height>21</height> </size> </property> </spacer> - <widget class="QLineEdit"> + <widget class="TQLineEdit"> <property name="name"> <cstring>kcfg_valueConstant5</cstring> </property> @@ -439,7 +439,7 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>80</width> <height>21</height> @@ -468,7 +468,7 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>20</width> <height>40</height> @@ -479,7 +479,7 @@ </widget> <customwidgets> </customwidgets> -<layoutdefaults spacing="6" margin="11"/> +<tqlayoutdefaults spacing="6" margin="11"/> <includehints> <includehint>kpushbutton.h</includehint> <includehint>kpushbutton.h</includehint> diff --git a/kcalc/dlabel.cpp b/kcalc/dlabel.cpp index c4dbb17..5591655 100644 --- a/kcalc/dlabel.cpp +++ b/kcalc/dlabel.cpp @@ -2,7 +2,7 @@ $Id$ KCalc, a scientific calculator for the X window system using the - Qt widget libraries, available at no cost at http://www.troll.no + TQt widget libraries, available at no cost at http://www.troll.no Copyright (C) 1996 Bernd Johannes Wuebben wuebben@math.cornell.edu @@ -34,9 +34,9 @@ -DispLogic::DispLogic(TQWidget *parent, const char *name, +DispLogic::DispLogic(TQWidget *tqparent, const char *name, KActionCollection *coll) - :KCalcDisplay(parent,name), _history_index(0) + :KCalcDisplay(tqparent,name), _history_index(0) { KNumber::setDefaultFloatOutput(true); KNumber::setDefaultFractionalInput(true); diff --git a/kcalc/dlabel.h b/kcalc/dlabel.h index 0a7c386..e2d0395 100644 --- a/kcalc/dlabel.h +++ b/kcalc/dlabel.h @@ -38,9 +38,10 @@ class KActionCollection; class DispLogic : public KCalcDisplay { Q_OBJECT + TQ_OBJECT public: - DispLogic(TQWidget *parent, const char *name, + DispLogic(TQWidget *tqparent, const char *name, KActionCollection *coll); ~DispLogic(); diff --git a/kcalc/general.ui b/kcalc/general.ui index 7ec8b15..59ba2f3 100644 --- a/kcalc/general.ui +++ b/kcalc/general.ui @@ -1,6 +1,6 @@ <!DOCTYPE UI><UI version="3.3" stdsetdef="1"> <class>General</class> -<widget class="QWidget"> +<widget class="TQWidget"> <property name="name"> <cstring>General</cstring> </property> @@ -22,7 +22,7 @@ <property name="margin"> <number>0</number> </property> - <widget class="QGroupBox"> + <widget class="TQGroupBox"> <property name="name"> <cstring>groupBox1</cstring> </property> @@ -33,7 +33,7 @@ <property name="name"> <cstring>unnamed</cstring> </property> - <widget class="QCheckBox" row="1" column="0" rowspan="1" colspan="2"> + <widget class="TQCheckBox" row="1" column="0" rowspan="1" colspan="2"> <property name="name"> <cstring>kcfg_Fixed</cstring> </property> @@ -41,7 +41,7 @@ <string>Set &decimal precision</string> </property> </widget> - <widget class="QLabel" row="2" column="1"> + <widget class="TQLabel" row="2" column="1"> <property name="name"> <cstring>textLabel1</cstring> </property> @@ -55,7 +55,7 @@ <cstring>kcfg_FixedPrecision</cstring> </property> </widget> - <widget class="QSpinBox" row="2" column="2"> + <widget class="TQSpinBox" row="2" column="2"> <property name="name"> <cstring>kcfg_FixedPrecision</cstring> </property> @@ -73,14 +73,14 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>21</width> <height>20</height> </size> </property> </spacer> - <widget class="QLabel" row="0" column="0" rowspan="1" colspan="2"> + <widget class="TQLabel" row="0" column="0" rowspan="1" colspan="2"> <property name="name"> <cstring>textLabel2</cstring> </property> @@ -101,21 +101,21 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>101</width> <height>20</height> </size> </property> </spacer> - <widget class="QSpinBox" row="0" column="2"> + <widget class="TQSpinBox" row="0" column="2"> <property name="name"> <cstring>kcfg_Precision</cstring> </property> </widget> </grid> </widget> - <widget class="QGroupBox"> + <widget class="TQGroupBox"> <property name="name"> <cstring>groupBox2</cstring> </property> @@ -126,7 +126,7 @@ <property name="name"> <cstring>unnamed</cstring> </property> - <widget class="QCheckBox"> + <widget class="TQCheckBox"> <property name="name"> <cstring>kcfg_Beep</cstring> </property> @@ -137,7 +137,7 @@ <bool>true</bool> </property> </widget> - <widget class="QCheckBox"> + <widget class="TQCheckBox"> <property name="name"> <cstring>kcfg_CaptionResult</cstring> </property> @@ -145,7 +145,7 @@ <string>Show &result in window title</string> </property> </widget> - <widget class="QCheckBox"> + <widget class="TQCheckBox"> <property name="name"> <cstring>kcfg_GroupDigits</cstring> </property> @@ -165,7 +165,7 @@ <property name="sizeType"> <enum>Expanding</enum> </property> - <property name="sizeHint"> + <property name="tqsizeHint"> <size> <width>20</width> <height>31</height> @@ -195,5 +195,5 @@ <tabstop>kcfg_Beep</tabstop> <tabstop>kcfg_CaptionResult</tabstop> </tabstops> -<layoutdefaults spacing="6" margin="11"/> +<tqlayoutdefaults spacing="6" margin="11"/> </UI> diff --git a/kcalc/kcalc.cpp b/kcalc/kcalc.cpp index 515536f..df773b2 100644 --- a/kcalc/kcalc.cpp +++ b/kcalc/kcalc.cpp @@ -78,8 +78,8 @@ static const char description[] = I18N_NOOP("KDE Calculator"); static const char version[] = KCALCVERSION; -KCalculator::KCalculator(TQWidget *parent, const char *name) - : KMainWindow(parent, name), inverse(false), +KCalculator::KCalculator(TQWidget *tqparent, const char *name) + : KMainWindow(tqparent, name), inverse(false), hyp_mode(false), memory_num(0.0), calc_display(NULL), mInternalSpacing(4), core() { @@ -106,7 +106,7 @@ KCalculator::KCalculator(TQWidget *parent, const char *name) // Create Button to select BaseMode BaseChooseGroup = new TQHButtonGroup(i18n("Base"), central); connect(BaseChooseGroup, TQT_SIGNAL(clicked(int)), TQT_SLOT(slotBaseSelected(int))); - BaseChooseGroup->setSizePolicy(TQSizePolicy::Expanding, TQSizePolicy::Fixed, false); + BaseChooseGroup->tqsetSizePolicy(TQSizePolicy::Expanding, TQSizePolicy::Fixed, false); pbBaseChoose[0] = new TQRadioButton(i18n("He&x"), BaseChooseGroup, @@ -155,7 +155,7 @@ KCalculator::KCalculator(TQWidget *parent, const char *name) // Create Calculator Buttons // - // First the widgets that are the parents of the buttons + // First the widgets that are the tqparents of the buttons mSmallPage = new TQWidget(central); mLargePage = new TQWidget(central); mNumericPage = setupNumericKeys(central); @@ -228,7 +228,7 @@ KCalculator::KCalculator(TQWidget *parent, const char *name) // - // All these layouts are needed because all the groups have their + // All these tqlayouts are needed because all the groups have their // own size per row so we can't use one huge TQGridLayout (mosfet) // TQGridLayout *smallBtnLayout = new TQGridLayout(mSmallPage, 6, 4, 0, @@ -246,54 +246,54 @@ KCalculator::KCalculator(TQWidget *parent, const char *name) mainLayout->addLayout(topLayout); mainLayout->addLayout(btnLayout); - // button layout + // button tqlayout btnLayout->addWidget(mSmallPage, 0, AlignTop); btnLayout->addSpacing(2*mInternalSpacing); btnLayout->addWidget(mNumericPage, 0, AlignTop); btnLayout->addSpacing(2*mInternalSpacing); btnLayout->addWidget(mLargePage, 0, AlignTop); - // small button layout + // small button tqlayout smallBtnLayout->addWidget(pbStat["NumData"], 0, 0); smallBtnLayout->addWidget(pbScientific["HypMode"], 0, 1); smallBtnLayout->addWidget(pbLogic["AND"], 0, 2); smallBtnLayout->addWidget(pbMod, 0, 3); - smallBtnLayout->addWidget(NumButtonGroup->find(0xA), 0, 4); + smallBtnLayout->addWidget(NumButtonGroup->tqfind(0xA), 0, 4); smallBtnLayout->addWidget(pbConstant[0], 0, 5); smallBtnLayout->addWidget(pbStat["Mean"], 1, 0); smallBtnLayout->addWidget(pbScientific["Sine"], 1, 1); smallBtnLayout->addWidget(pbLogic["OR"], 1, 2); smallBtnLayout->addWidget(pbReci, 1, 3); - smallBtnLayout->addWidget(NumButtonGroup->find(0xB), 1, 4); + smallBtnLayout->addWidget(NumButtonGroup->tqfind(0xB), 1, 4); smallBtnLayout->addWidget(pbConstant[1], 1, 5); smallBtnLayout->addWidget(pbStat["StandardDeviation"], 2, 0); smallBtnLayout->addWidget(pbScientific["Cosine"], 2, 1); smallBtnLayout->addWidget(pbLogic["XOR"], 2, 2); smallBtnLayout->addWidget(pbFactorial, 2, 3); - smallBtnLayout->addWidget(NumButtonGroup->find(0xC), 2, 4); + smallBtnLayout->addWidget(NumButtonGroup->tqfind(0xC), 2, 4); smallBtnLayout->addWidget(pbConstant[2], 2, 5); smallBtnLayout->addWidget(pbStat["Median"], 3, 0); smallBtnLayout->addWidget(pbScientific["Tangent"], 3, 1); smallBtnLayout->addWidget(pbLogic["LeftShift"], 3, 2); smallBtnLayout->addWidget(pbSquare, 3, 3); - smallBtnLayout->addWidget(NumButtonGroup->find(0xD), 3, 4); + smallBtnLayout->addWidget(NumButtonGroup->tqfind(0xD), 3, 4); smallBtnLayout->addWidget(pbConstant[3], 3, 5); smallBtnLayout->addWidget(pbStat["InputData"], 4, 0); smallBtnLayout->addWidget(pbScientific["Log10"], 4, 1); smallBtnLayout->addWidget(pbLogic["RightShift"], 4, 2); smallBtnLayout->addWidget(pbRoot, 4, 3); - smallBtnLayout->addWidget(NumButtonGroup->find(0xE), 4, 4); + smallBtnLayout->addWidget(NumButtonGroup->tqfind(0xE), 4, 4); smallBtnLayout->addWidget(pbConstant[4], 4, 5); smallBtnLayout->addWidget(pbStat["ClearData"], 5, 0); smallBtnLayout->addWidget(pbScientific["LogNatural"], 5, 1); smallBtnLayout->addWidget(pbLogic["One-Complement"], 5, 2); smallBtnLayout->addWidget(pbPower, 5, 3); - smallBtnLayout->addWidget(NumButtonGroup->find(0xF), 5, 4); + smallBtnLayout->addWidget(NumButtonGroup->tqfind(0xF), 5, 4); smallBtnLayout->addWidget(pbConstant[5], 5, 5); smallBtnLayout->setRowStretch(0, 0); @@ -303,7 +303,7 @@ KCalculator::KCalculator(TQWidget *parent, const char *name) smallBtnLayout->setRowStretch(4, 0); smallBtnLayout->setRowStretch(5, 0); - // large button layout + // large button tqlayout largeBtnLayout->addWidget(pbClear, 0, 0); largeBtnLayout->addWidget(pbAC, 0, 1); @@ -319,7 +319,7 @@ KCalculator::KCalculator(TQWidget *parent, const char *name) largeBtnLayout->addWidget(pbPercent, 4, 0); largeBtnLayout->addWidget(pbPlusMinus, 4, 1); - // top layout + // top tqlayout topLayout->addWidget(pbAngleChoose); topLayout->addWidget(BaseChooseGroup); topLayout->addStretch(); @@ -381,7 +381,7 @@ KCalculator::KCalculator(TQWidget *parent, const char *name) updateGeometry(); adjustSize(); - setFixedSize(sizeHint()); + setFixedSize(tqsizeHint()); UpdateDisplay(true); @@ -457,7 +457,7 @@ actionCollection()); void KCalculator::setupStatusbar(void) { - // Status bar contents + // tqStatus bar contents statusBar()->insertFixedItem(" NORM ", 0, true); statusBar()->setItemAlignment(0, AlignCenter); @@ -471,12 +471,12 @@ void KCalculator::setupStatusbar(void) statusBar()->setItemAlignment(3, AlignCenter); } -TQWidget* KCalculator::setupNumericKeys(TQWidget *parent) +TQWidget* KCalculator::setupNumericKeys(TQWidget *tqparent) { Q_CHECK_PTR(mSmallPage); Q_CHECK_PTR(mLargePage); - TQWidget *thisPage = new TQWidget(parent); + TQWidget *thisPage = new TQWidget(tqparent); KCalcButton *tmp_pb; @@ -608,28 +608,28 @@ TQWidget* KCalculator::setupNumericKeys(TQWidget *parent) TQGridLayout *thisLayout = new TQGridLayout(thisPage, 5, 4, 0, mInternalSpacing); - // large button layout + // large button tqlayout thisLayout->addWidget(pbEE, 0, 0); thisLayout->addWidget(pbDivision, 0, 1); thisLayout->addWidget(pbX, 0, 2); thisLayout->addWidget(pbMinus, 0, 3); - thisLayout->addWidget(NumButtonGroup->find(7), 1, 0); - thisLayout->addWidget(NumButtonGroup->find(8), 1, 1); - thisLayout->addWidget(NumButtonGroup->find(9), 1, 2); + thisLayout->addWidget(NumButtonGroup->tqfind(7), 1, 0); + thisLayout->addWidget(NumButtonGroup->tqfind(8), 1, 1); + thisLayout->addWidget(NumButtonGroup->tqfind(9), 1, 2); thisLayout->addMultiCellWidget(pbPlus, 1, 2, 3, 3); - thisLayout->addWidget(NumButtonGroup->find(4), 2, 0); - thisLayout->addWidget(NumButtonGroup->find(5), 2, 1); - thisLayout->addWidget(NumButtonGroup->find(6), 2, 2); + thisLayout->addWidget(NumButtonGroup->tqfind(4), 2, 0); + thisLayout->addWidget(NumButtonGroup->tqfind(5), 2, 1); + thisLayout->addWidget(NumButtonGroup->tqfind(6), 2, 2); //thisLayout->addMultiCellWidget(pbPlus, 1, 2, 3, 3); - thisLayout->addWidget(NumButtonGroup->find(1), 3, 0); - thisLayout->addWidget(NumButtonGroup->find(2), 3, 1); - thisLayout->addWidget(NumButtonGroup->find(3), 3, 2); + thisLayout->addWidget(NumButtonGroup->tqfind(1), 3, 0); + thisLayout->addWidget(NumButtonGroup->tqfind(2), 3, 1); + thisLayout->addWidget(NumButtonGroup->tqfind(3), 3, 2); thisLayout->addMultiCellWidget(pbEqual, 3, 4, 3, 3); - thisLayout->addMultiCellWidget(NumButtonGroup->find(0), 4, 4, 0, 1); + thisLayout->addMultiCellWidget(NumButtonGroup->tqfind(0), 4, 4, 0, 1); thisLayout->addWidget(pbPeriod, 4, 2); //thisLayout->addMultiCellWidget(pbEqual, 3, 4, 3, 3); @@ -741,33 +741,33 @@ TQWidget* KCalculator::setupNumericKeys(TQWidget *parent) return thisPage; } -void KCalculator::setupLogicKeys(TQWidget *parent) +void KCalculator::setupLogicKeys(TQWidget *tqparent) { - Q_CHECK_PTR(parent); + Q_CHECK_PTR(tqparent); KCalcButton *tmp_pb; - tmp_pb = new KCalcButton("AND", parent, "AND-Button", i18n("Bitwise AND")); + tmp_pb = new KCalcButton("AND", tqparent, "AND-Button", i18n("Bitwise AND")); pbLogic.insert("AND", tmp_pb); tmp_pb->setAccel(Key_Ampersand); connect(this, TQT_SIGNAL(switchShowAccels(bool)), tmp_pb, TQT_SLOT(slotSetAccelDisplayMode(bool))); connect(tmp_pb, TQT_SIGNAL(clicked(void)), TQT_SLOT(slotANDclicked(void))); - tmp_pb = new KCalcButton("OR", parent, "OR-Button", i18n("Bitwise OR")); + tmp_pb = new KCalcButton("OR", tqparent, "OR-Button", i18n("Bitwise OR")); pbLogic.insert("OR", tmp_pb); tmp_pb->setAccel(Key_Bar); connect(this, TQT_SIGNAL(switchShowAccels(bool)), tmp_pb, TQT_SLOT(slotSetAccelDisplayMode(bool))); connect(tmp_pb, TQT_SIGNAL(clicked(void)), TQT_SLOT(slotORclicked(void))); - tmp_pb = new KCalcButton("XOR", parent, "XOR-Button", i18n("Bitwise XOR")); + tmp_pb = new KCalcButton("XOR", tqparent, "XOR-Button", i18n("Bitwise XOR")); pbLogic.insert("XOR", tmp_pb); connect(this, TQT_SIGNAL(switchShowAccels(bool)), tmp_pb, TQT_SLOT(slotSetAccelDisplayMode(bool))); connect(tmp_pb, TQT_SIGNAL(clicked(void)), TQT_SLOT(slotXORclicked(void))); - tmp_pb = new KCalcButton("Cmp", parent, "One-Complement-Button", + tmp_pb = new KCalcButton("Cmp", tqparent, "One-Complement-Button", i18n("One's complement")); pbLogic.insert("One-Complement", tmp_pb); tmp_pb->setAccel(Key_AsciiTilde); @@ -775,7 +775,7 @@ void KCalculator::setupLogicKeys(TQWidget *parent) tmp_pb, TQT_SLOT(slotSetAccelDisplayMode(bool))); connect(tmp_pb, TQT_SIGNAL(clicked(void)), TQT_SLOT(slotNegateclicked(void))); - tmp_pb = new KCalcButton("Lsh", parent, "LeftBitShift-Button", + tmp_pb = new KCalcButton("Lsh", tqparent, "LeftBitShift-Button", i18n("Left bit shift")); tmp_pb->setAccel(Key_Less); pbLogic.insert("LeftShift", tmp_pb); @@ -784,7 +784,7 @@ void KCalculator::setupLogicKeys(TQWidget *parent) connect(tmp_pb, TQT_SIGNAL(clicked(void)), TQT_SLOT(slotLeftShiftclicked(void))); - tmp_pb = new KCalcButton("Rsh", parent, "RightBitShift-Button", + tmp_pb = new KCalcButton("Rsh", tqparent, "RightBitShift-Button", i18n("Right bit shift")); tmp_pb->setAccel(Key_Greater); pbLogic.insert("RightShift", tmp_pb); @@ -794,13 +794,13 @@ void KCalculator::setupLogicKeys(TQWidget *parent) TQT_SLOT(slotRightShiftclicked(void))); } -void KCalculator::setupScientificKeys(TQWidget *parent) +void KCalculator::setupScientificKeys(TQWidget *tqparent) { - Q_CHECK_PTR(parent); + Q_CHECK_PTR(tqparent); KCalcButton *tmp_pb; - tmp_pb = new KCalcButton("Hyp", parent, "Hyp-Button", i18n("Hyperbolic mode")); + tmp_pb = new KCalcButton("Hyp", tqparent, "Hyp-Button", i18n("Hyperbolic mode")); pbScientific.insert("HypMode", tmp_pb); tmp_pb->setAccel(Key_H); connect(this, TQT_SIGNAL(switchShowAccels(bool)), @@ -808,7 +808,7 @@ void KCalculator::setupScientificKeys(TQWidget *parent) connect(tmp_pb, TQT_SIGNAL(toggled(bool)), TQT_SLOT(slotHyptoggled(bool))); tmp_pb->setToggleButton(true); - tmp_pb = new KCalcButton(parent, "Sin-Button"); + tmp_pb = new KCalcButton(tqparent, "Sin-Button"); pbScientific.insert("Sine", tmp_pb); tmp_pb->addMode(ModeNormal, "Sin", i18n("Sine")); tmp_pb->addMode(ModeInverse, "Asin", i18n("Arc sine")); @@ -822,7 +822,7 @@ void KCalculator::setupScientificKeys(TQWidget *parent) tmp_pb, TQT_SLOT(slotSetMode(ButtonModeFlags,bool))); connect(tmp_pb, TQT_SIGNAL(clicked(void)), TQT_SLOT(slotSinclicked(void))); - tmp_pb = new KCalcButton(parent, "Cos-Button"); + tmp_pb = new KCalcButton(tqparent, "Cos-Button"); pbScientific.insert("Cosine", tmp_pb); tmp_pb->addMode(ModeNormal, "Cos", i18n("Cosine")); tmp_pb->addMode(ModeInverse, "Acos", i18n("Arc cosine")); @@ -836,7 +836,7 @@ void KCalculator::setupScientificKeys(TQWidget *parent) tmp_pb, TQT_SLOT(slotSetMode(ButtonModeFlags,bool))); connect(tmp_pb, TQT_SIGNAL(clicked(void)), TQT_SLOT(slotCosclicked(void))); - tmp_pb = new KCalcButton(parent, "Tan-Button"); + tmp_pb = new KCalcButton(tqparent, "Tan-Button"); pbScientific.insert("Tangent", tmp_pb); tmp_pb->addMode(ModeNormal, "Tan", i18n("Tangent")); tmp_pb->addMode(ModeInverse, "Atan", i18n("Arc tangent")); @@ -850,7 +850,7 @@ void KCalculator::setupScientificKeys(TQWidget *parent) tmp_pb, TQT_SLOT(slotSetMode(ButtonModeFlags,bool))); connect(tmp_pb, TQT_SIGNAL(clicked(void)),TQT_SLOT(slotTanclicked(void))); - tmp_pb = new KCalcButton(parent, "Ln-Button"); + tmp_pb = new KCalcButton(tqparent, "Ln-Button"); tmp_pb->addMode(ModeNormal, "Ln", i18n("Natural log")); tmp_pb->addMode(ModeInverse, "e<sup> x </sup>", i18n("Exponential function"), true); @@ -862,7 +862,7 @@ void KCalculator::setupScientificKeys(TQWidget *parent) tmp_pb, TQT_SLOT(slotSetMode(ButtonModeFlags,bool))); connect(tmp_pb, TQT_SIGNAL(clicked(void)), TQT_SLOT(slotLnclicked(void))); - tmp_pb = new KCalcButton(parent, "Log-Button"); + tmp_pb = new KCalcButton(tqparent, "Log-Button"); tmp_pb->addMode(ModeNormal, "Log", i18n("Logarithm to base 10")); tmp_pb->addMode(ModeInverse, "10<sup> x </sup>", i18n("10 to the power of x"), true); @@ -876,13 +876,13 @@ void KCalculator::setupScientificKeys(TQWidget *parent) } -void KCalculator::setupStatisticKeys(TQWidget *parent) +void KCalculator::setupStatisticKeys(TQWidget *tqparent) { - Q_CHECK_PTR(parent); + Q_CHECK_PTR(tqparent); KCalcButton *tmp_pb; - tmp_pb = new KCalcButton(parent, "Stat.NumData-Button"); + tmp_pb = new KCalcButton(tqparent, "Stat.NumData-Button"); tmp_pb->addMode(ModeNormal, "N", i18n("Number of data entered")); tmp_pb->addMode(ModeInverse, TQString::fromUtf8("\xce\xa3") + "x", i18n("Sum of all data items")); @@ -894,7 +894,7 @@ void KCalculator::setupStatisticKeys(TQWidget *parent) tmp_pb, TQT_SLOT(slotSetMode(ButtonModeFlags,bool))); connect(tmp_pb, TQT_SIGNAL(clicked(void)), TQT_SLOT(slotStatNumclicked(void))); - tmp_pb = new KCalcButton(parent, "Stat.Median-Button"); + tmp_pb = new KCalcButton(tqparent, "Stat.Median-Button"); tmp_pb->addMode(ModeNormal, "Med", i18n("Median")); pbStat.insert("Median", tmp_pb); mStatButtonList.append(tmp_pb); @@ -903,7 +903,7 @@ void KCalculator::setupStatisticKeys(TQWidget *parent) tmp_pb, TQT_SLOT(slotSetAccelDisplayMode(bool))); connect(tmp_pb, TQT_SIGNAL(clicked(void)), TQT_SLOT(slotStatMedianclicked(void))); - tmp_pb = new KCalcButton(parent, "Stat.Mean-Button"); + tmp_pb = new KCalcButton(tqparent, "Stat.Mean-Button"); tmp_pb->addMode(ModeNormal, "Mea", i18n("Mean")); tmp_pb->addMode(ModeInverse, TQString::fromUtf8("\xce\xa3") + "x<sup>2</sup>", @@ -916,7 +916,7 @@ void KCalculator::setupStatisticKeys(TQWidget *parent) tmp_pb, TQT_SLOT(slotSetMode(ButtonModeFlags,bool))); connect(tmp_pb, TQT_SIGNAL(clicked(void)), TQT_SLOT(slotStatMeanclicked(void))); - tmp_pb = new KCalcButton(parent, "Stat.StandardDeviation-Button"); + tmp_pb = new KCalcButton(tqparent, "Stat.StandardDeviation-Button"); tmp_pb->addMode(ModeNormal, TQString::fromUtf8("σ",-1) + "<sub>N-1</sub>", i18n("Sample standard deviation"), true); tmp_pb->addMode(ModeInverse, TQString::fromUtf8("σ",-1) + "<sub>N</sub>", @@ -929,7 +929,7 @@ void KCalculator::setupStatisticKeys(TQWidget *parent) tmp_pb, TQT_SLOT(slotSetMode(ButtonModeFlags,bool))); connect(tmp_pb, TQT_SIGNAL(clicked(void)), TQT_SLOT(slotStatStdDevclicked(void))); - tmp_pb = new KCalcButton(parent, "Stat.DataInput-Button"); + tmp_pb = new KCalcButton(tqparent, "Stat.DataInput-Button"); tmp_pb->addMode(ModeNormal, "Dat", i18n("Enter data")); tmp_pb->addMode(ModeInverse, "CDat", i18n("Delete last data item")); pbStat.insert("InputData", tmp_pb); @@ -940,7 +940,7 @@ void KCalculator::setupStatisticKeys(TQWidget *parent) tmp_pb, TQT_SLOT(slotSetMode(ButtonModeFlags,bool))); connect(tmp_pb, TQT_SIGNAL(clicked(void)), TQT_SLOT(slotStatDataInputclicked(void))); - tmp_pb = new KCalcButton(parent, "Stat.ClearData-Button"); + tmp_pb = new KCalcButton(tqparent, "Stat.ClearData-Button"); tmp_pb->addMode(ModeNormal, "CSt", i18n("Clear data store")); pbStat.insert("ClearData", tmp_pb); mStatButtonList.append(tmp_pb); @@ -949,16 +949,16 @@ void KCalculator::setupStatisticKeys(TQWidget *parent) connect(tmp_pb, TQT_SIGNAL(clicked(void)), TQT_SLOT(slotStatClearDataclicked(void))); } -void KCalculator::setupConstantsKeys(TQWidget *parent) +void KCalculator::setupConstantsKeys(TQWidget *tqparent) { - Q_CHECK_PTR(parent); + Q_CHECK_PTR(tqparent); ConstButtonGroup = new TQButtonGroup(0, "Const-Button-Group"); connect(ConstButtonGroup, TQT_SIGNAL(clicked(int)), TQT_SLOT(slotConstclicked(int))); KCalcConstButton *tmp_pb; - tmp_pb = new KCalcConstButton(parent, 0, "C1"); + tmp_pb = new KCalcConstButton(tqparent, 0, "C1"); tmp_pb->setAccel(ALT + Key_1); pbConstant[0] = tmp_pb; connect(this, TQT_SIGNAL(switchShowAccels(bool)), @@ -967,7 +967,7 @@ void KCalculator::setupConstantsKeys(TQWidget *parent) tmp_pb, TQT_SLOT(slotSetMode(ButtonModeFlags,bool))); ConstButtonGroup->insert(tmp_pb, 0); - tmp_pb = new KCalcConstButton(parent, 1, "C2"); + tmp_pb = new KCalcConstButton(tqparent, 1, "C2"); tmp_pb->setAccel(ALT + Key_2); pbConstant[1] = tmp_pb; connect(this, TQT_SIGNAL(switchShowAccels(bool)), @@ -976,7 +976,7 @@ void KCalculator::setupConstantsKeys(TQWidget *parent) tmp_pb, TQT_SLOT(slotSetMode(ButtonModeFlags,bool))); ConstButtonGroup->insert(tmp_pb, 1); - tmp_pb = new KCalcConstButton(parent, 2, "C3"); + tmp_pb = new KCalcConstButton(tqparent, 2, "C3"); tmp_pb->setAccel(ALT + Key_3); pbConstant[2] = tmp_pb; connect(this, TQT_SIGNAL(switchShowAccels(bool)), @@ -985,7 +985,7 @@ void KCalculator::setupConstantsKeys(TQWidget *parent) tmp_pb, TQT_SLOT(slotSetMode(ButtonModeFlags,bool))); ConstButtonGroup->insert(tmp_pb, 2); - tmp_pb = new KCalcConstButton(parent, 3, "C4"); + tmp_pb = new KCalcConstButton(tqparent, 3, "C4"); tmp_pb->setAccel(ALT + Key_4); pbConstant[3] = tmp_pb; connect(this, TQT_SIGNAL(switchShowAccels(bool)), @@ -994,7 +994,7 @@ void KCalculator::setupConstantsKeys(TQWidget *parent) tmp_pb, TQT_SLOT(slotSetMode(ButtonModeFlags,bool))); ConstButtonGroup->insert(tmp_pb, 3); - tmp_pb = new KCalcConstButton(parent, 4, "C5"); + tmp_pb = new KCalcConstButton(tqparent, 4, "C5"); tmp_pb->setAccel(ALT + Key_5); pbConstant[4] = tmp_pb; connect(this, TQT_SIGNAL(switchShowAccels(bool)), @@ -1003,7 +1003,7 @@ void KCalculator::setupConstantsKeys(TQWidget *parent) tmp_pb, TQT_SLOT(slotSetMode(ButtonModeFlags,bool))); ConstButtonGroup->insert(tmp_pb, 4); - tmp_pb = new KCalcConstButton(parent, 5, "C6"); + tmp_pb = new KCalcConstButton(tqparent, 5, "C6"); tmp_pb->setAccel(ALT + Key_6); pbConstant[5] = tmp_pb; connect(this, TQT_SIGNAL(switchShowAccels(bool)), @@ -1041,7 +1041,7 @@ void KCalculator::updateGeometry(void) s.setHeight(mSmallPage->fontMetrics().lineSpacing()); // why this stupid cast! - l = const_cast<TQObjectList *>(mSmallPage->children()); + l = const_cast<TQObjectList *>(mSmallPage->tqchildren()); for(uint i=0; i < l->count(); i++) { @@ -1050,7 +1050,7 @@ void KCalculator::updateGeometry(void) { TQWidget *tmp_widget = dynamic_cast<TQWidget *>(o); margin = TQApplication::style(). - pixelMetric(TQStyle::PM_ButtonMargin, (tmp_widget))*2; + tqpixelMetric(TQStyle::PM_ButtonMargin, (tmp_widget))*2; tmp_widget->setFixedSize(s.width()+margin, s.height()+margin); //tmp_widget->setMinimumSize(s.width()+margin, s.height()+margin); tmp_widget->installEventFilter( this ); @@ -1059,13 +1059,13 @@ void KCalculator::updateGeometry(void) } // why this stupic cast !! - l = const_cast<TQObjectList*>(mLargePage->children()); + l = const_cast<TQObjectList*>(mLargePage->tqchildren()); - int h1 = (NumButtonGroup->find(0x0F))->minimumSize().height(); + int h1 = (NumButtonGroup->tqfind(0x0F))->tqminimumSize().height(); int h2 = static_cast<int>( (static_cast<float>(h1) + 4.0) / 5.0 ); s.setWidth(mLargePage->fontMetrics().width("MMM") + TQApplication::style(). - pixelMetric(TQStyle::PM_ButtonMargin, NumButtonGroup->find(0x0F))*2); + tqpixelMetric(TQStyle::PM_ButtonMargin, NumButtonGroup->tqfind(0x0F))*2); s.setHeight(h1 + h2); for(uint i = 0; i < l->count(); i++) @@ -1086,13 +1086,13 @@ void KCalculator::updateGeometry(void) - l = (TQObjectList*)mNumericPage->children(); // silence please + l = (TQObjectList*)mNumericPage->tqchildren(); // silence please - h1 = (NumButtonGroup->find(0x0F))->minimumSize().height(); + h1 = (NumButtonGroup->tqfind(0x0F))->tqminimumSize().height(); h2 = (int)((((float)h1 + 4.0) / 5.0)); s.setWidth(mLargePage->fontMetrics().width("MMM") + TQApplication::style(). - pixelMetric(TQStyle::PM_ButtonMargin, NumButtonGroup->find(0x0F))*2); + tqpixelMetric(TQStyle::PM_ButtonMargin, NumButtonGroup->tqfind(0x0F))*2); s.setHeight(h1 + h2); for(uint i = 0; i < l->count(); i++) @@ -1110,7 +1110,7 @@ void KCalculator::updateGeometry(void) // Set Buttons of double size TQSize t(s); t.setWidth(2*s.width()); - NumButtonGroup->find(0x00)->setFixedSize(t); + NumButtonGroup->tqfind(0x00)->setFixedSize(t); t = s; t.setHeight(2*s.height()); pbEqual->setFixedSize(t); @@ -1152,11 +1152,11 @@ void KCalculator::slotBaseSelected(int base) // Enable the buttons not available in this base for (int i=0; i<current_base; i++) - NumButtonGroup->find(i)->setEnabled (true); + NumButtonGroup->tqfind(i)->setEnabled (true); // Disable the buttons not available in this base for (int i=current_base; i<16; i++) - NumButtonGroup->find(i)->setEnabled (false); + NumButtonGroup->tqfind(i)->setEnabled (false); // Only enable the decimal point in decimal pbPeriod->setEnabled(current_base == NB_DECIMAL); @@ -1271,7 +1271,7 @@ void KCalculator::slotInvtoggled(bool flag) else { statusBar()->changeItem("NORM", 0); - calc_display->setStatusText(0, TQString::null); + calc_display->setStatusText(0, TQString()); } } @@ -1544,7 +1544,7 @@ void KCalculator::slotMCclicked(void) { memory_num = 0; statusBar()->changeItem(" \xa0\xa0 ",3); - calc_display->setStatusText(3, TQString::null); + calc_display->setStatusText(3, TQString()); pbMemRecall->setDisabled(true); } @@ -1951,7 +1951,7 @@ void KCalculator::slotStatshow(bool toggled) pbStat["ClearData"]->hide(); } adjustSize(); - setFixedSize(sizeHint()); + setFixedSize(tqsizeHint()); KCalcSettings::setShowStat(toggled); } @@ -1983,10 +1983,10 @@ void KCalculator::slotScientificshow(bool toggled) pbAngleChoose->hide(); if(statusBar()->hasItem(2)) statusBar()->removeItem(2); - calc_display->setStatusText(2, TQString::null); + calc_display->setStatusText(2, TQString()); } adjustSize(); - setFixedSize(sizeHint()); + setFixedSize(tqsizeHint()); KCalcSettings::setShowScientific(toggled); } @@ -2007,7 +2007,7 @@ void KCalculator::slotLogicshow(bool toggled) resetBase(); BaseChooseGroup->show(); for (int i=10; i<16; i++) - (NumButtonGroup->find(i))->show(); + (NumButtonGroup->tqfind(i))->show(); } else { @@ -2022,12 +2022,12 @@ void KCalculator::slotLogicshow(bool toggled) BaseChooseGroup->hide(); if(statusBar()->hasItem(1)) statusBar()->removeItem(1); - calc_display->setStatusText(1, TQString::null); + calc_display->setStatusText(1, TQString()); for (int i=10; i<16; i++) - (NumButtonGroup->find(i))->hide(); + (NumButtonGroup->tqfind(i))->hide(); } adjustSize(); - setFixedSize(sizeHint()); + setFixedSize(tqsizeHint()); KCalcSettings::setShowLogic(toggled); } @@ -2053,7 +2053,7 @@ void KCalculator::slotConstantsShow(bool toggled) pbConstant[5]->hide(); } adjustSize(); - setFixedSize(sizeHint()); + setFixedSize(tqsizeHint()); KCalcSettings::setShowConstants(toggled); } @@ -2104,12 +2104,12 @@ void KCalculator::updateSettings() } else { - setCaption(TQString::null); + setCaption(TQString()); } calc_display->changeSettings(); updateGeometry(); - resize(minimumSize()); + resize(tqminimumSize()); // // 1999-10-31 Espen Sand: Don't ask me why ;) @@ -2145,7 +2145,7 @@ void KCalculator::set_colors() TQPalette numPal(KCalcSettings::numberButtonsColor(), bg); for(int i=0; i<10; i++) { - (NumButtonGroup->find(i))->setPalette(numPal); + (NumButtonGroup->tqfind(i))->setPalette(numPal); } TQPalette funcPal(KCalcSettings::functionButtonsColor(), bg); @@ -2164,7 +2164,7 @@ void KCalculator::set_colors() TQPalette hexPal(KCalcSettings::hexButtonsColor(), bg); for(int i=10; i<16; i++) { - (NumButtonGroup->find(i))->setPalette(hexPal); + (NumButtonGroup->tqfind(i))->setPalette(hexPal); } TQPalette memPal(KCalcSettings::memoryButtonsColor(), bg); @@ -2218,26 +2218,26 @@ bool KCalculator::eventFilter(TQObject *o, TQEvent *e) // Was it hex-button or normal digit?? if (num_but <10) for(int i=0; i<10; i++) - (NumButtonGroup->find(i))->setPalette(pal); + (NumButtonGroup->tqfind(i))->setPalette(pal); else for(int i=10; i<16; i++) - (NumButtonGroup->find(i))->setPalette(pal); + (NumButtonGroup->tqfind(i))->setPalette(pal); return true; } - else if( mFunctionButtonList.findRef((KCalcButton*)o) != -1) + else if( mFunctionButtonList.tqfindRef((KCalcButton*)o) != -1) { list = &mFunctionButtonList; } - else if( mStatButtonList.findRef((KCalcButton*)o) != -1) + else if( mStatButtonList.tqfindRef((KCalcButton*)o) != -1) { list = &mStatButtonList; } - else if( mMemButtonList.findRef((KCalcButton*)o) != -1) + else if( mMemButtonList.tqfindRef((KCalcButton*)o) != -1) { list = &mMemButtonList; } - else if( mOperationButtonList.findRef((KCalcButton*)o) != -1) + else if( mOperationButtonList.tqfindRef((KCalcButton*)o) != -1) { list = &mOperationButtonList; } @@ -2296,7 +2296,7 @@ extern "C" KDE_EXPORT int kdemain(int argc, char *argv[]) KCalculator *calc = new KCalculator; app.setTopWidget(calc); - calc->setCaption(TQString::null); + calc->setCaption(TQString()); calc->show(); int exitCode = app.exec(); diff --git a/kcalc/kcalc.h b/kcalc/kcalc.h index 87f389e..f135a3c 100644 --- a/kcalc/kcalc.h +++ b/kcalc/kcalc.h @@ -1,6 +1,6 @@ /* KCalc, a scientific calculator for the X window system using the - Qt widget libraries, available at no cost at http://www.troll.no + TQt widget libraries, available at no cost at http://www.troll.no Copyright (C) 1996 Bernd Johannes Wuebben wuebben@math.cornell.edu @@ -61,9 +61,10 @@ class Constants; class KCalculator : public KMainWindow { Q_OBJECT + TQ_OBJECT public: - KCalculator(TQWidget *parent = 0, const char *name = 0); + KCalculator(TQWidget *tqparent = 0, const char *name = 0); ~KCalculator(); signals: @@ -76,16 +77,16 @@ private: void updateGeometry(); void setupMainActions(void); void setupStatusbar(void); - TQWidget *setupNumericKeys(TQWidget *parent); - void setupLogicKeys(TQWidget *parent); - void setupScientificKeys(TQWidget *parent); - void setupStatisticKeys(TQWidget *parent); - void setupConstantsKeys(TQWidget *parent); + TQWidget *setupNumericKeys(TQWidget *tqparent); + void setupLogicKeys(TQWidget *tqparent); + void setupScientificKeys(TQWidget *tqparent); + void setupStatisticKeys(TQWidget *tqparent); + void setupConstantsKeys(TQWidget *tqparent); void keyPressEvent(TQKeyEvent *e); void keyReleaseEvent(TQKeyEvent *e); void set_precision(); void set_style(); - void resetBase(void) { (BaseChooseGroup->find(1))->animateClick();}; + void resetBase(void) { (BaseChooseGroup->tqfind(1))->animateClick();}; void UpdateDisplay(bool get_amount_from_core = false, bool store_result_in_history = false); diff --git a/kcalc/kcalc_button.cpp b/kcalc/kcalc_button.cpp index 7472f92..0bde80d 100644 --- a/kcalc/kcalc_button.cpp +++ b/kcalc/kcalc_button.cpp @@ -30,16 +30,16 @@ #include "kcalc_button.h" -KCalcButton::KCalcButton(TQWidget * parent, const char * name) - : KPushButton(parent, name), _show_accel_mode(false), +KCalcButton::KCalcButton(TQWidget * tqparent, const char * name) + : KPushButton(tqparent, name), _show_accel_mode(false), _mode_flags(ModeNormal) { setAutoDefault(false); } -KCalcButton::KCalcButton(const TQString &label, TQWidget * parent, +KCalcButton::KCalcButton(const TQString &label, TQWidget * tqparent, const char * name, const TQString &tooltip) - : KPushButton(label, parent, name), _show_accel_mode(false), _mode_flags(ModeNormal) + : KPushButton(label, tqparent, name), _show_accel_mode(false), _mode_flags(ModeNormal) { setAutoDefault(false); addMode(ModeNormal, label, tooltip); @@ -47,7 +47,7 @@ KCalcButton::KCalcButton(const TQString &label, TQWidget * parent, void KCalcButton::addMode(ButtonModeFlags mode, TQString label, TQString tooltip, bool is_label_richtext) { - if (_mode.contains(mode)) _mode.remove(mode); + if (_mode.tqcontains(mode)) _mode.remove(mode); _mode[mode] = ButtonMode(label, tooltip, is_label_richtext); @@ -67,7 +67,7 @@ void KCalcButton::slotSetMode(ButtonModeFlags mode, bool flag) return; // nothing to do } - if (_mode.contains(new_mode)) { + if (_mode.tqcontains(new_mode)) { // save accel, because setting label erases accel TQKeySequence _accel = accel(); @@ -92,7 +92,7 @@ void KCalcButton::slotSetMode(ButtonModeFlags mode, bool flag) static TQString escape(TQString str) { - str.replace('&', "&&"); + str.tqreplace('&', "&&"); return str; } @@ -118,7 +118,7 @@ void KCalcButton::paintLabel(TQPainter *paint) { if (_mode[_mode_flags].is_label_richtext) { TQSimpleRichText _text(_label, font()); - _text.draw(paint, width()/2-_text.width()/2, 0, childrenRegion(), colorGroup()); + _text.draw(paint, width()/2-_text.width()/2, 0, tqchildrenRegion(), tqcolorGroup()); } else { KPushButton::drawButtonLabel(paint); } @@ -128,7 +128,7 @@ void KCalcButton::drawButtonLabel(TQPainter *paint) { if (_show_accel_mode) { KPushButton::drawButtonLabel(paint); - } else if (_mode.contains(_mode_flags)) { + } else if (_mode.tqcontains(_mode_flags)) { paintLabel(paint); } } @@ -159,7 +159,7 @@ void KSquareButton::drawButtonLabel(TQPainter *paint) { if (_show_accel_mode) { KPushButton::drawButtonLabel(paint); - } else if (_mode.contains(_mode_flags)) { + } else if (_mode.tqcontains(_mode_flags)) { paintLabel(paint); } } diff --git a/kcalc/kcalc_button.h b/kcalc/kcalc_button.h index f1a060f..60a7c30 100644 --- a/kcalc/kcalc_button.h +++ b/kcalc/kcalc_button.h @@ -1,6 +1,6 @@ /* KCalc, a scientific calculator for the X window system using the - Qt widget libraries, available at no cost at http://www.troll.no + TQt widget libraries, available at no cost at http://www.troll.no Copyright (C) 1996 Bernd Johannes Wuebben wuebben@math.cornell.edu @@ -61,10 +61,11 @@ public: class KCalcButton : public KPushButton { Q_OBJECT + TQ_OBJECT public: - KCalcButton(TQWidget *parent, const char * name = 0); - KCalcButton(const TQString &label, TQWidget *parent, const char * name = 0, + KCalcButton(TQWidget *tqparent, const char * name = 0); + KCalcButton(const TQString &label, TQWidget *tqparent, const char * name = 0, const TQString &tooltip = TQString()); void addMode(ButtonModeFlags mode, TQString label, TQString tooltip, bool is_label_richtext = false); @@ -89,13 +90,14 @@ protected: class KSquareButton : public KCalcButton { Q_OBJECT + TQ_OBJECT public: - KSquareButton(TQWidget *parent, const char * name = 0) - : KCalcButton(parent, name) { }; - KSquareButton(const TQString &label, TQWidget *parent, const char * name = 0, + KSquareButton(TQWidget *tqparent, const char * name = 0) + : KCalcButton(tqparent, name) { }; + KSquareButton(const TQString &label, TQWidget *tqparent, const char * name = 0, const TQString &tooltip = TQString()) - : KCalcButton(label, parent, name, tooltip) { }; + : KCalcButton(label, tqparent, name, tooltip) { }; protected: virtual void drawButtonLabel(TQPainter *paint); diff --git a/kcalc/kcalc_const_button.cpp b/kcalc/kcalc_const_button.cpp index 071bb71..a8eb989 100644 --- a/kcalc/kcalc_const_button.cpp +++ b/kcalc/kcalc_const_button.cpp @@ -31,8 +31,8 @@ #include "kcalc_settings.h" -KCalcConstButton::KCalcConstButton(TQWidget *parent, int but_num, const char * name) - : KCalcButton(parent, name), _button_num(but_num) +KCalcConstButton::KCalcConstButton(TQWidget *tqparent, int but_num, const char * name) + : KCalcButton(tqparent, name), _button_num(but_num) { addMode(ModeInverse, "Store", i18n("Write display data into memory")); @@ -40,9 +40,9 @@ KCalcConstButton::KCalcConstButton(TQWidget *parent, int but_num, const char * n } -KCalcConstButton::KCalcConstButton(const TQString &label, TQWidget *parent, int but_num, +KCalcConstButton::KCalcConstButton(const TQString &label, TQWidget *tqparent, int but_num, const char * name, const TQString &tooltip) - : KCalcButton(label, parent, name, tooltip), _button_num(but_num) + : KCalcButton(label, tqparent, name, tooltip), _button_num(but_num) { addMode(ModeInverse, "Store", i18n("Write display data into memory")); diff --git a/kcalc/kcalc_const_button.h b/kcalc/kcalc_const_button.h index 110df3c..916d7f6 100644 --- a/kcalc/kcalc_const_button.h +++ b/kcalc/kcalc_const_button.h @@ -1,6 +1,6 @@ /* KCalc, a scientific calculator for the X window system using the - Qt widget libraries, available at no cost at http://www.troll.no + TQt widget libraries, available at no cost at http://www.troll.no Copyright (C) 1996 Bernd Johannes Wuebben wuebben@math.cornell.edu @@ -31,12 +31,13 @@ class KCalcConstButton : public KCalcButton { Q_OBJECT + TQ_OBJECT public: - KCalcConstButton(TQWidget *parent, int but_num, const char * name = 0); + KCalcConstButton(TQWidget *tqparent, int but_num, const char * name = 0); - KCalcConstButton(const TQString &label, TQWidget *parent, int but_num, const char * name = 0, + KCalcConstButton(const TQString &label, TQWidget *tqparent, int but_num, const char * name = 0, const TQString &tooltip = TQString()); TQString constant(void) const; diff --git a/kcalc/kcalc_const_menu.cpp b/kcalc/kcalc_const_menu.cpp index f758c9f..7984daf 100644 --- a/kcalc/kcalc_const_menu.cpp +++ b/kcalc/kcalc_const_menu.cpp @@ -49,8 +49,8 @@ const struct science_constant KCalcConstMenu::Constants[] = { {"N_A", I18N_NOOP("Avogadro's Number"), "", "6.0221415e23", Thermodynamics} }; -KCalcConstMenu::KCalcConstMenu(TQWidget * parent, const char * name) - : TQPopupMenu(parent, name) +KCalcConstMenu::KCalcConstMenu(TQWidget * tqparent, const char * name) + : TQPopupMenu(tqparent, name) { TQPopupMenu *math_menu = new TQPopupMenu(this, "mathematical constants"); TQPopupMenu *em_menu = new TQPopupMenu(this, "electromagnetic constants"); diff --git a/kcalc/kcalc_const_menu.h b/kcalc/kcalc_const_menu.h index 94c8412..331a6a1 100644 --- a/kcalc/kcalc_const_menu.h +++ b/kcalc/kcalc_const_menu.h @@ -1,6 +1,6 @@ /* KCalc, a scientific calculator for the X window system using the - Qt widget libraries, available at no cost at http://www.troll.no + TQt widget libraries, available at no cost at http://www.troll.no Copyright (C) 2004 Klaus Niederkruger @@ -36,12 +36,12 @@ struct science_constant{ ConstantCategory category; }; -class KCalcConstMenu : public QPopupMenu +class KCalcConstMenu : public TQPopupMenu { -Q_OBJECT +TQ_OBJECT public: - KCalcConstMenu(TQWidget * parent = 0, const char * name = 0); + KCalcConstMenu(TQWidget * tqparent = 0, const char * name = 0); static const struct science_constant Constants[]; diff --git a/kcalc/kcalc_core.cpp b/kcalc/kcalc_core.cpp index 4270895..89a2438 100644 --- a/kcalc/kcalc_core.cpp +++ b/kcalc/kcalc_core.cpp @@ -1,6 +1,6 @@ /* kCalculator, a scientific calculator for the X window system using the - Qt widget libraries, available at no cost at http://www.troll.no + TQt widget libraries, available at no cost at http://www.troll.no The stack engine contained in this file was take from Martin Bartlett's xfrmcalc @@ -209,7 +209,7 @@ CalcEngine::CalcEngine() struct sigaction fpe_trap; - sigemptyset(&fpe_trap.sa_mask); + sigemptyset(&fpe_trap.sa_tqmask); fpe_trap.sa_handler = &fpe_handler; #ifdef SA_RESTART fpe_trap.sa_flags = SA_RESTART; diff --git a/kcalc/kcalc_core.h b/kcalc/kcalc_core.h index fe818e9..f02d880 100644 --- a/kcalc/kcalc_core.h +++ b/kcalc/kcalc_core.h @@ -1,7 +1,7 @@ /* KCalc, a scientific calculator for the X window system using the - Qt widget libraries, available at no cost at http://www.troll.no + TQt widget libraries, available at no cost at http://www.troll.no Copyright (C) 1996 Bernd Johannes Wuebben wuebben@math.cornell.edu diff --git a/kcalc/kcalcdisplay.cpp b/kcalc/kcalcdisplay.cpp index 1f90e03..fb0595e 100644 --- a/kcalc/kcalcdisplay.cpp +++ b/kcalc/kcalcdisplay.cpp @@ -2,7 +2,7 @@ $Id$ KCalc, a scientific calculator for the X window system using the - Qt widget libraries, available at no cost at http://www.troll.no + TQt widget libraries, available at no cost at http://www.troll.no Copyright (C) 1996 Bernd Johannes Wuebben wuebben@math.cornell.edu @@ -39,17 +39,17 @@ #include "kcalcdisplay.moc" -KCalcDisplay::KCalcDisplay(TQWidget *parent, const char *name) - :TQLabel(parent,name), _beep(false), _groupdigits(false), _button(0), _lit(false), +KCalcDisplay::KCalcDisplay(TQWidget *tqparent, const char *name) + :TQLabel(tqparent,name), _beep(false), _groupdigits(false), _button(0), _lit(false), _num_base(NB_DECIMAL), _precision(9), _fixed_precision(-1), _display_amount(0), selection_timer(new TQTimer) { setFrameStyle(TQFrame::WinPanel | TQFrame::Sunken); - setAlignment(AlignRight | AlignVCenter); + tqsetAlignment(AlignRight | AlignVCenter); setFocus(); - setFocusPolicy(TQWidget::StrongFocus); - setSizePolicy(TQSizePolicy::Expanding, TQSizePolicy::Fixed, false); + setFocusPolicy(TQ_StrongFocus); + tqsetSizePolicy(TQSizePolicy::Expanding, TQSizePolicy::Fixed, false); connect(this, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotDisplaySelected())); @@ -71,7 +71,7 @@ bool KCalcDisplay::sendEvent(Event const event) case EventReset: _display_amount = 0; _str_int = "0"; - _str_int_exp = TQString::null; + _str_int_exp = TQString(); _eestate = false; _period = false; @@ -105,13 +105,13 @@ void KCalcDisplay::slotCopy(void) TQString txt = TQLabel::text(); if (_num_base == NB_HEX) txt.prepend( "0x" ); - (TQApplication::clipboard())->setText(txt, QClipboard::Clipboard); - (TQApplication::clipboard())->setText(txt, QClipboard::Selection); + (TQApplication::tqclipboard())->setText(txt, TQClipboard::Clipboard); + (TQApplication::tqclipboard())->setText(txt, TQClipboard::Selection); } void KCalcDisplay::slotPaste(bool bClipboard) { - TQString tmp_str = (TQApplication::clipboard())->text(bClipboard ? QClipboard::Clipboard : QClipboard::Selection); + TQString tmp_str = (TQApplication::tqclipboard())->text(bClipboard ? TQClipboard::Clipboard : TQClipboard::Selection); if (tmp_str.isNull()) { @@ -226,7 +226,7 @@ bool KCalcDisplay::setAmount(KNumber const & new_amount) TQString display_str; _str_int = "0"; - _str_int_exp = TQString::null; + _str_int_exp = TQString(); _period = false; _neg_sign = false; _eestate = false; @@ -243,7 +243,7 @@ bool KCalcDisplay::setAmount(KNumber const & new_amount) { _display_amount = new_amount; - display_str = _display_amount.toQString(KCalcSettings::precision(), _fixed_precision); + display_str = _display_amount.toTQString(KCalcSettings::precision(), _fixed_precision); #if 0 else if (_display_amount > 1.0e+16) display_str = TQCString().sprintf(PRINT_LONG_BIG, _precision + 1, _display_amount); @@ -281,7 +281,7 @@ TQString KCalcDisplay::text() const { if (_num_base != NB_DECIMAL) return TQLabel::text(); - TQString display_str = _display_amount.toQString(KCalcSettings::precision()); + TQString display_str = _display_amount.toTQString(KCalcSettings::precision()); return display_str; // return TQCString().sprintf(PRINT_LONG_BIG, 40, _display_amount); @@ -584,7 +584,7 @@ void KCalcDisplay::drawContents(TQPainter *p) // draw the status texts using half of the normal // font size but not smaller than 7pt TQFont f(font()); - f.setPointSize(QMAX((f.pointSize() / 2), 7)); + f.setPointSize(TQMAX((f.pointSize() / 2), 7)); p->setFont(f); TQFontMetrics fm(f); uint w = fm.width("_____"); @@ -596,13 +596,13 @@ void KCalcDisplay::drawContents(TQPainter *p) } } -// Return the QLabel's normal size hint vertically expanded +// Return the TQLabel's normal size hint vertically expanded // by half the font height to make room for the status texts -TQSize KCalcDisplay::sizeHint() const +TQSize KCalcDisplay::tqsizeHint() const { TQFont f(font()); - f.setPointSize(QMAX((f.pointSize() / 2), 7)); + f.setPointSize(TQMAX((f.pointSize() / 2), 7)); TQFontMetrics fm(f); - return TQLabel::sizeHint() + TQSize(0, fm.height()); + return TQLabel::tqsizeHint() + TQSize(0, fm.height()); } diff --git a/kcalc/kcalcdisplay.h b/kcalc/kcalcdisplay.h index 6f7233c..4c0371c 100644 --- a/kcalc/kcalcdisplay.h +++ b/kcalc/kcalcdisplay.h @@ -76,12 +76,13 @@ enum NumBase { }; -class KCalcDisplay : public QLabel +class KCalcDisplay : public TQLabel { Q_OBJECT + TQ_OBJECT public: - KCalcDisplay(TQWidget *parent=0, const char *name=0); + KCalcDisplay(TQWidget *tqparent=0, const char *name=0); ~KCalcDisplay(); protected: @@ -109,7 +110,7 @@ public: TQString text() const; bool updateDisplay(void); void setStatusText(uint i, const TQString& text); - virtual TQSize sizeHint() const; + virtual TQSize tqsizeHint() const; private: bool _beep; bool _groupdigits; diff --git a/kcalc/kcalctype.h b/kcalc/kcalctype.h index 8223e87..6c69aec 100644 --- a/kcalc/kcalctype.h +++ b/kcalc/kcalctype.h @@ -2,7 +2,7 @@ $Id$ KCalc, a scientific calculator for the X window system using the - Qt widget libraries, available at no cost at http://www.troll.no + TQt widget libraries, available at no cost at http://www.troll.no Copyright (C) 1996 Bernd Johannes Wuebben wuebben@math.cornell.edu diff --git a/kcalc/knumber/knumber.cpp b/kcalc/knumber/knumber.cpp index 80bae1f..123fee7 100644 --- a/kcalc/knumber/knumber.cpp +++ b/kcalc/knumber/knumber.cpp @@ -276,7 +276,7 @@ static void _inc_by_one(TQString &str, int position) // Cut off if more digits in fractional part than 'precision' static void _round(TQString &str, int precision) { - int decimalSymbolPos = str.find('.'); + int decimalSymbolPos = str.tqfind('.'); if (decimalSymbolPos == -1) if (precision == 0) return; @@ -312,7 +312,7 @@ static void _round(TQString &str, int precision) break; } - decimalSymbolPos = str.find('.'); + decimalSymbolPos = str.tqfind('.'); str.truncate(decimalSymbolPos + precision + 1); // if precision == 0 delete also '.' @@ -349,7 +349,7 @@ static TQString roundNumber(const TQString &numStr, int precision) } -TQString const KNumber::toQString(int width, int prec) const +TQString const KNumber::toTQString(int width, int prec) const { TQString tmp_str; @@ -360,7 +360,7 @@ TQString const KNumber::toQString(int width, int prec) const if (width > 0) { //result needs to be cut-off bool tmp_bool = _fraction_input; // stupid work-around _fraction_input = false; - tmp_str = (KNumber("1.0")*(*this)).toQString(width, -1); + tmp_str = (KNumber("1.0")*(*this)).toTQString(width, -1); _fraction_input = tmp_bool; } else tmp_str = TQString(_num->ascii()); @@ -369,7 +369,7 @@ TQString const KNumber::toQString(int width, int prec) const if (_float_output) { bool tmp_bool = _fraction_input; // stupid work-around _fraction_input = false; - tmp_str = (KNumber("1.0")*(*this)).toQString(width, -1); + tmp_str = (KNumber("1.0")*(*this)).toTQString(width, -1); _fraction_input = tmp_bool; } else { // _float_output == false if(_splitoffinteger_output) { @@ -378,9 +378,9 @@ TQString const KNumber::toQString(int width, int prec) const if (int_part == Zero) tmp_str = TQString(_num->ascii()); else if (int_part < Zero) - tmp_str = int_part.toQString() + " " + (int_part - *this)._num->ascii(); + tmp_str = int_part.toTQString() + " " + (int_part - *this)._num->ascii(); else - tmp_str = int_part.toQString() + " " + (*this - int_part)._num->ascii(); + tmp_str = int_part.toTQString() + " " + (*this - int_part)._num->ascii(); } else tmp_str = TQString(_num->ascii()); @@ -388,7 +388,7 @@ TQString const KNumber::toQString(int width, int prec) const //result needs to be cut-off bool tmp_bool = _fraction_input; // stupid work-around _fraction_input = false; - tmp_str = (KNumber("1.0")*(*this)).toQString(width, -1); + tmp_str = (KNumber("1.0")*(*this)).toTQString(width, -1); _fraction_input = tmp_bool; } } diff --git a/kcalc/knumber/knumber.h b/kcalc/knumber/knumber.h index 02fce32..2ca3b5c 100644 --- a/kcalc/knumber/knumber.h +++ b/kcalc/knumber/knumber.h @@ -36,8 +36,8 @@ class TQString; * KNumber is based on the GMP (GNU Multiprecision) library and * provides transparent support to integer, fractional and floating * point number. It contains rudimentary error handling, and also - * includes methods for converting the numbers to QStrings for - * output, and to read QStrings to obtain a KNumber. + * includes methods for converting the numbers to TQStrings for + * output, and to read TQStrings to obtain a KNumber. * * The different types of numbers that can be represented by objects * of this class will be described below: @@ -130,7 +130,7 @@ class KDE_EXPORT KNumber NumType type(void) const; /** - * Set whether the output of numbers (with KNumber::toQString) + * Set whether the output of numbers (with KNumber::toTQString) * should happen as floating point numbers or not. This method has * in fact only an effect on numbers of type @p * NumType::FractionType, which can be either displayed as fractions @@ -179,7 +179,7 @@ class KDE_EXPORT KNumber * is ignored. * */ - TQString const toQString(int width = -1, int prec = -1) const; + TQString const toTQString(int width = -1, int prec = -1) const; /** * Compute the absolute value, i.e. @p x.abs() returns the value diff --git a/kcalc/knumber/knumber_priv.cpp b/kcalc/knumber/knumber_priv.cpp index 56de7d3..8f69a5d 100644 --- a/kcalc/knumber/knumber_priv.cpp +++ b/kcalc/knumber/knumber_priv.cpp @@ -190,7 +190,7 @@ TQString const _knumerror::ascii(int prec) const case MinusInfinity: return TQString("-inf"); default: - return TQString::null; + return TQString(); } } diff --git a/kcalc/knumber/tests/knumbertest.cpp b/kcalc/knumber/tests/knumbertest.cpp index e34d94d..0d45355 100644 --- a/kcalc/knumber/tests/knumbertest.cpp +++ b/kcalc/knumber/tests/knumbertest.cpp @@ -32,13 +32,13 @@ void checkResult(TQString const &string, KNumber const & result, { std::cout << "Testing result of: " << string.ascii() << " should give " << desired_string.ascii() << " and gives " << - result.toQString(8).ascii() << "....\n"; + result.toTQString(8).ascii() << "....\n"; std::cout << "The type of the result should be " << numtypeToString(desired).ascii() << " and gives " << numtypeToString(result.type()).ascii() << ".... "; if (result.type() == desired && - result.toQString(8) == desired_string) { + result.toTQString(8) == desired_string) { std::cout << "OK\n"; return; } diff --git a/kcalc/stats.cpp b/kcalc/stats.cpp index 45da5c3..57b3d55 100644 --- a/kcalc/stats.cpp +++ b/kcalc/stats.cpp @@ -2,7 +2,7 @@ $Id$ KCalc, a scientific calculator for the X window system using the - Qt widget libraries, available at no cost at http://www.troll.no + TQt widget libraries, available at no cost at http://www.troll.no Copyright (C) 1996 Bernd Johannes Wuebben wuebben@math.cornell.edu diff --git a/kcalc/stats.h b/kcalc/stats.h index aba11f4..e8d1037 100644 --- a/kcalc/stats.h +++ b/kcalc/stats.h @@ -2,7 +2,7 @@ $Id$ KCalc, a scientific calculator for the X window system using the - Qt widget libraries, available at no cost at http://www.troll.no + TQt widget libraries, available at no cost at http://www.troll.no Copyright (C) 1996 Bernd Johannes Wuebben wuebben@math.cornell.edu |