Index: sansview/perspectives/fitting/fitpage.py
===================================================================
--- sansview/perspectives/fitting/fitpage.py	(revision fb59ed90d8d3e021f0f291a9064098aae148158d)
+++ sansview/perspectives/fitting/fitpage.py	(revision d7b7156f5e3396b66f5f4b5c4a366e887b25df32)
@@ -440,5 +440,6 @@
         
         ## class base method  to add view 2d button    
-        self._set_model_sizer(sizer=sizer, box_sizer=boxsizer1, title="Model",object=self.model_help )   
+        self._set_model_sizer(sizer=sizer, box_sizer=boxsizer1, 
+                              title="Model",object=self.model_help )   
         
     def _set_sizer_dispersion(self, dispersity):
@@ -475,7 +476,10 @@
                            wx.LEFT|wx.EXPAND|wx.ADJUST_MINSIZE, 15)
         ix += 1 
-        values = wx.StaticText(self, -1, 'Sigma (STD)')
-        values.SetToolTipString("Polydispersity multiplied by the value of the original parameter.")
-        self.sizer4_4.Add(values,( iy, ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 0)
+        values = wx.StaticText(self, -1, 'Sigma [A]')
+        values.SetToolTipString(\
+        "Sigma(STD) in the A unit; the standard deviation from the mean value.")
+
+        self.sizer4_4.Add(values,( iy, ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 
+                          0)
         ix +=2 
         self.text_disp_1 = wx.StaticText(self, -1, '')
@@ -499,10 +503,15 @@
         ix += 1 
         npts = wx.StaticText(self, -1, 'Npts')
-        npts.SetToolTipString("Number of points for weighting.")
+        npts.SetToolTipString("Number of sampling points for the numerical\n\
+        integration over the distribution function.")
         self.sizer4_4.Add(npts,( iy, ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 0)
         ix += 1 
         nsigmas = wx.StaticText(self, -1, 'Nsigmas')
-        nsigmas.SetToolTipString("Number of sigmas between which the range of the distribution function will be used for weighting. The value '3' covers 99.5% for Gaussian distribution function.")
-        self.sizer4_4.Add(nsigmas,( iy, ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 0)
+        nsigmas.SetToolTipString("   Number of sigmas between which the range\n\
+         of the distribution function will be used for weighting. \n\
+        The value '3' covers 99.5% for Gaussian distribution \n\
+        function.")
+        self.sizer4_4.Add(nsigmas,( iy, ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE,
+                           0)
         
         if self.engine_type=="park":
@@ -514,4 +523,5 @@
                 if not self.disp_cb_dict.has_key(item):
                     self.disp_cb_dict[item]= None
+                name0="Distribution of " + item
                 name1=item+".width"
                 name2=item+".npts"
@@ -525,14 +535,17 @@
                     if p=="width":
                         ix = 0
-                        cb = wx.CheckBox(self, -1, name1, (10, 10))
+                        cb = wx.CheckBox(self, -1, name0, (10, 10))
                         cb.SetToolTipString("Check for fitting")
                         wx.EVT_CHECKBOX(self, cb.GetId(), self.select_param)
                         self.sizer4_4.Add( cb,( iy, ix),(1,1),  
-                                           wx.LEFT|wx.EXPAND|wx.ADJUST_MINSIZE, 15)
+                                           wx.LEFT|wx.EXPAND|wx.ADJUST_MINSIZE, 
+                                           15)
                         ix = 1
                         value= self.model.getParam(name1)
-                        ctl1 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH,20),
-                                            style=wx.TE_PROCESS_ENTER)
-                        ctl1.SetToolTipString("Polydispersity multiplied by the value of '%s'."%item)
+                        ctl1 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH,20)
+                                                  ,style=wx.TE_PROCESS_ENTER)
+                        ctl1.SetToolTipString("Absolute Sigma: \n\
+                        1) It is the STD (ratio*mean) of '%s' distribution.\n \
+                        2) It should not exceed Mean/(2*Nsigmas)." %item)
                         ctl1.SetValue(str (format_number(value)))
                         self.sizer4_4.Add(ctl1, (iy,ix),(1,1),wx.EXPAND)
@@ -545,22 +558,28 @@
 
                         ix = 3
