Ver Fonte

- in SVG parser modified some imports to be one on each line
- fixed the Tcl Command BBox (leftovers from recent global changes)
- fixed some typos in strings reported by @pcb-hobbyst on FlatCAM forum

Marius Stanciu há 5 anos atrás
pai
commit
35674c9647

+ 3 - 0
CHANGELOG.md

@@ -25,6 +25,9 @@ CHANGELOG for FlatCAM beta
 - some more fixes to problems generated by latest changes in the open handlers
 - some more fixes to problems generated by latest changes in the open handlers
 - modified the make_freezed.py script for the new location of the icons
 - modified the make_freezed.py script for the new location of the icons
 - added a fix for the ConnectionRefusedError in Linux that is issued when first running after a FlatCAM crash
 - added a fix for the ConnectionRefusedError in Linux that is issued when first running after a FlatCAM crash
+- in SVG parser modified some imports to be one on each line
+- fixed the Tcl Command BBox (leftovers from recent global changes)
+- fixed some typos in strings reported by @pcb-hobbyst on FlatCAM forum
 
 
 
 
 27.04.2020
 27.04.2020

+ 2 - 0
README.md

@@ -22,6 +22,7 @@ Menu -> Help -> About FlatCAM -> Programmers -> Marius Stanciu
 - Unzip them on a HDD location that your user has permissions for.
 - Unzip them on a HDD location that your user has permissions for.
 
 
 1.Windows
 1.Windows
+
 - download the provided installer (for your OS flavor 64bit or 32bit) from:
 - download the provided installer (for your OS flavor 64bit or 32bit) from:
 https://bitbucket.org/jpcgt/flatcam/downloads/
 https://bitbucket.org/jpcgt/flatcam/downloads/
 - execute the installer and install the program. It is recommended to install as a Local User.
 - execute the installer and install the program. It is recommended to install as a Local User.
@@ -61,6 +62,7 @@ cd D:\FlatCAM_beta
 python FlatCAM.py
 python FlatCAM.py
 
 
 2.Linux
 2.Linux
+
 - make sure that Python 3.8 is installed on your OS and that the command: python3 -V confirm it
 - make sure that Python 3.8 is installed on your OS and that the command: python3 -V confirm it
 - verify that the pip package is installed for your Python installation (e.g 3.8) by running the command:
 - verify that the pip package is installed for your Python installation (e.g 3.8) by running the command:
 ```
 ```

+ 3 - 3
flatcamGUI/FlatCAMGUI.py

@@ -1744,7 +1744,7 @@ class FlatCAMGUI(QtWidgets.QMainWindow):
                 # F keys section
                 # F keys section
                 _("Open Online Manual"),
                 _("Open Online Manual"),
                 _("Open Online Tutorials"), _("Refresh Plots"), _("Delete Object"), _("Alternate: Delete Tool"),
                 _("Open Online Tutorials"), _("Refresh Plots"), _("Delete Object"), _("Alternate: Delete Tool"),
-                _("(left to Key_1)Toogle Notebook Area (Left Side)"), _("En(Dis)able Obj Plot"),
+                _("(left to Key_1)Toggle Notebook Area (Left Side)"), _("En(Dis)able Obj Plot"),
                 _("Deselects all objects")
                 _("Deselects all objects")
             )
             )
         )
         )
@@ -2296,13 +2296,13 @@ class FlatCAMGUI(QtWidgets.QMainWindow):
         self.rel_position_label = QtWidgets.QLabel(
         self.rel_position_label = QtWidgets.QLabel(
             "<b>Dx</b>: 0.0000&nbsp;&nbsp;   <b>Dy</b>: 0.0000&nbsp;&nbsp;&nbsp;&nbsp;")
             "<b>Dx</b>: 0.0000&nbsp;&nbsp;   <b>Dy</b>: 0.0000&nbsp;&nbsp;&nbsp;&nbsp;")
         self.rel_position_label.setMinimumWidth(110)
         self.rel_position_label.setMinimumWidth(110)
-        self.rel_position_label.setToolTip(_("Relative neasurement.\nReference is last click position"))
+        self.rel_position_label.setToolTip(_("Relative measurement.\nReference is last click position"))
         self.infobar.addWidget(self.rel_position_label)
         self.infobar.addWidget(self.rel_position_label)
 
 
         self.position_label = QtWidgets.QLabel(
         self.position_label = QtWidgets.QLabel(
             "&nbsp;&nbsp;&nbsp;&nbsp;<b>X</b>: 0.0000&nbsp;&nbsp;   <b>Y</b>: 0.0000")
             "&nbsp;&nbsp;&nbsp;&nbsp;<b>X</b>: 0.0000&nbsp;&nbsp;   <b>Y</b>: 0.0000")
         self.position_label.setMinimumWidth(110)
         self.position_label.setMinimumWidth(110)
