Changeset 7116dffd in sasview for src/sas/perspectives
- Timestamp:
- Jun 14, 2015 4:38:22 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:
- f3dc56c
- Parents:
- 4faed25
- Location:
- src/sas/perspectives/fitting
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
src/sas/perspectives/fitting/basepage.py
r7801df8 r7116dffd 2889 2889 wx.MessageBox(msg, info) 2890 2890 2891 def _on_mag_ help(self, event):2891 def _on_mag_angle_help(self, event): 2892 2892 """ 2893 2893 Bring up Magnetic Angle definition bmp image whenever the ? button … … 2908 2908 _doc_viewer = DocumentationWindow(self, -1, _TreeLocation, "", 2909 2909 "Magnetic Angle Defintions") 2910 2911 def _on_mag_help(self, event): 2912 """ 2913 Bring up Magnetic Angle definition bmp image whenever the ? button 2914 is clicked. Calls DocumentationWindow with the path of the location 2915 within the documentation tree (after /doc/ ....". When using old 2916 versions of Wx (i.e. before 2.9 and therefore not part of release 2917 versions distributed via installer) it brings up an image viewer 2918 box which allows the user to click through the rest of the images in 2919 the directory. Not ideal but probably better than alternative which 2920 would bring up the entire discussion of how magnetic models work? 2921 Specially since it is not likely to be accessed. The normal release 2922 versions bring up the normal image box. 2923 2924 :param evt: Triggers on clicking ? in Magnetic Angles? box 2925 """ 2926 2927 _TreeLocation = "user/perspectives/fitting/mag_help.html" 2928 _doc_viewer = DocumentationWindow(self, -1, _TreeLocation, "", 2929 "Polarized Beam/Magnetc Help") 2910 2930 2911 2931 def _on_mag_on(self, event): -
src/sas/perspectives/fitting/fitpage.py
r7801df8 r7116dffd 293 293 294 294 #Resolution Smearing Help button 295 self.btSmearHelp = wx.Button(self, -1, '?' )295 self.btSmearHelp = wx.Button(self, -1, '?', style=wx.BU_EXACTFIT) 296 296 self.btSmearHelp.SetToolTipString("Resolution Smearing Help.") 297 297 self.btSmearHelp.Bind(wx.EVT_BUTTON, self._onSmearHelp) … … 3066 3066 orient_angle = wx.StaticText(self, -1, '[For 2D only]:') 3067 3067 mag_on_button = wx.Button(self, -1, "Magnetic ON") 3068 mag_on_button.SetToolTipString("Turn Pol Beam/Mag scatt on/off") 3068 3069 mag_on_button.Bind(wx.EVT_BUTTON, self._on_mag_on) 3069 mag_help_button = wx.Button(self, -1, "Magnetic angles?") 3070 mag_angle_help_button = wx.Button(self, -1, "Magnetic angles?") 3071 mag_angle_help_button.SetToolTipString("see angle definitions") 3072 mag_help_button = wx.Button(self, -1, "Mag HELP") 3073 mag_help_button.SetToolTipString("Help on pol beam/mag fitting") 3070 3074 mag_help_button.Bind(wx.EVT_BUTTON, self._on_mag_help) 3075 mag_angle_help_button.Bind(wx.EVT_BUTTON, \ 3076 self._on_mag_angle_help) 3071 3077 sizer.Add(orient_angle, (iy, ix), (1, 1), 3072 3078 wx.LEFT | wx.EXPAND | wx.ADJUST_MINSIZE, 15) … … 3074 3080 sizer.Add(mag_on_button, (iy, ix), (1, 1), 3075 3081 wx.LEFT | wx.EXPAND | wx.ADJUST_MINSIZE, 15) 3082 ix += 1 3083 sizer.Add(mag_angle_help_button, (iy, ix), (1, 1), 3084 wx.LEFT | wx.EXPAND | wx.ADJUST_MINSIZE, 15) 3076 3085 sizer.Add(mag_help_button, (iy, ix + 1), (1, 1), 3077 3086 wx.LEFT | wx.EXPAND | wx.ADJUST_MINSIZE, 15) 3078 3087 3079 3088 #handle the magnetic buttons 3089 #clean this up so that assume mag is off then turn 3090 #all buttons on IF mag has mag and has 2D 3080 3091 if not self._has_magnetic: 3081 3092 mag_on_button.Show(False) … … 3089 3100 mag_on_button.SetLabel("Magnetic OFF") 3090 3101 mag_help_button.Show(True) 3102 mag_angle_help_button.Show(True) 3091 3103 else: 3092 3104 mag_on_button.SetLabel("Magnetic ON") 3093 3105 mag_help_button.Show(False) 3106 mag_angle_help_button.Show(False) 3094 3107 3095 3108 if not self.data.__class__.__name__ == "Data2D" and \
Note: See TracChangeset
for help on using the changeset viewer.