فهرست منبع

- the Jump To popup window will now autoselect the LineEdit therefore no more need for an extra click after launching the function

Marius Stanciu 6 سال پیش
والد
کامیت
aa7bc125f4
3فایلهای تغییر یافته به همراه6 افزوده شده و 4 حذف شده
  1. 1 0
      README.md
  2. 4 2
      flatcamGUI/GUIElements.py
  3. 1 2
      flatcamTools/ToolPunchGerber.py

+ 1 - 0
README.md

@@ -13,6 +13,7 @@ CAD program, and create G-Code for Isolation routing.
 
 
 - in Geometry Editor made sure that on final save, for MultiLineString geometry all the connected lines are merged into one LineString to minimize the number of vertical movements in GCode
 - in Geometry Editor made sure that on final save, for MultiLineString geometry all the connected lines are merged into one LineString to minimize the number of vertical movements in GCode
 - more work in Punch Gerber Tool
 - more work in Punch Gerber Tool
+- the Jump To popup window will now autoselect the LineEdit therefore no more need for an extra click after launching the function
 
 
 24.02.2020
 24.02.2020
 
 

+ 4 - 2
flatcamGUI/GUIElements.py

@@ -2278,7 +2278,7 @@ class Dialog_box(QtWidgets.QWidget):
 
 
 
 
 class DialogBoxRadio(QtWidgets.QDialog):
 class DialogBoxRadio(QtWidgets.QDialog):
-    def __init__(self, title=None, label=None, icon=None, initial_text=None, reference='abs'):
+    def __init__(self, title=None, label=None, icon=None, initial_text=None, reference='abs', parent=None):
         """
         """
 
 
         :param title: string with the window title
         :param title: string with the window title
@@ -2322,8 +2322,10 @@ class DialogBoxRadio(QtWidgets.QDialog):
               "If the reference is Relative then the Jump will be at the (x,y) distance\n"
               "If the reference is Relative then the Jump will be at the (x,y) distance\n"
               "from the current mouse location point.")
               "from the current mouse location point.")
         )
         )
-        self.lineEdit = EvalEntry()
+        self.lineEdit = EvalEntry(self)
         self.lineEdit.setText(str(self.location).replace('(', '').replace(')', ''))
         self.lineEdit.setText(str(self.location).replace('(', '').replace(')', ''))
+        self.lineEdit.selectAll()
+        self.lineEdit.setFocus()
         self.form.addRow(self.loc_label, self.lineEdit)
         self.form.addRow(self.loc_label, self.lineEdit)
 
 
         self.button_box = QtWidgets.QDialogButtonBox(QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel,
         self.button_box = QtWidgets.QDialogButtonBox(QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel,

+ 1 - 2
flatcamTools/ToolPunchGerber.py

@@ -249,7 +249,7 @@ class ToolPunchGerber(FlatCAMTool):
         self.grid1.addWidget(self.circular_ring_entry, 3, 1)
         self.grid1.addWidget(self.circular_ring_entry, 3, 1)
 
 
         # Oblong Annular Ring Value
         # Oblong Annular Ring Value
-        self.oblong_ring_label= QtWidgets.QLabel('%s:' % _("Oblong"))
+        self.oblong_ring_label = QtWidgets.QLabel('%s:' % _("Oblong"))
         self.oblong_ring_label.setToolTip(
         self.oblong_ring_label.setToolTip(
             _("The size of annular ring for oblong pads.")
             _("The size of annular ring for oblong pads.")
         )
         )
@@ -634,4 +634,3 @@ class ToolPunchGerber(FlatCAMTool):
         self.gerber_object_combo.setRootModelIndex(self.app.collection.index(0, 0, QtCore.QModelIndex()))
         self.gerber_object_combo.setRootModelIndex(self.app.collection.index(0, 0, QtCore.QModelIndex()))
         self.exc_combo.setRootModelIndex(self.app.collection.index(1, 0, QtCore.QModelIndex()))
         self.exc_combo.setRootModelIndex(self.app.collection.index(1, 0, QtCore.QModelIndex()))
         self.ui_disconnect()
         self.ui_disconnect()
-