]> Shamusworld >> Repos - architektonas/blobdiff - src/widgets/qg_actionhandler.cpp
In the middle of major refactoring...
[architektonas] / src / widgets / qg_actionhandler.cpp
index 2ddc8eba284c1e3fb8c05b7391e62746707664d2..de23f922cdd5a9122383bc2e4e48dea21da3a8a6 100644 (file)
 
 #include "rs_commandevent.h"
 #include "commands.h"
-#include "rs_actionblocksadd.h"
-#include "rs_actionblocksattributes.h"
-#include "rs_actionblockscreate.h"
-#include "rs_actionblocksedit.h"
-#include "rs_actionblocksexplode.h"
-#include "rs_actionblocksfreezeall.h"
-#include "rs_actionblocksinsert.h"
-#include "rs_actionblocksremove.h"
-#include "rs_actionblockstoggleview.h"
-#include "rs_actiondimaligned.h"
-#include "rs_actiondimangular.h"
-#include "rs_actiondimdiametric.h"
-#include "rs_actiondimleader.h"
-#include "rs_actiondimlinear.h"
-#include "rs_actiondimradial.h"
-#include "rs_actiondrawarc.h"
-#include "rs_actiondrawarc3p.h"
-#include "rs_actiondrawarctangential.h"
-#include "rs_actiondrawcircle.h"
-#include "rs_actiondrawcircle2p.h"
-#include "rs_actiondrawcircle3p.h"
-#include "rs_actiondrawcirclecr.h"
-#include "rs_actiondrawellipseaxis.h"
-#include "rs_actiondrawhatch.h"
-#include "rs_actiondrawimage.h"
-#include "rs_actiondrawline.h"
-#include "rs_actiondrawlineangle.h"
-#include "rs_actiondrawlinebisector.h"
-#include "rs_actiondrawlinefree.h"
-#include "rs_actiondrawlinehorvert.h"
-#include "rs_actiondrawlineparallel.h"
-#include "rs_actiondrawlineparallelthrough.h"
-#include "rs_actiondrawlinepolygon.h"
-#include "rs_actiondrawlinepolygon2.h"
-#include "rs_actiondrawlinerectangle.h"
-#include "rs_actiondrawlinerelangle.h"
-#include "rs_actiondrawlinetangent1.h"
-#include "rs_actiondrawlinetangent2.h"
-#include "rs_actiondrawpoint.h"
-#include "rs_actiondrawspline.h"
-#include "rs_actiondrawtext.h"
-#include "rs_actioneditcopy.h"
-#include "rs_actioneditpaste.h"
-#include "rs_actioneditundo.h"
-#include "rs_actionfileopen.h"
-#include "rs_actionfilesaveas.h"
-#include "rs_actioninfoangle.h"
-#include "rs_actioninfoarea.h"
-#include "rs_actioninfodist.h"
-#include "rs_actioninfodist2.h"
-#include "rs_actioninfoinside.h"
-#include "rs_actioninfototallength.h"
-#include "rs_actioninterface.h"
-#include "rs_actionlayersadd.h"
-#include "rs_actionlayersedit.h"
-#include "rs_actionlayersfreezeall.h"
-#include "rs_actionlayersremove.h"
-#include "rs_actionlayerstogglelock.h"
-#include "rs_actionlayerstoggleview.h"
-#include "rs_actionlibraryinsert.h"
-#include "rs_actionlockrelativezero.h"
-#include "rs_actionmodifyattributes.h"
-#include "rs_actionmodifybevel.h"
-#include "rs_actionmodifycut.h"
-#include "rs_actionmodifydelete.h"
-#include "rs_actionmodifydeletefree.h"
-#include "rs_actionmodifydeletequick.h"
-#include "rs_actionmodifyentity.h"
-#include "rs_actionmodifyexplodetext.h"
-#include "rs_actionmodifymirror.h"
-#include "rs_actionmodifymove.h"
-#include "rs_actionmodifymoverotate.h"
-#include "rs_actionmodifyrotate.h"
-#include "rs_actionmodifyrotate2.h"
-#include "rs_actionmodifyround.h"
-#include "rs_actionmodifyscale.h"
-#include "rs_actionmodifystretch.h"
-#include "rs_actionmodifytrim.h"
-#include "rs_actionmodifytrimamount.h"
-#include "rs_actionoptionsdrawing.h"
-#include "rs_actionselect.h"
-#include "rs_actionselectall.h"
-#include "rs_actionselectcontour.h"
-#include "rs_actionselectintersected.h"
-#include "rs_actionselectinvert.h"
-#include "rs_actionselectlayer.h"
-#include "rs_actionselectsingle.h"
-#include "rs_actionselectwindow.h"
-#include "rs_actionsetrelativezero.h"
-#include "rs_actionsetsnapmode.h"
-#include "rs_actionsetsnaprestriction.h"
-#include "rs_actionsnapintersectionmanual.h"
-#include "rs_actiontoolregeneratedimensions.h"
-#include "rs_actionzoomauto.h"
-#include "rs_actionzoomin.h"
-#include "rs_actionzoompan.h"
-#include "rs_actionzoomprevious.h"
-#include "rs_actionzoomredraw.h"
-#include "rs_actionzoomwindow.h"
+#include "actionblocksadd.h"
+#include "actionblocksattributes.h"
+#include "actionblockscreate.h"
+#include "actionblocksedit.h"
+#include "actionblocksexplode.h"
+#include "actionblocksfreezeall.h"
+#include "actionblocksinsert.h"
+#include "actionblocksremove.h"
+#include "actionblockstoggleview.h"
+#include "actiondimaligned.h"
+#include "actiondimangular.h"
+#include "actiondimdiametric.h"
+#include "actiondimleader.h"
+#include "actiondimlinear.h"
+#include "actiondimradial.h"
+#include "actiondrawarc.h"
+#include "actiondrawarc3p.h"
+#include "actiondrawarctangential.h"
+#include "actiondrawcircle.h"
+#include "actiondrawcircle2p.h"
+#include "actiondrawcircle3p.h"
+#include "actiondrawcirclecr.h"
+#include "actiondrawellipseaxis.h"
+#include "actiondrawhatch.h"
+#include "actiondrawimage.h"
+#include "actiondrawline.h"
+#include "actiondrawlineangle.h"
+#include "actiondrawlinebisector.h"
+#include "actiondrawlinefree.h"
+#include "actiondrawlinehorvert.h"
+#include "actiondrawlineparallel.h"
+#include "actiondrawlineparallelthrough.h"
+#include "actiondrawlinepolygon.h"
+#include "actiondrawlinepolygon2.h"
+#include "actiondrawlinerectangle.h"
+#include "actiondrawlinerelangle.h"
+#include "actiondrawlinetangent1.h"
+#include "actiondrawlinetangent2.h"
+#include "actiondrawpoint.h"
+#include "actiondrawspline.h"
+#include "actiondrawtext.h"
+#include "actioneditcopy.h"
+#include "actioneditpaste.h"
+#include "actioneditundo.h"
+#include "actionfileopen.h"
+#include "actionfilesaveas.h"
+#include "actioninfoangle.h"
+#include "actioninfoarea.h"
+#include "actioninfodist.h"
+#include "actioninfodist2.h"
+#include "actioninfoinside.h"
+#include "actioninfototallength.h"
+#include "actioninterface.h"
+#include "actionlayersadd.h"
+#include "actionlayersedit.h"
+#include "actionlayersfreezeall.h"
+#include "actionlayersremove.h"
+#include "actionlayerstogglelock.h"
+#include "actionlayerstoggleview.h"
+#include "actionlibraryinsert.h"
+#include "actionlockrelativezero.h"
+#include "actionmodifyattributes.h"
+#include "actionmodifybevel.h"
+#include "actionmodifycut.h"
+#include "actionmodifydelete.h"
+#include "actionmodifydeletefree.h"
+#include "actionmodifydeletequick.h"
+#include "actionmodifyentity.h"
+#include "actionmodifyexplodetext.h"
+#include "actionmodifymirror.h"
+#include "actionmodifymove.h"
+#include "actionmodifymoverotate.h"
+#include "actionmodifyrotate.h"
+#include "actionmodifyrotate2.h"
+#include "actionmodifyround.h"
+#include "actionmodifyscale.h"
+#include "actionmodifystretch.h"
+#include "actionmodifytrim.h"
+#include "actionmodifytrimamount.h"
+#include "actionoptionsdrawing.h"
+#include "actionselect.h"
+#include "actionselectall.h"
+#include "actionselectcontour.h"
+#include "actionselectintersected.h"
+#include "actionselectinvert.h"
+#include "actionselectlayer.h"
+#include "actionselectsingle.h"
+#include "actionselectwindow.h"
+#include "actionsetrelativezero.h"
+#include "actionsetsnapmode.h"
+#include "actionsetsnaprestriction.h"
+#include "actionsnapintersectionmanual.h"
+#include "actiontoolregeneratedimensions.h"
+#include "actionzoomauto.h"
+#include "actionzoomin.h"
+#include "actionzoompan.h"
+#include "actionzoomprevious.h"
+#include "actionzoomredraw.h"
+#include "actionzoomwindow.h"
 
 #warning "!!! Need to add polyline functionality !!!"
