Changeset 1246 for sans/Dev/trunk
- Timestamp:
- Mar 19, 2020 4:35:21 PM (3 years ago)
- Location:
- sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS
- Files:
-
- 15 edited
Legend:
- Unmodified
- Added
- Removed
-
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_DataPlotting.ipf
r1242 r1246 42 42 // Variable binType 43 43 44 45 Variable sc = 1 46 47 NVAR gLaptopMode = root:Packages:NIST:VSANS:Globals:gLaptopMode 48 49 if(gLaptopMode == 1) 50 sc = 0.7 51 endif 52 44 53 DoWindow/F V_1D_Data 45 54 if(V_flag==0) … … 52 61 // Variable/G root:Packages:NIST:VSANS:Globals:Plot_1D:gExpC = 1 53 62 54 55 Display /W=(277,526,748,938)/N=V_1D_Data/K=1 63 if(gLaptopMode == 1) 64 Display /W=(200,50,(200+470)*sc,(50+412)*sc)/N=V_1D_Data/K=1 65 else 66 Display /W=(277,526,748,938)/N=V_1D_Data/K=1 67 endif 68 56 69 57 70 ControlBar 70 58 71 59 PopupMenu popup0,pos={ 16,5},size={71,20},title="Bin Type"72 PopupMenu popup0,pos={sc*16,5*sc},size={sc*71,20*sc},title="Bin Type" 60 73 PopupMenu popup0,help={"This popup selects how the y-axis will be linearized based on the chosen data"} 61 74 PopupMenu popup0,value= ksBinTypeStr 62 75 PopupMenu popup0,mode=1,proc=V_BinningModePopup 63 76 64 CheckBox check0,pos={ 18.00,36.00},size={57.00,16.00},proc=V_Plot1D_LogCheckProc,title="Log Axes"77 CheckBox check0,pos={sc*18.00,36.00*sc},size={sc*57.00,16.00*sc},proc=V_Plot1D_LogCheckProc,title="Log Axes" 65 78 CheckBox check0,value= 1 66 79 67 // PopupMenu ymodel,pos={ 150,5},size={71,20},title="y-axis"80 // PopupMenu ymodel,pos={sc*150,5*sc},size={sc*71,20*sc},title="y-axis" 68 81 // PopupMenu ymodel,help={"This popup selects how the y-axis will be linearized based on the chosen data"} 69 82 // PopupMenu ymodel,value= #"\"I;log(I);ln(I);1/I;I^a;Iq^a;I^a q^b;1/sqrt(I);ln(Iq);ln(Iq^2)\"" 70 83 // PopupMenu ymodel,mode=NumVarOrDefault("root:Packages:NIST:VSANS:Globals:Plot_1d:gYMode", 1 ),proc=V_YMode_PopMenuProc 71 // PopupMenu xmodel,pos={ 220,5},size={74,20},title="x-axis"84 // PopupMenu xmodel,pos={sc*220,5*sc},size={sc*74,20*sc},title="x-axis" 72 85 // PopupMenu xmodel,help={"This popup selects how the x-axis will be linearized given the chosen data"} 73 86 // PopupMenu xmodel,value= #"\"q;log(q);q^2;q^c\"" 74 87 // PopupMenu xmodel,mode=NumVarOrDefault("root:Packages:NIST:VSANS:Globals:Plot_1d:gXMode", 1 ),proc=V_XMode_PopMenuProc 75 //// Button Rescale,pos={ 281,5},size={70,20},proc=V_Rescale_Plot_1D_ButtonProc,title="Rescale"88 //// Button Rescale,pos={sc*281,5*sc},size={sc*70,20*sc},proc=V_Rescale_Plot_1D_ButtonProc,title="Rescale" 76 89 //// Button Rescale,help={"Rescale the x and y-axes of the data"},disable=1 77 90 // 78 // SetVariable expa,pos={ 120,28},size={80,15},title="pow \"a\""91 // SetVariable expa,pos={sc*120,28*sc},size={sc*80,15*sc},title="pow \"a\"" 79 92 // SetVariable expa,help={"This sets the exponent \"a\" for some y-axis formats. The value is ignored if the model does not use an adjustable exponent"} 80 93 // SetVariable expa,limits={-2,10,0},value= root:Packages:NIST:VSANS:Globals:Plot_1d:gExpA 81 // SetVariable expb,pos={ 120,46},size={80,15},title="pow \"b\""94 // SetVariable expb,pos={sc*120,46*sc},size={sc*80,15*sc},title="pow \"b\"" 82 95 // SetVariable expb,help={"This sets the exponent \"b\" for some x-axis formats. The value is ignored if the model does not use an adjustable exponent"} 83 96 // SetVariable expb,limits={0,10,0},value= root:Packages:NIST:VSANS:Globals:Plot_1d:gExpB 84 97 // 85 // SetVariable expc,pos={ 220,28},size={80,15},title="pow \"c\""98 // SetVariable expc,pos={sc*220,28*sc},size={sc*80,15*sc},title="pow \"c\"" 86 99 // SetVariable expc,help={"This sets the exponent \"c\" for some x-axis formats. The value is ignored if the model does not use \"c\" as an adjustable exponent"} 87 100 // SetVariable expc,limits={-10,10,0},value= root:Packages:NIST:VSANS:Globals:Plot_1d:gExpC 88 101 89 Button AllQ,pos={ 320,15},size={70,20},proc=V_AllQ_Plot_1D_ButtonProc,title="All Q"102 Button AllQ,pos={sc*300,15*sc},size={sc*70,20*sc},proc=V_AllQ_Plot_1D_ButtonProc,title="All Q" 90 103 Button AllQ,help={"Show the full q-range of the dataset"} 91 104 92 Button Offset,pos={ 320,38},size={70,20},proc=V_RemoveOffset_ButtonProc,title="No Offset"105 Button Offset,pos={sc*300,38*sc},size={sc*70,20*sc},proc=V_RemoveOffset_ButtonProc,title="No Offset" 93 106 Button Offset,help={"Remove the offset"} 94 107 -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_Detector_Isolate.ipf
r1242 r1246 59 59 PauseUpdate; Silent 1 // building window... 60 60 61 62 NewPanel /W=(662,418,1586,960)/N=IsolateDetector /K=1 61 Variable sc = 1 62 63 if(root:Packages:NIST:VSANS:Globals:gLaptopMode == 1) 64 sc = 0.7 65 endif 66 67 NewPanel /W=(662*sc,418*sc,1586*sc,960*sc)/N=IsolateDetector /K=1 63 68 // ShowTools/A 64 69 65 PopupMenu popup_0,pos={ 169,18},size={109,20},proc=V_isoSetDetPanelPopMenuProc,title="Detector Panel"70 PopupMenu popup_0,pos={sc*169,18*sc},size={sc*109,20*sc},proc=V_isoSetDetPanelPopMenuProc,title="Detector Panel" 66 71 PopupMenu popup_0,mode=1,popvalue="FL",value= #"\"FL;FR;FT;FB;ML;MR;MT;MB;B;\"" 67 // PopupMenu popup_1,pos={ 200,20},size={157,20},proc=DetModelPopMenuProc,title="Model Function"72 // PopupMenu popup_1,pos={sc*200,20*sc},size={sc*157,20*sc},proc=DetModelPopMenuProc,title="Model Function" 68 73 // PopupMenu popup_1,mode=1,popvalue="BroadPeak",value= #"\"BroadPeak;other;\"" 69 PopupMenu popup_2,pos={ 20,18},size={109,20},title="Data Source",proc=V_SetFldrPopMenuProc74 PopupMenu popup_2,pos={sc*20,18*sc},size={sc*109,20*sc},title="Data Source",proc=V_SetFldrPopMenuProc 70 75 PopupMenu popup_2,mode=1,popvalue="RAW",value= #"\"RAW;SAM;EMP;BGD;DIV;MSK;\"" 71 76 72 Button button_0,pos={ 541,79},size={130,20},proc=V_isoCorrectButtonProc,title="Apply Corrections"73 // Button button_1,pos={ 651,79},size={80,20},proc=V_isoDetFitGuessButtonProc,title="Guess"74 Button button_2,pos={ 821,20},size={80,20},proc=V_isoHelpButtonProc,title="Help"75 76 77 78 CheckBox check_0,pos={ 542.00,131.00},size={110.00,16.00},title="non-linear correction"77 Button button_0,pos={sc*541,79*sc},size={sc*130,20*sc},proc=V_isoCorrectButtonProc,title="Apply Corrections" 78 // Button button_1,pos={sc*651,79*sc},size={sc*80,20*sc},proc=V_isoDetFitGuessButtonProc,title="Guess" 79 Button button_2,pos={sc*821,20*sc},size={sc*80,20*sc},proc=V_isoHelpButtonProc,title="Help" 80 81 82 83 CheckBox check_0,pos={sc*542.00,131.00*sc},size={sc*110.00,16.00*sc},title="non-linear correction" 79 84 CheckBox check_0,value= 0 80 CheckBox check_1,pos={ 542.00,159.00},size={110.00,16.00},title="dead time correction"85 CheckBox check_1,pos={sc*542.00,159.00*sc},size={sc*110.00,16.00*sc},title="dead time correction" 81 86 CheckBox check_1,value= 0 82 CheckBox check_2,pos={ 542.00,187.00},size={110.00,16.00},title="solid angle correction"87 CheckBox check_2,pos={sc*542.00,187.00*sc},size={sc*110.00,16.00*sc},title="solid angle correction" 83 88 CheckBox check_2,value= 0 84 CheckBox check_3,pos={ 542.00,215.00},size={110.00,16.00},title="sensitivity (DIV) correction"89 CheckBox check_3,pos={sc*542.00,215.00*sc},size={sc*110.00,16.00*sc},title="sensitivity (DIV) correction" 85 90 CheckBox check_3,value= 0 86 CheckBox check_4,pos={ 542.00,243.00},size={110.00,16.00},title="transmission correction"91 CheckBox check_4,pos={sc*542.00,243.00*sc},size={sc*110.00,16.00*sc},title="transmission correction" 87 92 CheckBox check_4,value= 0 88 CheckBox check_5,pos={ 542.00,271.00},size={110.00,16.00},title="tube shadow correction"93 CheckBox check_5,pos={sc*542.00,271.00*sc},size={sc*110.00,16.00*sc},title="tube shadow correction" 89 94 CheckBox check_5,value= 0 90 CheckBox check_6,pos={ 542.00,300.00},size={110.00,16.00},title="monitor normalization"95 CheckBox check_6,pos={sc*542.00,300.00*sc},size={sc*110.00,16.00*sc},title="monitor normalization" 91 96 CheckBox check_6,value= 0 92 97 … … 315 320 SetDataFolder $("root:Packages:NIST:VSANS:"+folder+":entry:instrument:detector_"+str) 316 321 Wave data1 = data 322 323 324 Variable sc = 1 325 326 NVAR gLaptopMode = root:Packages:NIST:VSANS:Globals:gLaptopMode 327 328 if(gLaptopMode == 1) 329 sc = 0.7 330 endif 331 332 left *= sc 333 top *= sc 334 right *= sc 335 bottom *= sc 336 337 left2 *= sc 338 top2 *= sc 339 right2 *= sc 340 bottom2 *= sc 341 317 342 318 343 //draw the detector panel … … 364 389 // temporarily set the global (preference) flags 365 390 366 // CheckBox check_0,pos={ 542.00,131.00},size={110.00,16.00},title="non-linear correction"391 // CheckBox check_0,pos={sc*542.00,131.00*sc},size={sc*110.00,16.00*sc},title="non-linear correction" 367 392 NVAR gDoNonLinearCor = root:Packages:NIST:VSANS:Globals:gDoNonLinearCor 368 393 sav0 = gDoNonLinearCor … … 370 395 gDoNonLinearCor = V_Value 371 396 372 // CheckBox check_1,pos={ 542.00,159.00},size={110.00,16.00},title="dead time correction"397 // CheckBox check_1,pos={sc*542.00,159.00*sc},size={sc*110.00,16.00*sc},title="dead time correction" 373 398 NVAR gDoDeadTimeCor = root:Packages:NIST:VSANS:Globals:gDoDeadTimeCor 374 399 sav1 = gDoDeadTimeCor … … 376 401 gDoDeadTimeCor = V_Value 377 402 378 // CheckBox check_2,pos={ 542.00,187.00},size={110.00,16.00},title="solid angle correction"403 // CheckBox check_2,pos={sc*542.00,187.00*sc},size={sc*110.00,16.00*sc},title="solid angle correction" 379 404 NVAR gDoSolidAngleCor = root:Packages:NIST:VSANS:Globals:gDoSolidAngleCor 380 405 sav2 = gDoSolidAngleCor … … 382 407 gDoSolidAngleCor = V_Value 383 408 384 // CheckBox check_3,pos={ 542.00,215.00},size={110.00,16.00},title="sensitivity (DIV) correction"409 // CheckBox check_3,pos={sc*542.00,215.00*sc},size={sc*110.00,16.00*sc},title="sensitivity (DIV) correction" 385 410 NVAR gDoDIVCor = root:Packages:NIST:VSANS:Globals:gDoDIVCor 386 411 sav3 = gDoDIVCor … … 388 413 gDoDIVCor = V_Value 389 414 390 // CheckBox check_4,pos={ 542.00,243.00},size={110.00,16.00},title="transmission correction"415 // CheckBox check_4,pos={sc*542.00,243.00*sc},size={sc*110.00,16.00*sc},title="transmission correction" 391 416 NVAR gDoTrans = root:Packages:NIST:VSANS:Globals:gDoTransmissionCor 392 417 sav4 = gDoTrans … … 394 419 gDoTrans = V_Value 395 420 396 // CheckBox check_5,pos={ 542.00,271.00},size={110.00,16.00},title="tube shadow correction"421 // CheckBox check_5,pos={sc*542.00,271.00*sc},size={sc*110.00,16.00*sc},title="tube shadow correction" 397 422 NVAR gDoTubeShadowCor = root:Packages:NIST:VSANS:Globals:gDoTubeShadowCor 398 423 sav5 = gDoTubeShadowCor … … 400 425 gDoTubeShadowCor = V_Value 401 426 402 // CheckBox check_6,pos={ 542.00,300.00},size={110.00,16.00},title="monitor normalization"427 // CheckBox check_6,pos={sc*542.00,300.00*sc},size={sc*110.00,16.00*sc},title="monitor normalization" 403 428 NVAR gDoMonitorNormalization = root:Packages:NIST:VSANS:Globals:gDoMonitorNormalization 404 429 sav6 = gDoMonitorNormalization -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_FileCatalog.ipf
r1242 r1246 210 210 211 211 numitems = ItemsInList(list,";") 212 Variable sc=1 213 NVAR gLaptopMode = root:Packages:NIST:VSANS:Globals:gLaptopMode 214 if(gLaptopMode == 1) 215 sc = 0.7 216 endif 212 217 213 218 // show a progress bar for filling the file catalog 214 219 Variable indefinite=0,useIgorDraw=1 215 NewPanel /N=ProgressPanel /W=(285 ,111,739,193)216 ValDisplay valdisp0,win=ProgressPanel,pos={ 18,32},size={342,18},limits={0,numitems,0},barmisc={0,0}220 NewPanel /N=ProgressPanel /W=(285*sc,111*sc,739*sc,193*sc) 221 ValDisplay valdisp0,win=ProgressPanel,pos={sc*18,32*sc},size={sc*342,18*sc},limits={0,numitems,0},barmisc={0,0} 217 222 ValDisplay valdisp0,win=ProgressPanel,value= _NUM:0 218 DrawText 20 ,24,"Refreshing file catalog... Please Wait..."223 DrawText 20*sc,24*sc,"Refreshing file catalog... Please Wait..." 219 224 220 225 if( indefinite ) … … 226 231 ValDisplay valdisp0,win=ProgressPanel,highColor=(49535,1000,1000) //(0,65535,0) 227 232 endif 228 Button bStop,win=ProgressPanel,pos={ 375,32},size={50,20},title="Stop"233 Button bStop,win=ProgressPanel,pos={sc*375,32*sc},size={sc*50,20*sc},title="Stop" 229 234 DoUpdate /W=ProgressPanel /E=1 // mark this as our progress window 230 235 … … 721 726 722 727 print "Creating CAT Sort-Panel..." 728 729 Variable sc = 1 730 731 NVAR gLaptopMode = root:Packages:NIST:VSANS:Globals:gLaptopMode 732 733 if(gLaptopMode == 1) 734 sc = 0.7 735 endif 723 736 724 737 //PauseUpdate 725 NewPanel /W=(600 ,360,790,730)/K=1 as "CAT - Sort Panel"738 NewPanel /W=(600*sc,360*sc,790*sc,730*sc)/K=1 as "CAT - Sort Panel" 726 739 DoWindow/C CatSortPanel 727 740 ModifyPanel fixedSize=1, cbRGB = (42919, 53970, 60909) 728 741 729 Button SortFilenamesButton, pos={ 25, 8}, size={140,24},proc=V_CatVSANSTable_SortProc,title="Filenames"730 Button SortLabelsButton, pos={ 25,38}, size={140,24},proc=V_CatVSANSTable_SortProc,title="Labels"731 Button SortDateAndTimeButton, pos={ 25,68}, size={140,24},proc=V_CatVSANSTable_SortProc,title="Date and Time"732 Button SortIntentButton, pos={ 25,98}, size={140,24},proc=V_CatVSANSTable_SortProc,title="Intent"733 Button SortPurposeButton, pos={ 25,128}, size={140,24},proc=V_CatVSANSTable_SortProc,title="Purpose"734 Button SortIDButton, pos={ 25,158}, size={140,24},proc=V_CatVSANSTable_SortProc,title="Group ID"735 Button SortLambdaButton, pos={ 25,188}, size={140,24},proc=V_CatVSANSTable_SortProc,title="Lambda"736 Button SortCountTimButton, pos={ 25,218}, size={140,24},proc=V_CatVSANSTable_SortProc,title="Count Time"737 Button SortSDDFButton, pos={ 25,248}, size={140,24},proc=V_CatVSANSTable_SortProc,title="SDD F"738 Button SortCountRateFButton, pos={ 25,278}, size={140,24},proc=V_CatVSANSTable_SortProc,title="Count Rate F"739 Button SortMonitorCountsButton, pos={ 25,308}, size={140,24},proc=V_CatVSANSTable_SortProc,title="Monitor Counts"740 Button SortTransmissionButton, pos={ 25,338}, size={140,24},proc=V_CatVSANSTable_SortProc,title="Transmission"742 Button SortFilenamesButton, pos={sc*25, 8*sc}, size={sc*140,24*sc},proc=V_CatVSANSTable_SortProc,title="Filenames" 743 Button SortLabelsButton, pos={sc*25,38*sc}, size={sc*140,24*sc},proc=V_CatVSANSTable_SortProc,title="Labels" 744 Button SortDateAndTimeButton, pos={sc*25,68*sc}, size={sc*140,24*sc},proc=V_CatVSANSTable_SortProc,title="Date and Time" 745 Button SortIntentButton, pos={sc*25,98*sc}, size={sc*140,24*sc},proc=V_CatVSANSTable_SortProc,title="Intent" 746 Button SortPurposeButton, pos={sc*25,128*sc}, size={sc*140,24*sc},proc=V_CatVSANSTable_SortProc,title="Purpose" 747 Button SortIDButton, pos={sc*25,158*sc}, size={sc*140,24*sc},proc=V_CatVSANSTable_SortProc,title="Group ID" 748 Button SortLambdaButton, pos={sc*25,188*sc}, size={sc*140,24*sc},proc=V_CatVSANSTable_SortProc,title="Lambda" 749 Button SortCountTimButton, pos={sc*25,218*sc}, size={sc*140,24*sc},proc=V_CatVSANSTable_SortProc,title="Count Time" 750 Button SortSDDFButton, pos={sc*25,248*sc}, size={sc*140,24*sc},proc=V_CatVSANSTable_SortProc,title="SDD F" 751 Button SortCountRateFButton, pos={sc*25,278*sc}, size={sc*140,24*sc},proc=V_CatVSANSTable_SortProc,title="Count Rate F" 752 Button SortMonitorCountsButton, pos={sc*25,308*sc}, size={sc*140,24*sc},proc=V_CatVSANSTable_SortProc,title="Monitor Counts" 753 Button SortTransmissionButton, pos={sc*25,338*sc}, size={sc*140,24*sc},proc=V_CatVSANSTable_SortProc,title="Transmission" 741 754 742 755 end -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_IQ_Annular.ipf
r1242 r1246 93 93 SetDataFolder $("root:Packages:NIST:VSANS:"+folderStr) 94 94 95 Variable sc = 1 96 97 NVAR gLaptopMode = root:Packages:NIST:VSANS:Globals:gLaptopMode 98 99 if(gLaptopMode == 1) 100 sc = 0.7 101 endif 102 95 103 DoWindow/F V_Phi_Graph 96 104 if(V_flag == 0) 97 Display /W=(35 ,45,572,419)/N=V_Phi_Graph /K=1105 Display /W=(35*sc,45*sc,572*sc,419*sc)/N=V_Phi_Graph /K=1 98 106 else 99 107 RemoveFromGraph/Z iPhiBin_qxqy_FLRTB -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_MainPanel.ipf
r1242 r1246 373 373 // 374 374 Window Main_VSANS_Panel() 375 Variable sc=1 376 377 if(root:Packages:NIST:VSANS:Globals:gLaptopMode == 1) 378 sc = 0.7 379 endif 380 375 381 PauseUpdate; Silent 1 // building window... 376 NewPanel /W=(500 ,60,924,320) /K=2as "VSANS Reduction Controls" + " " + num2str(kVSANSVersion)382 NewPanel /W=(500*sc,60*sc,924*sc,320*sc) /K=1 as "VSANS Reduction Controls" + " " + num2str(kVSANSVersion) 377 383 ModifyPanel cbRGB=(49694,61514,27679) 378 384 ModifyPanel fixedSize=1 379 385 ////// 380 386 //on main portion of panel 381 Button MainButtonA,pos={ 8,8},size={80,20},title="Pick Path",proc=V_PickPath_MainButtonProc387 Button MainButtonA,pos={sc*8,8*sc},size={sc*80,20*sc},title="Pick Path",proc=V_PickPath_MainButtonProc 382 388 Button MainButtonA,help={"Pick the local data folder that contains the VSANS data"} 383 Button MainButtonB,pos={ 100,8},size={90,20},proc=V_CatVShort_MainButtonProc,title="File Catalog"389 Button MainButtonB,pos={sc*100,8*sc},size={sc*90,20*sc},proc=V_CatVShort_MainButtonProc,title="File Catalog" 384 390 Button MainButtonB,help={"This will generate a condensed CATalog table of all files in a specified local folder"} 385 Button MainButtonC,pos={ 250,8},size={50,20},proc=V_HelpMainButtonProc,title="Help"391 Button MainButtonC,pos={sc*250,8*sc},size={sc*50,20*sc},proc=V_HelpMainButtonProc,title="Help" 386 392 Button MainButtonC,help={"Display the help file"} 387 Button MainButtonD,pos={ 320,8},size={80,20},proc=V_SR_OpenTracTicketPage,title="Feedback"393 Button MainButtonD,pos={sc*320,8*sc},size={sc*80,20*sc},proc=V_SR_OpenTracTicketPage,title="Feedback" 388 394 Button MainButtonD,help={"Submit bug reports or feature requests"} 389 395 390 TabControl MainTab,pos={ 7,49},size={410,202},tabLabel(0)="Raw Data",proc=V_MainTabProc396 TabControl MainTab,pos={sc*7,49*sc},size={sc*410,202*sc},tabLabel(0)="Raw Data",proc=V_MainTabProc 391 397 TabControl MainTab,tabLabel(1)="Reduction",tabLabel(2)="1-D Ops",tabLabel(3)="2-D Ops",tabLabel(4)="Misc Ops" 392 398 TabControl MainTab,value=0 … … 395 401 396 402 //on tab(0) - Raw Data - initially visible 397 Button MainButton_0a,pos={ 15,90},size={130,20},proc=V_DisplayMainButtonProc,title="Display Raw Data"403 Button MainButton_0a,pos={sc*15,90*sc},size={sc*130,20*sc},proc=V_DisplayMainButtonProc,title="Display Raw Data" 398 404 Button MainButton_0a,help={"Display will load and plot a single 2-D raw data file"} 399 Button MainButton_0b,pos={ 15,120},size={70,20},proc=V_PatchMainButtonProc,title="Patch"405 Button MainButton_0b,pos={sc*15,120*sc},size={sc*70,20*sc},proc=V_PatchMainButtonProc,title="Patch" 400 406 Button MainButton_0b,help={"Patch will update incorrect information in raw data headers"} 401 Button MainButton_0c,pos={ 15,150},size={110,20},proc=V_TransMainButtonProc,title="Transmission"407 Button MainButton_0c,pos={sc*15,150*sc},size={sc*110,20*sc},proc=V_TransMainButtonProc,title="Transmission" 402 408 Button MainButton_0c,help={"Shows the panel which allows calculation of sample transmissions and patching values into raw data headers"} 403 Button MainButton_0d,pos={ 15,180},size={130,20},proc=V_RealTime_MainButtonProc,title="RealTime Display"409 Button MainButton_0d,pos={sc*15,180*sc},size={sc*130,20*sc},proc=V_RealTime_MainButtonProc,title="RealTime Display" 404 410 Button MainButton_0d,help={"Shows the panel for control of the RealTime data display. Only used during data collection"} 405 Button MainButton_0e,pos={ 15,210},size={130,20},proc=V_CatSort_MainButtonProc,title="Sort Catalog"411 Button MainButton_0e,pos={sc*15,210*sc},size={sc*130,20*sc},proc=V_CatSort_MainButtonProc,title="Sort Catalog" 406 412 Button MainButton_0e,help={"Sort the Data Catalog, courtesy of ANSTO"} 407 Button MainButton_0f,pos={ 300,90},size={90,20},proc=V_DataTree_MainButtonProc,title="Data Tree"413 Button MainButton_0f,pos={sc*300,90*sc},size={sc*90,20*sc},proc=V_DataTree_MainButtonProc,title="Data Tree" 408 414 Button MainButton_0f,help={"Show the header and data tree"} 409 Button MainButton_0g,pos={ 170,180},size={110,20},proc=V_RTReduce_MainButtonProc,title="RT Reduction"415 Button MainButton_0g,pos={sc*170,180*sc},size={sc*110,20*sc},proc=V_RTReduce_MainButtonProc,title="RT Reduction" 410 416 Button MainButton_0g,help={"Reduce live (incomplete) data files during acquisition"} 411 Button MainButton_0h,pos={ 170,90},size={90,20},proc=V_Patch_XY_MainButtonProc,title="Patch XY"417 Button MainButton_0h,pos={sc*170,90*sc},size={sc*90,20*sc},proc=V_Patch_XY_MainButtonProc,title="Patch XY" 412 418 Button MainButton_0h,help={"Easy patching of XY beam center to multiple files"} 413 Button MainButton_0i,pos={ 170,120},size={110,20},proc=V_Patch_DeadTime_MainButtonProc,title="Patch DeadTime"419 Button MainButton_0i,pos={sc*170,120*sc},size={sc*110,20*sc},proc=V_Patch_DeadTime_MainButtonProc,title="Patch DeadTime" 414 420 Button MainButton_0i,help={"Easy patching of dead time tables to multiple files"} 415 Button MainButton_0j,pos={ 170,150},size={90,20},proc=V_Patch_Calib_MainButtonProc,title="Patch Calib"421 Button MainButton_0j,pos={sc*170,150*sc},size={sc*90,20*sc},proc=V_Patch_Calib_MainButtonProc,title="Patch Calib" 416 422 Button MainButton_0j,help={"Easy patching of nonlinear calibration tables to multiple files"} 417 423 418 424 //on tab(1) - Reduction 419 Button MainButton_1a,pos={ 15,90},size={110,20},proc=V_BuildProtocol_MainButtonProc,title="Build Protocol"425 Button MainButton_1a,pos={sc*15,90*sc},size={sc*110,20*sc},proc=V_BuildProtocol_MainButtonProc,title="Build Protocol" 420 426 Button MainButton_1a,help={"Shows a panel where the CATalog window is used as input for creating a protocol. Can also be used for standard reductions"} 421 // Button MainButton_1b,pos={ 15,120},size={110,20},proc=V_ReduceAFile_MainButtonProc,title="Reduce a File"427 // Button MainButton_1b,pos={sc*15,120*sc},size={sc*110,20*sc},proc=V_ReduceAFile_MainButtonProc,title="Reduce a File" 422 428 // Button MainButton_1b,help={"Presents a questionnare for creating a reduction protocol, then reduces a single file"} 423 Button MainButton_1c,pos={ 15,150},size={160,20},proc=V_ReduceMultiple_MainButtonProc,title="Reduce Multiple Files"429 Button MainButton_1c,pos={sc*15,150*sc},size={sc*160,20*sc},proc=V_ReduceMultiple_MainButtonProc,title="Reduce Multiple Files" 424 430 Button MainButton_1c,help={"Use for reducing multiple raw datasets after protocol(s) have been created"} 425 // Button MainButton_1d,pos={ 15,180},size={110,20},proc=V_ShowCatShort_MainButtonProc,title="Show CAT Table"431 // Button MainButton_1d,pos={sc*15,180*sc},size={sc*110,20*sc},proc=V_ShowCatShort_MainButtonProc,title="Show CAT Table" 426 432 // Button MainButton_1d,help={"This button will bring the CATalog window to the front, if it exists"} 427 433 Button MainButton_1a,disable=1 … … 431 437 432 438 //on tab(2) - 1-D operations 433 Button MainButton_2a,pos={ 15,90},size={60,20},proc=V_Plot1D_MainButtonProc,title="Plot"439 Button MainButton_2a,pos={sc*15,90*sc},size={sc*60,20*sc},proc=V_Plot1D_MainButtonProc,title="Plot" 434 440 Button MainButton_2a,help={"Loads and plots a 1-D dataset in the format expected by \"FIT\""} 435 // Button MainButton_2b,pos={ 15,120},size={60,20},proc=V_Sort1D_MainButtonProc,title="Sort"441 // Button MainButton_2b,pos={sc*15,120*sc},size={sc*60,20*sc},proc=V_Sort1D_MainButtonProc,title="Sort" 436 442 // Button MainButton_2b,help={"Sorts and combines 2 or 3 separate 1-D datasets into a single file. Use \"Plot\" button to import 1-D data files"} 437 Button MainButton_2c,pos={ 15,150},size={60,20},proc=V_Fit1D_MainButtonProc,title="FIT"443 Button MainButton_2c,pos={sc*15,150*sc},size={sc*60,20*sc},proc=V_Fit1D_MainButtonProc,title="FIT" 438 444 Button MainButton_2c,help={"Shows panel for performing a variety of linearized fits to 1-D data files. Use \"Plot\" button to import 1-D data files"} 439 // Button MainButton_2d,pos={ 15,180},size={60,20},proc=V_FITRPA_MainButtonProc,title="FIT/RPA"445 // Button MainButton_2d,pos={sc*15,180*sc},size={sc*60,20*sc},proc=V_FITRPA_MainButtonProc,title="FIT/RPA" 440 446 // Button MainButton_2d,help={"Shows panel for performing a fit to a polymer standard."} 441 // Button MainButton_2e,pos={ 120,90},size={90,20},proc=V_Subtract1D_MainButtonProc,title="Subtract 1D"447 // Button MainButton_2e,pos={sc*120,90*sc},size={sc*90,20*sc},proc=V_Subtract1D_MainButtonProc,title="Subtract 1D" 442 448 // Button MainButton_2e,help={"Shows panel for subtracting two 1-D data sets"} 443 Button MainButton_2e,pos={ 120,90},size={110,20},proc=V_Arithmetic1D_MainButtonProc,title="1D Arithmetic"449 Button MainButton_2e,pos={sc*120,90*sc},size={sc*110,20*sc},proc=V_Arithmetic1D_MainButtonProc,title="1D Arithmetic" 444 450 Button MainButton_2e,help={"Shows panel for doing arithmetic on 1D data sets"} 445 Button MainButton_2f,pos={ 120,120},size={130,20},proc=V_Combine1D_MainButtonProc,title="Combine 1D Files"451 Button MainButton_2f,pos={sc*120,120*sc},size={sc*130,20*sc},proc=V_Combine1D_MainButtonProc,title="Combine 1D Files" 446 452 Button MainButton_2f,help={"Shows panel for selecting points to trim before combining files"} 447 453 Button MainButton_2a,disable=1 … … 455 461 456 462 //on tab(3) - 2-D Operations 457 Button MainButton_3a,pos={ 15,90},size={90,20},proc=V_DisplayInterm_MainButtonProc,title="Display 2D"463 Button MainButton_3a,pos={sc*15,90*sc},size={sc*90,20*sc},proc=V_DisplayInterm_MainButtonProc,title="Display 2D" 458 464 Button MainButton_3a,help={"Display will plot a 2-D work data file that has previously been created during data reduction"} 459 Button MainButton_3b,pos={ 15,120},size={90,20},title="Draw Mask",proc=V_DrawMask_MainButtonProc465 Button MainButton_3b,pos={sc*15,120*sc},size={sc*90,20*sc},title="Draw Mask",proc=V_DrawMask_MainButtonProc 460 466 Button MainButton_3b,help={"Draw a mask file and save it."} 461 Button MainButton_3c,pos={ 15,150},size={90,20},proc=V_ReadMask_MainButtonProc,title="Read Mask"467 Button MainButton_3c,pos={sc*15,150*sc},size={sc*90,20*sc},proc=V_ReadMask_MainButtonProc,title="Read Mask" 462 468 Button MainButton_3c,help={"Reads a mask file into the proper work folder"} 463 // Button MainButton_3d,pos={ 15,180},size={100,20},title="Tile RAW 2D",proc=V_ShowTilePanel_MainButtonProc469 // Button MainButton_3d,pos={sc*15,180*sc},size={sc*100,20*sc},title="Tile RAW 2D",proc=V_ShowTilePanel_MainButtonProc 464 470 // Button MainButton_3d,help={"Adds selected RAW data files to a layout."} 465 Button MainButton_3e,pos={ 150,90},size={100,20},title="Copy Work",proc=V_CopyWork_MainButtonProc471 Button MainButton_3e,pos={sc*150,90*sc},size={sc*100,20*sc},title="Copy Work",proc=V_CopyWork_MainButtonProc 466 472 Button MainButton_3e,help={"Copies WORK data from specified folder to destination folder."} 467 // Button MainButton_3f,pos={ 150,120},size={110,20},title="WorkFile Math",proc=V_WorkMath_MainButtonProc473 // Button MainButton_3f,pos={sc*150,120*sc},size={sc*110,20*sc},title="WorkFile Math",proc=V_WorkMath_MainButtonProc 468 474 // Button MainButton_3f,help={"Perfom simple math operations on workfile data"} 469 Button MainButton_3g,pos={ 150,150},size={100,20},title="Event Data",proc=V_Event_MainButtonProc475 Button MainButton_3g,pos={sc*150,150*sc},size={sc*100,20*sc},title="Event Data",proc=V_Event_MainButtonProc 470 476 Button MainButton_3g,help={"Manipulate VSANS Event Mode data"} 471 Button MainButton_3h,pos={ 150,180},size={140,20},title="Event Reduction",proc=V_Event_MultReduceButtonProc477 Button MainButton_3h,pos={sc*150,180*sc},size={sc*140,20*sc},title="Event Reduction",proc=V_Event_MultReduceButtonProc 472 478 Button MainButton_3h,help={"Reduce VSANS Event Mode data"} 473 479 … … 483 489 484 490 //on tab(4) - Miscellaneous operations 485 Button MainButton_4a,pos={ 15,90},size={80,20},proc=V_Draw3D_MainButtonProc,title="3D Display"491 Button MainButton_4a,pos={sc*15,90*sc},size={sc*80,20*sc},proc=V_Draw3D_MainButtonProc,title="3D Display" 486 492 Button MainButton_4a,help={"Plots a 3-D surface of the selected file type"} 487 // Button MainButton_4b,pos={ 15,120},size={120,20},proc=V_ShowSchematic_MainButtonProc,title="Show Schematic"493 // Button MainButton_4b,pos={sc*15,120*sc},size={sc*120,20*sc},proc=V_ShowSchematic_MainButtonProc,title="Show Schematic" 488 494 // Button MainButton_4b,help={"Use this to show a schematic of the data reduction process for a selected sample file and reduction protocol"} 489 // Button MainButton_4c,pos={ 15,150},size={80,20},proc=V_ShowAvePanel_MainButtonProc,title="Average"495 // Button MainButton_4c,pos={sc*15,150*sc},size={sc*80,20*sc},proc=V_ShowAvePanel_MainButtonProc,title="Average" 490 496 // Button MainButton_4c,help={"Shows a panel for interactive selection of the 1-D averaging step"} 491 // Button MainButton_4d,pos={ 15,180},size={110,20},proc=V_CatShort_MainButtonProc,title="CAT/Notebook"497 // Button MainButton_4d,pos={sc*15,180*sc},size={sc*110,20*sc},proc=V_CatShort_MainButtonProc,title="CAT/Notebook" 492 498 // Button MainButton_4d,help={"This will generate a CATalog notebook of all files in a specified local folder"} 493 Button MainButton_4e,pos={ 180,90},size={130,20},proc=V_NonLinTubes_MainButtonProc,title="Fit NonLinear Tubes"499 Button MainButton_4e,pos={sc*180,90*sc},size={sc*130,20*sc},proc=V_NonLinTubes_MainButtonProc,title="Fit NonLinear Tubes" 494 500 Button MainButton_4e,help={""} 495 Button MainButton_4f,pos={ 180,120},size={130,20},proc=V_PRODIV_MainButtonProc,title="Make DIV file"501 Button MainButton_4f,pos={sc*180,120*sc},size={sc*130,20*sc},proc=V_PRODIV_MainButtonProc,title="Make DIV file" 496 502 Button MainButton_4f,help={"Displays panels and outlines the steps for generating a detector sensitivity file"} 497 // Button MainButton_4g,pos={ 180,150},size={130,20},proc=V_Raw2ASCII_MainButtonProc,title="RAW ASCII Export"503 // Button MainButton_4g,pos={sc*180,150*sc},size={sc*130,20*sc},proc=V_Raw2ASCII_MainButtonProc,title="RAW ASCII Export" 498 504 // Button MainButton_4g,help={"Exports selected RAW (2D) data file(s) as ASCII, either as pixel values or I(Qx,Qy)"} 499 Button MainButton_4h,pos={ 180,180},size={130,20},proc=V_Preferences_MainButtonProc,title="Preferences"505 Button MainButton_4h,pos={sc*180,180*sc},size={sc*130,20*sc},proc=V_Preferences_MainButtonProc,title="Preferences" 500 506 Button MainButton_4h,help={"Sets user preferences for selected parameters"} 501 507 -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_Marquee_Operations.ipf
r1243 r1246 379 379 380 380 if(cmpstr(detStr,"FR") == 0) 381 Print "Reference Y-Center is corrected for tube #7 zero position"381 Print "Reference Y-Center is corrected for FR tube #7 zero position" 382 382 383 383 yCorrection = 61.70 - yCorrection 384 384 Print "yCorrection (pix) = ",yCorrection 385 385 Print "yCorrection (cm) = ",yCorrection*yPixSize 386 Print "FRONT Reference X-center (cm) = ",x_mm/10387 Print "FRONT Reference Y-center (cm) = ",y_mm/10 + yCorrection*yPixSize388 386 xRef = x_mm/10 389 387 yRef = y_mm/10 + yCorrection*yPixSize 388 Print "FRONT Reference X-center (cm) = ",xRef 389 Print "FRONT Reference Y-center (cm) = ",yRef 390 390 391 endif 391 392 392 393 if(cmpstr(detStr,"MR") == 0) 393 Print "Reference Y-Center is corrected for tube #10 zero position"394 Print "Reference Y-Center is corrected for MR tube #10 zero position" 394 395 395 396 yCorrection = 61.94 - yCorrection 396 397 Print "yCorrection (pix) = ",yCorrection 397 398 Print "yCorrection (cm) = ",yCorrection*yPixSize 398 Print "MIDDLE Reference X-center (cm) = ",x_mm/10399 Print "MIDDLE Reference Y-center (cm) = ",y_mm/10 + yCorrection*yPixSize400 399 xRef = x_mm/10 401 400 yRef = y_mm/10 + yCorrection*yPixSize 401 Print "MIDDLE Reference X-center (cm) = ",xRef 402 Print "MIDDLE Reference Y-center (cm) = ",yRef 403 402 404 endif 403 405 404 406 // if measured on the LEFT panel, convert to the RIGHT coordinates for the reference value 405 407 // these corrections are exactly the opposite (subtract, not add) of what is done in V_fDeriveBeamCenters(xFR,yFR,xMR,yMR) 408 // since the lateral scans to determine the relative centers were done at the same time 409 // the pixel values for the zero are on the same y-level, set by the beam height 410 // 406 411 if(cmpstr(detStr,"FL") == 0) 407 Print "FRONT Reference X-center (cm) = ",x_mm/10 - kBCtrOffset_FL_x // NEW Dec 2018 values 408 Print "FRONT Reference Y-center (cm) = ",y_mm/10 - kBCtrOffset_FL_y 412 Print "Reference Y-Center is corrected for FR tube #7 zero position" 413 414 yCorrection = 61.70 - yCorrection 415 Print "yCorrection (pix) = ",yCorrection 416 Print "yCorrection (cm) = ",yCorrection*yPixSize 409 417 xRef = x_mm/10 - kBCtrOffset_FL_x 410 yRef = y_mm/10 - kBCtrOffset_FL_y 418 yRef = y_mm/10 - kBCtrOffset_FL_y + yCorrection*yPixSize 419 Print "FRONT Reference X-center (cm) = ",xRef // NEW Dec 2018 values 420 Print "FRONT Reference Y-center (cm) = ",yRef 421 411 422 endif 412 423 413 424 if(cmpstr(detStr,"ML") == 0) 414 Print "MIDDLE Reference X-center (cm) = ",x_mm/10 - kBCtrOffset_ML_x 415 Print "MIDDLE Reference Y-center (cm) = ",y_mm/10 - kBCtrOffset_ML_y 425 Print "Reference Y-Center is corrected for MR tube #10 zero position" 426 427 yCorrection = 61.94 - yCorrection 428 Print "yCorrection (pix) = ",yCorrection 429 Print "yCorrection (cm) = ",yCorrection*yPixSize 416 430 xRef = x_mm/10 - kBCtrOffset_ML_x 417 yRef = y_mm/10 - kBCtrOffset_ML_y 431 yRef = y_mm/10 - kBCtrOffset_ML_y + yCorrection*yPixSize 432 Print "MIDDLE Reference X-center (cm) = ",xRef 433 Print "MIDDLE Reference Y-center (cm) = ",yRef 434 418 435 endif 419 436 endif -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_MaskUtils.ipf
r1243 r1246 118 118 // 119 119 Proc V_MaskEditorPanel() 120 Variable sc = 1 121 122 if(root:Packages:NIST:VSANS:Globals:gLaptopMode == 1) 123 sc = 0.7 124 endif 125 120 126 PauseUpdate; Silent 1 // building window... 121 127 122 Display /W=(662 ,418,1300,960)/N=MaskEditPanel /K=1128 Display /W=(662*sc,418*sc,1300*sc,960*sc)/N=MaskEditPanel /K=1 123 129 124 130 ShowTools rect 125 ControlBar 100 126 127 PopupMenu popup_0,pos={ 18,40},size={109,20},proc=V_SetMaskPanelPopMenuProc,title="Detector Panel"131 ControlBar 100*sc 132 133 PopupMenu popup_0,pos={sc*18,40*sc},size={sc*109,20*sc},proc=V_SetMaskPanelPopMenuProc,title="Detector Panel" 128 134 PopupMenu popup_0,mode=1,popvalue="FL",value= #"\"FL;FR;FT;FB;ML;MR;MT;MB;B;\"" 129 PopupMenu popup_2,pos={ 18,10},size={109,20},title="Data Source"//,proc=SetFldrPopMenuProc135 PopupMenu popup_2,pos={sc*18,10*sc},size={sc*109,20*sc},title="Data Source"//,proc=SetFldrPopMenuProc 130 136 PopupMenu popup_2,mode=1,popvalue="RAW",value= #"\"RAW;SAM;ABS;VCALC;\"" 131 137 132 SetVariable setvar0,pos={ 226,32},size={112,23},title="tube number"138 SetVariable setvar0,pos={sc*226,32*sc},size={sc*112,23*sc},title="tube number" 133 139 SetVariable setvar0,limits={0,127,1},value=root:Packages:NIST:VSANS:Globals:Mask:gMaskTube 134 Button button_0,pos={ 226,58},size={50.00,20.00},proc=V_AddToMaskButtonProc,title="Add"135 Button button_1,pos={ 288,58},size={50.00,20.00},proc=V_RemoveFromMaskButtonProc,title="Del"136 Button button_2,pos={ 496,41},size={90.00,20.00},proc=V_ToggleMaskButtonProc,title="Toggle"137 Button button_3,pos={ 506,66},size={80.00,20.00},proc=V_SaveMaskButtonProc,title="Save"138 CheckBox check_0,pos={ 174,35},size={37.00,15.00},proc=V_DrawMaskRadioCheckProc,title="Row"140 Button button_0,pos={sc*226,58*sc},size={sc*50.00,20.00*sc},proc=V_AddToMaskButtonProc,title="Add" 141 Button button_1,pos={sc*288,58*sc},size={sc*50.00,20.00*sc},proc=V_RemoveFromMaskButtonProc,title="Del" 142 Button button_2,pos={sc*496,41*sc},size={sc*90.00,20.00*sc},proc=V_ToggleMaskButtonProc,title="Toggle" 143 Button button_3,pos={sc*506,66*sc},size={sc*80.00,20.00*sc},proc=V_SaveMaskButtonProc,title="Save" 144 CheckBox check_0,pos={sc*174,35*sc},size={sc*37.00,15.00*sc},proc=V_DrawMaskRadioCheckProc,title="Row" 139 145 CheckBox check_0,value= 0,mode=1 140 CheckBox check_1,pos={ 174,58},size={32.00,15.00},proc=V_DrawMaskRadioCheckProc,title="Col"146 CheckBox check_1,pos={sc*174,58*sc},size={sc*32.00,15.00*sc},proc=V_DrawMaskRadioCheckProc,title="Col" 141 147 CheckBox check_1,value= 1,mode=1 142 148 143 Button button_5,pos={ 18,70.00},size={70.00,20.00},proc=V_MaskToolsButton,title="Tools"144 Button button_6,pos={ 380,33},size={90.00,20.00},proc=V_AddShapeToMaskButtonProc,title="Add Shape"145 Button button_7,pos={ 380,58},size={90.00,20.00},proc=V_AddShapeToMaskButtonProc,title="Del Shape"146 Button button_8,pos={ 556.00,14.00},size={30.00,20.00},proc=V_DrawMaskHelpButtonProc,title="?"147 148 GroupBox group0,pos={ 163.00,5.00},size={188.00,90.00},title="Mask Tubes"149 GroupBox group1,pos={ 365.00,5.00},size={122.00,90.00},title="Mask Shapes"149 Button button_5,pos={sc*18,70.00*sc},size={sc*70.00,20.00*sc},proc=V_MaskToolsButton,title="Tools" 150 Button button_6,pos={sc*380,33*sc},size={sc*90.00,20.00*sc},proc=V_AddShapeToMaskButtonProc,title="Add Shape" 151 Button button_7,pos={sc*380,58*sc},size={sc*90.00,20.00*sc},proc=V_AddShapeToMaskButtonProc,title="Del Shape" 152 Button button_8,pos={sc*556.00,14.00*sc},size={sc*30.00,20.00*sc},proc=V_DrawMaskHelpButtonProc,title="?" 153 154 GroupBox group0,pos={sc*163.00,5.00*sc},size={sc*188.00,90.00*sc},title="Mask Tubes" 155 GroupBox group1,pos={sc*365.00,5.00*sc},size={sc*122.00,90.00*sc},title="Mask Shapes" 150 156 151 157 SetWindow MaskEditPanel, hook(MyHook)=V_MaskWindowHook … … 1117 1123 1118 1124 Proc V_Display_Det_Panels() 1125 1126 Variable sc = 1 1127 1128 if(root:Packages:NIST:VSANS:Globals:gLaptopMode == 1) 1129 sc = 0.7 1130 endif 1131 1119 1132 PauseUpdate; Silent 1 // building window... 1120 NewPanel /W=(720 ,45,1500,570)/N=VSANS_Det_Panels/K=11133 NewPanel /W=(720*sc,45*sc,1500*sc,570*sc)/N=VSANS_Det_Panels/K=1 1121 1134 DoWindow/C VSANS_Det_Panels 1122 1135 // ModifyPanel fixedSize=1,noEdit =1 1123 1136 1124 1137 1125 PopupMenu popup0,pos={ 15.00,10.00},size={77.00,23.00},proc=V_PickCarriagePopMenuProc,title="Carriage"1138 PopupMenu popup0,pos={sc*15.00,10.00*sc},size={sc*77.00,23.00*sc},proc=V_PickCarriagePopMenuProc,title="Carriage" 1126 1139 PopupMenu popup0,mode=1,value= #"\"F;M;B;\"" 1127 PopupMenu popup1,pos={ 100.00,10.00},size={68.00,23.00},proc=V_PickFolderPopMenuProc,title="Folder"1140 PopupMenu popup1,pos={sc*100.00,10.00*sc},size={sc*68.00,23.00*sc},proc=V_PickFolderPopMenuProc,title="Folder" 1128 1141 PopupMenu popup1,mode=1,popvalue="RAW",value= #"\"SAM;EMP;BGD;DIV;COR;CAL;RAW;ABS;STO;SUB;DRK;MSK;ADJ;VCALC;\"" 1129 1142 // PopupMenu popup1,mode=1,popvalue="RAW",value= #"\"SAM;EMP;BGD;DIV;COR;CAL;RAW;ABS;STO;SUB;DRK;MSK;ADJ;VCALC;\"" 1130 PopupMenu popup2,pos={ 200.00,10.00},size={83.00,23.00},title="Bin Type"//,proc=V_DummyPopMenuProc1143 PopupMenu popup2,pos={sc*200.00,10.00*sc},size={sc*83.00,23.00*sc},title="Bin Type"//,proc=V_DummyPopMenuProc 1131 1144 PopupMenu popup2,mode=1,value= ksBinTypeStr 1132 PopupMenu popup3,pos={ 350,10.00},size={83.00,23.00},title="Average Type"//,proc=V_DummyPopMenuProc1145 PopupMenu popup3,pos={sc*350,10.00*sc},size={sc*83.00,23.00*sc},title="Average Type"//,proc=V_DummyPopMenuProc 1133 1146 PopupMenu popup3,mode=1,value= #"\"Circular;Sector;Annular;\"" 1134 // Button button0,pos={ 520.00,10.00},size={110.00,20.00},proc=V_UpdatePanelsButtonProc,title="Update Display"1135 Button button1,pos={ 520.00,40.00},size={100.00,20.00},proc=V_ToggleFourMaskButtonProc,title="Toggle Mask"1136 Button button2,pos={ 350.00,40.00},size={120.00,20.00},proc=V_ShowAvgRangeButtonProc,title="Show Avg Range"1137 Button button3,pos={ 350.00,70.00},size={100.00,20.00},proc=V_DoPanelAvgButtonProc,title="Do Average"1138 Button button4,pos={ 720.00,10.00},size={25.00,20.00},proc=V_AvgPanelHelpButtonProc,title="?"1139 1140 SetVariable setvar0,pos={ 20,40},size={160,23},title="Annulus q-center (A)"1147 // Button button0,pos={sc*520.00,10.00*sc},size={sc*110.00,20.00*sc},proc=V_UpdatePanelsButtonProc,title="Update Display" 1148 Button button1,pos={sc*520.00,40.00*sc},size={sc*100.00,20.00*sc},proc=V_ToggleFourMaskButtonProc,title="Toggle Mask" 1149 Button button2,pos={sc*350.00,40.00*sc},size={sc*120.00,20.00*sc},proc=V_ShowAvgRangeButtonProc,title="Show Avg Range" 1150 Button button3,pos={sc*350.00,70.00*sc},size={sc*100.00,20.00*sc},proc=V_DoPanelAvgButtonProc,title="Do Average" 1151 Button button4,pos={sc*720.00,10.00*sc},size={sc*25.00,20.00*sc},proc=V_AvgPanelHelpButtonProc,title="?" 1152 1153 SetVariable setvar0,pos={sc*20,40*sc},size={sc*160,23*sc},title="Annulus q-center (A)" 1141 1154 SetVariable setvar0,limits={0,1,0.001},value=root:Packages:NIST:VSANS:Globals:Mask:gAnnularQCtr 1142 SetVariable setvar1,pos={ 20,70},size={160,23},title="Annulus (+/-) q (A)"1155 SetVariable setvar1,pos={sc*20,70*sc},size={sc*160,23*sc},title="Annulus (+/-) q (A)" 1143 1156 SetVariable setvar1,limits={0,1,0.001},value=root:Packages:NIST:VSANS:Globals:Mask:gAnnularDQ 1144 SetVariable setvar2,pos={ 190,40},size={150,23},title="Sector Angle (deg)"1157 SetVariable setvar2,pos={sc*190,40*sc},size={sc*150,23*sc},title="Sector Angle (deg)" 1145 1158 SetVariable setvar2,limits={-90,90,1},value=root:Packages:NIST:VSANS:Globals:Mask:gSectorAngle 1146 SetVariable setvar3,pos={ 190,70},size={150,23},title="Sector (+/-) (deg)"1159 SetVariable setvar3,pos={sc*190,70*sc},size={sc*150,23*sc},title="Sector (+/-) (deg)" 1147 1160 SetVariable setvar3,limits={0,90,1},value=root:Packages:NIST:VSANS:Globals:Mask:gSectorDQ 1148 1161 1149 PopupMenu popup4,pos={ 200,100},size={90,23.00},title="Sector Side(s)"//,proc=V_DummyPopMenuProc1162 PopupMenu popup4,pos={sc*200,100*sc},size={sc*90,23.00*sc},title="Sector Side(s)"//,proc=V_DummyPopMenuProc 1150 1163 PopupMenu popup4,mode=1,value= #"\"both;left;right;\"" 1151 1164 … … 1159 1172 1160 1173 // Display/W=(745,45,945,425)/HOST=# 1161 Display/W=(10 ,45+80,210,425+80)/HOST=#1174 Display/W=(10*sc,(45+80)*sc,210*sc,(425+80)*sc)/HOST=# 1162 1175 // root:Packages:NIST:VSANS:RAW:entry:instrument:detector_FL:data 1163 1176 AppendImage/T/G=1 tmpLR // /G=1 flag prevents interpretation as RGB so 3, 4 slices display correctly … … 1178 1191 1179 1192 // Display/W=(1300,45,1500,425)/HOST=# 1180 Display/W=(565 ,45+80,765,425+80)/HOST=#1193 Display/W=(565*sc,(45+80)*sc,765*sc,(425+80)*sc)/HOST=# 1181 1194 AppendImage/T/G=1 tmpLR // /G=1 flag prevents interpretation as RGB so 3, 4 slices display correctly 1182 1195 ModifyImage tmpLR ctab= {*,*,ColdWarm,0} … … 1195 1208 1196 1209 // Display/W=(945,45,1300,235)/HOST=# 1197 Display/W=(210 ,45+80,565,235+80)/HOST=#1210 Display/W=(210*sc,(45+80)*sc,565*sc,(235+80)*sc)/HOST=# 1198 1211 AppendImage/T/G=1 tmpTB // /G=1 flag prevents interpretation as RGB so 3, 4 slices display correctly 1199 1212 ModifyImage tmpTB ctab= {*,*,ColdWarm,0} … … 1212 1225 1213 1226 // Display/W=(945,235,1300,425)/HOST=# 1214 Display/W=(210 ,235+80,565,425+80)/HOST=#1227 Display/W=(210*sc,(235+80)*sc,565*sc,(425+80)*sc)/HOST=# 1215 1228 AppendImage/T/G=1 tmpTB // /G=1 flag prevents interpretation as RGB so 3, 4 slices display correctly 1216 1229 ModifyImage tmpTB ctab= {*,*,ColdWarm,0} … … 1237 1250 // 1238 1251 Function V_UpdateFourPanelDisp() 1252 1253 1254 Variable sc = 1 1255 1256 NVAR gLaptopMode = root:Packages:NIST:VSANS:Globals:gLaptopMode 1257 1258 if(gLaptopMode == 1) 1259 sc = 0.7 1260 endif 1239 1261 1240 1262 ControlInfo/W=VSANS_Det_Panels popup0 -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_MultipleReduce.ipf
r1242 r1246 62 62 // 63 63 Window V_Multiple_Reduce_Panel() 64 65 Variable sc = 1 66 67 if(root:Packages:NIST:VSANS:Globals:gLaptopMode == 1) 68 sc = 0.7 69 endif 70 64 71 PauseUpdate; Silent 1 // building window... 65 NewPanel /W=(535 ,72,951,228) /K=1 as "Multiple VSANS File Reduction"72 NewPanel /W=(535*sc,72*sc,951*sc,228*sc) /K=1 as "Multiple VSANS File Reduction" 66 73 ModifyPanel cbRGB=(64535,49151,48490) 67 74 ModifyPanel fixedSize=1 68 75 SetDrawLayer UserBack 69 DrawLine 7 ,30,422,3070 SetVariable PathDisplay,pos={ 77,7},size={300,13},title="Path"76 DrawLine 7*sc,30*sc,422*sc,30*sc 77 SetVariable PathDisplay,pos={sc*77,7*sc},size={sc*300,13*sc},title="Path" 71 78 SetVariable PathDisplay,help={"This is the path to the folder that will be used to find the SANS data while reducing. If no files appear in the popup, make sure that this folder is set correctly"} 72 79 SetVariable PathDisplay,limits={-Inf,Inf,0},value= root:Packages:NIST:VSANS:Globals:MRED:gCatPathStr 73 Button PathButton,pos={ 3,3},size={70,20},proc=V_PickMRPathButton,title="Pick Path"80 Button PathButton,pos={sc*3,3*sc},size={sc*70,20*sc},proc=V_PickMRPathButton,title="Pick Path" 74 81 Button PathButton,help={"Select the folder containing the raw SANS data files"} 75 Button helpButton,pos={ 385,3},size={25,20},proc=V_ShowMRHelp,title="?"82 Button helpButton,pos={sc*385,3*sc},size={sc*25,20*sc},proc=V_ShowMRHelp,title="?" 76 83 Button helpButton,help={"Show the help file for reducing multiple files using the same protocol"} 77 PopupMenu MRFilesPopup,pos={ 3,72},size={167,19},proc=V_MRedPopMenuProc,title="File(s) to Reduce"84 PopupMenu MRFilesPopup,pos={sc*3,72*sc},size={sc*167,19*sc},proc=V_MRedPopMenuProc,title="File(s) to Reduce" 78 85 PopupMenu MRFilesPopup,help={"The displayed file is the one that will be reduced. The entire list will be reduced if \"Reduce All..\" is selected. \r If no items, or the wrong items appear, click on the popup to refresh."} 79 86 PopupMenu MRFilesPopup,mode=1,popvalue="none",value= #"root:Packages:NIST:VSANS:Globals:MRED:gMRedList" 80 SetVariable MRList,pos={ 3,48},size={350,13},proc=V_FileNumberListProc,title="File number list: "87 SetVariable MRList,pos={sc*3,48*sc},size={sc*350,13*sc},proc=V_FileNumberListProc,title="File number list: " 81 88 SetVariable MRList,help={"Enter a comma delimited list of file numbers to reduce. Ranges can be entered using a dash."} 82 89 SetVariable MRList,limits={-Inf,Inf,1},value= root:Packages:NIST:VSANS:Globals:MRED:gFileNumList 83 Button ReduceAllButton,pos={ 3,128},size={180,20},proc=V_ReduceAllPopupFiles,title="Reduce All Files in Popup"90 Button ReduceAllButton,pos={sc*3,128*sc},size={sc*180,20*sc},proc=V_ReduceAllPopupFiles,title="Reduce All Files in Popup" 84 91 Button ReduceAllButton,help={"This will reduce ALL of the files in the popup list, not just the top file."} 85 // Button ReduceOneButton,pos={ 3,98},size={180,20},proc=V_ReduceTopPopupFile,title="Reduce Top File in Popup"92 // Button ReduceOneButton,pos={sc*3,98*sc},size={sc*180,20*sc},proc=V_ReduceTopPopupFile,title="Reduce Top File in Popup" 86 93 // Button ReduceOneButton,help={"This will reduce TOP files in the popup list, not all of the files."} 87 Button DoneButton,pos={ 290,128},size={110,20},proc=V_MRDoneButtonProc,title="Done Reducing"94 Button DoneButton,pos={sc*290,128*sc},size={sc*110,20*sc},proc=V_MRDoneButtonProc,title="Done Reducing" 88 95 Button DoneButton,help={"When done reducing files, this will close this control panel."} 89 Button cat_short,pos={ 310,72},size={90,20},proc=V_ShowCatShort_MRED,title="File Catalog"96 Button cat_short,pos={sc*310,72*sc},size={sc*90,20*sc},proc=V_ShowCatShort_MRED,title="File Catalog" 90 97 Button cat_short,help={"Use this button to generate a table with file header information. Very useful for identifying files."} 91 // Button show_cat_short,pos={ 280,98},size={120,20},proc=ShowCatShort_MRED,title="Show File Catalog"98 // Button show_cat_short,pos={sc*280,98*sc},size={sc*120,20*sc},proc=ShowCatShort_MRED,title="Show File Catalog" 92 99 // Button show_cat_short,help={"Use this button to bring the File Catalog window to the front."} 93 // Button sddList,pos={ 280,72},size={120,20},proc=ScatteringAtSDDTableButton,title="Files at SDD List"100 // Button sddList,pos={sc*280,72*sc},size={sc*120,20*sc},proc=ScatteringAtSDDTableButton,title="Files at SDD List" 94 101 // Button sddList,help={"Use this button to generate a table of scattering files at a given ample to detector distance."} 95 // Button acceptList,pos={ 280,98},size={120,20},proc=AcceptMREDList,title="Accept List"102 // Button acceptList,pos={sc*280,98*sc},size={sc*120,20*sc},proc=AcceptMREDList,title="Accept List" 96 103 // Button acceptList,help={"Accept the list of files to reduce."} 97 PopupMenu MRProto_pop,pos={ 3,98},size={119,19},proc=V_MRProtoPopMenuProc,title="Protocol "104 PopupMenu MRProto_pop,pos={sc*3,98*sc},size={sc*119,19*sc},proc=V_MRProtoPopMenuProc,title="Protocol " 98 105 PopupMenu MRProto_pop,help={"All of the data files in the popup will be reduced using this protocol"} 99 106 PopupMenu MRProto_pop,mode=1,popvalue="none",value= #"root:Packages:NIST:VSANS:Globals:MRED:gMRProtoList" -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_PatchFiles.ipf
r1243 r1246 122 122 // 123 123 Proc V_Patch_Panel() 124 125 Variable sc = 1 126 127 if(root:Packages:NIST:VSANS:Globals:gLaptopMode == 1) 128 sc = 0.7 129 endif 130 124 131 PauseUpdate; Silent 1 // building window... 125 NewPanel /W=(533 ,50,1140,588)/K=2as "Patch Raw VSANS Data Files"132 NewPanel /W=(533*sc,50*sc,1140*sc,588*sc)/K=1 as "Patch Raw VSANS Data Files" 126 133 DoWindow/C V_Patch_Panel 127 134 // ShowTools/A … … 132 139 ModifyPanel fixedSize=1 133 140 SetDrawLayer UserBack 134 DrawLine 7 ,30,422,30135 136 137 SetVariable PathDisplay,pos={ 77,7},size={310,13},title="Path"141 DrawLine 7*sc,30*sc,422*sc,30*sc 142 143 144 SetVariable PathDisplay,pos={sc*77,7*sc},size={sc*310,13*sc},title="Path" 138 145 SetVariable PathDisplay,help={"This is the path to the folder that will be used to find the SANS data while patching. If no files appear in the popup, make sure that this folder is set correctly"} 139 SetVariable PathDisplay,font="Courier",fSize=10 146 SetVariable PathDisplay,font="Courier",fSize=10*sc 140 147 SetVariable PathDisplay,limits={-Inf,Inf,0},value= root:Packages:NIST:VSANS:Globals:Patch:gCatPathStr 141 Button PathButton,pos={ 2,3},size={70,20},proc=V_PickPathButton,title="Pick Path"148 Button PathButton,pos={sc*2,3*sc},size={sc*70,20*sc},proc=V_PickPathButton,title="Pick Path" 142 149 Button PathButton,help={"Select the folder containing the raw SANS data files"} 143 Button helpButton,pos={ 400,3},size={25,20},proc=V_ShowPatchHelp,title="?"150 Button helpButton,pos={sc*400,3*sc},size={sc*25,20*sc},proc=V_ShowPatchHelp,title="?" 144 151 Button helpButton,help={"Show the help file for patching raw data headers"} 145 PopupMenu PatchPopup,pos={ 4,37},size={156,19},proc=V_PatchPopMenuProc,title="File(s) to Patch"152 PopupMenu PatchPopup,pos={sc*4,37*sc},size={sc*156,19*sc},proc=V_PatchPopMenuProc,title="File(s) to Patch" 146 153 PopupMenu PatchPopup,help={"The displayed file is the one that will be edited. The entire list will be edited if \"Change All..\" is selected. \r If no items, or the wrong items appear, click on the popup to refresh. \r List items are selected from the file based on MatchString"} 147 154 PopupMenu PatchPopup,mode=1,popvalue="none",value= #"root:Packages:NIST:VSANS:Globals:Patch:gPatchList" 148 155 149 Button CHButton,pos={ 314,37},size={110,20},proc=V_ChangeHeaderButtonProc,title="Change Header"156 Button CHButton,pos={sc*314,37*sc},size={sc*110,20*sc},proc=V_ChangeHeaderButtonProc,title="Change Header" 150 157 Button CHButton,help={"This will change the checked values (ONLY) in the single file selected in the popup."} 151 SetVariable PMStr,pos={ 6,63},size={174,13},proc=V_SetMatchStrProc,title="Match String"158 SetVariable PMStr,pos={sc*6,63*sc},size={sc*174,13*sc},proc=V_SetMatchStrProc,title="Match String" 152 159 SetVariable PMStr,help={"Enter the search string to narrow the list of files. \"*\" is the wildcard character. After entering, \"pop\" the menu to refresh the file list."} 153 SetVariable PMStr,font="Courier",fSize=10 160 SetVariable PMStr,font="Courier",fSize=10*sc 154 161 SetVariable PMStr,limits={-Inf,Inf,0},value= root:Packages:NIST:VSANS:Globals:Patch:gPatchMatchStr 155 Button ChAllButton,pos={ 245,60},size={180,20},proc=V_ChAllHeadersButtonProc,title="Change All Headers in List"162 Button ChAllButton,pos={sc*245,60*sc},size={sc*180,20*sc},proc=V_ChAllHeadersButtonProc,title="Change All Headers in List" 156 163 Button ChAllButton,help={"This will change the checked values (ONLY) in ALL of the files in the popup list, not just the top file. If the \"change\" checkbox for the item is not checked, nothing will be changed for that item."} 157 Button DoneButton,pos={ 450,60},size={110,20},proc=V_DoneButtonProc,title="Done Patching"164 Button DoneButton,pos={sc*450,60*sc},size={sc*110,20*sc},proc=V_DoneButtonProc,title="Done Patching" 158 165 Button DoneButton,help={"When done Patching files, this will close this control panel."} 159 CheckBox check0,pos={ 18,80},size={40,15},title="Run #",value= 1,mode=1,proc=V_MatchCheckProc160 CheckBox check1,pos={ 78,80},size={40,15},title="Text",value= 0,mode=1,proc=V_MatchCheckProc161 CheckBox check2,pos={ 138,80},size={40,15},title="Group_ID",value= 0,mode=1,proc=V_MatchCheckProc162 163 SetVariable curStr,pos={ 50,112},size={350,20},title="File Label:"166 CheckBox check0,pos={sc*18,80*sc},size={sc*40,15*sc},title="Run #",value= 1,mode=1,proc=V_MatchCheckProc 167 CheckBox check1,pos={sc*78,80*sc},size={sc*40,15*sc},title="Text",value= 0,mode=1,proc=V_MatchCheckProc 168 CheckBox check2,pos={sc*138,80*sc},size={sc*40,15*sc},title="Group_ID",value= 0,mode=1,proc=V_MatchCheckProc 169 170 SetVariable curStr,pos={sc*50,112*sc},size={sc*350,20*sc},title="File Label:" 164 171 SetVariable curStr,help={"Label of current file in popup list"} 165 SetVariable curStr,font="Courier",fSize=10 172 SetVariable curStr,font="Courier",fSize=10*sc 166 173 SetVariable curStr,limits={-Inf,Inf,0},value= root:Packages:NIST:VSANS:Globals:Patch:gPatchCurLabel 167 174 168 PopupMenu popup_0,pos={ 450,112},size={109,20},title="Detector Panel",proc=V_PatchPopMenuProc175 PopupMenu popup_0,pos={sc*450,112*sc},size={sc*109,20*sc},title="Detector Panel",proc=V_PatchPopMenuProc 169 176 PopupMenu popup_0,mode=1,popvalue="FL",value= #"\"FL;FR;FT;FB;ML;MR;MT;MB;B;\"" 170 177 171 178 172 TabControl PatchTab,pos={ 20,140},size={570,380}179 TabControl PatchTab,pos={sc*20,140*sc},size={sc*570,380*sc} 173 180 TabControl PatchTab,tabLabel(0)="Control",tabLabel(1)="Reduction",tabLabel(2)="Sample" 174 181 TabControl PatchTab,tabLabel(3)="Instrument",tabLabel(4)="Detectors",tabLabel(5)="PolSANS" … … 176 183 177 184 178 ListBox list0,pos={ 30,170.00},size={550.00,330},proc=V_PatchListBoxProc,frame=1179 ListBox list0,fSize=10 ,userColumnResize= 1,listWave=PP_ListWave,selWave=PP_SelWave,titleWave=PP_TitleWave185 ListBox list0,pos={sc*30,170.00*sc},size={sc*550.00,330*sc},proc=V_PatchListBoxProc,frame=1 186 ListBox list0,fSize=10*sc,userColumnResize= 1,listWave=PP_ListWave,selWave=PP_SelWave,titleWave=PP_TitleWave 180 187 ListBox list0,mode=2,widths={30,200} 181 188 … … 186 193 // TODO: add functions for these, make the intent a popup (since it's an enumerated type) 187 194 188 // PopupMenu popup_1,pos={ 42,base+14*step},size={109,20},title="File intent"195 // PopupMenu popup_1,pos={sc*42,base+14*step*sc},size={sc*109,20*sc},title="File intent" 189 196 // PopupMenu popup_1,mode=1,popvalue="SCATTER",value= #"\"SCATTER;EMPTY;BLOCKED BEAM;TRANS;EMPTY BEAM;\"" 190 197 … … 1710 1717 PauseUpdate; Silent 1 // building window... 1711 1718 1712 1713 NewPanel /W=(600,400,1000,1000)/N=DeadtimePanel /K=1 1719 Variable sc = 1 1720 1721 if(root:Packages:NIST:VSANS:Globals:gLaptopMode == 1) 1722 sc = 0.7 1723 endif 1724 1725 NewPanel /W=(600*sc,400*sc,1000*sc,1000*sc)/N=DeadtimePanel /K=1 1714 1726 // ShowTools/A 1715 1727 ModifyPanel cbRGB=(16266,47753,2552,23355) 1716 1728 1717 1729 SetDrawLayer UserBack 1718 DrawText 85,99,"Current Values" 1719 DrawText 21,258,"Write to all files (inlcusive)" 1720 SetDrawEnv fsize= 14,fstyle= 1 1721 DrawText 209,30,"Dead Time Constants" 1722 DrawText 20,133,"Run Number(s)" 1723 1724 PopupMenu popup_0,pos={20,40},size={109,20},title="Detector Panel" 1730 SetDrawEnv fsize= 14*sc,fstyle= 1 1731 DrawText 85*sc,99*sc,"Current Values" 1732 SetDrawEnv fsize= 14*sc,fstyle= 1 1733 DrawText 18*sc,258*sc,"Write to all files (inlcusive)" 1734 SetDrawEnv fsize= 14*sc,fstyle= 1 1735 DrawText 209*sc,30*sc,"Dead Time Constants" 1736 SetDrawEnv fsize= 14*sc,fstyle= 1 1737 DrawText 18*sc,133*sc,"Run Number(s)" 1738 1739 PopupMenu popup_0,pos={sc*20,40*sc},size={sc*109,20*sc},title="Detector Panel" 1725 1740 PopupMenu popup_0,mode=1,popvalue="FL",value= #"\"FL;FR;FT;FB;ML;MR;MT;MB;\"" 1726 1741 1727 Button button0,pos={ 20,81},size={50.00,20.00},proc=V_ReadDTButtonProc,title="Read"1728 Button button0_1,pos={ 20,220},size={50.00,20.00},proc=V_WriteDTButtonProc,title="Write"1729 Button button0_2,pos={ 18.00,336.00},size={140.00,20.00},proc=V_GeneratePerfDTButton,title="Perfect Dead Time"1730 Button button0_3,pos={ 18.00,370.00},size={140.00,20.00},proc=V_LoadCSVDTButton,title="Load Dead Time CSV"1731 Button button0_4,pos={ 18.00,400.00},size={140.00,20.00},proc=V_WriteCSVDTButton,title="Write Dead Time CSV"1732 1733 SetVariable setvar0,pos={ 20,141},size={100.00,14.00},title="first"1742 Button button0,pos={sc*20,81*sc},size={sc*50.00,20.00*sc},proc=V_ReadDTButtonProc,title="Read" 1743 Button button0_1,pos={sc*20,220*sc},size={sc*50.00,20.00*sc},proc=V_WriteDTButtonProc,title="Write" 1744 Button button0_2,pos={sc*18.00,336.00*sc},size={sc*140.00,20.00*sc},proc=V_GeneratePerfDTButton,title="Perfect Dead Time" 1745 Button button0_3,pos={sc*18.00,370.00*sc},size={sc*140.00,20.00*sc},proc=V_LoadCSVDTButton,title="Load Dead Time CSV" 1746 Button button0_4,pos={sc*18.00,400.00*sc},size={sc*140.00,20.00*sc},proc=V_WriteCSVDTButton,title="Write Dead Time CSV" 1747 1748 SetVariable setvar0,pos={sc*20,141*sc},size={sc*100.00,14.00*sc},title="first" 1734 1749 SetVariable setvar0,value= root:Packages:NIST:VSANS:Globals:Patch:gFileNum_Lo 1735 SetVariable setvar1,pos={ 20.00,167},size={100.00,14.00},title="last"1750 SetVariable setvar1,pos={sc*20.00,167*sc},size={sc*100.00,14.00*sc},title="last" 1736 1751 SetVariable setvar1,value= root:Packages:NIST:VSANS:Globals:Patch:gFileNum_Hi 1737 1752 1738 1753 1739 1754 // display the wave 1740 Edit/W=(180 ,40,380,550)/HOST=# root:Packages:NIST:VSANS:Globals:Patch:deadTimeWave1741 ModifyTable width(Point)= 401742 ModifyTable width(root:Packages:NIST:VSANS:Globals:Patch:deadTimeWave)= 1201755 Edit/W=(180*sc,40*sc,380*sc,550*sc)/HOST=# root:Packages:NIST:VSANS:Globals:Patch:deadTimeWave 1756 ModifyTable width(Point)=30 1757 ModifyTable width(root:Packages:NIST:VSANS:Globals:Patch:deadTimeWave)=80 1743 1758 RenameWindow #,T0 1744 1759 SetActiveSubwindow ## … … 2014 2029 PauseUpdate; Silent 1 // building window... 2015 2030 2016 2017 NewPanel /W=(600,400,1200,1000)/N=CalibrationPanel /K=1 2031 Variable sc = 1 2032 2033 if(root:Packages:NIST:VSANS:Globals:gLaptopMode == 1) 2034 sc = 0.7 2035 endif 2036 2037 NewPanel /W=(600*sc,400*sc,1200*sc,1000*sc)/N=CalibrationPanel /K=1 2018 2038 // ShowTools/A 2019 2039 ModifyPanel cbRGB=(16266,47753,2552,23355) 2020 2040 2021 2041 SetDrawLayer UserBack 2022 DrawText 85,99,"Current Values" 2023 DrawText 21,258,"Write to all files (inlcusive)" 2024 SetDrawEnv fsize= 14,fstyle= 1 2025 DrawText 227,28,"Quadratic Calibration Constants per Tube" 2026 DrawText 20,133,"Run Number(s)" 2027 2028 PopupMenu popup_0,pos={20,40},size={109,20},title="Detector Panel" 2042 SetDrawEnv fsize= 14*sc,fstyle= 1 2043 DrawText 85*sc,99*sc,"Current Values" 2044 SetDrawEnv fsize= 14*sc,fstyle= 1 2045 DrawText 18*sc,258*sc,"Write to all files (inlcusive)" 2046 SetDrawEnv fsize= 14*sc,fstyle= 1 2047 DrawText 227*sc,28*sc,"Quadratic Calibration Constants per Tube" 2048 SetDrawEnv fsize= 14*sc,fstyle= 1 2049 DrawText 18*sc,133*sc,"Run Number(s)" 2050 2051 PopupMenu popup_0,pos={sc*20,40*sc},size={sc*109,20*sc},title="Detector Panel" 2029 2052 PopupMenu popup_0,mode=1,popvalue="FL",value= #"\"FL;FR;FT;FB;ML;MR;MT;MB;\"" 2030 2053 2031 Button button0,pos={ 20,81},size={50.00,20.00},proc=V_ReadCalibButtonProc,title="Read"2032 Button button0_1,pos={ 20,220},size={50.00,20.00},proc=V_WriteCalibButtonProc,title="Write"2033 Button button0_2,pos={ 18.00,336.00},size={140.00,20.00},proc=V_GeneratePerfCalibButton,title="Perfect Calibration"2034 Button button0_3,pos={ 18.00,370.00},size={140.00,20.00},proc=V_LoadCSVCalibButton,title="Load Calibration CSV"2035 Button button0_4,pos={ 18.00,400.00},size={140.00,20.00},proc=V_WriteCSVCalibButton,title="Write Calibration CSV"2036 2037 SetVariable setvar0,pos={ 20,141},size={100.00,14.00},title="first"2054 Button button0,pos={sc*20,81*sc},size={sc*50.00,20.00*sc},proc=V_ReadCalibButtonProc,title="Read" 2055 Button button0_1,pos={sc*20,220*sc},size={sc*50.00,20.00*sc},proc=V_WriteCalibButtonProc,title="Write" 2056 Button button0_2,pos={sc*18.00,336.00*sc},size={sc*140.00,20.00*sc},proc=V_GeneratePerfCalibButton,title="Perfect Calibration" 2057 Button button0_3,pos={sc*18.00,370.00*sc},size={sc*140.00,20.00*sc},proc=V_LoadCSVCalibButton,title="Load Calibration CSV" 2058 Button button0_4,pos={sc*18.00,400.00*sc},size={sc*140.00,20.00*sc},proc=V_WriteCSVCalibButton,title="Write Calibration CSV" 2059 2060 SetVariable setvar0,pos={sc*20,141*sc},size={sc*100.00,14.00*sc},title="first" 2038 2061 SetVariable setvar0,value= root:Packages:NIST:VSANS:Globals:Patch:gFileNum_Lo 2039 SetVariable setvar1,pos={ 20.00,167},size={100.00,14.00},title="last"2062 SetVariable setvar1,pos={sc*20.00,167*sc},size={sc*100.00,14.00*sc},title="last" 2040 2063 SetVariable setvar1,value= root:Packages:NIST:VSANS:Globals:Patch:gFileNum_Hi 2041 2064 2042 2065 2043 2066 // display the wave 2044 Edit/W=(180 ,40,580,550)/HOST=# root:Packages:NIST:VSANS:Globals:Patch:calibrationWave2045 ModifyTable width(Point)= 402046 ModifyTable width(root:Packages:NIST:VSANS:Globals:Patch:calibrationWave)= 1102067 Edit/W=(180*sc,40*sc,580*sc,550*sc)/HOST=# root:Packages:NIST:VSANS:Globals:Patch:calibrationWave 2068 ModifyTable width(Point)=30 2069 ModifyTable width(root:Packages:NIST:VSANS:Globals:Patch:calibrationWave)=70 2047 2070 // the elements() command transposes the view in the table, but does not transpose the wave 2048 2071 ModifyTable elements(root:Packages:NIST:VSANS:Globals:Patch:calibrationWave) = (-3, -2) … … 2380 2403 PauseUpdate; Silent 1 // building window... 2381 2404 2382 2383 NewPanel /W=(600,400,1150,800)/N=Patch_XY_Panel /K=1 2405 Variable sc = 1 2406 2407 if(root:Packages:NIST:VSANS:Globals:gLaptopMode == 1) 2408 sc = 0.7 2409 endif 2410 2411 NewPanel /W=(600*sc,400*sc,1150*sc,800*sc)/N=Patch_XY_Panel /K=1 2384 2412 // ShowTools/A 2385 2413 … … 2387 2415 2388 2416 SetDrawLayer UserBack 2389 DrawText 85,99,"Current Values" 2390 DrawText 21,258,"Write to all files (inlcusive)" 2391 SetDrawEnv fsize= 14,fstyle= 1 2392 DrawText 262,30,"Beam Center [cm]" 2393 DrawText 20,133,"Run Number(s)" 2394 2395 Button button0,pos={20,81},size={50.00,20.00},proc=V_ReadXYButtonProc,title="Read" 2396 Button button0_1,pos={20,220},size={50.00,20.00},proc=V_WriteXYButtonProc,title="Write" 2397 SetVariable setvar0,pos={20,141},size={100.00,14.00},title="first" 2417 SetDrawEnv fsize= 14*sc,fstyle= 1 2418 DrawText 85*sc,99*sc,"Current Values" 2419 SetDrawEnv fsize= 14*sc,fstyle= 1 2420 DrawText 18*sc,258*sc,"Write to all files(inlcusive)" 2421 SetDrawEnv fsize= 14*sc,fstyle= 1 2422 DrawText 20*sc,133*sc,"Run Number(s)" 2423 DrawText 262*sc,30*sc,"Beam Center [cm]" 2424 2425 2426 Button button0,pos={sc*20,81*sc},size={sc*50.00,20.00*sc},proc=V_ReadXYButtonProc,title="Read" 2427 Button button0_1,pos={sc*20,220*sc},size={sc*50.00,20.00*sc},proc=V_WriteXYButtonProc,title="Write" 2428 SetVariable setvar0,pos={sc*20,141*sc},size={sc*100.00,14.00*sc},title="first" 2398 2429 SetVariable setvar0,value= root:Packages:NIST:VSANS:Globals:Patch:gFileNum_Lo 2399 SetVariable setvar1,pos={ 20.00,167},size={100.00,14.00},title="last"2430 SetVariable setvar1,pos={sc*20.00,167*sc},size={sc*100.00,14.00*sc},title="last" 2400 2431 SetVariable setvar1,value= root:Packages:NIST:VSANS:Globals:Patch:gFileNum_Hi 2401 2432 … … 2403 2434 SetDataFolder root:Packages:NIST:VSANS:Globals:Patch 2404 2435 // display the wave 2405 Edit/W=(180 ,40,500,370)/HOST=# panelW,xCtr_cm,yCtr_cm2436 Edit/W=(180*sc,40*sc,500*sc,370*sc)/HOST=# panelW,xCtr_cm,yCtr_cm 2406 2437 ModifyTable width(Point)=0 2407 ModifyTable width(panelW)= 802408 ModifyTable width(xCtr_cm)= 1002409 ModifyTable width(yCtr_cm)= 1002438 ModifyTable width(panelW)=50 2439 ModifyTable width(xCtr_cm)=60 2440 ModifyTable width(yCtr_cm)=60 2410 2441 RenameWindow #,T0 2411 2442 SetActiveSubwindow ## -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_Protocol_Reduction.ipf
r1242 r1246 1043 1043 // 1044 1044 Window V_ProtocolPanel() 1045 1046 Variable sc = 1 1047 1048 if(root:Packages:NIST:VSANS:Globals:gLaptopMode == 1) 1049 sc = 0.7 1050 endif 1051 1045 1052 PauseUpdate; Silent 1 // building window... 1046 NewPanel /W=(1 280,332,1630,932) /K=1 as "VSANS Reduction Protocol"1047 ModifyPanel cbRGB=(56589,50441,50159) , fixedSize=11053 NewPanel /W=(1180*sc,332*sc,1530*sc,932*sc) /K=1 as "VSANS Reduction Protocol" 1054 ModifyPanel cbRGB=(56589,50441,50159)//, fixedSize=1 1048 1055 SetDrawLayer UserBack 1049 DrawLine 3,65 ,301,651050 DrawLine 3,157 ,301,1571051 DrawLine 3,208 ,301,2081052 DrawLine 3,257 ,301,2571053 DrawLine 3,305 ,301,3051054 DrawLine 3,350 ,301,3501055 DrawLine 3,445 ,301,4451056 DrawLine 3,513 ,301,5131057 DrawLine 3,396 ,301,3961058 1059 // 1060 Button button_help,pos={ 300,2},size={25,20},proc=V_ShowProtoHelp,title="?"1056 DrawLine 3,65*sc,301*sc,65*sc 1057 DrawLine 3,157*sc,301*sc,157*sc 1058 DrawLine 3,208*sc,301*sc,208*sc 1059 DrawLine 3,257*sc,301*sc,257*sc 1060 DrawLine 3,305*sc,301*sc,305*sc 1061 DrawLine 3,350*sc,301*sc,350*sc 1062 DrawLine 3,445*sc,301*sc,445*sc 1063 DrawLine 3,513*sc,301*sc,513*sc 1064 DrawLine 3,396*sc,301*sc,396*sc 1065 1066 // 1067 Button button_help,pos={sc*300,2*sc},size={sc*25,20*sc},proc=V_ShowProtoHelp,title="?" 1061 1068 Button button_help,help={"Show the help file for setting up a reduction protocol"} 1062 Button button_quest,pos={20,2},size={150,20},proc=V_ProtocolQuestionnaire,title="Questions"1063 Button button_quest,help={"Run through the questionnaire for setting up a reduction protocol"}1064 Button button_quest,disable=21065 1066 1067 PopupMenu popup_sam,pos={ 85,68},size={51,23},proc=V_SAMFilePopMenuProc1069 // Button button_quest,pos={sc*20,2*sc},size={sc*150,20*sc},proc=V_ProtocolQuestionnaire,title="Questions" 1070 // Button button_quest,help={"Run through the questionnaire for setting up a reduction protocol"} 1071 // Button button_quest,disable=2 1072 1073 1074 PopupMenu popup_sam,pos={sc*85,68*sc},size={sc*51,23*sc},proc=V_SAMFilePopMenuProc 1068 1075 PopupMenu popup_sam,mode=1,value= #"V_getSAMList()" 1069 PopupMenu popup_bkg,pos={ 85,164},size={51,23},proc=V_BKGFilePopMenuProc1076 PopupMenu popup_bkg,pos={sc*85,164*sc},size={sc*51,23*sc},proc=V_BKGFilePopMenuProc 1070 1077 PopupMenu popup_bkg,mode=1,value= #"V_getBGDList()" 1071 PopupMenu popup_emp,pos={ 85,213},size={51,23},proc=V_EMPFilePopMenuProc1078 PopupMenu popup_emp,pos={sc*85,213*sc},size={sc*51,23*sc},proc=V_EMPFilePopMenuProc 1072 1079 PopupMenu popup_emp,mode=1,value= #"V_getEMPList()" 1073 PopupMenu popup_div,pos={ 85,263},size={51,23},proc=V_DIVFilePopMenuProc1080 PopupMenu popup_div,pos={sc*85,263*sc},size={sc*51,23*sc},proc=V_DIVFilePopMenuProc 1074 1081 PopupMenu popup_div,mode=1,value= #"V_getDIVList()" 1075 PopupMenu popup_msk,pos={ 85,356},size={51,23},proc=V_MSKFilePopMenuProc1082 PopupMenu popup_msk,pos={sc*85,356*sc},size={sc*51,23*sc},proc=V_MSKFilePopMenuProc 1076 1083 PopupMenu popup_msk,mode=1,value= #"V_getMSKList()" 1077 1084 1078 1085 1079 CheckBox prot_check,pos={ 6,163},size={74,14},title="Background"1086 CheckBox prot_check,pos={sc*6,163*sc},size={sc*74,14*sc},title="Background" 1080 1087 CheckBox prot_check,help={"If checked, the specified background file will be included in the data reduction. If the file name is \"ask\", then the user will be prompted for the file"} 1081 1088 CheckBox prot_check,value= 1 1082 CheckBox prot_check_1,pos={ 6,215},size={71,14},title="Empty Cell"1089 CheckBox prot_check_1,pos={sc*6,215*sc},size={sc*71,14*sc},title="Empty Cell" 1083 1090 CheckBox prot_check_1,help={"If checked, the specified empty cell file will be included in the data reduction. If the file name is \"ask\", then the user will be prompted for the file"} 1084 1091 CheckBox prot_check_1,value= 1 1085 CheckBox prot_check_2,pos={ 6,263},size={72,14},title="Sensitivity"1092 CheckBox prot_check_2,pos={sc*6,263*sc},size={sc*72,14*sc},title="Sensitivity" 1086 1093 CheckBox prot_check_2,help={"If checked, the specified detector sensitivity file will be included in the data reduction. If the file name is \"ask\", then the user will be prompted for the file"} 1087 1094 CheckBox prot_check_2,value= 1 1088 CheckBox prot_check_3,pos={ 6,356},size={43,14},title="Mask"1095 CheckBox prot_check_3,pos={sc*6,356*sc},size={sc*43,14*sc},title="Mask" 1089 1096 CheckBox prot_check_3,help={"If checked, the specified mask file will be included in the data reduction. If the file name is \"ask\", then the user will be prompted for the file"} 1090 1097 CheckBox prot_check_3,value= 1 1091 CheckBox prot_check_4,pos={ 6,70},size={53,14},title="Sample"1098 CheckBox prot_check_4,pos={sc*6,70*sc},size={sc*53,14*sc},title="Sample" 1092 1099 CheckBox prot_check_4,help={"If checked, the specified sample file will be included in the data reduction. If the file name is \"ask\", then the user will be prompted for the file"} 1093 1100 CheckBox prot_check_4,value= 1 1094 CheckBox prot_check_5,pos={ 6,399},size={56,14},title="Average"1101 CheckBox prot_check_5,pos={sc*6,399*sc},size={sc*56,14*sc},title="Average" 1095 1102 CheckBox prot_check_5,help={"If checked, the specified averaging will be performed at the end of the data reduction."} 1096 1103 CheckBox prot_check_5,value= 1 1097 CheckBox prot_check_9,pos={ 6,310},size={59,14},title="Absolute"1104 CheckBox prot_check_9,pos={sc*6,310*sc},size={sc*59,14*sc},title="Absolute" 1098 1105 CheckBox prot_check_9,help={"If checked, absolute calibration will be included in the data reduction. If the parameter list is \"ask\", then the user will be prompted for absolue parameters"} 1099 1106 CheckBox prot_check_9,value= 1 1100 1107 1101 1108 1102 // Button pick_sam,pos={ 214,28},size={70,20},proc=V_PickSAMButton,title="set SAM"1109 // Button pick_sam,pos={sc*214,28*sc},size={sc*70,20*sc},proc=V_PickSAMButton,title="set SAM" 1103 1110 // Button pick_sam,help={"This button will set the file selected in the File Catalog table to be the sample file"} 1104 // Button pick_bgd,pos={ 214,75},size={70,20},proc=V_PickBGDButton,title="set BGD"1111 // Button pick_bgd,pos={sc*214,75*sc},size={sc*70,20*sc},proc=V_PickBGDButton,title="set BGD" 1105 1112 // Button pick_bgd,help={"This button will set the file selected in the File Catalog table to be the background file."} 1106 // Button pick_emp,pos={ 214,125},size={70,20},proc=V_PickEMPButton,title="set EMP"1113 // Button pick_emp,pos={sc*214,125*sc},size={sc*70,20*sc},proc=V_PickEMPButton,title="set EMP" 1107 1114 // Button pick_emp,help={"This button will set the file selected in the File Catalog table to be the empty cell file."} 1108 // Button pick_DIV,pos={ 214,173},size={70,20},proc=V_PickDIVButton,title="set DIV"1115 // Button pick_DIV,pos={sc*214,173*sc},size={sc*70,20*sc},proc=V_PickDIVButton,title="set DIV" 1109 1116 // Button pick_DIV,help={"This button will set the file selected in the File Catalog table to be the sensitivity file."} 1110 Button pick_ABS,pos={ 264,308},size={80,20},proc=V_SetABSParamsButton,title="set ABS MF"1117 Button pick_ABS,pos={sc*264,308*sc},size={sc*80,20*sc},proc=V_SetABSParamsButton,title="set ABS MF" 1111 1118 Button pick_ABS,help={"This button will prompt the user for absolute scaling parameters"} 1112 1119 1113 Button pick_ABS_B,pos={ 264,330},size={80,20},proc=V_SetABSParamsButton,title="set ABS B"1120 Button pick_ABS_B,pos={sc*264,330*sc},size={sc*80,20*sc},proc=V_SetABSParamsButton,title="set ABS B" 1114 1121 Button pick_ABS_B,help={"This button will prompt the user for absolute scaling parameters"} 1115 // Button pick_MASK,pos={ 214,266},size={70,20},proc=V_PickMASKButton,title="set MASK"1122 // Button pick_MASK,pos={sc*214,266*sc},size={sc*70,20*sc},proc=V_PickMASKButton,title="set MASK" 1116 1123 // Button pick_MASK,help={"This button will set the file selected in the File Catalog table to be the mask file."} 1117 1124 1118 1125 1119 Button pick_AVE,pos={ 188,401},size={150,20},proc=V_SetAverageParamsButtonProc,title="set AVERAGE params"1126 Button pick_AVE,pos={sc*188,401*sc},size={sc*150,20*sc},proc=V_SetAverageParamsButtonProc,title="set AVERAGE params" 1120 1127 Button pick_AVE,help={"Prompts the user for the type of 1-D averaging to perform, as well as saving options"} 1121 1128 1122 1129 1123 Button pick_trim,pos={ 264,454},size={70,20},proc=V_TrimDataProtoButton,title="Trim"1130 Button pick_trim,pos={sc*264,454*sc},size={sc*70,20*sc},proc=V_TrimDataProtoButton,title="Trim" 1124 1131 Button pick_trim,help={"This button will prompt the user for trimming parameters"} 1125 1132 1126 1133 1127 SetVariable samStr,pos={ 6,90},size={250,15},title="file:"1134 SetVariable samStr,pos={sc*6,90*sc},size={sc*250,15*sc},title="file:" 1128 1135 SetVariable samStr,help={"Filename of the sample file(s) to be used in the data reduction"} 1129 1136 SetVariable samStr,limits={-Inf,Inf,0},value= root:Packages:NIST:VSANS:Globals:Protocols:gSAM 1130 SetVariable bgdStr,pos={ 7,186},size={250,15},title="file:"1137 SetVariable bgdStr,pos={sc*7,186*sc},size={sc*250,15*sc},title="file:" 1131 1138 SetVariable bgdStr,help={"Filename of the background file(s) to be used in the data reduction"} 1132 1139 SetVariable bgdStr,limits={-Inf,Inf,0},value= root:Packages:NIST:VSANS:Globals:Protocols:gBGD 1133 SetVariable empStr,pos={ 8,236},size={250,15},title="file:"1140 SetVariable empStr,pos={sc*8,236*sc},size={sc*250,15*sc},title="file:" 1134 1141 SetVariable empStr,help={"Filename of the empty cell file(s) to be used in the data reduction"} 1135 1142 SetVariable empStr,limits={-Inf,Inf,0},value= root:Packages:NIST:VSANS:Globals:Protocols:gEMP 1136 SetVariable divStr,pos={ 9,285},size={250,15},title="file:"1143 SetVariable divStr,pos={sc*9,285*sc},size={sc*250,15*sc},title="file:" 1137 1144 SetVariable divStr,help={"Filename of the detector sensitivity file to be used in the data reduction"} 1138 1145 SetVariable divStr,limits={-Inf,Inf,0},value= root:Packages:NIST:VSANS:Globals:Protocols:gDIV 1139 SetVariable maskStr,pos={ 9,377},size={250,15},title="file:"1146 SetVariable maskStr,pos={sc*9,377*sc},size={sc*250,15*sc},title="file:" 1140 1147 SetVariable maskStr,help={"Filename of the mask file to be used in the data reduction"} 1141 1148 SetVariable maskStr,limits={-Inf,Inf,0},value= root:Packages:NIST:VSANS:Globals:Protocols:gMASK 1142 SetVariable absStr,pos={ 7,331},size={250,15},title="parameters:"1149 SetVariable absStr,pos={sc*7,331*sc},size={sc*250,15*sc},title="parameters:" 1143 1150 SetVariable absStr,help={"Keyword-string of values necessary for absolute scaling of data. Remaining parameters are taken from the sample file."} 1144 1151 SetVariable absStr,limits={-Inf,Inf,0},value= root:Packages:NIST:VSANS:Globals:Protocols:gAbsStr 1145 SetVariable aveStr,pos={ 9,424},size={250,15},title="parameters:"1152 SetVariable aveStr,pos={sc*9,424*sc},size={sc*250,15*sc},title="parameters:" 1146 1153 SetVariable aveStr,help={"Keyword-string of choices used for averaging and saving the 1-D data files"} 1147 1154 SetVariable aveStr,limits={-Inf,Inf,0},value= root:Packages:NIST:VSANS:Globals:Protocols:gAVE 1148 1155 1149 SetVariable begStr,pos={ 9,464},size={250,15},title="Beg Trim:"1156 SetVariable begStr,pos={sc*9,464*sc},size={sc*250,15*sc},title="Beg Trim:" 1150 1157 SetVariable begStr,help={"Keyword-string of choices used for averaging and saving the 1-D data files"} 1151 1158 SetVariable begStr,limits={-Inf,Inf,0},value= root:Packages:NIST:VSANS:Globals:Protocols:gBegPtsStr 1152 SetVariable endStr,pos={ 9,484},size={250,15},title="End Trim:"1159 SetVariable endStr,pos={sc*9,484*sc},size={sc*250,15*sc},title="End Trim:" 1153 1160 SetVariable endStr,help={"Keyword-string of choices used for averaging and saving the 1-D data files"} 1154 1161 SetVariable endStr,limits={-Inf,Inf,0},value= root:Packages:NIST:VSANS:Globals:Protocols:gEndPtsStr … … 1158 1165 //only show DRK if user wants to see it 1159 1166 //if global = 1,then show => set disable = 0 1160 // CheckBox prot_check_6,pos={ 6,363},size={113,14},proc=DrkCheckProc,title="Use DRK correction"1167 // CheckBox prot_check_6,pos={sc*6,363*sc},size={sc*113,14*sc},proc=DrkCheckProc,title="Use DRK correction" 1161 1168 // CheckBox prot_check_6,help={"If checked, the selected file will be used for DRK correction. Typically this is NOT checked"} 1162 1169 // CheckBox prot_check_6,value= 0,disable = (!root:Packages:NIST:gAllowDRK) 1163 // SetVariable drkStr,pos={ 120,363},size={150,15},title="."1164 // SetVariable drkStr,help={"DRK detector count file" },disable = (!root:Packages:NIST:gAllowDRK)1170 // SetVariable drkStr,pos={sc*120,363*sc},size={sc*150,15*sc},title="." 1171 // SetVariable drkStr,help={"DRK detector count file"*sc},disable = (!root:Packages:NIST:gAllowDRK) 1165 1172 // SetVariable drkStr,limits={-Inf,Inf,0},value= root:Packages:NIST:VSANS:Globals:Protocols:gDRK 1166 1173 1167 1174 1168 Button export_button, size={ 120,20},pos={125,540},title="Export to Data",proc=V_ExportFileProtocol1175 Button export_button, size={sc*120,20*sc},pos={sc*125,540*sc},title="Export to Data",proc=V_ExportFileProtocol 1169 1176 Button export_button, help={"Exports the protocol to data file on disk for Importing into another experiment"} 1170 Button import_button, size={ 120,20},pos={125,562},title="Import from Data",proc=V_ImportFileProtocol1177 Button import_button, size={sc*120,20*sc},pos={sc*125,562*sc},title="Import from Data",proc=V_ImportFileProtocol 1171 1178 Button import_button,help={"Imports a protocol from a data file on disk for use in this experiment"} 1172 Button recallProt,pos={ 7,540},size={107,20},proc=V_RecallProtocolButton,title="Recall Protocol"1179 Button recallProt,pos={sc*7,540*sc},size={sc*107,20*sc},proc=V_RecallProtocolButton,title="Recall Protocol" 1173 1180 Button recallProt,help={"Resets the panel to the file choices in a previously saved protocol"} 1174 Button del_protocol,pos={ 7,562},size={110,20},proc=V_DeleteProtocolButton,title="Delete Protocol"1181 Button del_protocol,pos={sc*7,562*sc},size={sc*110,20*sc},proc=V_DeleteProtocolButton,title="Delete Protocol" 1175 1182 Button del_protocol,help={"Use this to delete a previously saved protocol."} 1176 Button done_protocol,pos={ 285,562},size={45,20},proc=V_DoneProtocolButton,title="Done"1183 Button done_protocol,pos={sc*285,562*sc},size={sc*45,20*sc},proc=V_DoneProtocolButton,title="Done" 1177 1184 Button done_protocol,help={"This button will close the panel. The panel can be recalled at any time from the SANS menu."} 1178 Button saveProtocol,pos={ 7,518},size={100,20},proc=V_SaveProtocolButton,title="Save Protocol"1185 Button saveProtocol,pos={sc*7,518*sc},size={sc*100,20*sc},proc=V_SaveProtocolButton,title="Save Protocol" 1179 1186 Button saveProtocol,help={"Saves the cerrent selections in the panel to a protocol which can be later recalled"} 1180 Button ReduceOne,pos={ 240,518},size={100,20},proc=V_ReduceOneButton,title="Reduce A File"1187 Button ReduceOne,pos={sc*240,518*sc},size={sc*100,20*sc},proc=V_ReduceOneButton,title="Reduce A File" 1181 1188 Button ReduceOne,help={"Using the panel selections, the specified sample file will be reduced. If none is specified, the user will be prompted for a sample file"} 1182 1189 … … 2682 2689 Function V_SelectABS_XYBox(x1,x2,y1,y2) 2683 2690 Variable &x1,&x2,&y1,&y2 2691 2692 2693 Variable sc = 1 2694 2695 NVAR gLaptopMode = root:Packages:NIST:VSANS:Globals:gLaptopMode 2696 2697 if(gLaptopMode == 1) 2698 sc = 0.7 2699 endif 2684 2700 2685 2701 Variable err=0 … … 2688 2704 Variable/G root:V_left,root:V_right,root:V_bottom,root:V_top //must be global for auto-update 2689 2705 DoWindow/F SANS_Data 2690 NewPanel/K=2 /W=(139 ,341,382,432) as "Select the primary beam"2706 NewPanel/K=2 /W=(139*sc,341*sc,382*sc,432*sc) as "Select the primary beam" 2691 2707 DoWindow/C junkWindow 2692 2708 AutoPositionWindow/E/M=1/R=SANS_Data 2693 2709 2694 Drawtext 21 ,20,"Select the primary beam with the"2695 DrawText 21 ,40, "marquee and press continue"2696 Button button0,pos={ 80,58},size={92,20},title="Continue"2710 Drawtext 21*sc,20*sc ,"Select the primary beam with the" 2711 DrawText 21*sc,40*sc, "marquee and press continue" 2712 Button button0,pos={sc*80,58*sc},size={sc*92,20*sc},title="Continue" 2697 2713 Button button0,proc=V_UserSelectBox_Continue 2698 2714 … … 2725 2741 2726 2742 Function V_UseStdOrEmpForABS() 2727 2728 NewPanel/K=2 /W=(139,341,402,448) as "Absolute Scaling" 2743 2744 Variable sc = 1 2745 2746 NVAR gLaptopMode = root:Packages:NIST:VSANS:Globals:gLaptopMode 2747 2748 if(gLaptopMode == 1) 2749 sc = 0.7 2750 endif 2751 2752 NewPanel/K=2 /W=(139*sc,341*sc,402*sc,448*sc) as "Absolute Scaling" 2729 2753 DoWindow/C junkABSWindow 2730 2754 ModifyPanel cbRGB=(57346,65535,49151) 2731 2755 SetDrawLayer UserBack 2732 2756 SetDrawEnv fstyle= 1 2733 DrawText 21 ,20,"Method of absolute calibration"2734 Button button0,pos={ 52,33},size={150,20},proc=V_UserSelectABS_Continue,title="Empty Beam Flux"2735 Button button1,pos={ 52,65},size={150,20},proc=V_UserSelectABS_Continue,title="Secondary Standard"2757 DrawText 21*sc,20*sc,"Method of absolute calibration" 2758 Button button0,pos={sc*52,33*sc},size={sc*150,20*sc},proc=V_UserSelectABS_Continue,title="Empty Beam Flux" 2759 Button button1,pos={sc*52,65*sc},size={sc*150,20*sc},proc=V_UserSelectABS_Continue,title="Secondary Standard" 2736 2760 2737 2761 PauseForUser junkABSWindow -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_RAW_Data_Panel.ipf
r1242 r1246 137 137 Window VSANS_DataPanel() : Panel 138 138 PauseUpdate; Silent 1 // building window... 139 NewPanel /W=(37,45,1038,719) /K=1 /N=VSANS_Data 139 140 Variable sc = 1 141 142 if(root:Packages:NIST:VSANS:Globals:gLaptopMode == 1) 143 sc = 0.7 144 endif 145 146 if(root:Packages:NIST:VSANS:Globals:gLaptopMode==1) 147 NewPanel /W=(7,36,700,445) /K=1 /N=VSANS_Data 148 else 149 NewPanel /W=(37,45,1038,719) /K=1 /N=VSANS_Data 150 endif 151 152 140 153 // ShowTools/A 141 154 ModifyPanel cbRGB=(65535,60076,49151) … … 147 160 SetDrawLayer UserBack 148 161 SetDrawEnv linethick= 2,dash= 1,fillpat= 0 149 DrawRect 200 ,70,310,160162 DrawRect 200*sc,70*sc,310*sc,160*sc 150 163 SetDrawEnv linethick= 2,dash= 1,fillpat= 0 151 DrawRect 320 ,70,430,160164 DrawRect 320*sc,70*sc,430*sc,160*sc 152 165 SetDrawEnv linethick= 2,dash= 1,fillpat= 0 153 DrawRect 440 ,70,535,160166 DrawRect 440*sc,70*sc,535*sc,160*sc 154 167 155 168 SetDrawEnv fsize= 18 156 DrawText 230 ,115,"Front"169 DrawText 230*sc,115*sc,"Front" 157 170 SetDrawEnv fsize= 18 158 DrawText 348 ,115,"Middle"171 DrawText 348*sc,115*sc,"Middle" 159 172 SetDrawEnv fsize= 18 160 DrawText 476 ,115,"Back"173 DrawText 476*sc,115*sc,"Back" 161 174 162 175 ToolsGrid visible=1 163 176 164 177 165 TabControl tab0,pos={ 13,41},size={572,617},proc=V_DataTabProc,tabLabel(0)="Front"178 TabControl tab0,pos={sc*13,41*sc},size={sc*572,617*sc},proc=V_DataTabProc,tabLabel(0)="Front" 166 179 TabControl tab0,tabLabel(1)="Middle",tabLabel(2)="Back",value= 2,focusRing=0 167 180 TabControl tab0 labelBack=(63535,56076,45151) 168 181 169 182 // on the side 170 Button button_status,pos={ 607,146},size={70,20},proc=V_StatusButtonProc,title="Status",disable=2171 Button button_IvsQ,pos={ 689,113},size={70,20},proc=V_IvsQPanelButtonProc,title="I vs. Q"172 Button button_file_m,pos={ 619,55},size={50,20},proc=V_File_minus_ButtonProc,title="File <"173 Button button_file_p,pos={ 679,55},size={50,20},proc=V_File_plus_ButtonProc,title="File >"174 Button button_log,pos={ 689,146},size={70,20},proc=V_LogLinButtonProc,title="isLin",userData="0"175 Button button_tab_p,pos={ 648,81},size={50,20},proc=V_Tab_p_ButtonProc,title="Tab >"176 Button button_isolate,pos={ 606,114},size={70,20},proc=V_IsolateButtonProc,title="Isolate"177 Button button_toWork,pos={ 770,146},size={90,20},proc=V_ToWorkFileButtonProc,title="to WORK"178 Button button_annular,pos={ 770,114},size={90,20},proc=V_annularAvgButtonProc,title="Annular Avg"179 Button button_SpreadPanels,pos={ 880,114},size={100,20},proc=V_SpreadPanelButtonProc,title="Spread Panels"180 Button button_RestorePanels,pos={ 880,146},size={100,20},proc=V_RestorePanelButtonProc,title="Restore Panels"181 182 Button button_sensor,pos={ 607,146+33},size={70,20},proc=V_SensorButtonProc,title="Sensors"183 Button button_mask,pos={ 689,146+33},size={70,20},proc=V_AvgMaskButtonProc,title="Avg Mask"184 185 186 TitleBox title_file,pos={ 606,178+30},fsize=12,size={76,20},variable= root:Packages:NIST:VSANS:Globals:gLastLoadedFile187 TitleBox title_dataPresent,pos={ 606,210+30},fsize=12,size={76,20},variable= root:Packages:NIST:VSANS:Globals:gCurDispFile188 TitleBox title_status,pos={ 606,240+30},size={200,200},fsize=12,variable= root:Packages:NIST:VSANS:Globals:gStatusText189 190 // Button button_tagFile,pos={ 720,412},size={70,20},proc=V_TagFileButtonProc,title="Tag File"183 Button button_status,pos={sc*607,146*sc},size={sc*70,20*sc},proc=V_StatusButtonProc,title="Status",disable=2 184 Button button_IvsQ,pos={sc*689,113*sc},size={sc*70,20*sc},proc=V_IvsQPanelButtonProc,title="I vs. Q" 185 Button button_file_m,pos={sc*619,55*sc},size={sc*50,20*sc},proc=V_File_minus_ButtonProc,title="File <" 186 Button button_file_p,pos={sc*679,55*sc},size={sc*50,20*sc},proc=V_File_plus_ButtonProc,title="File >" 187 Button button_log,pos={sc*689,146*sc},size={sc*70,20*sc},proc=V_LogLinButtonProc,title="isLin",userData="0" 188 Button button_tab_p,pos={sc*648,81*sc},size={sc*50,20*sc},proc=V_Tab_p_ButtonProc,title="Tab >" 189 Button button_isolate,pos={sc*606,114*sc},size={sc*70,20*sc},proc=V_IsolateButtonProc,title="Isolate" 190 Button button_toWork,pos={sc*770,146*sc},size={sc*90,20*sc},proc=V_ToWorkFileButtonProc,title="to WORK" 191 Button button_annular,pos={sc*770,114*sc},size={sc*90,20*sc},proc=V_annularAvgButtonProc,title="Annular Avg" 192 Button button_SpreadPanels,pos={sc*880,114*sc},size={sc*100,20*sc},proc=V_SpreadPanelButtonProc,title="Spread Panels" 193 Button button_RestorePanels,pos={sc*880,146*sc},size={sc*100,20*sc},proc=V_RestorePanelButtonProc,title="Restore Panels" 194 195 Button button_sensor,pos={sc*607,(146+33)*sc},size={sc*70,20*sc},proc=V_SensorButtonProc,title="Sensors" 196 Button button_mask,pos={sc*689,(146+33)*sc},size={sc*70,20*sc},proc=V_AvgMaskButtonProc,title="Avg Mask" 197 198 199 TitleBox title_file,pos={sc*606,(178+30)*sc},fsize=12*sc,size={sc*76,20*sc},variable= root:Packages:NIST:VSANS:Globals:gLastLoadedFile 200 TitleBox title_dataPresent,pos={sc*606,(210+30)*sc},fsize=12*sc,size={sc*76,20*sc},variable= root:Packages:NIST:VSANS:Globals:gCurDispFile 201 TitleBox title_status,pos={sc*606,(240+30)*sc},size={sc*200,200*sc},fsize=12*sc,variable= root:Packages:NIST:VSANS:Globals:gStatusText 202 203 // Button button_tagFile,pos={sc*720,412*sc},size={sc*70,20*sc},proc=V_TagFileButtonProc,title="Tag File" 191 204 // Button button_tagFile,disable=2 192 // Button button_saveIQ,pos={ 603,412},size={120,20},proc=V_SaveIQ_ButtonProc,title="Save I(Q) as ITX"193 // Button button_BeamCtr,pos={ 603,566},size={110,20},proc=V_BeamCtrButtonProc,title="Beam Center",disable=2194 // Button pick_trim,pos={ 603,450},size={120,20},proc=V_TrimDataProtoButton,title="Trim I(Q) Data"205 // Button button_saveIQ,pos={sc*603,412*sc},size={sc*120,20*sc},proc=V_SaveIQ_ButtonProc,title="Save I(Q) as ITX" 206 // Button button_BeamCtr,pos={sc*603,566*sc},size={sc*110,20*sc},proc=V_BeamCtrButtonProc,title="Beam Center",disable=2 207 // Button pick_trim,pos={sc*603,450*sc},size={sc*120,20*sc},proc=V_TrimDataProtoButton,title="Trim I(Q) Data" 195 208 // Button pick_trim,help={"This button will prompt the user for trimming parameters"} 196 209 197 210 198 211 // on the tabs, always visible 199 TitleBox title_xy,pos={ 20,65},fsize=12,size={76,20},variable= root:Packages:NIST:VSANS:Globals:gLastLoadedFile200 Slider slider_hi,pos={ 558,224},size={16,80},proc=V_HiMapSliderProc201 Slider slider_hi,limits={0,1,0 },value= 1,ticks= 0202 Slider slider_lo,pos={ 558,315},size={16,80},proc=V_LowMapSliderProc203 Slider slider_lo,limits={0,1,0 },value= 0,ticks= 0204 205 SetVariable xpos,pos={ 22,97},size={50,17},title="X "206 SetVariable xpos,limits={-Inf,Inf,0 },value= root:Packages:NIST:VSANS:Globals:gXPos212 TitleBox title_xy,pos={sc*20,65*sc},fsize=12*sc,size={sc*76,20*sc},variable= root:Packages:NIST:VSANS:Globals:gLastLoadedFile 213 Slider slider_hi,pos={sc*558,224*sc},size={sc*16,80*sc},proc=V_HiMapSliderProc 214 Slider slider_hi,limits={0,1,0*sc},value= 1,ticks= 0 215 Slider slider_lo,pos={sc*558,315*sc},size={sc*16,80*sc},proc=V_LowMapSliderProc 216 Slider slider_lo,limits={0,1,0*sc},value= 0,ticks= 0 217 218 SetVariable xpos,pos={sc*22,97*sc},size={sc*50,17*sc},title="X " 219 SetVariable xpos,limits={-Inf,Inf,0*sc},value= root:Packages:NIST:VSANS:Globals:gXPos 207 220 SetVariable xpos,help={"x-position on the detector"},frame=0,noedit=1 208 SetVariable ypos,pos={ 22,121},size={50,17},title="Y "209 SetVariable ypos,limits={-Inf,Inf,0 },value= root:Packages:NIST:VSANS:Globals:gYPos221 SetVariable ypos,pos={sc*22,121*sc},size={sc*50,17*sc},title="Y " 222 SetVariable ypos,limits={-Inf,Inf,0*sc},value= root:Packages:NIST:VSANS:Globals:gYPos 210 223 SetVariable ypos,help={"y-position on the detector"},frame=0,noedit=1 211 SetVariable counts,pos={ 22,151},size={150,17},title="Counts "212 SetVariable counts,limits={-Inf,Inf,0 },value= root:Packages:NIST:VSANS:Globals:gNCounts224 SetVariable counts,pos={sc*22,151*sc},size={sc*150,17*sc},title="Counts " 225 SetVariable counts,limits={-Inf,Inf,0*sc},value= root:Packages:NIST:VSANS:Globals:gNCounts 213 226 SetVariable counts,help={"Neutron counts"},frame=0,noedit=1 214 SetVariable qxval,pos={ 83,94},size={85,17},title="qX"227 SetVariable qxval,pos={sc*83,94*sc},size={sc*85,17*sc},title="qX" 215 228 SetVariable qxval,help={"q value in the x-direction on the detector"},frame=0,noedit=1 216 SetVariable qxval,format="%+7.5f",limits={-Inf,Inf,0 },value= root:Packages:NIST:VSANS:Globals:gQX217 SetVariable qyval,pos={ 83,113},size={85,17},title="qY"229 SetVariable qxval,format="%+7.5f",limits={-Inf,Inf,0*sc},value= root:Packages:NIST:VSANS:Globals:gQX 230 SetVariable qyval,pos={sc*83,113*sc},size={sc*85,17*sc},title="qY" 218 231 SetVariable qyval,help={"q value in the y-direction on the detector"},frame=0,noedit=1 219 SetVariable qyval,format="%+7.5f",limits={-Inf,Inf,0 },value= root:Packages:NIST:VSANS:Globals:gQY220 SetVariable q_pos,pos={ 83,132},size={85,17},title="q "232 SetVariable qyval,format="%+7.5f",limits={-Inf,Inf,0*sc},value= root:Packages:NIST:VSANS:Globals:gQY 233 SetVariable q_pos,pos={sc*83,132*sc},size={sc*85,17*sc},title="q " 221 234 SetVariable q_pos,help={"q-value on the detector at (x,y)"},format="%+7.5f" 222 SetVariable q_pos,limits={-Inf,Inf,0 },value= root:Packages:NIST:VSANS:Globals:gQQ,frame=0,noedit=1235 SetVariable q_pos,limits={-Inf,Inf,0*sc},value= root:Packages:NIST:VSANS:Globals:gQQ,frame=0,noedit=1 223 236 224 237 Make/O/D tmp_asdf 225 238 // for back panels (in pixels) 226 239 // Display/W=(50,185,545,620)/HOST=# tmp_asdf 227 Display/W=(50 ,185,517,620)/HOST=# tmp_asdf240 Display/W=(50*sc,185*sc,517*sc,620*sc)/HOST=# tmp_asdf 228 241 RenameWindow #,det_panelsB 229 242 ModifyGraph mode=2 // mode = 2 = dots … … 236 249 237 250 // for middle panels (in pixels?) 238 Display/W=(50 ,185,517,620)/HOST=# tmp_asdf251 Display/W=(50*sc,185*sc,517*sc,620*sc)/HOST=# tmp_asdf 239 252 RenameWindow #,det_panelsM 240 253 ModifyGraph mode=2 // mode = 2 = dots … … 247 260 248 261 // for front panels (in pixels?) 249 Display/W=(50 ,185,517,620)/HOST=# tmp_asdf262 Display/W=(50*sc,185*sc,517*sc,620*sc)/HOST=# tmp_asdf 250 263 RenameWindow #,det_panelsF 251 264 ModifyGraph mode=2 // mode = 2 = dots … … 276 289 277 290 Variable hookResult = 0 291 292 Variable sc = 1 293 294 NVAR gLaptopMode = root:Packages:NIST:VSANS:Globals:gLaptopMode 295 296 if(gLaptopMode == 1) 297 sc = 0.7 298 endif 278 299 279 300 switch(s.eventCode) … … 317 338 // if out of bounds, exit now 318 339 // TODO - currently the values are hard-wired. eliminate this later if the size of the graph changes 319 if(s.mouseLoc.h < 50 || s.mouseLoc.h > 545 || s.mouseLoc.v < 185 || s.mouseLoc.v > 620)340 if(s.mouseLoc.h < 50*sc || s.mouseLoc.h > 545*sc || s.mouseLoc.v < 185*sc || s.mouseLoc.v > 620*sc) 320 341 break 321 342 endif … … 481 502 STRUCT WMTabControlAction &tca 482 503 504 505 Variable sc = 1 506 507 NVAR gLaptopMode = root:Packages:NIST:VSANS:Globals:gLaptopMode 508 509 if(gLaptopMode == 1) 510 sc = 0.7 511 endif 512 483 513 switch( tca.eventCode ) 484 514 case 2: // mouse up … … 546 576 ModifyImage/W=VSANS_Data#det_panelsB ''#0 ctab= {lo_B,hi_B,ColdWarm,0} // don't autoscale {*,*,ColdWarm,0} 547 577 endif 548 MoveSubWindow/W=VSANS_Data#det_panelsB fnum=(50 ,185,517,620)549 MoveSubWindow/W=VSANS_Data#det_panelsM fnum=(320 ,70,430,160)550 MoveSubWindow/W=VSANS_Data#det_panelsF fnum=(200 ,70,310,160)578 MoveSubWindow/W=VSANS_Data#det_panelsB fnum=(50*sc,185*sc,517*sc,620*sc) 579 MoveSubWindow/W=VSANS_Data#det_panelsM fnum=(320*sc,70*sc,430*sc,160*sc) 580 MoveSubWindow/W=VSANS_Data#det_panelsF fnum=(200*sc,70*sc,310*sc,160*sc) 551 581 552 582 ModifyImage/W=VSANS_Data#det_panelsB ''#0 ctabAutoscale=0,lookup= LookupWave … … 603 633 ModifyImage/W=VSANS_Data#det_panelsM ''#3 ctab= {lo_MR,hi_MR,ColdWarm,0} 604 634 endif 605 MoveSubWindow/W=VSANS_Data#det_panelsM fnum=(50 ,185,517,620)606 MoveSubWindow/W=VSANS_Data#det_panelsB fnum=(440 ,70,550,160)607 MoveSubWindow/W=VSANS_Data#det_panelsF fnum=(200 ,70,310,160)635 MoveSubWindow/W=VSANS_Data#det_panelsM fnum=(50*sc,185*sc,517*sc,620*sc) 636 MoveSubWindow/W=VSANS_Data#det_panelsB fnum=(440*sc,70*sc,550*sc,160*sc) 637 MoveSubWindow/W=VSANS_Data#det_panelsF fnum=(200*sc,70*sc,310*sc,160*sc) 608 638 609 639 ModifyImage/W=VSANS_Data#det_panelsM ''#0 ctabAutoscale=0,lookup= LookupWave … … 661 691 ModifyImage/W=VSANS_Data#det_panelsF ''#3 ctab= {lo_FR,hi_FR,ColdWarm,0} 662 692 endif 663 MoveSubWindow/W=VSANS_Data#det_panelsF fnum=(50 ,185,517,620)664 MoveSubWindow/W=VSANS_Data#det_panelsB fnum=(440 ,70,550,160)665 MoveSubWindow/W=VSANS_Data#det_panelsM fnum=(320 ,70,430,160)693 MoveSubWindow/W=VSANS_Data#det_panelsF fnum=(50*sc,185*sc,517*sc,620*sc) 694 MoveSubWindow/W=VSANS_Data#det_panelsB fnum=(440*sc,70*sc,550*sc,160*sc) 695 MoveSubWindow/W=VSANS_Data#det_panelsM fnum=(320*sc,70*sc,430*sc,160*sc) 666 696 667 697 ModifyImage/W=VSANS_Data#det_panelsF ''#0 ctabAutoscale=0,lookup= LookupWave -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_RealTimeUpdate.ipf
r1242 r1246 126 126 //draws the RT panel and enforces bounds on the SetVariable controls for update period and timeout 127 127 // 128 Proc VSANS_RT_Panel() 128 Proc VSANS_RT_Panel() 129 Variable sc = 1 130 131 if(root:Packages:NIST:VSANS:Globals:gLaptopMode == 1) 132 sc = 0.7 133 endif 134 129 135 PauseUpdate; Silent 1 // building window... 130 NewPanel /W=(300 ,350,602,580) /K=2 // force the user to close using done136 NewPanel /W=(300*sc,350*sc,602*sc,580*sc) /K=2 // force the user to close using done 131 137 DoWindow/C VSANS_RT_Panel 132 138 DoWindow/T RT_Panel,"Real Time Display Controls" 133 139 ModifyPanel cbRGB=(65535,52428,6168) 134 140 SetDrawLayer UserBack 135 SetDrawEnv fstyle= 1 136 DrawText 26 ,21,"Enter values for real-time display"137 Button bkgStart,pos={ 171,54},size={120,20},proc=V_UpdateHSTButton,title="Start Updating"141 SetDrawEnv fstyle= 1,fsize=14*sc 142 DrawText 26*sc,21*sc,"Enter values for real-time display" 143 Button bkgStart,pos={sc*171,54*sc},size={sc*120,20*sc},proc=V_UpdateHSTButton,title="Start Updating" 138 144 Button bkgStart,help={"Starts or stops the updating of the real-time SANS image"} 139 // SetVariable setvar_0,pos={ 15,29},size={100,15},proc=RT_Param_SetVarProc,title="X Center"145 // SetVariable setvar_0,pos={sc*15,29*sc},size={sc*100,15*sc},proc=RT_Param_SetVarProc,title="X Center" 140 146 // SetVariable setvar_0,help={"Set this to the current beamcenter x-coordinate (in pixels)"} 141 147 // SetVariable setvar_0,limits={0,128,0},value= root:myGlobals:RT:xCtr 142 // SetVariable setvar_1,pos={ 14,46},size={100,15},proc=RT_Param_SetVarProc,title="Y Center"148 // SetVariable setvar_1,pos={sc*14,46*sc},size={sc*100,15*sc},proc=RT_Param_SetVarProc,title="Y Center" 143 149 // SetVariable setvar_1,help={"Set this to the current beamcenter y-coordinate (in pixels)"} 144 150 // SetVariable setvar_1,limits={0,128,0},value= root:myGlobals:RT:yCtr 145 // SetVariable setvar_2,pos={ 14,64},size={100,15},proc=RT_Param_SetVarProc,title="SDD (m)"151 // SetVariable setvar_2,pos={sc*14,64*sc},size={sc*100,15*sc},proc=RT_Param_SetVarProc,title="SDD (m)" 146 152 // SetVariable setvar_2,help={"Set this to the sample-to-detector distance of the current instrument configuration"} 147 153 // SetVariable setvar_2,limits={0,1600,0},value= root:myGlobals:RT:SDD 148 // SetVariable setvar_3,pos={ 15,82},size={100,15},proc=RT_Param_SetVarProc,title="Lambda (A)"154 // SetVariable setvar_3,pos={sc*15,82*sc},size={sc*100,15*sc},proc=RT_Param_SetVarProc,title="Lambda (A)" 149 155 // SetVariable setvar_3,help={"Set this to the wavelength of the current instrument configuration"} 150 156 // SetVariable setvar_3,limits={0,30,0},value= root:myGlobals:RT:lambda 151 SetVariable setvar_4,pos={ 11,31},size={150,20},proc=V_UpdateInt_SetVarProc,title="Update Interval (s)"157 SetVariable setvar_4,pos={sc*11,31*sc},size={sc*150,20*sc},proc=V_UpdateInt_SetVarProc,title="Update Interval (s)" 152 158 SetVariable setvar_4,help={"This is the period of the update"} 153 159 SetVariable setvar_4,limits={1,3600,0},value= root:Packages:NIST:VSANS:Globals:RT:updateInt 154 // SetVariable setvar_5,pos={ 11,56},size={150,20},title="Timeout Interval (s)"160 // SetVariable setvar_5,pos={sc*11,56*sc},size={sc*150,20*sc},title="Timeout Interval (s)" 155 161 // SetVariable setvar_5,help={"After the timeout interval has expired, the update process will automatically stop"} 156 162 // SetVariable setvar_5,limits={1,3600,0},value= root:myGlobals:RT:timeout 157 Button button_1,pos={ 170,29},size={120,20},proc=V_LoadRTButtonProc,title="Load Live Data"163 Button button_1,pos={sc*170,29*sc},size={sc*120,20*sc},proc=V_LoadRTButtonProc,title="Load Live Data" 158 164 Button button_1,help={"Load the data file for real-time display"} 159 Button button_2,pos={ 250,2},size={30,20},proc=V_RT_HelpButtonProc,title="?"165 Button button_2,pos={sc*250,2*sc},size={sc*30,20*sc},proc=V_RT_HelpButtonProc,title="?" 160 166 Button button_2,help={"Display the help file for real-time controls"} 161 Button button_3,pos={ 230,200},size={60,20},proc=V_RT_DoneButtonProc,title="Done"167 Button button_3,pos={sc*230,200*sc},size={sc*60,20*sc},proc=V_RT_DoneButtonProc,title="Done" 162 168 Button button_3,help={"Closes the panel and stops the updating process"} 163 SetVariable setvar_6,pos={ 11,105},size={250,20},title="Total Detector Counts"169 SetVariable setvar_6,pos={sc*11,105*sc},size={sc*250,20*sc},title="Total Detector Counts" 164 170 SetVariable setvar_6,help={"Total counts on the detector, as displayed"},noedit=1 165 171 SetVariable setvar_6,limits={0,Inf,0},value= root:Packages:NIST:VSANS:Globals:RT:totalCounts 166 SetVariable setvar_7,pos={ 11,82},size={250,20},title=" Count Time"172 SetVariable setvar_7,pos={sc*11,82*sc},size={sc*250,20*sc},title=" Count Time" 167 173 SetVariable setvar_7,help={"Count time, as displayed"},noedit=1 168 174 SetVariable setvar_7,limits={0,Inf,0},value= root:Packages:NIST:VSANS:Globals:RT:countTime 169 SetVariable setvar_8,pos={ 11,127},size={250,20},title=" Detector Count Rate"175 SetVariable setvar_8,pos={sc*11,127*sc},size={sc*250,20*sc},title=" Detector Count Rate" 170 176 SetVariable setvar_8,help={"Count rate, as displayed"},noedit=1 171 177 SetVariable setvar_8,limits={0,Inf,0},value= root:Packages:NIST:VSANS:Globals:RT:countRate 172 SetVariable setvar_9,pos={ 11,149},size={250,20},title=" Monitor Counts"178 SetVariable setvar_9,pos={sc*11,149*sc},size={sc*250,20*sc},title=" Monitor Counts" 173 179 SetVariable setvar_9,help={"Count rate, as displayed"},noedit=1 174 180 SetVariable setvar_9,limits={0,Inf,0},value= root:Packages:NIST:VSANS:Globals:RT:monitorCounts 175 SetVariable setvar_10,pos={ 11,171},size={250,20},title=" Monitor Count Rate"181 SetVariable setvar_10,pos={sc*11,171*sc},size={sc*250,20*sc},title=" Monitor Count Rate" 176 182 SetVariable setvar_10,help={"Count rate, as displayed"},noedit=1 177 183 SetVariable setvar_10,limits={0,Inf,0},value= root:Packages:NIST:VSANS:Globals:RT:monitorCountRate … … 515 521 Function V_ShowOnlineReductionPanel() 516 522 523 Variable sc = 1 524 525 NVAR gLaptopMode = root:Packages:NIST:VSANS:Globals:gLaptopMode 526 527 if(gLaptopMode == 1) 528 sc = 0.7 529 endif 530 517 531 //check for the path 518 532 PathInfo catPathName … … 536 550 // panel 537 551 PauseUpdate; Silent 1 538 NewPanel /W=(300 ,350,702,481) /K=2 //K=2 to force exit using "done" button to exit the background procedure552 NewPanel /W=(300*sc,350*sc,702*sc,481*sc) /K=2 //K=2 to force exit using "done" button to exit the background procedure 539 553 540 554 DoWindow/C V_ORPanel … … 546 560 547 561 // filename 548 GroupBox group_Flename pos={ 6,top}, size={groupWidth,18+26}, title="select file for online reduction:"549 PopupMenu popup_Filename pos={ 12,top+18}, size={groupWidth-12-0,20}, title=""550 PopupMenu popup_Filename mode=1, value=V_GetRawDataFileList(), bodyWidth= groupWidth-12-0562 GroupBox group_Flename pos={sc*6,top*sc}, size={sc*groupWidth,(18+26)*sc}, title="select file for online reduction:" 563 PopupMenu popup_Filename pos={sc*12,(top+18)*sc}, size={sc*(groupWidth-12-0),20*sc}, title="" 564 PopupMenu popup_Filename mode=1, value=V_GetRawDataFileList(), bodyWidth=sc*(groupWidth-12-0) 551 565 PopupMenu popup_Filename proc=V_ORPopupSelectFileProc 552 566 … … 561 575 562 576 // protocol 563 GroupBox group_Protocol pos={ 6,top}, size={groupWidth,18+22}, title="select protocol for online reduction:"564 SetVariable setvar_Protocol pos={ 12,top+18}, size={groupWidth-12-18,0}, title=" "577 GroupBox group_Protocol pos={sc*6,top*sc}, size={sc*groupWidth,(18+22)*sc}, title="select protocol for online reduction:" 578 SetVariable setvar_Protocol pos={sc*12,(top+18)*sc}, size={sc*(groupWidth-12-18),0*sc}, title=" " 565 579 SetVariable setvar_Protocol value=root:Packages:NIST:VSANS:Globals:OnlineReduction:Protocol 566 580 567 Button button_SelectProtocol pos={ 12+groupWidth-12-18,top+18-1}, size={18,18}, title="...", proc=V_ORButtonSelectProtocolProc581 Button button_SelectProtocol pos={sc*(12+groupWidth-12-18),(top+18-1)*sc}, size={sc*18,18*sc}, title="...", proc=V_ORButtonSelectProtocolProc 568 582 569 583 top += 18+22+7 … … 571 585 572 586 // sart, stop, done 573 Button button_Start pos={ left + 70 * 0, top}, size={60,20}, title="Start", proc=V_ORButtonStartProc574 Button button_Stop pos={ left + 70 * 1, top}, size={60,20}, title="Stop", proc=V_ORButtonStopProc, disable=2575 Button button_Done pos={ left + 70 * 2, top}, size={60,20}, title="Done", proc=V_ORButtonDoneProc587 Button button_Start pos={sc*(left + 70 * 0), top*sc}, size={sc*60,20*sc}, title="Start", proc=V_ORButtonStartProc 588 Button button_Stop pos={sc*(left + 70 * 1), top*sc}, size={sc*60,20*sc}, title="Stop", proc=V_ORButtonStopProc, disable=2 589 Button button_Done pos={sc*(left + 70 * 2), top*sc}, size={sc*60,20*sc}, title="Done", proc=V_ORButtonDoneProc 576 590 577 591 end -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_Transmission.ipf
r1242 r1246 51 51 52 52 Window V_TransmissionPanel() : Panel 53 54 Variable sc = 1 55 56 if(root:Packages:NIST:VSANS:Globals:gLaptopMode == 1) 57 sc = 0.7 58 endif 59 53 60 PauseUpdate; Silent 1 // building window... 54 NewPanel /W=(1496 ,366,1974,990) /K=161 NewPanel /W=(1496*sc,366*sc,1950*sc,940*sc) /K=1 55 62 ModifyPanel cbRGB=(32896,16448,0,19621) 56 63 DoWindow/C V_TransmissionPanel 57 64 58 65 // ShowTools/A 59 PopupMenu popup_0,pos={ 16.00,359.00},size={104.00,23.00},fstyle=1,fsize=12,proc=V_TSamFilePopMenuProc,title="Sample"66 PopupMenu popup_0,pos={sc*16.00,359.00*sc},size={sc*104.00,23.00*sc},fstyle=1,fsize=12*sc,proc=V_TSamFilePopMenuProc,title="Sample" 60 67 PopupMenu popup_0,mode=1,popvalue="_none_",value= #"root:Packages:NIST:VSANS:Globals:Transmission:gSamMatchList" 61 PopupMenu popup_1,pos={ 12.00,229.00},size={195.00,23.00},fstyle=1,fsize=12,proc=V_TTransmFilePopMenuProc,title="Transmission"68 PopupMenu popup_1,pos={sc*12.00,229.00*sc},size={sc*195.00,23.00*sc},fstyle=1,fsize=12*sc,proc=V_TTransmFilePopMenuProc,title="Transmission" 62 69 PopupMenu popup_1,mode=1,popvalue="_none_",value = #"root:Packages:NIST:VSANS:Globals:Transmission:gTransMatchList"//value= V_getFilePurposeList("TRANSMISSION",0) 63 PopupMenu popup_2,pos={ 17.00,79.00},size={188.00,23.00},fstyle=1,fsize=12,proc=V_TEmpBeamPopMenuProc,title="Open Beam"70 PopupMenu popup_2,pos={sc*17.00,79.00*sc},size={sc*188.00,23.00*sc},fstyle=1,fsize=12*sc,proc=V_TEmpBeamPopMenuProc,title="Open Beam" 64 71 PopupMenu popup_2,mode=1,popvalue="sans1.nxs.ngv",value= V_getFileIntentList("OPEN BEAM",0) 65 Button button_0,pos={ 34.00,499.00},size={100.00,20.00},proc=V_CalcTransmButtonProc,title="Calculate"66 Button button_2,pos={ 349.00,13.00},size={30.00,20.00},proc=V_HelpTransmButtonProc,title="?"67 Button button_3,pos={ 410.00,13.00},size={50.00,20.00},proc=V_DoneTransmButtonProc,title="Done"68 Button button_4,pos={ 164.00,500.00},size={150.00,20.00},proc=V_CalcTransmListButtonProc,title="Calculate All In Popup"69 SetVariable setvar_0,pos={ 18.00,390.00},size={300.00,14.00},title="Label:"72 Button button_0,pos={sc*34.00,499.00*sc},size={sc*100.00,20.00*sc},proc=V_CalcTransmButtonProc,title="Calculate" 73 Button button_2,pos={sc*340.00,13.00*sc},size={sc*30.00,20.00*sc},proc=V_HelpTransmButtonProc,title="?" 74 Button button_3,pos={sc*380.00,13.00*sc},size={sc*50.00,20.00*sc},proc=V_DoneTransmButtonProc,title="Done" 75 Button button_4,pos={sc*164.00,500.00*sc},size={sc*150.00,20.00*sc},proc=V_CalcTransmListButtonProc,title="Calculate All In Popup" 76 SetVariable setvar_0,pos={sc*18.00,390.00*sc},size={sc*300.00,14.00*sc},title="Label:" 70 77 SetVariable setvar_0,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gSamLabel 71 SetVariable setvar_1,pos={ 18.00,417.00},size={300.00,14.00},title="Group ID:"78 SetVariable setvar_1,pos={sc*18.00,417.00*sc},size={sc*300.00,14.00*sc},title="Group ID:" 72 79 SetVariable setvar_1,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gSamGrpID 73 SetVariable setvar_2,pos={ 15.00,257.00},size={300.00,14.00},title="Label:"80 SetVariable setvar_2,pos={sc*15.00,257.00*sc},size={sc*300.00,14.00*sc},title="Label:" 74 81 SetVariable setvar_2,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gTransLabel 75 SetVariable setvar_3,pos={ 14.00,283.00},size={300.00,14.00},title="Group ID:"82 SetVariable setvar_3,pos={sc*14.00,283.00*sc},size={sc*300.00,14.00*sc},title="Group ID:" 76 83 SetVariable setvar_3,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gTrnGrpID 77 SetVariable setvar_4,pos={ 18.00,108.00},size={300.00,14.00},title="Label:"84 SetVariable setvar_4,pos={sc*18.00,108.00*sc},size={sc*300.00,14.00*sc},title="Label:" 78 85 SetVariable setvar_4,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gEmptyLabel 79 SetVariable setvar_5,pos={ 18.00,132.00},size={300.00,14.00},title="XY Box:"86 SetVariable setvar_5,pos={sc*18.00,132.00*sc},size={sc*300.00,14.00*sc},title="XY Box:" 80 87 SetVariable setvar_5,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gEmptyBoxCoord 81 SetVariable setvar_6,pos={ 18.00,157.00},size={300.00,14.00},fstyle=1,fsize=12,title="Panel:"88 SetVariable setvar_6,pos={sc*18.00,157.00*sc},size={sc*300.00,14.00*sc},title="Panel:" //,fstyle=1,fsize=12*sc 82 89 SetVariable setvar_6,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gEmptyPanel 83 SetVariable setvar_7,pos={ 18.00,442.00},size={300.00,14.00},title="Transmission:"90 SetVariable setvar_7,pos={sc*18.00,442.00*sc},size={sc*300.00,14.00*sc},title="Transmission:" 84 91 SetVariable setvar_7,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gTrans 85 SetVariable setvar_8,pos={ 18.00,467.00},size={300.00,14.00},title="Error:"92 SetVariable setvar_8,pos={sc*18.00,467.00*sc},size={sc*300.00,14.00*sc},title="Error:" 86 93 SetVariable setvar_8,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gTransErr 87 94 EndMacro 88 95 89 96 90 //Window V_TransmissionPanel() : Panel 91 // PauseUpdate; Silent 1 // building window... 92 // NewPanel /W=(1286,328,1764,952) 93 // ModifyPanel cbRGB=(32896,16448,0,19621) 94 // DoWindow/C V_TransmissionPanel 95 // 96 //// ShowTools/A 97 // PopupMenu popup_0,pos={19.00,55.00},size={86.00,23.00},proc=V_TSamFilePopMenuProc,title="Sample" 98 //// PopupMenu popup_0,mode=1,value= V_getFilePurposeList("SCATTERING",0)//+V_getFileIntentList("EMPTY CELL",0) 99 // PopupMenu popup_0,mode=1,value=root:Packages:NIST:VSANS:Globals:Transmission:gSamMatchList 100 // PopupMenu popup_1,pos={102,248},size={72.00,23.00},proc=V_TTransmFilePopMenuProc,title="Transmission" 101 // PopupMenu popup_1,mode=1,value= V_getFilePurposeList("TRANSMISSION",0) 102 // PopupMenu popup_2,pos={164,353},size={72.00,23.00},proc=V_TEmpBeamPopMenuProc,title="Open Beam" 103 //// PopupMenu popup_2,mode=1,value= V_getFileIntentList("EMPTY BEAM",0) 104 // PopupMenu popup_2,mode=1,value= V_getFileIntentList("OPEN BEAM",0) 105 // Button button_0,pos={37,193},size={100.00,20.00},proc=V_CalcTransmButtonProc,title="Calculate" 106 //// Button button_1,pos={23.00,491.00},size={100.00,20.00},proc=V_WriteTransmButtonProc,title="Write" 107 // Button button_2,pos={349.00,13.00},size={30.00,20.00},proc=V_HelpTransmButtonProc,title="?" 108 // Button button_3,pos={410.00,13.00},size={50.00,20.00},proc=V_DoneTransmButtonProc,title="Done" 109 // SetVariable setvar_0,pos={21.00,86.00},size={300.00,14.00},title="Label:" 110 // SetVariable setvar_0,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gSamLabel 111 // SetVariable setvar_1,pos={21.00,113.00},size={300.00,14.00},title="Group ID:" 112 // SetVariable setvar_1,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gSamGrpID 113 // SetVariable setvar_2,pos={105,276.00},size={300.00,14.00},title="Label:" 114 // SetVariable setvar_2,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gTransLabel 115 // SetVariable setvar_3,pos={104,302},size={300.00,14.00},title="Group ID:" 116 // SetVariable setvar_3,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gTrnGrpID 117 // SetVariable setvar_4,pos={165,382},size={300.00,14.00},title="Label:" 118 // SetVariable setvar_4,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gEmptyLabel 119 // SetVariable setvar_5,pos={165,406},size={300.00,14.00},title="XY Box:" 120 // SetVariable setvar_5,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gEmptyBoxCoord 121 // SetVariable setvar_6,pos={165,431},size={300.00,14.00},title="Panel:" 122 // SetVariable setvar_6,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gEmptyPanel 123 // SetVariable setvar_7,pos={21,138},size={300.00,14.00},title="Transmission:" 124 // SetVariable setvar_7,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gTrans 125 // SetVariable setvar_8,pos={21,163},size={300.00,14.00},title="Error:" 126 // SetVariable setvar_8,limits={-inf,inf,0},value= root:Packages:NIST:VSANS:Globals:Transmission:gTransErr 127 //EndMacro 97 128 98 129 99 // TODO -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_Utilities_General.ipf
r1243 r1246 178 178 // there are some folders to kill, so proceed 179 179 180 NewPanel /N=ProgressPanel /W=(285,111,739,193) 181 ValDisplay valdisp0,win=ProgressPanel,pos={18,32},size={342,18},limits={0,num,0},barmisc={0,0} 180 Variable sc = 1 181 182 NVAR gLaptopMode = root:Packages:NIST:VSANS:Globals:gLaptopMode 183 184 if(gLaptopMode == 1) 185 sc = 0.7 186 endif 187 188 NewPanel /N=ProgressPanel /W=(285*sc,111*sc,739*sc,193*sc) 189 ValDisplay valdisp0,win=ProgressPanel,pos={sc*18,32*sc},size={sc*342,18*sc},limits={0,num,0},barmisc={0,0} 182 190 ValDisplay valdisp0,win=ProgressPanel,value= _NUM:0 183 DrawText 20 ,24,"Cleaning up old files... Please Wait..."191 DrawText 20*sc,24*sc,"Cleaning up old files... Please Wait..." 184 192 185 193 if( indefinite ) … … 191 199 ValDisplay valdisp0,win=ProgressPanel,highColor=(15000,45535,15000) //(0,65535,0) 192 200 endif 193 Button bStop,win=ProgressPanel,pos={ 375,32},size={50,20},title="Stop"201 Button bStop,win=ProgressPanel,pos={sc*375,32*sc},size={sc*50,20*sc},title="Stop" 194 202 DoUpdate /W=ProgressPanel /E=1 // mark this as our progress window 195 203 -
sans/Dev/trunk/NCNR_User_Procedures/Reduction/VSANS/V_VSANS_Preferences.ipf
r1242 r1246 53 53 val = NumVarOrDefault("root:Packages:NIST:VSANS:Globals:gXML_Write", 0 ) 54 54 Variable/G root:Packages:NIST:VSANS:Globals:gXML_Write = val 55 55 56 // flag to set "Laptop Mode" where the panels are drawn smaller and onscreen 57 val = NumVarOrDefault("root:Packages:NIST:VSANS:Globals:gLaptopMode", 0 ) 58 Variable/G root:Packages:NIST:VSANS:Globals:gLaptopMode = val 56 59 57 60 // VSANS tab … … 123 126 // endif 124 127 endif 125 128 129 130 DoAlert 1,"Do you want small panels? (this can be changed later in preferences)" 131 if(V_flag == 1) 132 // yes 133 Variable/G root:Packages:NIST:VSANS:Globals:gLaptopMode = 1 134 endif 126 135 // flag to allow adding raw data files with different attenuation (normally not done) 127 136 // val = NumVarOrDefault("root:Packages:NIST:VSANS:Globals:gDoAdjustRAW_Atten",0) … … 131 140 // VSANS ANALYSIS tab 132 141 /// items for VSANS Analysis 142 143 133 144 134 145 … … 272 283 End 273 284 285 Function V_LaptopModePref(ctrlName,checked) : CheckBoxControl 286 String ctrlName 287 Variable checked 288 289 NVAR gVal = root:Packages:NIST:VSANS:Globals:gLaptopMode 290 gVal = checked 291 End 292 293 294 295 274 296 Function V_PrefDoneButtonProc(ctrlName) : ButtonControl 275 297 String ctrlName … … 280 302 281 303 Proc VSANSPref_Panel() 304 Variable sc=1 305 306 if(root:Packages:NIST:VSANS:Globals:gLaptopMode == 1) 307 sc = 0.7 308 endif 309 282 310 PauseUpdate; Silent 1 // building window... 283 NewPanel /W=(646 ,208,1070,468)/K=2 as "VSANS Preference Panel"311 NewPanel /W=(646*sc,208*sc,1070*sc,468*sc)/K=2 as "VSANS Preference Panel" 284 312 DoWindow/C VSANSPref_Panel 285 313 ModifyPanel cbRGB=(47748,57192,54093) … … 288 316 ////// 289 317 //on main portion of panel, always visible 290 Button PrefPanelButtonA,pos={354 ,12},size={50,20},proc=V_PrefDoneButtonProc,title="Done"291 292 TabControl PrefTab,pos={7 ,49},size={410,202},tabLabel(0)="General",proc=V_PrefTabProc318 Button PrefPanelButtonA,pos={354*sc,12*sc},size={50*sc,20*sc},proc=V_PrefDoneButtonProc,title="Done" 319 320 TabControl PrefTab,pos={7*sc,49*sc},size={410*sc,202*sc},tabLabel(0)="General",proc=V_PrefTabProc 293 321 TabControl PrefTab,tabLabel(1)="VSANS",tabLabel(2)="Analysis" 294 322 TabControl PrefTab,value=1 … … 296 324 297 325 //on tab(0) - General 298 CheckBox PrefCtrl_0a,pos={21 ,96},size={124,14},proc=V_XMLWritePref,title="Use canSAS XML Output"326 CheckBox PrefCtrl_0a,pos={21*sc,96*sc},size={124*sc,14*sc},proc=V_XMLWritePref,title="Use canSAS XML Output" 299 327 CheckBox PrefCtrl_0a,help={"Checking this will set the default output format to be canSAS XML rather than NIST 6 column"} 300 328 CheckBox PrefCtrl_0a,value= root:Packages:NIST:VSANS:Globals:gXML_Write 329 CheckBox PrefCtrl_0b,pos={21*sc,120*sc},size={124*sc,14*sc},proc=V_LaptopModePref,title="Laptop Mode for Panels" 330 CheckBox PrefCtrl_0b,help={"Checking this will draw panels smaller to fit on a 1920x1080 laptop screen"} 331 CheckBox PrefCtrl_0b,value= root:Packages:NIST:VSANS:Globals:gLaptopMode 301 332 302 333 CheckBox PrefCtrl_0a,disable=1 334 CheckBox PrefCtrl_0b,disable=1 303 335 304 336 305 337 //on tab(1) - VSANS - initially visible 306 CheckBox PrefCtrl_1a,pos={21 ,80},size={171,14},proc=V_LogScalePrefCheck,title="Use Log scaling for 2D data display"338 CheckBox PrefCtrl_1a,pos={21*sc,80*sc},size={171*sc,14*sc},proc=V_LogScalePrefCheck,title="Use Log scaling for 2D data display" 307 339 CheckBox PrefCtrl_1a,help={"Checking this will display 2D VSANS data with a logarithmic color scale of neutron counts. If not checked, the color mapping will be linear."} 308 340 CheckBox PrefCtrl_1a,value= root:Packages:NIST:VSANS:Globals:gLogScalingAsDefault … … 310 342 // CheckBox PrefCtrl_1b,help={"Checking this will allow DRK correction to be used in reduction protocols. You will need to re-draw the protocol panel for this change to be visible."} 311 343 // CheckBox PrefCtrl_1b,value= root:Packages:NIST:VSANS:Globals:gAllowDRK 312 CheckBox PrefCtrl_1c,pos={21 ,100},size={137,14},proc=V_UnityTransPref,title="Check for Transmission = 1"344 CheckBox PrefCtrl_1c,pos={21*sc,100*sc},size={137*sc,14*sc},proc=V_UnityTransPref,title="Check for Transmission = 1" 313 345 CheckBox PrefCtrl_1c,help={"Checking this will check for SAM or EMP Trans = 1 during data correction"} 314 346 CheckBox PrefCtrl_1c,value= root:Packages:NIST:VSANS:Globals:gDoTransCheck 315 SetVariable PrefCtrl_1d,pos={21 ,130},size={200,15},title="Averaging Bin Width (pixels)"347 SetVariable PrefCtrl_1d,pos={21*sc,130*sc},size={200*sc,15*sc},title="Averaging Bin Width (pixels)" 316 348 SetVariable PrefCtrl_1d,limits={1,100,1},value= root:Packages:NIST:VSANS:Globals:gBinWidth 317 SetVariable PrefCtrl_1e,pos={21 ,155},size={200,15},title="# Phi Steps (annular avg)"349 SetVariable PrefCtrl_1e,pos={21*sc,155*sc},size={200*sc,15*sc},title="# Phi Steps (annular avg)" 318 350 SetVariable PrefCtrl_1e,limits={1,360,1},value= root:Packages:NIST:VSANS:Globals:gNPhiSteps 319 SetVariable PrefCtrl_1p,pos={21 ,180},size={200,15},title="Window Transmission"351 SetVariable PrefCtrl_1p,pos={21*sc,180*sc},size={200*sc,15*sc},title="Window Transmission" 320 352 SetVariable PrefCtrl_1p,limits={0.01,1,0.001},value= root:Packages:NIST:VSANS:Globals:gDownstreamWinTrans 321 353 322 354 323 CheckBox PrefCtrl_1f title="Do Transmssion Correction?",size={140 ,14},value=root:Packages:NIST:VSANS:Globals:gDoTransmissionCor,proc=V_DoTransCorrPref324 CheckBox PrefCtrl_1f pos={255 ,80},help={"TURN OFF ONLY FOR DEBUGGING. This corrects the data for angle dependent transmssion."}325 CheckBox PrefCtrl_1g title="Do Tube Efficiency+Shadowing?",size={140 ,14},proc=V_DoEfficiencyCorrPref326 CheckBox PrefCtrl_1g value=root:Packages:NIST:VSANS:Globals:gDoTubeShadowCor,pos={255 ,100},help={"TURN OFF ONLY FOR DEBUGGING. This corrects the data for angle dependent detector efficiency."}355 CheckBox PrefCtrl_1f title="Do Transmssion Correction?",size={140*sc,14*sc},value=root:Packages:NIST:VSANS:Globals:gDoTransmissionCor,proc=V_DoTransCorrPref 356 CheckBox PrefCtrl_1f pos={255*sc,80*sc},help={"TURN OFF ONLY FOR DEBUGGING. This corrects the data for angle dependent transmssion."} 357 CheckBox PrefCtrl_1g title="Do Tube Efficiency+Shadowing?",size={140*sc,14*sc},proc=V_DoEfficiencyCorrPref 358 CheckBox PrefCtrl_1g value=root:Packages:NIST:VSANS:Globals:gDoTubeShadowCor,pos={255*sc,100*sc},help={"TURN OFF ONLY FOR DEBUGGING. This corrects the data for angle dependent detector efficiency."} 327 359 // CheckBox PrefCtrl_1h title="Adjust RAW attenuation?",size={140,14},proc=V_DoRawAttenAdjPref 328 360 // CheckBox PrefCtrl_1h value=root:Packages:NIST:VSANS:Globals:gDoAdjustRAW_Atten,pos={255,140},help={"This is normally not done"} 329 361 330 CheckBox PrefCtrl_1i title="Do DIV Correction?",size={140 ,14},proc=V_DoDIVCorPref331 CheckBox PrefCtrl_1i value=root:Packages:NIST:VSANS:Globals:gDoDIVCor,pos={255 ,120},help={"TURN OFF ONLY FOR DEBUGGING."}332 CheckBox PrefCtrl_1j title="Do DeadTime Correction?",size={140 ,14},proc=V_DoDeadTimeCorPref333 CheckBox PrefCtrl_1j value=root:Packages:NIST:VSANS:Globals:gDoDeadTimeCor,pos={255 ,140},help={"TURN OFF ONLY FOR DEBUGGING."}334 CheckBox PrefCtrl_1k title="Do Solid Angle Correction?",size={140 ,14},proc=V_DoSolidAngleCorPref335 CheckBox PrefCtrl_1k value=root:Packages:NIST:VSANS:Globals:gDoSolidAngleCor,pos={255 ,160},help={"TURN OFF ONLY FOR DEBUGGING."}336 CheckBox PrefCtrl_1l title="Do Non-linear Correction?",size={140 ,14},proc=V_DoNonLinearCorPref,disable=2337 CheckBox PrefCtrl_1l value=root:Packages:NIST:VSANS:Globals:gDoNonLinearCor,pos={255 ,180},help={"Non-linear correction can't be turned off"}338 CheckBox PrefCtrl_1m title="Do Downstream Window Corr?",size={140 ,14},proc=V_DoDownstreamWindowCorPref339 CheckBox PrefCtrl_1m value=root:Packages:NIST:VSANS:Globals:gDoDownstreamWindowCor,pos={255 ,200},help={"TURN OFF ONLY FOR DEBUGGING."}362 CheckBox PrefCtrl_1i title="Do DIV Correction?",size={140*sc,14*sc},proc=V_DoDIVCorPref 363 CheckBox PrefCtrl_1i value=root:Packages:NIST:VSANS:Globals:gDoDIVCor,pos={255*sc,120*sc},help={"TURN OFF ONLY FOR DEBUGGING."} 364 CheckBox PrefCtrl_1j title="Do DeadTime Correction?",size={140*sc,14*sc},proc=V_DoDeadTimeCorPref 365 CheckBox PrefCtrl_1j value=root:Packages:NIST:VSANS:Globals:gDoDeadTimeCor,pos={255*sc,140*sc},help={"TURN OFF ONLY FOR DEBUGGING."} 366 CheckBox PrefCtrl_1k title="Do Solid Angle Correction?",size={140*sc,14*sc},proc=V_DoSolidAngleCorPref 367 CheckBox PrefCtrl_1k value=root:Packages:NIST:VSANS:Globals:gDoSolidAngleCor,pos={255*sc,160*sc},help={"TURN OFF ONLY FOR DEBUGGING."} 368 CheckBox PrefCtrl_1l title="Do Non-linear Correction?",size={140*sc,14*sc},proc=V_DoNonLinearCorPref,disable=2 369 CheckBox PrefCtrl_1l value=root:Packages:NIST:VSANS:Globals:gDoNonLinearCor,pos={255*sc,180*sc},help={"Non-linear correction can't be turned off"} 370 CheckBox PrefCtrl_1m title="Do Downstream Window Corr?",size={140*sc,14*sc},proc=V_DoDownstreamWindowCorPref 371 CheckBox PrefCtrl_1m value=root:Packages:NIST:VSANS:Globals:gDoDownstreamWindowCor,pos={255*sc,200*sc},help={"TURN OFF ONLY FOR DEBUGGING."} 340 372 // CheckBox PrefCtrl_1n title="Do Monitor Normalization?",size={140,14},proc=V_DoMonitorNormPref 341 373 // CheckBox PrefCtrl_1n value=root:Packages:NIST:VSANS:Globals:gDoMonitorNormalization,pos={255,220},help={"TURN OFF ONLY FOR DEBUGGING."} 342 CheckBox PrefCtrl_1o title="Ignore Back Detector?",size={140 ,14},proc=V_IgnoreDetBPref343 CheckBox PrefCtrl_1o value=root:Packages:NIST:VSANS:Globals:gIgnoreDetB,pos={150 ,220},help={"Will prevent data from Back detector being written to data files."}374 CheckBox PrefCtrl_1o title="Ignore Back Detector?",size={140*sc,14*sc},proc=V_IgnoreDetBPref 375 CheckBox PrefCtrl_1o value=root:Packages:NIST:VSANS:Globals:gIgnoreDetB,pos={150*sc,220*sc},help={"Will prevent data from Back detector being written to data files."} 344 376 345 377 // CheckBox PrefCtrl_1a,disable=1 … … 355 387 356 388 //on tab(2) - Analysis 357 GroupBox PrefCtrl_2a pos={21 ,100},size={1,1},title="nothing to set",fSize=12389 GroupBox PrefCtrl_2a pos={21*sc,100*sc},size={1,1},title="nothing to set",fSize=12 358 390 359 391 GroupBox PrefCtrl_2a,disable=1 360 361 392 End 362 393
Note: See TracChangeset
for help on using the changeset viewer.