-        self.position_label.setToolTip(_("Absolute neasurement.\nReference is (X=0, Y= 0) position"))
+        self.position_label.setToolTip(_("Absolute measurement.\nReference is (X=0, Y= 0) position"))
         self.infobar.addWidget(self.position_label)
         self.infobar.addWidget(self.position_label)
 
 
         self.units_label = QtWidgets.QLabel("[in]")
         self.units_label = QtWidgets.QLabel("[in]")

+ 3 - 3
flatcamGUI/ObjectUI.py

@@ -308,7 +308,7 @@ class GerberObjectUI(ObjectUI):
         # Tool Type
         # Tool Type
         self.tool_type_label = QtWidgets.QLabel('%s:' % _('Tool Type'))
         self.tool_type_label = QtWidgets.QLabel('%s:' % _('Tool Type'))
         self.tool_type_label.setToolTip(
         self.tool_type_label.setToolTip(
-            _("Choose what tool to use for Gerber isolation:\n"
+            _("Choose which tool to use for Gerber isolation:\n"
               "'Circular' or 'V-shape'.\n"
               "'Circular' or 'V-shape'.\n"
               "When the 'V-shape' is selected then the tool\n"
               "When the 'V-shape' is selected then the tool\n"
               "diameter will depend on the chosen cut depth.")
               "diameter will depend on the chosen cut depth.")
@@ -435,7 +435,7 @@ class GerberObjectUI(ObjectUI):
         grid1.addWidget(self.follow_cb, 8, 1)
         grid1.addWidget(self.follow_cb, 8, 1)
 
 
         self.except_cb.setToolTip(_("When the isolation geometry is generated,\n"
         self.except_cb.setToolTip(_("When the isolation geometry is generated,\n"
-                                    "by checking this, the area of the object bellow\n"
+                                    "by checking this, the area of the object below\n"
                                     "will be subtracted from the isolation geometry."))
                                     "will be subtracted from the isolation geometry."))
         grid1.addWidget(self.except_cb, 8, 2)
         grid1.addWidget(self.except_cb, 8, 2)
 
 
@@ -1532,7 +1532,7 @@ class GeometryObjectUI(ObjectUI):
                 "- Circular with 1 ... 4 teeth -> it is informative only. Being circular the cut width in material\n"
                 "- Circular with 1 ... 4 teeth -> it is informative only. Being circular the cut width in material\n"
                 "is exactly the tool diameter.\n"
                 "is exactly the tool diameter.\n"
                 "- Ball -> informative only and make reference to the Ball type endmill.\n"
                 "- Ball -> informative only and make reference to the Ball type endmill.\n"
-                "- V-Shape -> it will disable de Z-Cut parameter in the UI form and enable two additional UI form\n"
+                "- V-Shape -> it will disable Z-Cut parameter in the UI form and enable two additional UI form\n"
                 "fields: V-Tip Dia and V-Tip Angle. Adjusting those two values will adjust the Z-Cut parameter such\n"
                 "fields: V-Tip Dia and V-Tip Angle. Adjusting those two values will adjust the Z-Cut parameter such\n"
                 "as the cut width into material will be equal with the value in the Tool "
                 "as the cut width into material will be equal with the value in the Tool "
                 "Diameter column of this table.\n"
                 "Diameter column of this table.\n"

+ 1 - 1
flatcamGUI/PreferencesUI.py

@@ -2396,7 +2396,7 @@ class GerberAdvOptPrefGroupUI(OptionsGroupUI):
         # Tool Type
         # Tool Type
         self.tool_type_label = QtWidgets.QLabel('<b>%s</b>' % _('Tool Type'))
         self.tool_type_label = QtWidgets.QLabel('<b>%s</b>' % _('Tool Type'))
         self.tool_type_label.setToolTip(
         self.tool_type_label.setToolTip(
-            _("Choose what tool to use for Gerber isolation:\n"
+            _("Choose which tool to use for Gerber isolation:\n"
               "'Circular' or 'V-shape'.\n"
               "'Circular' or 'V-shape'.\n"
               "When the 'V-shape' is selected then the tool\n"
               "When the 'V-shape' is selected then the tool\n"
               "diameter will depend on the chosen cut depth.")
               "diameter will depend on the chosen cut depth.")

+ 2 - 1
flatcamParsers/ParseSVG.py

@@ -21,7 +21,8 @@
 
 
 # import xml.etree.ElementTree as ET
 # import xml.etree.ElementTree as ET
 from svg.path import Line, Arc, CubicBezier, QuadraticBezier, parse_path
 from svg.path import Line, Arc, CubicBezier, QuadraticBezier, parse_path
-from svg.path.path import Move, Close
+from svg.path.path import Move
+from svg.path.path import Close
 from shapely.geometry import LineString, LinearRing, MultiLineString
 from shapely.geometry import LineString, LinearRing, MultiLineString
 from shapely.affinity import skew, affine_transform, rotate
 from shapely.affinity import skew, affine_transform, rotate
 import numpy as np
 import numpy as np

+ 1 - 1
flatcamTools/ToolNCC.py

@@ -151,7 +151,7 @@ class NonCopperClear(FlatCAMTool, Gerber):
               "- Circular with 1 ... 4 teeth -> it is informative only. Being circular,\n"
               "- Circular with 1 ... 4 teeth -> it is informative only. Being circular,\n"
               "the cut width in material is exactly the tool diameter.\n"
               "the cut width in material is exactly the tool diameter.\n"
               "- Ball -> informative only and make reference to the Ball type endmill.\n"
               "- Ball -> informative only and make reference to the Ball type endmill.\n"
-              "- V-Shape -> it will disable de Z-Cut parameter in the resulting geometry UI form\n"
+              "- V-Shape -> it will disable Z-Cut parameter in the resulting geometry UI form\n"
               "and enable two additional UI form fields in the resulting geometry: V-Tip Dia and\n"
               "and enable two additional UI form fields in the resulting geometry: V-Tip Dia and\n"
               "V-Tip Angle. Adjusting those two values will adjust the Z-Cut parameter such\n"
               "V-Tip Angle. Adjusting those two values will adjust the Z-Cut parameter such\n"
               "as the cut width into material will be equal with the value in the Tool Diameter\n"
               "as the cut width into material will be equal with the value in the Tool Diameter\n"

+ 1 - 1
flatcamTools/ToolPaint.py

@@ -147,7 +147,7 @@ class ToolPaint(FlatCAMTool, Gerber):
               "- <B>Circular</B> with 1 ... 4 teeth -> it is informative only. Being circular, <BR>"
               "- <B>Circular</B> with 1 ... 4 teeth -> it is informative only. Being circular, <BR>"
               "the cut width in material is exactly the tool diameter.<BR>"
               "the cut width in material is exactly the tool diameter.<BR>"
               "- <B>Ball</B> -> informative only and make reference to the Ball type endmill.<BR>"
               "- <B>Ball</B> -> informative only and make reference to the Ball type endmill.<BR>"
-              "- <B>V-Shape</B> -> it will disable de Z-Cut parameter in the resulting geometry UI form "
+              "- <B>V-Shape</B> -> it will disable Z-Cut parameter in the resulting geometry UI form "
               "and enable two additional UI form fields in the resulting geometry: V-Tip Dia and "
               "and enable two additional UI form fields in the resulting geometry: V-Tip Dia and "
               "V-Tip Angle. Adjusting those two values will adjust the Z-Cut parameter such "
               "V-Tip Angle. Adjusting those two values will adjust the Z-Cut parameter such "
               "as the cut width into material will be equal with the value in the Tool Diameter "
               "as the cut width into material will be equal with the value in the Tool Diameter "

+ 2 - 2
tclCommands/TclCommandBbox.py

@@ -44,7 +44,7 @@ class TclCommandBbox(TclCommand):
             ('name', 'Object name for which to create bounding box. String'),
             ('name', 'Object name for which to create bounding box. String'),
             ('margin', "Distance of the edges of the box to the nearest polygon."
             ('margin', "Distance of the edges of the box to the nearest polygon."
                        "Float number."),
                        "Float number."),
-            ('rounded', "If the bounding box is to have rounded corners their radius is equal to the margin. "
+            ('rounded', "If the bounding box has to have rounded corners their radius is equal to the margin. "
                         "True (1) or False (0)."),
                         "True (1) or False (0)."),
             ('outname', 'Name of the resulting Geometry object. String.')
             ('outname', 'Name of the resulting Geometry object. String.')
         ]),
         ]),
@@ -70,7 +70,7 @@ class TclCommandBbox(TclCommand):
         if obj is None:
         if obj is None:
             self.raise_tcl_error("%s: %s" % (_("Object not found"), name))
             self.raise_tcl_error("%s: %s" % (_("Object not found"), name))
 
 
-        if not isinstance(obj, FlatCAMGerber) and not isinstance(obj, FlatCAMGeometry):
+        if obj.kind != 'gerber' and obj.kind != 'geometry':
             self.raise_tcl_error('%s %s: %s.' % (
             self.raise_tcl_error('%s %s: %s.' % (
                 _("Expected GerberObject or GeometryObject, got"), name, type(obj)))
                 _("Expected GerberObject or GeometryObject, got"), name, type(obj)))