From 63ab1dcd43456f240e76bf2550c65009ab15c782 Mon Sep 17 00:00:00 2001 From: donovaly Date: Sat, 16 Feb 2019 04:31:32 +0100 Subject: [PATCH 1/9] more work on the wording - uniform menu entries - fix some typos - wording cleanup --- a2p_MuxAssembly.py | 2 +- a2p_constraintDialog.py | 6 +++--- a2p_constraintcommands.py | 16 ++++++++-------- a2p_importpart.py | 40 +++++++++++++++++++-------------------- a2p_solversystem.py | 4 ++-- 5 files changed, 33 insertions(+), 35 deletions(-) diff --git a/a2p_MuxAssembly.py b/a2p_MuxAssembly.py index afc86e65..9ef4e0c8 100644 --- a/a2p_MuxAssembly.py +++ b/a2p_MuxAssembly.py @@ -341,7 +341,7 @@ class a2p_SimpleAssemblyShapeCommand(): def GetResources(self): import a2plib return {'Pixmap' : a2plib.path_a2p +'/icons/a2p_SimpleAssemblyShape.svg', - 'MenuText': "Create or refresh simple shape of complete Assembly", + 'MenuText': "Create or refresh simple shape of complete assembly", 'ToolTip': toolTip } diff --git a/a2p_constraintDialog.py b/a2p_constraintDialog.py index 0cfcf1a4..1fb34aa0 100644 --- a/a2p_constraintDialog.py +++ b/a2p_constraintDialog.py @@ -194,19 +194,19 @@ def initUI(self): self.deleteButton = QtGui.QPushButton(self.buttonPanel) self.deleteButton.setFixedHeight(32) self.deleteButton.setIcon(QtGui.QIcon(':/icons/a2p_DeleteConnections.svg')) #need new Icon - self.deleteButton.setToolTip("delete this constraint") + self.deleteButton.setToolTip("Delete this constraint") self.deleteButton.setText("Delete this constraint") self.solveButton = QtGui.QPushButton(self.buttonPanel) self.solveButton.setFixedHeight(32) self.solveButton.setIcon(QtGui.QIcon(':/icons/a2p_Solver.svg')) - self.solveButton.setToolTip("solve Constraints") + self.solveButton.setToolTip("Solve constraints") self.solveButton.setText("Solve") self.acceptButton = QtGui.QPushButton(self.buttonPanel) self.acceptButton.setFixedHeight(32) self.acceptButton.setIcon(QtGui.QIcon(':/icons/a2p_CheckAssembly.svg')) #need new Icon - self.acceptButton.setToolTip("solve Constraints") + self.acceptButton.setToolTip("Solve constraints") self.acceptButton.setText("Accept") #self.acceptButton.setDefault(True) diff --git a/a2p_constraintcommands.py b/a2p_constraintcommands.py index 48c76ec6..c674d052 100644 --- a/a2p_constraintcommands.py +++ b/a2p_constraintcommands.py @@ -52,7 +52,7 @@ def IsActive(self): def GetResources(self): return { 'Pixmap' : path_a2p + '/icons/a2p_PointIdentity.svg', - 'MenuText': 'Add PointIdentity Constraint', + 'MenuText': 'Add pointIdentity constraint', 'ToolTip': a2p_constraints.PointIdentityConstraint.getToolTip() } @@ -78,7 +78,7 @@ def IsActive(self): def GetResources(self): return { 'Pixmap' : path_a2p + '/icons/a2p_PointOnLineConstraint.svg', - 'MenuText': 'Add PointOnLine constraint', + 'MenuText': 'Add pointOnLine constraint', 'ToolTip': a2p_constraints.PointOnLineConstraint.getToolTip() } @@ -104,7 +104,7 @@ def IsActive(self): def GetResources(self): return { 'Pixmap' : path_a2p + '/icons/a2p_PointOnPlaneConstraint.svg', - 'MenuText': 'Add PointOnPlane constraint', + 'MenuText': 'Add pointOnPlane constraint', 'ToolTip': a2p_constraints.PointOnPlaneConstraint.getToolTip() } @@ -129,7 +129,7 @@ def IsActive(self): def GetResources(self): return { 'Pixmap' : path_a2p + '/icons/a2p_SphericalSurfaceConstraint.svg', - 'MenuText': 'Add a spherical constraint', + 'MenuText': 'Add sphereCenterIdent constraint', 'ToolTip': a2p_constraints.SphericalConstraint.getToolTip() } @@ -154,7 +154,7 @@ def IsActive(self): def GetResources(self): return { 'Pixmap' : path_a2p + '/icons/a2p_CircularEdgeConstraint.svg' , - 'MenuText': 'Add circular edge connection', + 'MenuText': 'Add circularEdge constraint', 'ToolTip': a2p_constraints.CircularEdgeConstraint.getToolTip() } @@ -179,7 +179,7 @@ def IsActive(self): def GetResources(self): return { 'Pixmap' : path_a2p + '/icons/a2p_AxialConstraint.svg', - 'MenuText': 'Add axial constraint', + 'MenuText': 'Add axis Coincident constraint', 'ToolTip': a2p_constraints.AxialConstraint.getToolTip() } @@ -279,7 +279,7 @@ def IsActive(self): def GetResources(self): return { 'Pixmap' : path_a2p + '/icons/a2p_PlaneCoincidentConstraint.svg', - 'MenuText': 'Add plane constraint', + 'MenuText': 'Add planeCoincident constraint', 'ToolTip': a2p_constraints.PlaneConstraint.getToolTip() } @@ -305,7 +305,7 @@ def IsActive(self): def GetResources(self): return { 'Pixmap' : path_a2p + '/icons/a2p_AngleConstraint.svg', - 'MenuText': 'Add angleBetweenPlanes constraint', + 'MenuText': 'Add angledPlanes constraint', 'ToolTip': a2p_constraints.AngledPlanesConstraint.getToolTip() } diff --git a/a2p_importpart.py b/a2p_importpart.py index 04b3552c..dcd12dba 100644 --- a/a2p_importpart.py +++ b/a2p_importpart.py @@ -123,7 +123,7 @@ def importPartFromFile(_doc, filename, importToCache=False): ImportGui.insert(filename,newname) importDoc = FreeCAD.ActiveDocument else: - msg = "A part can only be imported from a FreeCAD '*.fcstd' file" + msg = "A part can only be imported from a FreeCAD '*.FCStd' file" QtGui.QMessageBox.information( QtGui.QApplication.activeWindow(), "Value Error", msg ) return @@ -245,7 +245,7 @@ class a2p_ImportPartCommand(): def GetResources(self): return {'Pixmap' : a2plib.pathOfModule()+'/icons/a2p_ImportPart.svg', 'Accel' : "Shift+A", # a default shortcut (optional) - 'MenuText': "Add a Part from an external file", + 'MenuText': "Add a part from an external file", 'ToolTip' : toolTip } @@ -554,7 +554,7 @@ def Activated(self): def GetResources(self): return { 'Pixmap' : a2plib.pathOfModule()+'/icons/a2p_DuplicatePart.svg', - 'MenuText': 'Make a duplicate of a part', + 'MenuText': 'Create duplicate of a part', 'ToolTip': toolTip } @@ -680,7 +680,7 @@ def Activated(self): def GetResources(self): return { 'Pixmap' : a2plib.pathOfModule()+'/icons/a2p_EditPart.svg', - 'MenuText': 'Edit an imported Part (open linked fcstd file)', + 'MenuText': 'Edit an imported part (open linked FCStd file)', 'ToolTip': toolTip } @@ -822,7 +822,7 @@ def Activated(self): QtGui.QMessageBox.critical( QtGui.QApplication.activeWindow(), "Selection Error", - "Select exactly 1 Part") + "Select exactly 1 part") return part = selection[0] deleteList = [] @@ -992,7 +992,7 @@ def Activated(self): def GetResources(self): return { 'Pixmap' : a2plib.pathOfModule()+'/icons/a2p_Isolate_Element.svg', - 'MenuText': 'Show only selected elements, or all if none is selected', + 'MenuText': 'Show only selected elements or all if none is selected', 'ToolTip': toolTip } @@ -1025,7 +1025,7 @@ def GetResources(self): return { 'Pixmap' : a2plib.pathOfModule()+'/icons/a2p_ToggleTransparency.svg', 'MenuText': 'Toggle transparency of assembly', - 'ToolTip': 'Toggle transparency of assembly', + 'ToolTip': 'Toggles transparency of assembly', 'Checkable': self.IsChecked() } FreeCADGui.addCommand('a2p_ToggleTransparencyCommand', a2p_ToggleTransparencyCommand()) @@ -1057,7 +1057,7 @@ def IsChecked(self): def GetResources(self): return { 'Pixmap' : a2plib.pathOfModule()+'/icons/a2p_ToggleAutoSolve.svg', - 'MenuText': 'Toggle AutoSolve', + 'MenuText': 'Toggle auto solve', 'ToolTip': toolTipMessage, 'Checkable': self.IsChecked() } @@ -1076,8 +1076,8 @@ def IsChecked(self): def GetResources(self): return { 'Pixmap' : a2plib.pathOfModule()+'/icons/a2p_TogglePartial.svg', - 'MenuText': 'toggle partial processing', - 'ToolTip': 'toggle partial processing', + 'MenuText': 'Toggle partial processing', + 'ToolTip': 'Toggles partial processing', 'Checkable': self.IsChecked() } FreeCADGui.addCommand('a2p_TogglePartialProcessingCommand', a2p_TogglePartialProcessingCommand()) @@ -1142,7 +1142,7 @@ def Activated(self): def GetResources(self): return { 'Pixmap' : a2plib.pathOfModule()+'/icons/a2p_RepairTree.svg', - 'MenuText': 'Repair the treeView, if it is damaged somehow', + 'MenuText': 'Repair the tree view if it is somehow damaged', 'ToolTip': toolTipMessage } FreeCADGui.addCommand('a2p_repairTreeViewCommand', a2p_repairTreeViewCommand()) @@ -1153,11 +1153,9 @@ def GetResources(self): If the last constraint, which has been defined, has a property -'direction', it's value will be +'direction', its value will be toggled between 'aligned' and -'opposed' - -(alignment of axis's) +'opposed' (alignment of axis) ''' @@ -1223,7 +1221,7 @@ def GetResources(self): return { 'Pixmap' : a2plib.pathOfModule()+'/icons/a2p_Treeview.svg', 'MenuText': 'Generate HTML file with detailed constraining structure', - 'ToolTip': 'Generate HTML file with detailed constraining structure' + 'ToolTip': 'Generates HTML file with detailed constraining structure' } FreeCADGui.addCommand('a2p_Show_Hierarchy_Command', a2p_Show_Hierarchy_Command()) @@ -1245,7 +1243,7 @@ def GetResources(self): return { 'Pixmap' : a2plib.pathOfModule()+'/icons/a2p_DOFs.svg', 'MenuText': 'Print detailed DOF information to console', - 'ToolTip': 'Print detailed DOF information to console' + 'ToolTip': 'Prints detailed DOF information to console' } FreeCADGui.addCommand('a2p_Show_DOF_info_Command', a2p_Show_DOF_info_Command()) @@ -1279,8 +1277,8 @@ def Activated(self): def GetResources(self): return { 'Pixmap' : a2plib.pathOfModule()+'/icons/a2p_SetRelativePathes.svg', - 'MenuText': 'Convert absolute paths of importParts to relative ones', - 'ToolTip': 'Convert absolute paths of importParts to relative ones' + 'MenuText': 'Convert absolute paths of imported parts to relative ones', + 'ToolTip': 'Converts absolute paths of imported parts to relative ones' } FreeCADGui.addCommand('a2p_absPath_to_relPath_Command', a2p_absPath_to_relPath_Command()) @@ -1395,12 +1393,12 @@ def importUpdateConstraintSubobjects( doc, oldObject, newObject ): for cName in deletionList: flags = QtGui.QMessageBox.StandardButton.Yes | QtGui.QMessageBox.StandardButton.Abort - message = "constraint %s is broken. Delete constraint? otherwise check for wrong linkage." % cName + message = "Constraint %s is broken. Delete constraint? Otherwise check for wrong linkage." % cName #response = QtGui.QMessageBox.critical(QtGui.qApp.activeWindow(), "Broken Constraint", message, flags ) response = QtGui.QMessageBox.critical(None, "Broken Constraint", message, flags ) if response == QtGui.QMessageBox.Yes: - FreeCAD.Console.PrintError("removing constraint %s" % cName) + FreeCAD.Console.PrintError("Removing constraint %s" % cName) c = doc.getObject(cName) a2plib.removeConstraint(c) diff --git a/a2p_solversystem.py b/a2p_solversystem.py index c95f104d..6cca741d 100644 --- a/a2p_solversystem.py +++ b/a2p_solversystem.py @@ -549,8 +549,8 @@ def Activated(self): def GetResources(self): return { 'Pixmap' : path_a2p + '/icons/a2p_Solver.svg', - 'MenuText': 'Solve', - 'ToolTip': 'Solve A2plus constraints' + 'MenuText': 'Solve constraints', + 'ToolTip': 'Solves constraints' } FreeCADGui.addCommand('a2p_SolverCommand', a2p_SolverCommand()) From 087d0f8a8a0be0fe7481d8c8fc481c0bb4c60de2 Mon Sep 17 00:00:00 2001 From: donovaly Date: Sat, 16 Feb 2019 17:19:45 +0100 Subject: [PATCH 2/9] minor changes in a2p_prefs.ui Things I stumbled over while documenting the preferences --- GuiA2p/Resources/ui/a2p_prefs.ui | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/GuiA2p/Resources/ui/a2p_prefs.ui b/GuiA2p/Resources/ui/a2p_prefs.ui index 089ea1e8..84c78529 100644 --- a/GuiA2p/Resources/ui/a2p_prefs.ui +++ b/GuiA2p/Resources/ui/a2p_prefs.ui @@ -391,7 +391,7 @@ - Solve automatically if a constraints property is changed + Solve automatically if a constraint property is changed true From 5c47c61c5a5e9a72c346ae7ae4e99dd5f50fb7f1 Mon Sep 17 00:00:00 2001 From: donovaly Date: Sat, 16 Feb 2019 17:36:48 +0100 Subject: [PATCH 3/9] one more one more --- GuiA2p/Resources/ui/a2p_prefs.ui | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/GuiA2p/Resources/ui/a2p_prefs.ui b/GuiA2p/Resources/ui/a2p_prefs.ui index 84c78529..e2ae412f 100644 --- a/GuiA2p/Resources/ui/a2p_prefs.ui +++ b/GuiA2p/Resources/ui/a2p_prefs.ui @@ -38,7 +38,7 @@ - Show constraints on toolbar + Show constraints in toolbar true From 3ef4defad0e00611354c50934a8cc2b19fbdcb7c Mon Sep 17 00:00:00 2001 From: donovaly Date: Sat, 16 Feb 2019 17:45:59 +0100 Subject: [PATCH 4/9] uniform dialog text --- a2p_constraintDialog.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/a2p_constraintDialog.py b/a2p_constraintDialog.py index 1fb34aa0..0061e506 100644 --- a/a2p_constraintDialog.py +++ b/a2p_constraintDialog.py @@ -112,7 +112,7 @@ def initUI(self): self.flipDirectionButton = QtGui.QPushButton(self) self.flipDirectionButton.setIcon(QtGui.QIcon(':/icons/a2p_FlipConstraint.svg')) - self.flipDirectionButton.setText("Flip Dir.") + self.flipDirectionButton.setText("Flip direction") self.flipDirectionButton.setFixedHeight(32) QtCore.QObject.connect(self.flipDirectionButton, QtCore.SIGNAL("clicked()"), self.flipDirection) self.mainLayout.addWidget(self.flipDirectionButton,self.lineNo,2) From 33f27ce3b9405e347a5110b1e198987813014962 Mon Sep 17 00:00:00 2001 From: donovaly Date: Sat, 16 Feb 2019 17:54:46 +0100 Subject: [PATCH 5/9] Make it more clear --- GuiA2p/Resources/ui/a2p_prefs.ui | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/GuiA2p/Resources/ui/a2p_prefs.ui b/GuiA2p/Resources/ui/a2p_prefs.ui index e2ae412f..f666997e 100644 --- a/GuiA2p/Resources/ui/a2p_prefs.ui +++ b/GuiA2p/Resources/ui/a2p_prefs.ui @@ -321,7 +321,7 @@ - Use project-folder, all files are below this + All files are in this project folder: useProjectFolder From 55e1bdd7b0816b034dc1485d2858d851cd0b7697 Mon Sep 17 00:00:00 2001 From: donovaly Date: Sat, 16 Feb 2019 18:04:40 +0100 Subject: [PATCH 6/9] add a tooltip --- GuiA2p/Resources/ui/a2p_prefs.ui | 3 +++ 1 file changed, 3 insertions(+) diff --git a/GuiA2p/Resources/ui/a2p_prefs.ui b/GuiA2p/Resources/ui/a2p_prefs.ui index f666997e..d718ea9a 100644 --- a/GuiA2p/Resources/ui/a2p_prefs.ui +++ b/GuiA2p/Resources/ui/a2p_prefs.ui @@ -320,6 +320,9 @@ + + Specify the project folder in the field below + All files are in this project folder: From 1811d73cb4d966d13bca449cdcbbdde4bce87976 Mon Sep 17 00:00:00 2001 From: donovaly Date: Sat, 16 Feb 2019 18:42:01 +0100 Subject: [PATCH 7/9] remove unnecessary words - keep uniformity of preferences entries - in a later commit I will add tooltips to every setting --- GuiA2p/Resources/ui/a2p_prefs.ui | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/GuiA2p/Resources/ui/a2p_prefs.ui b/GuiA2p/Resources/ui/a2p_prefs.ui index d718ea9a..b0111131 100644 --- a/GuiA2p/Resources/ui/a2p_prefs.ui +++ b/GuiA2p/Resources/ui/a2p_prefs.ui @@ -105,7 +105,7 @@ - Enable recursive update of imported parts (process all subassemblies) + Enable recursive update of imported parts enableRecursiveUpdate From c61162207d866ee9533a588dfaeff74429be7111 Mon Sep 17 00:00:00 2001 From: donovaly Date: Sat, 16 Feb 2019 18:46:31 +0100 Subject: [PATCH 8/9] fix a typo --- GuiA2p/Resources/ui/a2p_prefs.ui | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/GuiA2p/Resources/ui/a2p_prefs.ui b/GuiA2p/Resources/ui/a2p_prefs.ui index b0111131..83bf5f20 100644 --- a/GuiA2p/Resources/ui/a2p_prefs.ui +++ b/GuiA2p/Resources/ui/a2p_prefs.ui @@ -131,7 +131,7 @@ - Inherit per face transparency from parts and sub-assemblies (experimental) + Inherit per face transparency from parts and subassemblies (experimental) usePerFaceTransparency From 646207401b97dc1bc9f34e43b7858bf80208cce6 Mon Sep 17 00:00:00 2001 From: donovaly Date: Sat, 16 Feb 2019 18:55:35 +0100 Subject: [PATCH 9/9] don't fear users either it is experimental or if not, it might be an expert feature --- GuiA2p/Resources/ui/a2p_prefs.ui | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/GuiA2p/Resources/ui/a2p_prefs.ui b/GuiA2p/Resources/ui/a2p_prefs.ui index 83bf5f20..9f414bd2 100644 --- a/GuiA2p/Resources/ui/a2p_prefs.ui +++ b/GuiA2p/Resources/ui/a2p_prefs.ui @@ -144,7 +144,7 @@ - Do not import invisible shapes (use with caution, can break assemblies) + Do not import invisible shapes (for expert users) doNotImportInvisibleShapes