diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-25 05:28:35 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-25 05:28:35 +0000 |
commit | f008adb5a77e094eaf6abf3fc0f36958e66896a5 (patch) | |
tree | 8e9244c4d4957c36be81e15b566b4aa5ea26c982 /kspread/kspread_view.cc | |
parent | 1210f27b660efb7b37ff43ec68763e85a403471f (diff) | |
download | koffice-f008adb5a77e094eaf6abf3fc0f36958e66896a5.tar.gz koffice-f008adb5a77e094eaf6abf3fc0f36958e66896a5.zip |
TQt4 port koffice
This should enable compilation under both Qt3 and Qt4; fixes for any missed components will be forthcoming
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/koffice@1238284 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kspread/kspread_view.cc')
-rw-r--r-- | kspread/kspread_view.cc | 1470 |
1 files changed, 735 insertions, 735 deletions
diff --git a/kspread/kspread_view.cc b/kspread/kspread_view.cc index 74c68545..c0c21005 100644 --- a/kspread/kspread_view.cc +++ b/kspread/kspread_view.cc @@ -33,18 +33,18 @@ #include <stdlib.h> #include <time.h> -// Qt includes -#include <qbuffer.h> -#include <qclipboard.h> -#include <qcursor.h> -#include <qlayout.h> -#include <qpaintdevicemetrics.h> -#include <qregexp.h> -#include <qtimer.h> -#include <qtoolbutton.h> -#include <qsqldatabase.h> -#include <qlistview.h> -#include <qsizepolicy.h> +// TQt includes +#include <tqbuffer.h> +#include <tqclipboard.h> +#include <tqcursor.h> +#include <tqlayout.h> +#include <tqpaintdevicemetrics.h> +#include <tqregexp.h> +#include <tqtimer.h> +#include <tqtoolbutton.h> +#include <tqsqldatabase.h> +#include <tqlistview.h> +#include <tqsizepolicy.h> // KDE includes #include <dcopclient.h> @@ -167,25 +167,25 @@ public: Sheet* activeSheet; // GUI elements - QWidget *frame; - QFrame *toolWidget; + TQWidget *frame; + TQFrame *toolWidget; Canvas *canvas; VBorder *vBorderWidget; HBorder *hBorderWidget; - QScrollBar *horzScrollBar; - QScrollBar *vertScrollBar; + TQScrollBar *horzScrollBar; + TQScrollBar *vertScrollBar; KoTabBar *tabBar; KStatusBarLabel* calcLabel; // formulabar, consists of: - QHBoxLayout* formulaBarLayout; + TQHBoxLayout* formulaBarLayout; ComboboxLocationEditWidget *posWidget; - QButton* formulaButton; - QButton *okButton; - QButton *cancelButton; + TQButton* formulaButton; + TQButton *okButton; + TQButton *cancelButton; KSpread::EditWidget *editWidget; - QGridLayout* viewLayout; - QHBoxLayout* tabScrollBarLayout; + TQGridLayout* viewLayout; + TQHBoxLayout* tabScrollBarLayout; // all UI actions ViewActions* actions; @@ -202,24 +202,24 @@ public: // selection/marker Selection* selection; Selection* choice; - QMap<Sheet*, QPoint> savedAnchors; - QMap<Sheet*, QPoint> savedMarkers; - QMap<Sheet*, KoPoint> savedOffsets; + TQMap<Sheet*, TQPoint> savedAnchors; + TQMap<Sheet*, TQPoint> savedMarkers; + TQMap<Sheet*, KoPoint> savedOffsets; // Find and Replace context. We remember the options and // the strings used previously. long findOptions; - QStringList findStrings; - QStringList replaceStrings; + TQStringList findStrings; + TQStringList replaceStrings; FindOption::searchTypeValue typeValue; FindOption::searchDirectionValue directionValue; - // Current "find" operation - KFind* find; - KReplace* replace; + // Current "tqfind" operation + KFind* tqfind; + KReplace* tqreplace; int findLeftColumn; int findRightColumn; - QPoint findPos; - QPoint findEnd; + TQPoint findPos; + TQPoint findEnd; InsertHandler* insertHandler; @@ -227,18 +227,18 @@ public: KoCharSelectDia* specialCharDlg; // Holds a guarded pointer to the transformation toolbox. - QGuardedPtr<KoTransformToolBox> transformToolBox; + TQGuardedPtr<KoTransformToolBox> transformToolBox; // the last popup menu (may be 0). // Since only one popup menu can be opened at once, its pointer is stored here. // Delete the old one before you store a pointer to anotheron here. - QPopupMenu *popupMenu; + TQPopupMenu *popupMenu; int popupMenuFirstToolId; - QPopupMenu *popupRow; - QPopupMenu *popupColumn; - QPopupMenu* popupChild; // for embedded children - QPopupMenu* popupListChoose; // for list of choose + TQPopupMenu *popupRow; + TQPopupMenu *popupColumn; + TQPopupMenu* popupChild; // for embedded tqchildren + TQPopupMenu* popupListChoose; // for list of choose // the child for which the popup menu has been opened. Child* popupChildObject; @@ -258,7 +258,7 @@ public: unsigned int spellEndCellX; unsigned int spellEndCellY; bool spellCheckSelection; - QStringList replaceAll; + TQStringList replaceAll; } spell; struct @@ -270,23 +270,23 @@ public: // the tools struct ToolEntry { - QString command; + TQString command; KDataToolInfo info; }; - QPtrList<ToolEntry> toolList; + TQPtrList<ToolEntry> toolList; void initActions(); void adjustActions( bool mode ); void adjustActions( Sheet* sheet, Cell* cell ); void adjustWorkbookActions( bool mode ); void updateButton( Cell *cell, int column, int row); - QButton* newIconButton( const char *_file, bool _kbutton = false, QWidget *_parent = 0L ); + TQButton* newIconButton( const char *_file, bool _kbutton = false, TQWidget *_parent = 0L ); PropertyEditor *m_propertyEditor; // On timeout this will execute the status bar operation (e.g. SUM). // This is delayed to speed up the selection. - QTimer statusBarOpTimer; + TQTimer statusBarOpTimer; }; class ViewActions @@ -411,8 +411,8 @@ public: KAction* paste; KAction* specialPaste; KAction* insertCellCopy; - KAction* find; - KAction* replace; + KAction* tqfind; + KAction* tqreplace; // navigation KAction* gotoCell; @@ -468,541 +468,541 @@ void View::Private::initActions() // -- cell formatting actions -- actions->cellLayout = new KAction( i18n("Cell Format..."), "cell_layout", - Qt::CTRL+ Qt::ALT+ Qt::Key_F, view, SLOT( layoutDlg() ), ac, "cellLayout" ); + TQt::CTRL+ TQt::ALT+ TQt::Key_F, TQT_TQOBJECT(view), TQT_SLOT( tqlayoutDlg() ), ac, "cellLayout" ); actions->cellLayout->setToolTip( i18n("Set the cell formatting.") ); actions->actionExtraProperties = new KAction( i18n( "&Properties" ), "penbrush", 0, - view, SLOT( extraProperties() ), ac, "extra_properties" ); + TQT_TQOBJECT(view), TQT_SLOT( extraProperties() ), ac, "extra_properties" ); actions->defaultFormat = new KAction( i18n("Default"), - 0, view, SLOT( defaultSelection() ), ac, "default" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( defaultSelection() ), ac, "default" ); actions->defaultFormat->setToolTip( i18n("Resets to the default format.") ); actions->bold = new KToggleAction( i18n("Bold"), "text_bold", - Qt::CTRL+Qt::Key_B, ac, "bold"); - QObject::connect( actions->bold, SIGNAL( toggled( bool) ), - view, SLOT( bold( bool ) ) ); + TQt::CTRL+TQt::Key_B, ac, "bold"); + TQT_BASE_OBJECT_NAME::connect( actions->bold, TQT_SIGNAL( toggled( bool) ), + TQT_TQOBJECT(view), TQT_SLOT( bold( bool ) ) ); actions->italic = new KToggleAction( i18n("Italic"), "text_italic", - Qt::CTRL+Qt::Key_I, ac, "italic"); - QObject::connect( actions->italic, SIGNAL( toggled( bool) ), - view, SLOT( italic( bool ) ) ); + TQt::CTRL+TQt::Key_I, ac, "italic"); + TQT_BASE_OBJECT_NAME::connect( actions->italic, TQT_SIGNAL( toggled( bool) ), + TQT_TQOBJECT(view), TQT_SLOT( italic( bool ) ) ); actions->underline = new KToggleAction( i18n("Underline"), "text_under", - Qt::CTRL+Qt::Key_U, ac, "underline"); - QObject::connect( actions->underline, SIGNAL( toggled( bool) ), - view, SLOT( underline( bool ) ) ); + TQt::CTRL+TQt::Key_U, ac, "underline"); + TQT_BASE_OBJECT_NAME::connect( actions->underline, TQT_SIGNAL( toggled( bool) ), + TQT_TQOBJECT(view), TQT_SLOT( underline( bool ) ) ); actions->strikeOut = new KToggleAction( i18n("Strike Out"), "text_strike", 0, ac, "strikeout"); - QObject::connect( actions->strikeOut, SIGNAL( toggled( bool) ), - view, SLOT( strikeOut( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->strikeOut, TQT_SIGNAL( toggled( bool) ), + TQT_TQOBJECT(view), TQT_SLOT( strikeOut( bool ) ) ); actions->selectFont = new KFontAction( i18n("Select Font..."), 0, ac, "selectFont" ); - QObject::connect( actions->selectFont, SIGNAL( activated( const QString& ) ), - view, SLOT( fontSelected( const QString& ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->selectFont, TQT_SIGNAL( activated( const TQString& ) ), + TQT_TQOBJECT(view), TQT_SLOT( fontSelected( const TQString& ) ) ); actions->selectFontSize = new KFontSizeAction( i18n("Select Font Size"), 0, ac, "selectFontSize" ); - QObject::connect( actions->selectFontSize, SIGNAL( fontSizeChanged( int ) ), - view, SLOT( fontSizeSelected( int ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->selectFontSize, TQT_SIGNAL( fontSizeChanged( int ) ), + TQT_TQOBJECT(view), TQT_SLOT( fontSizeSelected( int ) ) ); actions->fontSizeUp = new KAction( i18n("Increase Font Size"), "fontsizeup", - 0, view, SLOT( increaseFontSize() ), ac, "increaseFontSize" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( increaseFontSize() ), ac, "increaseFontSize" ); actions->fontSizeDown = new KAction( i18n("Decrease Font Size"), "fontsizedown", - 0, view, SLOT( decreaseFontSize() ), ac, "decreaseFontSize" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( decreaseFontSize() ), ac, "decreaseFontSize" ); actions->textColor = new TKSelectColorAction( i18n("Text Color"), - TKSelectColorAction::TextColor, view, SLOT( changeTextColor() ), + TKSelectColorAction::TextColor, TQT_TQOBJECT(view), TQT_SLOT( changeTextColor() ), ac, "textColor",true ); - actions->textColor->setDefaultColor(QColor()); + actions->textColor->setDefaultColor(TQColor()); actions->alignLeft = new KToggleAction( i18n("Align Left"), "text_left", 0, ac, "left"); - QObject::connect( actions->alignLeft, SIGNAL( toggled( bool ) ), - view, SLOT( alignLeft( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->alignLeft, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( alignLeft( bool ) ) ); actions->alignLeft->setExclusiveGroup( "Align" ); actions->alignLeft->setToolTip(i18n("Left justify the cell contents.")); actions->alignCenter = new KToggleAction( i18n("Align Center"), "text_center", 0, ac, "center"); - QObject::connect( actions->alignCenter, SIGNAL( toggled( bool ) ), - view, SLOT( alignCenter( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->alignCenter, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( alignCenter( bool ) ) ); actions->alignCenter->setExclusiveGroup( "Align" ); actions->alignCenter->setToolTip(i18n("Center the cell contents.")); actions->alignRight = new KToggleAction( i18n("Align Right"), "text_right", 0, ac, "right"); - QObject::connect( actions->alignRight, SIGNAL( toggled( bool ) ), - view, SLOT( alignRight( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->alignRight, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( alignRight( bool ) ) ); actions->alignRight->setExclusiveGroup( "Align" ); actions->alignRight->setToolTip(i18n("Right justify the cell contents.")); actions->alignTop = new KToggleAction( i18n("Align Top"), "text_top", 0, ac, "top"); - QObject::connect( actions->alignTop, SIGNAL( toggled( bool ) ), - view, SLOT( alignTop( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->alignTop, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( alignTop( bool ) ) ); actions->alignTop->setExclusiveGroup( "Pos" ); actions->alignTop->setToolTip(i18n("Align cell contents along the top of the cell.")); actions->alignMiddle = new KToggleAction( i18n("Align Middle"), "middle", 0, ac, "middle"); - QObject::connect( actions->alignMiddle, SIGNAL( toggled( bool ) ), - view, SLOT( alignMiddle( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->alignMiddle, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( alignMiddle( bool ) ) ); actions->alignMiddle->setExclusiveGroup( "Pos" ); actions->alignMiddle->setToolTip(i18n("Align cell contents centered in the cell.")); actions->alignBottom = new KToggleAction( i18n("Align Bottom"), "text_bottom", 0, ac, "bottom"); - QObject::connect( actions->alignBottom, SIGNAL( toggled( bool ) ), - view, SLOT( alignBottom( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->alignBottom, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( alignBottom( bool ) ) ); actions->alignBottom->setExclusiveGroup( "Pos" ); actions->alignBottom->setToolTip(i18n("Align cell contents along the bottom of the cell.")); actions->wrapText = new KToggleAction( i18n("Wrap Text"), "multirow", 0, ac, "multiRow" ); - QObject::connect( actions->wrapText, SIGNAL( toggled( bool ) ), - view, SLOT( wrapText( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->wrapText, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( wrapText( bool ) ) ); actions->wrapText->setToolTip(i18n("Make the cell text wrap onto multiple lines.")); actions->verticalText = new KToggleAction( i18n("Vertical Text"),"vertical_text" , 0 ,ac, "verticaltext" ); - QObject::connect( actions->verticalText, SIGNAL( toggled( bool ) ), - view, SLOT( verticalText( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->verticalText, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( verticalText( bool ) ) ); actions->verticalText->setToolTip(i18n("Print cell contents vertically.")); actions->increaseIndent = new KAction( i18n("Increase Indent"), - QApplication::reverseLayout() ? "format_decreaseindent":"format_increaseindent", - 0, view, SLOT( increaseIndent() ), ac, "increaseindent" ); + TQApplication::reverseLayout() ? "format_decreaseindent":"format_increaseindent", + 0, TQT_TQOBJECT(view), TQT_SLOT( increaseIndent() ), ac, "increaseindent" ); actions->increaseIndent->setToolTip(i18n("Increase the indentation.")); actions->decreaseIndent = new KAction( i18n("Decrease Indent"), - QApplication::reverseLayout() ? "format_increaseindent" : "format_decreaseindent", - 0, view, SLOT( decreaseIndent() ), ac, "decreaseindent"); + TQApplication::reverseLayout() ? "format_increaseindent" : "format_decreaseindent", + 0, TQT_TQOBJECT(view), TQT_SLOT( decreaseIndent() ), ac, "decreaseindent"); actions->decreaseIndent->setToolTip(i18n("Decrease the indentation.")); actions->changeAngle = new KAction( i18n("Change Angle..."), - 0, view, SLOT( changeAngle() ), ac, "changeangle" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( changeAngle() ), ac, "changeangle" ); actions->changeAngle->setToolTip(i18n("Change the angle that cell contents are printed.")); actions->percent = new KToggleAction( i18n("Percent Format"), "percent", 0, ac, "percent"); - QObject::connect( actions->percent, SIGNAL( toggled( bool ) ), - view, SLOT( percent( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->percent, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( percent( bool ) ) ); actions->percent->setToolTip(i18n("Set the cell formatting to look like a percentage.")); actions->precplus = new KAction( i18n("Increase Precision"), "prec_plus", - 0, view, SLOT( precisionPlus() ), ac, "precplus"); + 0, TQT_TQOBJECT(view), TQT_SLOT( precisionPlus() ), ac, "precplus"); actions->precplus->setToolTip(i18n("Increase the decimal precision shown onscreen.")); actions->precminus = new KAction( i18n("Decrease Precision"), "prec_minus", - 0, view, SLOT( precisionMinus() ), ac, "precminus"); + 0, TQT_TQOBJECT(view), TQT_SLOT( precisionMinus() ), ac, "precminus"); actions->precminus->setToolTip(i18n("Decrease the decimal precision shown onscreen.")); actions->money = new KToggleAction( i18n("Money Format"), "money", 0, ac, "money"); - QObject::connect( actions->money, SIGNAL( toggled( bool ) ), - view, SLOT( moneyFormat( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->money, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( moneyFormat( bool ) ) ); actions->money->setToolTip(i18n("Set the cell formatting to look like your local currency.")); actions->upper = new KAction( i18n("Upper Case"), "fontsizeup", - 0, view, SLOT( upper() ), ac, "upper" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( upper() ), ac, "upper" ); actions->upper->setToolTip(i18n("Convert all letters to upper case.")); actions->lower = new KAction( i18n("Lower Case"), "fontsizedown", - 0, view, SLOT( lower() ), ac, "lower" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( lower() ), ac, "lower" ); actions->lower->setToolTip(i18n("Convert all letters to lower case.")); actions->firstLetterUpper = new KAction( i18n("Convert First Letter to Upper Case"), "first_letter_upper", - 0, view, SLOT( firstLetterUpper() ),ac, "firstletterupper" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( firstLetterUpper() ),ac, "firstletterupper" ); actions->firstLetterUpper->setToolTip(i18n("Capitalize the first letter.")); actions->bgColor = new TKSelectColorAction( i18n("Background Color"), TKSelectColorAction::FillColor, ac, "backgroundColor", true ); - QObject::connect(actions->bgColor, SIGNAL( activated() ), - view, SLOT( changeBackgroundColor() ) ); - actions->bgColor->setDefaultColor(QColor()); + TQT_BASE_OBJECT_NAME::connect(actions->bgColor, TQT_SIGNAL( activated() ), + TQT_TQOBJECT(view), TQT_SLOT( changeBackgroundColor() ) ); + actions->bgColor->setDefaultColor(TQColor()); actions->bgColor->setToolTip(i18n("Set the background color.")); actions->borderLeft = new KAction( i18n("Border Left"), "border_left", - 0, view, SLOT( borderLeft() ), ac, "borderLeft" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( borderLeft() ), ac, "borderLeft" ); actions->borderLeft->setToolTip(i18n("Set a left border to the selected area.")); actions->borderRight = new KAction( i18n("Border Right"), "border_right", - 0, view, SLOT( borderRight() ), ac, "borderRight" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( borderRight() ), ac, "borderRight" ); actions->borderRight->setToolTip(i18n("Set a right border to the selected area.")); actions->borderTop = new KAction( i18n("Border Top"), "border_top", - 0, view, SLOT( borderTop() ), ac, "borderTop" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( borderTop() ), ac, "borderTop" ); actions->borderTop->setToolTip(i18n("Set a top border to the selected area.")); actions->borderBottom = new KAction( i18n("Border Bottom"), "border_bottom", - 0, view, SLOT( borderBottom() ), ac, "borderBottom" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( borderBottom() ), ac, "borderBottom" ); actions->borderBottom->setToolTip(i18n("Set a bottom border to the selected area.")); actions->borderAll = new KAction( i18n("All Borders"), "border_all", - 0, view, SLOT( borderAll() ), ac, "borderAll" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( borderAll() ), ac, "borderAll" ); actions->borderAll->setToolTip(i18n("Set a border around all cells in the selected area.")); actions->borderRemove = new KAction( i18n("Remove Borders"), "border_remove", - 0, view, SLOT( borderRemove() ), ac, "borderRemove" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( borderRemove() ), ac, "borderRemove" ); actions->borderRemove->setToolTip(i18n("Remove all borders in the selected area.")); actions->borderOutline = new KAction( i18n("Border Outline"), ("border_outline"), - 0, view, SLOT( borderOutline() ), ac, "borderOutline" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( borderOutline() ), ac, "borderOutline" ); actions->borderOutline->setToolTip(i18n("Set a border to the outline of the selected area.")); actions->borderColor = new TKSelectColorAction( i18n("Border Color"), TKSelectColorAction::LineColor, ac, "borderColor" ); - QObject::connect( actions->borderColor, SIGNAL( activated() ), - view, SLOT( changeBorderColor() ) ); + TQT_BASE_OBJECT_NAME::connect( actions->borderColor, TQT_SIGNAL( activated() ), + TQT_TQOBJECT(view), TQT_SLOT( changeBorderColor() ) ); actions->borderColor->setToolTip( i18n( "Select a new border color." ) ); actions->selectStyle = new KSelectAction( i18n( "St&yle" ), 0, ac, "stylemenu" ); actions->selectStyle->setToolTip( i18n( "Apply a predefined style to the selected cells." ) ); - QObject::connect( actions->selectStyle, SIGNAL( activated( const QString & ) ), - view, SLOT( styleSelected( const QString & ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->selectStyle, TQT_SIGNAL( activated( const TQString & ) ), + TQT_TQOBJECT(view), TQT_SLOT( styleSelected( const TQString & ) ) ); actions->createStyle = new KAction( i18n( "Create Style From Cell..." ), - 0, view, SLOT( createStyleFromCell()), ac, "createStyle" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( createStyleFromCell()), ac, "createStyle" ); actions->createStyle->setToolTip( i18n( "Create a new style based on the currently selected cell." ) ); // -- cell operation actions -- actions->editCell = new KAction( i18n("Modify Cell"),"cell_edit", - Qt::CTRL+Qt::Key_M, view, SLOT( editCell() ), ac, "editCell" ); + TQt::CTRL+TQt::Key_M, TQT_TQOBJECT(view), TQT_SLOT( editCell() ), ac, "editCell" ); actions->editCell->setToolTip(i18n("Edit the highlighted cell.")); actions->insertCell = new KAction( i18n("Insert Cells..."), "insertcell", - 0, view, SLOT( slotInsert() ), ac, "insertCell" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( slotInsert() ), ac, "insertCell" ); actions->insertCell->setToolTip(i18n("Insert a blank cell into the spreadsheet.")); actions->removeCell = new KAction( i18n("Remove Cells..."), "removecell", - 0, view, SLOT( slotRemove() ), ac, "removeCell" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( slotRemove() ), ac, "removeCell" ); actions->removeCell->setToolTip(i18n("Removes the current cell from the spreadsheet.")); actions->deleteCell = new KAction( i18n("Delete"), "deletecell", - 0, view, SLOT( deleteSelection() ), ac, "delete" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( deleteSelection() ), ac, "delete" ); actions->deleteCell->setToolTip(i18n("Delete all contents and formatting of the current cell.")); actions->mergeCell = new KToolBarPopupAction( i18n("Merge Cells"),"mergecell", - 0, view, SLOT( mergeCell() ), ac, "mergecell" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( mergeCell() ), ac, "mergecell" ); actions->mergeCell->setToolTip(i18n("Merge the selected region.")); actions->mergeCell->plug( actions->mergeCell->popupMenu() ); - actions->mergeCellHorizontal = new KAction( i18n("Merge Cells Horizontally"),"mergecell-horizontal", - 0, view, SLOT( mergeCellHorizontal() ), ac, "mergecellHorizontal" ); + actions->mergeCellHorizontal = new KAction( i18n("Merge CellsQt::Horizontally"),"mergecell-horizontal", + 0, TQT_TQOBJECT(view), TQT_SLOT( mergeCellHorizontal() ), ac, "mergecellHorizontal" ); actions->mergeCellHorizontal->setToolTip(i18n("Merge the selected region horizontally.")); actions->mergeCellHorizontal->plug( actions->mergeCell->popupMenu() ); - actions->mergeCellVertical = new KAction( i18n("Merge Cells Vertically"),"mergecell-vertical", - 0, view, SLOT( mergeCellVertical() ), ac, "mergecellVertical" ); + actions->mergeCellVertical = new KAction( i18n("Merge CellsQt::Vertically"),"mergecell-vertical", + 0, TQT_TQOBJECT(view), TQT_SLOT( mergeCellVertical() ), ac, "mergecellVertical" ); actions->mergeCellVertical->setToolTip(i18n("Merge the selected region vertically.")); actions->mergeCellVertical->plug( actions->mergeCell->popupMenu() ); actions->dissociateCell = new KAction( i18n("Dissociate Cells"),"dissociatecell", - 0, view, SLOT( dissociateCell() ), ac, "dissociatecell" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( dissociateCell() ), ac, "dissociatecell" ); actions->dissociateCell->setToolTip(i18n("Unmerge the selected region.")); actions->clearText = new KAction( i18n("Text"), - 0, view, SLOT( clearTextSelection() ), ac, "cleartext" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( clearTextSelection() ), ac, "cleartext" ); actions->clearText->setToolTip(i18n("Remove the contents of the current cell.")); actions->conditional = new KAction( i18n("Conditional Cell Attributes..."), - 0, view, SLOT( conditional() ), ac, "conditional" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( conditional() ), ac, "conditional" ); actions->conditional->setToolTip(i18n("Set cell format based on certain conditions.")); actions->clearConditional = new KAction( i18n("Conditional Cell Attributes"), - 0, view, SLOT( clearConditionalSelection() ), ac, "clearconditional" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( clearConditionalSelection() ), ac, "clearconditional" ); actions->clearConditional->setToolTip(i18n("Remove the conditional cell formatting.")); actions->validity = new KAction( i18n("Validity..."), - 0, view, SLOT( validity() ), ac, "validity" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( validity() ), ac, "validity" ); actions->validity->setToolTip(i18n("Set tests to confirm cell data is valid.")); actions->clearValidity = new KAction( i18n("Validity"), - 0, view, SLOT( clearValiditySelection() ), ac, "clearvalidity" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( clearValiditySelection() ), ac, "clearvalidity" ); actions->clearValidity->setToolTip(i18n("Remove the validity tests on this cell.")); actions->addModifyComment = new KAction( i18n("&Add/Modify Comment..."),"comment", - 0, view, SLOT( addModifyComment() ), ac, "addmodifycomment" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( addModifyComment() ), ac, "addmodifycomment" ); actions->addModifyComment->setToolTip(i18n("Edit a comment for this cell.")); actions->removeComment = new KAction( i18n("&Remove Comment"),"removecomment", - 0, view, SLOT( removeComment() ), ac, "removecomment" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( removeComment() ), ac, "removecomment" ); actions->removeComment->setToolTip(i18n("Remove this cell's comment.")); actions->clearComment = new KAction( i18n("Comment"), - 0, view, SLOT( clearCommentSelection() ), ac, "clearcomment" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( clearCommentSelection() ), ac, "clearcomment" ); actions->clearComment->setToolTip(i18n("Remove this cell's comment.")); // -- column & row actions -- actions->resizeColumn = new KAction( i18n("Resize Column..."), "resizecol", - 0, view, SLOT( resizeColumn() ), ac, "resizeCol" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( resizeColumn() ), ac, "resizeCol" ); actions->resizeColumn->setToolTip(i18n("Change the width of a column.")); actions->insertColumn = new KAction( i18n("Insert Columns"), "insert_table_col", - 0, view, SLOT( insertColumn() ), ac, "insertColumn" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( insertColumn() ), ac, "insertColumn" ); actions->insertColumn->setToolTip(i18n("Inserts a new column into the spreadsheet.")); actions->deleteColumn = new KAction( i18n("Delete Columns"), "delete_table_col", - 0, view, SLOT( deleteColumn() ), ac, "deleteColumn" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( deleteColumn() ), ac, "deleteColumn" ); actions->deleteColumn->setToolTip(i18n("Removes a column from the spreadsheet.")); actions->hideColumn = new KAction( i18n("Hide Columns"), "hide_table_column", - 0, view, SLOT( hideColumn() ), ac, "hideColumn" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( hideColumn() ), ac, "hideColumn" ); actions->hideColumn->setToolTip(i18n("Hide the column from view.")); actions->showColumn = new KAction( i18n("Show Columns..."), "show_table_column", - 0, view, SLOT( showColumn() ), ac, "showColumn" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( showColumn() ), ac, "showColumn" ); actions->showColumn->setToolTip(i18n("Show hidden columns.")); actions->equalizeColumn = new KAction( i18n("Equalize Column"), "adjustcol", - 0, view, SLOT( equalizeColumn() ), ac, "equalizeCol" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( equalizeColumn() ), ac, "equalizeCol" ); actions->equalizeColumn->setToolTip(i18n("Resizes selected columns to be the same size.")); actions->showSelColumns = new KAction( i18n("Show Columns"), "show_sheet_column", - 0, view, SLOT( showSelColumns() ), ac, "showSelColumns" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( showSelColumns() ), ac, "showSelColumns" ); actions->showSelColumns->setToolTip(i18n("Show hidden columns in the selection.")); actions->showSelColumns->setEnabled(false); actions->resizeRow = new KAction( i18n("Resize Row..."), "resizerow", - 0, view, SLOT( resizeRow() ), ac, "resizeRow" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( resizeRow() ), ac, "resizeRow" ); actions->resizeRow->setToolTip(i18n("Change the height of a row.")); actions->insertRow = new KAction( i18n("Insert Rows"), "insert_table_row", - 0, view, SLOT( insertRow() ), ac, "insertRow" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( insertRow() ), ac, "insertRow" ); actions->insertRow->setToolTip(i18n("Inserts a new row into the spreadsheet.")); actions->deleteRow = new KAction( i18n("Delete Rows"), "delete_table_row", - 0, view, SLOT( deleteRow() ), ac, "deleteRow" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( deleteRow() ), ac, "deleteRow" ); actions->deleteRow->setToolTip(i18n("Removes a row from the spreadsheet.")); actions->hideRow = new KAction( i18n("Hide Rows"), "hide_table_row", - 0, view, SLOT( hideRow() ), ac, "hideRow" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( hideRow() ), ac, "hideRow" ); actions->hideRow->setToolTip(i18n("Hide a row from view.")); actions->showRow = new KAction( i18n("Show Rows..."), "show_table_row", - 0, view, SLOT( showRow() ), ac, "showRow" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( showRow() ), ac, "showRow" ); actions->showRow->setToolTip(i18n("Show hidden rows.")); actions->equalizeRow = new KAction( i18n("Equalize Row"), "adjustrow", - 0, view, SLOT( equalizeRow() ), ac, "equalizeRow" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( equalizeRow() ), ac, "equalizeRow" ); actions->equalizeRow->setToolTip(i18n("Resizes selected rows to be the same size.")); actions->showSelRows = new KAction( i18n("Show Rows"), "show_table_row", - 0, view, SLOT( showSelRows() ), ac, "showSelRows" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( showSelRows() ), ac, "showSelRows" ); actions->showSelRows->setEnabled(false); actions->showSelRows->setToolTip(i18n("Show hidden rows in the selection.")); actions->adjust = new KAction( i18n("Adjust Row && Column"), - 0, view, SLOT( adjust() ), ac, "adjust" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( adjust() ), ac, "adjust" ); actions->adjust->setToolTip(i18n("Adjusts row/column size so that the contents will fit.")); // -- sheet/workbook actions -- actions->sheetProperties = new KAction( i18n("Sheet Properties"), - 0, view, SLOT( sheetProperties() ), ac, "sheetProperties" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( sheetProperties() ), ac, "sheetProperties" ); actions->sheetProperties->setToolTip(i18n("Modify current sheet's properties.")); actions->insertSheet = new KAction( i18n("Insert Sheet"),"inserttable", - 0, view, SLOT( insertSheet() ), ac, "insertSheet" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( insertSheet() ), ac, "insertSheet" ); actions->insertSheet->setToolTip(i18n("Insert a new sheet.")); // same action as insertSheet, but without 'insert' in the caption actions->menuInsertSheet = new KAction( i18n("&Sheet"),"inserttable", - 0, view, SLOT( insertSheet() ), ac, "menuInsertSheet" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( insertSheet() ), ac, "menuInsertSheet" ); actions->menuInsertSheet->setToolTip(i18n("Insert a new sheet.")); actions->removeSheet = new KAction( i18n("Remove Sheet"), "delete_table", - 0, view, SLOT( removeSheet() ), ac, "removeSheet" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( removeSheet() ), ac, "removeSheet" ); actions->removeSheet->setToolTip(i18n("Remove the active sheet.")); actions->renameSheet=new KAction( i18n("Rename Sheet..."), - 0, view, SLOT( slotRename() ), ac, "renameSheet" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( slotRename() ), ac, "renameSheet" ); actions->renameSheet->setToolTip(i18n("Rename the active sheet.")); actions->showSheet = new KAction(i18n("Show Sheet..."), - 0, view, SLOT( showSheet()), ac, "showSheet" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( showSheet()), ac, "showSheet" ); actions->showSheet->setToolTip(i18n("Show a hidden sheet.")); actions->hideSheet = new KAction(i18n("Hide Sheet"), - 0, view, SLOT( hideSheet() ), ac, "hideSheet" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( hideSheet() ), ac, "hideSheet" ); actions->hideSheet->setToolTip(i18n("Hide the active sheet.")); actions->autoFormat = new KAction( i18n("AutoFormat..."), - 0, view, SLOT( sheetFormat() ), ac, "sheetFormat" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( sheetFormat() ), ac, "sheetFormat" ); actions->autoFormat->setToolTip(i18n("Set the worksheet formatting.")); actions->areaName = new KAction( i18n("Area Name..."), - 0, view, SLOT( setAreaName() ), ac, "areaname" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( setAreaName() ), ac, "areaname" ); actions->areaName->setToolTip(i18n("Set a name for a region of the spreadsheet.")); actions->showArea = new KAction( i18n("Show Area..."), - 0, view, SLOT( showAreaName() ), ac, "showArea" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( showAreaName() ), ac, "showArea" ); actions->showArea->setToolTip(i18n("Display a named area.")); actions->insertFunction = new KAction( i18n("&Function..."), "funct", - 0, view, SLOT( insertMathExpr() ), ac, "insertMathExpr" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( insertMathExpr() ), ac, "insertMathExpr" ); actions->insertFunction->setToolTip(i18n("Insert math expression.")); actions->insertSeries = new KAction( i18n("&Series..."),"series", - 0, view, SLOT( insertSeries() ), ac, "series"); + 0, TQT_TQOBJECT(view), TQT_SLOT( insertSeries() ), ac, "series"); actions->insertSeries ->setToolTip(i18n("Insert a series.")); actions->insertLink = new KAction( i18n("&Link..."), "insert_link", - 0, view, SLOT( insertHyperlink() ), ac, "insertHyperlink" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( insertHyperlink() ), ac, "insertHyperlink" ); actions->insertLink->setToolTip(i18n("Insert an Internet hyperlink.")); actions->removeLink = new KAction( i18n("&Remove Link"), - 0, view, SLOT( removeHyperlink() ), ac, "removeHyperlink" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( removeHyperlink() ), ac, "removeHyperlink" ); actions->removeLink->setToolTip(i18n("Remove a link.")); actions->insertSpecialChar = new KAction( i18n( "S&pecial Character..." ), "char", - view, SLOT( insertSpecialChar() ), ac, "insertSpecialChar" ); + TQT_TQOBJECT(view), TQT_SLOT( insertSpecialChar() ), ac, "insertSpecialChar" ); actions->insertSpecialChar->setToolTip( i18n( "Insert one or more symbols or letters not found on the keyboard." ) ); actions->insertPart = new KoPartSelectAction( i18n("&Object"), "frame_query", - view, SLOT( insertObject() ), ac, "insertPart"); + TQT_TQOBJECT(view), TQT_SLOT( insertObject() ), ac, "insertPart"); actions->insertPart->setToolTip(i18n("Insert an object from another program.")); actions->insertChartFrame = new KToggleAction( i18n("&Chart"), "insert_chart", - 0, view, SLOT( insertChart() ), ac, "insertChart" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( insertChart() ), ac, "insertChart" ); actions->insertChartFrame->setToolTip(i18n("Insert a chart.")); actions->insertPicture = new KAction( i18n("&Picture"), - 0, view, SLOT( insertPicture() ), ac, "insertPicture" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( insertPicture() ), ac, "insertPicture" ); actions->insertPicture->setToolTip(i18n("Insert a picture.")); -#ifndef QT_NO_SQL +#ifndef TQT_NO_SQL actions->insertFromDatabase = new KAction( i18n("From &Database..."), - 0, view, SLOT( insertFromDatabase() ), ac, "insertFromDatabase"); + 0, TQT_TQOBJECT(view), TQT_SLOT( insertFromDatabase() ), ac, "insertFromDatabase"); actions->insertFromDatabase->setToolTip(i18n("Insert data from a SQL database.")); #endif actions->insertFromTextfile = new KAction( i18n("From &Text File..."), - 0, view, SLOT( insertFromTextfile() ), ac, "insertFromTextfile"); + 0, TQT_TQOBJECT(view), TQT_SLOT( insertFromTextfile() ), ac, "insertFromTextfile"); actions->insertFromTextfile->setToolTip(i18n("Insert data from a text file to the current cursor position/selection.")); actions->insertFromClipboard = new KAction( i18n("From &Clipboard..."), - 0, view, SLOT( insertFromClipboard() ), ac, "insertFromClipboard"); + 0, TQT_TQOBJECT(view), TQT_SLOT( insertFromClipboard() ), ac, "insertFromClipboard"); actions->insertFromClipboard->setToolTip(i18n("Insert CSV data from the clipboard to the current cursor position/selection.")); // actions->transform = new KAction( i18n("Transform Object..."), "rotate", -// 0, view, SLOT( transformPart() ), ac, "transform" ); +// 0, TQT_TQOBJECT(view), TQT_SLOT( transformPart() ), ac, "transform" ); // actions->transform->setToolTip(i18n("Rotate the contents of the cell.")); // actions->transform->setEnabled( false ); actions->sort = new KAction( i18n("&Sort..."), - 0, view, SLOT( sort() ), ac, "sort" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( sort() ), ac, "sort" ); actions->sort->setToolTip(i18n("Sort a group of cells.")); actions->sortDec = new KAction( i18n("Sort &Decreasing"), "sort_decrease", - 0, view, SLOT( sortDec() ), ac, "sortDec" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( sortDec() ), ac, "sortDec" ); actions->sortDec->setToolTip(i18n("Sort a group of cells in decreasing (last to first) order.")); actions->sortInc = new KAction( i18n("Sort &Increasing"), "sort_incr", - 0, view, SLOT( sortInc() ), ac, "sortInc" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( sortInc() ), ac, "sortInc" ); actions->sortInc->setToolTip(i18n("Sort a group of cells in ascending (first to last) order.")); actions->paperLayout = new KAction( i18n("Page Layout..."), - 0, view, SLOT( paperLayoutDlg() ), ac, "paperLayout" ); - actions->paperLayout->setToolTip(i18n("Specify the layout of the spreadsheet for a printout.")); + 0, TQT_TQOBJECT(view), TQT_SLOT( paperLayoutDlg() ), ac, "paperLayout" ); + actions->paperLayout->setToolTip(i18n("Specify the tqlayout of the spreadsheet for a printout.")); actions->definePrintRange = new KAction( i18n("Define Print Range"), - 0, view, SLOT( definePrintRange() ), ac, "definePrintRange" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( definePrintRange() ), ac, "definePrintRange" ); actions->definePrintRange->setToolTip(i18n("Define the print range in the current sheet.")); actions->resetPrintRange = new KAction( i18n("Reset Print Range"), - 0, view, SLOT( resetPrintRange() ), ac, "resetPrintRange" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( resetPrintRange() ), ac, "resetPrintRange" ); actions->definePrintRange->setToolTip(i18n("Define the print range in the current sheet.")); actions->showPageBorders = new KToggleAction( i18n("Show Page Borders"), 0, ac, "showPageBorders"); actions->showPageBorders->setCheckedState(i18n("Hide Page Borders")); - QObject::connect( actions->showPageBorders, SIGNAL( toggled( bool ) ), - view, SLOT( togglePageBorders( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->showPageBorders, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( togglePageBorders( bool ) ) ); actions->showPageBorders->setToolTip( i18n( "Show on the spreadsheet where the page borders will be." ) ); actions->recalcWorksheet = new KAction( i18n("Recalculate Sheet"), - Qt::SHIFT + Qt::Key_F9, view, SLOT( recalcWorkSheet() ), ac, "RecalcWorkSheet" ); + TQt::SHIFT + TQt::Key_F9, TQT_TQOBJECT(view), TQT_SLOT( recalcWorkSheet() ), ac, "RecalcWorkSheet" ); actions->recalcWorksheet->setToolTip(i18n("Recalculate the value of every cell in the current worksheet.")); actions->recalcWorkbook = new KAction( i18n("Recalculate Document"), - Qt::Key_F9, view, SLOT( recalcWorkBook() ), ac, "RecalcWorkBook" ); + TQt::Key_F9, TQT_TQOBJECT(view), TQT_SLOT( recalcWorkBook() ), ac, "RecalcWorkBook" ); actions->recalcWorkbook->setToolTip(i18n("Recalculate the value of every cell in all worksheets.")); actions->protectSheet = new KToggleAction( i18n( "Protect &Sheet..." ), 0, ac, "protectSheet" ); actions->protectSheet->setToolTip( i18n( "Protect the sheet from being modified." ) ); - QObject::connect( actions->protectSheet, SIGNAL( toggled( bool ) ), - view, SLOT( toggleProtectSheet( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->protectSheet, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( toggleProtectSheet( bool ) ) ); actions->protectDoc = new KToggleAction( i18n( "Protect &Document..." ), 0, ac, "protectDoc" ); actions->protectDoc->setToolTip( i18n( "Protect the document from being modified." ) ); - QObject::connect( actions->protectDoc, SIGNAL( toggled( bool ) ), - view, SLOT( toggleProtectDoc( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->protectDoc, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( toggleProtectDoc( bool ) ) ); // -- editing actions -- - actions->copy = KStdAction::copy( view, SLOT( copySelection() ), ac, "copy" ); + actions->copy = KStdAction::copy( TQT_TQOBJECT(view), TQT_SLOT( copySelection() ), ac, "copy" ); actions->copy->setToolTip(i18n("Copy the cell object to the clipboard.")); - actions->paste = KStdAction::paste( view, SLOT( paste() ), ac, "paste" ); + actions->paste = KStdAction::paste( TQT_TQOBJECT(view), TQT_SLOT( paste() ), ac, "paste" ); actions->paste->setToolTip(i18n("Paste the contents of the clipboard at the cursor.")); - actions->cut = KStdAction::cut( view, SLOT( cutSelection() ), ac, "cut" ); + actions->cut = KStdAction::cut( TQT_TQOBJECT(view), TQT_SLOT( cutSelection() ), ac, "cut" ); actions->cut->setToolTip(i18n("Move the cell object to the clipboard.")); actions->specialPaste = new KAction( i18n("Special Paste..."), "special_paste", - 0, view, SLOT( specialPaste() ), ac, "specialPaste" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( specialPaste() ), ac, "specialPaste" ); actions->specialPaste->setToolTip(i18n("Paste the contents of the clipboard with special options.")); actions->insertCellCopy = new KAction( i18n("Paste with Insertion"), "insertcellcopy", - 0, view, SLOT( slotInsertCellCopy() ), ac, "insertCellCopy" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( slotInsertCellCopy() ), ac, "insertCellCopy" ); actions->insertCellCopy->setToolTip(i18n("Inserts a cell from the clipboard into the spreadsheet.")); - actions->find = KStdAction::find( view, SLOT(find()), ac ); - /*actions->findNext =*/ KStdAction::findNext( view, SLOT( findNext() ), ac ); - /*actions->findPrevious =*/ KStdAction::findPrev( view, SLOT( findPrevious() ), ac ); + actions->tqfind = KStdAction::find( TQT_TQOBJECT(view), TQT_SLOT(tqfind()), ac ); + /*actions->findNext =*/ KStdAction::findNext( TQT_TQOBJECT(view), TQT_SLOT( findNext() ), ac ); + /*actions->findPrevious =*/ KStdAction::findPrev( TQT_TQOBJECT(view), TQT_SLOT( findPrevious() ), ac ); - actions->replace = KStdAction::replace( view, SLOT(replace()), ac ); + actions->tqreplace = KStdAction::replace( TQT_TQOBJECT(view), TQT_SLOT(tqreplace()), ac ); actions->fillRight = new KAction( i18n( "&Right" ), 0, - 0, view, SLOT( fillRight() ), ac, "fillRight" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( fillRight() ), ac, "fillRight" ); actions->fillLeft = new KAction( i18n( "&Left" ), 0, - 0, view, SLOT( fillLeft() ), ac, "fillLeft" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( fillLeft() ), ac, "fillLeft" ); actions->fillDown = new KAction( i18n( "&Down" ), 0, - 0, view, SLOT( fillDown() ), ac, "fillDown" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( fillDown() ), ac, "fillDown" ); actions->fillUp = new KAction( i18n( "&Up" ), 0, - 0, view, SLOT( fillUp() ), ac, "fillUp" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( fillUp() ), ac, "fillUp" ); // -- misc actions -- actions->styleDialog = new KAction( i18n( "Style Manager" ), - 0, view, SLOT( styleDialog() ), ac, "styles" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( styleDialog() ), ac, "styles" ); actions->styleDialog->setToolTip( i18n( "Edit and organize cell styles." ) ); actions->autoSum = new KAction( i18n("Autosum"), "black_sum", - 0, view, SLOT( autoSum() ), ac, "autoSum" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( autoSum() ), ac, "autoSum" ); actions->autoSum->setToolTip(i18n("Insert the 'sum' function")); - actions->spellChecking = KStdAction::spelling( view, SLOT( extraSpelling() ), + actions->spellChecking = KStdAction::spelling( TQT_TQOBJECT(view), TQT_SLOT( extraSpelling() ), ac, "spelling" ); actions->spellChecking->setToolTip(i18n("Check the spelling.")); actions->formulaSelection = new KSelectAction(i18n("Formula Selection"), 0, ac, "formulaSelection"); actions->formulaSelection->setToolTip(i18n("Insert a function.")); - QStringList lst; + TQStringList lst; lst.append( "SUM"); lst.append( "AVERAGE"); lst.append( "IF"); @@ -1013,146 +1013,146 @@ void View::Private::initActions() ((KSelectAction*) actions->formulaSelection)->setItems( lst ); actions->formulaSelection->setComboWidth( 80 ); actions->formulaSelection->setCurrentItem(0); - QObject::connect( actions->formulaSelection, SIGNAL( activated( const QString& ) ), - view, SLOT( formulaSelection( const QString& ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->formulaSelection, TQT_SIGNAL( activated( const TQString& ) ), + TQT_TQOBJECT(view), TQT_SLOT( formulaSelection( const TQString& ) ) ); actions->viewZoom = new KoZoomAction( i18n( "Zoom" ), "viewmag", 0, ac, "view_zoom" ); - QObject::connect( actions->viewZoom, SIGNAL( zoomChanged( const QString & ) ), - view, SLOT( viewZoom( const QString & ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->viewZoom, TQT_SIGNAL( zoomChanged( const TQString & ) ), + TQT_TQOBJECT(view), TQT_SLOT( viewZoom( const TQString & ) ) ); actions->consolidate = new KAction( i18n("&Consolidate..."), - 0, view, SLOT( consolidate() ), ac, "consolidate" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( consolidate() ), ac, "consolidate" ); actions->consolidate->setToolTip(i18n("Create a region of summary data from a group of similar regions.")); actions->goalSeek = new KAction( i18n("&Goal Seek..."), - 0, view, SLOT( goalSeek() ), ac, "goalSeek" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( goalSeek() ), ac, "goalSeek" ); actions->goalSeek->setToolTip( i18n("Repeating calculation to find a specific value.") ); actions->subTotals = new KAction( i18n("&Subtotals..."), - 0, view, SLOT( subtotals() ), ac, "subtotals" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( subtotals() ), ac, "subtotals" ); actions->subTotals->setToolTip( i18n("Create different kind of subtotals to a list or database.") ); actions->textToColumns = new KAction( i18n("&Text to Columns..."), - 0, view, SLOT( textToColumns() ), ac, "textToColumns" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( textToColumns() ), ac, "textToColumns" ); actions->textToColumns->setToolTip( i18n("Expand the content of cells to multiple columns.") ); actions->multipleOperations = new KAction( i18n("&Multiple Operations..."), - 0, view, SLOT( multipleOperations() ), ac, "multipleOperations" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( multipleOperations() ), ac, "multipleOperations" ); actions->multipleOperations->setToolTip( i18n("Apply the same formula to various cells using different values for the parameter.") ); actions->createTemplate = new KAction( i18n( "&Create Template From Document..." ), - 0, view, SLOT( createTemplate() ), ac, "createTemplate" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( createTemplate() ), ac, "createTemplate" ); actions->customList = new KAction( i18n("Custom Lists..."), - 0, view, SLOT( sortList() ), ac, "sortlist" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( sortList() ), ac, "sortlist" ); actions->customList->setToolTip(i18n("Create custom lists for sorting or autofill.")); // -- navigation actions -- actions->gotoCell = new KAction( i18n("Goto Cell..."),"goto", - 0, view, SLOT( gotoCell() ), ac, "gotoCell" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( gotoCell() ), ac, "gotoCell" ); actions->gotoCell->setToolTip(i18n("Move to a particular cell.")); actions->nextSheet = new KAction( i18n("Next Sheet"), "forward", - Qt::CTRL+Qt::Key_PageDown, view, SLOT( nextSheet() ), ac, "nextSheet"); + TQt::CTRL+TQt::Key_PageDown, TQT_TQOBJECT(view), TQT_SLOT( nextSheet() ), ac, "nextSheet"); actions->nextSheet->setToolTip(i18n("Move to the next sheet.")); actions->prevSheet = new KAction( i18n("Previous Sheet"), "back", - Qt::CTRL+Qt::Key_PageUp, view, SLOT( previousSheet() ), ac, "previousSheet"); + TQt::CTRL+TQt::Key_PageUp, TQT_TQOBJECT(view), TQT_SLOT( previousSheet() ), ac, "previousSheet"); actions->prevSheet->setToolTip(i18n("Move to the previous sheet.")); actions->firstSheet = new KAction( i18n("First Sheet"), "start", - 0, view, SLOT( firstSheet() ), ac, "firstSheet"); + 0, TQT_TQOBJECT(view), TQT_SLOT( firstSheet() ), ac, "firstSheet"); actions->firstSheet->setToolTip(i18n("Move to the first sheet.")); actions->lastSheet = new KAction( i18n("Last Sheet"), "finish", - 0, view, SLOT( lastSheet() ), ac, "lastSheet"); + 0, TQT_TQOBJECT(view), TQT_SLOT( lastSheet() ), ac, "lastSheet"); actions->lastSheet->setToolTip(i18n("Move to the last sheet.")); // -- settings actions -- - actions->showStatusBar = new KToggleAction( i18n("Show Status Bar"), + actions->showStatusBar = new KToggleAction( i18n("Show tqStatus Bar"), 0, ac, "showStatusBar" ); - actions->showStatusBar->setCheckedState(i18n("Hide Status Bar")); - QObject::connect( actions->showStatusBar, SIGNAL( toggled( bool ) ), - view, SLOT( showStatusBar( bool ) ) ); + actions->showStatusBar->setCheckedState(i18n("Hide tqStatus Bar")); + TQT_BASE_OBJECT_NAME::connect( actions->showStatusBar, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( showStatusBar( bool ) ) ); actions->showStatusBar->setToolTip(i18n("Show the status bar.")); actions->showTabBar = new KToggleAction( i18n("Show Tab Bar"), 0, ac, "showTabBar" ); actions->showTabBar->setCheckedState(i18n("Hide Tab Bar")); - QObject::connect( actions->showTabBar, SIGNAL( toggled( bool ) ), - view, SLOT( showTabBar( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->showTabBar, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( showTabBar( bool ) ) ); actions->showTabBar->setToolTip(i18n("Show the tab bar.")); actions->showFormulaBar = new KToggleAction( i18n("Show Formula Bar"), 0, ac, "showFormulaBar" ); actions->showFormulaBar->setCheckedState(i18n("Hide Formula Bar")); - QObject::connect( actions->showFormulaBar, SIGNAL( toggled( bool ) ), - view, SLOT( showFormulaBar( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->showFormulaBar, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( showFormulaBar( bool ) ) ); actions->showFormulaBar->setToolTip(i18n("Show the formula bar.")); actions->preference = new KAction( i18n("Configure KSpread..."),"configure", - 0, view, SLOT( preference() ), ac, "preference" ); + 0, TQT_TQOBJECT(view), TQT_SLOT( preference() ), ac, "preference" ); actions->preference->setToolTip(i18n("Set various KSpread options.")); // -- running calculation actions -- actions->calcNone = new KToggleAction( i18n("None"), 0, ac, "menu_none"); - QObject::connect( actions->calcNone, SIGNAL( toggled( bool ) ), - view, SLOT( menuCalc( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->calcNone, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( menuCalc( bool ) ) ); actions->calcNone->setExclusiveGroup( "Calc" ); actions->calcNone->setToolTip(i18n("No calculation")); actions->calcSum = new KToggleAction( i18n("Sum"), 0, ac, "menu_sum"); - QObject::connect( actions->calcSum, SIGNAL( toggled( bool ) ), - view, SLOT( menuCalc( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->calcSum, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( menuCalc( bool ) ) ); actions->calcSum->setExclusiveGroup( "Calc" ); actions->calcSum->setToolTip(i18n("Calculate using sum.")); actions->calcMin = new KToggleAction( i18n("Min"), 0, ac, "menu_min"); - QObject::connect( actions->calcMin, SIGNAL( toggled( bool ) ), - view, SLOT( menuCalc( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->calcMin, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( menuCalc( bool ) ) ); actions->calcMin->setExclusiveGroup( "Calc" ); actions->calcMin->setToolTip(i18n("Calculate using minimum.")); actions->calcMax = new KToggleAction( i18n("Max"), 0, ac, "menu_max"); - QObject::connect( actions->calcMax, SIGNAL( toggled( bool ) ), - view, SLOT( menuCalc( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->calcMax, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( menuCalc( bool ) ) ); actions->calcMax->setExclusiveGroup( "Calc" ); actions->calcMax->setToolTip(i18n("Calculate using maximum.")); actions->calcAverage = new KToggleAction( i18n("Average"), 0, ac, "menu_average"); - QObject::connect( actions->calcAverage, SIGNAL( toggled( bool ) ), - view, SLOT( menuCalc( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->calcAverage, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( menuCalc( bool ) ) ); actions->calcAverage->setExclusiveGroup( "Calc" ); actions->calcAverage->setToolTip(i18n("Calculate using average.")); actions->calcCount = new KToggleAction( i18n("Count"), 0, ac, "menu_count"); - QObject::connect( actions->calcCount, SIGNAL( toggled( bool ) ), - view, SLOT( menuCalc( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->calcCount, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( menuCalc( bool ) ) ); actions->calcCount->setExclusiveGroup( "Calc" ); actions->calcCount->setToolTip(i18n("Calculate using the count.")); actions->calcCountA = new KToggleAction( i18n("CountA"), 0, ac, "menu_counta"); - QObject::connect( actions->calcCountA, SIGNAL( toggled( bool ) ), - view, SLOT( menuCalc( bool ) ) ); + TQT_BASE_OBJECT_NAME::connect( actions->calcCountA, TQT_SIGNAL( toggled( bool ) ), + TQT_TQOBJECT(view), TQT_SLOT( menuCalc( bool ) ) ); actions->calcCountA->setExclusiveGroup( "Calc" ); actions->calcCountA->setToolTip(i18n("Calculate using the countA.")); // -- special action, only for developers -- actions->internalTests = new KAction( i18n("Run Internal Tests..."), "internalTests", - Qt::CTRL+ Qt::SHIFT + Qt::Key_T, view, SLOT( runInternalTests() ), ac, "internalTests" ); + TQt::CTRL+ TQt::SHIFT + TQt::Key_T, TQT_TQOBJECT(view), TQT_SLOT( runInternalTests() ), ac, "internalTests" ); actions->inspector = new KAction( i18n("Run Inspector..."), "inspector", - Qt::CTRL+ Qt::SHIFT + Qt::Key_I, view, SLOT( runInspector() ), ac, "inspector" ); + TQt::CTRL+ TQt::SHIFT + TQt::Key_I, TQT_TQOBJECT(view), TQT_SLOT( runInspector() ), ac, "inspector" ); m_propertyEditor = 0; } void View::Private::adjustActions( bool mode ) { - actions->replace->setEnabled( mode ); + actions->tqreplace->setEnabled( mode ); actions->insertSeries->setEnabled( mode ); actions->insertLink->setEnabled( mode ); actions->insertSpecialChar->setEnabled( mode ); @@ -1342,12 +1342,12 @@ void View::Private::updateButton( Cell *cell, int column, int row) toolbarLock = true; // workaround for bug #59291 (crash upon starting from template) - // certain Qt and Fontconfig combination fail miserably if can not + // certain TQt and Fontconfig combination fail miserably if can not // find the font name (e.g. not installed in the system) - QStringList fontList; + TQStringList fontList; KFontChooser::getFontList( fontList, 0 ); - QString fontFamily = cell->format()->textFontFamily( column,row ); - for ( QStringList::Iterator it = fontList.begin(); it != fontList.end(); ++it ) + TQString fontFamily = cell->format()->textFontFamily( column,row ); + for ( TQStringList::Iterator it = fontList.begin(); it != fontList.end(); ++it ) if ((*it).lower() == fontFamily.lower()) { actions->selectFont->setFont( fontFamily ); @@ -1387,24 +1387,24 @@ void View::Private::updateButton( Cell *cell, int column, int row) adjustActions( activeSheet, cell ); } -QButton* View::Private::newIconButton( const char *_file, bool _kbutton, QWidget *_parent ) +TQButton* View::Private::newIconButton( const char *_file, bool _kbutton, TQWidget *_parent ) { if ( _parent == 0L ) _parent = view; if ( !_kbutton ) { - QPushButton* pb = new QPushButton( _parent ); + TQPushButton* pb = new TQPushButton( _parent ); pb->setIconSet( SmallIconSet(_file) ); return pb; } else { - QToolButton* pb = new QToolButton( _parent ); + TQToolButton* pb = new TQToolButton( _parent ); pb->setIconSet( SmallIconSet(_file) ); return pb; } } -KPSheetSelectPage::KPSheetSelectPage( QWidget *parent ) -: KPrintDialogPage(parent), +KPSheetSelectPage::KPSheetSelectPage( TQWidget *tqparent ) +: KPrintDialogPage(tqparent), gui(new SheetSelectWidget(this)) { setTitle(gui->caption()); @@ -1414,25 +1414,25 @@ KPSheetSelectPage::KPSheetSelectPage( QWidget *parent ) gui->ListViewSelected->setSorting(-1); //connect buttons - connect(gui->ButtonSelectAll,SIGNAL(clicked()),this,SLOT(selectAll())); - connect(gui->ButtonSelect,SIGNAL(clicked()),this,SLOT(select())); - connect(gui->ButtonRemove,SIGNAL(clicked()),this,SLOT(remove())); - connect(gui->ButtonRemoveAll,SIGNAL(clicked()),this,SLOT(removeAll())); + connect(gui->ButtonSelectAll,TQT_SIGNAL(clicked()),this,TQT_SLOT(selectAll())); + connect(gui->ButtonSelect,TQT_SIGNAL(clicked()),this,TQT_SLOT(select())); + connect(gui->ButtonRemove,TQT_SIGNAL(clicked()),this,TQT_SLOT(remove())); + connect(gui->ButtonRemoveAll,TQT_SIGNAL(clicked()),this,TQT_SLOT(removeAll())); - connect(gui->ButtonMoveTop,SIGNAL(clicked()),this,SLOT(moveTop())); - connect(gui->ButtonMoveUp,SIGNAL(clicked()),this,SLOT(moveUp())); - connect(gui->ButtonMoveDown,SIGNAL(clicked()),this,SLOT(moveDown())); - connect(gui->ButtonMoveBottom,SIGNAL(clicked()),this,SLOT(moveBottom())); + connect(gui->ButtonMoveTop,TQT_SIGNAL(clicked()),this,TQT_SLOT(moveTop())); + connect(gui->ButtonMoveUp,TQT_SIGNAL(clicked()),this,TQT_SLOT(moveUp())); + connect(gui->ButtonMoveDown,TQT_SIGNAL(clicked()),this,TQT_SLOT(moveDown())); + connect(gui->ButtonMoveBottom,TQT_SIGNAL(clicked()),this,TQT_SLOT(moveBottom())); } // KPSheetSelectPage::~KPSheetSelectPage() // { // } -void KPSheetSelectPage::getOptions( QMap<QString,QString>& opts, bool /*incldef*/ ) +void KPSheetSelectPage::getOptions( TQMap<TQString,TQString>& opts, bool /*incldef*/ ) { - QStringList sheetlist = this->selectedSheets(); - QStringList::iterator it; + TQStringList sheetlist = this->selectedSheets(); + TQStringList::iterator it; unsigned int i = 0; for (it = sheetlist.begin(); it != sheetlist.end(); ++it, i++) { @@ -1440,16 +1440,16 @@ void KPSheetSelectPage::getOptions( QMap<QString,QString>& opts, bool /*incldef* } } -void KPSheetSelectPage::setOptions( const QMap<QString,QString>& opts ) +void KPSheetSelectPage::setOptions( const TQMap<TQString,TQString>& opts ) { unsigned int i = 0; - QStringList sheetlist; - while (opts.contains(printOptionForIndex(i))) + TQStringList sheetlist; + while (opts.tqcontains(printOptionForIndex(i))) { sheetlist.prepend(opts[printOptionForIndex(i++)]); } - QStringList::iterator it; + TQStringList::iterator it; for (it = sheetlist.begin(); it != sheetlist.end(); ++it) { kdDebug() << " adding sheet to list of printed sheets: " << *it << endl; @@ -1457,7 +1457,7 @@ void KPSheetSelectPage::setOptions( const QMap<QString,QString>& opts ) } } -bool KPSheetSelectPage::isValid(QString& /*msg*/) +bool KPSheetSelectPage::isValid(TQString& /*msg*/) { // we print the activeSheet() by default if no sheet is selected, // so we return true in any case @@ -1471,28 +1471,28 @@ bool KPSheetSelectPage::isValid(QString& /*msg*/) return true; } -QString KPSheetSelectPage::printOptionForIndex(unsigned int index) +TQString KPSheetSelectPage::printOptionForIndex(unsigned int index) { - return QString("sheetprintorder%1").arg(index); + return TQString("sheetprintorder%1").tqarg(index); } -void KPSheetSelectPage::prependAvailableSheet(const QString& sheetname) +void KPSheetSelectPage::prependAvailableSheet(const TQString& sheetname) { Q_ASSERT(gui); - new QListViewItem(gui->ListViewAvailable,sheetname); + new TQListViewItem(gui->ListViewAvailable,sheetname); } -void KPSheetSelectPage::prependSelectedSheet(const QString& sheetname) +void KPSheetSelectPage::prependSelectedSheet(const TQString& sheetname) { Q_ASSERT(gui); - new QListViewItem(gui->ListViewSelected,sheetname); + new TQListViewItem(gui->ListViewSelected,sheetname); } -QStringList KPSheetSelectPage::selectedSheets() +TQStringList KPSheetSelectPage::selectedSheets() { Q_ASSERT(gui); - QStringList list; - QListViewItem* item = gui->ListViewSelected->firstChild(); + TQStringList list; + TQListViewItem* item = gui->ListViewSelected->firstChild(); while (item) { list.append(item->text(0)); @@ -1501,12 +1501,12 @@ QStringList KPSheetSelectPage::selectedSheets() return list; } -QStringList KPSheetSelectPage::selectedSheets(KPrinter &prt) +TQStringList KPSheetSelectPage::selectedSheets(KPrinter &prt) { - QStringList list; + TQStringList list; unsigned int index; - const QMap<QString,QString>& options = prt.options(); - for (index = 0; options.contains(KPSheetSelectPage::printOptionForIndex(index)); index++) + const TQMap<TQString,TQString>& options = prt.options(); + for (index = 0; options.tqcontains(KPSheetSelectPage::printOptionForIndex(index)); index++) { list.append(options[KPSheetSelectPage::printOptionForIndex(index)]); } @@ -1522,14 +1522,14 @@ void KPSheetSelectPage::selectAll() { //we have to add all the stuff in reverse order // because inserted items (prependSelectedSheet) are prepended - QStringList list; - QListViewItem* item = gui->ListViewAvailable->firstChild(); + TQStringList list; + TQListViewItem* item = gui->ListViewAvailable->firstChild(); while (item) { list.prepend(item->text(0)); item = item->nextSibling(); } - QStringList::iterator it; + TQStringList::iterator it; for (it = list.begin(); it != list.end(); ++it) { this->prependSelectedSheet(*it); @@ -1540,15 +1540,15 @@ void KPSheetSelectPage::select() { //we have to add all the stuff in reverse order // because inserted items (prependSelectedSheet) are prepended - QStringList list; - QListViewItem* item = gui->ListViewAvailable->firstChild(); + TQStringList list; + TQListViewItem* item = gui->ListViewAvailable->firstChild(); while (item) { if (item->isSelected()) list.prepend(item->text(0)); item = item->nextSibling(); } - QStringList::iterator it; + TQStringList::iterator it; for (it = list.begin(); it != list.end(); ++it) { this->prependSelectedSheet(*it); @@ -1557,8 +1557,8 @@ void KPSheetSelectPage::select() void KPSheetSelectPage::remove() { - QListViewItem* item = gui->ListViewSelected->firstChild(); - QListViewItem* nextitem = NULL; + TQListViewItem* item = gui->ListViewSelected->firstChild(); + TQListViewItem* nextitem = NULL; while (item) { nextitem = item->nextSibling(); @@ -1579,9 +1579,9 @@ void KPSheetSelectPage::moveTop() //this creates a temporary new list (selected first, then rest) // which replaces the existing one, to avoid the need of an additional sort column - QValueList<QListViewItem*> newlist; - QListViewItem* item = gui->ListViewSelected->firstChild(); - QListViewItem* nextitem = NULL; + TQValueList<TQListViewItem*> newlist; + TQListViewItem* item = gui->ListViewSelected->firstChild(); + TQListViewItem* nextitem = NULL; // kdDebug() << "Filling new list with selected items first" << endl; while (item) { @@ -1609,7 +1609,7 @@ void KPSheetSelectPage::moveTop() // kdDebug() << "Refill the view with the correctly ordered list" << endl; //the view is empty now, refill in correct order (reversed!!) - QValueList<QListViewItem*>::iterator it; + TQValueList<TQListViewItem*>::iterator it; for (it = newlist.begin(); it != newlist.end(); ++it) { // kdDebug() << " adding " << (*it)->text(0) << endl; @@ -1622,9 +1622,9 @@ void KPSheetSelectPage::moveUp() //this creates a temporary new list // which replaces the existing one, to avoid the need of an additional sort column - QValueList<QListViewItem*> newlist; - QListViewItem* item = gui->ListViewSelected->firstChild(); - QListViewItem* nextitem = NULL; + TQValueList<TQListViewItem*> newlist; + TQListViewItem* item = gui->ListViewSelected->firstChild(); + TQListViewItem* nextitem = NULL; while (item) { nextitem = item->nextSibling(); @@ -1632,7 +1632,7 @@ void KPSheetSelectPage::moveUp() { while (nextitem && nextitem->isSelected()) { - QListViewItem* nextnextitem = nextitem->nextSibling(); + TQListViewItem* nextnextitem = nextitem->nextSibling(); newlist.prepend(nextitem); gui->ListViewSelected->takeItem(nextitem); nextitem = nextnextitem; @@ -1646,7 +1646,7 @@ void KPSheetSelectPage::moveUp() // kdDebug() << "Refill the view with the correctly ordered list" << endl; //the view is empty now, refill in correct order (reversed!!) - QValueList<QListViewItem*>::iterator it; + TQValueList<TQListViewItem*>::iterator it; for (it = newlist.begin(); it != newlist.end(); ++it) { // kdDebug() << " adding " << (*it)->text(0) << endl; @@ -1656,7 +1656,7 @@ void KPSheetSelectPage::moveUp() void KPSheetSelectPage::moveDown() { - QListViewItem* item = gui->ListViewSelected->lastItem(); + TQListViewItem* item = gui->ListViewSelected->lastItem(); // while (item) // { // nextitem = item->nextSibling(); @@ -1671,7 +1671,7 @@ void KPSheetSelectPage::moveDown() { while (item && !item->isSelected() && item->itemAbove() && item->itemAbove()->isSelected()) { - QListViewItem* tempitem = item->itemAbove(); + TQListViewItem* tempitem = item->itemAbove(); tempitem->moveItem(item); } if (item) @@ -1684,9 +1684,9 @@ void KPSheetSelectPage::moveBottom() //this creates a temporary new list (unselected first, then rest) // which replaces the existing one, to avoid the need of an additional sort column - QValueList<QListViewItem*> newlist; - QListViewItem* item = gui->ListViewSelected->firstChild(); - QListViewItem* nextitem = NULL; + TQValueList<TQListViewItem*> newlist; + TQListViewItem* item = gui->ListViewSelected->firstChild(); + TQListViewItem* nextitem = NULL; // kdDebug() << "Filling new list with unselected items first" << endl; while (item) { @@ -1714,7 +1714,7 @@ void KPSheetSelectPage::moveBottom() // kdDebug() << "Refill the view with the correctly ordered list" << endl; //the view is empty now, refill in correct order (reversed!!) - QValueList<QListViewItem*>::iterator it; + TQValueList<TQListViewItem*>::iterator it; for (it = newlist.begin(); it != newlist.end(); ++it) { // kdDebug() << " adding " << (*it)->text(0) << endl; @@ -1729,7 +1729,7 @@ void KPSheetSelectPage::moveBottom() * *****************************************************************************/ -View::View( QWidget *_parent, const char *_name, +View::View( TQWidget *_parent, const char *_name, Doc *_doc ) : KoView( _doc, _parent, _name ) { @@ -1750,17 +1750,17 @@ View::View( QWidget *_parent, const char *_name, d->selection = new Selection( this ); d->choice = new Selection( this ); d->choice->setMultipleSelection(true); - connect(d->selection, SIGNAL(changed(const Region&)), this, SLOT(slotChangeSelection(const Region&))); - connect(d->choice, SIGNAL(changed(const Region&)), this, SLOT(slotChangeChoice(const Region&))); - connect(d->choice, SIGNAL(changed(const Region&)), this, SLOT(slotScrollChoice(const Region&))); + connect(d->selection, TQT_SIGNAL(changed(const Region&)), this, TQT_SLOT(slotChangeSelection(const Region&))); + connect(d->choice, TQT_SIGNAL(changed(const Region&)), this, TQT_SLOT(slotChangeChoice(const Region&))); + connect(d->choice, TQT_SIGNAL(changed(const Region&)), this, TQT_SLOT(slotScrollChoice(const Region&))); d->findOptions = 0; d->findLeftColumn = 0; d->findRightColumn = 0; d->typeValue = FindOption::Value; d->directionValue = FindOption::Row; - d->find = 0; - d->replace = 0; + d->tqfind = 0; + d->tqreplace = 0; d->popupMenuFirstToolId = 0; d->popupMenu = 0; @@ -1797,8 +1797,8 @@ View::View( QWidget *_parent, const char *_name, // build the DCOP object dcopObject(); - connect( doc()->commandHistory(), SIGNAL( commandExecuted() ), - this, SLOT( commandExecuted() ) ); + connect( doc()->commandHistory(), TQT_SIGNAL( commandExecuted() ), + this, TQT_SLOT( commandExecuted() ) ); // GUI Initializations initView(); @@ -1808,33 +1808,33 @@ View::View( QWidget *_parent, const char *_name, // Handler for moving and resizing embedded parts KoContainerHandler* h = new KoContainerHandler( this, d->canvas ); - connect( h, SIGNAL( popupMenu( KoChild*, const QPoint& ) ), this, SLOT( popupChildMenu( KoChild*, const QPoint& ) ) ); + connect( h, TQT_SIGNAL( popupMenu( KoChild*, const TQPoint& ) ), this, TQT_SLOT( popupChildMenu( KoChild*, const TQPoint& ) ) ); - connect( this, SIGNAL( childSelected( KoDocumentChild* ) ), - this, SLOT( slotChildSelected( KoDocumentChild* ) ) ); - connect( this, SIGNAL( childUnselected( KoDocumentChild* ) ), - this, SLOT( slotChildUnselected( KoDocumentChild* ) ) ); + connect( this, TQT_SIGNAL( childSelected( KoDocumentChild* ) ), + this, TQT_SLOT( slotChildSelected( KoDocumentChild* ) ) ); + connect( this, TQT_SIGNAL( childUnselected( KoDocumentChild* ) ), + this, TQT_SLOT( slotChildUnselected( KoDocumentChild* ) ) ); // If a selected part becomes active this is like it is deselected // just before. - connect( this, SIGNAL( childActivated( KoDocumentChild* ) ), - this, SLOT( slotChildUnselected( KoDocumentChild* ) ) ); + connect( this, TQT_SIGNAL( childActivated( KoDocumentChild* ) ), + this, TQT_SLOT( slotChildUnselected( KoDocumentChild* ) ) ); - connect( d->canvas, SIGNAL( objectSelectedChanged() ), - this, SLOT( objectSelectedChanged() ) ); + connect( d->canvas, TQT_SIGNAL( objectSelectedChanged() ), + this, TQT_SLOT( objectSelectedChanged() ) ); - QObject::connect( doc()->map(), SIGNAL( sig_addSheet( Sheet* ) ), SLOT( slotAddSheet( Sheet* ) ) ); + TQT_BASE_OBJECT_NAME::connect( doc()->map(), TQT_SIGNAL( sig_addSheet( Sheet* ) ), TQT_SLOT( slotAddSheet( Sheet* ) ) ); - QObject::connect( doc(), SIGNAL( sig_refreshView( ) ), this, SLOT( slotRefreshView() ) ); + TQT_BASE_OBJECT_NAME::connect( doc(), TQT_SIGNAL( sig_refreshView( ) ), this, TQT_SLOT( slotRefreshView() ) ); - QObject::connect( doc(), SIGNAL( sig_refreshLocale() ), this, SLOT( refreshLocale())); + TQT_BASE_OBJECT_NAME::connect( doc(), TQT_SIGNAL( sig_refreshLocale() ), this, TQT_SLOT( refreshLocale())); - QObject::connect( doc(), SIGNAL( sig_addAreaName( const QString & ) ), d->posWidget, SLOT( slotAddAreaName( const QString & ) ) ); + TQT_BASE_OBJECT_NAME::connect( doc(), TQT_SIGNAL( sig_addAreaName( const TQString & ) ), d->posWidget, TQT_SLOT( slotAddAreaName( const TQString & ) ) ); - QObject::connect( doc(), SIGNAL( sig_removeAreaName( const QString & ) ), d->posWidget, SLOT( slotRemoveAreaName( const QString & ) ) ); + TQT_BASE_OBJECT_NAME::connect( doc(), TQT_SIGNAL( sig_removeAreaName( const TQString & ) ), d->posWidget, TQT_SLOT( slotRemoveAreaName( const TQString & ) ) ); - QObject::connect( doc(), SIGNAL( damagesFlushed( const QValueList<Damage*>& ) ), - this, SLOT( handleDamages( const QValueList<Damage*>& ) ) ); + TQT_BASE_OBJECT_NAME::connect( doc(), TQT_SIGNAL( damagesFlushed( const TQValueList<Damage*>& ) ), + this, TQT_SLOT( handleDamages( const TQValueList<Damage*>& ) ) ); //KoView::setZoom( doc()->zoomedResolutionY() /* KoView only supports one zoom */ ); // initial value //when kspread is embedded into konqueror apply a zoom=100 @@ -1844,7 +1844,7 @@ View::View( QWidget *_parent, const char *_name, setZoom( 100, true ); } - viewZoom( QString::number( doc()->zoom() ) ); + viewZoom( TQString::number( doc()->zoom() ) ); // ## Might be wrong, if doc isn't loaded yet d->actions->selectStyle->setItems( d->doc->styleManager()->styleNames() ); @@ -1855,9 +1855,9 @@ View::View( QWidget *_parent, const char *_name, // This is the last operation for the "View loading" process. // The loading flag will be unset at its end. if ( !doc()->map()->sheetList().isEmpty() ) - QTimer::singleShot(50, this, SLOT(initialPosition())); + TQTimer::singleShot(50, this, TQT_SLOT(initialPosition())); - connect (&d->statusBarOpTimer, SIGNAL(timeout()), this, SLOT(calcStatusBarOp())); + connect (&d->statusBarOpTimer, TQT_SIGNAL(timeout()), this, TQT_SLOT(calcStatusBarOp())); } View::~View() @@ -1869,7 +1869,7 @@ View::~View() delete (&*d->transformToolBox); /*if (d->calcLabel) { - disconnect(d->calcLabel,SIGNAL(pressed( int )),this,SLOT(statusBarClicked(int))); + disconnect(d->calcLabel,TQT_SIGNAL(pressed( int )),this,TQT_SLOT(statusBarClicked(int))); }*/ @@ -1877,10 +1877,10 @@ View::~View() d->canvas->endChoose(); d->activeSheet = 0; // set the active sheet to 0L so that when during destruction - // of embedded child documents possible repaints in Sheet are not + // of embedded child documents possible tqrepaints in Sheet are not // performed. The repains can happen if you delete an embedded document, // which leads to an regionInvalidated() signal emission in KoView, which calls - // repaint, etc.etc. :-) (Simon) + // tqrepaint, etc.etc. :-) (Simon) delete d->selection; delete d->choice; @@ -1898,7 +1898,7 @@ View::~View() delete d->actions; // NOTE Stefan: Delete the Canvas explicitly, even if it has this view as - // parent. Otherwise, it leads to crashes, because it tries to + // tqparent. Otherwise, it leads to crashes, because it tries to // access this View in some events (Bug #126492). delete d->canvas; delete d; @@ -1921,20 +1921,20 @@ Doc* View::doc() const void View::initView() { - d->viewLayout = new QGridLayout( this, 3, 4 ); + d->viewLayout = new TQGridLayout( this, 3, 4 ); // Vert. Scroll Bar d->calcLabel = 0; - d->vertScrollBar = new QScrollBar( this, "ScrollBar_2" ); + d->vertScrollBar = new TQScrollBar( this, "ScrollBar_2" ); d->vertScrollBar->setRange( 0, 4096 ); - d->vertScrollBar->setOrientation( QScrollBar::Vertical ); + d->vertScrollBar->setOrientation( Qt::Vertical ); d->vertScrollBar->setLineStep(60); //just random guess based on what feels okay d->vertScrollBar->setPageStep(60); //This should be controlled dynamically, depending on how many rows are shown // Edit Bar - d->toolWidget = new QFrame( this ); + d->toolWidget = new TQFrame( this ); - d->formulaBarLayout = new QHBoxLayout( d->toolWidget ); + d->formulaBarLayout = new TQHBoxLayout( d->toolWidget ); d->formulaBarLayout->setMargin( 4 ); d->formulaBarLayout->addSpacing( 2 ); @@ -1946,7 +1946,7 @@ void View::initView() d->formulaButton = d->newIconButton( "funct", true, d->toolWidget ); d->formulaBarLayout->addWidget( d->formulaButton ); d->formulaBarLayout->addSpacing( 2 ); - connect( d->formulaButton, SIGNAL( clicked() ), SLOT( insertMathExpr() ) ); + connect( d->formulaButton, TQT_SIGNAL( clicked() ), TQT_SLOT( insertMathExpr() ) ); d->cancelButton = d->newIconButton( "cancel", true, d->toolWidget ); d->formulaBarLayout->addWidget( d->cancelButton ); @@ -1960,7 +1960,7 @@ void View::initView() // The line-editor that appears above the sheet and allows to // edit the cells content. It knows about the two buttons. d->editWidget = new EditWidget( d->toolWidget, d->canvas, d->cancelButton, d->okButton ); - d->editWidget->setFocusPolicy( QWidget::StrongFocus ); + d->editWidget->setFocusPolicy( TQ_StrongFocus ); d->formulaBarLayout->addWidget( d->editWidget, 2 ); d->formulaBarLayout->addSpacing( 2 ); @@ -1968,34 +1968,34 @@ void View::initView() d->hBorderWidget = new HBorder( this, d->canvas,this ); d->vBorderWidget = new VBorder( this, d->canvas ,this ); - d->hBorderWidget->setSizePolicy( QSizePolicy::Expanding, QSizePolicy::Minimum ); - d->vBorderWidget->setSizePolicy( QSizePolicy::Minimum, QSizePolicy::Expanding ); + d->hBorderWidget->tqsetSizePolicy( TQSizePolicy::Expanding, TQSizePolicy::Minimum ); + d->vBorderWidget->tqsetSizePolicy( TQSizePolicy::Minimum, TQSizePolicy::Expanding ); - d->canvas->setFocusPolicy( QWidget::StrongFocus ); - QWidget::setFocusPolicy( QWidget::StrongFocus ); + d->canvas->setFocusPolicy( TQ_StrongFocus ); + TQWidget::setFocusPolicy( TQ_StrongFocus ); setFocusProxy( d->canvas ); - connect( this, SIGNAL( invalidated() ), d->canvas, SLOT( update() ) ); + connect( this, TQT_SIGNAL( tqinvalidated() ), d->canvas, TQT_SLOT( update() ) ); - QWidget* bottomPart = new QWidget( this ); - d->tabScrollBarLayout = new QHBoxLayout( bottomPart ); + TQWidget* bottomPart = new TQWidget( this ); + d->tabScrollBarLayout = new TQHBoxLayout( bottomPart ); d->tabScrollBarLayout->setAutoAdd( true ); d->tabBar = new KoTabBar( bottomPart ); - d->horzScrollBar = new QScrollBar( bottomPart, "ScrollBar_1" ); + d->horzScrollBar = new TQScrollBar( bottomPart, "ScrollBar_1" ); d->horzScrollBar->setRange( 0, 4096 ); - d->horzScrollBar->setOrientation( QScrollBar::Horizontal ); + d->horzScrollBar->setOrientation( Qt::Horizontal ); d->horzScrollBar->setLineStep(60); //just random guess based on what feels okay d->horzScrollBar->setPageStep(60); - QObject::connect( d->tabBar, SIGNAL( tabChanged( const QString& ) ), this, SLOT( changeSheet( const QString& ) ) ); - QObject::connect( d->tabBar, SIGNAL( tabMoved( unsigned, unsigned ) ), - this, SLOT( moveSheet( unsigned, unsigned ) ) ); - QObject::connect( d->tabBar, SIGNAL( contextMenu( const QPoint& ) ), - this, SLOT( popupTabBarMenu( const QPoint& ) ) ); - QObject::connect( d->tabBar, SIGNAL( doubleClicked() ), - this, SLOT( slotRename() ) ); + TQT_BASE_OBJECT_NAME::connect( d->tabBar, TQT_SIGNAL( tabChanged( const TQString& ) ), this, TQT_SLOT( changeSheet( const TQString& ) ) ); + TQT_BASE_OBJECT_NAME::connect( d->tabBar, TQT_SIGNAL( tabMoved( unsigned, unsigned ) ), + this, TQT_SLOT( moveSheet( unsigned, unsigned ) ) ); + TQT_BASE_OBJECT_NAME::connect( d->tabBar, TQT_SIGNAL( contextMenu( const TQPoint& ) ), + this, TQT_SLOT( popupTabBarMenu( const TQPoint& ) ) ); + TQT_BASE_OBJECT_NAME::connect( d->tabBar, TQT_SIGNAL( doubleClicked() ), + this, TQT_SLOT( slotRename() ) ); d->viewLayout->setColStretch( 1, 10 ); d->viewLayout->setRowStretch( 2, 10 ); @@ -2008,14 +2008,14 @@ void View::initView() KStatusBar * sb = statusBar(); Q_ASSERT(sb); - d->calcLabel = sb ? new KStatusBarLabel( QString::null, 0, sb ) : 0; + d->calcLabel = sb ? new KStatusBarLabel( TQString(), 0, sb ) : 0; addStatusBarItem( d->calcLabel, 0 ); if (d->calcLabel) - connect(d->calcLabel ,SIGNAL(itemPressed( int )),this,SLOT(statusBarClicked(int))); + connect(d->calcLabel ,TQT_SIGNAL(itemPressed( int )),this,TQT_SLOT(statusBarClicked(int))); // signal slot - QObject::connect( d->vertScrollBar, SIGNAL( valueChanged(int) ), d->canvas, SLOT( slotScrollVert(int) ) ); - QObject::connect( d->horzScrollBar, SIGNAL( valueChanged(int) ), d->canvas, SLOT( slotScrollHorz(int) ) ); + TQT_BASE_OBJECT_NAME::connect( d->vertScrollBar, TQT_SIGNAL( valueChanged(int) ), d->canvas, TQT_SLOT( slotScrollVert(int) ) ); + TQT_BASE_OBJECT_NAME::connect( d->horzScrollBar, TQT_SIGNAL( valueChanged(int) ), d->canvas, TQT_SLOT( slotScrollHorz(int) ) ); } @@ -2034,12 +2034,12 @@ VBorder* View::vBorderWidget()const return d->vBorderWidget; } -QScrollBar* View::horzScrollBar()const +TQScrollBar* View::horzScrollBar()const { return d->horzScrollBar; } -QScrollBar* View::vertScrollBar()const +TQScrollBar* View::vertScrollBar()const { return d->vertScrollBar; } @@ -2120,7 +2120,7 @@ void View::initConfig() doc()->setShowMessageError(config->readBoolEntry( "Msg error" ,false) ); doc()->setShowFormulaBar(config->readBoolEntry("Formula bar",true)); - doc()->setShowStatusBar(config->readBoolEntry("Status bar",true)); + doc()->setShowStatusBar(config->readBoolEntry("tqStatus bar",true)); changeNbOfRecentFiles(config->readNumEntry("NbRecentFile",10)); //autosave value is stored as a minute. @@ -2132,11 +2132,11 @@ void View::initConfig() if ( config->hasGroup("KSpread Color" ) ) { config->setGroup( "KSpread Color" ); - QColor _col(Qt::lightGray); + TQColor _col(TQt::lightGray); _col = config->readColorEntry("GridColor", &_col); doc()->setGridColor(_col); - QColor _pbCol(Qt::red); + TQColor _pbCol(TQt::red); _pbCol = config->readColorEntry("PageBorderColor", &_pbCol); doc()->changePageBorderColor(_pbCol); } @@ -2150,7 +2150,7 @@ if ( config->hasGroup("KSpread Page Layout" ) ) { d->activeSheet->setPaperFormat((KoFormat)config->readNumEntry("Default size page",1)); - d->activeSheet->setPaperOrientation((KoOrientation)config->readNumEntry("Default orientation page",0)); + d->activeSheet->setPaperQt::Orientation((KoOrientation)config->readNumEntry("Default orientation page",0)); d->activeSheet->setPaperUnit((KoUnit::Unit)config->readNumEntry("Default unit page",0)); } } @@ -2258,7 +2258,7 @@ void View::extraSpelling() d->spell.firstSpellSheet = d->activeSheet; d->spell.currentSpellSheet = d->spell.firstSpellSheet; - QRect selection = d->selection->selection(); + TQRect selection = d->selection->selection(); // if nothing is selected, check every cell if (d->selection->isSingular()) @@ -2296,44 +2296,44 @@ void View::startKSpell() doc()->getKSpellConfig()->setReplaceAllList( d->spell.replaceAll ); } - d->spell.kspell = new KSpell( this, i18n( "Spell Checking" ), this, - SLOT( spellCheckerReady() ), + d->spell.kspell = new KSpell( this, i18n( "Spell Checking" ), TQT_TQOBJECT(this), + TQT_SLOT( spellCheckerReady() ), doc()->getKSpellConfig() ); d->spell.kspell->setIgnoreUpperWords( doc()->dontCheckUpperWord() ); d->spell.kspell->setIgnoreTitleCase( doc()->dontCheckTitleCase() ); - QObject::connect( d->spell.kspell, SIGNAL( death() ), - this, SLOT( spellCheckerFinished() ) ); - QObject::connect( d->spell.kspell, SIGNAL( misspelling( const QString &, - const QStringList &, + TQT_BASE_OBJECT_NAME::connect( d->spell.kspell, TQT_SIGNAL( death() ), + this, TQT_SLOT( spellCheckerFinished() ) ); + TQT_BASE_OBJECT_NAME::connect( d->spell.kspell, TQT_SIGNAL( misspelling( const TQString &, + const TQStringList &, unsigned int) ), - this, SLOT( spellCheckerMisspelling( const QString &, - const QStringList &, + this, TQT_SLOT( spellCheckerMisspelling( const TQString &, + const TQStringList &, unsigned int) ) ); - QObject::connect( d->spell.kspell, SIGNAL( corrected( const QString &, - const QString &, + TQT_BASE_OBJECT_NAME::connect( d->spell.kspell, TQT_SIGNAL( corrected( const TQString &, + const TQString &, unsigned int) ), - this, SLOT( spellCheckerCorrected( const QString &, - const QString &, + this, TQT_SLOT( spellCheckerCorrected( const TQString &, + const TQString &, unsigned int ) ) ); - QObject::connect( d->spell.kspell, SIGNAL( done( const QString & ) ), - this, SLOT( spellCheckerDone( const QString & ) ) ); - QObject::connect( d->spell.kspell, SIGNAL( ignoreall (const QString & ) ), - this, SLOT( spellCheckerIgnoreAll( const QString & ) ) ); + TQT_BASE_OBJECT_NAME::connect( d->spell.kspell, TQT_SIGNAL( done( const TQString & ) ), + this, TQT_SLOT( spellCheckerDone( const TQString & ) ) ); + TQT_BASE_OBJECT_NAME::connect( d->spell.kspell, TQT_SIGNAL( ignoreall (const TQString & ) ), + this, TQT_SLOT( spellCheckerIgnoreAll( const TQString & ) ) ); - QObject::connect( d->spell.kspell, SIGNAL( replaceall( const QString & , const QString & )), this, SLOT( spellCheckerReplaceAll( const QString & , const QString & ))); + TQT_BASE_OBJECT_NAME::connect( d->spell.kspell, TQT_SIGNAL( replaceall( const TQString & , const TQString & )), this, TQT_SLOT( spellCheckerReplaceAll( const TQString & , const TQString & ))); } -void View::spellCheckerReplaceAll( const QString &orig, const QString & replacement) +void View::spellCheckerReplaceAll( const TQString &orig, const TQString & replacement) { d->spell.replaceAll.append( orig); d->spell.replaceAll.append( replacement); } -void View::spellCheckerIgnoreAll( const QString & word) +void View::spellCheckerIgnoreAll( const TQString & word) { doc()->addIgnoreWordAll( word ); } @@ -2450,9 +2450,9 @@ bool View::spellSwitchToOtherSheet() return false; // for optimization - QPtrList<Sheet> sheetList = doc()->map()->sheetList(); + TQPtrList<Sheet> sheetList = doc()->map()->sheetList(); - unsigned int curIndex = sheetList.findRef(d->spell.currentSpellSheet); + unsigned int curIndex = sheetList.tqfindRef(d->spell.currentSpellSheet); ++curIndex; // last sheet? then start at the beginning @@ -2492,8 +2492,8 @@ bool View::spellSwitchToOtherSheet() } -void View::spellCheckerMisspelling( const QString &, - const QStringList &, +void View::spellCheckerMisspelling( const TQString &, + const TQStringList &, unsigned int ) { // scroll to the cell @@ -2503,11 +2503,11 @@ void View::spellCheckerMisspelling( const QString &, d->spell.spellCurrCellY = d->spell.currentCell->row(); } - d->selection->initialize(QPoint(d->spell.spellCurrCellX, d->spell.spellCurrCellY)); + d->selection->initialize(TQPoint(d->spell.spellCurrCellX, d->spell.spellCurrCellY)); } -void View::spellCheckerCorrected( const QString & old, const QString & corr, +void View::spellCheckerCorrected( const TQString & old, const TQString & corr, unsigned int pos ) { Cell * cell; @@ -2529,14 +2529,14 @@ void View::spellCheckerCorrected( const QString & old, const QString & corr, return; doc()->emitBeginOperation(false); - QString content( cell->text() ); + TQString content( cell->text() ); UndoSetText* undo = new UndoSetText( doc(), d->activeSheet, content, d->spell.spellCurrCellX, d->spell.spellCurrCellY, cell->formatType()); - content.replace( pos, old.length(), corr ); + content.tqreplace( pos, old.length(), corr ); cell->setCellText( content ); d->editWidget->setText( content ); @@ -2546,7 +2546,7 @@ void View::spellCheckerCorrected( const QString & old, const QString & corr, doc()->emitEndOperation( d->activeSheet->visibleRect( d->canvas ) ); } -void View::spellCheckerDone( const QString & ) +void View::spellCheckerDone( const TQString & ) { int result = d->spell.kspell->dlgResult(); @@ -2628,7 +2628,7 @@ void View::spellCheckerFinished() void View::initialPosition() { // Loading completed, pick initial worksheet - QPtrListIterator<Sheet> it( doc()->map()->sheetList() ); + TQPtrListIterator<Sheet> it( doc()->map()->sheetList() ); for( ; it.current(); ++it ) addSheet( it.current() ); @@ -2660,7 +2660,7 @@ void View::initialPosition() if ( tbl ) { tbl->setHidden( false ); - QString tabName = tbl->sheetName(); + TQString tabName = tbl->sheetName(); d->tabBar->addTab( tabName ); } } @@ -2686,7 +2686,7 @@ void View::initialPosition() d->canvas->setYOffset( offsetY ); d->horzScrollBar->setValue( (int)offsetX ); d->vertScrollBar->setValue( (int)offsetY ); - d->selection->initialize( QPoint(col, row) ); + d->selection->initialize( TQPoint(col, row) ); } updateBorderButton(); @@ -2707,7 +2707,7 @@ void View::initialPosition() // make paint effective: doc()->decreaseNumOperation(); - QRect vr( activeSheet()->visibleRect( d->canvas ) ); + TQRect vr( activeSheet()->visibleRect( d->canvas ) ); doc()->emitBeginOperation( false ); activeSheet()->setRegionPaintDirty( vr ); @@ -2818,9 +2818,9 @@ void View::updateReadWrite( bool readwrite ) // d->okButton->setEnabled( readwrite ); d->editWidget->setEnabled( readwrite ); - QValueList<KAction*> actions = actionCollection()->actions(); - QValueList<KAction*>::ConstIterator aIt = actions.begin(); - QValueList<KAction*>::ConstIterator aEnd = actions.end(); + TQValueList<KAction*> actions = actionCollection()->actions(); + TQValueList<KAction*>::ConstIterator aIt = actions.begin(); + TQValueList<KAction*>::ConstIterator aEnd = actions.end(); for (; aIt != aEnd; ++aIt ) (*aIt)->setEnabled( readwrite ); @@ -2838,8 +2838,8 @@ void View::updateReadWrite( bool readwrite ) d->actions->gotoCell->setEnabled( true ); d->actions->viewZoom->setEnabled( true ); d->actions->showPageBorders->setEnabled( true ); - d->actions->find->setEnabled( true); - d->actions->replace->setEnabled( readwrite ); + d->actions->tqfind->setEnabled( true); + d->actions->tqreplace->setEnabled( readwrite ); if ( !doc()->isReadWrite()) d->actions->copy->setEnabled( true ); // d->actions->newView->setEnabled( true ); @@ -2850,9 +2850,9 @@ void View::createTemplate() { int width = 60; int height = 60; - QPixmap pix = doc()->generatePreview(QSize(width, height)); + TQPixmap pix = doc()->generatePreview(TQSize(width, height)); - KTempFile tempFile( QString::null, ".kst" ); + KTempFile tempFile( TQString(), ".kst" ); //Check that creation of temp file was successful if (tempFile.status() != 0) { @@ -2893,7 +2893,7 @@ void View::autoSum() //this behaviour??) Range rg; //rg.sheet=activeSheet(); - QRect sel = d->selection->selection(false); + TQRect sel = d->selection->selection(false); if (sel.height() > 1) { @@ -2914,7 +2914,7 @@ void View::autoSum() } else { - sel=QRect(); + sel=TQRect(); // only 1 cell selected // try to automagically find cells the user wants to sum up @@ -2933,7 +2933,7 @@ void View::autoSum() endPoint.setRow(end); endPoint.setColumn(d->selection->marker().x()); - QString str = Range(startPoint, endPoint).toString(); + TQString str = Range(startPoint, endPoint).toString(); d->canvas->createEditor( Canvas::CellEditor , true , true ); d->canvas->editor()->setText("=SUM(" + str + ")"); @@ -2952,7 +2952,7 @@ void View::autoSum() endPoint.setColumn(end); endPoint.setRow(d->selection->marker().y()); - QString str = Range(startPoint, endPoint).toString(); + TQString str = Range(startPoint, endPoint).toString(); d->canvas->createEditor( Canvas::CellEditor , true , true ); d->canvas->editor()->setText("=SUM(" + str + ")"); @@ -2963,7 +2963,7 @@ void View::autoSum() } if ( (sel.width() > 1) && (sel.height() > 1) ) - sel=QRect(); + sel=TQRect(); rg.setRange(sel); @@ -2986,7 +2986,7 @@ void View::autoSum() /* void View::oszilloscope() { - QDialog* dlg = new OsziDlg( this ); + TQDialog* dlg = new OsziDlg( this ); dlg->show(); } */ @@ -3001,7 +3001,7 @@ void View::changeTextColor() } } -void View::setSelectionTextColor(const QColor &txtColor) +void View::setSelectionTextColor(const TQColor &txtColor) { if (d->activeSheet != 0L) { @@ -3023,7 +3023,7 @@ void View::changeBackgroundColor() } } -void View::setSelectionBackgroundColor(const QColor &bgColor) +void View::setSelectionBackgroundColor(const TQColor &bgColor) { if (d->activeSheet != 0L) { @@ -3043,7 +3043,7 @@ void View::changeBorderColor() } } -void View::setSelectionBorderColor(const QColor &bdColor) +void View::setSelectionBorderColor(const TQColor &bdColor) { if (d->activeSheet != 0L) { @@ -3089,7 +3089,7 @@ void View::deleteColumn() doc()->emitBeginOperation( false ); - QRect r( d->selection->selection() ); + TQRect r( d->selection->selection() ); d->activeSheet->removeColumn( r.left(), ( r.right()-r.left() ) ); @@ -3097,7 +3097,7 @@ void View::deleteColumn() // Stefan: update the selection after deleting (a) column(s) d->selection->update(); - QRect vr( d->activeSheet->visibleRect( d->canvas ) ); + TQRect vr( d->activeSheet->visibleRect( d->canvas ) ); vr.setLeft( r.left() ); doc()->emitEndOperation( vr ); @@ -3109,14 +3109,14 @@ void View::deleteRow() return; doc()->emitBeginOperation( false ); - QRect r( d->selection->selection() ); + TQRect r( d->selection->selection() ); d->activeSheet->removeRow( r.top(),(r.bottom()-r.top()) ); updateEditWidget(); // Stefan: update the selection after deleting (a) column(s) d->selection->update(); - QRect vr( d->activeSheet->visibleRect( d->canvas ) ); + TQRect vr( d->activeSheet->visibleRect( d->canvas ) ); vr.setTop( r.top() ); doc()->emitEndOperation( vr ); @@ -3128,12 +3128,12 @@ void View::insertColumn() return; doc()->emitBeginOperation( false ); - QRect r( d->selection->selection() ); + TQRect r( d->selection->selection() ); d->activeSheet->insertColumn( r.left(), ( r.right()-r.left() ) ); updateEditWidget(); - QRect vr( d->activeSheet->visibleRect( d->canvas ) ); + TQRect vr( d->activeSheet->visibleRect( d->canvas ) ); vr.setLeft( r.left() - 1 ); doc()->emitEndOperation( vr ); @@ -3175,11 +3175,11 @@ void View::insertRow() if ( !d->activeSheet ) return; doc()->emitBeginOperation( false ); - QRect r( d->selection->selection() ); + TQRect r( d->selection->selection() ); d->activeSheet->insertRow( r.top(), ( r.bottom() - r.top() ) ); updateEditWidget(); - QRect vr( d->activeSheet->visibleRect( d->canvas ) ); + TQRect vr( d->activeSheet->visibleRect( d->canvas ) ); vr.setTop( r.top() - 1 ); doc()->emitEndOperation( vr ); @@ -3216,7 +3216,7 @@ void View::showSelRows() d->activeSheet->showRow(*selectionInfo()); } -void View::fontSelected( const QString & _font ) +void View::fontSelected( const TQString & _font ) { if ( d->toolbarLock ) return; @@ -3313,16 +3313,16 @@ void View::verticalText(bool b) void View::insertSpecialChar() { - QString f( d->actions->selectFont->font() ); - QChar c = ' '; + TQString f( d->actions->selectFont->font() ); + TQChar c = ' '; if ( d->specialCharDlg == 0 ) { d->specialCharDlg = new KoCharSelectDia( this, "insert special char", f, c, false ); - connect( d->specialCharDlg, SIGNAL( insertChar( QChar, const QString & ) ), - this, SLOT( slotSpecialChar( QChar, const QString & ) ) ); - connect( d->specialCharDlg, SIGNAL( finished() ), - this, SLOT( slotSpecialCharDlgClosed() ) ); + connect( d->specialCharDlg, TQT_SIGNAL( insertChar( TQChar, const TQString & ) ), + this, TQT_SLOT( slotSpecialChar( TQChar, const TQString & ) ) ); + connect( d->specialCharDlg, TQT_SIGNAL( finished() ), + this, TQT_SLOT( slotSpecialCharDlgClosed() ) ); } d->specialCharDlg->show(); } @@ -3331,28 +3331,28 @@ void View::slotSpecialCharDlgClosed() { if ( d->specialCharDlg ) { - disconnect( d->specialCharDlg, SIGNAL(insertChar(QChar,const QString &)), - this, SLOT(slotSpecialChar(QChar,const QString &))); - disconnect( d->specialCharDlg, SIGNAL( finished() ), - this, SLOT( slotSpecialCharDlgClosed() ) ); + disconnect( d->specialCharDlg, TQT_SIGNAL(insertChar(TQChar,const TQString &)), + this, TQT_SLOT(slotSpecialChar(TQChar,const TQString &))); + disconnect( d->specialCharDlg, TQT_SIGNAL( finished() ), + this, TQT_SLOT( slotSpecialCharDlgClosed() ) ); d->specialCharDlg->deleteLater(); d->specialCharDlg = 0L; } } -void View::slotSpecialChar( QChar c, const QString & _font ) +void View::slotSpecialChar( TQChar c, const TQString & _font ) { if ( d->activeSheet ) { - QPoint marker( d->selection->marker() ); + TQPoint marker( d->selection->marker() ); Cell * cell = d->activeSheet->nonDefaultCell( marker ); if ( cell->format()->textFont( marker.x(), marker.y() ).family() != _font ) { cell->format()->setTextFontFamily( _font ); } EditWidget * edit = d->editWidget; - QKeyEvent ev( QEvent::KeyPress, 0, 0, 0, QString( c ) ); - QApplication::sendEvent( edit, &ev ); + TQKeyEvent ev( TQEvent::KeyPress, 0, 0, 0, TQString( c ) ); + TQApplication::sendEvent( edit, &ev ); } } @@ -3369,7 +3369,7 @@ void View::insertMathExpr() // Torben thinks that not. } -void View::formulaSelection( const QString &_math ) +void View::formulaSelection( const TQString &_math ) { if ( d->activeSheet == 0 ) return; @@ -3507,7 +3507,7 @@ void View::sortInc() if (!activeSheet()) return; - QRect range = d->selection->selection(); + TQRect range = d->selection->selection(); if ( d->selection->isSingular() ) { KMessageBox::error( this, i18n( "You must select multiple cells." ) ); @@ -3529,7 +3529,7 @@ void View::sortInc() void View::sortDec() { - QRect range = d->selection->selection(); + TQRect range = d->selection->selection(); if ( d->selection->isSingular() ) { KMessageBox::error( this, i18n( "You must select multiple cells." ) ); @@ -3563,7 +3563,7 @@ void View::borderBottom() } } -void View::setSelectionBottomBorderColor( const QColor & color ) +void View::setSelectionBottomBorderColor( const TQColor & color ) { if ( d->activeSheet != 0L ) { @@ -3580,7 +3580,7 @@ void View::borderRight() if ( d->activeSheet != 0L ) { doc()->emitBeginOperation( false ); - if ( d->activeSheet->layoutDirection()==Sheet::RightToLeft ) + if ( d->activeSheet->tqlayoutDirection()==Sheet::RightToLeft ) d->activeSheet->borderLeft( d->selection, d->actions->borderColor->color() ); else d->activeSheet->borderRight( d->selection, d->actions->borderColor->color() ); @@ -3590,12 +3590,12 @@ void View::borderRight() } } -void View::setSelectionRightBorderColor( const QColor & color ) +void View::setSelectionRightBorderColor( const TQColor & color ) { if ( d->activeSheet != 0L ) { doc()->emitBeginOperation( false ); - if ( d->activeSheet->layoutDirection()==Sheet::RightToLeft ) + if ( d->activeSheet->tqlayoutDirection()==Sheet::RightToLeft ) d->activeSheet->borderLeft( selectionInfo(), color ); else d->activeSheet->borderRight( selectionInfo(), color ); @@ -3610,7 +3610,7 @@ void View::borderLeft() if ( d->activeSheet != 0L ) { doc()->emitBeginOperation( false ); - if ( d->activeSheet->layoutDirection()==Sheet::RightToLeft ) + if ( d->activeSheet->tqlayoutDirection()==Sheet::RightToLeft ) d->activeSheet->borderRight( d->selection, d->actions->borderColor->color() ); else d->activeSheet->borderLeft( d->selection, d->actions->borderColor->color() ); @@ -3620,12 +3620,12 @@ void View::borderLeft() } } -void View::setSelectionLeftBorderColor( const QColor & color ) +void View::setSelectionLeftBorderColor( const TQColor & color ) { if ( d->activeSheet != 0L ) { doc()->emitBeginOperation( false ); - if ( d->activeSheet->layoutDirection()==Sheet::RightToLeft ) + if ( d->activeSheet->tqlayoutDirection()==Sheet::RightToLeft ) d->activeSheet->borderRight( selectionInfo(), color ); else d->activeSheet->borderLeft( selectionInfo(), color ); @@ -3647,7 +3647,7 @@ void View::borderTop() } } -void View::setSelectionTopBorderColor( const QColor & color ) +void View::setSelectionTopBorderColor( const TQColor & color ) { if ( d->activeSheet != 0L ) { @@ -3671,7 +3671,7 @@ void View::borderOutline() } } -void View::setSelectionOutlineBorderColor( const QColor & color ) +void View::setSelectionOutlineBorderColor( const TQColor & color ) { if ( d->activeSheet != 0L ) { @@ -3695,7 +3695,7 @@ void View::borderAll() } } -void View::setSelectionAllBorderColor( const QColor & color ) +void View::setSelectionAllBorderColor( const TQColor & color ) { if ( d->activeSheet != 0L ) { @@ -3726,31 +3726,31 @@ void View::addSheet( Sheet * _t ) insertSheet( _t ); // Connect some signals - QObject::connect( _t, SIGNAL( sig_refreshView() ), SLOT( slotRefreshView() ) ); - QObject::connect( _t, SIGNAL( sig_updateView( Sheet* ) ), SLOT( slotUpdateView( Sheet* ) ) ); - QObject::connect( _t->print(), SIGNAL( sig_updateView( Sheet* ) ), SLOT( slotUpdateView( Sheet* ) ) ); - QObject::connect( _t, SIGNAL( sig_updateView( Sheet *, const Region& ) ), - SLOT( slotUpdateView( Sheet*, const Region& ) ) ); - QObject::connect( _t, SIGNAL( sig_updateView( EmbeddedObject* )), SLOT( slotUpdateView( EmbeddedObject* ) ) ); - - QObject::connect( _t, SIGNAL( sig_updateHBorder( Sheet * ) ), - SLOT( slotUpdateHBorder( Sheet * ) ) ); - QObject::connect( _t, SIGNAL( sig_updateVBorder( Sheet * ) ), - SLOT( slotUpdateVBorder( Sheet * ) ) ); - QObject::connect( _t, SIGNAL( sig_nameChanged( Sheet*, const QString& ) ), - this, SLOT( slotSheetRenamed( Sheet*, const QString& ) ) ); - QObject::connect( _t, SIGNAL( sig_SheetHidden( Sheet* ) ), - this, SLOT( slotSheetHidden( Sheet* ) ) ); - QObject::connect( _t, SIGNAL( sig_SheetShown( Sheet* ) ), - this, SLOT( slotSheetShown( Sheet* ) ) ); - QObject::connect( _t, SIGNAL( sig_SheetRemoved( Sheet* ) ), - this, SLOT( slotSheetRemoved( Sheet* ) ) ); + TQT_BASE_OBJECT_NAME::connect( _t, TQT_SIGNAL( sig_refreshView() ), TQT_SLOT( slotRefreshView() ) ); + TQT_BASE_OBJECT_NAME::connect( _t, TQT_SIGNAL( sig_updateView( Sheet* ) ), TQT_SLOT( slotUpdateView( Sheet* ) ) ); + TQT_BASE_OBJECT_NAME::connect( _t->print(), TQT_SIGNAL( sig_updateView( Sheet* ) ), TQT_SLOT( slotUpdateView( Sheet* ) ) ); + TQT_BASE_OBJECT_NAME::connect( _t, TQT_SIGNAL( sig_updateView( Sheet *, const Region& ) ), + TQT_SLOT( slotUpdateView( Sheet*, const Region& ) ) ); + TQT_BASE_OBJECT_NAME::connect( _t, TQT_SIGNAL( sig_updateView( EmbeddedObject* )), TQT_SLOT( slotUpdateView( EmbeddedObject* ) ) ); + + TQT_BASE_OBJECT_NAME::connect( _t, TQT_SIGNAL( sig_updateHBorder( Sheet * ) ), + TQT_SLOT( slotUpdateHBorder( Sheet * ) ) ); + TQT_BASE_OBJECT_NAME::connect( _t, TQT_SIGNAL( sig_updateVBorder( Sheet * ) ), + TQT_SLOT( slotUpdateVBorder( Sheet * ) ) ); + TQT_BASE_OBJECT_NAME::connect( _t, TQT_SIGNAL( sig_nameChanged( Sheet*, const TQString& ) ), + this, TQT_SLOT( slotSheetRenamed( Sheet*, const TQString& ) ) ); + TQT_BASE_OBJECT_NAME::connect( _t, TQT_SIGNAL( sig_SheetHidden( Sheet* ) ), + this, TQT_SLOT( slotSheetHidden( Sheet* ) ) ); + TQT_BASE_OBJECT_NAME::connect( _t, TQT_SIGNAL( sig_SheetShown( Sheet* ) ), + this, TQT_SLOT( slotSheetShown( Sheet* ) ) ); + TQT_BASE_OBJECT_NAME::connect( _t, TQT_SIGNAL( sig_SheetRemoved( Sheet* ) ), + this, TQT_SLOT( slotSheetRemoved( Sheet* ) ) ); // ########### Why do these signals not send a pointer to the sheet? // This will lead to bugs. - QObject::connect( _t, SIGNAL( sig_updateChildGeometry( EmbeddedKOfficeObject* ) ), - SLOT( slotUpdateChildGeometry( EmbeddedKOfficeObject* ) ) ); - QObject::connect( _t, SIGNAL( sig_maxColumn( int ) ), d->canvas, SLOT( slotMaxColumn( int ) ) ); - QObject::connect( _t, SIGNAL( sig_maxRow( int ) ), d->canvas, SLOT( slotMaxRow( int ) ) ); + TQT_BASE_OBJECT_NAME::connect( _t, TQT_SIGNAL( sig_updateChildGeometry( EmbeddedKOfficeObject* ) ), + TQT_SLOT( slotUpdateChildGeometry( EmbeddedKOfficeObject* ) ) ); + TQT_BASE_OBJECT_NAME::connect( _t, TQT_SIGNAL( sig_maxColumn( int ) ), d->canvas, TQT_SLOT( slotMaxColumn( int ) ) ); + TQT_BASE_OBJECT_NAME::connect( _t, TQT_SIGNAL( sig_maxRow( int ) ), d->canvas, TQT_SLOT( slotMaxRow( int ) ) ); if ( !d->loading ) updateBorderButton(); @@ -3767,15 +3767,15 @@ void View::slotSheetRemoved( Sheet *_t ) { doc()->emitBeginOperation( false ); - QString m_sheetName=_t->sheetName(); + TQString m_sheetName=_t->sheetName(); d->tabBar->removeTab( _t->sheetName() ); if (doc()->map()->findSheet( doc()->map()->visibleSheets().first())) setActiveSheet( doc()->map()->findSheet( doc()->map()->visibleSheets().first() )); else d->activeSheet = 0L; - QValueList<Reference>::Iterator it; - QValueList<Reference> area=doc()->listArea(); + TQValueList<Reference>::Iterator it; + TQValueList<Reference> area=doc()->listArea(); for ( it = area.begin(); it != area.end(); ++it ) { //remove Area Name when sheet target is removed @@ -3825,16 +3825,16 @@ void View::setActiveSheet( Sheet * _t, bool updateSheet ) return; } - if ( oldSheet && oldSheet->layoutDirection()==Sheet::RightToLeft != d->activeSheet->layoutDirection()==Sheet::RightToLeft ) + if ( oldSheet && oldSheet->tqlayoutDirection()==Sheet::RightToLeft != d->activeSheet->tqlayoutDirection()==Sheet::RightToLeft ) refreshView(); doc()->setDisplaySheet( d->activeSheet ); if ( updateSheet ) { d->tabBar->setActiveTab( _t->sheetName() ); - d->vBorderWidget->repaint(); - d->hBorderWidget->repaint(); - d->activeSheet->setRegionPaintDirty(QRect(QPoint(0,0), QPoint(KS_colMax, KS_rowMax))); + d->vBorderWidget->tqrepaint(); + d->hBorderWidget->tqrepaint(); + d->activeSheet->setRegionPaintDirty(TQRect(TQPoint(0,0), TQPoint(KS_colMax, KS_rowMax))); d->canvas->slotMaxColumn( d->activeSheet->maxColumn() ); d->canvas->slotMaxRow( d->activeSheet->maxRow() ); } @@ -3846,17 +3846,17 @@ void View::setActiveSheet( Sheet * _t, bool updateSheet ) d->adjustWorkbookActions( !doc()->map()->isProtected() ); /* see if there was a previous selection on this other sheet */ - QMapIterator<Sheet*, QPoint> it = d->savedAnchors.find(d->activeSheet); - QMapIterator<Sheet*, QPoint> it2 = d->savedMarkers.find(d->activeSheet); - QMapIterator<Sheet*, KoPoint> it3 = d->savedOffsets.find(d->activeSheet); + TQMapIterator<Sheet*, TQPoint> it = d->savedAnchors.tqfind(d->activeSheet); + TQMapIterator<Sheet*, TQPoint> it2 = d->savedMarkers.tqfind(d->activeSheet); + TQMapIterator<Sheet*, KoPoint> it3 = d->savedOffsets.tqfind(d->activeSheet); // TODO Stefan: store the save markers/anchors in the Selection? - QPoint newAnchor = (it == d->savedAnchors.end()) ? QPoint(1,1) : *it; - QPoint newMarker = (it2 == d->savedMarkers.end()) ? QPoint(1,1) : *it2; + TQPoint newAnchor = (it == d->savedAnchors.end()) ? TQPoint(1,1) : *it; + TQPoint newMarker = (it2 == d->savedMarkers.end()) ? TQPoint(1,1) : *it2; d->selection->clear(); d->selection->setSheet( d->activeSheet ); - d->selection->initialize(QRect(newMarker, newAnchor)); + d->selection->initialize(TQRect(newMarker, newAnchor)); d->canvas->scrollToCell(newMarker); if (it3 != d->savedOffsets.end()) @@ -3871,7 +3871,7 @@ void View::setActiveSheet( Sheet * _t, bool updateSheet ) doc()->emitEndOperation( d->activeSheet->visibleRect( d->canvas ) ); } -void View::slotSheetRenamed( Sheet* sheet, const QString& old_name ) +void View::slotSheetRenamed( Sheet* sheet, const TQString& old_name ) { doc()->emitBeginOperation( false ); d->tabBar->renameTab( old_name, sheet->sheetName() ); @@ -3893,7 +3893,7 @@ void View::slotSheetShown( Sheet* ) doc()->emitEndOperation( d->activeSheet->visibleRect( d->canvas ) ); } -void View::changeSheet( const QString& _name ) +void View::changeSheet( const TQString& _name ) { if ( activeSheet()->sheetName() == _name ) return; @@ -3914,8 +3914,8 @@ void View::changeSheet( const QString& _name ) updateBorderButton(); //update visible area - d->vBorderWidget->repaint(); - d->hBorderWidget->repaint(); + d->vBorderWidget->tqrepaint(); + d->hBorderWidget->tqrepaint(); d->canvas->slotMaxColumn( d->activeSheet->maxColumn() ); d->canvas->slotMaxRow( d->activeSheet->maxRow() ); t->setRegionPaintDirty( t->visibleRect( d->canvas ) ); @@ -3926,7 +3926,7 @@ void View::moveSheet( unsigned sheet, unsigned target ) { if( doc()->map()->isProtected() ) return; - QStringList vs = doc()->map()->visibleSheets(); + TQStringList vs = doc()->map()->visibleSheets(); if( target >= vs.count() ) doc()->map()->moveSheet( vs[ sheet ], vs[ vs.count()-1 ], false ); @@ -3945,7 +3945,7 @@ void View::sheetProperties() bool directionChanged = false; SheetPropertiesDialog* dlg = new SheetPropertiesDialog( this ); - dlg->setLayoutDirection( d->activeSheet->layoutDirection() ); + dlg->setLayoutDirection( d->activeSheet->tqlayoutDirection() ); dlg->setAutoCalc( d->activeSheet->getAutoCalc() ); dlg->setShowGrid( d->activeSheet->getShowGrid() ); dlg->setShowPageBorders( d->activeSheet->isShowPageBorders() ); @@ -3961,10 +3961,10 @@ void View::sheetProperties() { SheetPropertiesCommand* command = new SheetPropertiesCommand( doc(), d->activeSheet ); - if ( d->activeSheet->layoutDirection() != dlg->layoutDirection() ) + if ( d->activeSheet->tqlayoutDirection() != dlg->tqlayoutDirection() ) directionChanged = true; - command->setLayoutDirection( dlg->layoutDirection() ); + command->setLayoutDirection( dlg->tqlayoutDirection() ); command->setAutoCalc( dlg->autoCalc() ); command->setShowGrid( dlg->showGrid() ); command->setShowPageBorders( dlg->showPageBorders() ); @@ -4026,10 +4026,10 @@ void View::hideSheet() return; } - QStringList vs = doc()->map()->visibleSheets(); - int i = vs.findIndex( d->activeSheet->tableName() ) - 1; + TQStringList vs = doc()->map()->visibleSheets(); + int i = vs.tqfindIndex( d->activeSheet->tableName() ) - 1; if( i < 0 ) i = 1; - QString sn = vs[i]; + TQString sn = vs[i]; doc()->emitBeginOperation(false); @@ -4094,7 +4094,7 @@ void View::cutSelection() doc()->emitEndOperation(); KMacroCommand * macroCommand = 0L; - QPtrListIterator<EmbeddedObject> it( doc()->embeddedObjects() ); + TQPtrListIterator<EmbeddedObject> it( doc()->embeddedObjects() ); for ( ; it.current() ; ++it ) { if ( it.current()->sheet() == canvasWidget()->activeSheet() && it.current()->isSelected() ) @@ -4135,23 +4135,23 @@ void View::paste() if (!koDocument()->isReadWrite()) // don't paste into a read only document return; - QMimeSource *data = QApplication::clipboard()->data( QClipboard::Clipboard ); + TQMimeSource *data = TQApplication::tqclipboard()->data( TQClipboard::Clipboard ); for ( int i=0; data->format(i) != 0; i++ ) kdDebug() << "format:" << data->format(i) << endl; if ( data->provides( KoStoreDrag::mimeType("application/vnd.oasis.opendocument.spreadsheet" ) )) { canvasWidget()->deselectAllObjects(); - QCString returnedTypeMime = "application/vnd.oasis.opendocument.spreadsheet"; - const QByteArray arr = data->encodedData( returnedTypeMime ); + TQCString returnedTypeMime = "application/vnd.oasis.opendocument.spreadsheet"; + const TQByteArray arr = data->tqencodedData( returnedTypeMime ); if( arr.isEmpty() ) return; - QBuffer buffer( arr ); - KoStore * store = KoStore::createStore( &buffer, KoStore::Read ); + TQBuffer buffer( arr ); + KoStore * store = KoStore::createStore( TQT_TQIODEVICE(&buffer), KoStore::Read ); KoOasisStore oasisStore( store ); - QDomDocument doc; - QString errorMessage; + TQDomDocument doc; + TQString errorMessage; bool ok = oasisStore.loadAndParse( "content.xml", doc, errorMessage ); if ( !ok ) { kdError(32001) << "Error parsing content.xml: " << errorMessage << endl; @@ -4159,7 +4159,7 @@ void View::paste() } KoOasisStyles oasisStyles; - QDomDocument stylesDoc; + TQDomDocument stylesDoc; (void)oasisStore.loadAndParse( "styles.xml", stylesDoc, errorMessage ); // Load styles from style.xml oasisStyles.createStyleMap( stylesDoc, true ); @@ -4167,20 +4167,20 @@ void View::paste() oasisStyles.createStyleMap( doc, false ); // from KSpreadDoc::loadOasis: - QDomElement content = doc.documentElement(); - QDomElement realBody ( KoDom::namedItemNS( content, KoXmlNS::office, "body" ) ); + TQDomElement content = doc.documentElement(); + TQDomElement realBody ( KoDom::namedItemNS( content, KoXmlNS::office, "body" ) ); if ( realBody.isNull() ) { kdDebug() << "Invalid OASIS OpenDocument file. No office:body tag found." << endl; return; } - QDomElement body = KoDom::namedItemNS( realBody, KoXmlNS::office, "spreadsheet" ); + TQDomElement body = KoDom::namedItemNS( realBody, KoXmlNS::office, "spreadsheet" ); if ( body.isNull() ) { kdError(32001) << "No office:spreadsheet found!" << endl; - QDomElement childElem; - QString localName; + TQDomElement childElem; + TQString localName; forEachElement( childElem, realBody ) { localName = childElem.localName(); } @@ -4206,7 +4206,7 @@ void View::paste() else { //TODO: What if the clipboard data is available in both pixmap and OASIS format? (ie. for embedded parts) - QPixmap clipboardPixmap = QApplication::clipboard()->pixmap( QClipboard::Clipboard ); + TQPixmap clipboardPixmap = TQApplication::tqclipboard()->pixmap( TQClipboard::Clipboard ); if (!clipboardPixmap.isNull()) { d->activeSheet->insertPicture( markerDocumentPosition() , clipboardPixmap ); @@ -4269,7 +4269,7 @@ void View::changeAngle() return; AngleDialog dlg( this, "Angle" , - QPoint( d->canvas->markerColumn(), d->canvas->markerRow() )); + TQPoint( d->canvas->markerColumn(), d->canvas->markerRow() )); if ( dlg.exec() ) { //TODO Stefan: where is the angle operation? @@ -4364,7 +4364,7 @@ void View::goalSeek() } GoalSeekDialog * dlg - = new GoalSeekDialog( this, QPoint( d->canvas->markerColumn(), + = new GoalSeekDialog( this, TQPoint( d->canvas->markerColumn(), d->canvas->markerRow() ), "GoalSeekDialog" ); dlg->show(); @@ -4376,7 +4376,7 @@ void View::subtotals() if (!activeSheet()) return; - QRect selection( d->selection->selection() ); + TQRect selection( d->selection->selection() ); if ( ( selection.width() < 2 ) || ( selection.height() < 2 ) ) { KMessageBox::error( this, i18n("You must select multiple cells.") ); @@ -4388,7 +4388,7 @@ void View::subtotals() { doc()->emitBeginOperation( false ); - d->selection->initialize( QRect(dlg.selection().topLeft(), dlg.selection().bottomRight()));//, dlg.sheet() ); + d->selection->initialize( TQRect(dlg.selection().topLeft(), dlg.selection().bottomRight()));//, dlg.sheet() ); doc()->emitEndOperation( selection ); } } @@ -4410,7 +4410,7 @@ void View::textToColumns() d->canvas->closeEditor(); - QRect area=d->selection->selection(); + TQRect area=d->selection->selection(); //Only use the first column area.setRight(area.left()); @@ -4452,7 +4452,7 @@ void View::gotoCell() dlg.exec(); } -void View::find() +void View::tqfind() { if (!activeSheet()) return; @@ -4469,10 +4469,10 @@ void View::find() d->directionValue = dlg.searchDirection(); // Create the KFind object - delete d->find; - delete d->replace; - d->find = new KFind( dlg.pattern(), dlg.options(), this ); - d->replace = 0L; + delete d->tqfind; + delete d->tqreplace; + d->tqfind = new KFind( dlg.pattern(), dlg.options(), this ); + d->tqreplace = 0L; d->searchInSheets.currentSheet = activeSheet(); d->searchInSheets.firstSheet = d->searchInSheets.currentSheet; @@ -4481,46 +4481,46 @@ void View::find() findNext(); } -// Initialize a find or replace operation, using d->find or d->replace, +// Initialize a find or replace operation, using d->find or d->tqreplace, // and d->findOptions. void View::initFindReplace() { - KFind* findObj = d->find ? d->find : d->replace; + KFind* findObj = d->tqfind ? d->tqfind : d->tqreplace; Q_ASSERT( findObj ); - connect(findObj, SIGNAL( highlight( const QString &, int, int ) ), - this, SLOT( slotHighlight( const QString &, int, int ) ) ); - connect(findObj, SIGNAL( findNext() ), - this, SLOT( findNext() ) ); + connect(findObj, TQT_SIGNAL( highlight( const TQString &, int, int ) ), + this, TQT_SLOT( slotHighlight( const TQString &, int, int ) ) ); + connect(findObj, TQT_SIGNAL( findNext() ), + this, TQT_SLOT( findNext() ) ); bool bck = d->findOptions & KFindDialog::FindBackwards; Sheet* currentSheet = d->searchInSheets.currentSheet; - QRect region = ( d->findOptions & KFindDialog::SelectedText ) + TQRect region = ( d->findOptions & KFindDialog::SelectedText ) ? d->selection->selection() - : QRect( 1, 1, currentSheet->maxColumn(), currentSheet->maxRow() ); // All cells + : TQRect( 1, 1, currentSheet->maxColumn(), currentSheet->maxRow() ); // All cells int colStart = !bck ? region.left() : region.right(); int colEnd = !bck ? region.right() : region.left(); int rowStart = !bck ? region.top() :region.bottom(); int rowEnd = !bck ? region.bottom() : region.top(); if ( d->findOptions & KFindDialog::FromCursor ) { - QPoint marker( d->selection->marker() ); + TQPoint marker( d->selection->marker() ); colStart = marker.x(); rowStart = marker.y(); } d->findLeftColumn = region.left(); d->findRightColumn = region.right(); - d->findPos = QPoint( colStart, rowStart ); - d->findEnd = QPoint( colEnd, rowEnd ); + d->findPos = TQPoint( colStart, rowStart ); + d->findEnd = TQPoint( colEnd, rowEnd ); //kdDebug() << k_funcinfo << d->findPos << " to " << d->findEnd << endl; //kdDebug() << k_funcinfo << "leftcol=" << d->findLeftColumn << " rightcol=" << d->findRightColumn << endl; } void View::findNext() { - KFind* findObj = d->find ? d->find : d->replace; + KFind* findObj = d->tqfind ? d->tqfind : d->tqreplace; if ( !findObj ) { - find(); + tqfind(); return; } KFind::Result res = KFind::NoMatch; @@ -4534,15 +4534,15 @@ void View::findNext() findObj->setData( cell->format()->comment( cell->column(), cell->row() ) ); else findObj->setData( cell->text() ); - d->findPos = QPoint( cell->column(), cell->row() ); + d->findPos = TQPoint( cell->column(), cell->row() ); //kdDebug() << "setData(cell " << d->findPos << ")" << endl; } // Let KFind inspect the text fragment, and display a dialog if a match is found - if ( d->find ) - res = d->find->find(); + if ( d->tqfind ) + res = d->tqfind->find(); else - res = d->replace->replace(); + res = d->tqreplace->replace(); if ( res == KFind::NoMatch ) { // Go to next cell, skipping unwanted cells @@ -4574,10 +4574,10 @@ void View::findNext() findNext(); } else { // done, close the 'find next' dialog - if ( d->find ) - d->find->closeFindNextDialog(); + if ( d->tqfind ) + d->tqfind->closeFindNextDialog(); else - d->replace->closeReplaceNextDialog(); + d->tqreplace->closeReplaceNextDialog(); } } } @@ -4660,9 +4660,9 @@ Cell* View::findNextCell() void View::findPrevious() { - KFind* findObj = d->find ? d->find : d->replace; + KFind* findObj = d->tqfind ? d->tqfind : d->tqreplace; if ( !findObj ) { - find(); + tqfind(); return; } //kdDebug() << "findPrevious" << endl; @@ -4678,7 +4678,7 @@ void View::findPrevious() d->findOptions = opt; // restore initial options } -void View::replace() +void View::tqreplace() { if (!d->activeSheet) return; @@ -4694,26 +4694,26 @@ void View::replace() d->replaceStrings = dlg.replacementHistory(); d->typeValue = dlg.searchType(); - delete d->find; - delete d->replace; - d->find = 0L; + delete d->tqfind; + delete d->tqreplace; + d->tqfind = 0L; // NOTE Stefan: Avoid beginning of line replacements with nothing which // will lead to an infinite loop (Bug #125535). The reason // for this is unclear to me, but who cares and who would // want to do something like this, häh?! if (dlg.pattern() == "^" && dlg.replacement().isEmpty()) return; - d->replace = new KReplace( dlg.pattern(), dlg.replacement(), dlg.options() ); + d->tqreplace = new KReplace( dlg.pattern(), dlg.replacement(), dlg.options() ); d->searchInSheets.currentSheet = activeSheet(); d->searchInSheets.firstSheet = d->searchInSheets.currentSheet; initFindReplace(); - connect( d->replace, SIGNAL( replace( const QString &, int, int, int ) ), - this, SLOT( slotReplace( const QString &, int, int, int ) ) ); + connect( d->tqreplace, TQT_SIGNAL( tqreplace( const TQString &, int, int, int ) ), + this, TQT_SLOT( slotReplace( const TQString &, int, int, int ) ) ); if ( !doc()->undoLocked() ) { - QRect region( d->findPos, d->findEnd ); + TQRect region( d->findPos, d->findEnd ); //TODO create undo/redo for comment UndoChangeAreaTextCell *undo = new UndoChangeAreaTextCell( doc(), d->searchInSheets.currentSheet, region ); doc()->addCommand( undo ); @@ -4733,21 +4733,21 @@ void View::replace() #endif } -void View::slotHighlight( const QString &/*text*/, int /*matchingIndex*/, int /*matchedLength*/ ) +void View::slotHighlight( const TQString &/*text*/, int /*matchingIndex*/, int /*matchedLength*/ ) { d->selection->initialize( d->findPos ); KDialogBase *baseDialog=0L; - if ( d->find ) - baseDialog = d->find->findNextDialog(); + if ( d->tqfind ) + baseDialog = d->tqfind->findNextDialog(); else - baseDialog = d->replace->replaceNextDialog(); + baseDialog = d->tqreplace->replaceNextDialog(); kdDebug()<<" baseDialog :"<<baseDialog<<endl; - QRect globalRect( d->findPos, d->findEnd ); + TQRect globalRect( d->findPos, d->findEnd ); globalRect.moveTopLeft( canvasWidget()->mapToGlobal( globalRect.topLeft() ) ); - KDialog::avoidArea( baseDialog, QRect( d->findPos, d->findEnd )); + KDialog::avoidArea( baseDialog, TQRect( d->findPos, d->findEnd )); } -void View::slotReplace( const QString &newText, int, int, int ) +void View::slotReplace( const TQString &newText, int, int, int ) { // Which cell was this again? Cell *cell = d->searchInSheets.currentSheet->cellAt( d->findPos ); @@ -4763,7 +4763,7 @@ void View::slotReplace( const QString &newText, int, int, int ) void View::conditional() { - QRect rect( d->selection->selection() ); + TQRect rect( d->selection->selection() ); if ( util_isRowOrColumnSelected(rect)) { @@ -4778,7 +4778,7 @@ void View::conditional() void View::validity() { - QRect rect( d->selection->selection() ); + TQRect rect( d->selection->selection() ); if (d->selection->isColumnOrRowSelected()) { @@ -4795,7 +4795,7 @@ void View::validity() void View::insertSeries() { d->canvas->closeEditor(); - SeriesDlg dlg( this, "Series", QPoint( d->canvas->markerColumn(), d->canvas->markerRow() ) ); + SeriesDlg dlg( this, "Series", TQPoint( d->canvas->markerColumn(), d->canvas->markerRow() ) ); dlg.exec(); } @@ -4813,12 +4813,12 @@ void View::sort() void View::removeHyperlink() { - QPoint marker( d->selection->marker() ); + TQPoint marker( d->selection->marker() ); Cell * cell = d->activeSheet->cellAt( marker ); if( !cell ) return; if( cell->link().isEmpty() ) return; - LinkCommand* command = new LinkCommand( cell, QString::null, QString::null ); + LinkCommand* command = new LinkCommand( cell, TQString(), TQString() ); doc()->addCommand( command ); command->execute(); @@ -4833,7 +4833,7 @@ void View::insertHyperlink() d->canvas->closeEditor(); - QPoint marker( d->selection->marker() ); + TQPoint marker( d->selection->marker() ); Cell* cell = d->activeSheet->cellAt( marker ); LinkDialog* dlg = new LinkDialog( this ); @@ -4865,16 +4865,16 @@ void View::insertHyperlink() void View::insertFromDatabase() { -#ifndef QT_NO_SQL +#ifndef TQT_NO_SQL d->canvas->closeEditor(); - QRect rect = d->selection->selection(); + TQRect rect = d->selection->selection(); - QStringList str = QSqlDatabase::drivers(); + TQStringList str = TQSqlDatabase::drivers(); if ( str.isEmpty() ) { KMessageBox::error( this, i18n("No database drivers available. To use this feature you need " - "to install the necessary Qt 3 database drivers.") ); + "to install the necessary TQt 3 database drivers.") ); return; } @@ -4914,7 +4914,7 @@ void View::setupPrinter( KPrinter &prt ) SheetPrint* print = d->activeSheet->print(); - //apply page layout parameters + //apply page tqlayout parameters KoFormat pageFormat = print->paperFormat(); prt.setPageSize( static_cast<KPrinter::PageSize>( KoPageFormat::printerPageSize( pageFormat ) ) ); @@ -4932,7 +4932,7 @@ void View::setupPrinter( KPrinter &prt ) prt.addDialogPage(sheetpage); // kdDebug() << "Iterating through available sheets and initializing list of available sheets." << endl; - QPtrList<Sheet> sheetlist = doc()->map()->sheetList(); + TQPtrList<Sheet> sheetlist = doc()->map()->sheetList(); Sheet* sheet = sheetlist.last(); while ( sheet ) { @@ -4951,7 +4951,7 @@ void View::print( KPrinter &prt ) Sheet* selectedsheet = this->activeSheet(); //print all sheets in the order given by the print dialog (Sheet Selection) - QStringList sheetlist = KPSheetSelectPage::selectedSheets(prt); + TQStringList sheetlist = KPSheetSelectPage::selectedSheets(prt); if (sheetlist.empty()) { @@ -4959,19 +4959,19 @@ void View::print( KPrinter &prt ) sheetlist.append(d->activeSheet->sheetName()); } - QPainter painter; + TQPainter painter; painter.begin( &prt ); bool firstpage = true; - QStringList::iterator sheetlistiterator; + TQStringList::iterator sheetlistiterator; for (sheetlistiterator = sheetlist.begin(); sheetlistiterator != sheetlist.end(); ++sheetlistiterator) { kdDebug() << " printing sheet " << *sheetlistiterator << endl; Sheet* sheet = doc()->map()->findSheet(*sheetlistiterator); if (sheet == NULL) { - kdWarning() << i18n("Sheet %1 could not be found for printing").arg(*sheetlistiterator) << endl; + kdWarning() << i18n("Sheet %1 could not be found for printing").tqarg(*sheetlistiterator) << endl; continue; } @@ -4999,7 +4999,7 @@ void View::print( KPrinter &prt ) // anyway (it's the PS driver that takes care of the printer resolution). //But KSpread uses fixed 300 dpis, so we can use it. - QPaintDeviceMetrics metrics( &prt ); + TQPaintDeviceMetrics metrics( &prt ); int dpiX = metrics.logicalDpiX(); int dpiY = metrics.logicalDpiY(); @@ -5038,7 +5038,7 @@ void View::print( KPrinter &prt ) if( !prt.previewOnly() ) { KMessageBox::information( 0, - i18n("Nothing to print for sheet %1.").arg( + i18n("Nothing to print for sheet %1.").tqarg( d->activeSheet->sheetName()) ); //@todo: make sure we really can comment this out, // what to do with partially broken printouts? @@ -5051,13 +5051,13 @@ void View::print( KPrinter &prt ) this->setActiveSheet(selectedsheet); } -void View::insertChart( const QRect& _geometry, KoDocumentEntry& _e ) +void View::insertChart( const TQRect& _tqgeometry, KoDocumentEntry& _e ) { if ( !d->activeSheet ) return; // Transform the view coordinates to document coordinates - KoRect unzoomedRect = doc()->unzoomRect( _geometry ); + KoRect unzoomedRect = doc()->unzoomRect( _tqgeometry ); unzoomedRect.moveBy( d->canvas->xOffset(), d->canvas->yOffset() ); InsertObjectCommand *cmd = 0; @@ -5073,13 +5073,13 @@ void View::insertChart( const QRect& _geometry, KoDocumentEntry& _e ) cmd->execute(); } -void View::insertChild( const QRect& _geometry, KoDocumentEntry& _e ) +void View::insertChild( const TQRect& _tqgeometry, KoDocumentEntry& _e ) { if ( !d->activeSheet ) return; // Transform the view coordinates to document coordinates - KoRect unzoomedRect = doc()->unzoomRect( _geometry ); + KoRect unzoomedRect = doc()->unzoomRect( _tqgeometry ); unzoomedRect.moveBy( d->canvas->xOffset(), d->canvas->yOffset() ); InsertObjectCommand *cmd = new InsertObjectCommand( unzoomedRect, _e, d->canvas ); @@ -5089,7 +5089,7 @@ void View::insertChild( const QRect& _geometry, KoDocumentEntry& _e ) KoPoint View::markerDocumentPosition() { - QPoint marker=selectionInfo()->marker(); + TQPoint marker=selectionInfo()->marker(); return KoPoint( d->activeSheet->dblColumnPos(marker.x()), d->activeSheet->dblRowPos(marker.y()) ); @@ -5104,7 +5104,7 @@ void View::insertPicture() //This behaviour can be seen in other spreadsheets. //-- Robert Knight 12/02/06 <robertknight@gmail.com> - KURL file = KFileDialog::getImageOpenURL( QString::null, d->canvas ); + KURL file = KFileDialog::getImageOpenURL( TQString(), d->canvas ); if (file.isEmpty()) return; @@ -5127,7 +5127,7 @@ void View::slotUpdateChildGeometry( EmbeddedKOfficeObject */*_child*/ ) // Find frame for child ChildFrame *f = 0L; - QPtrListIterator<ChildFrame> it( m_lstFrames ); + TQPtrListIterator<ChildFrame> it( m_lstFrames ); for ( ; it.current() && !f; ++it ) if ( it.current()->child() == _child ) f = it.current(); @@ -5135,11 +5135,11 @@ void View::slotUpdateChildGeometry( EmbeddedKOfficeObject */*_child*/ ) assert( f != 0L ); // Are we already up to date ? - if ( _child->geometry() == f->partGeometry() ) + if ( _child->tqgeometry() == f->partGeometry() ) return; // TODO zooming - f->setPartGeometry( _child->geometry() ); + f->setPartGeometry( _child->tqgeometry() ); */ } @@ -5148,7 +5148,7 @@ void View::toggleProtectDoc( bool mode ) if ( !doc() || !doc()->map() ) return; - QCString passwd; + TQCString passwd; if ( mode ) { int result = KPasswordDialog::getNewPassword( passwd, i18n( "Protect Document" ) ); @@ -5158,8 +5158,8 @@ void View::toggleProtectDoc( bool mode ) return; } - QCString hash( "" ); - QString password( passwd ); + TQCString hash( "" ); + TQString password( passwd ); if ( password.length() > 0 ) SHA1::getHash( password, hash ); doc()->map()->setProtected( hash ); @@ -5173,8 +5173,8 @@ void View::toggleProtectDoc( bool mode ) return; } - QCString hash( "" ); - QString password( passwd ); + TQCString hash( "" ); + TQString password( passwd ); if ( password.length() > 0 ) SHA1::getHash( password, hash ); if ( !doc()->map()->checkPassword( hash ) ) @@ -5184,7 +5184,7 @@ void View::toggleProtectDoc( bool mode ) return; } - doc()->map()->setProtected( QCString() ); + doc()->map()->setProtected( TQCString() ); } doc()->setModified( true ); @@ -5196,7 +5196,7 @@ void View::toggleProtectSheet( bool mode ) if ( !d->activeSheet ) return; - QCString passwd; + TQCString passwd; if ( mode ) { int result = KPasswordDialog::getNewPassword( passwd, i18n( "Protect Sheet" ) ); @@ -5206,8 +5206,8 @@ void View::toggleProtectSheet( bool mode ) return; } - QCString hash( "" ); - QString password( passwd ); + TQCString hash( "" ); + TQString password( passwd ); if ( password.length() > 0 ) SHA1::getHash( password, hash ); @@ -5222,8 +5222,8 @@ void View::toggleProtectSheet( bool mode ) return; } - QCString hash( "" ); - QString password( passwd ); + TQCString hash( "" ); + TQString password( passwd ); if ( password.length() > 0 ) SHA1::getHash( password, hash ); @@ -5234,12 +5234,12 @@ void View::toggleProtectSheet( bool mode ) return; } - d->activeSheet->setProtected( QCString() ); + d->activeSheet->setProtected( TQCString() ); } doc()->setModified( true ); d->adjustActions( !mode ); doc()->emitBeginOperation(); - // d->activeSheet->setRegionPaintDirty( QRect(QPoint( 0, 0 ), QPoint( KS_colMax, KS_rowMax ) ) ); + // d->activeSheet->setRegionPaintDirty( TQRect(TQPoint( 0, 0 ), TQPoint( KS_colMax, KS_rowMax ) ) ); refreshView(); updateEditWidget(); doc()->emitEndOperation( d->activeSheet->visibleRect( d->canvas ) ); @@ -5255,13 +5255,13 @@ void View::togglePageBorders( bool mode ) doc()->emitEndOperation( d->activeSheet->visibleRect( d->canvas ) ); } -void View::viewZoom( const QString & s ) +void View::viewZoom( const TQString & s ) { int oldZoom = doc()->zoom(); bool ok = false; - QRegExp regexp("(\\d+)"); // "Captured" non-empty sequence of digits + TQRegExp regexp("(\\d+)"); // "Captured" non-empty sequence of digits regexp.search(s); int newZoom=regexp.cap(1).toInt(&ok); if ( !ok || newZoom < 10 ) //zoom should be valid and >10 @@ -5277,7 +5277,7 @@ void View::viewZoom( const QString & s ) if (activeSheet()) { - QRect r( d->activeSheet->visibleRect( d->canvas ) ); + TQRect r( d->activeSheet->visibleRect( d->canvas ) ); r.setWidth( r.width() + 2 ); doc()->emitEndOperation( r ); } @@ -5297,7 +5297,7 @@ void View::setZoom( int zoom, bool /*updateViews*/ ) Q_ASSERT(d->activeSheet); if (d->activeSheet) //this is 0 when viewing a document in konqueror!? (see Q_ASSERT above) - d->activeSheet->setRegionPaintDirty(QRect(QPoint(0,0), QPoint(KS_colMax, KS_rowMax))); + d->activeSheet->setRegionPaintDirty(TQRect(TQPoint(0,0), TQPoint(KS_colMax, KS_rowMax))); doc()->refreshInterface(); doc()->emitEndOperation(); @@ -5341,13 +5341,13 @@ void View::addModifyComment() return; CommentDialog dlg( this, "comment", - QPoint( d->canvas->markerColumn(), + TQPoint( d->canvas->markerColumn(), d->canvas->markerRow() ) ); if ( dlg.exec() ) updateEditWidget(); } -void View::setSelectionComment( QString comment ) +void View::setSelectionComment( TQString comment ) { if ( d->activeSheet != NULL ) { @@ -5369,7 +5369,7 @@ void View::editCell() d->canvas->createEditor(true); } -bool View::showSheet(const QString& sheetName) { +bool View::showSheet(const TQString& sheetName) { Sheet *t=doc()->map()->findSheet(sheetName); if ( !t ) { @@ -5438,37 +5438,37 @@ void View::lastSheet() d->tabBar->ensureVisible( t->sheetName() ); } -void View::keyPressEvent ( QKeyEvent* _ev ) +void View::keyPressEvent ( TQKeyEvent* _ev ) { // Dont eat accelerators - if ( _ev->state() & ( Qt::AltButton | Qt::ControlButton ) ) + if ( _ev->state() & ( TQt::AltButton | TQt::ControlButton ) ) { - if ( _ev->state() & ( Qt::ControlButton ) ) + if ( _ev->state() & ( TQt::ControlButton ) ) { switch( _ev->key() ) { #ifndef NDEBUG - case Qt::Key_V: // Ctrl+Shift+V to show debug (similar to KWord) - if ( _ev->state() & Qt::ShiftButton ) + case TQt::Key_V: // Ctrl+Shift+V to show debug (similar to KWord) + if ( _ev->state() & TQt::ShiftButton ) d->activeSheet->printDebug(); #endif default: - QWidget::keyPressEvent( _ev ); + TQWidget::keyPressEvent( _ev ); return; } } - QWidget::keyPressEvent( _ev ); + TQWidget::keyPressEvent( _ev ); } else - QApplication::sendEvent( d->canvas, _ev ); + TQApplication::sendEvent( d->canvas, _ev ); } -KoDocument * View::hitTest( const QPoint& /*pos*/ ) +KoDocument * View::hitTest( const TQPoint& /*pos*/ ) { // // Code copied from KoView::hitTest // KoViewChild *viewChild; // -// QWMatrix m = matrix(); +// TQWMatrix m = matrix(); // m.translate( d->canvas->xOffset() / doc()->zoomedResolutionX(), // d->canvas->yOffset() / doc()->zoomedResolutionY() ); // @@ -5477,11 +5477,11 @@ KoDocument * View::hitTest( const QPoint& /*pos*/ ) // { // if ( ( viewChild = child( docChild->document() ) ) ) // { -// if ( viewChild->frameRegion( m ).contains( pos ) ) +// if ( viewChild->frameRegion( m ).tqcontains( pos ) ) // return 0; // } // else -// if ( docChild->frameRegion( m ).contains( pos ) ) +// if ( docChild->frameRegion( m ).tqcontains( pos ) ) // return 0; // } // @@ -5490,15 +5490,15 @@ KoDocument * View::hitTest( const QPoint& /*pos*/ ) // { // if ( ( viewChild = child( docChild->document() ) ) ) // { -// if ( viewChild->frameRegion( m ).contains( pos ) ) +// if ( viewChild->frameRegion( m ).tqcontains( pos ) ) // return 0; // } // else -// if ( docChild->frameRegion( m ).contains( pos ) ) +// if ( docChild->frameRegion( m ).tqcontains( pos ) ) // return 0; // } // -// QPtrListIterator<KoDocumentChild> it( doc()->children() ); +// TQPtrListIterator<KoDocumentChild> it( doc()->tqchildren() ); // for (; it.current(); ++it ) // { // // Is the child document on the visible sheet ? @@ -5568,32 +5568,32 @@ void View::refreshView() d->hBorderWidget->setMinimumHeight( doc()->zoomItY( KoGlobal::defaultFont().pointSizeFloat() + 5 ) ); d->vBorderWidget->setMinimumWidth( doc()->zoomItX( YBORDER_WIDTH ) ); - Sheet::LayoutDirection sheetDir = sheet->layoutDirection(); - bool interfaceIsRTL = QApplication::reverseLayout(); + Sheet::LayoutDirection sheetDir = sheet->tqlayoutDirection(); + bool interfaceIsRTL = TQApplication::reverseLayout(); kdDebug()<<" sheetDir == Sheet::LeftToRight :"<<( sheetDir == Sheet::LeftToRight )<<endl; if ((sheetDir == Sheet::LeftToRight && !interfaceIsRTL) || (sheetDir == Sheet::RightToLeft && interfaceIsRTL)) { - d->formulaBarLayout->setDirection( QBoxLayout::LeftToRight ); - d->viewLayout->setOrigin( QGridLayout::TopLeft ); - d->tabScrollBarLayout->setDirection( QBoxLayout::LeftToRight ); + d->formulaBarLayout->setDirection( TQBoxLayout::LeftToRight ); + d->viewLayout->setOrigin( TQGridLayout::TopLeft ); + d->tabScrollBarLayout->setDirection( TQBoxLayout::LeftToRight ); d->tabBar->setReverseLayout( interfaceIsRTL ); } else { - d->formulaBarLayout->setDirection( QBoxLayout::RightToLeft ); - d->viewLayout->setOrigin( QGridLayout::TopRight ); - d->tabScrollBarLayout->setDirection( QBoxLayout::RightToLeft ); + d->formulaBarLayout->setDirection( TQBoxLayout::RightToLeft ); + d->viewLayout->setOrigin( TQGridLayout::TopRight ); + d->tabScrollBarLayout->setDirection( TQBoxLayout::RightToLeft ); d->tabBar->setReverseLayout( !interfaceIsRTL ); } } -void View::resizeEvent( QResizeEvent * ) +void View::resizeEvent( TQResizeEvent * ) { } -void View::popupChildMenu( KoChild* child, const QPoint& /*global_pos*/ ) +void View::popupChildMenu( KoChild* child, const TQPoint& /*global_pos*/ ) { if ( !child ) return; @@ -5602,9 +5602,9 @@ void View::popupChildMenu( KoChild* child, const QPoint& /*global_pos*/ ) // d->popupChildObject = static_cast<EmbeddedKOfficeObject*>(child); // -// d->popupChild = new QPopupMenu( this ); +// d->popupChild = new TQPopupMenu( this ); // -// d->popupChild->insertItem( i18n("Delete Embedded Document"), this, SLOT( slotPopupDeleteChild() ) ); +// d->popupChild->insertItem( i18n("Delete Embedded Document"), this, TQT_SLOT( slotPopupDeleteChild() ) ); // // d->popupChild->popup( global_pos ); @@ -5630,7 +5630,7 @@ void View::slotPopupDeleteChild() // doc()->emitEndOperation( d->activeSheet->visibleRect( d->canvas ) ); } -void View::popupColumnMenu( const QPoint & _point ) +void View::popupColumnMenu( const TQPoint & _point ) { assert( d->activeSheet ); @@ -5639,7 +5639,7 @@ void View::popupColumnMenu( const QPoint & _point ) delete d->popupColumn ; - d->popupColumn = new QPopupMenu( this ); + d->popupColumn = new TQPopupMenu( this ); bool isProtected = d->activeSheet->isProtected(); @@ -5664,7 +5664,7 @@ void View::popupColumnMenu( const QPoint & _point ) } d->actions->resizeColumn->plug( d->popupColumn ); - d->popupColumn->insertItem( i18n("Adjust Column"), this, SLOT(slotPopupAdjustColumn() ) ); + d->popupColumn->insertItem( i18n("Adjust Column"), this, TQT_SLOT(slotPopupAdjustColumn() ) ); d->popupColumn->insertSeparator(); d->actions->insertColumn->plug( d->popupColumn ); d->actions->deleteColumn->plug( d->popupColumn ); @@ -5677,7 +5677,7 @@ void View::popupColumnMenu( const QPoint & _point ) Region::ConstIterator endOfList = d->selection->constEnd(); for (Region::ConstIterator it = d->selection->constBegin(); it != endOfList; ++it) { - QRect range = (*it)->rect().normalize(); + TQRect range = (*it)->rect().normalize(); int col; for (col = range.left(); col < range.right(); ++col) { @@ -5713,7 +5713,7 @@ void View::popupColumnMenu( const QPoint & _point ) } } - QObject::connect( d->popupColumn, SIGNAL(activated( int ) ), this, SLOT( slotActivateTool( int ) ) ); + TQT_BASE_OBJECT_NAME::connect( d->popupColumn, TQT_SIGNAL(activated( int ) ), this, TQT_SLOT( slotActivateTool( int ) ) ); d->popupColumn->popup( _point ); } @@ -5726,7 +5726,7 @@ void View::slotPopupAdjustColumn() d->activeSheet->adjustColumn(*selectionInfo()); } -void View::popupRowMenu( const QPoint & _point ) +void View::popupRowMenu( const TQPoint & _point ) { assert( d->activeSheet ); @@ -5735,7 +5735,7 @@ void View::popupRowMenu( const QPoint & _point ) delete d->popupRow ; - d->popupRow= new QPopupMenu(); + d->popupRow= new TQPopupMenu(); bool isProtected = d->activeSheet->isProtected(); @@ -5760,7 +5760,7 @@ void View::popupRowMenu( const QPoint & _point ) } d->actions->resizeRow->plug( d->popupRow ); - d->popupRow->insertItem( i18n("Adjust Row"), this, SLOT( slotPopupAdjustRow() ) ); + d->popupRow->insertItem( i18n("Adjust Row"), this, TQT_SLOT( slotPopupAdjustRow() ) ); d->popupRow->insertSeparator(); d->actions->insertRow->plug( d->popupRow ); d->actions->deleteRow->plug( d->popupRow ); @@ -5772,7 +5772,7 @@ void View::popupRowMenu( const QPoint & _point ) Region::ConstIterator endOfList = d->selection->constEnd(); for (Region::ConstIterator it = d->selection->constBegin(); it != endOfList; ++it) { - QRect range = (*it)->rect().normalize(); + TQRect range = (*it)->rect().normalize(); int row; for (row = range.top(); row < range.bottom(); ++row) { @@ -5808,7 +5808,7 @@ void View::popupRowMenu( const QPoint & _point ) } } - QObject::connect( d->popupRow, SIGNAL( activated( int ) ), this, SLOT( slotActivateTool( int ) ) ); + TQT_BASE_OBJECT_NAME::connect( d->popupRow, TQT_SIGNAL( activated( int ) ), this, TQT_SLOT( slotActivateTool( int ) ) ); d->popupRow->popup( _point ); } @@ -5829,12 +5829,12 @@ void View::slotListChoosePopupMenu( ) assert( d->activeSheet ); delete d->popupListChoose; - d->popupListChoose = new QPopupMenu(); + d->popupListChoose = new TQPopupMenu(); int id = 0; - QRect selection( d->selection->selection() ); + TQRect selection( d->selection->selection() ); Cell * cell = d->activeSheet->cellAt( d->canvas->markerColumn(), d->canvas->markerRow() ); - QString tmp = cell->text(); - QStringList itemList; + TQString tmp = cell->text(); + TQStringList itemList; for ( int col = selection.left(); col <= selection.right(); ++col ) { @@ -5847,7 +5847,7 @@ void View::slotListChoosePopupMenu( ) { if ( c->value().isString() && c->text() != tmp && !c->text().isEmpty() ) { - if ( itemList.findIndex( c->text() ) == -1 ) + if ( itemList.tqfindIndex( c->text() ) == -1 ) itemList.append(c->text()); } } @@ -5873,7 +5873,7 @@ void View::slotListChoosePopupMenu( ) } */ - for ( QStringList::Iterator it = itemList.begin(); it != itemList.end();++it ) + for ( TQStringList::Iterator it = itemList.begin(); it != itemList.end();++it ) d->popupListChoose->insertItem( (*it), id++ ); if ( id == 0 ) @@ -5886,28 +5886,28 @@ void View::slotListChoosePopupMenu( ) h = cell->extraHeight(); ty += h; - if ( d->activeSheet->layoutDirection()==Sheet::RightToLeft ) + if ( d->activeSheet->tqlayoutDirection()==Sheet::RightToLeft ) { tx = canvasWidget()->width() - tx; } - QPoint p( (int)tx, (int)ty ); - QPoint p2 = d->canvas->mapToGlobal( p ); + TQPoint p( (int)tx, (int)ty ); + TQPoint p2 = d->canvas->mapToGlobal( p ); - if ( d->activeSheet->layoutDirection()==Sheet::RightToLeft ) + if ( d->activeSheet->tqlayoutDirection()==Sheet::RightToLeft ) { - p2.setX( p2.x() - d->popupListChoose->sizeHint().width() + 1 ); + p2.setX( p2.x() - d->popupListChoose->tqsizeHint().width() + 1 ); } d->popupListChoose->popup( p2 ); - QObject::connect( d->popupListChoose, SIGNAL( activated( int ) ), - this, SLOT( slotItemSelected( int ) ) ); + TQT_BASE_OBJECT_NAME::connect( d->popupListChoose, TQT_SIGNAL( activated( int ) ), + this, TQT_SLOT( slotItemSelected( int ) ) ); } void View::slotItemSelected( int id ) { - QString tmp = d->popupListChoose->text( id ); + TQString tmp = d->popupListChoose->text( id ); int x = d->canvas->markerColumn(); int y = d->canvas->markerRow(); Cell * cell = d->activeSheet->nonDefaultCell( x, y ); @@ -5927,10 +5927,10 @@ void View::slotItemSelected( int id ) cell->setCellText( tmp ); d->editWidget->setText( tmp ); - doc()->emitEndOperation( QRect( x, y, 1, 1 ) ); + doc()->emitEndOperation( TQRect( x, y, 1, 1 ) ); } -void View::openPopupMenu( const QPoint & _point ) +void View::openPopupMenu( const TQPoint & _point ) { assert( d->activeSheet ); delete d->popupMenu; @@ -5938,7 +5938,7 @@ void View::openPopupMenu( const QPoint & _point ) if ( !koDocument()->isReadWrite() ) return; - d->popupMenu = new QPopupMenu(); + d->popupMenu = new TQPopupMenu(); EmbeddedObject *obj; if ( d->canvas->isObjectSelected() && ( obj = d->canvas->getObject( d->canvas->mapFromGlobal( _point ), d->activeSheet ) ) && obj->isSelected() ) @@ -5999,7 +5999,7 @@ void View::openPopupMenu( const QPoint & _point ) if (activeSheet()->testListChoose(selectionInfo())) { d->popupMenu->insertSeparator(); - d->popupMenu->insertItem( i18n("Selection List..."), this, SLOT( slotListChoosePopupMenu() ) ); + d->popupMenu->insertItem( i18n("Selection List..."), this, TQT_SLOT( slotListChoosePopupMenu() ) ); } } @@ -6011,15 +6011,15 @@ void View::openPopupMenu( const QPoint & _point ) { d->popupMenuFirstToolId = 10; int i = 0; - QValueList<KDataToolInfo> tools = KDataToolInfo::query( "QString", "text/plain", doc()->instance() ); + TQValueList<KDataToolInfo> tools = KDataToolInfo::query( TQSTRING_OBJECT_NAME_STRING, "text/plain", doc()->instance() ); if ( tools.count() > 0 ) { d->popupMenu->insertSeparator(); - QValueList<KDataToolInfo>::Iterator entry = tools.begin(); + TQValueList<KDataToolInfo>::Iterator entry = tools.begin(); for( ; entry != tools.end(); ++entry ) { - QStringList lst = (*entry).userCommands(); - QStringList::ConstIterator it = lst.begin(); + TQStringList lst = (*entry).userCommands(); + TQStringList::ConstIterator it = lst.begin(); // ### Torben: Insert pixmaps here, too for (; it != lst.end(); ++it ) @@ -6036,7 +6036,7 @@ void View::openPopupMenu( const QPoint & _point ) } } - QObject::connect( d->popupMenu, SIGNAL( activated( int ) ), this, SLOT( slotActivateTool( int ) ) ); + TQT_BASE_OBJECT_NAME::connect( d->popupMenu, TQT_SIGNAL( activated( int ) ), this, TQT_SLOT( slotActivateTool( int ) ) ); } } @@ -6060,9 +6060,9 @@ void View::slotActivateTool( int _id ) return; } - QString text = activeSheet()->getWordSpelling( selectionInfo() ); + TQString text = activeSheet()->getWordSpelling( selectionInfo() ); - if ( tool->run( entry->command, &text, "QString", "text/plain") ) + if ( tool->run( entry->command, &text, TQSTRING_OBJECT_NAME_STRING, "text/plain") ) { doc()->emitBeginOperation(false); @@ -6097,7 +6097,7 @@ void View::deleteSelection() void View::deleteSelectedObjects() { KMacroCommand * macroCommand = 0L; - QPtrListIterator<EmbeddedObject> it( doc()->embeddedObjects() ); + TQPtrListIterator<EmbeddedObject> it( doc()->embeddedObjects() ); for ( ; it.current() ; ++it ) { if ( it.current()->sheet() == canvasWidget()->activeSheet() && it.current()->isSelected() ) @@ -6245,14 +6245,14 @@ void View::defaultSelection() void View::slotInsert() { - QRect r( d->selection->selection() ); + TQRect r( d->selection->selection() ); InsertDialog dlg( this, "InsertDialog", r, InsertDialog::Insert ); dlg.exec(); } void View::slotRemove() { - QRect r( d->selection->selection() ); + TQRect r( d->selection->selection() ); InsertDialog dlg( this, "Remove", r, InsertDialog::Remove ); dlg.exec(); } @@ -6286,7 +6286,7 @@ void View::slotInsertCellCopy() void View::setAreaName() { - AreaDialog dlg( this, "Area Name",QPoint(d->canvas->markerColumn(), d->canvas->markerRow()) ); + AreaDialog dlg( this, "Area Name",TQPoint(d->canvas->markerColumn(), d->canvas->markerRow()) ); dlg.exec(); } @@ -6353,7 +6353,7 @@ void View::equalizeColumn() } -void View::layoutDlg() +void View::tqlayoutDlg() { if (!activeSheet()) return; @@ -6370,9 +6370,9 @@ void View::extraProperties() d->m_propertyEditor = new PropertyEditor( this, "KPrPropertyEditor", d->activeSheet, doc() ); d->m_propertyEditor->setCaption( i18n( "Properties" ) ); - connect( d->m_propertyEditor, SIGNAL( propertiesOk() ), this, SLOT( propertiesOk() ) ); + connect( d->m_propertyEditor, TQT_SIGNAL( propertiesOk() ), this, TQT_SLOT( propertiesOk() ) ); d->m_propertyEditor->exec(); - disconnect( d->m_propertyEditor, SIGNAL( propertiesOk() ), this, SLOT( propertiesOk() ) ); + disconnect( d->m_propertyEditor, TQT_SIGNAL( propertiesOk() ), this, TQT_SLOT( propertiesOk() ) ); delete d->m_propertyEditor; d->m_propertyEditor = 0; @@ -6401,7 +6401,7 @@ void View::styleDialog() d->activeSheet->setRegionPaintDirty( d->activeSheet->visibleRect( d->canvas ) ); } if ( d->canvas ) - d->canvas->repaint(); + d->canvas->tqrepaint(); } void View::paperLayoutDlg() @@ -6593,11 +6593,11 @@ void View::createStyleFromCell() if ( !d->activeSheet ) return; - QPoint p( d->selection->selection().topLeft() ); + TQPoint p( d->selection->selection().topLeft() ); Cell * cell = d->activeSheet->nonDefaultCell( p.x(), p.y() ); bool ok = false; - QString styleName( "" ); + TQString styleName( "" ); while( true ) { @@ -6629,12 +6629,12 @@ void View::createStyleFromCell() doc()->styleManager()->m_styles[ styleName ] = style; cell->format()->setStyle( style ); - QStringList lst( d->actions->selectStyle->items() ); + TQStringList lst( d->actions->selectStyle->items() ); lst.push_back( styleName ); d->actions->selectStyle->setItems( lst ); } -void View::styleSelected( const QString & style ) +void View::styleSelected( const TQString & style ) { if (d->activeSheet ) { @@ -6718,7 +6718,7 @@ void View::insertChart() KMessageBox::error( this, i18n("Area too large.")); return; } - QValueList<KoDocumentEntry> vec = KoDocumentEntry::query( true, "'KOfficeChart' in ServiceTypes" ); + TQValueList<KoDocumentEntry> vec = KoDocumentEntry::query( true, "'KOfficeChart' in ServiceTypes" ); if ( vec.isEmpty() ) { KMessageBox::error( this, i18n("No charting component registered.") ); @@ -6748,9 +6748,9 @@ void View::zoomMinus() if ( d->activeSheet != 0L ) d->activeSheet->setLayoutDirtyFlag(); - d->canvas->repaint(); - d->vBorderWidget->repaint(); - d->hBorderWidget->repaint(); + d->canvas->tqrepaint(); + d->vBorderWidget->tqrepaint(); + d->hBorderWidget->tqrepaint(); } void View::zoomPlus() @@ -6763,9 +6763,9 @@ void View::zoomPlus() if ( d->activeSheet != 0L ) d->activeSheet->setLayoutDirtyFlag(); - d->canvas->repaint(); - d->vBorderWidget->repaint(); - d->hBorderWidget->repaint(); + d->canvas->tqrepaint(); + d->vBorderWidget->tqrepaint(); + d->hBorderWidget->tqrepaint(); } */ @@ -6818,8 +6818,8 @@ void View::slotRename() } bool ok; - QString activeName = sheet->sheetName(); - QString newName = KInputDialog::getText( i18n("Rename Sheet"),i18n("Enter name:"), activeName, &ok, this ); + TQString activeName = sheet->sheetName(); + TQString newName = KInputDialog::getText( i18n("Rename Sheet"),i18n("Enter name:"), activeName, &ok, this ); if( !ok ) return; @@ -6830,11 +6830,11 @@ void View::slotRename() i18n("Change Sheet Name") ); newName = newName.simplifyWhiteSpace(); - int n = newName.find('-'); + int n = newName.tqfind('-'); if ( n > -1 ) newName[n] = '_'; - n = newName.find('!'); + n = newName.tqfind('!'); if ( n > -1 ) newName[n] = '_'; - n = newName.find('$'); + n = newName.tqfind('$'); if ( n > -1 ) newName[n] = '_'; newName = KInputDialog::getText( i18n("Rename Sheet"),i18n("Enter name:"), newName, &ok, this ); @@ -6874,7 +6874,7 @@ void View::slotRename() } } -void View::setText (const QString & _text, bool array) +void View::setText (const TQString & _text, bool array) { if ( d->activeSheet == 0L ) return; @@ -6911,9 +6911,9 @@ void View::slotAddSheet( Sheet *_sheet ) void View::slotRefreshView() { refreshView(); - d->canvas->repaint(); - d->vBorderWidget->repaint(); - d->hBorderWidget->repaint(); + d->canvas->tqrepaint(); + d->vBorderWidget->tqrepaint(); + d->hBorderWidget->tqrepaint(); } void View::slotUpdateView( Sheet *_sheet ) @@ -6928,7 +6928,7 @@ void View::slotUpdateView( Sheet *_sheet ) void View::slotUpdateView( Sheet * _sheet, const Region& region ) { - // qDebug("void View::slotUpdateView( Sheet *_sheet, const QRect& %i %i|%i %i )\n",_rect.left(),_rect.top(),_rect.right(),_rect.bottom()); + // qDebug("void View::slotUpdateView( Sheet *_sheet, const TQRect& %i %i|%i %i )\n",_rect.left(),_rect.top(),_rect.right(),_rect.bottom()); // Do we display this sheet ? if ( _sheet != d->activeSheet ) @@ -6941,7 +6941,7 @@ void View::slotUpdateView( Sheet * _sheet, const Region& region ) void View::slotUpdateView( EmbeddedObject *obj ) { - d->canvas->repaintObject( obj ); + d->canvas->tqrepaintObject( obj ); } void View::slotUpdateHBorder( Sheet * _sheet ) @@ -7023,7 +7023,7 @@ void View::slotChangeSelection(const KSpread::Region& changedRegion) // Send some event around. This is read for example // by the calculator plugin. // SelectionChanged ev(*selectionInfo(), activeSheet()->name()); -// QApplication::sendEvent( this, &ev ); +// TQApplication::sendEvent( this, &ev ); d->canvas->setSelectionChangePaintDirty( d->activeSheet, changedRegion ); d->vBorderWidget->update(); @@ -7080,7 +7080,7 @@ void View::calcStatusBarOp() Sheet * sheet = activeSheet(); ValueCalc* calc = d->doc->calc(); Value val; - QRect tmpRect(d->selection->selection()); + TQRect tmpRect(d->selection->selection()); MethodOfCalc tmpMethod = doc()->getTypeOfCalc(); if ( tmpMethod != NoneCalc ) { @@ -7114,8 +7114,8 @@ void View::calcStatusBarOp() } - QString res = d->doc->converter()->asString (val).asString (); - QString tmp; + TQString res = d->doc->converter()->asString (val).asString (); + TQString tmp; switch(tmpMethod ) { case SumOfNumber: @@ -7143,7 +7143,7 @@ void View::calcStatusBarOp() //doc()->emitBeginOperation(); if ( d->calcLabel ) - d->calcLabel->setText(QString(" ") + tmp + ' '); + d->calcLabel->setText(TQString(" ") + tmp + ' '); //doc()->emitEndOperation(); } @@ -7153,8 +7153,8 @@ void View::statusBarClicked(int _id) return; if ( _id == 0 ) //menu calc { - QPoint mousepos = QCursor::pos(); - ((QPopupMenu*)factory()->container( "calc_popup" , this ) )->popup( mousepos ); + TQPoint mousepos = TQCursor::pos(); + ((TQPopupMenu*)factory()->container( "calc_popup" , this ) )->popup( mousepos ); } } @@ -7194,9 +7194,9 @@ void View::menuCalc( bool ) } -QWMatrix View::matrix() const +TQWMatrix View::matrix() const { - QWMatrix m; + TQWMatrix m; m.scale( d->doc->zoomedResolutionX(), d->doc->zoomedResolutionY() ); m.translate( - d->canvas->xOffset(), - d->canvas->yOffset() ); @@ -7209,7 +7209,7 @@ void View::transformPart() if ( d->transformToolBox.isNull() ) { - d->transformToolBox = new KoTransformToolBox( selectedChild(), topLevelWidget() ); + d->transformToolBox = new KoTransformToolBox( selectedChild(), tqtopLevelWidget() ); d->transformToolBox->show(); d->transformToolBox->setDocumentChild( selectedChild() ); @@ -7236,7 +7236,7 @@ void View::slotChildSelected( KoDocumentChild* /*ch*/ ) doc()->emitBeginOperation( false ); - d->activeSheet->setRegionPaintDirty(QRect(QPoint(0,0), QPoint(KS_colMax, KS_rowMax))); + d->activeSheet->setRegionPaintDirty(TQRect(TQPoint(0,0), TQPoint(KS_colMax, KS_rowMax))); doc()->emitEndOperation(); paintUpdates(); @@ -7257,7 +7257,7 @@ void View::slotChildUnselected( KoDocumentChild* ) doc()->emitBeginOperation( false ); - d->activeSheet->setRegionPaintDirty(QRect(QPoint(0,0), QPoint(KS_colMax, KS_rowMax))); + d->activeSheet->setRegionPaintDirty(TQRect(TQPoint(0,0), TQPoint(KS_colMax, KS_rowMax))); doc()->emitEndOperation(); paintUpdates(); } @@ -7280,7 +7280,7 @@ DCOPObject * View::dcopObject() return d->dcop; } -QWidget * View::canvas() const +TQWidget * View::canvas() const { return canvasWidget(); } @@ -7319,7 +7319,7 @@ void View::guiActivateEvent( KParts::GUIActivateEvent *ev ) { /*if (d->calcLabel) { - disconnect(d->calcLabel,SIGNAL(pressed( int )),this,SLOT(statusBarClicked(int))); + disconnect(d->calcLabel,TQT_SIGNAL(pressed( int )),this,TQT_SLOT(statusBarClicked(int))); }*/ } } @@ -7327,7 +7327,7 @@ void View::guiActivateEvent( KParts::GUIActivateEvent *ev ) KoView::guiActivateEvent( ev ); } -void View::popupTabBarMenu( const QPoint & _point ) +void View::popupTabBarMenu( const TQPoint & _point ) { if ( !koDocument()->isReadWrite() || !factory() ) return; @@ -7354,7 +7354,7 @@ void View::popupTabBarMenu( const QPoint & _point ) d->actions->hideSheet->setEnabled( false ); d->actions->removeSheet->setEnabled( false ); } - static_cast<QPopupMenu*>(factory()->container("menupage_popup",this))->popup(_point); + static_cast<TQPopupMenu*>(factory()->container("menupage_popup",this))->popup(_point); } } @@ -7369,7 +7369,7 @@ void View::updateBorderButton() void View::removeSheet( Sheet *_t ) { doc()->emitBeginOperation(false); - QString m_tablName=_t->sheetName(); + TQString m_tablName=_t->sheetName(); d->tabBar->removeTab( m_tablName ); setActiveSheet( doc()->map()->findSheet( doc()->map()->visibleSheets().first() )); @@ -7382,7 +7382,7 @@ void View::removeSheet( Sheet *_t ) void View::insertSheet( Sheet* sheet ) { doc()->emitBeginOperation( false ); - QString tabName = sheet->sheetName(); + TQString tabName = sheet->sheetName(); if ( !sheet->isHidden() ) { d->tabBar->addTab( tabName ); @@ -7394,7 +7394,7 @@ void View::insertSheet( Sheet* sheet ) doc()->emitEndOperation( sheet->visibleRect( d->canvas ) ); } -QColor View::borderColor() const +TQColor View::borderColor() const { return d->actions->borderColor->color(); } @@ -7442,21 +7442,21 @@ void View::commandExecuted() calcStatusBarOp(); } -void View::initialiseMarkerFromSheet( Sheet *_sheet, const QPoint &point ) +void View::initialiseMarkerFromSheet( Sheet *_sheet, const TQPoint &point ) { - d->savedMarkers.replace( _sheet, point); + d->savedMarkers.tqreplace( _sheet, point); } -QPoint View::markerFromSheet( Sheet* sheet ) const +TQPoint View::markerFromSheet( Sheet* sheet ) const { - QMapIterator<Sheet*, QPoint> it = d->savedMarkers.find(sheet); - QPoint newMarker = (it == d->savedMarkers.end()) ? QPoint(1,1) : *it; + TQMapIterator<Sheet*, TQPoint> it = d->savedMarkers.tqfind(sheet); + TQPoint newMarker = (it == d->savedMarkers.end()) ? TQPoint(1,1) : *it; return newMarker; } KoPoint View::offsetFromSheet( Sheet* sheet ) const { - QMapIterator<Sheet*, KoPoint> it = d->savedOffsets.find(sheet); + TQMapIterator<Sheet*, KoPoint> it = d->savedOffsets.tqfind(sheet); KoPoint offset = (it == d->savedOffsets.end()) ? KoPoint() : *it; return offset; } @@ -7466,18 +7466,18 @@ void View::saveCurrentSheetSelection() /* save the current selection on this sheet */ if (d->activeSheet != NULL) { - d->savedAnchors.replace(d->activeSheet, d->selection->anchor()); + d->savedAnchors.tqreplace(d->activeSheet, d->selection->anchor()); kdDebug() << " Current scrollbar vert value: " << d->canvas->vertScrollBar()->value() << endl; kdDebug() << "Saving marker pos: " << d->selection->marker() << endl; - d->savedMarkers.replace(d->activeSheet, d->selection->marker()); - d->savedOffsets.replace(d->activeSheet, KoPoint(d->canvas->xOffset(), + d->savedMarkers.tqreplace(d->activeSheet, d->selection->marker()); + d->savedOffsets.tqreplace(d->activeSheet, KoPoint(d->canvas->xOffset(), d->canvas->yOffset())); } } -void View::handleDamages( const QValueList<Damage*>& damages ) +void View::handleDamages( const TQValueList<Damage*>& damages ) { - QValueList<Damage*>::ConstIterator it; + TQValueList<Damage*>::ConstIterator it; for( it = damages.begin(); it != damages.end(); ++it ) { Damage* damage = *it; @@ -7488,7 +7488,7 @@ void View::handleDamages( const QValueList<Damage*>& damages ) CellDamage* cd = static_cast<CellDamage*>( damage ); Cell* damagedCell = cd->cell(); Sheet* damagedSheet = damagedCell->sheet(); - QRect drect( damagedCell->column(), damagedCell->row(), 1, 1 ); + TQRect drect( damagedCell->column(), damagedCell->row(), 1, 1 ); damagedSheet->setRegionPaintDirty( drect ); paintUpdates(); } @@ -7505,8 +7505,8 @@ void View::handleDamages( const QValueList<Damage*>& damages ) b = damagedSheet->nextCellBinding() ) b->cellChanged( 0 ); - d->activeSheet->setRegionPaintDirty( QRect(QPoint(0,0), - QPoint(KS_colMax, KS_rowMax))); + d->activeSheet->setRegionPaintDirty( TQRect(TQPoint(0,0), + TQPoint(KS_colMax, KS_rowMax))); paintUpdates(); refreshView(); @@ -7535,9 +7535,9 @@ void View::runInspector() delete ins; } -QColor View::highlightColor() +TQColor View::highlightColor() { - return QApplication::palette().active().highlight().light( 175 ); + return TQApplication::tqpalette().active().highlight().light( 175 ); } } // namespace KSpread |