-                        ctl2 = wx.TextCtrl(self, -1, size=(_BOX_WIDTH,20), style=0)
+                        ctl2 = wx.TextCtrl(self, -1, size=(_BOX_WIDTH,20), 
+                                           style=0)
                   
-                        self.sizer4_4.Add(ctl2, (iy,ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 0)
+                        self.sizer4_4.Add(ctl2, (iy,ix),(1,1), 
+                                          wx.EXPAND|wx.ADJUST_MINSIZE, 0)
                      
                         ctl2.Hide()
 
                         ix = 4
-                        ctl3 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,20), style=wx.TE_PROCESS_ENTER,
-                                                       text_enter_callback = self._onparamRangeEnter)
+                        ctl3 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,
+                                            20), style=wx.TE_PROCESS_ENTER,
+                                text_enter_callback = self._onparamRangeEnter)
                         
-                        self.sizer4_4.Add(ctl3, (iy,ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 0)
+                        self.sizer4_4.Add(ctl3, (iy,ix),(1,1), 
+                                          wx.EXPAND|wx.ADJUST_MINSIZE, 0)
                         ctl3.Hide()
                 
                         ix = 5
-                        ctl4 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,20), style=wx.TE_PROCESS_ENTER,
-                                                       text_enter_callback = self._onparamRangeEnter)
+                        ctl4 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,
+                                            20), style=wx.TE_PROCESS_ENTER,
+                            text_enter_callback = self._onparamRangeEnter)
                         
-                        self.sizer4_4.Add(ctl4, (iy,ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 0)
+                        self.sizer4_4.Add(ctl4, (iy,ix),(1,1), 
+                                          wx.EXPAND|wx.ADJUST_MINSIZE, 0)
 
                         ctl4.Hide()
@@ -576,5 +595,6 @@
                             ix = 6
                             value= self.model.getParam(name2)
-                            Tctl = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,20),
+                            Tctl = self.ModelTextCtrl(self, -1, 
+                                                      size=(_BOX_WIDTH/2,20),
                                                 style=wx.TE_PROCESS_ENTER)
                             
@@ -587,5 +607,6 @@
                             ix = 7
                             value= self.model.getParam(name3)
-                            Tct2 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,20),
+                            Tct2 = self.ModelTextCtrl(self, -1, 
+                                                      size=(_BOX_WIDTH/2,20),
                                                 style=wx.TE_PROCESS_ENTER)
                             
@@ -598,16 +619,21 @@
                             
                             self.fixed_param.append([None,name3, Tct2
-                                                     ,None,None,None, None,None])
+                                                     ,None,None,None, 
+                                                     None,None])
                             
         ix =0
         iy +=1 
-        self.sizer4_4.Add((20,20),(iy,ix),(1,1), wx.LEFT|wx.EXPAND|wx.ADJUST_MINSIZE, 15)  
+        self.sizer4_4.Add((20,20),(iy,ix),(1,1), 
+                          wx.LEFT|wx.EXPAND|wx.ADJUST_MINSIZE, 15)  
+        first_orient  = True
         for item in self.model.dispersion.keys():
             if  item in self.model.orientation_params:
                 if not self.disp_cb_dict.has_key(item):
                     self.disp_cb_dict[item]= None
+                name0="Distribution of " + item
                 name1=item+".width"
                 name2=item+".npts"
                 name3=item+".nsigmas"
+                
                 if not self.model.details.has_key(name1):
                     self.model.details [name1] = ["",None,None]                  
@@ -619,9 +645,10 @@
                     if p=="width":
                         ix = 0
-                        cb = wx.CheckBox(self, -1, name1, (10, 10))
+                        cb = wx.CheckBox(self, -1, name0, (10, 10))
                         cb.SetToolTipString("Check for fitting")
                         wx.EVT_CHECKBOX(self, cb.GetId(), self.select_param)
                         self.sizer4_4.Add( cb,( iy, ix),(1,1),  
-                                           wx.LEFT|wx.EXPAND|wx.ADJUST_MINSIZE, 15)
+                                           wx.LEFT|wx.EXPAND|wx.ADJUST_MINSIZE, 
+                                           15)
                         if self.data.__class__.__name__ =="Data2D":
                             cb.Show(True)
@@ -630,12 +657,21 @@
                         ix = 1
                         value= self.model.getParam(name1)
