diff options
Diffstat (limited to 'src')
45 files changed, 491 insertions, 491 deletions
diff --git a/src/Makefile.am b/src/Makefile.am index a07cdf2..30f344f 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -32,7 +32,7 @@ qalculate_tde_SOURCES = buttonwithindexsignal.cpp kqalculate.cpp \ qalculateunitsdialog.cpp qalculatevariablesdialog.cpp qalculateresultdisplay.cpp qalculate_tde_LDFLAGS = $(KDE_RPATH) $(all_libraries) -qalculate_tde_LDADD = $(LIB_QT) -lDCOP $(LIB_KDECORE) $(LIB_KDEUI) $(LIB_KIO) +qalculate_tde_LDADD = $(LIB_QT) -lDCOP $(LIB_TDECORE) $(LIB_TDEUI) $(LIB_TDEIO) # this is where the desktop file will go shelldesktopdir = $(xdg_appsdir) diff --git a/src/kqalculate.cpp b/src/kqalculate.cpp index 537db41..f6438f2 100644 --- a/src/kqalculate.cpp +++ b/src/kqalculate.cpp @@ -23,7 +23,7 @@ #endif #include <kdialog.h> -#include <klocale.h> +#include <tdelocale.h> #include "kqalculate.h" #include "qalculateinsertfunctiondialog.h" @@ -52,8 +52,8 @@ #include "qalculatesetbasedialog.h" #include "qalculateinsertmatrixvectordialog.h" -#include <kwin.h> -#include <kglobalsettings.h> +#include <twin.h> +#include <tdeglobalsettings.h> #include <kuniqueapplication.h> #include <kstringhandler.h> #include <tqtable.h> @@ -68,7 +68,7 @@ #include <kcompletion.h> #include <klineedit.h> #include <tqlabel.h> -#include <kmessagebox.h> +#include <tdemessagebox.h> #include <tqpixmap.h> #include <tqpicture.h> #include <tqpainter.h> @@ -88,36 +88,36 @@ #include <tqbitmap.h> #include <tqscrollview.h> #include <tqobject.h> -#include <kapplication.h> -#include <kaction.h> +#include <tdeapplication.h> +#include <tdeaction.h> #include <tqspinbox.h> #include <kprogress.h> -#include <kpopupmenu.h> -#include <kmenubar.h> +#include <tdepopupmenu.h> +#include <tdemenubar.h> #include <tqlayout.h> #include <tqtimer.h> -#include <kcompletionbox.h> +#include <tdecompletionbox.h> #include <tqstringlist.h> #include <tqcombobox.h> #include <ksystemtray.h> -#if KDE_VERSION_MAJOR > 3 || KDE_VERSION_MINOR > 1 -#include <kactionclasses.h> +#if TDE_VERSION_MAJOR > 3 || TDE_VERSION_MINOR > 1 +#include <tdeactionclasses.h> #endif -#if KDE_VERSION_MAJOR > 3 || KDE_VERSION_MINOR >= 4 -#include <kaccelmanager.h> +#if TDE_VERSION_MAJOR > 3 || TDE_VERSION_MINOR >= 4 +#include <tdeaccelmanager.h> #endif #include <tqbuttongroup.h> #include <tqvbuttongroup.h> #include <tqradiobutton.h> #include <tqgrid.h> -#include <kfiledialog.h> +#include <tdefiledialog.h> #include <tqimage.h> -#include <kaccel.h> -#include <kio/netaccess.h> -#if KDE_VERSION_MAJOR > 3 || KDE_VERSION_MINOR >= 2 +#include <tdeaccel.h> +#include <tdeio/netaccess.h> +#if TDE_VERSION_MAJOR > 3 || TDE_VERSION_MINOR >= 2 #include <kinputdialog.h> #endif -#include <kdeversion.h> +#include <tdeversion.h> #include <tqstyle.h> #include <kglobalaccel.h> #include <kkeydialog.h> @@ -187,19 +187,19 @@ const MathStructure *KQalculate::getResultPart(int i) { return &result_parts[(size_t) i - 1]; } -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 #include <kiconloader.h> -#include <kconfig.h> +#include <tdeconfig.h> TQPixmap loadSystrayIcon(const TQString &icon) { - KConfig *appCfg = kapp->config(); - KConfigGroupSaver configSaver(appCfg, "System Tray"); + TDEConfig *appCfg = kapp->config(); + TDEConfigGroupSaver configSaver(appCfg, "System Tray"); int iconWidth = appCfg->readNumEntry("systrayIconWidth", 22); - return KGlobal::instance()->iconLoader()->loadIcon(icon, KIcon::Panel, iconWidth); + return TDEGlobal::instance()->iconLoader()->loadIcon(icon, TDEIcon::Panel, iconWidth); } #endif -#if KDE_VERSION_MAJOR > 3 || KDE_VERSION_MINOR >= 3 -#define ICON_SIZE_SMALL_MEDIUM KIcon::SizeSmallMedium +#if TDE_VERSION_MAJOR > 3 || TDE_VERSION_MINOR >= 3 +#define ICON_SIZE_SMALL_MEDIUM TDEIcon::SizeSmallMedium #else #define ICON_SIZE_SMALL_MEDIUM 22 #endif @@ -209,7 +209,7 @@ void ModeObject::loadMode() { mainWin->loadMode(i_mode); } -KQalculate::KQalculate(KUniqueApplication *parent, const char* name, WFlags fl) : KMainWindow(0, name, fl) { +KQalculate::KQalculate(KUniqueApplication *parent, const char* name, WFlags fl) : TDEMainWindow(0, name, fl) { if(!name) setName("kqalculate"); @@ -261,8 +261,8 @@ KQalculate::KQalculate(KUniqueApplication *parent, const char* name, WFlags fl) history_height = 0; trayicon = NULL; - ActionHideSystemTrayIcon = new KAction(i18n("Remove from System Tray"), "hidesystemtrayicon", 0, this, SLOT(hideSystemTrayIcon()), actionCollection(), "hide_system_tray_icon"); - ActionHide = new KAction(i18n("Hide"), "hide", 0, this, SLOT(hide()), actionCollection(), "hide"); + ActionHideSystemTrayIcon = new TDEAction(i18n("Remove from System Tray"), "hidesystemtrayicon", 0, this, SLOT(hideSystemTrayIcon()), actionCollection(), "hide_system_tray_icon"); + ActionHide = new TDEAction(i18n("Hide"), "hide", 0, this, SLOT(hide()), actionCollection(), "hide"); showSystemTrayIcon(close_to_systray); setCentralWidget(new TQWidget(this)); @@ -275,14 +275,14 @@ KQalculate::KQalculate(KUniqueApplication *parent, const char* name, WFlags fl) if(use_icon_buttons > 0) { use_button_pixmaps = true; } else if(use_icon_buttons < 0) { - KConfig config("kdeglobals", true, false); + TDEConfig config("kdeglobals", true, false); config.setGroup("KDE"); use_button_pixmaps = config.readBoolEntry("ShowIconsOnPushButtons", false); } if(use_button_pixmaps) leftButtonsLayout = new TQVBoxLayout(0, 0, 3); else leftButtonsLayout = new TQVBoxLayout(0, 0, 6); - if(use_button_pixmaps) executeButton = new QalculateButton(KApplication::kApplication()->iconLoader()->loadIconSet("exec", KIcon::Small, ICON_SIZE_SMALL_MEDIUM), "", centralWidget()); + if(use_button_pixmaps) executeButton = new QalculateButton(TDEApplication::kApplication()->iconLoader()->loadIconSet("application-x-executable", TDEIcon::Small, ICON_SIZE_SMALL_MEDIUM), "", centralWidget()); else if(rpn_mode) executeButton = new QalculateButton(i18n("Enter"), centralWidget()); else executeButton = new QalculateButton(i18n("="), centralWidget()); executeButton->setSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Fixed, false); @@ -292,12 +292,12 @@ KQalculate::KQalculate(KUniqueApplication *parent, const char* name, WFlags fl) leftButtonsSeparator = new KSeparator(TQt::Horizontal, centralWidget()); leftButtonsLayout->addWidget(leftButtonsSeparator); if(use_button_pixmaps) leftButtonsSeparator->hide(); - if(use_button_pixmaps) storeButton = new QalculateButton(KApplication::kApplication()->iconLoader()->loadIconSet("filesaveas", KIcon::Small, ICON_SIZE_SMALL_MEDIUM), "", centralWidget()); + if(use_button_pixmaps) storeButton = new QalculateButton(TDEApplication::kApplication()->iconLoader()->loadIconSet("document-save-as", TDEIcon::Small, ICON_SIZE_SMALL_MEDIUM), "", centralWidget()); else storeButton = new QalculateButton(i18n("Store"), centralWidget()); storeButton->setSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Fixed, false); TQToolTip::add(storeButton, i18n("Store result as variable")); leftButtonsLayout->addWidget(storeButton); - if(use_button_pixmaps) convertButton = new QalculateButton(KApplication::kApplication()->iconLoader()->loadIconSet("qalculate_convert", KIcon::Small, ICON_SIZE_SMALL_MEDIUM), "", centralWidget()); + if(use_button_pixmaps) convertButton = new QalculateButton(TDEApplication::kApplication()->iconLoader()->loadIconSet("qalculate_convert", TDEIcon::Small, ICON_SIZE_SMALL_MEDIUM), "", centralWidget()); else convertButton = new QalculateButton(i18n("Convert"), centralWidget()); convertButton->setSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Fixed, false); TQToolTip::add(convertButton, i18n("Convert units in result")); @@ -451,11 +451,11 @@ KQalculate::KQalculate(KUniqueApplication *parent, const char* name, WFlags fl) keypadAngleLayout->addItem(new TQSpacerItem(1, 1, TQSizePolicy::Expanding, TQSizePolicy::Minimum)); keypadFunctionsLayout->addMultiCellLayout(keypadAngleLayout, 4, 4, 0, 2); -#if KDE_VERSION_MAJOR > 3 || KDE_VERSION_MINOR >= 4 - KAcceleratorManager::setNoAccel(kpDegreesButton); - KAcceleratorManager::setNoAccel(kpRadiansButton); - KAcceleratorManager::setNoAccel(kpGradiansButton); - KAcceleratorManager::setNoAccel(kpNoAngleUnitButton); +#if TDE_VERSION_MAJOR > 3 || TDE_VERSION_MINOR >= 4 + TDEAcceleratorManager::setNoAccel(kpDegreesButton); + TDEAcceleratorManager::setNoAccel(kpRadiansButton); + TDEAcceleratorManager::setNoAccel(kpGradiansButton); + TDEAcceleratorManager::setNoAccel(kpNoAngleUnitButton); #endif keypadBottomLayout->addLayout(keypadFunctionsLayout); @@ -551,27 +551,27 @@ KQalculate::KQalculate(KUniqueApplication *parent, const char* name, WFlags fl) stackPageLayout->addWidget(stackList); if(use_button_pixmaps) stackPageButtonsLayout = new TQVBoxLayout(stackPageLayout, 3); else stackPageButtonsLayout = new TQVBoxLayout(stackPageLayout, 6); - if(use_button_pixmaps) registerUpButton = new QalculateButton(KApplication::kApplication()->iconLoader()->loadIconSet("up", KIcon::Small, ICON_SIZE_SMALL_MEDIUM), "", stackPage); + if(use_button_pixmaps) registerUpButton = new QalculateButton(TDEApplication::kApplication()->iconLoader()->loadIconSet("go-up", TDEIcon::Small, ICON_SIZE_SMALL_MEDIUM), "", stackPage); else registerUpButton = new QalculateButton(i18n("Up"), stackPage); TQToolTip::add(registerUpButton, i18n("Move selected register up")); registerUpButton->setSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Fixed, false); stackPageButtonsLayout->addWidget(registerUpButton); - if(use_button_pixmaps) registerDownButton = new QalculateButton(KApplication::kApplication()->iconLoader()->loadIconSet("down", KIcon::Small, ICON_SIZE_SMALL_MEDIUM), "", stackPage); + if(use_button_pixmaps) registerDownButton = new QalculateButton(TDEApplication::kApplication()->iconLoader()->loadIconSet("go-down", TDEIcon::Small, ICON_SIZE_SMALL_MEDIUM), "", stackPage); else registerDownButton = new QalculateButton(i18n("Down"), stackPage); TQToolTip::add(registerDownButton, i18n("Move selected register down")); registerDownButton->setSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Fixed, false); stackPageButtonsLayout->addWidget(registerDownButton); - if(use_button_pixmaps) editRegisterButton = new QalculateButton(KApplication::kApplication()->iconLoader()->loadIconSet("edit", KIcon::Small, ICON_SIZE_SMALL_MEDIUM), "", stackPage); + if(use_button_pixmaps) editRegisterButton = new QalculateButton(TDEApplication::kApplication()->iconLoader()->loadIconSet("edit", TDEIcon::Small, ICON_SIZE_SMALL_MEDIUM), "", stackPage); else editRegisterButton = new QalculateButton(i18n("Edit"), stackPage); TQToolTip::add(editRegisterButton, i18n("Edit value of selected register")); editRegisterButton->setSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Fixed, false); stackPageButtonsLayout->addWidget(editRegisterButton); - if(use_button_pixmaps) deleteRegisterButton = new QalculateButton(KApplication::kApplication()->iconLoader()->loadIconSet("editdelete", KIcon::Small, ICON_SIZE_SMALL_MEDIUM), "", stackPage); + if(use_button_pixmaps) deleteRegisterButton = new QalculateButton(TDEApplication::kApplication()->iconLoader()->loadIconSet("edit-delete", TDEIcon::Small, ICON_SIZE_SMALL_MEDIUM), "", stackPage); else deleteRegisterButton = new QalculateButton(i18n("Delete"), stackPage); TQToolTip::add(deleteRegisterButton, i18n("Delete selected register")); deleteRegisterButton->setSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Fixed, false); stackPageButtonsLayout->addWidget(deleteRegisterButton); - if(use_button_pixmaps) clearStackButton = new QalculateButton(KApplication::kApplication()->iconLoader()->loadIconSet("view_remove", KIcon::Small, ICON_SIZE_SMALL_MEDIUM), "", stackPage); + if(use_button_pixmaps) clearStackButton = new QalculateButton(TDEApplication::kApplication()->iconLoader()->loadIconSet("view_remove", TDEIcon::Small, ICON_SIZE_SMALL_MEDIUM), "", stackPage); else clearStackButton = new QalculateButton(i18n("Clear"), stackPage); TQToolTip::add(clearStackButton, i18n("Clear the RPN stack")); clearStackButton->setSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Fixed, false); @@ -608,7 +608,7 @@ KQalculate::KQalculate(KUniqueApplication *parent, const char* name, WFlags fl) connect(stackList, SIGNAL(selectionChanged()), this, SLOT(registerSelected())); connect(stackList, SIGNAL(itemRenamed(TQListViewItem*)), this, SLOT(stackRegisterSet(TQListViewItem*))); connect(stackList, SIGNAL(moved()), this, SLOT(stackRegisterMoved())); - connect(stackList, SIGNAL(contextMenu(KListView*, TQListViewItem*, const TQPoint&)), this, SLOT(popupStackMenu(KListView*, TQListViewItem*, const TQPoint&))); + connect(stackList, SIGNAL(contextMenu(TDEListView*, TQListViewItem*, const TQPoint&)), this, SLOT(popupStackMenu(TDEListView*, TQListViewItem*, const TQPoint&))); connect(registerUpButton, SIGNAL(clicked()), this, SLOT(registerUp())); connect(registerDownButton, SIGNAL(clicked()), this, SLOT(registerDown())); connect(editRegisterButton, SIGNAL(clicked()), this, SLOT(editRegister())); @@ -946,7 +946,7 @@ void KQalculate::fontChange(const TQFont &old_font) { kpSquare->setMarkup(i18n("x<sup>2</sup>")); kpRaise->setMarkup(i18n("x<sup>y</sup>")); result_display_updated(); - KMainWindow::fontChange(old_font); + TDEMainWindow::fontChange(old_font); updateButtonWidths(); } @@ -954,13 +954,13 @@ void KQalculate::showSystemTrayIcon(bool do_show) { if(do_show && !trayicon) { trayicon = new KSystemTray(this); TQObject::connect(trayicon, SIGNAL(quitSelected()), tqApp, SLOT(quit())); -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 trayicon->setPixmap(loadSystrayIcon(PACKAGE)); #else trayicon->setPixmap(trayicon->loadIcon(PACKAGE)); #endif -#if KDE_VERSION_MAJOR > 3 || KDE_VERSION_MINOR >= 2 - KPopupMenu* traypop = trayicon->contextMenu(); +#if TDE_VERSION_MAJOR > 3 || TDE_VERSION_MINOR >= 2 + TDEPopupMenu* traypop = trayicon->contextMenu(); ActionHideSystemTrayIcon->plug(traypop, 1); #endif TQToolTip::add(trayicon, i18n("Qalculate! - Scientific Calculator")); @@ -982,194 +982,194 @@ void KQalculate::hideSystemTrayIcon() { void KQalculate::setupActions() { - ActionNewVariable = new KAction(i18n("Variable"), "filenew", 0, this, SLOT(newVariable()), actionCollection(), "new_variable"); - ActionNewMatrix = new KAction(i18n("Matrix"), "filenew", 0, this, SLOT(newMatrix()), actionCollection(), "new_matrix"); - ActionNewVector = new KAction(i18n("Vector"), "filenew", 0, this, SLOT(newVector()), actionCollection(), "new_vector"); - ActionNewUnknownVariable = new KAction(i18n("Unknown Variable"), "filenew", 0, this, SLOT(newUnknownVariable()), actionCollection(), "new_unknown_variable"); - ActionNewFunction = new KAction(i18n("Function"), "filenew", 0, this, SLOT(newFunction()), actionCollection(), "new_function"); - ActionNewDataSet = new KAction(i18n("Data Set"), "filenew", 0, this, SLOT(newDataSet()), actionCollection(), "new_data_set"); - ActionNewUnit = new KAction(i18n("Unit"), "filenew", 0, this, SLOT(newUnit()), actionCollection(), "new_unit"); - ActionImportCSVFile = new KAction(i18n("Import CSV File..."), "fileimport", 0, this, SLOT(importCSVFile()), actionCollection(), "import_csv_file"); - ActionExportCSVFile = new KAction(i18n("Export CSV File..."), "filexport", 0, this, SLOT(exportCSVFile()), actionCollection(), "export_csv_file"); - ActionStoreResult = new KAction(i18n("Store Result..."), "filesave", CTRL+Key_S, this, SLOT(storeResult()), actionCollection(), "store_result"); - ActionSaveAsImage = new KAction(i18n("Save Result Image..."), "filesave", 0, this, SLOT(saveAsImage()), actionCollection(), "save_as_image"); - ActionSaveDefinitions = new KAction(i18n("Save Definitions"), "filesave", 0, this, SLOT(saveDefinitions()), actionCollection(), "save_definitions"); - ActionUpdateExchangeRates = new KAction(i18n("Update Exchange Rates"), "reload", 0, this, SLOT(updateExchangeRates()), actionCollection(), "update_exchange_rates"); - ActionPlotFunctionsData = new KAction(i18n("Plot Functions/Data"), 0, this, SLOT(plotFunctionsData()), actionCollection(), "plot_functions_data"); + ActionNewVariable = new TDEAction(i18n("Variable"), "filenew", 0, this, SLOT(newVariable()), actionCollection(), "new_variable"); + ActionNewMatrix = new TDEAction(i18n("Matrix"), "filenew", 0, this, SLOT(newMatrix()), actionCollection(), "new_matrix"); + ActionNewVector = new TDEAction(i18n("Vector"), "filenew", 0, this, SLOT(newVector()), actionCollection(), "new_vector"); + ActionNewUnknownVariable = new TDEAction(i18n("Unknown Variable"), "filenew", 0, this, SLOT(newUnknownVariable()), actionCollection(), "new_unknown_variable"); + ActionNewFunction = new TDEAction(i18n("Function"), "filenew", 0, this, SLOT(newFunction()), actionCollection(), "new_function"); + ActionNewDataSet = new TDEAction(i18n("Data Set"), "filenew", 0, this, SLOT(newDataSet()), actionCollection(), "new_data_set"); + ActionNewUnit = new TDEAction(i18n("Unit"), "filenew", 0, this, SLOT(newUnit()), actionCollection(), "new_unit"); + ActionImportCSVFile = new TDEAction(i18n("Import CSV File..."), "fileimport", 0, this, SLOT(importCSVFile()), actionCollection(), "import_csv_file"); + ActionExportCSVFile = new TDEAction(i18n("Export CSV File..."), "filexport", 0, this, SLOT(exportCSVFile()), actionCollection(), "export_csv_file"); + ActionStoreResult = new TDEAction(i18n("Store Result..."), "filesave", CTRL+Key_S, this, SLOT(storeResult()), actionCollection(), "store_result"); + ActionSaveAsImage = new TDEAction(i18n("Save Result Image..."), "filesave", 0, this, SLOT(saveAsImage()), actionCollection(), "save_as_image"); + ActionSaveDefinitions = new TDEAction(i18n("Save Definitions"), "filesave", 0, this, SLOT(saveDefinitions()), actionCollection(), "save_definitions"); + ActionUpdateExchangeRates = new TDEAction(i18n("Update Exchange Rates"), "reload", 0, this, SLOT(updateExchangeRates()), actionCollection(), "update_exchange_rates"); + ActionPlotFunctionsData = new TDEAction(i18n("Plot Functions/Data"), 0, this, SLOT(plotFunctionsData()), actionCollection(), "plot_functions_data"); ActionPlotFunctionsData->setEnabled(canplot); - ActionConvertNumberBases = new KAction(i18n("Convert Number Bases"), 0, this, SLOT(convertNumberBases()), actionCollection(), "convert_number_bases"); - ActionPeriodicTable = new KAction(i18n("Periodic Table"), 0, this, SLOT(periodicTable()), actionCollection(), "periodic_table"); + ActionConvertNumberBases = new TDEAction(i18n("Convert Number Bases"), 0, this, SLOT(convertNumberBases()), actionCollection(), "convert_number_bases"); + ActionPeriodicTable = new TDEAction(i18n("Periodic Table"), 0, this, SLOT(periodicTable()), actionCollection(), "periodic_table"); if(close_to_systray) { ActionClose = KStdAction::close(this, SLOT(close()), actionCollection()); } else { ActionClose = NULL; } - globalAccel = new KGlobalAccel(this); - globalAccel->insert("Show/hide Qalculate!", i18n("Show/hide main Qalculate! window"), TQString::null, KShortcut(), KShortcut(), this, SLOT(showHide())); + globalAccel = new TDEGlobalAccel(this); + globalAccel->insert("Show/hide Qalculate!", i18n("Show/hide main Qalculate! window"), TQString::null, TDEShortcut(), TDEShortcut(), this, SLOT(showHide())); globalAccel->readSettings(); globalAccel->updateConnections(); - ActionConfigureGlobalShortcuts = new KAction(i18n("Configure &Global Shortcuts..."), "configure_shortcuts", 0, this, SLOT(configureGlobalShortcuts()), actionCollection(), "configure_global_shortcuts"); + ActionConfigureGlobalShortcuts = new TDEAction(i18n("Configure &Global Shortcuts..."), "configure_shortcuts", 0, this, SLOT(configureGlobalShortcuts()), actionCollection(), "configure_global_shortcuts"); ActionQuit = KStdAction::quit(tqApp, SLOT(quit()), actionCollection()); - ActionManageVariables = new KAction(i18n("Manage Variables"), Key_F2, this, SLOT(manageVariables()), actionCollection(), "manage_variables"); - ActionManageFunctions = new KAction(i18n("Manage Functions"), Key_F3, this, SLOT(manageFunctions()), actionCollection(), "manage_functions"); - ActionManageUnits = new KAction(i18n("Manage Units"), Key_F4, this, SLOT(manageUnits()), actionCollection(), "manage_units"); - ActionManageDataSets = new KAction(i18n("Manage Data Sets"), 0, this, SLOT(manageDataSets()), actionCollection(), "manage_data_sets"); - ActionFactorize = new KAction(i18n("Factorize"), 0, this, SLOT(factorize()), actionCollection(), "factorize"); - ActionSimplify = new KAction(i18n("Simplify"), 0, this, SLOT(simplify()), actionCollection(), "simplify"); - ActionSetUnknowns = new KAction(i18n("Set Unknowns..."), 0, this, SLOT(setUnknowns()), actionCollection(), "set_unknowns"); - ActionConvertToUnitExpression = new KAction(i18n("Convert to Unit Expression..."), CTRL+Key_T, this, SLOT(convertToUnitExpression()), actionCollection(), "convert_to_unit_expression"); - ActionConvertToBaseUnits = new KAction(i18n("Convert to Base Units"), 0, this, SLOT(convertToBaseUnits()), actionCollection(), "convert_to_base_units"); - ActionConvertToBestUnit = new KAction(i18n("Convert to Best Unit"), 0, this, SLOT(convertToBestUnit()), actionCollection(), "convert_to_best_unit"); - ActionInsertMatrix = new KAction(i18n("Insert Matrix..."), 0, this, SLOT(insertMatrix()), actionCollection(), "insert_matrix"); - ActionInsertVector = new KAction(i18n("Insert Vector..."), 0, this, SLOT(insertVector()), actionCollection(), "insert_vector"); - ActionCopyResult = new KAction(i18n("Copy Result"), "editcopy", Key_F5, this, SLOT(copyResult()), actionCollection(), "copy_result"); - ActionClearHistory = new KAction(i18n("Clear History"), "editclear", 0, this, SLOT(clearHistory()), actionCollection(), "clear_history"); - ActionPreferences = new KAction(i18n("Configure Qalculate!"), "configure", 0, this, SLOT(preferences()), actionCollection(), "preferences"); + ActionManageVariables = new TDEAction(i18n("Manage Variables"), Key_F2, this, SLOT(manageVariables()), actionCollection(), "manage_variables"); + ActionManageFunctions = new TDEAction(i18n("Manage Functions"), Key_F3, this, SLOT(manageFunctions()), actionCollection(), "manage_functions"); + ActionManageUnits = new TDEAction(i18n("Manage Units"), Key_F4, this, SLOT(manageUnits()), actionCollection(), "manage_units"); + ActionManageDataSets = new TDEAction(i18n("Manage Data Sets"), 0, this, SLOT(manageDataSets()), actionCollection(), "manage_data_sets"); + ActionFactorize = new TDEAction(i18n("Factorize"), 0, this, SLOT(factorize()), actionCollection(), "factorize"); + ActionSimplify = new TDEAction(i18n("Simplify"), 0, this, SLOT(simplify()), actionCollection(), "simplify"); + ActionSetUnknowns = new TDEAction(i18n("Set Unknowns..."), 0, this, SLOT(setUnknowns()), actionCollection(), "set_unknowns"); + ActionConvertToUnitExpression = new TDEAction(i18n("Convert to Unit Expression..."), CTRL+Key_T, this, SLOT(convertToUnitExpression()), actionCollection(), "convert_to_unit_expression"); + ActionConvertToBaseUnits = new TDEAction(i18n("Convert to Base Units"), 0, this, SLOT(convertToBaseUnits()), actionCollection(), "convert_to_base_units"); + ActionConvertToBestUnit = new TDEAction(i18n("Convert to Best Unit"), 0, this, SLOT(convertToBestUnit()), actionCollection(), "convert_to_best_unit"); + ActionInsertMatrix = new TDEAction(i18n("Insert Matrix..."), 0, this, SLOT(insertMatrix()), actionCollection(), "insert_matrix"); + ActionInsertVector = new TDEAction(i18n("Insert Vector..."), 0, this, SLOT(insertVector()), actionCollection(), "insert_vector"); + ActionCopyResult = new TDEAction(i18n("Copy Result"), "editcopy", Key_F5, this, SLOT(copyResult()), actionCollection(), "copy_result"); + ActionClearHistory = new TDEAction(i18n("Clear History"), "editclear", 0, this, SLOT(clearHistory()), actionCollection(), "clear_history"); + ActionPreferences = new TDEAction(i18n("Configure Qalculate!"), "configure", 0, this, SLOT(preferences()), actionCollection(), "preferences"); KStdAction::keyBindings(guiFactory(), SLOT(configureShortcuts()), actionCollection(), "keybindings"); - ActionNumberBaseBinary = new KRadioAction(i18n("Binary"), 0, this, SLOT(numberBaseBinary()), actionCollection(), "number_base_binary"); + ActionNumberBaseBinary = new TDERadioAction(i18n("Binary"), 0, this, SLOT(numberBaseBinary()), actionCollection(), "number_base_binary"); ActionNumberBaseBinary->setExclusiveGroup("group_number_base"); - ActionNumberBaseOctal = new KRadioAction(i18n("Octal"), 0, this, SLOT(numberBaseOctal()), actionCollection(), "number_base_octal"); + ActionNumberBaseOctal = new TDERadioAction(i18n("Octal"), 0, this, SLOT(numberBaseOctal()), actionCollection(), "number_base_octal"); ActionNumberBaseOctal->setExclusiveGroup("group_number_base"); - ActionNumberBaseDecimal = new KRadioAction(i18n("Decimal"), 0, this, SLOT(numberBaseDecimal()), actionCollection(), "number_base_decimal"); + ActionNumberBaseDecimal = new TDERadioAction(i18n("Decimal"), 0, this, SLOT(numberBaseDecimal()), actionCollection(), "number_base_decimal"); ActionNumberBaseDecimal->setExclusiveGroup("group_number_base"); - ActionNumberBaseHexadecimal = new KRadioAction(i18n("Hexadecimal"), 0, this, SLOT(numberBaseHexadecimal()), actionCollection(), "number_base_hexadecimal"); + ActionNumberBaseHexadecimal = new TDERadioAction(i18n("Hexadecimal"), 0, this, SLOT(numberBaseHexadecimal()), actionCollection(), "number_base_hexadecimal"); ActionNumberBaseHexadecimal->setExclusiveGroup("group_number_base"); - ActionNumberBaseOther = new KRadioAction(i18n("Other..."), 0, this, SLOT(numberBaseOther()), actionCollection(), "number_base_other"); + ActionNumberBaseOther = new TDERadioAction(i18n("Other..."), 0, this, SLOT(numberBaseOther()), actionCollection(), "number_base_other"); ActionNumberBaseOther->setExclusiveGroup("group_number_base"); - ActionNumberBaseSexagesimal = new KRadioAction(i18n("Sexagesimal"), 0, this, SLOT(numberBaseSexagesimal()), actionCollection(), "number_base_sexagesimal"); + ActionNumberBaseSexagesimal = new TDERadioAction(i18n("Sexagesimal"), 0, this, SLOT(numberBaseSexagesimal()), actionCollection(), "number_base_sexagesimal"); ActionNumberBaseSexagesimal->setExclusiveGroup("group_number_base"); - ActionNumberBaseTimeFormat = new KRadioAction(i18n("Time Format"), 0, this, SLOT(numberBaseTimeFormat()), actionCollection(), "number_base_time_format"); + ActionNumberBaseTimeFormat = new TDERadioAction(i18n("Time Format"), 0, this, SLOT(numberBaseTimeFormat()), actionCollection(), "number_base_time_format"); ActionNumberBaseTimeFormat->setExclusiveGroup("group_number_base"); - ActionNumberBaseRomanNumerals = new KRadioAction(i18n("Roman Numerals"), 0, this, SLOT(numberBaseRomanNumerals()), actionCollection(), "number_base_roman_numerals"); + ActionNumberBaseRomanNumerals = new TDERadioAction(i18n("Roman Numerals"), 0, this, SLOT(numberBaseRomanNumerals()), actionCollection(), "number_base_roman_numerals"); ActionNumberBaseRomanNumerals->setExclusiveGroup("group_number_base"); - ActionSetBase = new KAction(i18n("Select Result and Expression Base..."), CTRL+Key_B, this, SLOT(setBase()), actionCollection(), "set_base"); - ActionNumericalDisplayNormal = new KRadioAction(i18n("Normal"), 0, this, SLOT(numericalDisplayNormal()), actionCollection(), "numerical_display_normal"); + ActionSetBase = new TDEAction(i18n("Select Result and Expression Base..."), CTRL+Key_B, this, SLOT(setBase()), actionCollection(), "set_base"); + ActionNumericalDisplayNormal = new TDERadioAction(i18n("Normal"), 0, this, SLOT(numericalDisplayNormal()), actionCollection(), "numerical_display_normal"); ActionNumericalDisplayNormal->setExclusiveGroup("group_numberical_display"); - ActionNumericalDisplayEngineering = new KRadioAction(i18n("Engineering"), 0, this, SLOT(numericalDisplayEngineering()), actionCollection(), "numerical_display_engineering"); + ActionNumericalDisplayEngineering = new TDERadioAction(i18n("Engineering"), 0, this, SLOT(numericalDisplayEngineering()), actionCollection(), "numerical_display_engineering"); ActionNumericalDisplayEngineering->setExclusiveGroup("group_numberical_display"); - ActionNumericalDisplayScientific = new KRadioAction(i18n("Scientific"), 0, this, SLOT(numericalDisplayScientific()), actionCollection(), "numerical_display_scientific"); + ActionNumericalDisplayScientific = new TDERadioAction(i18n("Scientific"), 0, this, SLOT(numericalDisplayScientific()), actionCollection(), "numerical_display_scientific"); ActionNumericalDisplayScientific->setExclusiveGroup("group_numberical_display"); - ActionNumericalDisplayPurelyScientific = new KRadioAction(i18n("Purely Scientific"), 0, this, SLOT(numericalDisplayPurelyScientific()), actionCollection(), "numerical_display_purely_scientific"); + ActionNumericalDisplayPurelyScientific = new TDERadioAction(i18n("Purely Scientific"), 0, this, SLOT(numericalDisplayPurelyScientific()), actionCollection(), "numerical_display_purely_scientific"); ActionNumericalDisplayPurelyScientific->setExclusiveGroup("group_numberical_display"); - ActionNumericalDisplaySimple = new KRadioAction(i18n("Simple"), 0, this, SLOT(numericalDisplaySimple()), actionCollection(), "numerical_display_simple"); + ActionNumericalDisplaySimple = new TDERadioAction(i18n("Simple"), 0, this, SLOT(numericalDisplaySimple()), actionCollection(), "numerical_display_simple"); ActionNumericalDisplaySimple->setExclusiveGroup("group_numberical_display"); - ActionIndicateInfiniteSeries = new KToggleAction(i18n("Indicate Infinite Series"), 0, actionCollection(), "indicate_infinite_series"); + ActionIndicateInfiniteSeries = new TDEToggleAction(i18n("Indicate Infinite Series"), 0, actionCollection(), "indicate_infinite_series"); TQObject::connect(ActionIndicateInfiniteSeries, SIGNAL(toggled(bool)), this, SLOT(indicateInfiniteSeries(bool))); - ActionSortMinusLast = new KToggleAction(i18n("Sort Minus Last"), 0, actionCollection(), "sort_minus_last"); + ActionSortMinusLast = new TDEToggleAction(i18n("Sort Minus Last"), 0, actionCollection(), "sort_minus_last"); TQObject::connect(ActionSortMinusLast, SIGNAL(toggled(bool)), this, SLOT(sortMinusLast(bool))); - ActionNegativeExponents = new KToggleAction(i18n("Negative Exponents"), 0, actionCollection(), "negative_exponents"); + ActionNegativeExponents = new TDEToggleAction(i18n("Negative Exponents"), 0, actionCollection(), "negative_exponents"); TQObject::connect(ActionNegativeExponents, SIGNAL(toggled(bool)), this, SLOT(negativeExponents(bool))); - ActionShowEndingZeroes = new KToggleAction(i18n("Show Ending Zeroes"), 0, actionCollection(), "show_ending_zeroes"); + ActionShowEndingZeroes = new TDEToggleAction(i18n("Show Ending Zeroes"), 0, actionCollection(), "show_ending_zeroes"); TQObject::connect(ActionShowEndingZeroes, SIGNAL(toggled(bool)), this, SLOT(showEndingZeroes(bool))); - ActionRoundHalfwayNumbersToEven = new KToggleAction(i18n("Round Halfway Numbers to Even"), 0, actionCollection(), "round_halfway_numbers_to_even"); + ActionRoundHalfwayNumbersToEven = new TDEToggleAction(i18n("Round Halfway Numbers to Even"), 0, actionCollection(), "round_halfway_numbers_to_even"); TQObject::connect(ActionRoundHalfwayNumbersToEven, SIGNAL(toggled(bool)), this, SLOT(roundHalfwayNumbersToEven(bool))); - ActionFractionalDisplayDecimal = new KRadioAction(i18n("Decimal"), 0, this, SLOT(fractionalDisplayDecimal()), actionCollection(), "fractional_display_decimal"); + ActionFractionalDisplayDecimal = new TDERadioAction(i18n("Decimal"), 0, this, SLOT(fractionalDisplayDecimal()), actionCollection(), "fractional_display_decimal"); ActionFractionalDisplayDecimal->setExclusiveGroup("group_fractional_display"); - ActionFractionalDisplayDecimalTryExact = new KRadioAction(i18n("Decimal (Try Exact)"), 0, this, SLOT(fractionalDisplayDecimalTryExact()), actionCollection(), "fractional_display_decimal_try_exact"); + ActionFractionalDisplayDecimalTryExact = new TDERadioAction(i18n("Decimal (Try Exact)"), 0, this, SLOT(fractionalDisplayDecimalTryExact()), actionCollection(), "fractional_display_decimal_try_exact"); ActionFractionalDisplayDecimalTryExact->setExclusiveGroup("group_fractional_display"); - ActionFractionalDisplayFraction = new KRadioAction(i18n("Fraction"), 0, this, SLOT(fractionalDisplayFraction()), actionCollection(), "fractional_display_fraction"); + ActionFractionalDisplayFraction = new TDERadioAction(i18n("Fraction"), 0, this, SLOT(fractionalDisplayFraction()), actionCollection(), "fractional_display_fraction"); ActionFractionalDisplayFraction->setExclusiveGroup("group_fractional_display"); - ActionFractionalDisplayCombined = new KRadioAction(i18n("Combined"), 0, this, SLOT(fractionalDisplayCombined()), actionCollection(), "fractional_display_combined"); + ActionFractionalDisplayCombined = new TDERadioAction(i18n("Combined"), 0, this, SLOT(fractionalDisplayCombined()), actionCollection(), "fractional_display_combined"); ActionFractionalDisplayCombined->setExclusiveGroup("group_fractional_display"); - ActionEnablePrefixes = new KToggleAction(i18n("Enable Prefixes"), 0, actionCollection(), "enable_prefixes"); + ActionEnablePrefixes = new TDEToggleAction(i18n("Enable Prefixes"), 0, actionCollection(), "enable_prefixes"); TQObject::connect(ActionEnablePrefixes, SIGNAL(toggled(bool)), this, SLOT(enablePrefixes(bool))); - ActionEnableUseOfAllPrefixes = new KToggleAction(i18n("Enable Use of All SI Prefixes"), 0, actionCollection(), "enable_use_of_all_prefixes"); + ActionEnableUseOfAllPrefixes = new TDEToggleAction(i18n("Enable Use of All SI Prefixes"), 0, actionCollection(), "enable_use_of_all_prefixes"); TQObject::connect(ActionEnableUseOfAllPrefixes, SIGNAL(toggled(bool)), this, SLOT(enableUseOfAllPrefixes(bool))); - ActionEnableDenominatorPrefixes = new KToggleAction(i18n("Enable Denominator Prefixes"), 0, actionCollection(), "enable_denominator_prefixes"); + ActionEnableDenominatorPrefixes = new TDEToggleAction(i18n("Enable Denominator Prefixes"), 0, actionCollection(), "enable_denominator_prefixes"); TQObject::connect(ActionEnableDenominatorPrefixes, SIGNAL(toggled(bool)), this, SLOT(enableDenominatorPrefixes(bool))); - ActionPlaceUnitsSeparately = new KToggleAction(i18n("Place Units Separately"), 0, actionCollection(), "place_units_separately"); + ActionPlaceUnitsSeparately = new TDEToggleAction(i18n("Place Units Separately"), 0, actionCollection(), "place_units_separately"); TQObject::connect(ActionPlaceUnitsSeparately, SIGNAL(toggled(bool)), this, SLOT(placeUnitsSeparately(bool))); - ActionAutoNoConversion = new KRadioAction(i18n("No Automatic Conversion"), 0, this, SLOT(autoNoConversion()), actionCollection(), "auto_no_conversion"); + ActionAutoNoConversion = new TDERadioAction(i18n("No Automatic Conversion"), 0, this, SLOT(autoNoConversion()), actionCollection(), "auto_no_conversion"); ActionAutoNoConversion->setExclusiveGroup("group_auto_conversion"); - ActionAutoConvertToBaseUnits = new KRadioAction(i18n("Convert to Base Units"), 0, this, SLOT(autoConvertToBaseUnits()), actionCollection(), "auto_convert_to_base_units"); + ActionAutoConvertToBaseUnits = new TDERadioAction(i18n("Convert to Base Units"), 0, this, SLOT(autoConvertToBaseUnits()), actionCollection(), "auto_convert_to_base_units"); ActionAutoConvertToBaseUnits->setExclusiveGroup("group_auto_conversion"); - ActionAutoConvertToBestUnit = new KRadioAction(i18n("Convert to Best Unit"), 0, this, SLOT(autoConvertToBestUnit()), actionCollection(), "auto_convert_to_best_unit"); + ActionAutoConvertToBestUnit = new TDERadioAction(i18n("Convert to Best Unit"), 0, this, SLOT(autoConvertToBestUnit()), actionCollection(), "auto_convert_to_best_unit"); ActionAutoConvertToBestUnit->setExclusiveGroup("group_auto_conversion"); - ActionAngleUnitDegrees = new KRadioAction(i18n("Degrees"), 0, this, SLOT(angleUnitDegrees()), actionCollection(), "angle_unit_degrees"); + ActionAngleUnitDegrees = new TDERadioAction(i18n("Degrees"), 0, this, SLOT(angleUnitDegrees()), actionCollection(), "angle_unit_degrees"); ActionAngleUnitDegrees->setExclusiveGroup("group_angle_unit"); - ActionAngleUnitRadians = new KRadioAction(i18n("Radians"), 0, this, SLOT(angleUnitRadians()), actionCollection(), "angle_unit_radians"); + ActionAngleUnitRadians = new TDERadioAction(i18n("Radians"), 0, this, SLOT(angleUnitRadians()), actionCollection(), "angle_unit_radians"); ActionAngleUnitRadians->setExclusiveGroup("group_angle_unit"); - ActionAngleUnitGradians = new KRadioAction(i18n("Gradians"), 0, this, SLOT(angleUnitGradians()), actionCollection(), "angle_unit_gradians"); + ActionAngleUnitGradians = new TDERadioAction(i18n("Gradians"), 0, this, SLOT(angleUnitGradians()), actionCollection(), "angle_unit_gradians"); ActionAngleUnitGradians->setExclusiveGroup("group_angle_unit"); - ActionAngleUnitNone = new KRadioAction(i18n("None"), 0, this, SLOT(angleUnitNone()), actionCollection(), "angle_unit_none"); + ActionAngleUnitNone = new TDERadioAction(i18n("None"), 0, this, SLOT(angleUnitNone()), actionCollection(), "angle_unit_none"); ActionAngleUnitNone->setExclusiveGroup("group_angle_unit"); - ActionAbbreviateNames = new KToggleAction(i18n("Abbreviate Names"), 0, actionCollection(), "abbreviate_names"); + ActionAbbreviateNames = new TDEToggleAction(i18n("Abbreviate Names"), 0, actionCollection(), "abbreviate_names"); TQObject::connect(ActionAbbreviateNames, SIGNAL(toggled(bool)), this, SLOT(abbreviateNames(bool))); - ActionEnableVariables = new KToggleAction(i18n("Enable Variables"), 0, actionCollection(), "enable_variables"); + ActionEnableVariables = new TDEToggleAction(i18n("Enable Variables"), 0, actionCollection(), "enable_variables"); TQObject::connect(ActionEnableVariables, SIGNAL(toggled(bool)), this, SLOT(enableVariables(bool))); - ActionEnableFunctions = new KToggleAction(i18n("Enable Functions"), 0, actionCollection(), "enable_functions"); + ActionEnableFunctions = new TDEToggleAction(i18n("Enable Functions"), 0, actionCollection(), "enable_functions"); TQObject::connect(ActionEnableFunctions, SIGNAL(toggled(bool)), this, SLOT(enableFunctions(bool))); - ActionEnableUnits = new KToggleAction(i18n("Enable Units"), 0, actionCollection(), "enable_units"); + ActionEnableUnits = new TDEToggleAction(i18n("Enable Units"), 0, actionCollection(), "enable_units"); TQObject::connect(ActionEnableUnits, SIGNAL(toggled(bool)), this, SLOT(enableUnits(bool))); - ActionEnableUnknowns = new KToggleAction(i18n("Enable Unknowns"), 0, actionCollection(), "enable_unknowns"); + ActionEnableUnknowns = new TDEToggleAction(i18n("Enable Unknowns"), 0, actionCollection(), "enable_unknowns"); TQObject::connect(ActionEnableUnknowns, SIGNAL(toggled(bool)), this, SLOT(enableUnknowns(bool))); - ActionCalculateVariables = new KToggleAction(i18n("Calculate Variables"), 0, actionCollection(), "calculate_variables"); + ActionCalculateVariables = new TDEToggleAction(i18n("Calculate Variables"), 0, actionCollection(), "calculate_variables"); TQObject::connect(ActionCalculateVariables, SIGNAL(toggled(bool)), this, SLOT(calculateVariables(bool))); - ActionAllowComplexResult = new KToggleAction(i18n("Allow Complex Result"), 0, actionCollection(), "allow_complex_result"); + ActionAllowComplexResult = new TDEToggleAction(i18n("Allow Complex Result"), 0, actionCollection(), "allow_complex_result"); TQObject::connect(ActionAllowComplexResult, SIGNAL(toggled(bool)), this, SLOT(allowComplexResult(bool))); - ActionAllowInfiniteResult = new KToggleAction(i18n("Allow Infinite Result"), 0, actionCollection(), "allow_infinite_result"); + ActionAllowInfiniteResult = new TDEToggleAction(i18n("Allow Infinite Result"), 0, actionCollection(), "allow_infinite_result"); TQObject::connect(ActionAllowInfiniteResult, SIGNAL(toggled(bool)), this, SLOT(allowInfiniteResult(bool))); - ActionApproximationTryExact = new KRadioAction(i18n("Try Exact"), 0, this, SLOT(approximationTryExact()), actionCollection(), "approximation_try_exact"); + ActionApproximationTryExact = new TDERadioAction(i18n("Try Exact"), 0, this, SLOT(approximationTryExact()), actionCollection(), "approximation_try_exact"); ActionApproximationTryExact->setExclusiveGroup("group_approximation"); - ActionApproximationAlwaysExact = new KRadioAction(i18n("Always Exact"), 0, this, SLOT(approximationAlwaysExact()), actionCollection(), "approximation_always_exact"); + ActionApproximationAlwaysExact = new TDERadioAction(i18n("Always Exact"), 0, this, SLOT(approximationAlwaysExact()), actionCollection(), "approximation_always_exact"); ActionApproximationAlwaysExact->setExclusiveGroup("group_approximation"); - ActionApproximationApproximate = new KRadioAction(i18n("Approximate"), 0, this, SLOT(approximationApproximate()), actionCollection(), "approximation_approximate"); + ActionApproximationApproximate = new TDERadioAction(i18n("Approximate"), 0, this, SLOT(approximationApproximate()), actionCollection(), "approximation_approximate"); ActionApproximationApproximate->setExclusiveGroup("group_approximation"); - ActionAssumptionTypeUnknown = new KRadioAction(i18n("Unknown"), 0, this, SLOT(assumptionTypeUnknown()), actionCollection(), "assumption_type_unknown"); + ActionAssumptionTypeUnknown = new TDERadioAction(i18n("Unknown"), 0, this, SLOT(assumptionTypeUnknown()), actionCollection(), "assumption_type_unknown"); ActionAssumptionTypeUnknown->setExclusiveGroup("group_assumption_type"); - ActionAssumptionTypeNonMatrix = new KRadioAction(i18n("Not Matrix"), 0, this, SLOT(assumptionTypeNonMatrix()), actionCollection(), "assumption_type_nonmatrix"); + ActionAssumptionTypeNonMatrix = new TDERadioAction(i18n("Not Matrix"), 0, this, SLOT(assumptionTypeNonMatrix()), actionCollection(), "assumption_type_nonmatrix"); ActionAssumptionTypeNonMatrix->setExclusiveGroup("group_assumption_type"); - ActionAssumptionTypeNumber = new KRadioAction(i18n("Number"), 0, this, SLOT(assumptionTypeNumber()), actionCollection(), "assumption_type_number"); + ActionAssumptionTypeNumber = new TDERadioAction(i18n("Number"), 0, this, SLOT(assumptionTypeNumber()), actionCollection(), "assumption_type_number"); ActionAssumptionTypeNumber->setExclusiveGroup("group_assumption_type"); - ActionAssumptionTypeComplex = new KRadioAction(i18n("Complex"), 0, this, SLOT(assumptionTypeComplex()), actionCollection(), "assumption_type_complex"); + ActionAssumptionTypeComplex = new TDERadioAction(i18n("Complex"), 0, this, SLOT(assumptionTypeComplex()), actionCollection(), "assumption_type_complex"); ActionAssumptionTypeComplex->setExclusiveGroup("group_assumption_type"); - ActionAssumptionTypeReal = new KRadioAction(i18n("Real"), 0, this, SLOT(assumptionTypeReal()), actionCollection(), "assumption_type_real"); + ActionAssumptionTypeReal = new TDERadioAction(i18n("Real"), 0, this, SLOT(assumptionTypeReal()), actionCollection(), "assumption_type_real"); ActionAssumptionTypeReal->setExclusiveGroup("group_assumption_type"); - ActionAssumptionTypeRational = new KRadioAction(i18n("Rational"), 0, this, SLOT(assumptionTypeRational()), actionCollection(), "assumption_type_rational"); + ActionAssumptionTypeRational = new TDERadioAction(i18n("Rational"), 0, this, SLOT(assumptionTypeRational()), actionCollection(), "assumption_type_rational"); ActionAssumptionTypeRational->setExclusiveGroup("group_assumption_type"); - ActionAssumptionTypeInteger = new KRadioAction(i18n("Integer"), 0, this, SLOT(assumptionTypeInteger()), actionCollection(), "assumption_type_integer"); + ActionAssumptionTypeInteger = new TDERadioAction(i18n("Integer"), 0, this, SLOT(assumptionTypeInteger()), actionCollection(), "assumption_type_integer"); ActionAssumptionTypeInteger->setExclusiveGroup("group_assumption_type"); - ActionAssumptionSignUnknown = new KRadioAction(i18n("Unknown"), 0, this, SLOT(assumptionSignUnknown()), actionCollection(), "assumption_sign_unknown"); + ActionAssumptionSignUnknown = new TDERadioAction(i18n("Unknown"), 0, this, SLOT(assumptionSignUnknown()), actionCollection(), "assumption_sign_unknown"); ActionAssumptionSignUnknown->setExclusiveGroup("group_assumption_sign"); - ActionAssumptionSignNonZero = new KRadioAction(i18n("Non-Zero"), 0, this, SLOT(assumptionSignNonZero()), actionCollection(), "assumption_sign_non_zero"); + ActionAssumptionSignNonZero = new TDERadioAction(i18n("Non-Zero"), 0, this, SLOT(assumptionSignNonZero()), actionCollection(), "assumption_sign_non_zero"); ActionAssumptionSignNonZero->setExclusiveGroup("group_assumption_sign"); - ActionAssumptionSignPositive = new KRadioAction(i18n("Positive"), 0, this, SLOT(assumptionSignPositive()), actionCollection(), "assumption_sign_positive"); + ActionAssumptionSignPositive = new TDERadioAction(i18n("Positive"), 0, this, SLOT(assumptionSignPositive()), actionCollection(), "assumption_sign_positive"); ActionAssumptionSignPositive->setExclusiveGroup("group_assumption_sign"); - ActionAssumptionSignNonNegative = new KRadioAction(i18n("Non-Negative"), 0, this, SLOT(assumptionSignNonNegative()), actionCollection(), "assumption_sign_non_negative"); + ActionAssumptionSignNonNegative = new TDERadioAction(i18n("Non-Negative"), 0, this, SLOT(assumptionSignNonNegative()), actionCollection(), "assumption_sign_non_negative"); ActionAssumptionSignNonNegative->setExclusiveGroup("group_assumption_sign"); - ActionAssumptionSignNegative = new KRadioAction(i18n("Negative"), 0, this, SLOT(assumptionSignNegative()), actionCollection(), "assumption_sign_negative"); + ActionAssumptionSignNegative = new TDERadioAction(i18n("Negative"), 0, this, SLOT(assumptionSignNegative()), actionCollection(), "assumption_sign_negative"); ActionAssumptionSignNegative->setExclusiveGroup("group_assumption_sign"); - ActionAssumptionSignNonPositive = new KRadioAction(i18n("Non-Positive"), 0, this, SLOT(assumptionSignNonPositive()), actionCollection(), "assumption_sign_non_positive"); + ActionAssumptionSignNonPositive = new TDERadioAction(i18n("Non-Positive"), 0, this, SLOT(assumptionSignNonPositive()), actionCollection(), "assumption_sign_non_positive"); ActionAssumptionSignNonPositive->setExclusiveGroup("group_assumption_sign"); - ActionNonZeroDenominators = new KToggleAction(i18n("Non-Zero Denominators"), 0, actionCollection(), "non_zero_denominators"); + ActionNonZeroDenominators = new TDEToggleAction(i18n("Non-Zero Denominators"), 0, actionCollection(), "non_zero_denominators"); TQObject::connect(ActionNonZeroDenominators, SIGNAL(toggled(bool)), this, SLOT(nonZeroDenominators(bool))); - ActionWarnAboutDenominatorsAssumedNonZero = new KToggleAction(i18n("Warn About Denominators Assumed Non-Zero"), 0, actionCollection(), "warn_about_denominators_assumed_nonzero"); + ActionWarnAboutDenominatorsAssumedNonZero = new TDEToggleAction(i18n("Warn About Denominators Assumed Non-Zero"), 0, actionCollection(), "warn_about_denominators_assumed_nonzero"); TQObject::connect(ActionWarnAboutDenominatorsAssumedNonZero, SIGNAL(toggled(bool)), this, SLOT(warnAboutDenominatorsAssumedNonZero(bool))); - ActionAlgebraicModeSimplify = new KRadioAction(i18n("Simplify"), 0, this, SLOT(algebraicModeSimplify()), actionCollection(), "algebraic_mode_simplify"); + ActionAlgebraicModeSimplify = new TDERadioAction(i18n("Simplify"), 0, this, SLOT(algebraicModeSimplify()), actionCollection(), "algebraic_mode_simplify"); ActionAlgebraicModeSimplify->setExclusiveGroup("group_alebraic_mode"); - ActionAlgebraicModeFactorize = new KRadioAction(i18n("Factorize"), 0, this, SLOT(algebraicModeFactorize()), actionCollection(), "algebraic_mode_factorize"); + ActionAlgebraicModeFactorize = new TDERadioAction(i18n("Factorize"), 0, this, SLOT(algebraicModeFactorize()), actionCollection(), "algebraic_mode_factorize"); ActionAlgebraicModeFactorize->setExclusiveGroup("group_alebraic_mode"); - ActionAlgebraicModeNone = new KRadioAction(i18n("None"), 0, this, SLOT(algebraicModeNone()), actionCollection(), "algebraic_mode_none"); + ActionAlgebraicModeNone = new TDERadioAction(i18n("None"), 0, this, SLOT(algebraicModeNone()), actionCollection(), "algebraic_mode_none"); ActionAlgebraicModeNone->setExclusiveGroup("group_alebraic_mode"); - ActionReadPrecision = new KToggleAction(i18n("Read Precision"), 0, actionCollection(), "read_precision"); + ActionReadPrecision = new TDEToggleAction(i18n("Read Precision"), 0, actionCollection(), "read_precision"); TQObject::connect(ActionReadPrecision, SIGNAL(toggled(bool)), this, SLOT(readPrecision(bool))); - ActionLimitImplicitMultiplication = new KToggleAction(i18n("Limit Implicit Multiplication"), 0, actionCollection(), "limit_implicit_multiplication"); + ActionLimitImplicitMultiplication = new TDEToggleAction(i18n("Limit Implicit Multiplication"), 0, actionCollection(), "limit_implicit_multiplication"); TQObject::connect(ActionLimitImplicitMultiplication, SIGNAL(toggled(bool)), this, SLOT(limitImplicitMultiplication(bool))); - ActionRPNMode = new KToggleAction(i18n("RPN Mode"), CTRL+Key_R, actionCollection(), "rpn_mode"); + ActionRPNMode = new TDEToggleAction(i18n("RPN Mode"), CTRL+Key_R, actionCollection(), "rpn_mode"); TQObject::connect(ActionRPNMode, SIGNAL(toggled(bool)), this, SLOT(rpnMode(bool))); - ActionRPNSyntax = new KToggleAction(i18n("RPN Syntax"), 0, actionCollection(), "rpn_syntax"); + ActionRPNSyntax = new TDEToggleAction(i18n("RPN Syntax"), 0, actionCollection(), "rpn_syntax"); TQObject::connect(ActionRPNSyntax, SIGNAL(toggled(bool)), this, SLOT(rpnSyntax(bool))); - ActionPrecision = new KAction(i18n("Precision"), 0, this, SLOT(precision()), actionCollection(), "precision"); - ActionDecimals = new KAction(i18n("Decimals"), 0, this, SLOT(decimals()), actionCollection(), "decimals"); - ActionSaveModeAs = new KAction(i18n("Save Mode..."), "filesave", 0, this, SLOT(saveModeAs()), actionCollection(), "save_mode_as"); - ActionDeleteMode = new KAction(i18n("Delete Mode..."), "editdelete", 0, this, SLOT(deleteMode()), actionCollection(), "delete_mode"); + ActionPrecision = new TDEAction(i18n("Precision"), 0, this, SLOT(precision()), actionCollection(), "precision"); + ActionDecimals = new TDEAction(i18n("Decimals"), 0, this, SLOT(decimals()), actionCollection(), "decimals"); + ActionSaveModeAs = new TDEAction(i18n("Save Mode..."), "filesave", 0, this, SLOT(saveModeAs()), actionCollection(), "save_mode_as"); + ActionDeleteMode = new TDEAction(i18n("Delete Mode..."), "editdelete", 0, this, SLOT(deleteMode()), actionCollection(), "delete_mode"); ActionDeleteMode->setEnabled(modes.size() > 2); - ActionSaveMode = new KAction(i18n("Save Default Mode"), "filesave", 0, this, SLOT(saveMode()), actionCollection(), "save_mode"); - ActionClearStack = new KAction(i18n("Clear Stack"), "view_remove", 0, this, SLOT(clearStack()), actionCollection(), "clear_stack"); - ActionDeleteRegister = new KAction(i18n("Delete"), "editdelete", 0, this, SLOT(deleteRegister()), actionCollection(), "delete_register"); - ActionEditRegister = new KAction(i18n("Edit"), "edit", 0, this, SLOT(editRegister()), actionCollection(), "edit_register"); + ActionSaveMode = new TDEAction(i18n("Save Default Mode"), "filesave", 0, this, SLOT(saveMode()), actionCollection(), "save_mode"); + ActionClearStack = new TDEAction(i18n("Clear Stack"), "view_remove", 0, this, SLOT(clearStack()), actionCollection(), "clear_stack"); + ActionDeleteRegister = new TDEAction(i18n("Delete"), "editdelete", 0, this, SLOT(deleteRegister()), actionCollection(), "delete_register"); + ActionEditRegister = new TDEAction(i18n("Edit"), "edit", 0, this, SLOT(editRegister()), actionCollection(), "edit_register"); - new KAction(i18n("Exp RPN Operation"), CTRL+SHIFT+Key_E, this, SLOT(insertExp()), actionCollection(), "rpn_exp10"); + new TDEAction(i18n("Exp RPN Operation"), CTRL+SHIFT+Key_E, this, SLOT(insertExp()), actionCollection(), "rpn_exp10"); setModeActions(); @@ -3895,16 +3895,16 @@ void KQalculate::execute() { bool KQalculate::fetch_exchange_rates(int) { KURL url(CALCULATOR->getExchangeRatesUrl().c_str()); TQString filename(CALCULATOR->getExchangeRatesFileName().c_str()); -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 - if(KIO::NetAccess::download(url, filename)) { +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 + if(TDEIO::NetAccess::download(url, filename)) { #else - if(KIO::NetAccess::download(url, filename, this)) { + if(TDEIO::NetAccess::download(url, filename, this)) { #endif return true; } else { TQString errorstr = i18n("Failed to download exchange rates from ECB."); errorstr += "\n"; - errorstr += KIO::NetAccess::lastErrorString(); + errorstr += TDEIO::NetAccess::lastErrorString(); KMessageBox::error(this, errorstr); return false; } @@ -4019,7 +4019,7 @@ void KQalculate::showHide() { if(isVisible()) { hide(); } else { -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 KWin::Info info = KWin::info(winId()); KWin::setOnDesktop(winId(), KWin::currentDesktop()); move(info.geometry.topLeft()); @@ -4031,7 +4031,7 @@ void KQalculate::showHide() { setShown(true); show(); raise(); -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 KWin::setActiveWindow(winId()); #else KWin::activateWindow(winId()); @@ -4766,7 +4766,7 @@ QalculateModeDialog::QalculateModeDialog(TQWidget *parent) : KDialogBase(parent, keyButton = new KKeyButton(mainWidget()); grid->addWidget(keyButton, 1, 1); - connect(keyButton, SIGNAL(capturedShortcut(const KShortcut&)), this, SLOT(updateShortcut(const KShortcut&))); + connect(keyButton, SIGNAL(capturedShortcut(const TDEShortcut&)), this, SLOT(updateShortcut(const TDEShortcut&))); connect(modeCombo, SIGNAL(activated(int)), this, SLOT(modeSelected(int))); } @@ -4777,13 +4777,13 @@ void QalculateModeDialog::modeSelected(int index) { keyButton->setShortcut(modes[index].shortcut, false); } } -void QalculateModeDialog::updateShortcut(const KShortcut &shortcut) { +void QalculateModeDialog::updateShortcut(const TDEShortcut &shortcut) { keyButton->setShortcut(shortcut, false); } TQString QalculateModeDialog::modeName() { return modeCombo->currentText(); } -const KShortcut &QalculateModeDialog::modeShortcut() { +const TDEShortcut &QalculateModeDialog::modeShortcut() { return keyButton->shortcut(); } void QalculateModeDialog::slotOk() { @@ -4818,7 +4818,7 @@ void KQalculate::saveModeAs() { delete dialog; } void KQalculate::deleteMode() { -#if KDE_VERSION_MAJOR > 3 || KDE_VERSION_MINOR >= 2 +#if TDE_VERSION_MAJOR > 3 || TDE_VERSION_MINOR >= 2 bool b_ok = false; TQStringList mode_names; for(size_t i = 2; i < modes.size(); i++) { @@ -5133,9 +5133,9 @@ void KQalculate::RPNStackEnter(Variable *v) { } void KQalculate::RPNRegisterAdded(const TQString &text, size_t index) { if(index == 0) { - new KListViewItem(stackList, TQString::number(index + 1), text); + new TDEListViewItem(stackList, TQString::number(index + 1), text); } else { - new KListViewItem(stackList, getRPNRegister(index - 1), TQString::number(index + 1), text); + new TDEListViewItem(stackList, getRPNRegister(index - 1), TQString::number(index + 1), text); } updateRPNIndexes(); clearStackButton->setEnabled(true); @@ -5266,7 +5266,7 @@ void KQalculate::stackRegisterSet(TQListViewItem *li) { execute_expression_do_mathoperation = false; execute_expression2(); } -void KQalculate::popupStackMenu(KListView*, TQListViewItem *li, const TQPoint &p) { +void KQalculate::popupStackMenu(TDEListView*, TQListViewItem *li, const TQPoint &p) { stackMenu->setItemEnabled(stackMenu->idAt(0), li != NULL); stackMenu->setItemEnabled(stackMenu->idAt(1), li != NULL); stackMenu->setItemEnabled(stackMenu->idAt(3), CALCULATOR->RPNStackSize() > 0); @@ -5884,7 +5884,7 @@ void KQalculate::applyPreferences() { if(use_icon_buttons > 0) { use_button_pixmaps = true; } else if(use_icon_buttons < 0) { - KConfig config("kdeglobals", true, false); + TDEConfig config("kdeglobals", true, false); config.setGroup("KDE"); use_button_pixmaps = config.readBoolEntry("ShowIconsOnPushButtons", false); } @@ -5893,23 +5893,23 @@ void KQalculate::applyPreferences() { if(use_button_pixmaps) { leftButtonsLayout->setSpacing(3); executeButton->setText(""); - executeButton->setIconSet(KApplication::kApplication()->iconLoader()->loadIconSet("exec", KIcon::Small, ICON_SIZE_SMALL_MEDIUM)); + executeButton->setIconSet(TDEApplication::kApplication()->iconLoader()->loadIconSet("application-x-executable", TDEIcon::Small, ICON_SIZE_SMALL_MEDIUM)); storeButton->setText(""); - storeButton->setIconSet(KApplication::kApplication()->iconLoader()->loadIconSet("filesaveas", KIcon::Small, ICON_SIZE_SMALL_MEDIUM)); + storeButton->setIconSet(TDEApplication::kApplication()->iconLoader()->loadIconSet("document-save-as", TDEIcon::Small, ICON_SIZE_SMALL_MEDIUM)); convertButton->setText(""); - convertButton->setIconSet(KApplication::kApplication()->iconLoader()->loadIconSet("qalculate_convert", KIcon::Small, ICON_SIZE_SMALL_MEDIUM)); + convertButton->setIconSet(TDEApplication::kApplication()->iconLoader()->loadIconSet("qalculate_convert", TDEIcon::Small, ICON_SIZE_SMALL_MEDIUM)); leftButtonsSeparator->hide(); stackPageButtonsLayout->setSpacing(3); registerUpButton->setText(""); - registerUpButton->setIconSet(KApplication::kApplication()->iconLoader()->loadIconSet("up", KIcon::Small, ICON_SIZE_SMALL_MEDIUM)); + registerUpButton->setIconSet(TDEApplication::kApplication()->iconLoader()->loadIconSet("go-up", TDEIcon::Small, ICON_SIZE_SMALL_MEDIUM)); registerDownButton->setText(""); - registerDownButton->setIconSet(KApplication::kApplication()->iconLoader()->loadIconSet("down", KIcon::Small, ICON_SIZE_SMALL_MEDIUM)); + registerDownButton->setIconSet(TDEApplication::kApplication()->iconLoader()->loadIconSet("go-down", TDEIcon::Small, ICON_SIZE_SMALL_MEDIUM)); editRegisterButton->setText(""); - editRegisterButton->setIconSet(KApplication::kApplication()->iconLoader()->loadIconSet("edit", KIcon::Small, ICON_SIZE_SMALL_MEDIUM)); + editRegisterButton->setIconSet(TDEApplication::kApplication()->iconLoader()->loadIconSet("edit", TDEIcon::Small, ICON_SIZE_SMALL_MEDIUM)); deleteRegisterButton->setText(""); - deleteRegisterButton->setIconSet(KApplication::kApplication()->iconLoader()->loadIconSet("editdelete", KIcon::Small, ICON_SIZE_SMALL_MEDIUM)); + deleteRegisterButton->setIconSet(TDEApplication::kApplication()->iconLoader()->loadIconSet("edit-delete", TDEIcon::Small, ICON_SIZE_SMALL_MEDIUM)); clearStackButton->setText(""); - clearStackButton->setIconSet(KApplication::kApplication()->iconLoader()->loadIconSet("view_remove", KIcon::Small, ICON_SIZE_SMALL_MEDIUM)); + clearStackButton->setIconSet(TDEApplication::kApplication()->iconLoader()->loadIconSet("view_remove", TDEIcon::Small, ICON_SIZE_SMALL_MEDIUM)); } else { leftButtonsLayout->setSpacing(6); if(rpn_mode) executeButton->setText(i18n("Enter")); @@ -6148,7 +6148,7 @@ void KQalculate::insertVector() { } void KQalculate::keyPressEvent(TQKeyEvent *e) { - KMainWindow::keyPressEvent(e); + TDEMainWindow::keyPressEvent(e); if(e->isAccepted()) return; if(close_to_systray && e->key() == Key_Escape && e->state() == 0) { e->accept(); @@ -6167,13 +6167,13 @@ bool KQalculate::queryClose() { setShown(false); return false; } -void KQalculate::saveProperties(KConfig*) { - KConfig *cfg = KGlobal::config(); +void KQalculate::saveProperties(TDEConfig*) { + TDEConfig *cfg = TDEGlobal::config(); cfg->setGroup("Session"); cfg->writeEntry("docked", isHidden()); } -void KQalculate::readProperties(KConfig*) { - KConfig *cfg = KGlobal::config(); +void KQalculate::readProperties(TDEConfig*) { + TDEConfig *cfg = TDEGlobal::config(); cfg->setGroup("Session"); if(close_to_systray && cfg->readBoolEntry("docked", true)) { hide(); @@ -6518,23 +6518,23 @@ void QalculateParseLabel::drawContents(TQPainter *p) { QalculateButton::QalculateButton(TQWidget *parent, const char *name) : TQPushButton(parent, name) { setSizePolicy(TQSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Minimum)); umtcw = true; -#if KDE_VERSION_MAJOR > 3 || KDE_VERSION_MINOR >= 4 - KAcceleratorManager::setNoAccel(this); +#if TDE_VERSION_MAJOR > 3 || TDE_VERSION_MINOR >= 4 + TDEAcceleratorManager::setNoAccel(this); #endif } QalculateButton::QalculateButton(const TQString &text, TQWidget *parent, const char *name) : TQPushButton(text, parent, name) { setSizePolicy(TQSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Minimum)); umtcw = true; -#if KDE_VERSION_MAJOR > 3 || KDE_VERSION_MINOR >= 4 - KAcceleratorManager::setNoAccel(this); +#if TDE_VERSION_MAJOR > 3 || TDE_VERSION_MINOR >= 4 + TDEAcceleratorManager::setNoAccel(this); #endif } QalculateButton::QalculateButton(const TQIconSet &icon, const TQString &text, TQWidget *parent, const char *name) : TQPushButton(icon, text, parent, name) { setSizePolicy(TQSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Minimum)); umtcw = true; -#if KDE_VERSION_MAJOR > 3 || KDE_VERSION_MINOR >= 4 - KAcceleratorManager::setNoAccel(this); +#if TDE_VERSION_MAJOR > 3 || TDE_VERSION_MINOR >= 4 + TDEAcceleratorManager::setNoAccel(this); #endif } QalculateButton::~QalculateButton() {} @@ -6652,7 +6652,7 @@ void QalculateStyleSheet::scaleFont(TQFont &font, int logicalSize) const { } -QalculateRPNStackListView::QalculateRPNStackListView(TQWidget *parent, const char *name) : KListView(parent, name) {} +QalculateRPNStackListView::QalculateRPNStackListView(TQWidget *parent, const char *name) : TDEListView(parent, name) {} QalculateRPNStackListView::~QalculateRPNStackListView() {} void QalculateRPNStackListView::keyPressEvent(TQKeyEvent *e) { @@ -6663,11 +6663,11 @@ void QalculateRPNStackListView::keyPressEvent(TQKeyEvent *e) { case Key_End: {} case Key_Up: {} case Key_Down: { - KListView::keyPressEvent(e); + TDEListView::keyPressEvent(e); break; } default: { - if(e->key() == KGlobalSettings::contextMenuKey()) KListView::keyPressEvent(e); + if(e->key() == TDEGlobalSettings::contextMenuKey()) TDEListView::keyPressEvent(e); else e->ignore(); } } diff --git a/src/kqalculate.h b/src/kqalculate.h index 2e74f14..6f1d874 100644 --- a/src/kqalculate.h +++ b/src/kqalculate.h @@ -22,15 +22,15 @@ #define KQALCULATE_H #include <tqvariant.h> -#include <kmainwindow.h> +#include <tdemainwindow.h> #include <tqvaluevector.h> #include <tqlabel.h> #include <tqpushbutton.h> #include <tqstylesheet.h> #include <ktextbrowser.h> -#include <klistview.h> +#include <tdelistview.h> #include <kdialogbase.h> -#include <kshortcut.h> +#include <tdeshortcut.h> class Prefix; class QalculatePrecisionDialog; @@ -49,9 +49,9 @@ class QalculateFunctionsDialog; class QalculateUnitsDialog; class QalculateDataSetsDialog; class QalculateConvertUnitsDialog; -class KAction; -class KRadioAction; -class KToggleAction; +class TDEAction; +class TDERadioAction; +class TDEToggleAction; class TQToolBar; class TQPopupMenu; class KPushButton; @@ -80,10 +80,10 @@ class QalculateButton; class TQVBoxLayout; class KSeparator; class KUniqueApplication; -class KConfig; +class TDEConfig; class TQListViewItem; class QalculateRPNStackListView; -class KGlobalAccel; +class TDEGlobalAccel; class KKeyButton; void *view_proc(void *pipe); @@ -110,7 +110,7 @@ class ModeObject : public TQObject { }; -class KQalculate : public KMainWindow { +class KQalculate : public TDEMainWindow { Q_OBJECT @@ -217,38 +217,38 @@ public: TQPushButton *historyButton, *keypadButton, *stackButton; KMenuBar *menubar; TQPopupMenu *menu_functions, *menu_variables, *menu_units, *menu_to_unit, *menu_set_prefix, *menu_modes; - KToggleAction *ActionAbbreviateNames, *ActionReadPrecision, *ActionNonZeroDenominators, *ActionWarnAboutDenominatorsAssumedNonZero; - KToggleAction *ActionLimitImplicitMultiplication, *ActionRPNMode, *ActionRPNSyntax, *ActionIndicateInfiniteSeries, *ActionNegativeExponents, *ActionSortMinusLast; - KToggleAction *ActionShowEndingZeroes, *ActionRoundHalfwayNumbersToEven, *ActionEnablePrefixes; - KToggleAction *ActionEnableUseOfAllPrefixes, *ActionEnableDenominatorPrefixes, *ActionPlaceUnitsSeparately; - KToggleAction *ActionEnableVariables, *ActionEnableFunctions, *ActionEnableUnits, *ActionEnableUnknowns; - KToggleAction *ActionCalculateVariables, *ActionAllowComplexResult, *ActionAllowInfiniteResult; - KRadioAction *ActionApproximationAlwaysExact, *ActionApproximationTryExact, *ActionApproximationApproximate; - KRadioAction *ActionAlgebraicModeSimplify, *ActionAlgebraicModeFactorize, *ActionAlgebraicModeNone; - KRadioAction *ActionFractionalDisplayDecimal, *ActionFractionalDisplayDecimalTryExact; - KRadioAction *ActionFractionalDisplayFraction, *ActionFractionalDisplayCombined; - KRadioAction *ActionNumericalDisplayEngineering, *ActionNumericalDisplayScientific, *ActionNumericalDisplayPurelyScientific, *ActionNumericalDisplaySimple, *ActionNumericalDisplayNormal; - KRadioAction *ActionNumberBaseBinary, *ActionNumberBaseOctal, *ActionNumberBaseDecimal, *ActionNumberBaseHexadecimal, *ActionNumberBaseOther; - KRadioAction *ActionNumberBaseSexagesimal, *ActionNumberBaseTimeFormat, *ActionNumberBaseRomanNumerals; - KRadioAction *ActionAssumptionTypeUnknown, *ActionAssumptionTypeNonMatrix, *ActionAssumptionTypeNumber, *ActionAssumptionTypeComplex, *ActionAssumptionTypeReal; - KRadioAction *ActionAssumptionTypeRational, *ActionAssumptionTypeInteger, *ActionAssumptionSignUnknown, *ActionAssumptionSignNonZero; - KRadioAction *ActionAssumptionSignPositive, *ActionAssumptionSignNonNegative, *ActionAssumptionSignNegative; - KRadioAction *ActionAssumptionSignNonPositive, *ActionAngleUnitDegrees, *ActionAngleUnitRadians, *ActionAngleUnitGradians; - KRadioAction *ActionAngleUnitNone, *ActionAutoNoConversion, *ActionAutoConvertToBaseUnits, *ActionAutoConvertToBestUnit; - KAction *ActionSetBase, *ActionPrecision, *ActionDecimals, *ActionSaveModeAs, *ActionDeleteMode, *ActionSaveMode, *ActionQuit; - KAction *ActionUpdateExchangeRates, *ActionManageVariables, *ActionConvertToUnitExpression, *ActionStoreResult, *ActionClose; - KAction *ActionConvertNumberBases, *ActionManageFunctions, *ActionConvertToBaseUnits, *ActionConvertToBestUnit; - KAction *ActionManageUnits, *ActionManageDataSets, *ActionFactorize, *ActionSimplify, *ActionSetUnknowns, *ActionCopyResult; - KAction *ActionPreferences, *ActionSaveAsImage, *ActionImportCSVFile, *ActionExportCSVFile, *ActionPeriodicTable; - KAction *ActionPlotFunctionsData, *ActionSaveDefinitions, *ActionNewVariable, *ActionNewMatrix, *ActionNewVector; - KAction *ActionNewUnknownVariable, *ActionNewFunction, *ActionNewUnit, *ActionNewDataSet; - KAction *ActionInsertMatrix, *ActionInsertVector; - KAction *ActionClearHistory; - KAction *ActionHideSystemTrayIcon, *ActionHide; - KAction *ActionClearStack, *ActionDeleteRegister, *ActionEditRegister; - KAction *ActionConfigureGlobalShortcuts; - - KGlobalAccel *globalAccel; + TDEToggleAction *ActionAbbreviateNames, *ActionReadPrecision, *ActionNonZeroDenominators, *ActionWarnAboutDenominatorsAssumedNonZero; + TDEToggleAction *ActionLimitImplicitMultiplication, *ActionRPNMode, *ActionRPNSyntax, *ActionIndicateInfiniteSeries, *ActionNegativeExponents, *ActionSortMinusLast; + TDEToggleAction *ActionShowEndingZeroes, *ActionRoundHalfwayNumbersToEven, *ActionEnablePrefixes; + TDEToggleAction *ActionEnableUseOfAllPrefixes, *ActionEnableDenominatorPrefixes, *ActionPlaceUnitsSeparately; + TDEToggleAction *ActionEnableVariables, *ActionEnableFunctions, *ActionEnableUnits, *ActionEnableUnknowns; + TDEToggleAction *ActionCalculateVariables, *ActionAllowComplexResult, *ActionAllowInfiniteResult; + TDERadioAction *ActionApproximationAlwaysExact, *ActionApproximationTryExact, *ActionApproximationApproximate; + TDERadioAction *ActionAlgebraicModeSimplify, *ActionAlgebraicModeFactorize, *ActionAlgebraicModeNone; + TDERadioAction *ActionFractionalDisplayDecimal, *ActionFractionalDisplayDecimalTryExact; + TDERadioAction *ActionFractionalDisplayFraction, *ActionFractionalDisplayCombined; + TDERadioAction *ActionNumericalDisplayEngineering, *ActionNumericalDisplayScientific, *ActionNumericalDisplayPurelyScientific, *ActionNumericalDisplaySimple, *ActionNumericalDisplayNormal; + TDERadioAction *ActionNumberBaseBinary, *ActionNumberBaseOctal, *ActionNumberBaseDecimal, *ActionNumberBaseHexadecimal, *ActionNumberBaseOther; + TDERadioAction *ActionNumberBaseSexagesimal, *ActionNumberBaseTimeFormat, *ActionNumberBaseRomanNumerals; + TDERadioAction *ActionAssumptionTypeUnknown, *ActionAssumptionTypeNonMatrix, *ActionAssumptionTypeNumber, *ActionAssumptionTypeComplex, *ActionAssumptionTypeReal; + TDERadioAction *ActionAssumptionTypeRational, *ActionAssumptionTypeInteger, *ActionAssumptionSignUnknown, *ActionAssumptionSignNonZero; + TDERadioAction *ActionAssumptionSignPositive, *ActionAssumptionSignNonNegative, *ActionAssumptionSignNegative; + TDERadioAction *ActionAssumptionSignNonPositive, *ActionAngleUnitDegrees, *ActionAngleUnitRadians, *ActionAngleUnitGradians; + TDERadioAction *ActionAngleUnitNone, *ActionAutoNoConversion, *ActionAutoConvertToBaseUnits, *ActionAutoConvertToBestUnit; + TDEAction *ActionSetBase, *ActionPrecision, *ActionDecimals, *ActionSaveModeAs, *ActionDeleteMode, *ActionSaveMode, *ActionQuit; + TDEAction *ActionUpdateExchangeRates, *ActionManageVariables, *ActionConvertToUnitExpression, *ActionStoreResult, *ActionClose; + TDEAction *ActionConvertNumberBases, *ActionManageFunctions, *ActionConvertToBaseUnits, *ActionConvertToBestUnit; + TDEAction *ActionManageUnits, *ActionManageDataSets, *ActionFactorize, *ActionSimplify, *ActionSetUnknowns, *ActionCopyResult; + TDEAction *ActionPreferences, *ActionSaveAsImage, *ActionImportCSVFile, *ActionExportCSVFile, *ActionPeriodicTable; + TDEAction *ActionPlotFunctionsData, *ActionSaveDefinitions, *ActionNewVariable, *ActionNewMatrix, *ActionNewVector; + TDEAction *ActionNewUnknownVariable, *ActionNewFunction, *ActionNewUnit, *ActionNewDataSet; + TDEAction *ActionInsertMatrix, *ActionInsertVector; + TDEAction *ActionClearHistory; + TDEAction *ActionHideSystemTrayIcon, *ActionHide; + TDEAction *ActionClearStack, *ActionDeleteRegister, *ActionEditRegister; + TDEAction *ActionConfigureGlobalShortcuts; + + TDEGlobalAccel *globalAccel; TQValueVector<int>::size_type current_history_index; TQValueVector<ModeObject*> mode_objects; @@ -452,7 +452,7 @@ public slots: TQListViewItem *getRPNRegister(size_t index); void stackRegisterMoved(); void stackRegisterSet(TQListViewItem*); - void popupStackMenu(KListView*, TQListViewItem*, const TQPoint&); + void popupStackMenu(TDEListView*, TQListViewItem*, const TQPoint&); void registerSelected(); void editHistoryExpression(); void editHistoryParse(); @@ -471,8 +471,8 @@ protected: TQString parsed_expression; void keyPressEvent(TQKeyEvent *e); void fontChange(const TQFont &old_font); - void saveProperties(KConfig *cfg); - void readProperties(KConfig *cfg); + void saveProperties(TDEConfig *cfg); + void readProperties(TDEConfig *cfg); private: @@ -550,7 +550,7 @@ public: }; -class QalculateRPNStackListView : public KListView { +class QalculateRPNStackListView : public TDEListView { Q_OBJECT @@ -580,12 +580,12 @@ class QalculateModeDialog : public KDialogBase { virtual ~QalculateModeDialog(); TQString modeName(); - const KShortcut &modeShortcut(); + const TDEShortcut &modeShortcut(); public slots: void slotOk(); - void updateShortcut(const KShortcut&); + void updateShortcut(const TDEShortcut&); void modeSelected(int); }; diff --git a/src/main.cpp b/src/main.cpp index b7f36e7..c9c9ee6 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -24,15 +24,15 @@ #include "kqalculate.h" #include "preferences.h" -#include <kwin.h> +#include <twin.h> #include <kuniqueapplication.h> -#include <kaboutdata.h> -#include <kcmdlineargs.h> -#include <klocale.h> +#include <tdeaboutdata.h> +#include <tdecmdlineargs.h> +#include <tdelocale.h> #include <unistd.h> #include <tqtextcodec.h> #include <tqobject.h> -#include <kmessagebox.h> +#include <tdemessagebox.h> #include <tqtimer.h> #include <klineedit.h> #include <tqtooltip.h> @@ -46,11 +46,11 @@ static const char description[] = I18N_NOOP("A powerful and easy to use desktop static const char version[] = VERSION; -static KCmdLineOptions options[] = { +static TDECmdLineOptions options[] = { {"c", 0, 0}, {"clipboard", I18N_NOOP("Calculate X11-clipboard content (selected text)"), 0}, {"+[Expression]", I18N_NOOP( "Initial expression to calculate" ), 0}, - KCmdLineLastOption + TDECmdLineLastOption }; extern KnownVariable *vans[5]; @@ -83,8 +83,8 @@ void create_qalculate_window(KUniqueApplication *parent) { b_busy = false; new Calculator(); - if(KGlobal::locale()->decimalSymbol() == ",") CALCULATOR->useDecimalComma(); - CALCULATOR->place_currency_code_before = KGlobal::locale()->positivePrefixCurrencySymbol(); + if(TDEGlobal::locale()->decimalSymbol() == ",") CALCULATOR->useDecimalComma(); + CALCULATOR->place_currency_code_before = TDEGlobal::locale()->positivePrefixCurrencySymbol(); //load application specific preferences load_preferences(); @@ -105,7 +105,7 @@ void create_qalculate_window(KUniqueApplication *parent) { } -TQString parse_expression_arguments(KCmdLineArgs *args) { +TQString parse_expression_arguments(TDECmdLineArgs *args) { TQString calc_arg; if(args->isSet("clipboard")) { calc_arg = tqApp->clipboard()->text(TQClipboard::Selection); @@ -125,7 +125,7 @@ TQString parse_expression_arguments(KCmdLineArgs *args) { void start_qalculate() { - KCmdLineArgs* args = KCmdLineArgs::parsedArgs(); + TDECmdLineArgs* args = TDECmdLineArgs::parsedArgs(); TQString calc_arg = parse_expression_arguments(args); args->clear(); if(!calc_arg.isEmpty()) { @@ -234,11 +234,11 @@ public: int newInstance() { if(mainWin && started) { - KCmdLineArgs* args = KCmdLineArgs::parsedArgs(); + TDECmdLineArgs* args = TDECmdLineArgs::parsedArgs(); TQString calc_arg = parse_expression_arguments(args); args->clear(); -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 KWin::Info info = KWin::info(mainWin->winId()); KWin::setOnDesktop(mainWin->winId(), KWin::currentDesktop()); mainWin->move(info.geometry.topLeft()); @@ -250,7 +250,7 @@ public: mainWin->setShown(true); mainWin->show(); mainWin->raise(); -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 KWin::setActiveWindow(mainWin->winId()); #else KWin::activateWindow(mainWin->winId()); @@ -263,7 +263,7 @@ public: return 0; } else { - if(isRestored() && KMainWindow::canBeRestored(1)) { + if(isRestored() && TDEMainWindow::canBeRestored(1)) { create_qalculate_window(this); setMainWidget(mainWin); mainWin->restore(1, false); @@ -287,10 +287,10 @@ int main(int argc, char **argv) { mainWin = NULL; - KAboutData about(PACKAGE, I18N_NOOP("Qalculate!"), version, description, KAboutData::License_GPL, "(C) 2005-2006 Niklas Knutsson", 0, "http://qalculate.sourceforge.net/", "nique769@users.sourceforge.net"); + TDEAboutData about(PACKAGE, I18N_NOOP("Qalculate!"), version, description, TDEAboutData::License_GPL, "(C) 2005-2006 Niklas Knutsson", 0, "http://qalculate.sourceforge.net/", "nique769@users.sourceforge.net"); about.addAuthor("Niklas Knutsson", 0, "nq@altern.org"); - KCmdLineArgs::init(argc, argv, &about); - KCmdLineArgs::addCmdLineOptions(options); + TDECmdLineArgs::init(argc, argv, &about); + TDECmdLineArgs::addCmdLineOptions(options); KUniqueApplication::addCmdLineOptions(); if(!QalculateApp::start()) { diff --git a/src/preferences.cpp b/src/preferences.cpp index 7d768ec..f4f4011 100644 --- a/src/preferences.cpp +++ b/src/preferences.cpp @@ -30,7 +30,7 @@ #include <unistd.h> #include <dirent.h> #include <stdio.h> -#include <klocale.h> +#include <tdelocale.h> #include <tqstringlist.h> #include <ktextbrowser.h> #include <tqwidgetstack.h> @@ -200,7 +200,7 @@ void load_preferences() { evalops.assume_denominators_nonzero = true; evalops.warn_about_denominators_assumed_nonzero = true; evalops.parse_options.angle_unit = ANGLE_UNIT_RADIANS; - evalops.parse_options.dot_as_separator = KGlobal::locale()->thousandsSeparator() == "."; + evalops.parse_options.dot_as_separator = TDEGlobal::locale()->thousandsSeparator() == "."; rpn_mode = false; rpn_keypad_only = true; diff --git a/src/qalculate_tde.desktop b/src/qalculate_tde.desktop index 1eddf6e..c92ea56 100644 --- a/src/qalculate_tde.desktop +++ b/src/qalculate_tde.desktop @@ -4,10 +4,10 @@ GenericName=Scientific Calculator Exec=qalculate-tde Icon=qalculate_tde Type=Application -DocPath=qalculate_tde/index.html -Categories=Qt;KDE;Utility;Science; +X-DocPath=qalculate_tde/index.html +Categories=Qt;TDE;Utility;Science; Terminal=false X-DCOP-ServiceType=Unique X-DCOP-ServiceName=qalculate_tde -X-KDE-StartupNotify=true +X-TDE-StartupNotify=true Comment=Powerful and easy to use desktop calculator diff --git a/src/qalculate_tde_utils.h b/src/qalculate_tde_utils.h index 973c036..05df313 100644 --- a/src/qalculate_tde_utils.h +++ b/src/qalculate_tde_utils.h @@ -28,7 +28,7 @@ #undef getItem #include <tqstring.h> -#include <kshortcut.h> +#include <tdeshortcut.h> class TQLabel; class TQLineEdit; @@ -58,7 +58,7 @@ struct mode_struct { int precision; TQString name; bool rpn_mode; - KShortcut shortcut; + TDEShortcut shortcut; }; void insert_text_in_expression(const TQString &str); diff --git a/src/qalculate_tdeui.rc b/src/qalculate_tdeui.rc index eae44d9..b3e8497 100644 --- a/src/qalculate_tdeui.rc +++ b/src/qalculate_tdeui.rc @@ -2,7 +2,7 @@ <kpartgui name="kqalculate"> <MenuBar> <Menu name="file"><text>&File</text> - <Menu name="new" icon="filenew"><text>&New</text> + <Menu name="new" icon="document-new"><text>&New</text> <Action name="new_variable"/> <Action name="new_matrix"/> <Action name="new_vector"/> diff --git a/src/qalculateconvertnumberbasesdialog.cpp b/src/qalculateconvertnumberbasesdialog.cpp index 950bd00..8ff4ba9 100644 --- a/src/qalculateconvertnumberbasesdialog.cpp +++ b/src/qalculateconvertnumberbasesdialog.cpp @@ -19,7 +19,7 @@ ***************************************************************************/ #include "qalculateconvertnumberbasesdialog.h" #include "qalculate_tde_utils.h" -#include <klocale.h> +#include <tdelocale.h> #include <tqgrid.h> #include <tqlabel.h> #include <klineedit.h> diff --git a/src/qalculateconvertunitsdialog.cpp b/src/qalculateconvertunitsdialog.cpp index 0808780..25336c4 100644 --- a/src/qalculateconvertunitsdialog.cpp +++ b/src/qalculateconvertunitsdialog.cpp @@ -22,13 +22,13 @@ #include <tqlabel.h> #include <klineedit.h> -#include <klocale.h> +#include <tdelocale.h> #include <tqhbox.h> -#include <klistview.h> -#include <klocale.h> +#include <tdelistview.h> +#include <tdelocale.h> #include <tqvbox.h> -#include <klistview.h> -#include <kmessagebox.h> +#include <tdelistview.h> +#include <tdemessagebox.h> #include <tqlayout.h> #include <tqpushbutton.h> #include <tqsplitter.h> @@ -59,12 +59,12 @@ QalculateConvertUnitsDialog::QalculateConvertUnitsDialog(TQWidget *parent, const setDetailsWidget(box_d); - categoryView = new KListView(splitter); + categoryView = new TDEListView(splitter); categoryView->addColumn(i18n("Category")); categoryView->setRootIsDecorated(false); categoryView->setFullWidth(true); - unitView = new KListView(splitter); + unitView = new TDEListView(splitter); unitView->addColumn(i18n("Unit")); unitView->setRootIsDecorated(false); unitView->setFullWidth(true); @@ -82,7 +82,7 @@ void QalculateConvertUnitsDialog::updateUnitTree() { unitItems.clear(); categoryItems.clear(); categoryView->clear(); - TQListViewItem *i = new KListViewItem(categoryView, i18n("All")), *i2; + TQListViewItem *i = new TDEListViewItem(categoryView, i18n("All")), *i2; categoryItems[i] = i18n("All"); i->setOpen(true); TQString str; @@ -100,7 +100,7 @@ void QalculateConvertUnitsDialog::updateUnitTree() { while(item) { str += "/"; str += item->item.c_str(); - i = new KListViewItem(i2, item->item.c_str()); + i = new TDEListViewItem(i2, item->item.c_str()); i->setOpen(false); categoryItems[i] = str; if(str == selected_category) { @@ -129,7 +129,7 @@ void QalculateConvertUnitsDialog::updateUnitTree() { } if(!unit_cats.objects.empty()) { //add "Uncategorized" category if there are units without category - i = new KListViewItem(categoryView, i18n("Uncategorized")); + i = new TDEListViewItem(categoryView, i18n("Uncategorized")); categoryItems[i] = i18n("Uncategorized"); if(selected_category == i18n("Uncategorized")) { categoryView->ensureItemVisible(i); @@ -161,7 +161,7 @@ void QalculateConvertUnitsDialog::unitSelected() { } void QalculateConvertUnitsDialog::addUnitTreeItem(Unit *u) { - TQListViewItem *i = new KListViewItem(unitView, u->title(true).c_str()); + TQListViewItem *i = new TDEListViewItem(unitView, u->title(true).c_str()); unitItems[i] = u; } diff --git a/src/qalculateconvertunitsdialog.h b/src/qalculateconvertunitsdialog.h index a924b72..efa5990 100644 --- a/src/qalculateconvertunitsdialog.h +++ b/src/qalculateconvertunitsdialog.h @@ -25,7 +25,7 @@ class KLineEdit; class Unit; -class KListView; +class TDEListView; class TQListViewItem; /** @@ -46,8 +46,8 @@ public: TQMap<TQListViewItem*, Unit*> unitItems; TQMap<TQListViewItem*, TQString> categoryItems; - KListView *categoryView; - KListView *unitView; + TDEListView *categoryView; + TDEListView *unitView; TQString selected_category; bool block_unit_convert; diff --git a/src/qalculatedatasetsdialog.cpp b/src/qalculatedatasetsdialog.cpp index 5505805..d30dc9d 100644 --- a/src/qalculatedatasetsdialog.cpp +++ b/src/qalculatedatasetsdialog.cpp @@ -28,9 +28,9 @@ #include <tqvbox.h> #include <tqhbox.h> #include <tqgrid.h> -#include <klistview.h> -#include <kmessagebox.h> -#include <klocale.h> +#include <tdelistview.h> +#include <tdemessagebox.h> +#include <tdelocale.h> #include <tqlayout.h> #include <tqgroupbox.h> #include <tqscrollview.h> @@ -59,7 +59,7 @@ QalculateDataSetsDialog::QalculateDataSetsDialog(TQWidget *parent, const char *n widget->setSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Expanding); TQVBoxLayout *vbox = new TQVBoxLayout(widget, spacingHint(), spacingHint()); vbox->addWidget(new TQLabel(i18n("Data Sets:"), widget)); - dataSetsView = new KListView(widget); + dataSetsView = new TDEListView(widget); vbox->addWidget(dataSetsView); dataSetsView->addColumn(i18n("Data Set")); dataSetsView->setRootIsDecorated(false); @@ -82,7 +82,7 @@ QalculateDataSetsDialog::QalculateDataSetsDialog(TQWidget *parent, const char *n widget->setSizePolicy(TQSizePolicy::Minimum, TQSizePolicy::Expanding); vbox = new TQVBoxLayout(widget, spacingHint(), spacingHint()); vbox->addWidget(new TQLabel(i18n("Objects:"), widget)); - objectsView = new KListView(widget); + objectsView = new TDEListView(widget); vbox->addWidget(objectsView); objectsView->addColumn(i18n("Object")); objectsView->setRootIsDecorated(false); @@ -135,7 +135,7 @@ void QalculateDataSetsDialog::updateDataSetTree() { for(size_t index = 1; ; index++) { ds = CALCULATOR->getDataSet(index); if(!ds) break; - i = new KListViewItem(dataSetsView, ds->title().c_str()); + i = new TDEListViewItem(dataSetsView, ds->title().c_str()); dataSetItems[i] = ds; if(ds == selected_dataset) { dataSetsView->blockSignals(false); @@ -234,7 +234,7 @@ void QalculateDataSetsDialog::dataSetSelected() { bool b = false, b2 = false; TQListViewItem *i; while(o) { - i = new KListViewItem(objectsView); + i = new TDEListViewItem(objectsView); objectItems[i] = o; dp = ds->getFirstProperty(&pit); int index = 0; @@ -427,7 +427,7 @@ void QalculateDataSetsDialog::objectSelected() { KLineEdit *le = new KLineEdit(sval, attributesGrid); le->setReadOnly(true); le->setFrameStyle(TQFrame::NoFrame | TQFrame::Plain); - QalculateButtonWithData *button = new QalculateButtonWithData((void*) dp, TQIconSet(SmallIcon("editpaste")), "", attributesGrid); + QalculateButtonWithData *button = new QalculateButtonWithData((void*) dp, TQIconSet(SmallIcon("edit-paste")), "", attributesGrid); TQObject::connect(button, SIGNAL(clickedWithData(void*)), SLOT(insertObjectData(void*))); } } diff --git a/src/qalculatedatasetsdialog.h b/src/qalculatedatasetsdialog.h index 3ab19d4..a4b77e1 100644 --- a/src/qalculatedatasetsdialog.h +++ b/src/qalculatedatasetsdialog.h @@ -24,7 +24,7 @@ #include <tqmap.h> class TQPushButton; -class KListView; +class TDEListView; class KTextBrowser; class TQScrollView; class TQGrid; @@ -46,7 +46,7 @@ public: virtual ~QalculateDataSetsDialog(); TQPushButton *newObjectButton, *editObjectButton, *deleteObjectButton, *newDataSetButton, *editDataSetButton, *deleteDataSetButton; - KListView *objectsView, *dataSetsView; + TDEListView *objectsView, *dataSetsView; KTextBrowser *descriptionBrowser; TQScrollView *attributesView; TQGrid *attributesGrid; diff --git a/src/qalculatedecimalsdialog.cpp b/src/qalculatedecimalsdialog.cpp index 8e5ba98..ce121ae 100644 --- a/src/qalculatedecimalsdialog.cpp +++ b/src/qalculatedecimalsdialog.cpp @@ -21,7 +21,7 @@ #include <tqlabel.h> #include <tqspinbox.h> -#include <klocale.h> +#include <tdelocale.h> #include <tqgrid.h> QalculateDecimalsDialog::QalculateDecimalsDialog(TQWidget *parent, const char *name) : KDialogBase(parent, name, false, i18n("Decimals"), Close, Close, true) { diff --git a/src/qalculateeditdataobjectdialog.cpp b/src/qalculateeditdataobjectdialog.cpp index e944e9d..df63409 100644 --- a/src/qalculateeditdataobjectdialog.cpp +++ b/src/qalculateeditdataobjectdialog.cpp @@ -25,7 +25,7 @@ #include <kcombobox.h> #include <tqvaluevector.h> #include <tqstring.h> -#include <klocale.h> +#include <tdelocale.h> QalculateEditDataObjectDialog::QalculateEditDataObjectDialog(TQWidget *parent, const char *name) : KDialogBase(parent, name, true, i18n("Edit Object"), Ok | Cancel, Ok, true) { diff --git a/src/qalculateeditdatasetdialog.cpp b/src/qalculateeditdatasetdialog.cpp index 248039e..e543368 100644 --- a/src/qalculateeditdatasetdialog.cpp +++ b/src/qalculateeditdatasetdialog.cpp @@ -26,20 +26,20 @@ #include <kpushbutton.h> #include <kcombobox.h> #include <tqlabel.h> -#include <klocale.h> +#include <tdelocale.h> #include <tqvbox.h> #include <tqhbox.h> #include <tqcheckbox.h> -#include <kmessagebox.h> -#include <kdeversion.h> +#include <tdemessagebox.h> +#include <tdeversion.h> #include <tqlayout.h> -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 1 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 1 #include <tqtextedit.h> #else #include <ktextedit.h> #endif -#include <klistview.h> -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#include <tdelistview.h> +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 #include <tqtabwidget.h> #else #include <ktabwidget.h> @@ -56,7 +56,7 @@ QalculateEditDataSetDialog::QalculateEditDataSetDialog(TQWidget *parent, const c edited_dataset = NULL; property_edit_dialog = NULL; -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 tabs = new TQTabWidget(this); #else tabs = new KTabWidget(this); @@ -77,7 +77,7 @@ QalculateEditDataSetDialog::QalculateEditDataSetDialog(TQWidget *parent, const c fileEdit = new KLineEdit(page1); grid->addWidget(fileEdit, 1, 1); grid->addWidget(new TQLabel(i18n("Description:"), page1), 2, 0); -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 1 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 1 descriptionEdit = new TQTextEdit(page1); #else descriptionEdit = new KTextEdit(page1); @@ -85,7 +85,7 @@ QalculateEditDataSetDialog::QalculateEditDataSetDialog(TQWidget *parent, const c descriptionEdit->setTextFormat(TQTextEdit::PlainText); grid->addMultiCellWidget(descriptionEdit, 3, 3, 0, 1); grid->addWidget(new TQLabel(i18n("Copyright:"), page1), 4, 0); -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 1 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 1 copyrightEdit = new TQTextEdit(page1); #else copyrightEdit = new KTextEdit(page1); @@ -95,7 +95,7 @@ QalculateEditDataSetDialog::QalculateEditDataSetDialog(TQWidget *parent, const c TQVBoxLayout *vbox = new TQVBoxLayout(page2, spacingHint()); vbox->addWidget(new TQLabel(i18n("Properties:"), page2)); - propertiesView = new KListView(page2); + propertiesView = new TDEListView(page2); propertiesView->addColumn(i18n("Title")); propertiesView->addColumn(i18n("Name")); propertiesView->addColumn(i18n("Type")); @@ -195,7 +195,7 @@ void QalculateEditDataSetDialog::updateDatasetPropertyList() { str += i18n("key"); str += ")"; } - TQListViewItem *item = new KListViewItem(propertiesView, i_prev, tmp_props[i]->title(false).c_str(), tmp_props[i]->getName().c_str(), str); + TQListViewItem *item = new TDEListViewItem(propertiesView, i_prev, tmp_props[i]->title(false).c_str(), tmp_props[i]->getName().c_str(), str); i_prev = item; propertiesItems[item] = tmp_props[i]; } @@ -454,7 +454,7 @@ QalculateEditDataPropertyDialog::QalculateEditDataPropertyDialog(TQWidget *paren titleEdit = new KLineEdit(mainWidget()); grid->addWidget(titleEdit, 2, 1); grid->addWidget(new TQLabel(i18n("Description:"), mainWidget()), 3, 0); -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 1 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 1 descriptionEdit = new TQTextEdit(mainWidget()); #else descriptionEdit = new KTextEdit(mainWidget()); @@ -616,7 +616,7 @@ QalculateEditDataPropertyNamesDialog::QalculateEditDataPropertyNamesDialog(TQWid TQVBoxLayout *layout = new TQVBoxLayout(this, marginHint(), spacingHint()); - namesView = new KListView(this); + namesView = new TDEListView(this); namesView->addColumn(i18n("Name")); namesView->addColumn(i18n("Reference")); namesView->setColumnAlignment(1, TQt::AlignCenter); @@ -649,7 +649,7 @@ QalculateEditDataPropertyNamesDialog::~QalculateEditDataPropertyNamesDialog() {} void QalculateEditDataPropertyNamesDialog::newName() { ExpressionName name; - TQListViewItem *i = new KListViewItem(namesView, namesView->lastChild(), "", i18n("No"), i18n("No"), i18n("No"), i18n("No"), i18n("No"), i18n("No"), i18n("No")); + TQListViewItem *i = new TDEListViewItem(namesView, namesView->lastChild(), "", i18n("No"), i18n("No"), i18n("No"), i18n("No"), i18n("No"), i18n("No"), i18n("No")); namesView->setSelected(i, true); tqApp->processEvents(); namesView->rename(i, 0); @@ -664,7 +664,7 @@ void QalculateEditDataPropertyNamesDialog::setNames(DataProperty *item, const TQ if(!names_edited && item && item->countNames() > 0) { TQListViewItem *i_prev = NULL; for(size_t index = 1; index <= item->countNames(); index++) { - TQListViewItem *i = new KListViewItem(namesView, i_prev); + TQListViewItem *i = new TDEListViewItem(namesView, i_prev); i_prev = i; if(item->nameIsReference(index)) i->setText(1, i18n("Yes")); @@ -682,7 +682,7 @@ void QalculateEditDataPropertyNamesDialog::setNames(DataProperty *item, const TQ if(it.current()) it.current()->setText(0, namestr); } else { - new KListViewItem(namesView, namestr, i18n("No")); + new TDEListViewItem(namesView, namestr, i18n("No")); } } } diff --git a/src/qalculateeditdatasetdialog.h b/src/qalculateeditdatasetdialog.h index 3dde6fa..e85de7d 100644 --- a/src/qalculateeditdatasetdialog.h +++ b/src/qalculateeditdatasetdialog.h @@ -31,7 +31,7 @@ class TQPushButton; class MathStructure; class QalculateEditNamesDialog; class DataSet; -class KListView; +class TDEListView; class TQTextEdit; class DataProperty; class TQTabWidget; @@ -60,7 +60,7 @@ public: DataSet *edited_dataset; KLineEdit *objectArgumentEdit, *propertyArgumentEdit, *defaultPropertyEdit, *nameEdit, *titleEdit, *fileEdit; TQLabel *namesLabel; - KListView *propertiesView; + TDEListView *propertiesView; TQTextEdit *descriptionEdit, *copyrightEdit; TQPushButton *namesButton, *newPropertyButton, *editPropertyButton, *deletePropertyButton; TQTabWidget *tabs; @@ -127,7 +127,7 @@ public: bool isEmpty(); void setNamesLE(TQLineEdit *entry, TQLabel *label); - KListView* namesView; + TDEListView* namesView; TQPushButton* newButton; TQPushButton* deleteButton; TQPushButton* buttonClose; diff --git a/src/qalculateeditfunctiondialog.cpp b/src/qalculateeditfunctiondialog.cpp index 2264d55..82dd579 100644 --- a/src/qalculateeditfunctiondialog.cpp +++ b/src/qalculateeditfunctiondialog.cpp @@ -26,26 +26,26 @@ #include <kpushbutton.h> #include <kcombobox.h> #include <tqlabel.h> -#include <klocale.h> +#include <tdelocale.h> #include <tqvbox.h> #include <tqhbox.h> #include <tqcheckbox.h> -#include <kmessagebox.h> +#include <tdemessagebox.h> #include <tqlayout.h> -#include <kdeversion.h> -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 1 +#include <tdeversion.h> +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 1 #include <tqtextedit.h> #else #include <ktextedit.h> #endif -#include <klistview.h> -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#include <tdelistview.h> +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 #include <tqtabwidget.h> #else #include <ktabwidget.h> #endif #include <tqheader.h> -#include <kapplication.h> +#include <tdeapplication.h> #include <kstdguiitem.h> extern PrintOptions printops; @@ -59,7 +59,7 @@ QalculateEditFunctionDialog::QalculateEditFunctionDialog(TQWidget *parent, const edited_function = NULL; argument_edit_dialog = NULL; -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 tabs = new TQTabWidget(this); #else tabs = new KTabWidget(this); @@ -96,7 +96,7 @@ QalculateEditFunctionDialog::QalculateEditFunctionDialog(TQWidget *parent, const hideButton = new TQCheckBox(i18n("Hide function"), page1); hbox->addWidget(hideButton); grid->addWidget(new TQLabel(i18n("Description:"), page1), 5, 0); -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 1 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 1 descriptionEdit = new TQTextEdit(page1); #else descriptionEdit = new KTextEdit(page1); @@ -104,7 +104,7 @@ QalculateEditFunctionDialog::QalculateEditFunctionDialog(TQWidget *parent, const descriptionEdit->setTextFormat(TQTextEdit::PlainText); grid->addMultiCellWidget(descriptionEdit, 6, 6, 0, 1); vbox->addWidget(new TQLabel(i18n("Expression:"), page2)); -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 1 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 1 expressionEdit = new TQTextEdit(page2); #else expressionEdit = new KTextEdit(page2); @@ -120,7 +120,7 @@ QalculateEditFunctionDialog::QalculateEditFunctionDialog(TQWidget *parent, const subFunctionsButton = new TQPushButton(i18n("Sub-Functions"), page2); hbox->addWidget(subFunctionsButton); vbox->addWidget(new TQLabel(i18n("Arguments:"), page2)); - argumentsView = new KListView(page2); + argumentsView = new TDEListView(page2); argumentsView->addColumn(i18n("Name")); argumentsView->addColumn(i18n("Type")); argumentsView->setSorting(-1); @@ -152,7 +152,7 @@ QalculateEditFunctionDialog::~QalculateEditFunctionDialog() {} void QalculateEditFunctionDialog::slotHelp() { - KApplication::kApplication()->invokeHelp("qalculate-function-creation"); + TDEApplication::kApplication()->invokeHelp("qalculate-function-creation"); } void QalculateEditFunctionDialog::argumentSelectionChanged() { @@ -377,13 +377,13 @@ MathFunction *QalculateEditFunctionDialog::editFunction(TQString category, MathF str = defarg.printlong().c_str(); str2 = ""; } - TQListViewItem *i_new = new KListViewItem(argumentsView, i_prev, str2, str); + TQListViewItem *i_new = new TDEListViewItem(argumentsView, i_prev, str2, str); i_prev = i_new; argumentsItems[i_new] = arg; argumentsItemsEdited[i_new] = false; } } - argumentsView->setResizeMode(KListView::AllColumns); + argumentsView->setResizeMode(TDEListView::AllColumns); if(exec() == TQDialog::Accepted) { f = edited_function; @@ -419,7 +419,7 @@ void QalculateEditFunctionDialog::newArgument() { } Argument *arg = argument_edit_dialog->editArgument(); if(arg) { - TQListViewItem *i = new KListViewItem(argumentsView, argumentsView->lastChild(), arg->name().c_str(), arg->printlong().c_str()); + TQListViewItem *i = new TDEListViewItem(argumentsView, argumentsView->lastChild(), arg->name().c_str(), arg->printlong().c_str()); argumentsItems[i] = arg; argumentsItemsEdited[i] = true; } @@ -477,7 +477,7 @@ QalculateEditSubFunctionsDialog::QalculateEditSubFunctionsDialog(TQWidget *paren TQVBoxLayout *layout = new TQVBoxLayout(this, marginHint(), spacingHint()); - subFunctionsView = new KListView(this); + subFunctionsView = new TDEListView(this); subFunctionsView->addColumn(i18n("Reference")); subFunctionsView->addColumn(i18n("Expression")); subFunctionsView->addColumn(i18n("Precalculate")); @@ -513,7 +513,7 @@ void QalculateEditSubFunctionsDialog::newSubFunction() { ExpressionName name; TQString str = "\\"; str += TQString::number(subFunctionsView->childCount() + 1); - TQListViewItem *i = new KListViewItem(subFunctionsView, subFunctionsView->lastChild(), str, "", i18n("Yes")); + TQListViewItem *i = new TDEListViewItem(subFunctionsView, subFunctionsView->lastChild(), str, "", i18n("Yes")); subFunctionsView->setSelected(i, true); tqApp->processEvents(); subFunctionsView->rename(i, 1); @@ -527,7 +527,7 @@ void QalculateEditSubFunctionsDialog::setSubFunctions(UserFunction *f, bool edit if(!edited && f && f->countSubfunctions() > 0) { TQListViewItem *i_prev = NULL; for(size_t index = 1; index <= f->countSubfunctions(); index++) { - TQListViewItem *i = new KListViewItem(subFunctionsView, i_prev); + TQListViewItem *i = new TDEListViewItem(subFunctionsView, i_prev); i_prev = i; TQString str = "\\"; str += TQString::number(index); diff --git a/src/qalculateeditfunctiondialog.h b/src/qalculateeditfunctiondialog.h index 2797ee1..5670ebc 100644 --- a/src/qalculateeditfunctiondialog.h +++ b/src/qalculateeditfunctiondialog.h @@ -33,7 +33,7 @@ class QalculateEditNamesDialog; class QalculateEditSubFunctionsDialog; class QalculateEditArgumentDialog; class MathFunction; -class KListView; +class TDEListView; class TQTextEdit; class Argument; class TQTabWidget; @@ -61,7 +61,7 @@ public: KLineEdit *conditionEdit, *nameEdit, *titleEdit; TQLabel *namesLabel; TQCheckBox *hideButton; - KListView *argumentsView; + TDEListView *argumentsView; TQTextEdit *descriptionEdit, *expressionEdit; TQPushButton *namesButton, *subFunctionsButton, *newArgumentButton, *editArgumentButton, *deleteArgumentButton; TQTabWidget *tabs; @@ -99,7 +99,7 @@ public: void setSubFunctions(UserFunction *f = NULL, bool edited = false); bool isEmpty(); - KListView* subFunctionsView; + TDEListView* subFunctionsView; TQPushButton* newButton; TQPushButton* deleteButton; TQPushButton* buttonClose; diff --git a/src/qalculateeditmatrixvectordialog.cpp b/src/qalculateeditmatrixvectordialog.cpp index f25c917..578f06b 100644 --- a/src/qalculateeditmatrixvectordialog.cpp +++ b/src/qalculateeditmatrixvectordialog.cpp @@ -26,17 +26,17 @@ #include <tqpushbutton.h> #include <kcombobox.h> #include <tqlabel.h> -#include <klocale.h> +#include <tdelocale.h> #include <tqvbox.h> #include <tqhbox.h> #include <tqcheckbox.h> -#include <kmessagebox.h> +#include <tdemessagebox.h> #include <tqspinbox.h> #include <tqlayout.h> #include <tqbuttongroup.h> #include <tqradiobutton.h> #include <tqtable.h> -#include <kapplication.h> +#include <tdeapplication.h> extern PrintOptions printops; extern EvaluationOptions evalops; @@ -125,7 +125,7 @@ QalculateEditMatrixVectorDialog::QalculateEditMatrixVectorDialog(TQWidget *paren QalculateEditMatrixVectorDialog::~QalculateEditMatrixVectorDialog() {} void QalculateEditMatrixVectorDialog::slotHelp() { - KApplication::kApplication()->invokeHelp("qalculate-vectors-matrices"); + TDEApplication::kApplication()->invokeHelp("qalculate-vectors-matrices"); } void QalculateEditMatrixVectorDialog::typeChanged(int i) { diff --git a/src/qalculateeditnamesdialog.cpp b/src/qalculateeditnamesdialog.cpp index 685ca10..4b3d9df 100644 --- a/src/qalculateeditnamesdialog.cpp +++ b/src/qalculateeditnamesdialog.cpp @@ -20,8 +20,8 @@ #include "qalculateeditnamesdialog.h" #include "qalculate_tde_utils.h" -#include <klocale.h> -#include <klistview.h> +#include <tdelocale.h> +#include <tdelistview.h> #include <kpushbutton.h> #include <tqlayout.h> #include <klineedit.h> @@ -37,7 +37,7 @@ QalculateEditNamesDialog::QalculateEditNamesDialog(int item_type, TQWidget *pare TQVBoxLayout *layout = new TQVBoxLayout(this, marginHint(), spacingHint()); - namesView = new KListView(this); + namesView = new TDEListView(this); namesView->addColumn(i18n("Name")); namesView->addColumn(i18n("Abbreviation")); namesView->setColumnAlignment(1, TQt::AlignCenter); @@ -85,7 +85,7 @@ QalculateEditNamesDialog::~QalculateEditNamesDialog() {} void QalculateEditNamesDialog::newName() { ExpressionName name; - TQListViewItem *i = new KListViewItem(namesView, namesView->lastChild(), "", i18n("No"), i18n("No"), i18n("No"), i18n("No"), i18n("No"), i18n("No"), i18n("No")); + TQListViewItem *i = new TDEListViewItem(namesView, namesView->lastChild(), "", i18n("No"), i18n("No"), i18n("No"), i18n("No"), i18n("No"), i18n("No"), i18n("No")); namesView->setSelected(i, true); tqApp->processEvents(); namesView->rename(i, 0); @@ -101,7 +101,7 @@ void QalculateEditNamesDialog::setNames(ExpressionItem *item, const TQString &na TQListViewItem *i_prev = NULL; for(size_t index = 1; index <= item->countNames(); index++) { const ExpressionName *ename = &item->getName(index); - TQListViewItem *i = new KListViewItem(namesView, i_prev); + TQListViewItem *i = new TDEListViewItem(namesView, i_prev); i_prev = i; if(ename->abbreviation) i->setText(1, i18n("Yes")); @@ -144,7 +144,7 @@ void QalculateEditNamesDialog::setNames(ExpressionItem *item, const TQString &na it.current()->setText(0, namestr); } else { ExpressionName ename(namestr.ascii()); - TQListViewItem *i = new KListViewItem(namesView, ename.name.c_str()); + TQListViewItem *i = new TDEListViewItem(namesView, ename.name.c_str()); if(ename.abbreviation) i->setText(1, i18n("Yes")); else diff --git a/src/qalculateeditnamesdialog.h b/src/qalculateeditnamesdialog.h index 3feb5c0..b66837b 100644 --- a/src/qalculateeditnamesdialog.h +++ b/src/qalculateeditnamesdialog.h @@ -23,7 +23,7 @@ #include <kdialog.h> class ExpressionItem; -class KListView; +class TDEListView; class TQPushButton; class TQLineEdit; class TQLabel; @@ -46,7 +46,7 @@ public: bool isEmpty(); void setNamesLE(TQLineEdit *entry, TQLabel *label); - KListView* namesView; + TDEListView* namesView; TQPushButton* newButton; TQPushButton* deleteButton; TQPushButton* buttonClose; diff --git a/src/qalculateeditunitdialog.cpp b/src/qalculateeditunitdialog.cpp index b5a8000..b678b10 100644 --- a/src/qalculateeditunitdialog.cpp +++ b/src/qalculateeditunitdialog.cpp @@ -26,15 +26,15 @@ #include <tqpushbutton.h> #include <kcombobox.h> #include <tqlabel.h> -#include <klocale.h> +#include <tdelocale.h> #include <tqvbox.h> #include <tqhbox.h> #include <tqcheckbox.h> -#include <kmessagebox.h> +#include <tdemessagebox.h> #include <tqgroupbox.h> #include <tqspinbox.h> #include <tqlayout.h> -#include <kapplication.h> +#include <tdeapplication.h> extern PrintOptions printops; extern EvaluationOptions evalops; @@ -134,7 +134,7 @@ QalculateEditUnitDialog::QalculateEditUnitDialog(TQWidget *parent, const char *n QalculateEditUnitDialog::~QalculateEditUnitDialog() {} void QalculateEditUnitDialog::slotHelp() { - KApplication::kApplication()->invokeHelp("qalculate-unit-creation"); + TDEApplication::kApplication()->invokeHelp("qalculate-unit-creation"); } void QalculateEditUnitDialog::slotOk() { diff --git a/src/qalculateeditunknownvariabledialog.cpp b/src/qalculateeditunknownvariabledialog.cpp index 9b089a0..15ca74a 100644 --- a/src/qalculateeditunknownvariabledialog.cpp +++ b/src/qalculateeditunknownvariabledialog.cpp @@ -26,13 +26,13 @@ #include <tqpushbutton.h> #include <kcombobox.h> #include <tqlabel.h> -#include <klocale.h> +#include <tdelocale.h> #include <tqvbox.h> #include <tqhbox.h> #include <tqcheckbox.h> -#include <kmessagebox.h> +#include <tdemessagebox.h> #include <tqlayout.h> -#include <kapplication.h> +#include <tdeapplication.h> extern PrintOptions printops; extern tree_struct variable_cats; @@ -120,7 +120,7 @@ void QalculateEditUnknownVariableDialog::signComboActivated(int i) { } void QalculateEditUnknownVariableDialog::slotHelp() { - KApplication::kApplication()->invokeHelp("qalculate-variable-creation"); + TDEApplication::kApplication()->invokeHelp("qalculate-variable-creation"); } void QalculateEditUnknownVariableDialog::slotOk() { diff --git a/src/qalculateeditvariabledialog.cpp b/src/qalculateeditvariabledialog.cpp index ed6d208..aab9af3 100644 --- a/src/qalculateeditvariabledialog.cpp +++ b/src/qalculateeditvariabledialog.cpp @@ -26,13 +26,13 @@ #include <tqpushbutton.h> #include <kcombobox.h> #include <tqlabel.h> -#include <klocale.h> +#include <tdelocale.h> #include <tqvbox.h> #include <tqhbox.h> #include <tqcheckbox.h> -#include <kmessagebox.h> +#include <tdemessagebox.h> #include <tqlayout.h> -#include <kapplication.h> +#include <tdeapplication.h> extern PrintOptions printops; extern EvaluationOptions evalops; @@ -90,7 +90,7 @@ QalculateEditVariableDialog::QalculateEditVariableDialog(TQWidget *parent, const QalculateEditVariableDialog::~QalculateEditVariableDialog() {} void QalculateEditVariableDialog::slotHelp() { - KApplication::kApplication()->invokeHelp("qalculate-variable-creation"); + TDEApplication::kApplication()->invokeHelp("qalculate-variable-creation"); } void QalculateEditVariableDialog::slotOk() { diff --git a/src/qalculateexportcsvdialog.cpp b/src/qalculateexportcsvdialog.cpp index 4ba91e2..9c73297 100644 --- a/src/qalculateexportcsvdialog.cpp +++ b/src/qalculateexportcsvdialog.cpp @@ -28,9 +28,9 @@ #include <tqpushbutton.h> #include <kcombobox.h> #include <tqbuttongroup.h> -#include <kmessagebox.h> -#include <klocale.h> -#include <kapplication.h> +#include <tdemessagebox.h> +#include <tdelocale.h> +#include <tdeapplication.h> extern MathStructure *mstruct; @@ -75,7 +75,7 @@ QalculateExportCSVDialog::QalculateExportCSVDialog(TQWidget *parent, const char QalculateExportCSVDialog::~QalculateExportCSVDialog() {} void QalculateExportCSVDialog::slotHelp() { - KApplication::kApplication()->invokeHelp("qalculate-import-export-csv"); + TDEApplication::kApplication()->invokeHelp("qalculate-import-export-csv"); } void QalculateExportCSVDialog::exportSourceChanged(int i) { diff --git a/src/qalculateexpressionedit.cpp b/src/qalculateexpressionedit.cpp index ab6a2cf..31ccecf 100644 --- a/src/qalculateexpressionedit.cpp +++ b/src/qalculateexpressionedit.cpp @@ -21,18 +21,18 @@ #include "qalculate_tde_utils.h" #include "kqalculate.h" -#include <kdeversion.h> +#include <tdeversion.h> #include <kcursor.h> #include <tqstyle.h> #include <tqpainter.h> #include <tqapplication.h> #include <tqfontmetrics.h> #include <kstringhandler.h> -#include <kpopupmenu.h> +#include <tdepopupmenu.h> #include <kxmlguifactory.h> #include <kxmlguiclient.h> -#include <kaction.h> -#include <klocale.h> +#include <tdeaction.h> +#include <tdelocale.h> #include <tqsimplerichtext.h> extern vector<mode_struct> modes; @@ -73,7 +73,7 @@ private: QalculateExpressionEdit::QalculateExpressionEdit(bool connected_to_main_win, TQWidget *parent, const char *name) : KLineEdit(parent, name) { qalculateCompletionBox = new QalculateExpressionEditCompletionBox(this); - qalculateCompletion = new KCompletion(); + qalculateCompletion = new TDECompletion(); setCompletionObject(qalculateCompletion); pos_before_completion = 0; @@ -83,7 +83,7 @@ QalculateExpressionEdit::QalculateExpressionEdit(bool connected_to_main_win, TQW dont_change_index = false; expression_history_index = -1; - setCompletionMode(KGlobalSettings::CompletionPopup); + setCompletionMode(TDEGlobalSettings::CompletionPopup); setKeyCompression(false); @@ -128,13 +128,13 @@ void QalculateExpressionEdit::cancelCompletion(const TQString &str) { } void QalculateExpressionEdit::enableCompletion() { - setCompletionMode(KGlobalSettings::CompletionPopup); + setCompletionMode(TDEGlobalSettings::CompletionPopup); } void QalculateExpressionEdit::disableCompletion() { - setCompletionMode(KGlobalSettings::CompletionNone); + setCompletionMode(TDEGlobalSettings::CompletionNone); } bool QalculateExpressionEdit::completionEnabled() const { - return completionMode() == KGlobalSettings::CompletionPopup; + return completionMode() == TDEGlobalSettings::CompletionPopup; } TQPopupMenu *QalculateExpressionEdit::createPopupMenu() { @@ -143,7 +143,7 @@ TQPopupMenu *QalculateExpressionEdit::createPopupMenu() { TQPopupMenu *menu = KLineEdit::createPopupMenu(); setCompletionObject(qalculateCompletion); menu->insertSeparator(); - if(completionMode() == KGlobalSettings::CompletionPopup) menu->insertItem(i18n("Disable Completion"), this, SLOT(disableCompletion())); + if(completionMode() == TDEGlobalSettings::CompletionPopup) menu->insertItem(i18n("Disable Completion"), this, SLOT(disableCompletion())); else menu->insertItem(i18n("Enable Completion"), this, SLOT(enableCompletion())); if(b_main) { menu->insertSeparator(); @@ -792,7 +792,7 @@ QalculateExpressionEditListBoxItem::QalculateExpressionEditListBoxItem(Expressio QalculateExpressionEditListBoxItem::~QalculateExpressionEditListBoxItem() { } -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 TQString rPixelSqueeze(const TQString& name, const TQFontMetrics& fontMetrics, uint maxPixels) { uint nameWidth = fontMetrics.width(name); @@ -838,7 +838,7 @@ void QalculateExpressionEditListBoxItem::paint(TQPainter *painter) { if(rt.widthUsed() > nameWidth - 1) { squeezedText = text(); if(italic_index > 0) squeezedText.truncate(italic_index); -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 squeezedText = rPixelSqueeze(squeezedText, listBox()->fontMetrics(), nameWidth); #else squeezedText = KStringHandler::rPixelSqueeze(squeezedText, listBox()->fontMetrics(), nameWidth); @@ -850,14 +850,14 @@ void QalculateExpressionEditListBoxItem::paint(TQPainter *painter) { rt.draw(painter, 1, 0, TQRect(0, 0, nameWidth - 1, itemHeight), cg, &painter->brush()); } } else { -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 squeezedText = rPixelSqueeze(text(), listBox()->fontMetrics(), nameWidth); #else squeezedText = KStringHandler::rPixelSqueeze(text(), listBox()->fontMetrics(), nameWidth); #endif painter->drawText(0, 0, nameWidth, itemHeight, TQt::AlignLeft | TQt::AlignVCenter, squeezedText); } -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 squeezedText = rPixelSqueeze(title, listBox()->fontMetrics(), titleWidth); #else squeezedText = KStringHandler::rPixelSqueeze(title, listBox()->fontMetrics(), titleWidth); @@ -888,7 +888,7 @@ bool QalculateExpressionEditListBoxItem::reuse(ExpressionItem *newItem) { return true; } -QalculateExpressionEditCompletionBox::QalculateExpressionEditCompletionBox(TQWidget *parent, const char *name) : KCompletionBox(parent, name) { +QalculateExpressionEditCompletionBox::QalculateExpressionEditCompletionBox(TQWidget *parent, const char *name) : TDECompletionBox(parent, name) { } QalculateExpressionEditCompletionBox::~QalculateExpressionEditCompletionBox() { } @@ -941,7 +941,7 @@ void QalculateExpressionEditCompletionBox::setItems(const TQValueVector<Expressi sort(); if(isVisible() && size().height() != sizeHint().height()) { -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 hide(); popup(); #else @@ -951,9 +951,9 @@ void QalculateExpressionEditCompletionBox::setItems(const TQValueVector<Expressi blockSignals(block); - // Trigger d->down_workaround = true within KCompletionBox + // Trigger d->down_workaround = true within TDECompletionBox TQStringList dummy; - KCompletionBox::insertItems(dummy, 1); + TDECompletionBox::insertItems(dummy, 1); } diff --git a/src/qalculateexpressionedit.h b/src/qalculateexpressionedit.h index 6dff6da..79545a6 100644 --- a/src/qalculateexpressionedit.h +++ b/src/qalculateexpressionedit.h @@ -21,7 +21,7 @@ #define QALCULATEEXPRESSIONEDIT_H #include <klineedit.h> -#include <kcompletionbox.h> +#include <tdecompletionbox.h> #include <kcompletion.h> #include <tqvaluevector.h> @@ -47,7 +47,7 @@ public: int expression_history_index; bool dont_change_index; QalculateExpressionEditCompletionBox *qalculateCompletionBox; - KCompletion *qalculateCompletion; + TDECompletion *qalculateCompletion; virtual bool eventFilter(TQObject *o, TQEvent *ev); void keyPressEvent(TQKeyEvent *e); @@ -81,7 +81,7 @@ protected: }; -class QalculateExpressionEditCompletionBox : public KCompletionBox { +class QalculateExpressionEditCompletionBox : public TDECompletionBox { Q_OBJECT diff --git a/src/qalculatefunctionsdialog.cpp b/src/qalculatefunctionsdialog.cpp index b511394..4bb53bf 100644 --- a/src/qalculatefunctionsdialog.cpp +++ b/src/qalculatefunctionsdialog.cpp @@ -24,12 +24,12 @@ #include <tqsplitter.h> #include <tqvbox.h> #include <tqhbox.h> -#include <klistview.h> -#include <kmessagebox.h> -#include <klocale.h> +#include <tdelistview.h> +#include <tdemessagebox.h> +#include <tdelocale.h> #include <tqlayout.h> #include <ktextbrowser.h> -#include <kapplication.h> +#include <tdeapplication.h> #include <kstdguiitem.h> extern tree_struct function_cats; @@ -51,11 +51,11 @@ QalculateFunctionsDialog::QalculateFunctionsDialog(TQWidget *parent, const char TQSplitter *splitter = new TQSplitter(TQt::Horizontal, this); leftLayout->addWidget(splitter); - categoryView = new KListView(splitter); + categoryView = new TDEListView(splitter); categoryView->addColumn(i18n("Category")); categoryView->setRootIsDecorated(false); - functionView = new KListView(splitter); + functionView = new TDEListView(splitter); functionView->addColumn(i18n("Function Name")); functionView->setRootIsDecorated(false); @@ -108,14 +108,14 @@ QalculateFunctionsDialog::~QalculateFunctionsDialog() { } void QalculateFunctionsDialog::slotHelp() { - KApplication::kApplication()->invokeHelp("qalculate-managers"); + TDEApplication::kApplication()->invokeHelp("qalculate-managers"); } void QalculateFunctionsDialog::updateFunctionTree() { functionItems.clear(); categoryItems.clear(); categoryView->clear(); - TQListViewItem *i = new KListViewItem(categoryView, i18n("All")), *i2; + TQListViewItem *i = new TDEListViewItem(categoryView, i18n("All")), *i2; categoryItems[i] = i18n("All"); i->setOpen(true); TQString str; @@ -133,7 +133,7 @@ void QalculateFunctionsDialog::updateFunctionTree() { while(item) { str += "/"; str += item->item.c_str(); - i = new KListViewItem(i2, item->item.c_str()); + i = new TDEListViewItem(i2, item->item.c_str()); i->setOpen(false); categoryItems[i] = str; if(str == selected_category) { @@ -162,7 +162,7 @@ void QalculateFunctionsDialog::updateFunctionTree() { } if(!function_cats.objects.empty()) { //add "Uncategorized" category if there are functions without category - i = new KListViewItem(categoryView, i18n("Uncategorized")); + i = new TDEListViewItem(categoryView, i18n("Uncategorized")); categoryItems[i] = i18n("Uncategorized"); if(selected_category == i18n("Uncategorized")) { categoryView->ensureItemVisible(i); @@ -171,7 +171,7 @@ void QalculateFunctionsDialog::updateFunctionTree() { } if(!ia_functions.empty()) { //add "Inactive" category if there are inactive functions - i = new KListViewItem(categoryView, i18n("Inactive")); + i = new TDEListViewItem(categoryView, i18n("Inactive")); categoryItems[i] = i18n("Inactive"); if(selected_category == i18n("Inactive")) { categoryView->ensureItemVisible(i); @@ -483,7 +483,7 @@ void QalculateFunctionsDialog::functionSelected() { } void QalculateFunctionsDialog::addFunctionTreeItem(MathFunction *f) { - TQListViewItem *i = new KListViewItem(functionView, f->title(true).c_str()); + TQListViewItem *i = new TDEListViewItem(functionView, f->title(true).c_str()); functionItems[i] = f; if(f == selected_function) { functionView->setSelected(i, true); diff --git a/src/qalculatefunctionsdialog.h b/src/qalculatefunctionsdialog.h index 99f3998..33d86ab 100644 --- a/src/qalculatefunctionsdialog.h +++ b/src/qalculatefunctionsdialog.h @@ -25,7 +25,7 @@ class MathFunction; class QalculateEditFunctionDialog; -class KListView; +class TDEListView; class TQListViewItem; class TQPushButton; class KTextBrowser; @@ -49,8 +49,8 @@ public: TQMap<TQListViewItem*, MathFunction*> functionItems; TQMap<TQListViewItem*, TQString> categoryItems; - KListView *categoryView; - KListView *functionView; + TDEListView *categoryView; + TDEListView *functionView; TQPushButton *newButton; TQPushButton *editButton; TQPushButton *deleteButton; diff --git a/src/qalculateimportcsvdialog.cpp b/src/qalculateimportcsvdialog.cpp index 71ea628..2a6e257 100644 --- a/src/qalculateimportcsvdialog.cpp +++ b/src/qalculateimportcsvdialog.cpp @@ -30,9 +30,9 @@ #include <kcombobox.h> #include <tqspinbox.h> #include <tqbuttongroup.h> -#include <kmessagebox.h> -#include <klocale.h> -#include <kapplication.h> +#include <tdemessagebox.h> +#include <tdelocale.h> +#include <tdeapplication.h> extern tree_struct variable_cats; @@ -100,7 +100,7 @@ QalculateImportCSVDialog::~QalculateImportCSVDialog() { } void QalculateImportCSVDialog::slotHelp() { - KApplication::kApplication()->invokeHelp("qalculate-import-export-csv"); + TDEApplication::kApplication()->invokeHelp("qalculate-import-export-csv"); } void QalculateImportCSVDialog::delimiterChanged(int i) { diff --git a/src/qalculateinsertfunctiondialog.cpp b/src/qalculateinsertfunctiondialog.cpp index 0260b2a..74c0777 100644 --- a/src/qalculateinsertfunctiondialog.cpp +++ b/src/qalculateinsertfunctiondialog.cpp @@ -25,7 +25,7 @@ #include <tqlabel.h> #include <tqgrid.h> #include <tqhbox.h> -#include <klocale.h> +#include <tdelocale.h> #include <tqspinbox.h> #include <kcombobox.h> #include <tqhbuttongroup.h> @@ -33,8 +33,8 @@ #include <tqstring.h> #include <tqpushbutton.h> #include <kdatepicker.h> -#include <kfiledialog.h> -#include <kdeversion.h> +#include <tdefiledialog.h> +#include <tdeversion.h> #include <kstdguiitem.h> #include "buttonwithindexsignal.h" #include "qalculateinsertmatrixvectordialog.h" @@ -45,11 +45,11 @@ extern EvaluationOptions evalops; QalculateInsertFunctionDialog::QalculateInsertFunctionDialog(MathFunction *f, TQWidget *parent, const TQString &selected_text, const char *name) : KDialogBase(parent, name, true, f->title(true).c_str(), Ok|Apply|Cancel, Ok) { -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 setButtonOKText(i18n("Insert")); setButtonApplyText(i18n("Execute")); #else -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 3 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 3 setButtonOK(KGuiItem(i18n("Insert"))); #else setButtonOK(KStdGuiItem::insert()); diff --git a/src/qalculateinsertmatrixvectordialog.cpp b/src/qalculateinsertmatrixvectordialog.cpp index 2dbb933..07835aa 100644 --- a/src/qalculateinsertmatrixvectordialog.cpp +++ b/src/qalculateinsertmatrixvectordialog.cpp @@ -26,17 +26,17 @@ #include <tqpushbutton.h> #include <kcombobox.h> #include <tqlabel.h> -#include <klocale.h> +#include <tdelocale.h> #include <tqvbox.h> #include <tqhbox.h> #include <tqcheckbox.h> -#include <kmessagebox.h> +#include <tdemessagebox.h> #include <tqspinbox.h> #include <tqlayout.h> #include <tqbuttongroup.h> #include <tqradiobutton.h> -#include <kapplication.h> -#include <kdeversion.h> +#include <tdeapplication.h> +#include <tdeversion.h> #include <kstdguiitem.h> extern PrintOptions printops; @@ -276,11 +276,11 @@ TQString QalculateInsertMatrixVectorDialog::editMatrixVector(const MathStructure } if(is_result) { -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 setButtonOKText(i18n("Insert")); setButtonCancelText(KStdGuiItem::close().text()); #else -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 3 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 3 setButtonOK(KGuiItem(i18n("Insert"))); #else setButtonOK(KStdGuiItem::insert()); @@ -295,7 +295,7 @@ TQString QalculateInsertMatrixVectorDialog::editMatrixVector(const MathStructure setCaption(i18n("Matrix Result")); } } else { -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 setButtonOKText(KStdGuiItem::ok().text()); setButtonCancelText(KStdGuiItem::cancel().text()); #else diff --git a/src/qalculateperiodictabledialog.cpp b/src/qalculateperiodictabledialog.cpp index 28611d6..914b97b 100644 --- a/src/qalculateperiodictabledialog.cpp +++ b/src/qalculateperiodictabledialog.cpp @@ -19,7 +19,7 @@ ***************************************************************************/ #include "qalculateperiodictabledialog.h" #include "qalculate_tde_utils.h" -#include <klocale.h> +#include <tdelocale.h> #include <tqlayout.h> #include <tqlabel.h> #include <tqtooltip.h> @@ -248,7 +248,7 @@ QalculateElementInfoDialog::QalculateElementInfoDialog(DataObject *element, TQWi str = "<b>"; str += dp->title().c_str(); str += ":"; str += "</b>"; new TQLabel(str, grid); new KActiveLabel(sval, grid); - button = new QalculateButtonWithData((void*) dp, TQIconSet(SmallIcon("editpaste")), "", grid); + button = new QalculateButtonWithData((void*) dp, TQIconSet(SmallIcon("edit-paste")), "", grid); TQObject::connect(button, SIGNAL(clickedWithData(void*)), SLOT(insertElementData(void*))); } } diff --git a/src/qalculateplotdialog.cpp b/src/qalculateplotdialog.cpp index ff4c155..6755bed 100644 --- a/src/qalculateplotdialog.cpp +++ b/src/qalculateplotdialog.cpp @@ -24,23 +24,23 @@ #include <kpushbutton.h> #include <kcombobox.h> #include <tqlabel.h> -#include <klocale.h> +#include <tdelocale.h> #include <tqcheckbox.h> #include <tqradiobutton.h> #include <tqbuttongroup.h> #include <tqspinbox.h> -#include <kmessagebox.h> +#include <tdemessagebox.h> #include <tqlayout.h> #include <ktextedit.h> -#include <klistview.h> -#include <kdeversion.h> -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#include <tdelistview.h> +#include <tdeversion.h> +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 #include <tqtabwidget.h> #else #include <ktabwidget.h> #endif -#include <kfiledialog.h> -#include <kapplication.h> +#include <tdefiledialog.h> +#include <tdeapplication.h> #include <kstdguiitem.h> extern PlotLegendPlacement default_plot_legend_placement; @@ -70,7 +70,7 @@ QalculatePlotDialog::QalculatePlotDialog(TQWidget *parent, const char *name) : K actionButton(User1)->setEnabled(false); -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 tabs = new TQTabWidget(this); #else tabs = new KTabWidget(this); @@ -149,7 +149,7 @@ QalculatePlotDialog::QalculatePlotDialog(TQWidget *parent, const char *name) : K hbox->addWidget(modifyButton); removeButton = new TQPushButton(i18n("Remove"), page1); hbox->addWidget(removeButton); - seriesView = new KListView(page1); + seriesView = new TDEListView(page1); seriesView->addColumn(i18n("Title")); seriesView->addColumn(i18n("Expression")); seriesView->setRootIsDecorated(false); @@ -315,7 +315,7 @@ QalculatePlotDialog::QalculatePlotDialog(TQWidget *parent, const char *name) : K QalculatePlotDialog::~QalculatePlotDialog() {} void QalculatePlotDialog::slotHelp() { - KApplication::kApplication()->invokeHelp("qalculate-plotting"); + TDEApplication::kApplication()->invokeHelp("qalculate-plotting"); } void QalculatePlotDialog::saveMode() { @@ -485,7 +485,7 @@ void QalculatePlotDialog::addSeries() { MathStructure *x_vector, *y_vector; generatePlotSeries(&x_vector, &y_vector, type, expression.ascii(), str_x.ascii()); rows = rowsButton->isChecked(); - TQListViewItem *i = new KListViewItem(seriesView, seriesView->lastChild(), title, expression); + TQListViewItem *i = new TDEListViewItem(seriesView, seriesView->lastChild(), title, expression); itemStyle[i] = styleCombo->currentItem(); itemSmoothing[i] = smoothingCombo->currentItem(); itemType[i] = type; diff --git a/src/qalculateplotdialog.h b/src/qalculateplotdialog.h index 7dbf8d8..4d8e9b8 100644 --- a/src/qalculateplotdialog.h +++ b/src/qalculateplotdialog.h @@ -32,7 +32,7 @@ class TQButtonGroup; class KComboBox; class TQPushButton; class TQTabWidget; -class KListView; +class TDEListView; class TQLabel; class TQListViewItem; class QalculateExpressionEdit; @@ -61,7 +61,7 @@ public: KComboBox *styleCombo, *smoothingCombo, *legendPlacementCombo; TQPushButton *addButton, *modifyButton, *removeButton, *applyRangeButton, *applyAppearanceButton; TQTabWidget *tabs; - KListView *seriesView; + TDEListView *seriesView; bool generatePlot(PlotParameters &pp, vector<MathStructure> &y_vectors, vector<MathStructure> &x_vectors, vector<PlotDataParameters*> &pdps); void generatePlotSeries(MathStructure **x_vector, MathStructure **y_vector, int type, string str, string str_x); diff --git a/src/qalculateprecisiondialog.cpp b/src/qalculateprecisiondialog.cpp index 7aae1d3..c11634f 100644 --- a/src/qalculateprecisiondialog.cpp +++ b/src/qalculateprecisiondialog.cpp @@ -21,16 +21,16 @@ #include <tqlabel.h> #include <tqspinbox.h> -#include <klocale.h> +#include <tdelocale.h> #include <tqhbox.h> #include <kguiitem.h> #include <tqlayout.h> #include <kpushbutton.h> -#include <kdeversion.h> +#include <tdeversion.h> QalculatePrecisionDialog::QalculatePrecisionDialog(TQWidget *parent, const char *name) : KDialogBase(parent, name, false, i18n("Precision"), Apply | Close, Close, true) { -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 setButtonApplyText(i18n("Recalculate")); #else setButtonApply(KGuiItem(i18n("Recalculate"))); diff --git a/src/qalculatepreferencesdialog.cpp b/src/qalculatepreferencesdialog.cpp index 02d9eee..b2dca67 100644 --- a/src/qalculatepreferencesdialog.cpp +++ b/src/qalculatepreferencesdialog.cpp @@ -20,17 +20,17 @@ #include "qalculatepreferencesdialog.h" #include "qalculate_tde_utils.h" -#include <klocale.h> +#include <tdelocale.h> #include <tqbuttongroup.h> #include <tqcheckbox.h> #include <tqlabel.h> #include <tqradiobutton.h> #include <tqtooltip.h> -#include <kdeversion.h> -#if KDE_VERSION_MAJOR > 3 || KDE_VERSION_MINOR > 1 -#include <kfontrequester.h> +#include <tdeversion.h> +#if TDE_VERSION_MAJOR > 3 || TDE_VERSION_MINOR > 1 +#include <tdefontrequester.h> #endif -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 #include <tqtabwidget.h> #else #include <ktabwidget.h> @@ -56,16 +56,16 @@ extern TQColor status_warning_color; extern int use_icon_buttons; extern bool rpn_keypad_only; -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 -#include <kfontdialog.h> +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 +#include <tdefontdialog.h> -class KFontRequester : public TQWidget +class TDEFontRequester : public TQWidget { Q_OBJECT public: - KFontRequester( TQWidget *parent=0L, const char *name=0L, + TDEFontRequester( TQWidget *parent=0L, const char *name=0L, bool onlyFixed=false ); TQFont font() const { return m_selFont; } @@ -90,7 +90,7 @@ class KFontRequester : public TQWidget }; -KFontRequester::KFontRequester( TQWidget *parent, const char *name, +TDEFontRequester::TDEFontRequester( TQWidget *parent, const char *name, bool onlyFixed ) : TQWidget( parent, name ), m_onlyFixed( onlyFixed ) { @@ -111,16 +111,16 @@ KFontRequester::KFontRequester( TQWidget *parent, const char *name, } -void KFontRequester::setFont( const TQFont &font, bool onlyFixed ) +void TDEFontRequester::setFont( const TQFont &font, bool onlyFixed ) { m_selFont = font; m_onlyFixed = onlyFixed; displaySampleText(); } -void KFontRequester::buttonClicked() +void TDEFontRequester::buttonClicked() { - int result = KFontDialog::getFont( m_selFont, m_onlyFixed, parentWidget() ); + int result = TDEFontDialog::getFont( m_selFont, m_onlyFixed, parentWidget() ); if ( result == KDialog::Accepted ) { @@ -128,7 +128,7 @@ void KFontRequester::buttonClicked() } } -void KFontRequester::displaySampleText() +void TDEFontRequester::displaySampleText() { m_sampleLabel->setFont( m_selFont ); @@ -146,7 +146,7 @@ void KFontRequester::displaySampleText() QalculatePreferencesDialog::QalculatePreferencesDialog(TQWidget *parent, const char *name) : KDialogBase(parent, name, true, i18n("Preferences"), Ok | Apply | Cancel, Ok, false) { -#if KDE_VERSION_MAJOR < 4 && KDE_VERSION_MINOR < 2 +#if TDE_VERSION_MAJOR < 4 && TDE_VERSION_MINOR < 2 TQTabWidget *tabs = new TQTabWidget(this); #else TQTabWidget *tabs = new KTabWidget(this); @@ -229,26 +229,26 @@ QalculatePreferencesDialog::QalculatePreferencesDialog(TQWidget *parent, const c vbox = new TQVBoxLayout(page2, spacingHint()); useCustomResultFontButton = new TQCheckBox(i18n("Custom result font"), page2); vbox->addWidget(useCustomResultFontButton); - resultFontEdit = new KFontRequester(page2); + resultFontEdit = new TDEFontRequester(page2); vbox->addWidget(resultFontEdit); useCustomExpressionFontButton = new TQCheckBox(i18n("Custom expression font"), page2); vbox->addWidget(useCustomExpressionFontButton); - expressionFontEdit = new KFontRequester(page2); + expressionFontEdit = new TDEFontRequester(page2); vbox->addWidget(expressionFontEdit); useCustomStatusFontButton = new TQCheckBox(i18n("Custom status font"), page2); vbox->addWidget(useCustomStatusFontButton); - statusFontEdit = new KFontRequester(page2); + statusFontEdit = new TDEFontRequester(page2); vbox->addWidget(statusFontEdit); grid = new TQGridLayout(vbox); grid->addWidget(new TQLabel(i18n("Status error color:"), page2), 0, 0); -#if KDE_VERSION_MAJOR == 3 && KDE_VERSION_MINOR < 1 +#if TDE_VERSION_MAJOR == 3 && TDE_VERSION_MINOR < 1 statusErrorColorButton = new KColorButton(page2); #else statusErrorColorButton = new KColorButton("red", "red", page2); #endif grid->addWidget(statusErrorColorButton, 0, 1); grid->addWidget(new TQLabel(i18n("Status warning color:"), page2), 1, 0); -#if KDE_VERSION_MAJOR == 3 && KDE_VERSION_MINOR < 1 +#if TDE_VERSION_MAJOR == 3 && TDE_VERSION_MINOR < 1 statusWarningColorButton = new KColorButton(page2); #else statusWarningColorButton = new KColorButton("blue", "blue", page2); diff --git a/src/qalculatepreferencesdialog.h b/src/qalculatepreferencesdialog.h index aca83d5..99b6f59 100644 --- a/src/qalculatepreferencesdialog.h +++ b/src/qalculatepreferencesdialog.h @@ -25,7 +25,7 @@ class TQCheckBox; class TQRadioButton; class TQLabel; -class KFontRequester; +class TDEFontRequester; class KColorButton; /** @@ -45,7 +45,7 @@ public: TQCheckBox *rpnKeypadOnlyButton, *systrayButton, *statusButton, *iconsButton, *fetchExchangeRatesButton, *saveModeButton, *saveDefsButton, *dotAsSeparatorButton, *unicodeButton, *lowerCaseButton, *lowerCaseEButton, *alternativeBasePrefixButton, *spellOutLogicalOperatorsButton, *useCustomResultFontButton, *useCustomExpressionFontButton, *useCustomStatusFontButton; TQRadioButton *dotButton, *exButton, *asteriskButton, *divisionSlashButton, *divisionButton, *slashButton; TQLabel *multiplicationLabel, *divisionLabel; - KFontRequester *resultFontEdit, *expressionFontEdit, *statusFontEdit; + TDEFontRequester *resultFontEdit, *expressionFontEdit, *statusFontEdit; KColorButton *statusErrorColorButton, *statusWarningColorButton; protected slots: diff --git a/src/qalculateresultdisplay.cpp b/src/qalculateresultdisplay.cpp index 39cafef..aea41fa 100644 --- a/src/qalculateresultdisplay.cpp +++ b/src/qalculateresultdisplay.cpp @@ -21,15 +21,15 @@ #include "qalculate_tde_utils.h" #include "kqalculate.h" -#include <kpopupmenu.h> +#include <tdepopupmenu.h> #include <kxmlguifactory.h> #include <kxmlguiclient.h> -#include <kaction.h> -#include <kmessagebox.h> +#include <tdeaction.h> +#include <tdemessagebox.h> #include <tqwhatsthis.h> #include <tqtooltip.h> -#include <klocale.h> -#include <kapplication.h> +#include <tdelocale.h> +#include <tdeapplication.h> #include <tqsimplerichtext.h> extern vector<mode_struct> modes; @@ -239,7 +239,7 @@ QalculateResultDisplay::QalculateResultDisplay(TQWidget *parent, const char *nam //connect(this, SIGNAL(anchorClicked(const TQString&, const TQString&)), this, SLOT(onAnchorClicked(const TQString&, const TQString&))); connect(this, SIGNAL(doubleClicked(int, int)), this, SLOT(onDoubleClicked(int, int))); if(kapp) { - connect(kapp, SIGNAL(kdisplayPaletteChanged()), this, SLOT(paletteChanged())); + connect(kapp, SIGNAL(tdedisplayPaletteChanged()), this, SLOT(paletteChanged())); } } diff --git a/src/qalculatesetbasedialog.cpp b/src/qalculatesetbasedialog.cpp index 4f29d7d..b67934a 100644 --- a/src/qalculatesetbasedialog.cpp +++ b/src/qalculatesetbasedialog.cpp @@ -22,7 +22,7 @@ #include <tqradiobutton.h> #include <tqvbuttongroup.h> #include <tqspinbox.h> -#include <klocale.h> +#include <tdelocale.h> #include <tqvbox.h> QalculateSetBaseDialog::QalculateSetBaseDialog(TQWidget *parent, const char *name) diff --git a/src/qalculateunitsdialog.cpp b/src/qalculateunitsdialog.cpp index 399e5d4..8710f2f 100644 --- a/src/qalculateunitsdialog.cpp +++ b/src/qalculateunitsdialog.cpp @@ -24,16 +24,16 @@ #include <tqsplitter.h> #include <tqvbox.h> #include <tqhbox.h> -#include <klistview.h> -#include <kmessagebox.h> -#include <klocale.h> +#include <tdelistview.h> +#include <tdemessagebox.h> +#include <tdelocale.h> #include <tqlayout.h> #include <kcombobox.h> #include <tqlabel.h> #include <tqgroupbox.h> #include <klineedit.h> #include <kiconloader.h> -#include <kapplication.h> +#include <tdeapplication.h> #include <kstdguiitem.h> extern tree_struct unit_cats; @@ -59,11 +59,11 @@ QalculateUnitsDialog::QalculateUnitsDialog(TQWidget *parent, const char *name) : splitter->setSizePolicy(TQSizePolicy::Expanding, TQSizePolicy::Expanding); leftLayout->addWidget(splitter); - categoryView = new KListView(splitter); + categoryView = new TDEListView(splitter); categoryView->addColumn(i18n("Category")); categoryView->setRootIsDecorated(false); - unitView = new KListView(splitter); + unitView = new TDEListView(splitter); unitView->addColumn(i18n("Unit")); unitView->addColumn(i18n("Names")); unitView->addColumn(i18n("Base")); @@ -139,7 +139,7 @@ QalculateUnitsDialog::~QalculateUnitsDialog() { } void QalculateUnitsDialog::slotHelp() { - KApplication::kApplication()->invokeHelp("qalculate-managers"); + TDEApplication::kApplication()->invokeHelp("qalculate-managers"); } void QalculateUnitsDialog::updateUnitTree() { @@ -147,7 +147,7 @@ void QalculateUnitsDialog::updateUnitTree() { comboItems.clear(); categoryItems.clear(); categoryView->clear(); - TQListViewItem *i = new KListViewItem(categoryView, i18n("All")), *i2; + TQListViewItem *i = new TDEListViewItem(categoryView, i18n("All")), *i2; categoryItems[i] = i18n("All"); i->setOpen(true); TQString str; @@ -165,7 +165,7 @@ void QalculateUnitsDialog::updateUnitTree() { while(item) { str += "/"; str += item->item.c_str(); - i = new KListViewItem(i2, item->item.c_str()); + i = new TDEListViewItem(i2, item->item.c_str()); i->setOpen(false); categoryItems[i] = str; if(str == selected_category) { @@ -194,7 +194,7 @@ void QalculateUnitsDialog::updateUnitTree() { } if(!unit_cats.objects.empty()) { //add "Uncategorized" category if there are units without category - i = new KListViewItem(categoryView, i18n("Uncategorized")); + i = new TDEListViewItem(categoryView, i18n("Uncategorized")); categoryItems[i] = i18n("Uncategorized"); if(selected_category == i18n("Uncategorized")) { categoryView->ensureItemVisible(i); @@ -203,7 +203,7 @@ void QalculateUnitsDialog::updateUnitTree() { } if(!ia_units.empty()) { //add "Inactive" category if there are inactive units - i = new KListViewItem(categoryView, i18n("Inactive")); + i = new TDEListViewItem(categoryView, i18n("Inactive")); categoryItems[i] = i18n("Inactive"); if(selected_category == i18n("Inactive")) { categoryView->ensureItemVisible(i); @@ -393,7 +393,7 @@ void QalculateUnitsDialog::addUnitTreeItem(Unit *u) { break; } } - TQListViewItem *i = new KListViewItem(unitView, u->title(true).c_str(), snames, sbase); + TQListViewItem *i = new TDEListViewItem(unitView, u->title(true).c_str(), snames, sbase); unitItems[i] = u; if(u == selected_unit) { unitView->setSelected(i, true); diff --git a/src/qalculateunitsdialog.h b/src/qalculateunitsdialog.h index a82713e..0dd8484 100644 --- a/src/qalculateunitsdialog.h +++ b/src/qalculateunitsdialog.h @@ -26,7 +26,7 @@ class Unit; class QalculateEditUnitDialog; -class KListView; +class TDEListView; class TQListViewItem; class TQPushButton; class KLineEdit; @@ -55,8 +55,8 @@ public: TQValueVector<Unit*> comboItems; TQGroupBox *convertGroup; - KListView *categoryView; - KListView *unitView; + TDEListView *categoryView; + TDEListView *unitView; TQPushButton *newButton; TQPushButton *editButton; TQPushButton *deleteButton; diff --git a/src/qalculatevariablesdialog.cpp b/src/qalculatevariablesdialog.cpp index 202cc9d..57e07ea 100644 --- a/src/qalculatevariablesdialog.cpp +++ b/src/qalculatevariablesdialog.cpp @@ -27,11 +27,11 @@ #include <tqsplitter.h> #include <tqvbox.h> #include <tqhbox.h> -#include <klistview.h> -#include <kmessagebox.h> -#include <klocale.h> +#include <tdelistview.h> +#include <tdemessagebox.h> +#include <tdelocale.h> #include <tqlayout.h> -#include <kapplication.h> +#include <tdeapplication.h> #include <kstdguiitem.h> extern tree_struct variable_cats; @@ -53,10 +53,10 @@ QalculateVariablesDialog::QalculateVariablesDialog(TQWidget *parent, const char TQSplitter *splitter = new TQSplitter(TQt::Horizontal, this); layout->addWidget(splitter); - categoryView = new KListView(splitter); + categoryView = new TDEListView(splitter); categoryView->addColumn(i18n("Category")); - variableView = new KListView(splitter); + variableView = new TDEListView(splitter); variableView->addColumn(i18n("Variable Name")); variableView->addColumn(i18n("Value")); variableView->setRootIsDecorated(false); @@ -106,14 +106,14 @@ QalculateVariablesDialog::QalculateVariablesDialog(TQWidget *parent, const char QalculateVariablesDialog::~QalculateVariablesDialog() {} void QalculateVariablesDialog::slotHelp() { - KApplication::kApplication()->invokeHelp("qalculate-managers"); + TDEApplication::kApplication()->invokeHelp("qalculate-managers"); } void QalculateVariablesDialog::updateVariableTree() { variableItems.clear(); categoryItems.clear(); categoryView->clear(); - TQListViewItem *i = new KListViewItem(categoryView, i18n("All")), *i2; + TQListViewItem *i = new TDEListViewItem(categoryView, i18n("All")), *i2; categoryItems[i] = i18n("All"); i->setOpen(true); TQString str; @@ -131,7 +131,7 @@ void QalculateVariablesDialog::updateVariableTree() { while(item) { str += "/"; str += item->item.c_str(); - i = new KListViewItem(i2, item->item.c_str()); + i = new TDEListViewItem(i2, item->item.c_str()); i->setOpen(false); categoryItems[i] = str; if(str == selected_category) { @@ -162,7 +162,7 @@ void QalculateVariablesDialog::updateVariableTree() { if(!variable_cats.objects.empty()) { //add "Uncategorized" category if there are variables without category - i = new KListViewItem(categoryView, i18n("Uncategorized")); + i = new TDEListViewItem(categoryView, i18n("Uncategorized")); categoryItems[i] = i18n("Uncategorized"); if(selected_category == i18n("Uncategorized")) { categoryView->ensureItemVisible(i); @@ -171,7 +171,7 @@ void QalculateVariablesDialog::updateVariableTree() { } if(!ia_variables.empty()) { //add "Inactive" category if there are inactive variables - i = new KListViewItem(categoryView, i18n("Inactive")); + i = new TDEListViewItem(categoryView, i18n("Inactive")); categoryItems[i] = i18n("Inactive"); if(selected_category == i18n("Inactive")) { categoryView->ensureItemVisible(i); @@ -440,7 +440,7 @@ void QalculateVariablesDialog::addVariableTreeItem(Variable *v) { value = i18n("default assumptions"); } } - TQListViewItem *i = new KListViewItem(variableView, v->title(true).c_str(), value); + TQListViewItem *i = new TDEListViewItem(variableView, v->title(true).c_str(), value); variableItems[i] = v; if(v == selected_variable) { variableView->setSelected(i, true); diff --git a/src/qalculatevariablesdialog.h b/src/qalculatevariablesdialog.h index 5fe3655..414bd7e 100644 --- a/src/qalculatevariablesdialog.h +++ b/src/qalculatevariablesdialog.h @@ -28,7 +28,7 @@ class QalculateEditVariableDialog; class QalculateEditMatrixVectorDialog; class QalculateEditUnknownVariableDialog; class QalculateExportCSVDialog; -class KListView; +class TDEListView; class TQListViewItem; class TQPushButton; @@ -54,8 +54,8 @@ public: TQMap<TQListViewItem*, Variable*> variableItems; TQMap<TQListViewItem*, TQString> categoryItems; - KListView *categoryView; - KListView *variableView; + TDEListView *categoryView; + TDEListView *variableView; TQPushButton *newButton; TQPushButton *editButton; TQPushButton *deleteButton; |