Ejemplo n.º 1
0
    def __init__(self,
                 parent,
                 Id=wx.ID_ANY,
                 Title="",
                 pos=wx.DefaultPosition,
                 size=wx.DefaultSize,
                 style=wx.DEFAULT_FRAME_STYLE | wx.SUNKEN_BORDER
                 | wx.STAY_ON_TOP):
        style = style & (~wx.MINIMIZE_BOX)
        wx.Frame.__init__(self, parent, Id, Title, pos, size, style)

        self.fileOperations = FileOperations()
        #         pub.subscribe(self.__OnCellChange, 'OnCellChange')
        self._mgr = aui.AuiManager()

        # tell AuiManager to manage this frame
        self._mgr.SetManagedWindow(self)

        # set frame icon
        icon = wx.Icon()
        icon.CopyFromBitmap(
            self.fileOperations.getImageBitmap(imageName='eclipse16.png'))
        self.SetIcon(icon)

        # set up default notebook style
        #         self._mgr._autoNBStyle = aui.AUI_NB_DEFAULT_STYLE | aui.AUI_NB_TAB_EXTERNAL_MOVE | wx.NO_BORDER
        self._notebook_theme = 0

        self.BuildPanes()
        self.BindEvents()
        self.Show(show=True)
Ejemplo n.º 2
0
    def initFrameManager_(self):
        '''
            init the AUI-Manager and some default window targets
        '''
        self.auiMgr = aui.AuiManager()
        self.auiMgr.SetManagedWindow(self)

        self.auiMgr.AddPane(
            self.createRendererSlot_(self),
            aui.AuiPaneInfo().Name("RenderWindow")
            #                             .BestSize(wx.Size(250, 200)).MinSize(wx.Size(250, 200))
            .CenterPane())

        self.auiMgr.AddPane(
            self.createResourceView_(self),
            aui.AuiPaneInfo().Name("Resources").Caption("Resources").BestSize(
                wx.Size(300, 200)).MinSize(wx.Size(300, 200)).CloseButton(
                    True).MaximizeButton(True).Left().Layer(1).Position(0))

        self.auiMgr.AddPane(
            self.createPropertyInspectorSlot_(self),
            aui.AuiPaneInfo().Name("Properties").Caption(
                "Properties").BestSize(wx.Size(300, 200)).MinSize(
                    wx.Size(300, 200)).CloseButton(True).MaximizeButton(
                        True).Left().Layer(1).Position(1))

        self.auiMgr.AddPane(
            self.createLogPane_(self),
            aui.AuiPaneInfo().Name("Log and More").Caption("Log and More").
            BestSize(wx.Size(800, 150)).MinSize(wx.Size(
                500,
                100)).CloseButton(True).MaximizeButton(True).Bottom().Hide())
Ejemplo n.º 3
0
    def __init__(self):
        wx.Frame.__init__(self, None, title="neural")

        self.aui = aui.AuiManager(self)
        self.aui.SetAGWFlags(self.aui.GetAGWFlags() ^ aui.AUI_MGR_LIVE_RESIZE)
        self.editor = editor = NeuralEditPanel(self)
        self.props = props = NeuralPropertiesPanel(self)
        self.tools = tools = NeuralToolsPanel(self)

        editor.Bind(EVT_SELECTION_CHANGED, props.on_edit_selection_changed)
        editor.Bind(EVT_ELEMENT_ADDED, self.on_element_added)
        editor.Bind(EVT_ELEMENT_REMOVED, self.on_element_removed)
        editor.Bind(EVT_NET_STATE_CHANGED, props.on_state_changed)

        props.Bind(EVT_ELEMENT_RENAMED, editor.on_neuron_renamed)
        props.Bind(EVT_REMOVE_LINK, editor.on_remove_link)
        props.Bind(EVT_REMOVE_LINKS, editor.on_remove_links)

        tools.Bind(EVT_FILE_NEW, editor.on_file_new)
        tools.Bind(EVT_FILE_OPEN, editor.on_file_open)
        tools.Bind(EVT_FILE_SAVE, editor.on_file_save)
        tools.Bind(EVT_SIM_START, editor.on_sim_start)
        tools.Bind(EVT_SIM_STOP, editor.on_sim_stop)
        tools.Bind(EVT_NEURON_TYPE_CHANGED, editor.set_neuron_type)

        tools.Bind(EVT_FILE_NEW, self.on_file_new)
        tools.Bind(EVT_FILE_OPEN, self.on_file_open)
        tools.Bind(EVT_FILE_SAVE, self.on_file_save)

        self.Bind(wx.EVT_CLOSE, self.on_close)

        self.aui.AddPane(
            tools,
            aui.AuiPaneInfo().Top().CaptionVisible(False).Resizable(False))
        self.aui.AddPane(
            props,
            aui.AuiPaneInfo().Left().CloseButton(False).Caption(
                'properties').CaptionVisible(True).MinSize(props.Size))
        self.aui.AddPane(editor,
                         aui.AuiPaneInfo().CenterPane().MinSize(editor.Size))
        self.aui.Update()

        self.Fit()
        self.Show()