-                        ctl1 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH,20),
-                                            style=wx.TE_PROCESS_ENTER)
-                        ctl1.SetToolTipString("Polydispersity multiplied by the value of '%s'."%item)
+                        ctl1 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH,
+                                        20),style=wx.TE_PROCESS_ENTER)
+                        ctl1.SetToolTipString("Absolute Sigma: \n\
+                        1) It is the STD (ratio*mean) of '%s' distribution."% \
+                        item)
                         ctl1.SetValue(str (format_number(value)))
                         if self.data.__class__.__name__ =="Data2D":
+                            if first_orient:
+                                values.SetLabel('Sigma [A (or deg)]')
+                                values.SetToolTipString(\
+                                "Sigma(STD) in the A or deg(for angles) unit;\n\
+                                the standard deviation from the mean value.")
+                                first_orient = False
                             ctl1.Show(True)
                         elif ctl1.IsShown():
                             ctl1.Hide()
+                        
                         self.sizer4_4.Add(ctl1, (iy,ix),(1,1),wx.EXPAND)
                         ## text to show error sign
@@ -647,21 +683,28 @@
 
                         ix = 3
-                        ctl2 = wx.TextCtrl(self, -1, size=(_BOX_WIDTH,20), style=0)
+                        ctl2 = wx.TextCtrl(self, -1, size=(_BOX_WIDTH,20), 
+                                           style=0)
                     
-                        self.sizer4_4.Add(ctl2, (iy,ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 0)
+                        self.sizer4_4.Add(ctl2, (iy,ix),(1,1), 
+                                          wx.EXPAND|wx.ADJUST_MINSIZE, 0)
                         ctl2.Hide()
                             
                         ix = 4
-                        ctl3 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,20), style=wx.TE_PROCESS_ENTER,
-                                                       text_enter_callback = self._onparamRangeEnter)
-
-                        self.sizer4_4.Add(ctl3, (iy,ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 0)
+                        ctl3 = self.ModelTextCtrl(self, -1, 
+                                                  size=(_BOX_WIDTH/2,20), 
+                                                  style=wx.TE_PROCESS_ENTER,
+                                text_enter_callback = self._onparamRangeEnter)
+
+                        self.sizer4_4.Add(ctl3, (iy,ix),(1,1), 
+                                          wx.EXPAND|wx.ADJUST_MINSIZE, 0)
 
                         ctl3.Hide()
                 
                         ix = 5
-                        ctl4 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,20), style=wx.TE_PROCESS_ENTER,
-                                                       text_enter_callback = self._onparamRangeEnter)
-                        self.sizer4_4.Add(ctl4, (iy,ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 0)
+                        ctl4 = self.ModelTextCtrl(self, -1, 
+                            size=(_BOX_WIDTH/2,20), style=wx.TE_PROCESS_ENTER,
+                                text_enter_callback = self._onparamRangeEnter)
+                        self.sizer4_4.Add(ctl4, (iy,ix),(1,1), 
+                                          wx.EXPAND|wx.ADJUST_MINSIZE, 0)
                         ctl4.Hide()
                         #if self.data.__class__.__name__ =="Data2D":
@@ -670,5 +713,6 @@
                             #ctl4.Hide()
                         
-                        if self.engine_type=="park" and self.data.__class__.__name__ =="Data2D":
+                        if self.engine_type=="park" and \
+                                    self.data.__class__.__name__ =="Data2D":
                             ctl3.Show(True)
                             ctl4.Show(True) 
@@ -679,10 +723,11 @@
                         self.fittable_param.append([cb,name1,ctl1,text2,
                                                     ctl2, ctl3, ctl4,None])
-                        self.orientation_params_disp.append([cb,name1,ctl1,text2,
-                                                    ctl2, ctl3, ctl4,None])
+                        self.orientation_params_disp.append([cb,name1,ctl1,
+                                                  text2, ctl2, ctl3, ctl4,None])
                     elif p=="npts":
                             ix = 6
                             value= self.model.getParam(name2)
-                            Tctl = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,20),
+                            Tctl = self.ModelTextCtrl(self, -1, 
+                                                      size=(_BOX_WIDTH/2,20),
                                                 style=wx.TE_PROCESS_ENTER)
                             
@@ -696,10 +741,12 @@
                             self.fixed_param.append([None,name2, Tctl,None,None,
                                                       None, None,None])
-                            self.orientation_params_disp.append([None,name2, Tctl,None,None,
+                            self.orientation_params_disp.append([None,name2, 
+                                                    Tctl,None,None,
                                                       None, None,None])
                     elif p=="nsigmas":
                             ix = 7
                             value= self.model.getParam(name3)
-                            Tct2 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,20),
+                            Tct2 = self.ModelTextCtrl(self, -1, 
+                                                      size=(_BOX_WIDTH/2,20),
                                                 style=wx.TE_PROCESS_ENTER)
                             
@@ -714,9 +761,9 @@
 
                             self.fixed_param.append([None,name3, Tct2
-                                                     ,None,None, None, None,None])    
+                                                 ,None,None, None, None,None])    
                                                        
-                            self.orientation_params_disp.append([None,name3, Tct2
-                                                     ,None,None, None, None,None])
-       
+                            self.orientation_params_disp.append([None,name3, 
+                                            Tct2 ,None,None, None, None,None])
+        
         self.state.disp_cb_dict = copy.deepcopy(self.disp_cb_dict)  
           
@@ -727,5 +774,6 @@
         self._copy_parameters_state(self.orientation_params_disp,
                                      self.state.orientation_params_disp)
-        self._copy_parameters_state(self.fittable_param, self.state.fittable_param)
+        self._copy_parameters_state(self.fittable_param, 
+                                    self.state.fittable_param)
         self._copy_parameters_state(self.fixed_param, self.state.fixed_param)
 
@@ -769,10 +817,12 @@
         #self._clear_Err_on_Fit() 
 
-        # Remove or do not allow fitting on the Q=0 point, especially when y(q=0)=None at x[0].         
+        # Remove or do not allow fitting on the Q=0 point, especially 
+        # when y(q=0)=None at x[0].         
         self.qmin_x = float(self.qmin.GetValue())
         self.qmax_x = float( self.qmax.GetValue())
         self.manager._reset_schedule_problem( value=0)
         self.manager.schedule_for_fit( value=1,page=self,fitproblem =None) 
-        self.manager.set_fit_range(page= self,qmin= self.qmin_x, qmax= self.qmax_x)
+        self.manager.set_fit_range(page= self,qmin= self.qmin_x, 
+                                   qmax= self.qmax_x)
         
         #single fit 
@@ -782,8 +832,10 @@
         #    self.btFit.SetLabel("Stop")
         #    self.btFit.Unbind(event=wx.EVT_BUTTON, id= self.btFit.GetId())
-        #    self.btFit.Bind(event= wx.EVT_BUTTON, handler=self._StopFit, id=self.btFit.GetId())
+        #    self.btFit.Bind(event= wx.EVT_BUTTON, 
+        #            handler=self._StopFit, id=self.btFit.GetId())
         #else:
         #    self.btFit.SetLabel("Fit")
-        #    self.btFit.Bind(event= wx.EVT_BUTTON, handler=self._onFit, id=self.btFit.GetId())
+        #    self.btFit.Bind(event= wx.EVT_BUTTON, 
+        #                handler=self._onFit, id=self.btFit.GetId())
            
     def _StopFit(self, event):
@@ -795,5 +847,6 @@
             self.manager.stop_fit()
         self.btFit.Unbind(event=wx.EVT_BUTTON, id=self.btFit.GetId())
-        self.btFit.Bind(event=wx.EVT_BUTTON, handler=self._onFit,id=self.btFit.GetId())
+        self.btFit.Bind(event=wx.EVT_BUTTON, handler=self._onFit,
+                        id=self.btFit.GetId())
         
             
@@ -831,6 +884,8 @@
             ## event to post model to fit to fitting plugins
             (ModelEventbox, EVT_MODEL_BOX) = wx.lib.newevent.NewEvent()
-            if self.data is not None and self.data.__class__.__name__ !="Data2D":
-                ## set smearing value whether or not the data contain the smearing info
+            if self.data is not None and \
+                    self.data.__class__.__name__ !="Data2D":
+                ## set smearing value whether or not 
+                #    the data contain the smearing info
                 evt = ModelEventbox(model=self.model, 
                                         smearer=temp_smear, 
@@ -881,5 +936,6 @@
                 if not self.disable_smearer.GetValue():
                     temp_smearer= self.current_smearer
-                    ## set smearing value whether or not the data contain the smearing info
+                    ## set smearing value whether or not 
+                    #        the data contain the smearing info
                     if self.slit_smearer.GetValue():
                         flag1 = self.update_slit_smear()
@@ -889,6 +945,7 @@
                         flag = flag or flag1
                 elif self.data.__class__.__name__ !="Data2D":
-                    self.manager.set_smearer(smearer=temp_smearer, qmin= float(self.qmin_x),
-                                                             qmax= float(self.qmax_x)) 
+                    self.manager.set_smearer(smearer=temp_smearer, 
+                                             qmin= float(self.qmin_x),
+                                            qmax= float(self.qmax_x)) 
                 if flag:   
                     #self.compute_chisqr(smearer= temp_smearer)
@@ -901,5 +958,7 @@
                     self.state_change= False 
             else: 
-                return    # invalid fit range: do nothing here: msg already displayed in validate    
+                # invalid fit range: do nothing here: 
+                # msg already displayed in validate 
+                return      
         else:
             self.save_current_state()
@@ -983,10 +1042,12 @@
             if self.data.__class__.__name__ =="Data2D":
                 # set mask   
-                radius= numpy.sqrt( self.data.qx_data*self.data.qx_data + self.data.qy_data*self.data.qy_data )
+                radius= numpy.sqrt( self.data.qx_data*self.data.qx_data + 
+                                    self.data.qy_data*self.data.qy_data )
                 index_data = ((self.qmin <= radius)&(radius<= self.qmax))
                 index_data = (index_data)&(self.data.mask)
                 index_data = (index_data)&(numpy.isfinite(self.data.data))
                 if len(index_data[index_data]) < 10:
-                    msg= "Cannot Plot :No or too little npts in that data range!!!  "
+                    msg= "Cannot Plot :No or too little npts in \
+                                        that data range!!!  "
                     wx.PostEvent(self.parent.parent, StatusEvent(status = msg ))
                     return
@@ -995,5 +1056,6 @@
                     self.Npts_fit.Setvalue(str(len(self.data.mask)))
             else:
-                index_data = ((self.qmin <= self.data.x)&(self.data.x <= self.qmax))
+                index_data = ((self.qmin <= self.data.x)& \
+                              (self.data.x <= self.qmax))
                 self.Npts_fit.SetValue(str(len(self.data.x[index_data])))
            
@@ -1068,5 +1130,6 @@
        
         :return: self.smear_type, self.dq_l and self.dq_r, 
-            respectively the type of the smear, dq_min and dq_max for pinhole smear data 
+            respectively the type of the smear, dq_min and 
+            dq_max for pinhole smear data 
             while dxl and dxw for slit smear
             
@@ -1083,5 +1146,6 @@
             if data.dqx_data == None or  data.dqy_data ==None: 
                 return
-            elif self.smearer != None and (data.dqx_data.any()!=0) and (data.dqx_data.any()!=0): 
+            elif self.smearer != None and (data.dqx_data.any()!=0) and \
+                            (data.dqx_data.any()!=0): 
                 self.smear_type = "Pinhole2d"
                 self.dq_l = format_number(numpy.average(data.dqx_data)) 
@@ -1225,5 +1289,6 @@
             self.onSmear(event=None)
             if self.current_smearer != None:
-                self.current_smearer.set_accuracy(accuracy = self.smear2d_accuracy) 
+                self.current_smearer.set_accuracy(accuracy = 
+                                                  self.smear2d_accuracy) 
         event.Skip()
 
@@ -1241,5 +1306,6 @@
         self.model.setParam(name,fun_val)
         # save state
-        self._copy_parameters_state(self.str_parameters, self.state.str_parameters)
+        self._copy_parameters_state(self.str_parameters, 
+                                    self.state.str_parameters)
         # update params
         self._update_paramv_on_fit() 
@@ -1255,5 +1321,6 @@
         """
         
-        from sans.guiframe.local_perspectives.plotting.masking import MaskPanel as MaskDialog
+        from sans.guiframe.local_perspectives.plotting.masking \
+        import MaskPanel as MaskDialog
         
         self.panel = MaskDialog(self, data=self.data,id =-1 )
@@ -1383,5 +1450,6 @@
         qmin,qmax = self.get_range()
         if self.data.__class__.__name__ =="Data2D": 
-            radius= numpy.sqrt( self.data.qx_data*self.data.qx_data + self.data.qy_data*self.data.qy_data )
+            radius= numpy.sqrt( self.data.qx_data*self.data.qx_data + 
+                                self.data.qy_data*self.data.qy_data )
             index_data = (self.qmin_x <= radius)&(radius<= self.qmax_x)
             index_data= (index_data)&(self.data.mask)
@@ -1478,5 +1546,6 @@
                     if dispersity !=None:
                         name= dispersity.__name__
-                        if name == "GaussianDispersion" and self.enable_disp.GetValue():
+                        if name == "GaussianDispersion" and \
+                        self.enable_disp.GetValue():
                             if hasattr(self,"text_disp_1" ):
                                 if self.text_disp_1 !=None:
@@ -1516,5 +1585,6 @@
                             if dispersity !=None:
                                 name= dispersity.__name__
-                                if name == "GaussianDispersion" and self.enable_disp.GetValue():
+                                if name == "GaussianDispersion" and \
+                                                self.enable_disp.GetValue():
                                     if hasattr(self,"text_disp_1" ):
                                         if self.text_disp_1!=None:
@@ -1683,5 +1753,6 @@
                 else:
                     step = (self.dx_max - self.dx_min)/(len_data-1)    
-                    data.dx = numpy.arange(self.dx_min,self.dx_max+step/1.1,step)            
+                    data.dx = numpy.arange(self.dx_min,self.dx_max+step/1.1,
+                                           step)            
             elif self.dx_min != None: 
                 if self._is_2D(): data.dqx_data[data.dqx_data==0] = self.dx_min
@@ -1693,5 +1764,6 @@
             # 2D need to set accuracy
             if self._is_2D(): 
-                self.current_smearer.set_accuracy(accuracy = self.smear2d_accuracy)
+                self.current_smearer.set_accuracy(accuracy = \
+                                                  self.smear2d_accuracy)
 
         if msg != None:
@@ -1701,5 +1773,6 @@
             get_pin_max.SetBackgroundColour("white")
         ## set smearing value whether or not the data contain the smearing info
-        self.manager.set_smearer(smearer=self.current_smearer, qmin= float(self.qmin_x),qmax= float(self.qmax_x))
+        self.manager.set_smearer(smearer=self.current_smearer, qmin= \
+                                 float(self.qmin_x),qmax= float(self.qmax_x))
         return msg
         
@@ -1794,5 +1867,6 @@
         height = self.smear_slit_height.GetValue()
         
-        # check and change the box bg color if it was pink but it should be white now
+        # check and change the box bg color if it was pink 
+        #    but it should be white now
         # because this is the case that _set_slit_smear() will not handle
         if height.lstrip().rstrip()=="":
@@ -1869,5 +1943,6 @@
         #temp_smearer = self.current_smearer
         ## set smearing value whether or not the data contain the smearing info
-        self.manager.set_smearer(smearer=self.current_smearer, qmin= float(self.qmin_x), qmax= float(self.qmax_x)) 
+        self.manager.set_smearer(smearer=self.current_smearer, qmin= \
+                                 float(self.qmin_x), qmax= float(self.qmax_x)) 
         return msg
     
@@ -2045,5 +2120,6 @@
                     self.param_toFit.remove(item)
 
-        #Select parameters to fit for list of fittable parameters with dispersion          
+        #Select parameters to fit for list of fittable parameters 
+        #        with dispersion          
         for item in self.fittable_param:
             #Skip t ifhe angle parameters if 1D data
@@ -2068,5 +2144,6 @@
             len_orient_para *= 2
         #Set the value of checkbox that selected every checkbox or not            
-        if len(self.parameters)+len(self.fittable_param)-len_orient_para ==len(self.param_toFit):
+        if len(self.parameters)+len(self.fittable_param)-len_orient_para ==\
+                len(self.param_toFit):
             self.cb1.SetValue(True)
         else:
@@ -2199,5 +2276,6 @@
         
         for item in keys:
-            if not item in self.disp_list and not item in self.model.orientation_params:
+            if not item in self.disp_list and not item in \
+                    self.model.orientation_params:
                 
                 ##prepare a spot to store errors
@@ -2207,5 +2285,6 @@
                 iy += 1
                 ix = 0
-                if self.model.__class__ in self.model_list_box["Multi-Functions"] \
+                if self.model.__class__ in \
+                    self.model_list_box["Multi-Functions"] \
                     and item in self.model.non_fittable:
                     non_fittable_name = wx.StaticText(self, -1, item )
@@ -2217,16 +2296,20 @@
                     if len(self.model.fun_list) > 0:
                         num = item.split('_')[1][5:7]
-                        fun_box = wx.ComboBox(self, -1,size=(100,-1),style=wx.CB_READONLY, name = '%s'% item)
+                        fun_box = wx.ComboBox(self, -1,size=(100,-1),
+                                    style=wx.CB_READONLY, name = '%s'% item)
                         self._set_fun_box_list(fun_box)
                         fun_box.SetSelection(0)
-                        #self.fun_box.SetToolTipString("A function describing the interface")
+                        #self.fun_box.SetToolTipString("A function 
+                        #    describing the interface")
                         wx.EVT_COMBOBOX(fun_box,-1, self._on_fun_box)
                     else:
-                        fun_box = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH,20),
-                                        style=wx.TE_PROCESS_ENTER, name ='%s'% item)
+                        fun_box = self.ModelTextCtrl(self, -1, 
+                                                     size=(_BOX_WIDTH,20),
+                                style=wx.TE_PROCESS_ENTER, name ='%s'% item)
                         fun_box.SetToolTipString("Hit 'Enter' after typing.")
                         fun_box.SetValue(format_number(value))
                     sizer.Add(fun_box, (iy,ix),(1,1), wx.EXPAND)
-                    self.str_parameters.append([None,item, fun_box,None,None,None,None,None])
+                    self.str_parameters.append([None,item, fun_box,
+                                                None,None,None,None,None])
 
                     
@@ -2257,18 +2340,23 @@
                     ix += 1
                     ctl2 = wx.TextCtrl(self, -1, size=(_BOX_WIDTH,20), style=0)
-                    sizer.Add(ctl2, (iy,ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 0)
+                    sizer.Add(ctl2, (iy,ix),(1,1), 
+                              wx.EXPAND|wx.ADJUST_MINSIZE, 0)
                     ctl2.Hide()
                     
                     ix += 1
-                    ctl3 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,20), style=wx.TE_PROCESS_ENTER,
-                                                   text_enter_callback = self._onparamRangeEnter)
+                    ctl3 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,20),
+                                               style=wx.TE_PROCESS_ENTER,
+                                text_enter_callback = self._onparamRangeEnter)
          
-                    sizer.Add(ctl3, (iy,ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 0)
+                    sizer.Add(ctl3, (iy,ix),(1,1), 
+                              wx.EXPAND|wx.ADJUST_MINSIZE, 0)
                     ctl3.Hide()
             
                     ix += 1
-                    ctl4 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,20), style=wx.TE_PROCESS_ENTER,
-                                                   text_enter_callback = self._onparamRangeEnter)
-                    sizer.Add(ctl4, (iy,ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 0)
+                    ctl4 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,20),
+                                               style=wx.TE_PROCESS_ENTER,
+                                text_enter_callback = self._onparamRangeEnter)
+                    sizer.Add(ctl4, (iy,ix),(1,1), 
+                              wx.EXPAND|wx.ADJUST_MINSIZE, 0)
           
                     ctl4.Hide()
@@ -2280,8 +2368,10 @@
                     # Units
                     if self.model.details.has_key(item):
-                        units = wx.StaticText(self, -1, self.model.details[item][0], style=wx.ALIGN_LEFT)
+                        units = wx.StaticText(self, -1, 
+                            self.model.details[item][0], style=wx.ALIGN_LEFT)
                     else:
                         units = wx.StaticText(self, -1, "", style=wx.ALIGN_LEFT)
-                    sizer.Add(units, (iy,ix),(1,1),  wx.EXPAND|wx.ADJUST_MINSIZE, 0)
+                    sizer.Add(units, (iy,ix),(1,1), 
+                               wx.EXPAND|wx.ADJUST_MINSIZE, 0)
                         
                     ##[cb state, name, value, "+/-", error of fit, min, max , units]
@@ -2290,5 +2380,6 @@
                                   
         iy+=1
-        sizer.Add((10,10),(iy,ix),(1,1), wx.LEFT|wx.EXPAND|wx.ADJUST_MINSIZE, 15)
+        sizer.Add((10,10),(iy,ix),(1,1), 
+                  wx.LEFT|wx.EXPAND|wx.ADJUST_MINSIZE, 15)
         
         # type can be either Guassian or Array
@@ -2304,5 +2395,6 @@
             if item in self.model.orientation_params:       
                 orient_angle = wx.StaticText(self, -1, '[For 2D only]:')
-                sizer.Add(orient_angle,(iy, ix),(1,1), wx.LEFT|wx.EXPAND|wx.ADJUST_MINSIZE, 15) 
+                sizer.Add(orient_angle,(iy, ix),(1,1), 
+                          wx.LEFT|wx.EXPAND|wx.ADJUST_MINSIZE, 15) 
                 if not self.data.__class__.__name__ =="Data2D":
                     orient_angle.Hide()
@@ -2353,23 +2445,29 @@
                     ix += 1
                     ctl2 = wx.TextCtrl(self, -1, size=(_BOX_WIDTH,20), style=0)
-                    sizer.Add(ctl2, (iy,ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 0)
+                    sizer.Add(ctl2, (iy,ix),(1,1), 
+                              wx.EXPAND|wx.ADJUST_MINSIZE, 0)
                     ctl2.Hide()
                     
                     
                     ix += 1
-                    ctl3 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,20), style=wx.TE_PROCESS_ENTER,
-                                                   text_enter_callback = self._onparamRangeEnter)
+                    ctl3 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,20), 
+                                              style=wx.TE_PROCESS_ENTER,
+                                text_enter_callback = self._onparamRangeEnter)
                     
-                    sizer.Add(ctl3, (iy,ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 0)
+                    sizer.Add(ctl3, (iy,ix),(1,1), 
+                              wx.EXPAND|wx.ADJUST_MINSIZE, 0)
                     ctl3.Hide()
                  
                     ix += 1
-                    ctl4 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,20), style=wx.TE_PROCESS_ENTER,
-                                                   text_enter_callback = self._onparamRangeEnter)
-                    sizer.Add(ctl4, (iy,ix),(1,1), wx.EXPAND|wx.ADJUST_MINSIZE, 0)
+                    ctl4 = self.ModelTextCtrl(self, -1, size=(_BOX_WIDTH/2,20),
+                                               style=wx.TE_PROCESS_ENTER,
+                            text_enter_callback = self._onparamRangeEnter)
+                    sizer.Add(ctl4, (iy,ix),(1,1), 
+                              wx.EXPAND|wx.ADJUST_MINSIZE, 0)
                    
                     ctl4.Hide()
                     
-                    if self.engine_type =="park" and self.data.__class__.__name__ =="Data2D":                      
+                    if self.engine_type =="park" and \
+                            self.data.__class__.__name__ =="Data2D":                      
                         ctl3.Show(True)
                         ctl4.Show(True)
@@ -2378,5 +2476,7 @@
                     # Units
                     if self.model.details.has_key(item):
-                        units = wx.StaticText(self, -1, self.model.details[item][0], style=wx.ALIGN_LEFT)
+                        units = wx.StaticText(self, -1, 
+                                              self.model.details[item][0], 
+                                              style=wx.ALIGN_LEFT)
                     else:
                         units = wx.StaticText(self, -1, "", style=wx.ALIGN_LEFT)
@@ -2387,7 +2487,8 @@
                         units.Hide()
                     
-                    sizer.Add(units, (iy,ix),(1,1),  wx.EXPAND|wx.ADJUST_MINSIZE, 0)
+                    sizer.Add(units, (iy,ix),(1,1),  
+                              wx.EXPAND|wx.ADJUST_MINSIZE, 0)
                                           
-                    ##[cb state, name, value, "+/-", error of fit, min, max , units]
+                    ##[cb state, name, value, "+/-", error of fit,min,max,units]
                     self.parameters.append([cb,item, ctl1,
                                             text2,ctl2, ctl3, ctl4,units])