-#ifdef RS_PROF
-#include "rs_actiondrawpolyline.h"
-#include "rs_actionpolylineadd.h"
-#include "rs_actionpolylineappend.h"
-#include "rs_actionpolylinedel.h"
-#include "rs_actionpolylinedelbetween.h"
-#include "rs_actionpolylinetrim.h"
+#if 0
+#include "actiondrawpolyline.h"
+#include "actionpolylineadd.h"
+#include "actionpolylineappend.h"
+#include "actionpolylinedel.h"
+#include "actionpolylinedelbetween.h"
+#include "actionpolylinetrim.h"
 #endif
 
 #ifdef RS_CAM
@@ -183,7 +183,7 @@ void QG_ActionHandler::killSelectActions()
 /**
  * @return Current action or NULL.
  */
-RS_ActionInterface * QG_ActionHandler::getCurrentAction()
+ActionInterface * QG_ActionHandler::getCurrentAction()
 {
        GraphicView * gv = mainWindow->getGraphicView();
 
@@ -195,7 +195,7 @@ RS_ActionInterface * QG_ActionHandler::getCurrentAction()
 
 #if 0
 Instead of the following giant switch statement, you could something like the following:
-RS_ActionInterface * QG_ActionHandler::setCurrentAction(RS_ActionInterface * action)
+ActionInterface * QG_ActionHandler::setCurrentAction(ActionInterface * action)
 {
        GraphicView * gv = mainWindow->getGraphicView();
        RS_Document * doc = mainWindow->getDocument();
@@ -212,7 +212,7 @@ RS_ActionInterface * QG_ActionHandler::setCurrentAction(RS_ActionInterface * act
        return action;
 }
 Then you'd call it with:
-               a = new RS_ActionEditUndo(true, *doc, *gv);
+               a = new ActionEditUndo(true, *doc, *gv);
 
 Hmmm.... We need gv & doc *before* we call this...
 
@@ -229,13 +229,13 @@ Well... The problem is the action, they're all different...
  *
  * @return Pointer to the created action or NULL.
  */
-RS_ActionInterface * QG_ActionHandler::setCurrentAction(RS2::ActionType id)
+ActionInterface * QG_ActionHandler::setCurrentAction(RS2::ActionType id)
 {
        RS_DEBUG->print("QG_ActionHandler::setCurrentAction()");
 
        GraphicView * gv = mainWindow->getGraphicView();
        RS_Document * doc = mainWindow->getDocument();
-       RS_ActionInterface * a = NULL;
+       ActionInterface * a = NULL;
 
        // only global options are allowed without a document:
        if (gv == NULL || doc == NULL)
@@ -248,527 +248,527 @@ RS_ActionInterface * QG_ActionHandler::setCurrentAction(RS2::ActionType id)
        switch (id)
        {
                //case RS2::ActionFileNew:
-               //    a = new RS_ActionFileNew(*doc, *gv);
+               //    a = new ActionFileNew(*doc, *gv);
                //      break;
                //case RS2::ActionFileSave:
-               //    a = new RS_ActionFileSave(*doc, *gv);
+               //    a = new ActionFileSave(*doc, *gv);
                //      break;
                //case RS2::ActionFileClose:
-               //    //a = new RS_ActionFileClose(*doc, *gv);
+               //    //a = new ActionFileClose(*doc, *gv);
                //      break;
                //case RS2::ActionFileQuit:
-               //    //a = new RS_ActionFileQuit(*doc, *gv);
+               //    //a = new ActionFileQuit(*doc, *gv);
                //      break;
        case RS2::ActionFileOpen:
-               a = new RS_ActionFileOpen(*doc, *gv);
+               a = new ActionFileOpen(*doc, *gv);
                break;
        case RS2::ActionFileSaveAs:
-               a = new RS_ActionFileSaveAs(*doc, *gv);
+               a = new ActionFileSaveAs(*doc, *gv);
                break;
 
                // Editing actions:
                //
        case RS2::ActionEditUndo:
-               a = new RS_ActionEditUndo(true, *doc, *gv);
+               a = new ActionEditUndo(true, *doc, *gv);
                break;
        case RS2::ActionEditRedo:
-               a = new RS_ActionEditUndo(false, *doc, *gv);
+               a = new ActionEditUndo(false, *doc, *gv);
                break;
        case RS2::ActionEditCut:
-               a = new RS_ActionSelect(*doc, *gv, RS2::ActionEditCutNoSelect);
+               a = new ActionSelect(*doc, *gv, RS2::ActionEditCutNoSelect);
                break;
        case RS2::ActionEditCutNoSelect:
-               a = new RS_ActionEditCopy(false, *doc, *gv);
+               a = new ActionEditCopy(false, *doc, *gv);
                break;
        case RS2::ActionEditCopy:
-               a = new RS_ActionSelect(*doc, *gv, RS2::ActionEditCopyNoSelect);
+               a = new ActionSelect(*doc, *gv, RS2::ActionEditCopyNoSelect);
                break;
        case RS2::ActionEditCopyNoSelect:
-               a = new RS_ActionEditCopy(true, *doc, *gv);
+               a = new ActionEditCopy(true, *doc, *gv);
                break;
        case RS2::ActionEditPaste:
-               a = new RS_ActionEditPaste(*doc, *gv);
+               a = new ActionEditPaste(*doc, *gv);
                break;
 
                // Selecting actions:
                //
        case RS2::ActionSelectSingle:
                gv->killSelectActions();
-               a = new RS_ActionSelectSingle(*doc, *gv);
+               a = new ActionSelectSingle(*doc, *gv);
                break;
        case RS2::ActionSelectContour:
                gv->killSelectActions();
-               a = new RS_ActionSelectContour(*doc, *gv);
+               a = new ActionSelectContour(*doc, *gv);
                break;
        case RS2::ActionSelectAll:
-               a = new RS_ActionSelectAll(*doc, *gv, true);
+               a = new ActionSelectAll(*doc, *gv, true);
                break;
        case RS2::ActionDeselectAll:
-               a = new RS_ActionSelectAll(*doc, *gv, false);
+               a = new ActionSelectAll(*doc, *gv, false);
                break;
        case RS2::ActionSelectWindow:
                gv->killSelectActions();
-               a = new RS_ActionSelectWindow(*doc, *gv, true);
+               a = new ActionSelectWindow(*doc, *gv, true);
                break;
        case RS2::ActionDeselectWindow:
                gv->killSelectActions();
-               a = new RS_ActionSelectWindow(*doc, *gv, false);
+               a = new ActionSelectWindow(*doc, *gv, false);
                break;
        case RS2::ActionSelectInvert:
-               a = new RS_ActionSelectInvert(*doc, *gv);
+               a = new ActionSelectInvert(*doc, *gv);
                break;
        case RS2::ActionSelectIntersected:
                gv->killSelectActions();
-               a = new RS_ActionSelectIntersected(*doc, *gv, true);
+               a = new ActionSelectIntersected(*doc, *gv, true);
                break;
        case RS2::ActionDeselectIntersected:
                gv->killSelectActions();
-               a = new RS_ActionSelectIntersected(*doc, *gv, false);
+               a = new ActionSelectIntersected(*doc, *gv, false);
                break;
        case RS2::ActionSelectLayer:
                gv->killSelectActions();
-               a = new RS_ActionSelectLayer(*doc, *gv);
+               a = new ActionSelectLayer(*doc, *gv);
                break;
 
                // Tool actions:
                //
        case RS2::ActionToolRegenerateDimensions:
-               a = new RS_ActionToolRegenerateDimensions(*doc, *gv);
+               a = new ActionToolRegenerateDimensions(*doc, *gv);
                break;
 
                // Zooming actions:
                //
        case RS2::ActionZoomIn:
-               a = new RS_ActionZoomIn(*doc, *gv, RS2::In, RS2::Both);
+               a = new ActionZoomIn(*doc, *gv, RS2::In, RS2::Both);
                break;
        case RS2::ActionZoomOut:
-               a = new RS_ActionZoomIn(*doc, *gv, RS2::Out, RS2::Both);
+               a = new ActionZoomIn(*doc, *gv, RS2::Out, RS2::Both);
                break;
        case RS2::ActionZoomAuto:
-               a = new RS_ActionZoomAuto(*doc, *gv);
+               a = new ActionZoomAuto(*doc, *gv);
                break;
        case RS2::ActionZoomWindow:
-               a = new RS_ActionZoomWindow(*doc, *gv);
+               a = new ActionZoomWindow(*doc, *gv);
                break;
        case RS2::ActionZoomPan:
-               a = new RS_ActionZoomPan(*doc, *gv);
+               a = new ActionZoomPan(*doc, *gv);
                break;
        case RS2::ActionZoomPrevious:
-               a = new RS_ActionZoomPrevious(*doc, *gv);
+               a = new ActionZoomPrevious(*doc, *gv);
                break;
        case RS2::ActionZoomRedraw:
-               a = new RS_ActionZoomRedraw(*doc, *gv);
+               a = new ActionZoomRedraw(*doc, *gv);
                break;
 
                // Drawing actions:
                //
        case RS2::ActionDrawPoint:
-               a = new RS_ActionDrawPoint(*doc, *gv);
+               a = new ActionDrawPoint(*doc, *gv);
                break;
        case RS2::ActionDrawLine:
-               a = new RS_ActionDrawLine(*doc, *gv);
+               a = new ActionDrawLine(*doc, *gv);
                break;
        case RS2::ActionDrawLineAngle:
-               a = new RS_ActionDrawLineAngle(*doc, *gv, 0.0, false);
+               a = new ActionDrawLineAngle(*doc, *gv, 0.0, false);
                break;
        case RS2::ActionDrawLineHorizontal:
-               a = new RS_ActionDrawLineAngle(*doc, *gv, 0.0, true);
+               a = new ActionDrawLineAngle(*doc, *gv, 0.0, true);
                break;
        case RS2::ActionDrawLineHorVert:
-               a = new RS_ActionDrawLineHorVert(*doc, *gv);
+               a = new ActionDrawLineHorVert(*doc, *gv);
                break;
        case RS2::ActionDrawLineVertical:
-               a = new RS_ActionDrawLineAngle(*doc, *gv, M_PI/2.0, true);
+               a = new ActionDrawLineAngle(*doc, *gv, M_PI / 2.0, true);
                break;
        case RS2::ActionDrawLineFree:
-               a = new RS_ActionDrawLineFree(*doc, *gv);
+               a = new ActionDrawLineFree(*doc, *gv);
                break;
        case RS2::ActionDrawLineParallel:
-               a = new RS_ActionDrawLineParallel(*doc, *gv);
+               a = new ActionDrawLineParallel(*doc, *gv);
                break;
        case RS2::ActionDrawLineParallelThrough:
-               a = new RS_ActionDrawLineParallelThrough(*doc, *gv);
+               a = new ActionDrawLineParallelThrough(*doc, *gv);
                break;
        case RS2::ActionDrawLineRectangle:
-               a = new RS_ActionDrawLineRectangle(*doc, *gv);
+               a = new ActionDrawLineRectangle(*doc, *gv);
                break;
        case RS2::ActionDrawLineBisector:
-               a = new RS_ActionDrawLineBisector(*doc, *gv);
+               a = new ActionDrawLineBisector(*doc, *gv);
                break;
        case RS2::ActionDrawLineTangent1:
-               a = new RS_ActionDrawLineTangent1(*doc, *gv);
+               a = new ActionDrawLineTangent1(*doc, *gv);
                break;
        case RS2::ActionDrawLineTangent2:
-               a = new RS_ActionDrawLineTangent2(*doc, *gv);
+               a = new ActionDrawLineTangent2(*doc, *gv);
                break;
        case RS2::ActionDrawLineOrthogonal:
-               a = new RS_ActionDrawLineRelAngle(*doc, *gv, M_PI / 2.0, true);
+               a = new ActionDrawLineRelAngle(*doc, *gv, M_PI / 2.0, true);
                break;
        case RS2::ActionDrawLineRelAngle:
-               a = new RS_ActionDrawLineRelAngle(*doc, *gv, M_PI / 2.0, false);
+               a = new ActionDrawLineRelAngle(*doc, *gv, M_PI / 2.0, false);
                break;
 #warning "!!! Need to add polyline functionality !!!"
 #ifdef RS_PROF
        case RS2::ActionDrawPolyline:
-               a = new RS_ActionDrawPolyline(*doc, *gv);
+               a = new ActionDrawPolyline(*doc, *gv);
                break;
        case RS2::ActionPolylineAdd:
-               a = new RS_ActionPolylineAdd(*doc, *gv);
+               a = new ActionPolylineAdd(*doc, *gv);
                break;
        case RS2::ActionPolylineAppend:
-               a = new RS_ActionPolylineAppend(*doc, *gv);
+               a = new ActionPolylineAppend(*doc, *gv);
                break;
        case RS2::ActionPolylineDel:
-               a = new RS_ActionPolylineDel(*doc, *gv);
+               a = new ActionPolylineDel(*doc, *gv);
                break;
        case RS2::ActionPolylineDelBetween:
-               a = new RS_ActionPolylineDelBetween(*doc, *gv);
+               a = new ActionPolylineDelBetween(*doc, *gv);
                break;
        case RS2::ActionPolylineTrim:
-               a = new RS_ActionPolylineTrim(*doc, *gv);
+               a = new ActionPolylineTrim(*doc, *gv);
                break;
 #endif
        case RS2::ActionDrawLinePolygon:
-               a = new RS_ActionDrawLinePolygon(*doc, *gv);
+               a = new ActionDrawLinePolygon(*doc, *gv);
                break;
        case RS2::ActionDrawLinePolygon2:
-               a = new RS_ActionDrawLinePolygon2(*doc, *gv);
+               a = new ActionDrawLinePolygon2(*doc, *gv);
                break;
        case RS2::ActionDrawCircle:
-               a = new RS_ActionDrawCircle(*doc, *gv);
+               a = new ActionDrawCircle(*doc, *gv);
                break;
        case RS2::ActionDrawCircleCR:
-               a = new RS_ActionDrawCircleCR(*doc, *gv);
+               a = new ActionDrawCircleCR(*doc, *gv);
                break;
        case RS2::ActionDrawCircle2P:
-               a = new RS_ActionDrawCircle2P(*doc, *gv);
+               a = new ActionDrawCircle2P(*doc, *gv);
                break;
        case RS2::ActionDrawCircle3P:
-               a = new RS_ActionDrawCircle3P(*doc, *gv);
+               a = new ActionDrawCircle3P(*doc, *gv);
                break;
        case RS2::ActionDrawCircleParallel:
-               a = new RS_ActionDrawLineParallel(*doc, *gv);
+               a = new ActionDrawLineParallel(*doc, *gv);
                break;
        case RS2::ActionDrawArc:
-               a = new RS_ActionDrawArc(*doc, *gv);
+               a = new ActionDrawArc(*doc, *gv);
                break;
        case RS2::ActionDrawArc3P:
-               a = new RS_ActionDrawArc3P(*doc, *gv);
+               a = new ActionDrawArc3P(*doc, *gv);
                break;
        case RS2::ActionDrawArcParallel:
-               a = new RS_ActionDrawLineParallel(*doc, *gv);
+               a = new ActionDrawLineParallel(*doc, *gv);
                break;
        case RS2::ActionDrawArcTangential:
-               a = new RS_ActionDrawArcTangential(*doc, *gv);
+               a = new ActionDrawArcTangential(*doc, *gv);
                break;
        case RS2::ActionDrawEllipseAxis:
-               a = new RS_ActionDrawEllipseAxis(*doc, *gv, false);
+               a = new ActionDrawEllipseAxis(*doc, *gv, false);
                break;
        case RS2::ActionDrawEllipseArcAxis:
-               a = new RS_ActionDrawEllipseAxis(*doc, *gv, true);
+               a = new ActionDrawEllipseAxis(*doc, *gv, true);
                break;
        case RS2::ActionDrawSpline:
-               a = new RS_ActionDrawSpline(*doc, *gv);
+               a = new ActionDrawSpline(*doc, *gv);
                break;
        case RS2::ActionDrawText:
-               a = new RS_ActionDrawText(*doc, *gv);
+               a = new ActionDrawText(*doc, *gv);
                break;
        case RS2::ActionDrawHatch:
-               a = new RS_ActionSelect(*doc, *gv, RS2::ActionDrawHatchNoSelect);
+               a = new ActionSelect(*doc, *gv, RS2::ActionDrawHatchNoSelect);
                break;
        case RS2::ActionDrawHatchNoSelect:
-               a = new RS_ActionDrawHatch(*doc, *gv);
+               a = new ActionDrawHatch(*doc, *gv);
                break;
        case RS2::ActionDrawImage:
-               a = new RS_ActionDrawImage(*doc, *gv);
+               a = new ActionDrawImage(*doc, *gv);
                break;
 
                // Dimensioning actions:
                //
        case RS2::ActionDimAligned:
-               a = new RS_ActionDimAligned(*doc, *gv);
+               a = new ActionDimAligned(*doc, *gv);
                break;
        case RS2::ActionDimLinear:
-               a = new RS_ActionDimLinear(*doc, *gv);
+               a = new ActionDimLinear(*doc, *gv);
                break;
        case RS2::ActionDimLinearHor:
-               a = new RS_ActionDimLinear(*doc, *gv, 0.0, true);
+               a = new ActionDimLinear(*doc, *gv, 0.0, true);
                break;
        case RS2::ActionDimLinearVer:
-               a = new RS_ActionDimLinear(*doc, *gv, M_PI / 2.0, true);
+               a = new ActionDimLinear(*doc, *gv, M_PI / 2.0, true);
                break;
        case RS2::ActionDimRadial:
-               a = new RS_ActionDimRadial(*doc, *gv);
+               a = new ActionDimRadial(*doc, *gv);
                break;
        case RS2::ActionDimDiametric:
-               a = new RS_ActionDimDiametric(*doc, *gv);
+               a = new ActionDimDiametric(*doc, *gv);
                break;
        case RS2::ActionDimAngular:
-               a = new RS_ActionDimAngular(*doc, *gv);
+               a = new ActionDimAngular(*doc, *gv);
                break;
        case RS2::ActionDimLeader:
-               a = new RS_ActionDimLeader(*doc, *gv);
+               a = new ActionDimLeader(*doc, *gv);
                break;
 
                // Modifying actions:
                //
        case RS2::ActionModifyAttributes:
-               a = new RS_ActionSelect(*doc, *gv, RS2::ActionModifyAttributesNoSelect);
+               a = new ActionSelect(*doc, *gv, RS2::ActionModifyAttributesNoSelect);
                break;
        case RS2::ActionModifyAttributesNoSelect:
-               a = new RS_ActionModifyAttributes(*doc, *gv);
+               a = new ActionModifyAttributes(*doc, *gv);
                break;
        case RS2::ActionModifyDelete:
-               a = new RS_ActionSelect(*doc, *gv, RS2::ActionModifyDeleteNoSelect);
+               a = new ActionSelect(*doc, *gv, RS2::ActionModifyDeleteNoSelect);
                break;
        case RS2::ActionModifyDeleteNoSelect:
-               a = new RS_ActionModifyDelete(*doc, *gv);
+               a = new ActionModifyDelete(*doc, *gv);
                break;
        case RS2::ActionModifyDeleteQuick:
-               a = new RS_ActionSelect(*doc, *gv, RS2::ActionModifyDeleteQuick);
+               a = new ActionSelect(*doc, *gv, RS2::ActionModifyDeleteQuick);
                break;
        case RS2::ActionModifyDeleteFree:
-               a = new RS_ActionModifyDeleteFree(*doc, *gv);
+               a = new ActionModifyDeleteFree(*doc, *gv);
                break;
        case RS2::ActionModifyMove:
-               a = new RS_ActionSelect(*doc, *gv, RS2::ActionModifyMoveNoSelect);
+               a = new ActionSelect(*doc, *gv, RS2::ActionModifyMoveNoSelect);
                break;
        case RS2::ActionModifyMoveNoSelect:
-               a = new RS_ActionModifyMove(*doc, *gv);
+               a = new ActionModifyMove(*doc, *gv);
                break;
        case RS2::ActionModifyRotate:
-               a = new RS_ActionSelect(*doc, *gv, RS2::ActionModifyRotateNoSelect);
+               a = new ActionSelect(*doc, *gv, RS2::ActionModifyRotateNoSelect);
                break;
        case RS2::ActionModifyRotateNoSelect:
-               a = new RS_ActionModifyRotate(*doc, *gv);
+               a = new ActionModifyRotate(*doc, *gv);
                break;
        case RS2::ActionModifyScale:
-               a = new RS_ActionSelect(*doc, *gv, RS2::ActionModifyScaleNoSelect);
+               a = new ActionSelect(*doc, *gv, RS2::ActionModifyScaleNoSelect);
                break;
        case RS2::ActionModifyScaleNoSelect:
-               a = new RS_ActionModifyScale(*doc, *gv);
+               a = new ActionModifyScale(*doc, *gv);
                break;
        case RS2::ActionModifyMirror:
-               a = new RS_ActionSelect(*doc, *gv, RS2::ActionModifyMirrorNoSelect);
+               a = new ActionSelect(*doc, *gv, RS2::ActionModifyMirrorNoSelect);
                break;
        case RS2::ActionModifyMirrorNoSelect:
-               a = new RS_ActionModifyMirror(*doc, *gv);
+               a = new ActionModifyMirror(*doc, *gv);
                break;
        case RS2::ActionModifyMoveRotate:
-               a = new RS_ActionSelect(*doc, *gv, RS2::ActionModifyMoveRotateNoSelect);
+               a = new ActionSelect(*doc, *gv, RS2::ActionModifyMoveRotateNoSelect);
                break;
        case RS2::ActionModifyMoveRotateNoSelect:
-               a = new RS_ActionModifyMoveRotate(*doc, *gv);
+               a = new ActionModifyMoveRotate(*doc, *gv);
                break;
        case RS2::ActionModifyRotate2:
-               a = new RS_ActionSelect(*doc, *gv, RS2::ActionModifyRotate2NoSelect);
+               a = new ActionSelect(*doc, *gv, RS2::ActionModifyRotate2NoSelect);
                break;
        case RS2::ActionModifyRotate2NoSelect:
-               a = new RS_ActionModifyRotate2(*doc, *gv);
+               a = new ActionModifyRotate2(*doc, *gv);
                break;
        case RS2::ActionModifyEntity:
-               a = new RS_ActionModifyEntity(*doc, *gv);
+               a = new ActionModifyEntity(*doc, *gv);
                break;
        case RS2::ActionModifyTrim:
-               a = new RS_ActionModifyTrim(*doc, *gv, false);
+               a = new ActionModifyTrim(*doc, *gv, false);
                break;
        case RS2::ActionModifyTrim2:
-               a = new RS_ActionModifyTrim(*doc, *gv, true);
+               a = new ActionModifyTrim(*doc, *gv, true);
                break;
        case RS2::ActionModifyTrimAmount:
-               a = new RS_ActionModifyTrimAmount(*doc, *gv);
+               a = new ActionModifyTrimAmount(*doc, *gv);
                break;
        case RS2::ActionModifyCut:
-               a = new RS_ActionModifyCut(*doc, *gv);
+               a = new ActionModifyCut(*doc, *gv);
                break;
        case RS2::ActionModifyStretch:
-               a = new RS_ActionModifyStretch(*doc, *gv);
+               a = new ActionModifyStretch(*doc, *gv);
                break;
        case RS2::ActionModifyBevel:
-               a = new RS_ActionModifyBevel(*doc, *gv);
+               a = new ActionModifyBevel(*doc, *gv);
                break;
        case RS2::ActionModifyRound:
-               a = new RS_ActionModifyRound(*doc, *gv);
+               a = new ActionModifyRound(*doc, *gv);
                break;
        case RS2::ActionModifyExplodeText:
-               a = new RS_ActionSelect(*doc, *gv, RS2::ActionModifyExplodeTextNoSelect);
+               a = new ActionSelect(*doc, *gv, RS2::ActionModifyExplodeTextNoSelect);
                break;
        case RS2::ActionModifyExplodeTextNoSelect:
-               a = new RS_ActionModifyExplodeText(*doc, *gv);
+               a = new ActionModifyExplodeText(*doc, *gv);
                break;
 
                // Snapping actions:
                //
        case RS2::ActionSnapFree:
-               a = new RS_ActionSetSnapMode(*doc, *gv, RS2::SnapFree);
+               a = new ActionSetSnapMode(*doc, *gv, RS2::SnapFree);
                break;
        case RS2::ActionSnapGrid:
-               a = new RS_ActionSetSnapMode(*doc, *gv, RS2::SnapGrid);
+               a = new ActionSetSnapMode(*doc, *gv, RS2::SnapGrid);
                break;
        case RS2::ActionSnapEndpoint:
-               a = new RS_ActionSetSnapMode(*doc, *gv, RS2::SnapEndpoint);
+               a = new ActionSetSnapMode(*doc, *gv, RS2::SnapEndpoint);
                break;
        case RS2::ActionSnapOnEntity:
-               a = new RS_ActionSetSnapMode(*doc, *gv, RS2::SnapOnEntity);
+               a = new ActionSetSnapMode(*doc, *gv, RS2::SnapOnEntity);
                break;
        case RS2::ActionSnapCenter:
-               a = new RS_ActionSetSnapMode(*doc, *gv, RS2::SnapCenter);
+               a = new ActionSetSnapMode(*doc, *gv, RS2::SnapCenter);
                break;
        case RS2::ActionSnapMiddle:
-               a = new RS_ActionSetSnapMode(*doc, *gv, RS2::SnapMiddle);
+               a = new ActionSetSnapMode(*doc, *gv, RS2::SnapMiddle);
                break;
        case RS2::ActionSnapDist:
-               a = new RS_ActionSetSnapMode(*doc, *gv, RS2::SnapDist);
+               a = new ActionSetSnapMode(*doc, *gv, RS2::SnapDist);
                break;
        case RS2::ActionSnapIntersection:
-               a = new RS_ActionSetSnapMode(*doc, *gv, RS2::SnapIntersection);
+               a = new ActionSetSnapMode(*doc, *gv, RS2::SnapIntersection);
                break;
        case RS2::ActionSnapIntersectionManual:
-               a = new RS_ActionSnapIntersectionManual(*doc, *gv);
+               a = new ActionSnapIntersectionManual(*doc, *gv);
                break;
 
                // Snap restriction actions:
                //
        case RS2::ActionRestrictNothing:
-               a = new RS_ActionSetSnapRestriction(*doc, *gv, RS2::RestrictNothing);
+               a = new ActionSetSnapRestriction(*doc, *gv, RS2::RestrictNothing);
                break;
        case RS2::ActionRestrictOrthogonal:
-               a = new RS_ActionSetSnapRestriction(*doc, *gv,
+               a = new ActionSetSnapRestriction(*doc, *gv,
                                                                                        RS2::RestrictOrthogonal);
                break;
        case RS2::ActionRestrictHorizontal:
-               a = new RS_ActionSetSnapRestriction(*doc, *gv,
+               a = new ActionSetSnapRestriction(*doc, *gv,
                                                                                        RS2::RestrictHorizontal);
                break;
        case RS2::ActionRestrictVertical:
-               a = new RS_ActionSetSnapRestriction(*doc, *gv,
+               a = new ActionSetSnapRestriction(*doc, *gv,
                                                                                        RS2::RestrictVertical);
                break;
 
                // Relative zero:
                //
        case RS2::ActionSetRelativeZero:
-               a = new RS_ActionSetRelativeZero(*doc, *gv);
+               a = new ActionSetRelativeZero(*doc, *gv);
                break;
        case RS2::ActionLockRelativeZero:
-               a = new RS_ActionLockRelativeZero(*doc, *gv, true);
+               a = new ActionLockRelativeZero(*doc, *gv, true);
                break;
        case RS2::ActionUnlockRelativeZero:
-               a = new RS_ActionLockRelativeZero(*doc, *gv, false);
+               a = new ActionLockRelativeZero(*doc, *gv, false);
                break;
 
                // Info actions:
                //
        case RS2::ActionInfoInside:
-               a = new RS_ActionInfoInside(*doc, *gv);
+               a = new ActionInfoInside(*doc, *gv);
                break;
        case RS2::ActionInfoDist:
-               a = new RS_ActionInfoDist(*doc, *gv);
+               a = new ActionInfoDist(*doc, *gv);
                break;
        case RS2::ActionInfoDist2:
-               a = new RS_ActionInfoDist2(*doc, *gv);
+               a = new ActionInfoDist2(*doc, *gv);
                break;
        case RS2::ActionInfoAngle:
-               a = new RS_ActionInfoAngle(*doc, *gv);
+               a = new ActionInfoAngle(*doc, *gv);
                break;
        case RS2::ActionInfoTotalLength:
-               a = new RS_ActionSelect(*doc, *gv, RS2::ActionInfoTotalLengthNoSelect);
+               a = new ActionSelect(*doc, *gv, RS2::ActionInfoTotalLengthNoSelect);
                break;
        case RS2::ActionInfoTotalLengthNoSelect:
-               a = new RS_ActionInfoTotalLength(*doc, *gv);
+               a = new ActionInfoTotalLength(*doc, *gv);
                break;
        case RS2::ActionInfoArea:
-               a = new RS_ActionInfoArea(*doc, *gv);
+               a = new ActionInfoArea(*doc, *gv);
                break;
 
                // Layer actions:
                //
        case RS2::ActionLayersDefreezeAll:
-               a = new RS_ActionLayersFreezeAll(false, *doc, *gv);
+               a = new ActionLayersFreezeAll(false, *doc, *gv);
                break;
        case RS2::ActionLayersFreezeAll:
-               a = new RS_ActionLayersFreezeAll(true, *doc, *gv);
+               a = new ActionLayersFreezeAll(true, *doc, *gv);
                break;
        case RS2::ActionLayersAdd:
-               a = new RS_ActionLayersAdd(*doc, *gv);
+               a = new ActionLayersAdd(*doc, *gv);
                break;
        case RS2::ActionLayersRemove:
-               a = new RS_ActionLayersRemove(*doc, *gv);
+               a = new ActionLayersRemove(*doc, *gv);
                break;
        case RS2::ActionLayersEdit:
-               a = new RS_ActionLayersEdit(*doc, *gv);
+               a = new ActionLayersEdit(*doc, *gv);
                break;
        case RS2::ActionLayersToggleView:
-               a = new RS_ActionLayersToggleView(*doc, *gv);
+               a = new ActionLayersToggleView(*doc, *gv);
                break;
        case RS2::ActionLayersToggleLock:
-               a = new RS_ActionLayersToggleLock(*doc, *gv);
+               a = new ActionLayersToggleLock(*doc, *gv);
                break;
 
                // Block actions:
                //
        case RS2::ActionBlocksDefreezeAll:
-               a = new RS_ActionBlocksFreezeAll(false, *doc, *gv);
+               a = new ActionBlocksFreezeAll(false, *doc, *gv);
                break;
        case RS2::ActionBlocksFreezeAll:
-               a = new RS_ActionBlocksFreezeAll(true, *doc, *gv);
+               a = new ActionBlocksFreezeAll(true, *doc, *gv);
                break;
        case RS2::ActionBlocksAdd:
-               a = new RS_ActionBlocksAdd(*doc, *gv);
+               a = new ActionBlocksAdd(*doc, *gv);
                break;
        case RS2::ActionBlocksRemove:
-               a = new RS_ActionBlocksRemove(*doc, *gv);
+               a = new ActionBlocksRemove(*doc, *gv);
                break;
        case RS2::ActionBlocksAttributes:
-               a = new RS_ActionBlocksAttributes(*doc, *gv);
+               a = new ActionBlocksAttributes(*doc, *gv);
                break;
        case RS2::ActionBlocksEdit:
-               a = new RS_ActionBlocksEdit(*doc, *gv);
+               a = new ActionBlocksEdit(*doc, *gv);
                break;
        case RS2::ActionBlocksInsert:
-               a = new RS_ActionBlocksInsert(*doc, *gv);
+               a = new ActionBlocksInsert(*doc, *gv);
                break;
        case RS2::ActionBlocksToggleView:
-               a = new RS_ActionBlocksToggleView(*doc, *gv);
+               a = new ActionBlocksToggleView(*doc, *gv);
                break;
        case RS2::ActionBlocksCreate:
-               a = new RS_ActionSelect(*doc, *gv, RS2::ActionBlocksCreateNoSelect);
+               a = new ActionSelect(*doc, *gv, RS2::ActionBlocksCreateNoSelect);
                break;
        case RS2::ActionBlocksCreateNoSelect:
-               a = new RS_ActionBlocksCreate(*doc, *gv);
+               a = new ActionBlocksCreate(*doc, *gv);
                break;
        case RS2::ActionBlocksExplode:
-               a = new RS_ActionSelect(*doc, *gv, RS2::ActionBlocksExplodeNoSelect);
+               a = new ActionSelect(*doc, *gv, RS2::ActionBlocksExplodeNoSelect);
                break;
        case RS2::ActionBlocksExplodeNoSelect:
-               a = new RS_ActionBlocksExplode(*doc, *gv);
+               a = new ActionBlocksExplode(*doc, *gv);
                break;
 
 
                // library browser:
                //
        case RS2::ActionLibraryInsert:
-               a = new RS_ActionLibraryInsert(*doc, *gv);
+               a = new ActionLibraryInsert(*doc, *gv);
                break;
 
                // options:
                //
                //case RS2::ActionOptionsGeneral:
-               //    a = new RS_ActionOptionsGeneral(*doc, *gv);
+               //    a = new ActionOptionsGeneral(*doc, *gv);
                //      break;
 
        case RS2::ActionOptionsDrawing:
-               a = new RS_ActionOptionsDrawing(*doc, *gv);
+               a = new ActionOptionsDrawing(*doc, *gv);
                break;
 
                // cam:
                //
 #ifdef RS_CAM
        case RS2::ActionCamExportAuto:
-               a = new RS_ActionCamExportAuto(*doc, *gv);
+               a = new ActionCamExportAuto(*doc, *gv);
                break;
        case RS2::ActionCamReorder:
-               a = new RS_ActionCamReorder(*doc, *gv);
+               a = new ActionCamReorder(*doc, *gv);
                break;
 #endif
 
@@ -791,7 +791,7 @@ RS_ActionInterface * QG_ActionHandler::setCurrentAction(RS2::ActionType id)
  */
 QStringList QG_ActionHandler::getAvailableCommands()
 {
-       RS_ActionInterface * currentAction = getCurrentAction();
+       ActionInterface * currentAction = getCurrentAction();
 
        if (currentAction)
                return currentAction->getAvailableCommands();