- prepared the application for usage of dark icons in case of using the dark theme

- updated the languages
- RELEASE 8.99
This commit is contained in:
Marius Stanciu
2019-12-15 16:28:36 +02:00
committed by Marius
parent ca4c7b245f
commit 8361ee7897
34 changed files with 18341 additions and 18387 deletions

View File

@@ -65,7 +65,7 @@ class FCDrillAdd(FCShapeTool):
QtGui.QGuiApplication.restoreOverrideCursor()
except Exception:
pass
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_drill.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.draw_app.app.resource_location + '/aero_drill.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
geo = self.utility_geometry(data=(self.draw_app.snap_x, self.draw_app.snap_y))
@@ -171,7 +171,7 @@ class FCDrillArray(FCShapeTool):
except Exception as e:
pass
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_drill_array.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.draw_app.app.resource_location + '/aero_drill_array.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
geo = self.utility_geometry(data=(self.draw_app.snap_x, self.draw_app.snap_y), static=True)
@@ -376,7 +376,7 @@ class FCSlot(FCShapeTool):
QtGui.QGuiApplication.restoreOverrideCursor()
except Exception as e:
pass
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_slot.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.draw_app.app.resource_location + '/aero_slot.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
self.steps_per_circ = self.draw_app.app.defaults["geometry_circle_steps"]
@@ -566,7 +566,7 @@ class FCSlotArray(FCShapeTool):
QtGui.QGuiApplication.restoreOverrideCursor()
except Exception as e:
pass
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_array.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.draw_app.app.resource_location + '/aero_array.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
self.steps_per_circ = self.draw_app.app.defaults["geometry_circle_steps"]
@@ -1471,7 +1471,7 @@ class FlatCAMExcEditor(QtCore.QObject):
self.tools_box.addLayout(self.title_box)
# ## Page Title icon
pixmap = QtGui.QPixmap('share/flatcam_icon32.png')
pixmap = QtGui.QPixmap(self.app.resource_location + '/flatcam_icon32.png')
self.icon = QtWidgets.QLabel()
self.icon.setPixmap(pixmap)
self.title_box.addWidget(self.icon, stretch=0)

View File

@@ -304,12 +304,12 @@ class TextInputTool(FlatCAMTool):
self.font_bold_tb = QtWidgets.QToolButton()
self.font_bold_tb.setCheckable(True)
self.font_bold_tb.setIcon(QtGui.QIcon('share/bold32.png'))
self.font_bold_tb.setIcon(QtGui.QIcon(self.app.resource_location + '/bold32.png'))
hlay.addWidget(self.font_bold_tb)
self.font_italic_tb = QtWidgets.QToolButton()
self.font_italic_tb.setCheckable(True)
self.font_italic_tb.setIcon(QtGui.QIcon('share/italic32.png'))
self.font_italic_tb.setIcon(QtGui.QIcon(self.app.resource_location + '/italic32.png'))
hlay.addWidget(self.font_italic_tb)
self.form_layout.addRow(QtWidgets.QLabel('%s:' % "Size"), hlay)
@@ -1495,7 +1495,7 @@ class TransformEditorTool(FlatCAMTool):
text='%s:' % _('Enter an Angle Value (degrees)'),
min=-359.9999, max=360.0000, decimals=self.decimals,
init_val=float(self.app.defaults['tools_transform_rotate']))
val_box.setWindowIcon(QtGui.QIcon('share/rotate.png'))
val_box.setWindowIcon(QtGui.QIcon(self.app.resource_location + '/rotate.png'))
val, ok = val_box.get_value()
if ok:
@@ -1514,7 +1514,7 @@ class TransformEditorTool(FlatCAMTool):
text='%s: (%s)' % (_('Enter a distance Value'), str(units)),
min=-9999.9999, max=10000.0000, decimals=self.decimals,
init_val=float(self.app.defaults['tools_transform_offset_x']))
val_box.setWindowIcon(QtGui.QIcon('share/offsetx32.png'))
val_box.setWindowIcon(QtGui.QIcon(self.app.resource_location + '/offsetx32.png'))
val, ok = val_box.get_value()
if ok:
@@ -1533,7 +1533,7 @@ class TransformEditorTool(FlatCAMTool):
text='%s: (%s)' % (_('Enter a distance Value'), str(units)),
min=-9999.9999, max=10000.0000, decimals=self.decimals,
init_val=float(self.app.defaults['tools_transform_offset_y']))
val_box.setWindowIcon(QtGui.QIcon('share/offsety32.png'))
val_box.setWindowIcon(QtGui.QIcon(self.app.resource_location + '/offsety32.png'))
val, ok = val_box.get_value()
if ok:
@@ -1550,7 +1550,7 @@ class TransformEditorTool(FlatCAMTool):
text='%s:' % _('Enter an Angle Value (degrees)'),
min=-359.9999, max=360.0000, decimals=self.decimals,
init_val=float(self.app.defaults['tools_transform_skew_x']))
val_box.setWindowIcon(QtGui.QIcon('share/skewX.png'))
val_box.setWindowIcon(QtGui.QIcon(self.app.resource_location + '/skewX.png'))
val, ok = val_box.get_value()
if ok:
@@ -1567,7 +1567,7 @@ class TransformEditorTool(FlatCAMTool):
text='%s:' % _('Enter an Angle Value (degrees)'),
min=-359.9999, max=360.0000, decimals=self.decimals,
init_val=float(self.app.defaults['tools_transform_skew_y']))
val_box.setWindowIcon(QtGui.QIcon('share/skewY.png'))
val_box.setWindowIcon(QtGui.QIcon(self.app.resource_location + '/skewY.png'))
val, ok = val_box.get_value()
if ok:
@@ -1938,7 +1938,7 @@ class FCCircle(FCShapeTool):
QtGui.QGuiApplication.restoreOverrideCursor()
except Exception:
pass
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_circle_geo.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.app.resource_location + '/aero_circle_geo.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
self.draw_app.app.inform.emit(_("Click on Center point ..."))
@@ -1990,7 +1990,7 @@ class FCArc(FCShapeTool):
QtGui.QGuiApplication.restoreOverrideCursor()
except Exception:
pass
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_arc.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.app.resource_location + '/aero_arc.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
self.draw_app.app.inform.emit(_("Click on Center point ..."))
@@ -2209,7 +2209,7 @@ class FCRectangle(FCShapeTool):
QtGui.QGuiApplication.restoreOverrideCursor()
except Exception:
pass
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.app.resource_location + '/aero.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
self.draw_app.app.inform.emit(_("Click on 1st corner ..."))
@@ -2263,7 +2263,7 @@ class FCPolygon(FCShapeTool):
QtGui.QGuiApplication.restoreOverrideCursor()
except Exception:
pass
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.app.resource_location + '/aero.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
self.draw_app.app.inform.emit(_("Click on 1st corner ..."))
@@ -2326,7 +2326,7 @@ class FCPath(FCPolygon):
QtGui.QGuiApplication.restoreOverrideCursor()
except Exception:
pass
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_path5.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.app.resource_location + '/aero_path5.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
def make(self):
@@ -2686,7 +2686,7 @@ class FCText(FCShapeTool):
QtGui.QGuiApplication.restoreOverrideCursor()
except Exception:
pass
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_text.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.app.resource_location + '/aero_text.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
# self.shape_buffer = self.draw_app.shape_buffer

