Commit 0e37eee7 authored by Guillaume Seguin's avatar Guillaume Seguin

Add length/speed labels to extrusion controls

parent b0683bb9
......@@ -167,14 +167,15 @@ def add_extra_controls(self, root, parentpanel, extra_buttons = None):
self.Add(ebuttonspanel, pos = (base_line + 2, 0), span = (1, 5), flag = wx.EXPAND)
esettingspanel = root.newPanel(parentpanel)
esettingssizer = wx.BoxSizer(wx.HORIZONTAL)
esettingssizer = wx.GridBagSizer()
root.edist = FloatSpin(esettingspanel, -1, value = root.settings.last_extrusion, min_val = 0, max_val = 1000, size = (70, -1), digits = 1)
root.edist.SetBackgroundColour((225, 200, 200))
root.edist.SetForegroundColour("black")
root.edist.Bind(wx.EVT_SPINCTRL, root.setfeeds)
root.edist.Bind(wx.EVT_TEXT, root.setfeeds)
esettingssizer.Add(root.edist, flag = wx.ALIGN_CENTER | wx.RIGHT, border = 5)
esettingssizer.Add(wx.StaticText(esettingspanel, -1, _("mm @")), flag = wx.ALIGN_CENTER | wx.RIGHT, border = 5)
esettingssizer.Add(root.edist, pos = (1, 0), flag = wx.ALIGN_CENTER | wx.RIGHT, border = 5)
esettingssizer.Add(wx.StaticText(esettingspanel, -1, _("Length:")), pos = (0, 0), flag = wx.ALIGN_LEFT)
esettingssizer.Add(wx.StaticText(esettingspanel, -1, _("mm @")), pos = (1, 1), flag = wx.ALIGN_CENTER | wx.RIGHT, border = 5)
root.edist.SetToolTip(wx.ToolTip(_("Amount to Extrude or Retract (mm)")))
root.efeedc = FloatSpin(esettingspanel, -1, value = root.settings.e_feedrate, min_val = 0, max_val = 50000, size = (70, -1), digits = 1)
root.efeedc.SetToolTip(wx.ToolTip(_("Extrude / Retract speed (mm/min)")))
......@@ -182,8 +183,9 @@ def add_extra_controls(self, root, parentpanel, extra_buttons = None):
root.efeedc.SetForegroundColour("black")
root.efeedc.Bind(wx.EVT_SPINCTRL, root.setfeeds)
root.efeedc.Bind(wx.EVT_TEXT, root.setfeeds)
esettingssizer.Add(root.efeedc, flag = wx.ALIGN_CENTER | wx.RIGHT, border = 5)
esettingssizer.Add(wx.StaticText(esettingspanel, -1, _("mm/\nmin")), flag = wx.ALIGN_CENTER)
esettingssizer.Add(root.efeedc, pos = (1, 2), flag = wx.ALIGN_CENTER | wx.RIGHT, border = 5)
esettingssizer.Add(wx.StaticText(esettingspanel, -1, _("Speed:")), pos = (0, 2), flag = wx.ALIGN_LEFT)
esettingssizer.Add(wx.StaticText(esettingspanel, -1, _("mm/\nmin")), pos = (1, 3), flag = wx.ALIGN_CENTER)
esettingspanel.SetSizer(esettingssizer)
self.Add(esettingspanel, pos = (base_line + 3, 0), span = (1, 5))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment