- small changes in the Geometry UI

This commit is contained in:
Marius Stanciu 2019-12-10 04:14:58 +02:00 committed by Marius
parent b771cbd110
commit cee8c223a8
4 changed files with 50 additions and 17 deletions

View File

@ -7385,8 +7385,7 @@ class App(QtCore.QObject):
self.ui.rel_position_label.setText("<b>Dx</b>: %.4f&nbsp;&nbsp; <b>Dy</b>: "
"%.4f&nbsp;&nbsp;&nbsp;&nbsp;" % (dx, dy))
self.inform.emit('[success] %s' %
_("Done."))
self.inform.emit('[success] %s' % _("Done."))
return location
def on_copy_object(self):

View File

@ -9,6 +9,10 @@ CAD program, and create G-Code for Isolation routing.
=================================================
10.12.2019
- small changes in the Geometry UI
9.12.2019
- updated the border for fit view on OpenGL graphic mode

View File

@ -4602,8 +4602,7 @@ class CNCjob(Geometry):
# For Incremental coordinates type G91
# next_x = pt[0] - prev_x
# next_y = pt[1] - prev_y
self.app.inform.emit('[ERROR_NOTCL] %s' %
_('G91 coordinates not implemented ...'))
self.app.inform.emit('[ERROR_NOTCL] %s' % _('G91 coordinates not implemented ...'))
next_x = pt[0]
next_y = pt[1]

View File

@ -158,6 +158,8 @@ class GerberObjectUI(ObjectUI):
ObjectUI.__init__(self, title=_('Gerber Object'), parent=parent, decimals=decimals)
self.decimals = decimals
self.custom_box.addWidget(QtWidgets.QLabel(''))
# Plot options
grid0 = QtWidgets.QGridLayout()
grid0.setAlignment(QtCore.Qt.AlignLeft | QtCore.Qt.AlignVCenter)
@ -165,10 +167,20 @@ class GerberObjectUI(ObjectUI):
grid0.setColumnStretch(0, 0)
grid0.setColumnStretch(1, 1)
# Plot CB
self.plot_cb = FCCheckBox()
self.plot_cb.setToolTip(
_("Plot (show) this object.")
)
plot_label = QtWidgets.QLabel('<b>%s:</b>' % _("Plot"))
grid0.addWidget(plot_label, 0, 0)
grid0.addWidget(self.plot_cb, 0, 1)
self.plot_options_label = QtWidgets.QLabel("<b>%s:</b>" % _("Plot Options"))
self.plot_options_label.setMinimumWidth(90)
grid0.addWidget(self.plot_options_label, 0, 0)
grid0.addWidget(self.plot_options_label, 1, 0)
# Solid CB
self.solid_cb = FCCheckBox(label=_('Solid'))
@ -176,23 +188,15 @@ class GerberObjectUI(ObjectUI):
_("Solid color polygons.")
)
self.solid_cb.setMinimumWidth(50)
grid0.addWidget(self.solid_cb, 0, 1)
grid0.addWidget(self.solid_cb, 1, 1)
# Multicolored CB
self.multicolored_cb = FCCheckBox(label=_('M-Color'))
self.multicolored_cb = FCCheckBox(label=_('Multi-Color'))
self.multicolored_cb.setToolTip(
_("Draw polygons in different colors.")
)
self.multicolored_cb.setMinimumWidth(55)
grid0.addWidget(self.multicolored_cb, 0, 2)
# Plot CB
self.plot_cb = FCCheckBox(_('Plot'))
self.plot_cb.setToolTip(
_("Plot (show) this object.")
)
self.plot_cb.setMinimumWidth(59)
grid0.addWidget(self.plot_cb, 0, 3)
grid0.addWidget(self.multicolored_cb, 1, 2)
# ## Object name
self.name_hlay = QtWidgets.QHBoxLayout()
@ -264,7 +268,10 @@ class GerberObjectUI(ObjectUI):
# start with apertures table hidden
self.apertures_table.setVisible(False)
self.custom_box.addWidget(QtWidgets.QLabel(''))
separator_line = QtWidgets.QFrame()
separator_line.setFrameShape(QtWidgets.QFrame.HLine)
separator_line.setFrameShadow(QtWidgets.QFrame.Sunken)
self.custom_box.addWidget(separator_line)
# Isolation Routing
self.isolation_routing_label = QtWidgets.QLabel("<b>%s</b>" % _("Isolation Routing"))
@ -552,6 +559,12 @@ class GerberObjectUI(ObjectUI):
_("Create the Geometry Object\n"
"for non-copper routing.")
)
self.generate_ncc_button.setStyleSheet("""
QPushButton
{
font-weight: bold;
}
""")
grid2.addWidget(self.clearcopper_label, 1, 0)
grid2.addWidget(self.generate_ncc_button, 1, 1)
@ -568,6 +581,12 @@ class GerberObjectUI(ObjectUI):
_("Generate the geometry for\n"
"the board cutout.")
)
self.generate_cutout_button.setStyleSheet("""
QPushButton
{
font-weight: bold;
}
""")
grid2.addWidget(self.board_cutout_label, 2, 0)
grid2.addWidget(self.generate_cutout_button, 2, 1)
@ -1617,6 +1636,12 @@ class GeometryObjectUI(ObjectUI):
self.generate_cnc_button.setToolTip(
_("Generate the CNC Job object.")
)
self.generate_cnc_button.setStyleSheet("""
QPushButton
{
font-weight: bold;
}
""")
self.geo_param_box.addWidget(self.generate_cnc_button)
# ##############
@ -1638,6 +1663,12 @@ class GeometryObjectUI(ObjectUI):
self.paint_tool_button.setToolTip(
_("Launch Paint Tool in Tools Tab.")
)
self.paint_tool_button.setStyleSheet("""
QPushButton
{
font-weight: bold;
}
""")
self.geo_tools_box.addWidget(self.paint_tool_button)