# -*- coding: UTF-8 -*-
#
# generated by wxGlade 0.9.9pre on Wed Apr 29 22:07:23 2020
#

import wx

# begin wxGlade: dependencies
# end wxGlade

# begin wxGlade: extracode
import wx.py.shell
import matplotlib_canvas
# end wxGlade


class MyFrame(wx.Frame):
    def __init__(self, *args, **kwds):
        # begin wxGlade: MyFrame.__init__
        kwds["style"] = kwds.get("style", 0) | wx.DEFAULT_FRAME_STYLE
        wx.Frame.__init__(self, *args, **kwds)
        self.SetTitle("Matplotlib canvas example")
        
        # Menu Bar
        self.frame_menubar = wx.MenuBar()
        wxglade_tmp_menu = wx.Menu()
        item = wxglade_tmp_menu.Append(wx.ID_ANY, "&Save figure as...", "")
        self.Bind(wx.EVT_MENU, self.on_file_save, id=item.GetId())
        item = wxglade_tmp_menu.Append(wx.ID_ANY, "E&xit", "")
        self.Bind(wx.EVT_MENU, self.on_file_exit, id=item.GetId())
        self.frame_menubar.Append(wxglade_tmp_menu, "&File")
        self.SetMenuBar(self.frame_menubar)
        # Menu Bar end
        
        sizer_1 = wx.BoxSizer(wx.VERTICAL)
        
        self.canvas = matplotlib_canvas.MatplotlibCanvas(self, wx.ID_ANY)
        self.canvas.SetMinSize((100, 100))
        #self.controller = matplotlib_canvas.NavigationController2(self.canvas)
        sizer_1.Add(self.canvas, 2, wx.ALL | wx.EXPAND, 0)
        
        self.notebook_3 = wx.Notebook(self, wx.ID_ANY)
        sizer_1.Add(self.notebook_3, 1, wx.EXPAND, 0)
        
        self.notebook_3_pane_1 = wx.Panel(self.notebook_3, wx.ID_ANY)
        self.notebook_3.AddPage(self.notebook_3_pane_1, "GUI")
        
        sizer_19 = wx.BoxSizer(wx.VERTICAL)
        
        sizer_13 = wx.StaticBoxSizer(wx.StaticBox(self.notebook_3_pane_1, wx.ID_ANY, "Cursor and Mouse"), wx.HORIZONTAL)
        sizer_19.Add(sizer_13, 0, wx.EXPAND, 0)
        
        label_21 = wx.StaticText(self.notebook_3_pane_1, wx.ID_ANY, "x/y:")
        sizer_13.Add(label_21, 0, wx.ALIGN_CENTER_VERTICAL | wx.ALL, 5)
        
        self.text_cursor_xy_pixel = wx.TextCtrl(self.notebook_3_pane_1, wx.ID_ANY, "px", style=wx.TE_READONLY)
        self.text_cursor_xy_pixel.SetMinSize((40, -1))
        self.text_cursor_xy_pixel.SetToolTip("Last cursor position in pixels on canvas")
        sizer_13.Add(self.text_cursor_xy_pixel, 2, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.text_cursor_xy_value = wx.TextCtrl(self.notebook_3_pane_1, wx.ID_ANY, "", style=wx.TE_READONLY)
        self.text_cursor_xy_value.SetMinSize((40, -1))
        self.text_cursor_xy_value.SetToolTip("Last cursor position in axis values")
        sizer_13.Add(self.text_cursor_xy_value, 2, wx.ALIGN_CENTER_VERTICAL, 0)
        
        sizer_13.Add((20, 20), 1, wx.EXPAND, 0)
        
        label_23 = wx.StaticText(self.notebook_3_pane_1, wx.ID_ANY, "Mouse action:")
        sizer_13.Add(label_23, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 30)
        
        self.choice_mouse_action = wx.Choice(self.notebook_3_pane_1, wx.ID_ANY, choices=["None/Pick", "Pan/Zoom", "Zoom"])
        self.choice_mouse_action.SetToolTip("Pick: click on element to e.g. delete them\nPan/Zoom: pan with left, zoom with right button\nZoom: zoom to rectangle")
        self.choice_mouse_action.SetSelection(0)
        sizer_13.Add(self.choice_mouse_action, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_24 = wx.StaticText(self.notebook_3_pane_1, wx.ID_ANY, "Zoom:")
        label_24.SetToolTip("Zoom history (not yet implemented)")
        sizer_13.Add(label_24, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 30)
        
        self.button_zoom_hist_home = wx.Button(self.notebook_3_pane_1, wx.ID_ANY, "|")
        self.button_zoom_hist_home.SetMinSize((18, -1))
        self.button_zoom_hist_home.SetToolTip("Zoom history: home")
        sizer_13.Add(self.button_zoom_hist_home, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.button_zoom_hist_back = wx.Button(self.notebook_3_pane_1, wx.ID_ANY, "<")
        self.button_zoom_hist_back.SetMinSize((18, -1))
        self.button_zoom_hist_back.SetToolTip("Zoom history: go back")
        self.button_zoom_hist_back.Enable(False)
        sizer_13.Add(self.button_zoom_hist_back, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.button_zoom_hist_forward = wx.Button(self.notebook_3_pane_1, wx.ID_ANY, ">")
        self.button_zoom_hist_forward.SetMinSize((18, -1))
        self.button_zoom_hist_forward.SetToolTip("Zoom history: go forward")
        self.button_zoom_hist_forward.Enable(False)
        sizer_13.Add(self.button_zoom_hist_forward, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.button_autoscale = wx.Button(self.notebook_3_pane_1, wx.ID_ANY, "A")
        self.button_autoscale.SetMinSize((18, -1))
        self.button_autoscale.SetToolTip("auto scale axes")
        sizer_13.Add(self.button_autoscale, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 4)
        
        label_22 = wx.StaticText(self.notebook_3_pane_1, wx.ID_ANY, "Picked:")
        sizer_13.Add(label_22, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 30)
        
        self.text_picked = wx.TextCtrl(self.notebook_3_pane_1, wx.ID_ANY, "", style=wx.TE_READONLY)
        self.text_picked.SetMinSize((60, -1))
        sizer_13.Add(self.text_picked, 4, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.checkbox_pick_delete = wx.CheckBox(self.notebook_3_pane_1, wx.ID_ANY, "Delete on click")
        sizer_13.Add(self.checkbox_pick_delete, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT | wx.RIGHT, 6)
        
        sizer_12 = wx.StaticBoxSizer(wx.StaticBox(self.notebook_3_pane_1, wx.ID_ANY, "Canvas Control"), wx.HORIZONTAL)
        sizer_19.Add(sizer_12, 0, wx.ALL | wx.EXPAND, 3)
        
        label_25 = wx.StaticText(self.notebook_3_pane_1, wx.ID_ANY, "Size:")
        label_25.SetToolTip("Zoom history (not yet implemented)")
        sizer_12.Add(label_25, 0, wx.ALIGN_CENTER_VERTICAL | wx.ALL, 5)
        
        self.choice_canvas_size = wx.Choice(self.notebook_3_pane_1, wx.ID_ANY, choices=["Variable", "400x300", "800x600", "1024x768", "1600x1200"])
        self.choice_canvas_size.SetToolTip("change canvas size")
        self.choice_canvas_size.SetSelection(0)
        sizer_12.Add(self.choice_canvas_size, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_15 = wx.StaticText(self.notebook_3_pane_1, wx.ID_ANY, "Subplots:")
        label_15.SetToolTip("Subplot layout; will only be applied on next Clear")
        sizer_12.Add(label_15, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 30)
        
        self.choice_subplots = wx.Choice(self.notebook_3_pane_1, wx.ID_ANY, choices=["1x1", "1x2", "2x1", "2x2", "2x3"])
        self.choice_subplots.SetToolTip("Subplot layout rows x columns; will only be applied on next Clear\n")
        self.choice_subplots.SetSelection(0)
        sizer_12.Add(self.choice_subplots, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.button_clear_plots = wx.Button(self.notebook_3_pane_1, wx.ID_ANY, "Clear plots")
        sizer_12.Add(self.button_clear_plots, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 30)
        
        self.button_clear_figures = wx.Button(self.notebook_3_pane_1, wx.ID_ANY, "Clear figures")
        self.button_clear_figures.Enable(False)
        sizer_12.Add(self.button_clear_figures, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 8)
        
        self.button_clear_all = wx.Button(self.notebook_3_pane_1, wx.ID_ANY, "Clear all")
        sizer_12.Add(self.button_clear_all, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 8)
        
        sizer_12.Add((20, 20), 1, wx.EXPAND, 0)
        
        self.button_multicursor = wx.ToggleButton(self.notebook_3_pane_1, wx.ID_ANY, "Multicursor")
        self.button_multicursor.SetToolTip("Show synchronized cursor on all plots, if multiple sublplots are enabled/plotted.")
        sizer_12.Add(self.button_multicursor, 0, 0, 0)
        
        sizer_8 = wx.StaticBoxSizer(wx.StaticBox(self.notebook_3_pane_1, wx.ID_ANY, "Add Function Plots"), wx.VERTICAL)
        sizer_19.Add(sizer_8, 0, wx.ALL | wx.EXPAND, 3)
        
        sizer_4 = wx.BoxSizer(wx.HORIZONTAL)
        sizer_8.Add(sizer_4, 0, wx.ALL | wx.EXPAND, 5)
        
        label_4 = wx.StaticText(self.notebook_3_pane_1, wx.ID_ANY, "f(x) = ")
        sizer_4.Add(label_4, 0, wx.ALIGN_CENTER_VERTICAL | wx.ALL, 5)
        
        self.text_function = wx.TextCtrl(self.notebook_3_pane_1, wx.ID_ANY, "sin(x)", style=wx.TE_PROCESS_ENTER)
        sizer_4.Add(self.text_function, 1, 0, 0)
        
        sizer_3 = wx.BoxSizer(wx.HORIZONTAL)
        sizer_8.Add(sizer_3, 0, wx.ALL | wx.EXPAND, 5)
        
        label_1 = wx.StaticText(self.notebook_3_pane_1, wx.ID_ANY, "xmin")
        sizer_3.Add(label_1, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.text_plot_xmin = wx.TextCtrl(self.notebook_3_pane_1, wx.ID_ANY, "0", style=wx.TE_PROCESS_ENTER)
        self.text_plot_xmin.SetMinSize((40, -1))
        sizer_3.Add(self.text_plot_xmin, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_2 = wx.StaticText(self.notebook_3_pane_1, wx.ID_ANY, "xmax")
        sizer_3.Add(label_2, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 0)
        
        self.text_plot_xmax = wx.TextCtrl(self.notebook_3_pane_1, wx.ID_ANY, "10", style=wx.TE_PROCESS_ENTER)
        self.text_plot_xmax.SetMinSize((40, -1))
        sizer_3.Add(self.text_plot_xmax, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_3 = wx.StaticText(self.notebook_3_pane_1, wx.ID_ANY, "step")
        sizer_3.Add(label_3, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_plot_xstep = wx.TextCtrl(self.notebook_3_pane_1, wx.ID_ANY, "0.1", style=wx.TE_PROCESS_ENTER)
        self.text_plot_xstep.SetMinSize((40, -1))
        sizer_3.Add(self.text_plot_xstep, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        sizer_3.Add((20, 20), 1, 0, 0)
        
        label_19 = wx.StaticText(self.notebook_3_pane_1, wx.ID_ANY, "Subplot position:")
        sizer_3.Add(label_19, 0, wx.ALIGN_CENTER_VERTICAL | wx.ALL, 5)
        
        self.choice_subplot = wx.Choice(self.notebook_3_pane_1, wx.ID_ANY, choices=["top left", "top right", "bottom left", "bottom right"])
        self.choice_subplot.SetToolTip("not yet implemented")
        self.choice_subplot.SetSelection(0)
        sizer_3.Add(self.choice_subplot, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.button_plot = wx.Button(self.notebook_3_pane_1, wx.ID_ANY, "Plot")
        self.button_plot.SetDefault()
        sizer_3.Add(self.button_plot, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        sizer_6 = wx.BoxSizer(wx.HORIZONTAL)
        sizer_19.Add(sizer_6, 0, wx.EXPAND, 0)
        
        sizer_14 = wx.StaticBoxSizer(wx.StaticBox(self.notebook_3_pane_1, wx.ID_ANY, "Add Figures (on plot area, by axis coordinates)"), wx.HORIZONTAL)
        sizer_6.Add(sizer_14, 1, wx.ALL, 3)
        
        self.notebook_2 = wx.Notebook(self.notebook_3_pane_1, wx.ID_ANY)
        sizer_14.Add(self.notebook_2, 1, 0, 0)
        
        self.notebook_2_line = wx.Panel(self.notebook_2, wx.ID_ANY)
        self.notebook_2.AddPage(self.notebook_2_line, "Add Line")
        
        sizer_15 = wx.BoxSizer(wx.HORIZONTAL)
        
        label_29 = wx.StaticText(self.notebook_2_line, wx.ID_ANY, "x0")
        sizer_15.Add(label_29, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.text_plot_line_x0 = wx.TextCtrl(self.notebook_2_line, wx.ID_ANY, "3", style=wx.TE_PROCESS_ENTER)
        self.text_plot_line_x0.SetMinSize((40, -1))
        sizer_15.Add(self.text_plot_line_x0, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_31 = wx.StaticText(self.notebook_2_line, wx.ID_ANY, "y0")
        sizer_15.Add(label_31, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_plot_line_y0 = wx.TextCtrl(self.notebook_2_line, wx.ID_ANY, "0", style=wx.TE_PROCESS_ENTER)
        self.text_plot_line_y0.SetMinSize((40, -1))
        sizer_15.Add(self.text_plot_line_y0, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_32 = wx.StaticText(self.notebook_2_line, wx.ID_ANY, "x1")
        sizer_15.Add(label_32, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_plot_line_x1 = wx.TextCtrl(self.notebook_2_line, wx.ID_ANY, "10", style=wx.TE_PROCESS_ENTER)
        self.text_plot_line_x1.SetMinSize((40, -1))
        sizer_15.Add(self.text_plot_line_x1, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_33 = wx.StaticText(self.notebook_2_line, wx.ID_ANY, "y1")
        sizer_15.Add(label_33, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_plot_line_y1 = wx.TextCtrl(self.notebook_2_line, wx.ID_ANY, "2", style=wx.TE_PROCESS_ENTER)
        self.text_plot_line_y1.SetMinSize((40, -1))
        sizer_15.Add(self.text_plot_line_y1, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        sizer_15.Add((20, 20), 1, 0, 0)
        
        self.button_plot_line = wx.Button(self.notebook_2_line, wx.ID_ANY, "Plot Line")
        self.button_plot_line.SetDefault()
        sizer_15.Add(self.button_plot_line, 0, 0, 0)
        
        self.notebook_2_AddRectangle = wx.Panel(self.notebook_2, wx.ID_ANY)
        self.notebook_2.AddPage(self.notebook_2_AddRectangle, "Add Rectangle")
        
        sizer_16 = wx.BoxSizer(wx.HORIZONTAL)
        
        label_35 = wx.StaticText(self.notebook_2_AddRectangle, wx.ID_ANY, "corner x")
        sizer_16.Add(label_35, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.text_plot_rect_x = wx.TextCtrl(self.notebook_2_AddRectangle, wx.ID_ANY, "2", style=wx.TE_PROCESS_ENTER)
        self.text_plot_rect_x.SetMinSize((40, -1))
        sizer_16.Add(self.text_plot_rect_x, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_36 = wx.StaticText(self.notebook_2_AddRectangle, wx.ID_ANY, "y")
        sizer_16.Add(label_36, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_plot_rect_y = wx.TextCtrl(self.notebook_2_AddRectangle, wx.ID_ANY, "0.5", style=wx.TE_PROCESS_ENTER)
        self.text_plot_rect_y.SetMinSize((40, -1))
        sizer_16.Add(self.text_plot_rect_y, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_37 = wx.StaticText(self.notebook_2_AddRectangle, wx.ID_ANY, "width")
        sizer_16.Add(label_37, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_plot_rect_width = wx.TextCtrl(self.notebook_2_AddRectangle, wx.ID_ANY, "3", style=wx.TE_PROCESS_ENTER)
        self.text_plot_rect_width.SetMinSize((40, -1))
        sizer_16.Add(self.text_plot_rect_width, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_38 = wx.StaticText(self.notebook_2_AddRectangle, wx.ID_ANY, "height")
        sizer_16.Add(label_38, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_plot_rect_height = wx.TextCtrl(self.notebook_2_AddRectangle, wx.ID_ANY, "3", style=wx.TE_PROCESS_ENTER)
        self.text_plot_rect_height.SetMinSize((40, -1))
        sizer_16.Add(self.text_plot_rect_height, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_40 = wx.StaticText(self.notebook_2_AddRectangle, wx.ID_ANY, "angle")
        sizer_16.Add(label_40, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_plot_rect_angle = wx.TextCtrl(self.notebook_2_AddRectangle, wx.ID_ANY, "15", style=wx.TE_PROCESS_ENTER)
        self.text_plot_rect_angle.SetMinSize((40, -1))
        sizer_16.Add(self.text_plot_rect_angle, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_41 = wx.StaticText(self.notebook_2_AddRectangle, wx.ID_ANY, u"°")
        sizer_16.Add(label_41, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        sizer_16.Add((20, 20), 1, 0, 0)
        
        self.button_plot_rect = wx.Button(self.notebook_2_AddRectangle, wx.ID_ANY, "Plot Rectangle")
        self.button_plot_rect.SetDefault()
        sizer_16.Add(self.button_plot_rect, 0, 0, 0)
        
        self.notebook_2_circle = wx.Panel(self.notebook_2, wx.ID_ANY)
        self.notebook_2.AddPage(self.notebook_2_circle, "Add Circle")
        
        sizer_17 = wx.BoxSizer(wx.HORIZONTAL)
        
        label_42 = wx.StaticText(self.notebook_2_circle, wx.ID_ANY, "center x")
        sizer_17.Add(label_42, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.text_plot_circle_x = wx.TextCtrl(self.notebook_2_circle, wx.ID_ANY, "5 ", style=wx.TE_PROCESS_ENTER)
        self.text_plot_circle_x.SetMinSize((40, -1))
        sizer_17.Add(self.text_plot_circle_x, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_43 = wx.StaticText(self.notebook_2_circle, wx.ID_ANY, "y")
        sizer_17.Add(label_43, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_plot_circle_y = wx.TextCtrl(self.notebook_2_circle, wx.ID_ANY, "0", style=wx.TE_PROCESS_ENTER)
        self.text_plot_circle_y.SetMinSize((40, -1))
        sizer_17.Add(self.text_plot_circle_y, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_44 = wx.StaticText(self.notebook_2_circle, wx.ID_ANY, "radius")
        sizer_17.Add(label_44, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_plot_circle_radius = wx.TextCtrl(self.notebook_2_circle, wx.ID_ANY, "1", style=wx.TE_PROCESS_ENTER)
        self.text_plot_circle_radius.SetMinSize((40, -1))
        sizer_17.Add(self.text_plot_circle_radius, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        sizer_17.Add((20, 20), 1, 0, 0)
        
        self.button_plot_circle = wx.Button(self.notebook_2_circle, wx.ID_ANY, "Plot Circle")
        self.button_plot_circle.SetDefault()
        sizer_17.Add(self.button_plot_circle, 0, 0, 0)
        
        sizer_9 = wx.StaticBoxSizer(wx.StaticBox(self.notebook_3_pane_1, wx.ID_ANY, "Add Figures (on canvas, by pixels)"), wx.HORIZONTAL)
        sizer_6.Add(sizer_9, 1, wx.ALL, 3)
        
        self.notebook_1 = wx.Notebook(self.notebook_3_pane_1, wx.ID_ANY)
        sizer_9.Add(self.notebook_1, 1, 0, 0)
        
        self.notebook_1_line = wx.Panel(self.notebook_1, wx.ID_ANY)
        self.notebook_1.AddPage(self.notebook_1_line, "Add Line")
        
        sizer_5 = wx.BoxSizer(wx.HORIZONTAL)
        
        label_5 = wx.StaticText(self.notebook_1_line, wx.ID_ANY, "x0")
        sizer_5.Add(label_5, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.text_line_x0 = wx.TextCtrl(self.notebook_1_line, wx.ID_ANY, "10", style=wx.TE_PROCESS_ENTER)
        self.text_line_x0.SetMinSize((40, -1))
        sizer_5.Add(self.text_line_x0, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_6 = wx.StaticText(self.notebook_1_line, wx.ID_ANY, "y0")
        sizer_5.Add(label_6, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_line_y0 = wx.TextCtrl(self.notebook_1_line, wx.ID_ANY, "10", style=wx.TE_PROCESS_ENTER)
        self.text_line_y0.SetMinSize((40, -1))
        sizer_5.Add(self.text_line_y0, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_7 = wx.StaticText(self.notebook_1_line, wx.ID_ANY, "x1")
        sizer_5.Add(label_7, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_line_x1 = wx.TextCtrl(self.notebook_1_line, wx.ID_ANY, "100", style=wx.TE_PROCESS_ENTER)
        self.text_line_x1.SetMinSize((40, -1))
        sizer_5.Add(self.text_line_x1, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_8 = wx.StaticText(self.notebook_1_line, wx.ID_ANY, "y1")
        sizer_5.Add(label_8, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_line_y1 = wx.TextCtrl(self.notebook_1_line, wx.ID_ANY, "100", style=wx.TE_PROCESS_ENTER)
        self.text_line_y1.SetMinSize((40, -1))
        sizer_5.Add(self.text_line_y1, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_9 = wx.StaticText(self.notebook_1_line, wx.ID_ANY, "pixels")
        sizer_5.Add(label_9, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        sizer_5.Add((20, 20), 1, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.button_draw_line = wx.Button(self.notebook_1_line, wx.ID_ANY, "Draw Line")
        self.button_draw_line.SetDefault()
        sizer_5.Add(self.button_draw_line, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.notebook_1_AddRectangle = wx.Panel(self.notebook_1, wx.ID_ANY)
        self.notebook_1.AddPage(self.notebook_1_AddRectangle, "Add Rectangle")
        
        sizer_10 = wx.BoxSizer(wx.HORIZONTAL)
        
        label_10 = wx.StaticText(self.notebook_1_AddRectangle, wx.ID_ANY, "corner x")
        sizer_10.Add(label_10, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.text_rect_x = wx.TextCtrl(self.notebook_1_AddRectangle, wx.ID_ANY, "100", style=wx.TE_PROCESS_ENTER)
        self.text_rect_x.SetMinSize((40, -1))
        sizer_10.Add(self.text_rect_x, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_11 = wx.StaticText(self.notebook_1_AddRectangle, wx.ID_ANY, "y")
        sizer_10.Add(label_11, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_rect_y = wx.TextCtrl(self.notebook_1_AddRectangle, wx.ID_ANY, "10", style=wx.TE_PROCESS_ENTER)
        self.text_rect_y.SetMinSize((40, -1))
        sizer_10.Add(self.text_rect_y, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_12 = wx.StaticText(self.notebook_1_AddRectangle, wx.ID_ANY, "width")
        sizer_10.Add(label_12, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_rect_width = wx.TextCtrl(self.notebook_1_AddRectangle, wx.ID_ANY, "100", style=wx.TE_PROCESS_ENTER)
        self.text_rect_width.SetMinSize((40, -1))
        sizer_10.Add(self.text_rect_width, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_13 = wx.StaticText(self.notebook_1_AddRectangle, wx.ID_ANY, "height")
        sizer_10.Add(label_13, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_rect_height = wx.TextCtrl(self.notebook_1_AddRectangle, wx.ID_ANY, "100", style=wx.TE_PROCESS_ENTER)
        self.text_rect_height.SetMinSize((40, -1))
        sizer_10.Add(self.text_rect_height, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_14 = wx.StaticText(self.notebook_1_AddRectangle, wx.ID_ANY, "pixels")
        sizer_10.Add(label_14, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_16 = wx.StaticText(self.notebook_1_AddRectangle, wx.ID_ANY, "angle")
        sizer_10.Add(label_16, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_rect_angle = wx.TextCtrl(self.notebook_1_AddRectangle, wx.ID_ANY, "0", style=wx.TE_PROCESS_ENTER)
        self.text_rect_angle.SetMinSize((40, -1))
        sizer_10.Add(self.text_rect_angle, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_17 = wx.StaticText(self.notebook_1_AddRectangle, wx.ID_ANY, u"°")
        sizer_10.Add(label_17, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        sizer_10.Add((20, 20), 1, 0, 0)
        
        self.button_draw_rect = wx.Button(self.notebook_1_AddRectangle, wx.ID_ANY, "Draw Rectangle")
        self.button_draw_rect.SetDefault()
        sizer_10.Add(self.button_draw_rect, 0, 0, 0)
        
        self.notebook_1_circle = wx.Panel(self.notebook_1, wx.ID_ANY)
        self.notebook_1.AddPage(self.notebook_1_circle, "Add Circle")
        
        sizer_11 = wx.BoxSizer(wx.HORIZONTAL)
        
        label_26 = wx.StaticText(self.notebook_1_circle, wx.ID_ANY, "center x")
        sizer_11.Add(label_26, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.text_circle_x = wx.TextCtrl(self.notebook_1_circle, wx.ID_ANY, "300", style=wx.TE_PROCESS_ENTER)
        self.text_circle_x.SetMinSize((40, -1))
        sizer_11.Add(self.text_circle_x, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_27 = wx.StaticText(self.notebook_1_circle, wx.ID_ANY, "y")
        sizer_11.Add(label_27, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_circle_y = wx.TextCtrl(self.notebook_1_circle, wx.ID_ANY, "200", style=wx.TE_PROCESS_ENTER)
        self.text_circle_y.SetMinSize((40, -1))
        sizer_11.Add(self.text_circle_y, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_28 = wx.StaticText(self.notebook_1_circle, wx.ID_ANY, "radius")
        sizer_11.Add(label_28, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 5)
        
        self.text_circle_radius = wx.TextCtrl(self.notebook_1_circle, wx.ID_ANY, "10", style=wx.TE_PROCESS_ENTER)
        self.text_circle_radius.SetMinSize((40, -1))
        sizer_11.Add(self.text_circle_radius, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_30 = wx.StaticText(self.notebook_1_circle, wx.ID_ANY, "pixels")
        sizer_11.Add(label_30, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        sizer_11.Add((20, 20), 1, 0, 0)
        
        self.button_draw_circle = wx.Button(self.notebook_1_circle, wx.ID_ANY, "Draw Circle")
        self.button_draw_circle.SetDefault()
        sizer_11.Add(self.button_draw_circle, 0, 0, 0)
        
        sizer_18 = wx.StaticBoxSizer(wx.StaticBox(self.notebook_3_pane_1, wx.ID_ANY, "Colours etc"), wx.HORIZONTAL)
        sizer_19.Add(sizer_18, 0, wx.EXPAND, 0)
        
        label_20 = wx.StaticText(self.notebook_3_pane_1, wx.ID_ANY, "Line colour:")
        sizer_18.Add(label_20, 0, wx.ALIGN_CENTER_VERTICAL | wx.ALL, 5)
        
        self.combo_box_colour = wx.ComboBox(self.notebook_3_pane_1, wx.ID_ANY, choices=["black", "red", "green", "blue", "yellow"], style=wx.CB_DROPDOWN | wx.CB_READONLY)
        self.combo_box_colour.SetToolTip("not yet implemented")
        self.combo_box_colour.SetSelection(0)
        sizer_18.Add(self.combo_box_colour, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_18 = wx.StaticText(self.notebook_3_pane_1, wx.ID_ANY, "Line width:")
        sizer_18.Add(label_18, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 15)
        
        self.combo_box_line_width = wx.ComboBox(self.notebook_3_pane_1, wx.ID_ANY, choices=["0.1", "0.2", "0.5", "1", "2"], style=wx.CB_DROPDOWN | wx.CB_READONLY)
        self.combo_box_line_width.SetMinSize((50, -1))
        self.combo_box_line_width.SetToolTip("not yet implemented")
        self.combo_box_line_width.SetSelection(3)
        sizer_18.Add(self.combo_box_line_width, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        label_46 = wx.StaticText(self.notebook_3_pane_1, wx.ID_ANY, "Line style:")
        sizer_18.Add(label_46, 0, wx.ALIGN_CENTER_VERTICAL | wx.LEFT, 15)
        
        self.choice_line_style = wx.Choice(self.notebook_3_pane_1, wx.ID_ANY, choices=[" -  solid", " -- dashed", " -. dash dot", " :  dotted"])
        self.choice_line_style.SetSelection(0)
        sizer_18.Add(self.choice_line_style, 0, wx.ALIGN_CENTER_VERTICAL, 0)
        
        self.notebook_3_Shell = wx.Panel(self.notebook_3, wx.ID_ANY)
        self.notebook_3.AddPage(self.notebook_3_Shell, "Shell")
        
        sizer_7 = wx.StaticBoxSizer(wx.StaticBox(self.notebook_3_Shell, wx.ID_ANY, "Shell"), wx.VERTICAL)
        
        self.shell = wx.py.shell.Shell(self.notebook_3_Shell, wx.ID_ANY, introText = "\nThis is the shell.\nHave a look at the variables 'app', 'frame', 'canvas' and 'shell'.\n")
        # insert some variables into the shell's locals
        self.shell.interp.locals["frame"]  = self
        self.shell.interp.locals["shell2"] = self.shell
        self.shell.interp.locals["canvas"] = self.canvas
        sizer_7.Add(self.shell, 2, wx.EXPAND, 0)
        
        self.notebook_3_Shell.SetSizer(sizer_7)
        
        self.notebook_1_circle.SetSizer(sizer_11)
        
        self.notebook_1_AddRectangle.SetSizer(sizer_10)
        
        self.notebook_1_line.SetSizer(sizer_5)
        
        self.notebook_2_circle.SetSizer(sizer_17)
        
        self.notebook_2_AddRectangle.SetSizer(sizer_16)
        
        self.notebook_2_line.SetSizer(sizer_15)
        
        self.notebook_3_pane_1.SetSizer(sizer_19)
        
        self.SetSizer(sizer_1)
        sizer_1.Fit(self)
        
        self.Layout()

        self.Bind(wx.EVT_CHOICE, self.on_choice_mouse_action, self.choice_mouse_action)
        self.Bind(wx.EVT_BUTTON, lambda e: self.on_button_zoom_history("home"), self.button_zoom_hist_home)
        self.Bind(wx.EVT_BUTTON, lambda e: self.on_button_zoom_history("back"), self.button_zoom_hist_back)
        self.Bind(wx.EVT_BUTTON, lambda e: self.on_button_zoom_history("forward"), self.button_zoom_hist_forward)
        self.Bind(wx.EVT_BUTTON, self.on_button_autoscale, self.button_autoscale)
        self.Bind(wx.EVT_CHOICE, self.on_choice_canvas_size, self.choice_canvas_size)
        self.Bind(wx.EVT_CHOICE, self.on_choice_subplots, self.choice_subplots)
        self.Bind(wx.EVT_BUTTON, lambda e: self.on_button_clear("plots"), self.button_clear_plots)
        self.Bind(wx.EVT_BUTTON, lambda e: self.on_button_clear("figures"), self.button_clear_figures)
        self.Bind(wx.EVT_BUTTON, lambda e: self.on_button_clear("all"), self.button_clear_all)
        self.Bind(wx.EVT_TOGGLEBUTTON, self.on_button_multicursor, self.button_multicursor)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_plot, self.text_function)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_plot, self.text_plot_xmin)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_plot, self.text_plot_xmax)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_plot, self.text_plot_xstep)
        self.Bind(wx.EVT_CHOICE, self.on_choice_subplot, self.choice_subplot)
        self.Bind(wx.EVT_BUTTON, self.on_button_plot, self.button_plot)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_plot_line, self.text_plot_line_x0)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_plot_line, self.text_plot_line_y0)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_plot_line, self.text_plot_line_x1)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_plot_line, self.text_plot_line_y1)
        self.Bind(wx.EVT_BUTTON, self.on_button_plot_line, self.button_plot_line)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_plot_rect, self.text_plot_rect_x)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_plot_rect, self.text_plot_rect_y)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_plot_rect, self.text_plot_rect_width)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_plot_rect, self.text_plot_rect_height)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_plot_rect, self.text_plot_rect_angle)
        self.Bind(wx.EVT_BUTTON, self.on_button_plot_rect, self.button_plot_rect)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_plot_circle, self.text_plot_circle_x)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_plot_circle, self.text_plot_circle_y)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_plot_circle, self.text_plot_circle_radius)
        self.Bind(wx.EVT_BUTTON, self.on_button_plot_circle, self.button_plot_circle)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_draw_line, self.text_line_x0)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_draw_line, self.text_line_y0)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_draw_line, self.text_line_x1)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_draw_line, self.text_line_y1)
        self.Bind(wx.EVT_BUTTON, self.on_button_draw_line, self.button_draw_line)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_draw_rect, self.text_rect_x)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_draw_rect, self.text_rect_y)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_draw_rect, self.text_rect_width)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_draw_rect, self.text_rect_height)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_draw_rect, self.text_rect_angle)
        self.Bind(wx.EVT_BUTTON, self.on_button_draw_rect, self.button_draw_rect)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_draw_circle, self.text_circle_x)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_draw_circle, self.text_circle_y)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_button_draw_circle, self.text_circle_radius)
        self.Bind(wx.EVT_BUTTON, self.on_button_draw_circle, self.button_draw_circle)
        self.Bind(wx.EVT_COMBOBOX, self.on_combo_colour, self.combo_box_colour)
        self.Bind(wx.EVT_TEXT, self.on_combo_colour, self.combo_box_colour)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_combo_colour, self.combo_box_colour)
        self.Bind(wx.EVT_COMBOBOX, self.on_combo_line_width, self.combo_box_line_width)
        self.Bind(wx.EVT_TEXT, self.on_combo_line_width, self.combo_box_line_width)
        self.Bind(wx.EVT_TEXT_ENTER, self.on_combo_line_width, self.combo_box_line_width)
        self.Bind(wx.EVT_CHOICE, self.on_choice_line_style, self.choice_line_style)
        # end wxGlade

    def on_file_save(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_file_save' not implemented!")
        event.Skip()

    def on_file_exit(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_file_exit' not implemented!")
        event.Skip()

    def on_choice_mouse_action(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_choice_mouse_action' not implemented!")
        event.Skip()

    def on_button_autoscale(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_button_autoscale' not implemented!")
        event.Skip()

    def on_choice_canvas_size(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_choice_canvas_size' not implemented!")
        event.Skip()

    def on_choice_subplots(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_choice_subplots' not implemented!")
        event.Skip()

    def on_button_multicursor(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_button_multicursor' not implemented!")
        event.Skip()

    def on_button_plot(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_button_plot' not implemented!")
        event.Skip()

    def on_choice_subplot(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_choice_subplot' not implemented!")
        event.Skip()

    def on_button_plot_line(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_button_plot_line' not implemented!")
        event.Skip()

    def on_button_plot_rect(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_button_plot_rect' not implemented!")
        event.Skip()

    def on_button_plot_circle(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_button_plot_circle' not implemented!")
        event.Skip()

    def on_button_draw_line(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_button_draw_line' not implemented!")
        event.Skip()

    def on_button_draw_rect(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_button_draw_rect' not implemented!")
        event.Skip()

    def on_button_draw_circle(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_button_draw_circle' not implemented!")
        event.Skip()

    def on_combo_colour(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_combo_colour' not implemented!")
        event.Skip()

    def on_combo_line_width(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_combo_line_width' not implemented!")
        event.Skip()

    def on_choice_line_style(self, event):  # wxGlade: MyFrame.<event_handler>
        print("Event handler 'on_choice_line_style' not implemented!")
        event.Skip()

# end of class MyFrame