Ejemplo n.º 4
0
    def _init_gui(self):
        print('Running ', str(sys.argv))

        self._create_menu()

        self.__mgr = aui.AuiManager()
        self.__mgr.SetManagedWindow(self)
        self.__mgr.SetDockSizeConstraint(0.5, 0.5)

        self._create_toolbar()
        self._create_display_panel()

        self.__mgr.Update()

        self._default_size = (600, 500)
        self._min_size = (350, 350)
        self.SetSize(self._default_size)
        self.SetMinSize(self._min_size)
        self.Center()
        self.Show()
Ejemplo n.º 5
0
    def __init__(self, parent, scatt_mgr, id=wx.ID_ANY):

        scrolled.ScrolledPanel.__init__(self, parent)
        self.SetupScrolling(scroll_x=False, scroll_y=True, scrollToTop=False)

        self.scatt_mgr = scatt_mgr

        self.mainPanel = wx.Panel(parent=self, id=wx.ID_ANY)

        # self._createCategoryPanel()
        # Fancy gui
        self._mgr = aui.AuiManager(self.mainPanel)
        # self._mgr.SetManagedWindow(self)

        self._mgr.Update()

        self._doLayout()
        self.Bind(wx.EVT_SCROLLWIN, self.OnScroll)
        self.Bind(wx.EVT_SCROLL_CHANGED, self.OnScrollChanged)

        self.Bind(aui.EVT_AUI_PANE_CLOSE, self.OnPlotPaneClosed)

        dlgSize = (-1, 400)
        # self.SetBestSize(dlgSize)
        # self.SetInitialSize(dlgSize)
        self.SetAutoLayout(1)
        # fix goutput's pane size (required for Mac OSX)
        # if self.gwindow:
        #    self.gwindow.SetSashPosition(int(self.GetSize()[1] * .75))
        self.ignore_scroll = 0
        self.Bind(wx.EVT_MOUSEWHEEL, self.OnMouseWheel)

        self.scatt_i = 1
        self.scatt_id_scatt_i = {}
        self.transpose = {}
        self.scatts = {}

        self.Bind(wx.EVT_CLOSE, self.OnClose)

        self.scatt_mgr.cursorPlotMove.connect(self.CursorPlotMove)
Ejemplo n.º 6
0
    def __init__(self, parent, id=wx.ID_ANY, Title="", pos=wx.DefaultPosition,
                 size=wx.DefaultSize, style=wx.DEFAULT_FRAME_STYLE | wx.SUNKEN_BORDER, log=None):

        wx.Frame.__init__(self, parent, id, Title, pos, size, style)
        
        self.fileOperations = FileOperations()
        pub.subscribe(self.__OnCellChange, 'OnCellChange')
        self._mgr = aui.AuiManager()

        # tell AuiManager to manage this frame
        self._mgr.SetManagedWindow(self)

        # set frame icon
