diff options
Diffstat (limited to 'karbon/karbon_view.cpp')
-rw-r--r-- | karbon/karbon_view.cpp | 110 |
1 files changed, 55 insertions, 55 deletions
diff --git a/karbon/karbon_view.cpp b/karbon/karbon_view.cpp index 64fc0e53..c5c02d66 100644 --- a/karbon/karbon_view.cpp +++ b/karbon/karbon_view.cpp @@ -159,7 +159,7 @@ KarbonView::KarbonView( KarbonPart* p, TQWidget* parent, const char* name ) reorganizeGUI(); - connect( p, TQT_SIGNAL( unitChanged( KoUnit::Unit ) ), TQT_TQOBJECT(this), TQT_SLOT( setUnit( KoUnit::Unit ) ) ); + connect( p, TQT_SIGNAL( unitChanged( KoUnit::Unit ) ), this, TQT_SLOT( setUnit( KoUnit::Unit ) ) ); // widgets: m_horizRuler = new VRuler( TQt::Horizontal, this ); @@ -171,7 +171,7 @@ KarbonView::KarbonView( KarbonPart* p, TQWidget* parent, const char* name ) connect( p, TQT_SIGNAL( unitChanged( KoUnit::Unit ) ), m_vertRuler, TQT_SLOT( setUnit( KoUnit::Unit ) ) ); m_canvas = new VCanvas( this, this, p ); - connect( m_canvas, TQT_SIGNAL( contentsMoving( int, int ) ), TQT_TQOBJECT(this), TQT_SLOT( canvasContentsMoving( int, int ) ) ); + connect( m_canvas, TQT_SIGNAL( contentsMoving( int, int ) ), this, TQT_SLOT( canvasContentsMoving( int, int ) ) ); m_canvas->show(); @@ -262,7 +262,7 @@ KarbonView::createContainer( TQWidget *parent, int index, const TQDomElement &el mainWindow()->addDockWindow( m_toolbox, dock, false); mainWindow()->moveDockWindow( m_toolbox, dock, false, 0, 0 ); - //connect( m_toolbox, TQT_SIGNAL( activeToolChanged( VTool * ) ), TQT_TQOBJECT(this), TQT_SLOT( slotActiveToolChanged( VTool * ) ) ); + //connect( m_toolbox, TQT_SIGNAL( activeToolChanged( VTool * ) ), this, TQT_SLOT( slotActiveToolChanged( VTool * ) ) ); if( shell() ) { @@ -272,17 +272,17 @@ KarbonView::createContainer( TQWidget *parent, int index, const TQDomElement &el connect( m_strokeFillPreview, TQT_SIGNAL( fillSelected() ), m_typeButtonBox, TQT_SLOT( setFill() ) ); connect( m_strokeFillPreview, TQT_SIGNAL( strokeSelected() ), m_typeButtonBox, TQT_SLOT( setStroke() ) ); - connect( m_strokeFillPreview, TQT_SIGNAL( strokeChanged( const VStroke & ) ), TQT_TQOBJECT(this), TQT_SLOT( slotStrokeChanged( const VStroke & ) ) ); - connect( m_strokeFillPreview, TQT_SIGNAL( fillChanged( const VFill & ) ), TQT_TQOBJECT(this), TQT_SLOT( slotFillChanged( const VFill & ) ) ); + connect( m_strokeFillPreview, TQT_SIGNAL( strokeChanged( const VStroke & ) ), this, TQT_SLOT( slotStrokeChanged( const VStroke & ) ) ); + connect( m_strokeFillPreview, TQT_SIGNAL( fillChanged( const VFill & ) ), this, TQT_SLOT( slotFillChanged( const VFill & ) ) ); connect( m_strokeFillPreview, TQT_SIGNAL( strokeSelected() ), m_ColorManager, TQT_SLOT( setStrokeDocker() ) ); connect( m_strokeFillPreview, TQT_SIGNAL( fillSelected( ) ), m_ColorManager, TQT_SLOT( setFillDocker() ) ); - connect( m_part->commandHistory(), TQT_SIGNAL( commandExecuted( VCommand* ) ), TQT_TQOBJECT(this), TQT_SLOT( commandExecuted( VCommand* ) ) ); + connect( m_part->commandHistory(), TQT_SIGNAL( commandExecuted( VCommand* ) ), this, TQT_SLOT( commandExecuted( VCommand* ) ) ); - connect( m_ColorManager, TQT_SIGNAL(modeChanged( KDualColorButton::DualColor)), TQT_TQOBJECT(this), TQT_SLOT( strokeFillSelectionChanged(KDualColorButton::DualColor) ) ); - connect( m_ColorManager, TQT_SIGNAL(bgColorChanged( const TQColor & )), TQT_TQOBJECT(this), TQT_SLOT(colorChanged( const TQColor & )) ); - connect( m_ColorManager, TQT_SIGNAL(fgColorChanged( const TQColor & )), TQT_TQOBJECT(this), TQT_SLOT(colorChanged( const TQColor & )) ); + connect( m_ColorManager, TQT_SIGNAL(modeChanged( KDualColorButton::DualColor)), this, TQT_SLOT( strokeFillSelectionChanged(KDualColorButton::DualColor) ) ); + connect( m_ColorManager, TQT_SIGNAL(bgColorChanged( const TQColor & )), this, TQT_SLOT(colorChanged( const TQColor & )) ); + connect( m_ColorManager, TQT_SIGNAL(fgColorChanged( const TQColor & )), this, TQT_SLOT(colorChanged( const TQColor & )) ); selectionChanged(); //create toolbars @@ -303,10 +303,10 @@ KarbonView::removeContainer( TQWidget *container, TQWidget *parent, if( shell() && container == m_toolbox ) { - disconnect( m_part->commandHistory(), TQT_SIGNAL( commandExecuted( VCommand* ) ), TQT_TQOBJECT(this), TQT_SLOT( commandExecuted( VCommand* ) ) ); - disconnect( m_ColorManager, TQT_SIGNAL(modeChanged( KDualColorButton::DualColor)), TQT_TQOBJECT(this), TQT_SLOT( strokeFillSelectionChanged(KDualColorButton::DualColor) ) ); - disconnect( m_ColorManager, TQT_SIGNAL(bgColorChanged( const TQColor & )), TQT_TQOBJECT(this), TQT_SLOT(colorChanged( const TQColor & )) ); - disconnect( m_ColorManager, TQT_SIGNAL(fgColorChanged( const TQColor & )), TQT_TQOBJECT(this), TQT_SLOT(colorChanged( const TQColor & )) ); + disconnect( m_part->commandHistory(), TQT_SIGNAL( commandExecuted( VCommand* ) ), this, TQT_SLOT( commandExecuted( VCommand* ) ) ); + disconnect( m_ColorManager, TQT_SIGNAL(modeChanged( KDualColorButton::DualColor)), this, TQT_SLOT( strokeFillSelectionChanged(KDualColorButton::DualColor) ) ); + disconnect( m_ColorManager, TQT_SIGNAL(bgColorChanged( const TQColor & )), this, TQT_SLOT(colorChanged( const TQColor & )) ); + disconnect( m_ColorManager, TQT_SIGNAL(fgColorChanged( const TQColor & )), this, TQT_SLOT(colorChanged( const TQColor & )) ); delete m_toolbox; m_toolbox = 0L; m_toolController->youAintGotNoToolBox(); @@ -940,11 +940,11 @@ KarbonView::initActions() { // view -----> m_viewAction = new TDESelectAction( - i18n( "View &Mode" ), 0, TQT_TQOBJECT(this), + i18n( "View &Mode" ), 0, this, TQT_SLOT( viewModeChanged() ), actionCollection(), "view_mode" ); m_zoomAction = new TDESelectAction( - i18n( "&Zoom" ), "viewmag", 0, TQT_TQOBJECT(this), + i18n( "&Zoom" ), "viewmag", 0, this, TQT_SLOT( zoomChanged() ), actionCollection(), "view_zoom" ); TQStringList mstl; @@ -975,8 +975,8 @@ KarbonView::initActions() m_zoomAction->setEditable( true ); m_zoomAction->setCurrentItem( 7 ); - KStdAction::zoomIn( TQT_TQOBJECT(this), TQT_SLOT( viewZoomIn() ), actionCollection(), "view_zoom_in" ); - KStdAction::zoomOut( TQT_TQOBJECT(this), TQT_SLOT( viewZoomOut() ), actionCollection(), "view_zoom_out" ); + KStdAction::zoomIn( this, TQT_SLOT( viewZoomIn() ), actionCollection(), "view_zoom_in" ); + KStdAction::zoomOut( this, TQT_SLOT( viewZoomOut() ), actionCollection(), "view_zoom_out" ); m_showPageMargins = new TDEToggleAction( i18n("Show Page Margins"), "view_margins", 0, actionCollection(), "view_show_margins" ); connect( m_showPageMargins, TQT_SIGNAL(toggled(bool)), TQT_SLOT(togglePageMargins(bool))); @@ -989,133 +989,133 @@ KarbonView::initActions() return; // edit -----> - KStdAction::cut( TQT_TQOBJECT(this), + KStdAction::cut( this, TQT_SLOT( editCut() ), actionCollection(), "edit_cut" ); - KStdAction::copy( TQT_TQOBJECT(this), + KStdAction::copy( this, TQT_SLOT( editCopy() ), actionCollection(), "edit_copy" ); - KStdAction::paste( TQT_TQOBJECT(this), + KStdAction::paste( this, TQT_SLOT( editPaste() ), actionCollection(), "edit_paste" ); - KStdAction::selectAll( TQT_TQOBJECT(this), TQT_SLOT( editSelectAll() ), actionCollection(), "edit_select_all" ); - KStdAction::deselect( TQT_TQOBJECT(this), TQT_SLOT( editDeselectAll() ), actionCollection(), "edit_deselect_all" ); + KStdAction::selectAll( this, TQT_SLOT( editSelectAll() ), actionCollection(), "edit_select_all" ); + KStdAction::deselect( this, TQT_SLOT( editDeselectAll() ), actionCollection(), "edit_deselect_all" ); new TDEAction( - i18n( "&Import Graphic..." ), 0, 0, TQT_TQOBJECT(this), + i18n( "&Import Graphic..." ), 0, 0, this, TQT_SLOT( fileImportGraphic() ), actionCollection(), "file_import" ); m_deleteSelectionAction = new TDEAction( - i18n( "D&elete" ), "edit-delete", TQKeySequence( "Del" ), TQT_TQOBJECT(this), + i18n( "D&elete" ), "edit-delete", TQKeySequence( "Del" ), this, TQT_SLOT( editDeleteSelection() ), actionCollection(), "edit_delete" ); new TDEAction( - i18n( "&History" ), 0, 0, TQT_TQOBJECT(this), + i18n( "&History" ), 0, 0, this, TQT_SLOT( editPurgeHistory() ), actionCollection(), "edit_purge_history" ); // edit <----- // object -----> new TDEAction( - i18n( "&Duplicate" ), "duplicate", TQKeySequence( "Ctrl+D" ), TQT_TQOBJECT(this), + i18n( "&Duplicate" ), "duplicate", TQKeySequence( "Ctrl+D" ), this, TQT_SLOT( selectionDuplicate() ), actionCollection(), "object_duplicate" ); new TDEAction( - i18n( "Bring to &Front" ), "bring_forward", TQKeySequence( "Ctrl+Shift+]" ), TQT_TQOBJECT(this), + i18n( "Bring to &Front" ), "bring_forward", TQKeySequence( "Ctrl+Shift+]" ), this, TQT_SLOT( selectionBringToFront() ), actionCollection(), "object_move_totop" ); new TDEAction( - i18n( "&Raise" ), "raise", TQKeySequence( "Ctrl+]" ), TQT_TQOBJECT(this), + i18n( "&Raise" ), "raise", TQKeySequence( "Ctrl+]" ), this, TQT_SLOT( selectionMoveUp() ), actionCollection(), "object_move_up" ); new TDEAction( - i18n( "&Lower" ), "lower", TQKeySequence( "Ctrl+[" ), TQT_TQOBJECT(this), + i18n( "&Lower" ), "lower", TQKeySequence( "Ctrl+[" ), this, TQT_SLOT( selectionMoveDown() ), actionCollection(), "object_move_down" ); new TDEAction( - i18n( "Send to &Back" ), "send_backward", TQKeySequence( "Ctrl+Shift+[" ), TQT_TQOBJECT(this), + i18n( "Send to &Back" ), "send_backward", TQKeySequence( "Ctrl+Shift+[" ), this, TQT_SLOT( selectionSendToBack() ), actionCollection(), "object_move_tobottom" ); new TDEAction( - i18n( "Align Left" ), "aoleft", 0, TQT_TQOBJECT(this), + i18n( "Align Left" ), "aoleft", 0, this, TQT_SLOT( selectionAlignHorizontalLeft() ), actionCollection(), "object_align_horizontal_left" ); new TDEAction( - i18n( "Align Center (Horizontal)" ), "aocenterh", 0, TQT_TQOBJECT(this), + i18n( "Align Center (Horizontal)" ), "aocenterh", 0, this, TQT_SLOT( selectionAlignHorizontalCenter() ), actionCollection(), "object_align_horizontal_center" ); new TDEAction( - i18n( "Align Right" ), "aoright", 0, TQT_TQOBJECT(this), + i18n( "Align Right" ), "aoright", 0, this, TQT_SLOT( selectionAlignHorizontalRight() ), actionCollection(), "object_align_horizontal_right" ); new TDEAction( - i18n( "Align Top" ), "aotop", 0, TQT_TQOBJECT(this), + i18n( "Align Top" ), "aotop", 0, this, TQT_SLOT( selectionAlignVerticalTop() ), actionCollection(), "object_align_vertical_top" ); new TDEAction( - i18n( "Align Middle (Vertical)" ), "aocenterv", 0, TQT_TQOBJECT(this), + i18n( "Align Middle (Vertical)" ), "aocenterv", 0, this, TQT_SLOT( selectionAlignVerticalCenter() ), actionCollection(), "object_align_vertical_center" ); new TDEAction( - i18n( "Align Bottom" ), "aobottom", 0, TQT_TQOBJECT(this), + i18n( "Align Bottom" ), "aobottom", 0, this, TQT_SLOT( selectionAlignVerticalBottom() ), actionCollection(), "object_align_vertical_bottom" ); new TDEAction( - i18n( "Distribute Center (Horizontal)" ), "", 0, TQT_TQOBJECT(this), + i18n( "Distribute Center (Horizontal)" ), "", 0, this, TQT_SLOT( selectionDistributeHorizontalCenter() ), actionCollection(), "object_distribute_horizontal_center" ); new TDEAction( - i18n( "Distribute Gaps (Horizontal)" ), "", 0, TQT_TQOBJECT(this), + i18n( "Distribute Gaps (Horizontal)" ), "", 0, this, TQT_SLOT( selectionDistributeHorizontalGap() ), actionCollection(), "object_distribute_horizontal_gap" ); new TDEAction( - i18n( "Distribute Left Borders" ), "", 0, TQT_TQOBJECT(this), + i18n( "Distribute Left Borders" ), "", 0, this, TQT_SLOT( selectionDistributeHorizontalLeft() ), actionCollection(), "object_distribute_horizontal_left" ); new TDEAction( - i18n( "Distribute Right Borders" ), "", 0, TQT_TQOBJECT(this), + i18n( "Distribute Right Borders" ), "", 0, this, TQT_SLOT( selectionDistributeHorizontalRight() ), actionCollection(), "object_distribute_horizontal_right" ); new TDEAction( - i18n( "Distribute Center (Vertical)" ), "", 0, TQT_TQOBJECT(this), + i18n( "Distribute Center (Vertical)" ), "", 0, this, TQT_SLOT( selectionDistributeVerticalCenter() ), actionCollection(), "object_distribute_vertical_center" ); new TDEAction( - i18n( "Distribute Gaps (Vertical)" ), "", 0, TQT_TQOBJECT(this), + i18n( "Distribute Gaps (Vertical)" ), "", 0, this, TQT_SLOT( selectionDistributeVerticalGap() ), actionCollection(), "object_distribute_vertical_gap" ); new TDEAction( - i18n( "Distribute Bottom Borders" ), "", 0, TQT_TQOBJECT(this), + i18n( "Distribute Bottom Borders" ), "", 0, this, TQT_SLOT( selectionDistributeVerticalBottom() ), actionCollection(), "object_distribute_vertical_bottom" ); new TDEAction( - i18n( "Distribute Top Borders" ), "", 0, TQT_TQOBJECT(this), + i18n( "Distribute Top Borders" ), "", 0, this, TQT_SLOT( selectionDistributeVerticalTop() ), actionCollection(), "object_distribute_vertical_top" ); - m_showRulerAction = new TDEToggleAction( i18n( "Show Rulers" ), 0, TQT_TQOBJECT(this), TQT_SLOT( showRuler() ), actionCollection(), "view_show_ruler" ); + m_showRulerAction = new TDEToggleAction( i18n( "Show Rulers" ), 0, this, TQT_SLOT( showRuler() ), actionCollection(), "view_show_ruler" ); #if KDE_IS_VERSION(3,2,90) m_showRulerAction->setCheckedState(i18n("Hide Rulers")); #endif m_showRulerAction->setToolTip( i18n( "Shows or hides rulers." ) ); m_showRulerAction->setChecked( false ); - m_showGridAction = new TDEToggleAction( i18n( "Show Grid" ), "view_grid", TQT_TQOBJECT(this), TQT_SLOT( showGrid() ), actionCollection(), "view_show_grid" ); + m_showGridAction = new TDEToggleAction( i18n( "Show Grid" ), "view_grid", this, TQT_SLOT( showGrid() ), actionCollection(), "view_show_grid" ); #if KDE_IS_VERSION(3,2,90) m_showGridAction->setCheckedState(i18n("Hide Grid")); #endif m_showGridAction->setToolTip( i18n( "Shows or hides grid." ) ); //m_showGridAction->setChecked( true ); - m_snapGridAction = new TDEToggleAction( i18n( "Snap to Grid" ), 0, TQT_TQOBJECT(this), TQT_SLOT( snapToGrid() ), actionCollection(), "view_snap_to_grid" ); + m_snapGridAction = new TDEToggleAction( i18n( "Snap to Grid" ), 0, this, TQT_SLOT( snapToGrid() ), actionCollection(), "view_snap_to_grid" ); m_snapGridAction->setToolTip( i18n( "Snaps to grid." ) ); //m_snapGridAction->setChecked( true ); m_groupObjects = new TDEAction( - i18n( "&Group Objects" ), "group", TQKeySequence( "Ctrl+G" ), TQT_TQOBJECT(this), + i18n( "&Group Objects" ), "group", TQKeySequence( "Ctrl+G" ), this, TQT_SLOT( groupSelection() ), actionCollection(), "selection_group" ); m_ungroupObjects = new TDEAction( - i18n( "&Ungroup Objects" ), "ungroup", TQKeySequence( "Ctrl+Shift+G" ), TQT_TQOBJECT(this), + i18n( "&Ungroup Objects" ), "ungroup", TQKeySequence( "Ctrl+Shift+G" ), this, TQT_SLOT( ungroupSelection() ), actionCollection(), "selection_ungroup" ); m_closePath = new TDEAction( - i18n( "&Close Path" ), TQKeySequence( "Ctrl+U" ), TQT_TQOBJECT(this), + i18n( "&Close Path" ), TQKeySequence( "Ctrl+U" ), this, TQT_SLOT( closePath() ), actionCollection(), "close_path" ); // object <----- // line style (dashes) - m_lineStyleAction = new KoLineStyleAction( i18n( "Line Style" ), "linestyle", TQT_TQOBJECT(this), TQT_SLOT( setLineStyle( int ) ), actionCollection(), "setLineStyle" ); + m_lineStyleAction = new KoLineStyleAction( i18n( "Line Style" ), "linestyle", this, TQT_SLOT( setLineStyle( int ) ), actionCollection(), "setLineStyle" ); // line width m_setLineWidth = new KoUnitDoubleSpinComboBox( this, 0.0, 1000.0, 0.5, 1.0, KoUnit::U_PT, 1 ); - new KWidgetAction( m_setLineWidth, i18n( "Set Line Width" ), 0, TQT_TQOBJECT(this), TQT_SLOT( setLineWidth() ), actionCollection(), "setLineWidth" ); + new KWidgetAction( m_setLineWidth, i18n( "Set Line Width" ), 0, this, TQT_SLOT( setLineWidth() ), actionCollection(), "setLineWidth" ); m_setLineWidth->insertItem( 0.25 ); m_setLineWidth->insertItem( 0.5 ); m_setLineWidth->insertItem( 0.75 ); @@ -1126,13 +1126,13 @@ KarbonView::initActions() m_setLineWidth->insertItem( 5.0 ); m_setLineWidth->insertItem( 10.0 ); m_setLineWidth->insertItem( 20.0 ); - connect( m_setLineWidth, TQT_SIGNAL( valueChanged( double ) ), TQT_TQOBJECT(this), TQT_SLOT( setLineWidth() ) ); + connect( m_setLineWidth, TQT_SIGNAL( valueChanged( double ) ), this, TQT_SLOT( setLineWidth() ) ); m_configureAction = new TDEAction( - i18n( "Configure Karbon..." ), "configure", 0, TQT_TQOBJECT(this), + i18n( "Configure Karbon..." ), "configure", 0, this, TQT_SLOT( configure() ), actionCollection(), "configure" ); - new TDEAction( i18n( "Page &Layout..." ), 0, TQT_TQOBJECT(this), + new TDEAction( i18n( "Page &Layout..." ), 0, this, TQT_SLOT( pageLayout() ), actionCollection(), "page_layout" ); m_contextHelpAction = new KoContextHelpAction( actionCollection(), this ); } |