View File

@@ -199,7 +199,7 @@ class FCPad(FCShapeTool):
QtGui.QGuiApplication.restoreOverrideCursor()
except Exception as e:
pass
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_circle.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.app.resource_location + '/aero_circle.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
try:
@@ -417,7 +417,7 @@ class FCPadArray(FCShapeTool):
QtGui.QGuiApplication.restoreOverrideCursor()
except Exception as e:
pass
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_array.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.app.resource_location + '/aero_array.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
self.storage_obj = self.draw_app.storage_dict[self.draw_app.last_aperture_selected]['geometry']
@@ -874,7 +874,7 @@ class FCRegion(FCShapeTool):
except Exception as e:
log.debug("FlatCAMGrbEditor.FCRegion --> %s" % str(e))
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.app.resource_location + '/aero.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
self.draw_app.app.inform.emit(_('Corner Mode 1: 45 degrees ...'))
@@ -1148,7 +1148,7 @@ class FCTrack(FCRegion):
except Exception as e:
log.debug("FlatCAMGrbEditor.FCTrack.__init__() --> %s" % str(e))
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_path%s.png' % self.draw_app.bend_mode))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.app.resource_location + '/aero_path%s.png' % self.draw_app.bend_mode))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
self.draw_app.app.inform.emit(_('Track Mode 1: 45 degrees ...'))
@@ -1295,27 +1295,27 @@ class FCTrack(FCRegion):
if self.draw_app.bend_mode == 1:
self.draw_app.bend_mode = 2
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_path2.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.draw_app.app.resource_location + '/aero_path2.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
msg = _('Track Mode 2: Reverse 45 degrees ...')
elif self.draw_app.bend_mode == 2:
self.draw_app.bend_mode = 3
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_path3.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.draw_app.app.resource_location + '/aero_path3.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
msg = _('Track Mode 3: 90 degrees ...')
elif self.draw_app.bend_mode == 3:
self.draw_app.bend_mode = 4
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_path4.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.draw_app.app.resource_location + '/aero_path4.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
msg = _('Track Mode 4: Reverse 90 degrees ...')
elif self.draw_app.bend_mode == 4:
self.draw_app.bend_mode = 5
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_path5.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.draw_app.app.resource_location + '/aero_path5.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
msg = _('Track Mode 5: Free angle ...')
else:
self.draw_app.bend_mode = 1
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_path1.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.draw_app.app.resource_location + '/aero_path1.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
msg = _('Track Mode 1: 45 degrees ...')
@@ -1334,27 +1334,27 @@ class FCTrack(FCRegion):
if self.draw_app.bend_mode == 1:
self.draw_app.bend_mode = 5
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_path5.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.draw_app.app.resource_location + '/aero_path5.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
msg = _('Track Mode 5: Free angle ...')
elif self.draw_app.bend_mode == 5:
self.draw_app.bend_mode = 4
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_path4.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.draw_app.app.resource_location + '/aero_path4.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
msg = _('Track Mode 4: Reverse 90 degrees ...')
elif self.draw_app.bend_mode == 4:
self.draw_app.bend_mode = 3
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_path3.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.draw_app.app.resource_location + '/aero_path3.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
msg = _('Track Mode 3: 90 degrees ...')
elif self.draw_app.bend_mode == 3:
self.draw_app.bend_mode = 2
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_path2.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.draw_app.app.resource_location + '/aero_path2.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
msg = _('Track Mode 2: Reverse 45 degrees ...')
else:
self.draw_app.bend_mode = 1
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_path1.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.draw_app.app.resource_location + '/aero_path1.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
msg = _('Track Mode 1: 45 degrees ...')
@@ -1379,7 +1379,7 @@ class FCDisc(FCShapeTool):
QtGui.QGuiApplication.restoreOverrideCursor()
except Exception as e:
pass
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_disc.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.draw_app.app.resource_location + '/aero_disc.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
size_ap = float(self.draw_app.storage_dict[self.draw_app.last_aperture_selected]['size'])
@@ -1461,7 +1461,7 @@ class FCSemiDisc(FCShapeTool):
except Exception as e:
log.debug("FlatCAMGrbEditor.FCSemiDisc --> %s" % str(e))
self.cursor = QtGui.QCursor(QtGui.QPixmap('share/aero_semidisc.png'))
self.cursor = QtGui.QCursor(QtGui.QPixmap(self.draw_app.app.resource_location + '/aero_semidisc.png'))
QtGui.QGuiApplication.setOverrideCursor(self.cursor)
self.draw_app.app.inform.emit(_("Click on Center point ..."))
@@ -2367,7 +2367,7 @@ class FlatCAMGrbEditor(QtCore.QObject):
layout.addLayout(self.title_box)
# Page Title icon
pixmap = QtGui.QPixmap('share/flatcam_icon32.png')
pixmap = QtGui.QPixmap(self.app.resource_location + '/flatcam_icon32.png')
self.icon = QtWidgets.QLabel()
self.icon.setPixmap(pixmap)
self.title_box.addWidget(self.icon, stretch=0)
@@ -5949,7 +5949,7 @@ class TransformEditorTool(FlatCAMTool):
text='%s:' % _('Enter an Angle Value (degrees)'),
min=-359.9999, max=360.0000, decimals=self.decimals,
init_val=float(self.app.defaults['tools_transform_rotate']))
val_box.setWindowIcon(QtGui.QIcon('share/rotate.png'))
val_box.setWindowIcon(QtGui.QIcon(self.app.resource_location + '/rotate.png'))
val, ok = val_box.get_value()
if ok:
@@ -5966,7 +5966,7 @@ class TransformEditorTool(FlatCAMTool):
text='%s: (%s)' % (_('Enter a distance Value'), str(units)),
min=-9999.9999, max=10000.0000, decimals=self.decimals,
init_val=float(self.app.defaults['tools_transform_offset_x']))
val_box.setWindowIcon(QtGui.QIcon('share/offsetx32.png'))
val_box.setWindowIcon(QtGui.QIcon(self.app.resource_location + '/offsetx32.png'))
val, ok = val_box.get_value()
if ok:
@@ -5983,7 +5983,7 @@ class TransformEditorTool(FlatCAMTool):
text='%s: (%s)' % (_('Enter a distance Value'), str(units)),
min=-9999.9999, max=10000.0000, decimals=self.decimals,
init_val=float(self.app.defaults['tools_transform_offset_y']))
val_box.setWindowIcon(QtGui.QIcon('share/offsety32.png'))
val_box.setWindowIcon(QtGui.QIcon(self.app.resource_location + '/offsety32.png'))
val, ok = val_box.get_value()
if ok:
@@ -5998,7 +5998,7 @@ class TransformEditorTool(FlatCAMTool):
text='%s:' % _('Enter an Angle Value (degrees)'),
min=-359.9999, max=360.0000, decimals=self.decimals,
init_val=float(self.app.defaults['tools_transform_skew_x']))
val_box.setWindowIcon(QtGui.QIcon('share/skewX.png'))
val_box.setWindowIcon(QtGui.QIcon(self.app.resource_location + '/skewX.png'))
val, ok = val_box.get_value()
if ok:
@@ -6013,7 +6013,7 @@ class TransformEditorTool(FlatCAMTool):
text='%s:' % _('Enter an Angle Value (degrees)'),
min=-359.9999, max=360.0000, decimals=self.decimals,
init_val=float(self.app.defaults['tools_transform_skew_y']))
val_box.setWindowIcon(QtGui.QIcon('share/skewY.png'))
val_box.setWindowIcon(QtGui.QIcon(self.app.resource_location + '/skewY.png'))
val, ok = val_box.get_value()
if ok: