Changeset 8fa53f7 in sasview
- Timestamp:
- Nov 9, 2016 3:11:54 AM (8 years ago)
- Branches:
- master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
- Children:
- cb1e9a5
- Parents:
- 94f0873f
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/sas/sasgui/guiframe/data_panel.py
rc8e1996 r8fa53f7 520 520 Add a listcrtl in the panel 521 521 """ 522 tree_ctrl_label = wx.StaticText(self, -1, "Data") 523 tree_ctrl_label.SetForegroundColour('blue') 524 self.tree_ctrl = DataTreeCtrl(parent=self, style=wx.SUNKEN_BORDER) 522 # Add splitter 523 w, h = self.parent.GetSize() 524 splitter = wx.SplitterWindow(self) 525 splitter.SetMinimumPaneSize(50) 526 splitter.SetSashGravity(1.0) 527 528 file_panel = wx.Panel(splitter, -1) 529 theory_panel = wx.Panel(splitter, -1) 530 531 file_sizer = wx.BoxSizer(wx.VERTICAL) 532 file_sizer.SetMinSize(wx.Size(w/13, h*2/5)) 533 theory_sizer = wx.BoxSizer(wx.VERTICAL) 534 theory_sizer.SetMinSize(wx.Size(w/13, h*2/5)) 535 536 self.tree_ctrl = DataTreeCtrl(parent=splitter, style=wx.SUNKEN_BORDER) 537 525 538 self.tree_ctrl.Bind(CT.EVT_TREE_ITEM_CHECKING, self.on_check_item) 526 539 self.tree_ctrl.Bind(CT.EVT_TREE_ITEM_MENU, self.on_right_click_data) … … 557 570 wx.EVT_MENU(self, self.editmask_id, self.on_edit_data) 558 571 559 tree_ctrl_theory_label = wx.StaticText(self, -1, "Theory") 560 tree_ctrl_theory_label.SetForegroundColour('blue') 561 self.tree_ctrl_theory = DataTreeCtrl(parent=self, 572 self.tree_ctrl_theory = DataTreeCtrl(parent=splitter, 562 573 style=wx.SUNKEN_BORDER) 563 574 self.tree_ctrl_theory.Bind(CT.EVT_TREE_ITEM_CHECKING, … … 565 576 self.tree_ctrl_theory.Bind(CT.EVT_TREE_ITEM_MENU, 566 577 self.on_right_click_theory) 567 self.sizer1.Add(tree_ctrl_label, 0, wx.LEFT, 10) 568 self.sizer1.Add(self.tree_ctrl, 1, wx.EXPAND | wx.ALL, 10) 569 self.sizer1.Add(tree_ctrl_theory_label, 0, wx.LEFT, 10) 570 self.sizer1.Add(self.tree_ctrl_theory, 1, wx.EXPAND | wx.ALL, 10) 578 579 _ = self.tree_ctrl.InsertItem(self.tree_ctrl.root, 580 -999, " Data") 581 582 _ = self.tree_ctrl_theory.InsertItem(self.tree_ctrl_theory.root, 583 -1, " Theory") 584 585 splitter.SplitHorizontally(self.tree_ctrl, self.tree_ctrl_theory) 586 self.sizer1.Add(splitter, 1, wx.EXPAND | wx.ALL, 10) 571 587 572 588 def on_right_click_theory(self, event):
Note: See TracChangeset
for help on using the changeset viewer.