#         self.SetIcon(self.fileOperations.getImageBitmap(imageName='eclipse16.png'))

        # set up default notebook style
#         self._mgr._autoNBStyle = aui.AUI_NB_DEFAULT_STYLE | aui.AUI_NB_TAB_EXTERNAL_MOVE | wx.NO_BORDER
        self._notebook_theme = 0
        self.createStatusBar()

        self.BuildPanes()
        self.BindEvents()
Ejemplo n.º 7
0
    def __init__(self,
                 parent=None,
                 id=wx.ID_ANY,
                 title="PyDiaGUI",
                 *args,
                 **kwargs):
        super(PyDiaGUI, self).__init__(parent, id, title, *args, **kwargs)

        self.mgr = aui.AuiManager()

        # tell AuiManager to manage this frame
        self.mgr.SetManagedWindow(self)

        self.original_title = self.GetTitle()
        self.log = Log()
        self.session = None  # PyDia
        self.sessionPages = []

        self.SetSize(wx.Size(800, 600))
        self.SetMinSize(wx.Size(400, 300))
        self.Centre()
        self.Show(True)

        # status bar
        self.statusbar = self.CreateStatusBar()

        try:
            self.MakeMenuBar()
            self.MakeToolBar()
            self.MakeShellPane()
            self.MakeSymbolTreePane()
            self.MakeSymbolBook()
            self.BindEvents()

            self.AddWelcomePage()
            self.statusbar.SetStatusText("Ready")
            self.DoUpdate()
        except:
            self.ShowExceptionInDialog()
Ejemplo n.º 8
0
 def __init__(self, parent, title, size=(700, 440)):
     wx.Frame.__init__(self,
                       parent,
                       -1,
                       title,
                       size=size,
                       style=wx.DEFAULT_FRAME_STYLE
                       | wx.NO_FULL_REPAINT_ON_RESIZE)
     self.Center()
     #         self.Bind(wx.EVT_CLOSE, self.OnCloseFrame)
     self.allowAuiFloating = False
     self.SetMinSize((640, 480))
     self.fileOperations = FileOperations()
     icon = wx.Icon()
     icon.CopyFromBitmap(
         self.fileOperations.getImageBitmap(imageName='eclipse16.png'))
     self.SetIcon(icon)
     self._mgr = aui.AuiManager()
     # tell AuiManager to manage this frame
     self._mgr.SetManagedWindow(self)
     self.BuildPanes()
     self.BindEvents()
     self.Show()
