From 65f63479538b613b6976926d4790be0bf1f60b0d Mon Sep 17 00:00:00 2001 From: "luz.paz" Date: Mon, 23 Mar 2020 08:36:51 -0400 Subject: [PATCH] [skip ci] Fix typos Found via ``` codespell -q 3 -L aci,ake,aline,alle,alledges,alocation,als,ang,anid,ba,beginn,behaviour,bloaded,byteorder,calculater,cancelled,cancelling,cas,cascade,centimetre,childs,colour,colours,commen,connexion,currenty,dof,doubleclick,dum,eiter,elemente,ende,feld,finde,findf,freez,hist,iff,indicies,initialisation,initialise,initialised,initialises,initialisiert,ist,kilometre,lod,mantatory,methode,metres,millimetre,modell,nd,noe,normale,normaly,nto,numer,oder,orgin,orginx,orginy,ot,pard,pres,programm,que,recurrance,rougly,seperator,serie,sinc,strack,substraction,te,thist,thru,tread,uint,unter,vertexes,wallthickness,whitespaces -S ./.git,*.po,*.ts,./ChangeLog.txt,./src/3rdParty,./src/Mod/Assembly/App/opendcm,./src/CXX,./src/zipios++,./src/Base/swig*,./src/Mod/Robot/App/kdl_cp,./src/Mod/Import/App/SCL,./src/WindowsInstaller,./src/Doc/FreeCAD.uml ``` --- src/Gui/Control.cpp | 2 +- src/Gui/DocumentRecovery.cpp | 2 +- src/Mod/AddonManager/addonmanager_workers.py | 2 +- src/Mod/Draft/coding_conventions.md | 4 ++-- src/Mod/Import/InitGui.py | 1 + src/Mod/Material/Material.py | 6 +++--- src/Mod/Path/PathScripts/PathSurface.py | 8 ++++---- src/Mod/Raytracing/Init.py | 1 + src/Mod/ReverseEngineering/Init.py | 1 + src/Mod/Sketcher/Gui/Command.cpp | 2 +- 10 files changed, 16 insertions(+), 13 deletions(-) diff --git a/src/Gui/Control.cpp b/src/Gui/Control.cpp index 11ca885cd4..791bd836ab 100644 --- a/src/Gui/Control.cpp +++ b/src/Gui/Control.cpp @@ -110,7 +110,7 @@ void ControlSingleton::showDialog(Gui::TaskView::TaskDialog *dlg) return; } - // Since the caller sets up a modeless task panel, it indicates intension + // Since the caller sets up a modeless task panel, it indicates intention // for prolonged editing. So disable auto transaction in the current call // stack. // Do this before showing the dialog because its open() function is called diff --git a/src/Gui/DocumentRecovery.cpp b/src/Gui/DocumentRecovery.cpp index bbc9c1d0de..faa00555f8 100644 --- a/src/Gui/DocumentRecovery.cpp +++ b/src/Gui/DocumentRecovery.cpp @@ -230,7 +230,7 @@ QString DocumentRecovery::createProjectFile(const QString& documentXml) void DocumentRecovery::closeEvent(QCloseEvent* e) { // Do not disable the X button in the title bar - // #0004281: Close Documant Recovery + // #0004281: Close Document Recovery e->accept(); } diff --git a/src/Mod/AddonManager/addonmanager_workers.py b/src/Mod/AddonManager/addonmanager_workers.py index 31ac5eb245..a87d40146a 100644 --- a/src/Mod/AddonManager/addonmanager_workers.py +++ b/src/Mod/AddonManager/addonmanager_workers.py @@ -231,7 +231,7 @@ class CheckWBWorker(QtCore.QThread): class FillMacroListWorker(QtCore.QThread): - """This worker opulates the list of macros""" + """This worker populates the list of macros""" add_macro_signal = QtCore.Signal(Macro) info_label_signal = QtCore.Signal(str) diff --git a/src/Mod/Draft/coding_conventions.md b/src/Mod/Draft/coding_conventions.md index ba662d93ef..c807f41bc6 100644 --- a/src/Mod/Draft/coding_conventions.md +++ b/src/Mod/Draft/coding_conventions.md @@ -30,7 +30,7 @@ ## Python -### Code formating +### Code formatting - In general, code should follow [PEP 8](https://www.python.org/dev/peps/pep-0008/) and [PEP 257](https://www.python.org/dev/peps/pep-0257/) (docstrings). @@ -72,7 +72,7 @@ and not meant to be part of the public interface should start with an underscore like `_MyInternalClass` or `_my_small_variable`. -### Python code formating tools +### Python code formatting tools - Using a code editor that automatically checks compliance with PEP 8 is recommended. diff --git a/src/Mod/Import/InitGui.py b/src/Mod/Import/InitGui.py index d55f9c0d2c..d61259dec2 100644 --- a/src/Mod/Import/InitGui.py +++ b/src/Mod/Import/InitGui.py @@ -1,3 +1,4 @@ +# -*- coding: utf8 -*- # Import gui init module # (c) 2003 Jürgen Riegel # diff --git a/src/Mod/Material/Material.py b/src/Mod/Material/Material.py index ba592f297b..18ad48eacc 100644 --- a/src/Mod/Material/Material.py +++ b/src/Mod/Material/Material.py @@ -24,18 +24,18 @@ import sys import FreeCAD -# here the usage description if you use this tool from the command line ("__main__") +# The usage description if you use this tool from the command line ("__main__") CommandlineUsage = """Material - Tool to work with FreeCAD Material definition cards Usage: Material [Options] card-file-name Options: - -c, --output-csv=file-name write a comma separated grid with the material data + -c, --output-csv=filename write a comma separated grid with the material data Exit: 0 No Error or Warning found - 1 Argument error, wrong or less Arguments given + 1 Argument error, wrong or too few Arguments given Tool to work with FreeCAD Material definition cards diff --git a/src/Mod/Path/PathScripts/PathSurface.py b/src/Mod/Path/PathScripts/PathSurface.py index 414d60ca5f..0c83884bc7 100644 --- a/src/Mod/Path/PathScripts/PathSurface.py +++ b/src/Mod/Path/PathScripts/PathSurface.py @@ -111,7 +111,7 @@ class ObjectSurface(PathOp.ObjectOp): obj.addProperty("App::PropertyPercent", "StepOver", "Surface", QtCore.QT_TRANSLATE_NOOP("App::Property", "Step over percentage of the drop cutter path")) obj.addProperty("App::PropertyVectorDistance", "CircularCenterCustom", "Surface Cut Options", QtCore.QT_TRANSLATE_NOOP("PathOp", "The start point of this path")) - obj.addProperty("App::PropertyEnumeration", "CircularCenterAt", "Surface Cut Options", QtCore.QT_TRANSLATE_NOOP("PathOp", "Choose what point to start the ciruclar pattern: Center Of Mass, Center Of Boundbox, Xmin Ymin of boundbox, Custom.")) + obj.addProperty("App::PropertyEnumeration", "CircularCenterAt", "Surface Cut Options", QtCore.QT_TRANSLATE_NOOP("PathOp", "Choose what point to start the circular pattern: Center Of Mass, Center Of Boundbox, Xmin Ymin of boundbox, Custom.")) obj.addProperty("App::PropertyEnumeration", "CutMode", "Surface Cut Options", QtCore.QT_TRANSLATE_NOOP("App::Property", "The direction that the toolpath should go around the part: Climb(ClockWise) or Conventional(CounterClockWise)")) obj.addProperty("App::PropertyEnumeration", "CutPattern", "Surface Cut Options", QtCore.QT_TRANSLATE_NOOP("App::Property", "Clearing pattern to use")) obj.addProperty("App::PropertyFloat", "CutPatternAngle", "Surface Cut Options", QtCore.QT_TRANSLATE_NOOP("App::Property", "Yaw angle for certain clearing patterns")) @@ -507,7 +507,7 @@ class ObjectSurface(PathOp.ObjectOp): PathLog.error('No data for model base: {}'.format(JOB.Model.Group[m].Label)) else: if m > 0: - # Raise to clearance between moddels + # Raise to clearance between models CMDS.append(Path.Command('N (Transition to base: {}.)'.format(Mdl.Label))) CMDS.append(Path.Command('G0', {'Z': obj.ClearanceHeight.Value, 'F': self.vertRapid})) PathLog.info('Working on Model.Group[{}]: {}'.format(m, Mdl.Label)) @@ -1171,7 +1171,7 @@ class ObjectSurface(PathOp.ObjectOp): def _isPocket(self, b, f, w): '''_isPocket(b, f, w)... - Attempts to determing if the wire(w) in face(f) of base(b) is a pocket or raised protrusion. + Attempts to determine if the wire(w) in face(f) of base(b) is a pocket or raised protrusion. Returns True if pocket, False if raised protrusion.''' e = w.Edges[0] for fi in range(0, len(b.Shape.Faces)): @@ -1907,7 +1907,7 @@ class ObjectSurface(PathOp.ObjectOp): def _planarPerformOclScan(self, obj, pdc, pathGeom, offsetPoints=False): '''_planarPerformOclScan(obj, pdc, pathGeom, offsetPoints=False)... - Switching fuction for calling the appropriate path-geometry to OCL points conversion fucntion + Switching function for calling the appropriate path-geometry to OCL points conversion function for the various cut patterns.''' PathLog.debug('_planarPerformOclScan()') SCANS = list() diff --git a/src/Mod/Raytracing/Init.py b/src/Mod/Raytracing/Init.py index 19eb5447a3..5cf86075c7 100644 --- a/src/Mod/Raytracing/Init.py +++ b/src/Mod/Raytracing/Init.py @@ -1,3 +1,4 @@ +# -*- coding: utf8 -*- # FreeCAD init script of the Raytracing module # (c) 2001 Jürgen Riegel diff --git a/src/Mod/ReverseEngineering/Init.py b/src/Mod/ReverseEngineering/Init.py index ecf1bb3f55..3a13579462 100644 --- a/src/Mod/ReverseEngineering/Init.py +++ b/src/Mod/ReverseEngineering/Init.py @@ -1,3 +1,4 @@ +# -*- coding: utf8 -*- # FreeCAD init script of the ReverseEngineering module # (c) 2001 Jürgen Riegel diff --git a/src/Mod/Sketcher/Gui/Command.cpp b/src/Mod/Sketcher/Gui/Command.cpp index 825594bd4b..c80bed10fc 100644 --- a/src/Mod/Sketcher/Gui/Command.cpp +++ b/src/Mod/Sketcher/Gui/Command.cpp @@ -762,7 +762,7 @@ void CmdSketcherMirrorSketch::activated(int iMsg) std::vector tempgeo = tempsketch->getInternalGeometry(); std::vector tempconstr = tempsketch->Constraints.getValues(); - // If value of addedGeometries or addedConstraints is -1, it gets added to vector begin iterator and that is invlid + // If value of addedGeometries or addedConstraints is -1, it gets added to vector begin iterator and that is invalid std::vector mirrorgeo(tempgeo.begin() + (addedGeometries + 1), tempgeo.end()); std::vector mirrorconstr(tempconstr.begin() + (addedConstraints + 1), tempconstr.end());