Draft - enable toggle grid command in edit mode

Some people would like to have more control over draft grid visibility  while in Sketcher edit mode.  Hence this PR enables the usage of Draft ToggleGrid  command in Sketcher edit mode.

Forum discussion:
https://forum.freecadweb.org/viewtopic.php?f=34&t=43265&start=20#p374747
This commit is contained in:
triplus
2020-03-07 00:38:14 +01:00
committed by Yorik van Havre
parent 621c30db50
commit 946fd7352b

View File

@@ -4856,7 +4856,8 @@ class ToggleGrid():
return {'Pixmap' : 'Draft_Grid',
'Accel' : "G,R",
'MenuText': QtCore.QT_TRANSLATE_NOOP("Draft_ToggleGrid", "Toggle Grid"),
'ToolTip' : QtCore.QT_TRANSLATE_NOOP("Draft_ToggleGrid", "Toggles the Draft grid on/off")}
'ToolTip' : QtCore.QT_TRANSLATE_NOOP("Draft_ToggleGrid", "Toggles the Draft grid on/off"),
'CmdType' : 'ForEdit'}
def Activated(self):
if hasattr(FreeCADGui,"Snapper"):