# HG changeset patch # User Teemu Piippo # Date 1440899829 -10800 # Node ID c1526d1877d72517909bd76d138686f94f1f1257 # Parent a4b463a7ee82bd94026a543e5453766e20b5b7ee More through removal of the vertex object diff -r a4b463a7ee82 -r c1526d1877d7 icons/add-vertex.png Binary file icons/add-vertex.png has changed diff -r a4b463a7ee82 -r c1526d1877d7 icons/corner-verts.png Binary file icons/corner-verts.png has changed diff -r a4b463a7ee82 -r c1526d1877d7 icons/vertex.png Binary file icons/vertex.png has changed diff -r a4b463a7ee82 -r c1526d1877d7 ldforge.qrc --- a/ldforge.qrc Sun Aug 30 04:53:37 2015 +0300 +++ b/ldforge.qrc Sun Aug 30 04:57:09 2015 +0300 @@ -9,7 +9,6 @@ ./icons/add-radial.png ./icons/add-subfile.png ./icons/add-triangle.png - ./icons/add-vertex.png ./icons/arrow-down.png ./icons/arrow-left.png ./icons/arrow-right.png @@ -34,7 +33,6 @@ ./icons/comment.png ./icons/condline.png ./icons/copy.png - ./icons/corner-verts.png ./icons/coverer.png ./icons/cut.png ./icons/delete.png @@ -102,7 +100,6 @@ ./icons/triangle.png ./icons/uncolorize.png ./icons/undo.png - ./icons/vertex.png ./icons/visibility-hide.png ./icons/visibility-show.png ./icons/visibility-toggle.png diff -r a4b463a7ee82 -r c1526d1877d7 src/actions.cpp --- a/src/actions.cpp Sun Aug 30 04:53:37 2015 +0300 +++ b/src/actions.cpp Sun Aug 30 04:57:09 2015 +0300 @@ -201,13 +201,6 @@ // ============================================================================= // -void MainWindow::slot_actionNewVertex() -{ - AddObjectDialog::staticDialog (OBJ_Vertex, nullptr); -} - -// ============================================================================= -// void MainWindow::slot_actionEdit() { if (Selection().size() != 1) diff -r a4b463a7ee82 -r c1526d1877d7 src/addObjectDialog.cpp --- a/src/addObjectDialog.cpp Sun Aug 30 04:53:37 2015 +0300 +++ b/src/addObjectDialog.cpp Sun Aug 30 04:57:09 2015 +0300 @@ -73,11 +73,6 @@ coordCount = 12; } break; - case OBJ_Vertex: - { - coordCount = 3; - } break; - case OBJ_BFC: { rb_bfcType = new RadioGroup ("Statement", {}, 0, Qt::Vertical); diff -r a4b463a7ee82 -r c1526d1877d7 src/ldObject.cpp --- a/src/ldObject.cpp Sun Aug 30 04:53:37 2015 +0300 +++ b/src/ldObject.cpp Sun Aug 30 04:57:09 2015 +0300 @@ -511,11 +511,6 @@ text += ", "; QString noun = format ("%1%2", typeName (objType), Plural (count)); - - // Plural of "vertex" is "vertices", correct that - if (objType == OBJ_Vertex and count != 1) - noun = "vertices"; - text += format ("%1 %2", count, noun); } diff -r a4b463a7ee82 -r c1526d1877d7 src/ldObject.h --- a/src/ldObject.h Sun Aug 30 04:53:37 2015 +0300 +++ b/src/ldObject.h Sun Aug 30 04:57:09 2015 +0300 @@ -67,7 +67,6 @@ OBJ_Triangle, // Object represents a triangle OBJ_Line, // Object represents a line OBJ_CondLine, // Object represents a conditional line - OBJ_Vertex, // Object is a vertex, LDForge extension object OBJ_BFC, // Object represents a BFC statement OBJ_Overlay, // Object contains meta-info about an overlay image. OBJ_Comment, // Object represents a comment diff -r a4b463a7ee82 -r c1526d1877d7 src/mainwindow.cpp --- a/src/mainwindow.cpp Sun Aug 30 04:53:37 2015 +0300 +++ b/src/mainwindow.cpp Sun Aug 30 04:57:09 2015 +0300 @@ -48,7 +48,7 @@ #include "addObjectDialog.h" #include "messageLog.h" #include "configuration.h" -#include "ui_ldforge.h" +#include "ui_mainwindow.h" #include "primitives.h" #include "editmodes/abstractEditMode.h" @@ -1090,6 +1090,13 @@ // ============================================================================= // +QTreeWidget* MainWindow::getPrimitivesTree() const +{ + return ui->primitives; +} + +// ============================================================================= +// QKeySequence MainWindow::defaultShortcut (QAction* act) // [static] { return g_defaultShortcuts[act]; diff -r a4b463a7ee82 -r c1526d1877d7 src/mainwindow.h --- a/src/mainwindow.h Sun Aug 30 04:53:37 2015 +0300 +++ b/src/mainwindow.h Sun Aug 30 04:57:09 2015 +0300 @@ -22,9 +22,9 @@ #include #include #include +#include #include "configuration.h" #include "ldObject.h" -#include "ui_ldforge.h" #include "colors.h" class MessageManager; @@ -158,14 +158,8 @@ // Updates the object list. Right now this just rebuilds it. void refreshObjectList(); - void endAction(); - - inline QTreeWidget* getPrimitivesTree() const - { - return ui->primitives; - } - + QTreeWidget* getPrimitivesTree() const; static QKeySequence defaultShortcut (QAction* act); void loadShortcuts (QSettings const* settings); void saveShortcuts (QSettings* settings); @@ -211,7 +205,6 @@ void slot_actionNewCLine(); void slot_actionNewComment(); void slot_actionNewBFC(); - void slot_actionNewVertex(); void slot_actionUndo(); void slot_actionRedo(); void slot_actionCut(); diff -r a4b463a7ee82 -r c1526d1877d7 src/mainwindow.ui --- a/src/mainwindow.ui Sun Aug 30 04:53:37 2015 +0300 +++ b/src/mainwindow.ui Sun Aug 30 04:57:09 2015 +0300 @@ -265,7 +265,6 @@ - @@ -436,7 +435,6 @@ - @@ -841,15 +839,6 @@ New &BFC Statement - - - - :/icons/add-vertex.png:/icons/add-vertex.png - - - New &Vertex - - @@ -1196,7 +1185,7 @@ - Demote Conditional Lines + Demote &Conditional Lines Demote conditional lines down to normal lines.