- Timestamp:
- Mar 24, 2015 8:42:13 PM (10 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, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
- Children:
- f552ff3
- Parents:
- 1805b87
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/sas/perspectives/pr/inversion_panel.py
r8b21fa7 rdea2f6e 16 16 from pr_widgets import DataFileTextCtrl 17 17 from pr_widgets import OutputTextCtrl 18 from sas.guiframe.documentation_window import DocumentationWindow 18 19 19 20 if sys.platform.count("win32") > 0: … … 675 676 self.Bind(wx.EVT_BUTTON, self._on_invert, id=wx_id) 676 677 678 # self.button_help = wx.Button(self, -1, "HELP") 679 # app_tip = "Get help on P(r) inversion." 680 # self.button_help.SetToolTipString(app_tip) 681 # self.button_help.Bind(wx.EVT_BUTTON, self.on_help) 682 677 683 self._set_reset_flag(True) 678 684 self._set_save_flag(True) … … 680 686 sizer_button.Add((20, 20), 1, wx.EXPAND | wx.ADJUST_MINSIZE, 0) 681 687 sizer_button.Add(button_ok, 0, wx.LEFT | wx.ADJUST_MINSIZE, 10) 688 # sizer_button.Add(self.button_help, 0, wx.LEFT | wx.ADJUST_MINSIZE, 10) 682 689 683 690 iy_vb += 1 … … 928 935 logging.error(msg) 929 936 930 class HelpDialog(wx.Dialog): 937 def on_help(self, event): 938 """ 939 Bring up the P(r) Documentation whenever 940 the HELP button is clicked. 941 942 Calls DocumentationWindow with the path of the location within the 943 documentation tree (after /doc/ ....". Note that when using old 944 versions of Wx (before 2.9) and thus not the release version of 945 installers, the help comes up at the top level of the file as 946 webbrowser does not pass anything past the # to the browser when it is 947 running "file:///...." 948 949 :param evt: Triggers on clicking the help button 931 950 """ 932 """ 933 def __init__(self, parent, id): 934 """ 935 """ 936 from sas.pr.invertor import help 937 wx.Dialog.__init__(self, parent, id, size=(400, 450)) 938 self.SetTitle("P(r) help") 939 self.SetWindowVariant(variant=FONT_VARIANT) 940 941 vbox = wx.BoxSizer(wx.VERTICAL) 942 943 explanation = help() 944 945 label_explain = wx.StaticText(self, -1, explanation, size=(360, 350)) 946 947 vbox.Add(label_explain, 0, wx.ALL | wx.EXPAND, 15) 948 949 950 static_line = wx.StaticLine(self, -1) 951 vbox.Add(static_line, 0, wx.EXPAND, 0) 952 953 button_ok = wx.Button(self, wx.ID_OK, "OK") 954 955 sizer_button = wx.BoxSizer(wx.HORIZONTAL) 956 sizer_button.Add((20, 20), 1, wx.EXPAND | wx.ADJUST_MINSIZE, 0) 957 sizer_button.Add(button_ok, 0, wx.LEFT | wx.RIGHT | wx.ADJUST_MINSIZE, 10) 958 959 vbox.Add(sizer_button, 0, wx.EXPAND | wx.BOTTOM | wx.TOP, 10) 960 961 self.SetSizer(vbox) 962 self.SetAutoLayout(True) 963 964 self.Layout() 965 self.Centre() 951 952 _TreeLocation = "user/perspectives/pr/pr_help.html" 953 _doc_viewer = DocumentationWindow(self, -1, \ 954 _TreeLocation, "P(r) Help") 955 956 957 958 #class HelpDialog(wx.Dialog): 959 # """ 960 # """ 961 # def __init__(self, parent, id): 962 # """ 963 # """ 964 # from sas.pr.invertor import help 965 # wx.Dialog.__init__(self, parent, id, size=(400, 450)) 966 # self.SetTitle("P(r) help") 967 # self.SetWindowVariant(variant=FONT_VARIANT) 968 # 969 # vbox = wx.BoxSizer(wx.VERTICAL) 970 # 971 # explanation = help() 972 # 973 # label_explain = wx.StaticText(self, -1, explanation, size=(360, 350)) 974 # 975 # vbox.Add(label_explain, 0, wx.ALL | wx.EXPAND, 15) 976 # 977 # 978 # static_line = wx.StaticLine(self, -1) 979 # vbox.Add(static_line, 0, wx.EXPAND, 0) 980 # 981 # button_ok = wx.Button(self, wx.ID_OK, "OK") 982 # 983 # sizer_button = wx.BoxSizer(wx.HORIZONTAL) 984 # sizer_button.Add((20, 20), 1, wx.EXPAND | wx.ADJUST_MINSIZE, 0) 985 # sizer_button.Add(button_ok, 0, wx.LEFT | wx.RIGHT | wx.ADJUST_MINSIZE, 10) 986 # 987 # vbox.Add(sizer_button, 0, wx.EXPAND | wx.BOTTOM | wx.TOP, 10) 988 # 989 # self.SetSizer(vbox) 990 # self.SetAutoLayout(True) 991 # 992 # self.Layout() 993 # self.Centre() 966 994 967 995 class PrDistDialog(wx.Dialog):
Note: See TracChangeset
for help on using the changeset viewer.