Changeset 27976fd0 in sasview


Ignore:
Timestamp:
Apr 21, 2009 7:07:20 PM (15 years ago)
Author:
Gervaise Alina <gervyh@…>
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:
f99a6b1
Parents:
c09ac449
Message:

model description details

Location:
sansview
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • sansview/perspectives/fitting/fitting.py

    rd902cf0 r27976fd0  
    125125        self.fit_panel.set_model_list(self.menu_mng.get_model_list()) 
    126126        owner.Bind(fitpage.EVT_MODEL_BOX,self._on_model_panel) 
    127          
    128         #self.menu3= wx.Menu() 
    129         #id4 = wx.NewId() 
    130          
     127       
    131128        #create  menubar items 
    132129        return [(id, self.menu1, "Fitting"), 
    133130                (id2, menu2, "Model")] 
    134         #return [(id, self.menu1, "Fitting"), 
    135         #        (id4,self.menu3,"Averagers"), 
    136         #        (id2, menu2, "Model")] 
     131        
    137132     
    138133    def on_add_sim_page(self, event): 
     
    448443                    current_pg= page 
    449444            except: 
    450                 raise 
    451                 return 
    452                 #msg= "%s error: %s" % (engineType,sys.exc_value) 
    453                 #wx.PostEvent(self.parent, StatusEvent(status= msg )) 
    454                 #return  
     445                msg= "%s error: %s" % (engineType,sys.exc_value) 
     446                wx.PostEvent(self.parent, StatusEvent(status= msg )) 
     447                return  
    455448        #Do the simultaneous fit 
    456449        try: 
     
    483476             
    484477        except: 
    485             raise 
    486             #msg= "%s error: %s" % (engineType,sys.exc_value) 
    487             #wx.PostEvent(self.parent, StatusEvent(status= msg ,type="stop")) 
    488             #return  
     478            msg= "%s error: %s" % (engineType,sys.exc_value) 
     479            wx.PostEvent(self.parent, StatusEvent(status= msg ,type="stop")) 
     480            return  
    489481               
    490482               
     
    570562            value.clear_model_param() 
    571563        except: 
    572             raise 
     564            msg= title +" error: %s" % sys.exc_value 
     565            wx.PostEvent(self.parent, StatusEvent(status= msg, type="stop")) 
    573566            return 
    574             #msg= title +" error: %s" % sys.exc_value 
    575             #wx.PostEvent(self.parent, StatusEvent(status= msg, type="stop")) 
    576             #return 
    577567        
    578568    def _onSelect(self,event): 
     
    658648                        wx.PostEvent(self.parent, StatusEvent(status="Page was already Created")) 
    659649                except: 
    660                     raise 
    661                     #wx.PostEvent(self.parent, StatusEvent(status="Creating Fit page: %s"\ 
    662                     #%sys.exc_value)) 
    663                     #return 
     650                    wx.PostEvent(self.parent, StatusEvent(status="Creating Fit page: %s"\ 
     651                    %sys.exc_value)) 
     652                    return 
     653                 
     654                 
    664655    def _updateFit(self): 
    665656        """ 
     
    712703            wx.PostEvent(self.parent, StatusEvent(status=" " , type="stop"))  
    713704        except: 
    714             raise 
    715             #msg= "Single Fit completed but Following error occurred:%s"% sys.exc_value 
    716             #wx.PostEvent(self.parent, StatusEvent(status=msg,type="stop")) 
    717             #return 
     705            msg= "Single Fit completed but Following error occurred:%s"% sys.exc_value 
     706            wx.PostEvent(self.parent, StatusEvent(status=msg,type="stop")) 
     707            return 
    718708        
    719709        
  • sansview/perspectives/fitting/modelpage.py

    r6fdfc8f r27976fd0  
    6666             
    6767        else: 
    68             description="" 
     68            description="Model contains no description" 
    6969            if self.model!=None: 
    7070                description = self.model.description 
    71                  
     71            if description.lstrip().rstrip() =="":  
     72                description="Model contains no description" 
    7273            self.description = wx.StaticText( self,-1,str(description) ) 
    7374            self.sizer_description.Add( self.description, 1, wx.EXPAND | wx.ALL, 10 ) 
     
    403404        if frame.rhelp.HasAnchor(name): 
    404405            frame.rhelp.ScrollToAnchor(name) 
     406        else: 
     407           msg= "Model does not contains an available description " 
     408           msg +="Please.Search in the Help window" 
     409           wx.PostEvent(self.parent.parent, StatusEvent(status = msg )) 
     410                      
    405411             
    406412             
  • sansview/plugins/testmodel.py

    r6df36b3 r27976fd0  
    3030        self.details['B'] = ['', -1e16, 1e16] 
    3131        self.details['C'] = ['', -1e16, 1e16] 
     32        self.description = "F(x)=A+Bcos(2x)+Csin(2x) " 
    3233    
    3334    def function(self, x = 0.0): 
Note: See TracChangeset for help on using the changeset viewer.