diff options
| author | Lex Neva <lexelby@users.noreply.github.com> | 2018-09-12 20:49:31 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-09-12 20:49:31 -0400 |
| commit | 3fd741a1a4218b6559184aaadcde8abca178bde2 (patch) | |
| tree | 638a96776f6deecb82150b2b97efb372084e464c /lib/extensions/params.py | |
| parent | eff7c8d8ce7c9c1f8396c99bcf5fc15078ff99b7 (diff) | |
| parent | a876066c75eafc20547b055c5dffe8e89e4c327f (diff) | |
Merge pull request #284 from inkstitch/simulator-timeline
simulator timeline
Diffstat (limited to 'lib/extensions/params.py')
| -rw-r--r-- | lib/extensions/params.py | 15 |
1 files changed, 6 insertions, 9 deletions
diff --git a/lib/extensions/params.py b/lib/extensions/params.py index c464e044..c9c994c9 100644 --- a/lib/extensions/params.py +++ b/lib/extensions/params.py @@ -287,7 +287,6 @@ class ParamsTab(ScrolledPanel): summary_box = wx.StaticBox(self, wx.ID_ANY, label=_("Inkscape objects")) sizer = wx.StaticBoxSizer(summary_box, wx.HORIZONTAL) -# sizer = wx.BoxSizer(wx.HORIZONTAL) self.description = wx.StaticText(self) self.update_description() self.description.SetLabel(self.description_text) @@ -422,7 +421,7 @@ class SettingsFrame(wx.Frame): stitch_plan = patches_to_stitch_plan(patches) if self.simulate_window: self.simulate_window.stop() - self.simulate_window.load(stitch_plan=stitch_plan) + self.simulate_window.load(stitch_plan) else: params_rect = self.GetScreenRect() simulator_pos = params_rect.GetTopRight() @@ -431,20 +430,18 @@ class SettingsFrame(wx.Frame): current_screen = wx.Display.GetFromPoint(wx.GetMousePosition()) display = wx.Display(current_screen) screen_rect = display.GetClientArea() + simulator_pos.y = screen_rect.GetTop() - max_width = screen_rect.GetWidth() - params_rect.GetWidth() - max_height = screen_rect.GetHeight() + width = screen_rect.GetWidth() - params_rect.GetWidth() + height = screen_rect.GetHeight() try: self.simulate_window = EmbroiderySimulator(None, -1, _("Preview"), simulator_pos, - size=(300, 300), - x_position=simulator_pos.x, + size=(width, height), stitch_plan=stitch_plan, on_close=self.simulate_window_closed, - target_duration=5, - max_width=max_width, - max_height=max_height) + target_duration=5) except: error = traceback.format_exc() |
