diff -r 1f368f0a323b -r 1dd18eea7c84 src/gui_editactions.cpp --- a/src/gui_editactions.cpp Sun May 19 01:31:13 2013 +0300 +++ b/src/gui_editactions.cpp Sun May 19 02:04:46 2013 +0300 @@ -186,7 +186,7 @@ // ======================================================================================================================================= // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * // ======================================================================================================================================= -MAKE_ACTION (radialResolution, "Radial resolution", "radial-resolve", "Resolve radials into primitives.", (0)) { +MAKE_ACTION (radialConvert, "Radials to Subfiles", "radial-convert", "Convert radials into primitives.", (0)) { vector fails; vector sel = g_win->sel (); EditHistory* history = new EditHistory; @@ -314,31 +314,32 @@ if (g_win->sel ().size() <= 0) return; - short dColor; - short dDefault = -1; + short colnum; + short defcol = -1; std::vector objs = g_win->sel (); // If all selected objects have the same color, said color is our default // value to the color selection dialog. - dDefault = g_win->getSelectedColor (); + defcol = g_win->getSelectedColor (); // Show the dialog to the user now and ask for a color. - if (ColorSelectDialog::staticDialog (dColor, dDefault, g_win)) { - std::vector ulaIndices; - std::vector daColors; + if (ColorSelectDialog::staticDialog (colnum, defcol, g_win)) { + std::vector indices; + std::vector colornums; for (LDObject* obj : objs) { - if (obj->color != -1) { - ulaIndices.push_back (obj->getIndex (g_curfile)); - daColors.push_back (obj->color); - - obj->color = dColor; - g_win->R ()->compileObject (obj); - } + if (obj->isColored () == false) + continue; + + indices.push_back (obj->getIndex (g_curfile)); + colornums.push_back (obj->color); + + obj->color = colnum; + g_win->R ()->compileObject (obj); } - History::addEntry (new SetColorHistory (ulaIndices, daColors, dColor)); + History::addEntry (new SetColorHistory (indices, colornums, colnum)); g_win->refresh (); } } @@ -793,7 +794,7 @@ return false; } -MAKE_ACTION (autoColor, "Auto-color", "auto-color", "Set the color of the given object to the first found unused color.", (0)) { +MAKE_ACTION (autoColor, "Autocolor", "autocolor", "Set the color of the given object to the first found unused color.", (0)) { short colnum = 0; vector indices; vector colors;