Ignore:
Timestamp:
Jun 6, 2017 2:19:21 PM (5 years ago)
Author:
srkline
Message:

Minor changes to the function of the Beam Center panel so that it made sense, and would untimately allow writing the new center values to a data file on disk

Other cosetic changes to some of the panels

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_BeamCenter.ipf

    r1041 r1043  
    5454        Button button_1,pos={615,20},size={80,20},proc=V_DetFitButtonProc,title="Do Fit" 
    5555        Button button_2,pos={744,20},size={80,20},proc=V_DetFitHelpButtonProc,title="Help" 
    56         Button button_3,pos={615,400},size={110,20},proc=V_WriteCtrButtonProc,title="Write Centers" 
    57         Button button_4,pos={730,400},size={110,20},proc=V_CtrTableButtonProc,title="Ctr table" 
     56        Button button_3,pos={730,400},size={110,20},proc=V_CopyCtrButtonProc,title="Copy Centers" 
     57        Button button_4,pos={615,400},size={110,20},proc=V_CtrTableButtonProc,title="Ctr table" 
    5858        Button button_5,pos={730,440},size={110,20},proc=V_WriteCtrTableButtonProc,title="Write table" 
    5959 
     
    441441// TODO -- currently hard-wired for coefficients from the only fit function 
    442442// 
     443// only copies the center values to the local folder (then read back in by clicking  "Ctr Table") 
     444// 
    443445// -- will need to recalc mm center AND q-values 
    444 Function V_WriteCtrButtonProc(ba) : ButtonControl 
     446Function V_CopyCtrButtonProc(ba) : ButtonControl 
    445447        STRUCT WMButtonAction &ba 
    446448 
     
    459461                        V_putDet_beam_center_y(fname,detStr,coefW[10]) 
    460462 
    461                         DoAlert 0, "-- will need to recalc mm center AND q-values" 
     463//                      DoAlert 0, "-- will need to recalc mm center AND q-values" 
     464                         
     465                        V_BCtrTable()           //reads the values back in 
    462466                         
    463467                        break 
     
    717721Function V_BeamCtr_WriteTable() 
    718722 
    719         DoAlert 0,"this currently only writes pix values locally, not mm, and not to files on disk" 
     723        Variable runNumber 
     724        Prompt runNumber, "enter the run number:" 
     725        DoPrompt "Pick file to write to",runNumber 
     726        If(V_flag==1) 
     727                return(0) 
     728        endif    
    720729         
    721730        String folder 
     
    728737        Wave/T panelW = root:PanelW 
    729738         
    730         ControlInfo popup_2 
    731         folder = S_Value 
    732          
    733         fname = folder 
     739 
     740        fname = V_FindFileFromRunNumber(runNumber) 
     741 
    734742        for(ii=0;ii<ItemsInList(ksDetectorListAll);ii+=1) 
    735743//              detStr = StringFromList(ii, ksDetectorListAll, ";") 
    736744                detStr = panelW[ii] 
    737                 V_putDet_beam_center_x(fname,detStr,xCtr_pix[ii]) 
    738                 V_putDet_beam_center_y(fname,detStr,yCtr_pix[ii]) 
     745                V_writeDet_beam_center_x(fname,detStr,xCtr_pix[ii]) 
     746                V_writeDet_beam_center_y(fname,detStr,yCtr_pix[ii]) 
    739747                 
    740748                // TODO 
Note: See TracChangeset for help on using the changeset viewer.