Ejemplo n.º 9
0
    def __init__(self,
                 parent,
                 id=-1,
                 title="",
                 pos=wx.DefaultPosition,
                 size=wx.DefaultSize,
                 style=wx.DEFAULT_FRAME_STYLE | wx.SUNKEN_BORDER
                 | wx.CLIP_CHILDREN):

        wx.Frame.__init__(self, parent, id, title, pos, size, style)

        # tell FrameManager to manage this frame
        self._mgr = aui.AuiManager()
        self._mgr.SetManagedWindow(self)

        self._perspectives = []
        self.n = 0
        self.x = 0

        self.SetIcon(GetMondrianIcon())

        # create menu
        mb = wx.MenuBar()

        file_menu = wx.Menu()
        file_menu.Append(wx.ID_EXIT, "Exit")

        view_menu = wx.Menu()
        view_menu.Append(ID_CreateText, "Create Text Control")
        view_menu.Append(ID_CreateHTML, "Create HTML Control")
        view_menu.Append(ID_CreateTree, "Create Tree")
        view_menu.Append(ID_CreateGrid, "Create Grid")
        view_menu.Append(ID_CreateSizeReport, "Create Size Reporter")
        view_menu.AppendSeparator()
        view_menu.Append(ID_GridContent, "Use a Grid for the Content Pane")
        view_menu.Append(ID_TextContent,
                         "Use a Text Control for the Content Pane")
        view_menu.Append(ID_HTMLContent,
                         "Use an HTML Control for the Content Pane")
        view_menu.Append(ID_TreeContent,
                         "Use a Tree Control for the Content Pane")
        view_menu.Append(ID_SizeReportContent,
                         "Use a Size Reporter for the Content Pane")

        options_menu = wx.Menu()
        options_menu.AppendRadioItem(ID_TransparentHint, "Transparent Hint")
        options_menu.AppendRadioItem(ID_VenetianBlindsHint,
                                     "Venetian Blinds Hint")
        options_menu.AppendRadioItem(ID_RectangleHint, "Rectangle Hint")
        options_menu.AppendRadioItem(ID_NoHint, "No Hint")
        options_menu.AppendSeparator()
        options_menu.AppendCheckItem(ID_HintFade, "Hint Fade-in")
        options_menu.AppendCheckItem(ID_AllowFloating, "Allow Floating")
        options_menu.AppendCheckItem(ID_NoVenetianFade,
                                     "Disable Venetian Blinds Hint Fade-in")
        options_menu.AppendCheckItem(ID_TransparentDrag, "Transparent Drag")
        options_menu.AppendCheckItem(ID_AllowActivePane, "Allow Active Pane")
        options_menu.AppendSeparator()
        options_menu.AppendRadioItem(ID_NoGradient, "No Caption Gradient")
        options_menu.AppendRadioItem(ID_VerticalGradient,
                                     "Vertical Caption Gradient")
        options_menu.AppendRadioItem(ID_HorizontalGradient,
                                     "Horizontal Caption Gradient")
        options_menu.AppendSeparator()
        options_menu.Append(ID_Settings, "Settings Pane")

        self._perspectives_menu = wx.Menu()
        self._perspectives_menu.Append(ID_CreatePerspective,
                                       "Create Perspective")
        self._perspectives_menu.Append(ID_CopyPerspective,
                                       "Copy Perspective Data To Clipboard")
        self._perspectives_menu.AppendSeparator()
        self._perspectives_menu.Append(ID_FirstPerspective + 0,
                                       "Default Startup")
        self._perspectives_menu.Append(ID_FirstPerspective + 1, "All Panes")
        self._perspectives_menu.Append(ID_FirstPerspective + 2,
                                       "Vertical Toolbar")

        help_menu = wx.Menu()
        help_menu.Append(ID_About, "About...")

        mb.Append(file_menu, "File")
        mb.Append(view_menu, "View")
        mb.Append(self._perspectives_menu, "Perspectives")
        mb.Append(options_menu, "Options")
        mb.Append(help_menu, "Help")

        self.SetMenuBar(mb)

        self.statusbar = self.CreateStatusBar(2, wx.STB_SIZEGRIP)
        self.statusbar.SetStatusWidths([-2, -3])
        self.statusbar.SetStatusText("Ready", 0)
        self.statusbar.SetStatusText("Welcome To wxPython!", 1)

        # min size for the frame itself isn't completely done.
        # see the end up FrameManager::Update() for the test
        # code. For now, just hard code a frame minimum size
        self.SetMinSize(wx.Size(400, 300))

        # create some toolbars
        tb1 = wx.ToolBar(self, -1, wx.DefaultPosition, wx.DefaultSize,
                         wx.TB_FLAT | wx.TB_NODIVIDER)
        tb1.SetToolBitmapSize(wx.Size(48, 48))
        tb1.AddLabelTool(101, "Test", wx.ArtProvider.GetBitmap(wx.ART_ERROR))
        tb1.AddSeparator()
        tb1.AddLabelTool(102, "Test",
                         wx.ArtProvider.GetBitmap(wx.ART_QUESTION))
        tb1.AddLabelTool(103, "Test",
                         wx.ArtProvider.GetBitmap(wx.ART_INFORMATION))
        tb1.AddLabelTool(103, "Test", wx.ArtProvider.GetBitmap(wx.ART_WARNING))
        tb1.AddLabelTool(103, "Test",
                         wx.ArtProvider.GetBitmap(wx.ART_MISSING_IMAGE))
        tb1.Realize()

        tb2 = wx.ToolBar(self, -1, wx.DefaultPosition, wx.DefaultSize,
                         wx.TB_FLAT | wx.TB_NODIVIDER)
        tb2.SetToolBitmapSize(wx.Size(16, 16))
        tb2_bmp1 = wx.ArtProvider.GetBitmap(wx.ART_QUESTION, wx.ART_OTHER,
                                            wx.Size(16, 16))
        tb2.AddLabelTool(101, "Test", tb2_bmp1)
        tb2.AddLabelTool(101, "Test", tb2_bmp1)
        tb2.AddLabelTool(101, "Test", tb2_bmp1)
        tb2.AddLabelTool(101, "Test", tb2_bmp1)
        tb2.AddSeparator()
        tb2.AddLabelTool(101, "Test", tb2_bmp1)
        tb2.AddLabelTool(101, "Test", tb2_bmp1)
        tb2.AddSeparator()
        tb2.AddLabelTool(101, "Test", tb2_bmp1)
        tb2.AddLabelTool(101, "Test", tb2_bmp1)
        tb2.AddLabelTool(101, "Test", tb2_bmp1)
        tb2.AddLabelTool(101, "Test", tb2_bmp1)
        tb2.Realize()

        tb3 = wx.ToolBar(self, -1, wx.DefaultPosition, wx.DefaultSize,
                         wx.TB_FLAT | wx.TB_NODIVIDER)
        tb3.SetToolBitmapSize(wx.Size(16, 16))
        tb3_bmp1 = wx.ArtProvider.GetBitmap(wx.ART_FOLDER, wx.ART_OTHER,
                                            wx.Size(16, 16))
        tb3.AddLabelTool(101, "Test", tb3_bmp1)
        tb3.AddLabelTool(101, "Test", tb3_bmp1)
        tb3.AddLabelTool(101, "Test", tb3_bmp1)
        tb3.AddLabelTool(101, "Test", tb3_bmp1)
        tb3.AddSeparator()
        tb3.AddLabelTool(101, "Test", tb3_bmp1)
        tb3.AddLabelTool(101, "Test", tb3_bmp1)
        tb3.Realize()

        tb4 = wx.ToolBar(self, -1, wx.DefaultPosition, wx.DefaultSize,
                         wx.TB_FLAT | wx.TB_NODIVIDER | wx.TB_HORZ_TEXT)
        tb4.SetToolBitmapSize(wx.Size(16, 16))
        tb4_bmp1 = wx.ArtProvider.GetBitmap(wx.ART_NORMAL_FILE, wx.ART_OTHER,
                                            wx.Size(16, 16))
        tb4.AddLabelTool(101, "Item 1", tb4_bmp1)
        tb4.AddLabelTool(101, "Item 2", tb4_bmp1)
        tb4.AddLabelTool(101, "Item 3", tb4_bmp1)
        tb4.AddLabelTool(101, "Item 4", tb4_bmp1)
        tb4.AddSeparator()
        tb4.AddLabelTool(101, "Item 5", tb4_bmp1)
        tb4.AddLabelTool(101, "Item 6", tb4_bmp1)
        tb4.AddLabelTool(101, "Item 7", tb4_bmp1)
        tb4.AddLabelTool(101, "Item 8", tb4_bmp1)
        tb4.Realize()

        tb5 = wx.ToolBar(self, -1, wx.DefaultPosition, wx.DefaultSize,
                         wx.TB_FLAT | wx.TB_NODIVIDER | wx.TB_VERTICAL)
        tb5.SetToolBitmapSize(wx.Size(48, 48))
        tb5.AddLabelTool(101, "Test", wx.ArtProvider.GetBitmap(wx.ART_ERROR))
        tb5.AddSeparator()
        tb5.AddLabelTool(102, "Test",
                         wx.ArtProvider.GetBitmap(wx.ART_QUESTION))
        tb5.AddLabelTool(103, "Test",
                         wx.ArtProvider.GetBitmap(wx.ART_INFORMATION))
        tb5.AddLabelTool(103, "Test", wx.ArtProvider.GetBitmap(wx.ART_WARNING))
        tb5.AddLabelTool(103, "Test",
                         wx.ArtProvider.GetBitmap(wx.ART_MISSING_IMAGE))
        tb5.Realize()

        # add a bunch of panes
        self._mgr.AddPane(
            self.CreateSizeReportCtrl(),
            aui.AuiPaneInfo().Name("test1").Caption(
                "Pane Caption").Top().CloseButton(True).MaximizeButton(True))

        self._mgr.AddPane(
            self.CreateSizeReportCtrl(),
            aui.AuiPaneInfo().Name("test2").Caption("Client Size Reporter").
            Bottom().Position(1).CloseButton(True).MaximizeButton(True))

        self._mgr.AddPane(
            self.CreateSizeReportCtrl(),
            aui.AuiPaneInfo().Name("test3").Caption("Client Size Reporter").
            Bottom().CloseButton(True).MaximizeButton(True))

        self._mgr.AddPane(
            self.CreateSizeReportCtrl(),
            aui.AuiPaneInfo().Name("test4").Caption(
                "Pane Caption").Left().CloseButton(True).MaximizeButton(True))

        self._mgr.AddPane(
            self.CreateSizeReportCtrl(),
            aui.AuiPaneInfo().Name("test5").Caption(
                "Pane Caption").Right().CloseButton(True).MaximizeButton(True))

        self._mgr.AddPane(
            self.CreateSizeReportCtrl(),
            aui.AuiPaneInfo().Name("test6").Caption("Client Size Reporter").
            Right().Row(1).CloseButton(True).MaximizeButton(True))

        self._mgr.AddPane(
            self.CreateSizeReportCtrl(),
            aui.AuiPaneInfo().Name("test7").Caption("Client Size Reporter").
            Left().Layer(1).CloseButton(True).MaximizeButton(True))

        self._mgr.AddPane(
            self.CreateTreeCtrl(),
            aui.AuiPaneInfo().Name("test8").Caption("Tree Pane").Left().Layer(
                1).Position(1).CloseButton(True).MaximizeButton(True))

        self._mgr.AddPane(
            self.CreateSizeReportCtrl(),
            aui.AuiPaneInfo().Name("test9").Caption("Min Size 200x100").
            BestSize(wx.Size(200, 100)).MinSize(wx.Size(
                200,
                100)).Bottom().Layer(1).CloseButton(True).MaximizeButton(True))

        self._mgr.AddPane(
            self.CreateTextCtrl(),
            aui.AuiPaneInfo().Name("test10").Caption("Text Pane").Bottom().
            Layer(1).Position(1).CloseButton(True).MaximizeButton(True))

        self._mgr.AddPane(
            self.CreateSizeReportCtrl(),
            aui.AuiPaneInfo().Name("test11").Caption(
                "Fixed Pane").Bottom().Layer(1).Position(
                    2).Fixed().CloseButton(True).MaximizeButton(True))

        self._mgr.AddPane(
            SettingsPanel(self, self),
            aui.AuiPaneInfo().Name("settings").Caption(
                "Dock Manager Settings").Dockable(False).Float().Hide().
            CloseButton(True).MaximizeButton(True))

        # create some center panes

        self._mgr.AddPane(
            self.CreateGrid(),
            aui.AuiPaneInfo().Name("grid_content").CenterPane().Hide())

        self._mgr.AddPane(
            self.CreateTreeCtrl(),
            aui.AuiPaneInfo().Name("tree_content").CenterPane().Hide())

        self._mgr.AddPane(
            self.CreateSizeReportCtrl(),
            aui.AuiPaneInfo().Name("sizereport_content").CenterPane().Hide())

        self._mgr.AddPane(
            self.CreateTextCtrl(),
            aui.AuiPaneInfo().Name("text_content").CenterPane().Hide())

        self._mgr.AddPane(self.CreateHTMLCtrl(),
                          aui.AuiPaneInfo().Name("html_content").CenterPane())

        # add the toolbars to the manager

        self._mgr.AddPane(
            tb1,
            aui.AuiPaneInfo().Name("tb1").Caption("Big Toolbar").ToolbarPane().
            Top().LeftDockable(False).RightDockable(False))

        self._mgr.AddPane(
            tb2,
            aui.AuiPaneInfo().Name("tb2").Caption("Toolbar 2").ToolbarPane().
            Top().Row(1).LeftDockable(False).RightDockable(False))

        self._mgr.AddPane(
            tb3,
            aui.AuiPaneInfo().Name("tb3").Caption("Toolbar 3").ToolbarPane().
            Top().Row(1).Position(1).LeftDockable(False).RightDockable(False))

        self._mgr.AddPane(
            tb4,
            aui.AuiPaneInfo().Name("tb4").Caption(
                "Sample Bookmark Toolbar").ToolbarPane().Top().Row(
                    2).LeftDockable(False).RightDockable(False))

        self._mgr.AddPane(
            tb5,
            aui.AuiPaneInfo().Name("tbvert").Caption(
                "Sample Vertical Toolbar").ToolbarPane().Left().GripperTop().
            TopDockable(False).BottomDockable(False))

        self._mgr.AddPane(
            wx.Button(self, -1, "Test Button"),
            aui.AuiPaneInfo().Name("tb5").ToolbarPane().Top().Row(2).Position(
                1).LeftDockable(False).RightDockable(False))

        # make some default perspectives

        self._mgr.GetPane("tbvert").Hide()

        perspective_all = self._mgr.SavePerspective()

        all_panes = self._mgr.GetAllPanes()

        for ii in range(len(all_panes)):
            if not all_panes[ii].IsToolbar():
                all_panes[ii].Hide()

        self._mgr.GetPane("tb1").Hide()
        self._mgr.GetPane("tb5").Hide()
        self._mgr.GetPane("test8").Show().Left().Layer(0).Row(0).Position(0)
        self._mgr.GetPane("test10").Show().Bottom().Layer(0).Row(0).Position(0)
        self._mgr.GetPane("html_content").Show()

        perspective_default = self._mgr.SavePerspective()

        for ii in range(len(all_panes)):
            if not all_panes[ii].IsToolbar():
                all_panes[ii].Hide()

        self._mgr.GetPane("tb1").Hide()
        self._mgr.GetPane("tb5").Hide()
        self._mgr.GetPane("tbvert").Show()
        self._mgr.GetPane("grid_content").Show()
        self._mgr.GetPane("test8").Show().Left().Layer(0).Row(0).Position(0)
        self._mgr.GetPane("test10").Show().Bottom().Layer(0).Row(0).Position(0)
        self._mgr.GetPane("html_content").Show()

        perspective_vert = self._mgr.SavePerspective()

        self._perspectives.append(perspective_default)
        self._perspectives.append(perspective_all)
        self._perspectives.append(perspective_vert)

        self._mgr.GetPane("tbvert").Hide()
        self._mgr.GetPane("grid_content").Hide()

        # "commit" all changes made to FrameManager
        self._mgr.Update()

        self.Bind(wx.EVT_ERASE_BACKGROUND, self.OnEraseBackground)
        self.Bind(wx.EVT_SIZE, self.OnSize)
        self.Bind(wx.EVT_CLOSE, self.OnClose)

        # Show How To Use The Closing Panes Event
        self.Bind(aui.EVT_AUI_PANE_CLOSE, self.OnPaneClose)

        self.Bind(wx.EVT_MENU, self.OnCreateTree, id=ID_CreateTree)
        self.Bind(wx.EVT_MENU, self.OnCreateGrid, id=ID_CreateGrid)
        self.Bind(wx.EVT_MENU, self.OnCreateText, id=ID_CreateText)
        self.Bind(wx.EVT_MENU, self.OnCreateHTML, id=ID_CreateHTML)
        self.Bind(wx.EVT_MENU, self.OnCreateSizeReport, id=ID_CreateSizeReport)
        self.Bind(wx.EVT_MENU,
                  self.OnCreatePerspective,
                  id=ID_CreatePerspective)
        self.Bind(wx.EVT_MENU, self.OnCopyPerspective, id=ID_CopyPerspective)

        self.Bind(wx.EVT_MENU, self.OnManagerFlag, id=ID_AllowFloating)
        self.Bind(wx.EVT_MENU, self.OnManagerFlag, id=ID_TransparentHint)
        self.Bind(wx.EVT_MENU, self.OnManagerFlag, id=ID_VenetianBlindsHint)
        self.Bind(wx.EVT_MENU, self.OnManagerFlag, id=ID_RectangleHint)
        self.Bind(wx.EVT_MENU, self.OnManagerFlag, id=ID_NoHint)
        self.Bind(wx.EVT_MENU, self.OnManagerFlag, id=ID_HintFade)
        self.Bind(wx.EVT_MENU, self.OnManagerFlag, id=ID_NoVenetianFade)
        self.Bind(wx.EVT_MENU, self.OnManagerFlag, id=ID_TransparentDrag)
        self.Bind(wx.EVT_MENU, self.OnManagerFlag, id=ID_AllowActivePane)

        self.Bind(wx.EVT_MENU, self.OnGradient, id=ID_NoGradient)
        self.Bind(wx.EVT_MENU, self.OnGradient, id=ID_VerticalGradient)
        self.Bind(wx.EVT_MENU, self.OnGradient, id=ID_HorizontalGradient)
        self.Bind(wx.EVT_MENU, self.OnSettings, id=ID_Settings)
        self.Bind(wx.EVT_MENU, self.OnChangeContentPane, id=ID_GridContent)
        self.Bind(wx.EVT_MENU, self.OnChangeContentPane, id=ID_TreeContent)
        self.Bind(wx.EVT_MENU, self.OnChangeContentPane, id=ID_TextContent)
        self.Bind(wx.EVT_MENU,
                  self.OnChangeContentPane,
                  id=ID_SizeReportContent)
        self.Bind(wx.EVT_MENU, self.OnChangeContentPane, id=ID_HTMLContent)
        self.Bind(wx.EVT_MENU, self.OnExit, id=wx.ID_EXIT)
        self.Bind(wx.EVT_MENU, self.OnAbout, id=ID_About)

        self.Bind(wx.EVT_UPDATE_UI, self.OnUpdateUI, id=ID_TransparentHint)
        self.Bind(wx.EVT_UPDATE_UI, self.OnUpdateUI, id=ID_VenetianBlindsHint)
        self.Bind(wx.EVT_UPDATE_UI, self.OnUpdateUI, id=ID_RectangleHint)
        self.Bind(wx.EVT_UPDATE_UI, self.OnUpdateUI, id=ID_NoHint)
        self.Bind(wx.EVT_UPDATE_UI, self.OnUpdateUI, id=ID_HintFade)
        self.Bind(wx.EVT_UPDATE_UI, self.OnUpdateUI, id=ID_AllowFloating)
        self.Bind(wx.EVT_UPDATE_UI, self.OnUpdateUI, id=ID_NoVenetianFade)
        self.Bind(wx.EVT_UPDATE_UI, self.OnUpdateUI, id=ID_TransparentDrag)
        self.Bind(wx.EVT_UPDATE_UI, self.OnUpdateUI, id=ID_AllowActivePane)
        self.Bind(wx.EVT_UPDATE_UI, self.OnUpdateUI, id=ID_NoGradient)
        self.Bind(wx.EVT_UPDATE_UI, self.OnUpdateUI, id=ID_VerticalGradient)
        self.Bind(wx.EVT_UPDATE_UI, self.OnUpdateUI, id=ID_HorizontalGradient)

        self.Bind(wx.EVT_MENU_RANGE,
                  self.OnRestorePerspective,
                  id=ID_FirstPerspective,
                  id2=ID_FirstPerspective + 1000)