- re-added the position labels in the status bar; they will be useful if HUD is Off (Altium does the same :) so learn from the best)

This commit is contained in:
Marius Stanciu
2020-05-12 01:21:29 +03:00
committed by Marius
parent 3a337212f0
commit d739a5b05d
14 changed files with 43 additions and 42 deletions

View File

@@ -1069,7 +1069,7 @@ class ToolCalibration(FlatCAMTool):
# delete the absolute and relative position and messages in the infobar
self.app.ui.position_label.setText("")
self.app.ui.rel_position_label.setText("")
# self.app.ui.rel_position_label.setText("")
# first clear previous text in text editor (if any)
self.gcode_editor_tab.code_editor.clear()

View File

@@ -917,8 +917,8 @@ class ToolCopperThieving(FlatCAMTool):
self.app.dy = curr_pos[1] - float(self.cursor_pos[1])
# # update the positions on status bar
# self.app.ui.position_label.setText("&nbsp;&nbsp;&nbsp;&nbsp;<b>X</b>: %.4f&nbsp;&nbsp; "
# "<b>Y</b>: %.4f" % (curr_pos[0], curr_pos[1]))
self.app.ui.position_label.setText("&nbsp;<b>X</b>: %.4f&nbsp;&nbsp; "
"<b>Y</b>: %.4f&nbsp;" % (curr_pos[0], curr_pos[1]))
# self.app.ui.rel_position_label.setText("<b>Dx</b>: %.4f&nbsp;&nbsp; <b>Dy</b>: "
# "%.4f&nbsp;&nbsp;&nbsp;&nbsp;" % (self.app.dx, self.app.dy))

View File

@@ -544,11 +544,11 @@ class Distance(FlatCAMTool):
else:
pos = (pos_canvas[0], pos_canvas[1])
# self.app.ui.position_label.setText(
# "&nbsp;&nbsp;&nbsp;&nbsp;<b>X</b>: {}&nbsp;&nbsp; <b>Y</b>: {}".format(
# '%.*f' % (self.decimals, pos[0]), '%.*f' % (self.decimals, pos[1])
# )
# )
self.app.ui.position_label.setText(
"&nbsp;&nbsp;&nbsp;&nbsp;<b>X</b>: {}&nbsp;&nbsp; <b>Y</b>: {}".format(
'%.*f' % (self.decimals, pos[0]), '%.*f' % (self.decimals, pos[1])
)
)
units = self.app.defaults["units"].lower()
self.app.plotcanvas.text_hud.text = \
@@ -583,7 +583,7 @@ class Distance(FlatCAMTool):
except Exception as e:
log.debug("Distance.on_mouse_move_meas() --> %s" % str(e))
self.app.ui.position_label.setText("")
self.app.ui.rel_position_label.setText("")
# self.app.ui.rel_position_label.setText("")
def utility_geometry(self, pos):
# first delete old shape

View File

@@ -1832,8 +1832,8 @@ class NonCopperClear(FlatCAMTool, Gerber):
self.app.dy = curr_pos[1] - float(self.cursor_pos[1])
# # update the positions on status bar
# self.app.ui.position_label.setText("&nbsp;&nbsp;&nbsp;&nbsp;<b>X</b>: %.4f&nbsp;&nbsp; "
# "<b>Y</b>: %.4f" % (curr_pos[0], curr_pos[1]))
self.app.ui.position_label.setText("&nbsp;<b>X</b>: %.4f&nbsp;&nbsp; "
"<b>Y</b>: %.4f&nbsp;" % (curr_pos[0], curr_pos[1]))
# self.app.ui.rel_position_label.setText("<b>Dx</b>: %.4f&nbsp;&nbsp; <b>Dy</b>: "
# "%.4f&nbsp;&nbsp;&nbsp;&nbsp;" % (self.app.dx, self.app.dy))

View File

@@ -1731,8 +1731,8 @@ class ToolPaint(FlatCAMTool, Gerber):
self.app.dy = curr_pos[1] - float(self.cursor_pos[1])
# # update the positions on status bar
# self.app.ui.position_label.setText("&nbsp;&nbsp;&nbsp;&nbsp;<b>X</b>: %.4f&nbsp;&nbsp; "
# "<b>Y</b>: %.4f" % (curr_pos[0], curr_pos[1]))
self.app.ui.position_label.setText("&nbsp;<b>X</b>: %.4f&nbsp;&nbsp; "
"<b>Y</b>: %.4f&nbsp;" % (curr_pos[0], curr_pos[1]))
# self.app.ui.rel_position_label.setText("<b>Dx</b>: %.4f&nbsp;&nbsp; <b>Dy</b>: "
# "%.4f&nbsp;&nbsp;&nbsp;&nbsp;" % (self.app.dx, self.app.dy))