diff options
| author | Kaalleen <36401965+kaalleen@users.noreply.github.com> | 2023-09-08 17:03:33 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-09-08 17:03:33 +0200 |
| commit | 427dac519bb9ceadf03012ccca44c012b7990b36 (patch) | |
| tree | ea674e9372b1597db0508696cfc40fdcb0852484 | |
| parent | 577823e276040d4f71810f7f8fc173225dbc4e74 (diff) | |
Fix Param Simulator (win/mac) (#2507)
* add pause icon
* fix params simulator for mac
| -rw-r--r--[l---------] | icons/pause.png | bin | 8 -> 2447 bytes | |||
| -rw-r--r-- | icons/pause.svg | 56 | ||||
| -rw-r--r-- | lib/gui/simulator.py | 18 |
3 files changed, 65 insertions, 9 deletions
diff --git a/icons/pause.png b/icons/pause.png Binary files differindex 6222e6f7..39b55f3b 120000..100644 --- a/icons/pause.png +++ b/icons/pause.png diff --git a/icons/pause.svg b/icons/pause.svg new file mode 100644 index 00000000..eec61f24 --- /dev/null +++ b/icons/pause.svg @@ -0,0 +1,56 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<!-- Created with Inkscape (http://www.inkscape.org/) --> + +<svg + width="256" + height="256" + viewBox="0 0 256 256" + id="svg8375" + version="1.1" + inkscape:version="1.3 (0e150ed6c4, 2023-07-21)" + sodipodi:docname="pause.svg" + xml:space="preserve" + inkscape:export-filename="pause.png" + inkscape:export-xdpi="96" + inkscape:export-ydpi="96" + xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape" + xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd" + xmlns="http://www.w3.org/2000/svg" + xmlns:svg="http://www.w3.org/2000/svg" + xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" + xmlns:cc="http://creativecommons.org/ns#" + xmlns:dc="http://purl.org/dc/elements/1.1/"><defs + id="defs8377" /><sodipodi:namedview + id="base" + pagecolor="#ffffff" + bordercolor="#666666" + borderopacity="1.0" + inkscape:pageopacity="0.0" + inkscape:pageshadow="2" + inkscape:zoom="1.3991985" + inkscape:cx="133.29059" + inkscape:cy="120.42609" + inkscape:document-units="px" + inkscape:current-layer="layer1" + showgrid="false" + units="mm" + inkscape:window-width="1920" + inkscape:window-height="1011" + inkscape:window-x="0" + inkscape:window-y="32" + inkscape:window-maximized="1" + inkscape:showpageshadow="2" + inkscape:pagecheckerboard="0" + inkscape:deskcolor="#d1d1d1" /><metadata + id="metadata8380"><rdf:RDF><cc:Work + rdf:about=""><dc:format>image/svg+xml</dc:format><dc:type + rdf:resource="http://purl.org/dc/dcmitype/StillImage" /></cc:Work></rdf:RDF></metadata><g + inkscape:label="Layer 1" + inkscape:groupmode="layer" + id="layer1"><path + id="path1" + style="opacity:1;fill:#000000;fill-opacity:0.97692001;fill-rule:evenodd;stroke:none;stroke-width:0.377953;stroke-linecap:round;stroke-linejoin:round;stroke-opacity:1" + d="m 75.675755,39.52655 h 19.06887 c 11.080005,0 20.000005,8.92 20.000005,20 v 139.35948 c 0,11.08 -8.92,20 -20.000005,20 h -19.06887 c -11.08,0 -20,-8.92 -20,-20 V 59.52655 c 0,-11.08 8.92,-20 20,-20 z" /><path + id="path2" + style="opacity:1;fill:#000000;fill-opacity:0.97692001;fill-rule:evenodd;stroke:none;stroke-width:0.377953;stroke-linecap:round;stroke-linejoin:round;stroke-opacity:1" + d="m 165.10513,39.52655 h 19.06888 c 11.08,0 20,8.92 20,20 v 139.35948 c 0,11.08 -8.92,20 -20,20 h -19.06888 c -11.08,0 -20,-8.92 -20,-20 V 59.52655 c 0,-11.08 8.92,-20 20,-20 z" /></g></svg> diff --git a/lib/gui/simulator.py b/lib/gui/simulator.py index 963acd45..e1357432 100644 --- a/lib/gui/simulator.py +++ b/lib/gui/simulator.py @@ -76,20 +76,20 @@ class ControlPanel(wx.Panel): self.btnForwardCommand.Bind(wx.EVT_BUTTON, self.animation_one_command_forward) self.btnForwardCommand.SetBitmap(self.load_icon('forward_command')) self.btnForwardCommand.SetToolTip(_('Go forward one command (page-up)')) - self.btnForward = wx.ToggleButton(self, -1, style=self.button_style) + self.btnForward = wx.BitmapToggleButton(self, -1, style=self.button_style) self.btnForward.SetValue(True) self.btnForward.Bind(wx.EVT_TOGGLEBUTTON, self.on_forward_button) self.btnForward.SetBitmap(self.load_icon('forward')) self.btnForward.SetToolTip(_('Animate forward (arrow right)')) - self.btnReverse = wx.ToggleButton(self, -1, style=self.button_style) + self.btnReverse = wx.BitmapToggleButton(self, -1, style=self.button_style) self.btnReverse.Bind(wx.EVT_TOGGLEBUTTON, self.on_reverse_button) self.btnReverse.SetBitmap(self.load_icon('reverse')) self.btnReverse.SetToolTip(_('Animate in reverse (arrow right)')) - self.btnPlay = wx.ToggleButton(self, -1, style=self.button_style) + self.btnPlay = wx.BitmapToggleButton(self, -1, style=self.button_style) self.btnPlay.Bind(wx.EVT_TOGGLEBUTTON, self.on_play_button) self.btnPlay.SetBitmap(self.load_icon('play')) self.btnPlay.SetToolTip(_('Play (P)')) - self.btnPause = wx.ToggleButton(self, -1, style=self.button_style) + self.btnPause = wx.BitmapToggleButton(self, -1, style=self.button_style) self.btnPause.Bind(wx.EVT_TOGGLEBUTTON, self.on_pause_button) self.btnPause.SetBitmap(self.load_icon('pause')) self.btnPause.SetToolTip(_('Pause (P)')) @@ -97,7 +97,7 @@ class ControlPanel(wx.Panel): self.btnRestart.Bind(wx.EVT_BUTTON, self.animation_restart) self.btnRestart.SetBitmap(self.load_icon('restart')) self.btnRestart.SetToolTip(_('Restart (R)')) - self.btnNpp = wx.ToggleButton(self, -1, style=self.button_style) + self.btnNpp = wx.BitmapToggleButton(self, -1, style=self.button_style) self.btnNpp.Bind(wx.EVT_TOGGLEBUTTON, self.toggle_npp) self.btnNpp.SetBitmap(self.load_icon('npp')) self.btnNpp.SetToolTip(_('Display needle penetration point (O)')) @@ -109,19 +109,19 @@ class ControlPanel(wx.Panel): self.stitchBox.Bind(wx.EVT_TEXT_ENTER, self.on_stitch_box_focusout) self.stitchBox.Bind(wx.EVT_KILL_FOCUS, self.on_stitch_box_focusout) self.Bind(wx.EVT_LEFT_DOWN, self.on_stitch_box_focusout) - self.btnJump = wx.ToggleButton(self, -1, style=self.button_style) + self.btnJump = wx.BitmapToggleButton(self, -1, style=self.button_style) self.btnJump.SetToolTip(_('Show jump stitches')) self.btnJump.SetBitmap(self.load_icon('jump')) self.btnJump.Bind(wx.EVT_TOGGLEBUTTON, lambda event: self.on_marker_button('jump', event)) - self.btnTrim = wx.ToggleButton(self, -1, style=self.button_style) + self.btnTrim = wx.BitmapToggleButton(self, -1, style=self.button_style) self.btnTrim.SetToolTip(_('Show trims')) self.btnTrim.SetBitmap(self.load_icon('trim')) self.btnTrim.Bind(wx.EVT_TOGGLEBUTTON, lambda event: self.on_marker_button('trim', event)) - self.btnStop = wx.ToggleButton(self, -1, style=self.button_style) + self.btnStop = wx.BitmapToggleButton(self, -1, style=self.button_style) self.btnStop.SetToolTip(_('Show stops')) self.btnStop.SetBitmap(self.load_icon('stop')) self.btnStop.Bind(wx.EVT_TOGGLEBUTTON, lambda event: self.on_marker_button('stop', event)) - self.btnColorChange = wx.ToggleButton(self, -1, style=self.button_style) + self.btnColorChange = wx.BitmapToggleButton(self, -1, style=self.button_style) self.btnColorChange.SetToolTip(_('Show color changes')) self.btnColorChange.SetBitmap(self.load_icon('color_change')) self.btnColorChange.Bind(wx.EVT_TOGGLEBUTTON, lambda event: self.on_marker_button('color_change', event)) |
