NSCL DDAS  1.0
Support for XIA DDAS at the NSCL
 All Classes Namespaces Files Functions Variables Macros Pages
TimingParamDialogue.h
1 // TimingParamDialogue.h
2 //
3 // A class defining the dialogue to control the timing
4 // parameters in the Pixie16 modules.
5 //
6 // Author : Jeromy Tompkins
7 //
8 
9 #ifndef TIMINGPARAMDIALOGUE_H_
10 #define TIMINGPARAMDIALOGUE_H_
11 
12 #include <iostream>
13 #include <iomanip>
14 #include "TImage.h"
15 #include "TGIcon.h"
16 #include "TGFrame.h"
17 #include "TGButton.h"
18 #include "TGNumberEntry.h"
19 #include "TGTextEntry.h"
20 #include "TGLabel.h"
21 #include "TG3DLine.h"
22 #include "MediaLocator.h"
23 
24 #include "pixie16app_export.h"
25 
26 class TimingParamDialogue: public TGTransientFrame
27 {
28  private:
29  enum Commands
30  {
31  LOAD,
32  APPLY,
33  CANCEL,
34  MODNUMBER,
35  FILTER,
36  COPYBUTTON
37  };
38 
39  private:
40  TGHorizontalFrame* fHFrame;
41 
42  // Image data
43  TImage* fPicData;
44  TGIcon* fPic;
45 
46  // Frames and such for the Table
47  TGVerticalFrame* mn_vert;
48  TGHorizontalFrame* mn;
49  int Rows;
50  TGVerticalFrame **Column;
51  TGTextEntry *cl0;//label for the title of the column[0]
52  TGTextEntry **CLabel;//labels for the numeric columns
53  TGNumberEntryField ***NumEntry;//numeric entries [column][row],
54  //column[0] has the labels
55  TGTextEntry **Labels; //labels in the left most column
56 
57  int numModules;
58  TGNumberEntry *numericMod;
59  TGHorizontalFrame* Buttons ;
60 
61  MediaLocator m_imageLocator;
62 
63  public:
64  TimingParamDialogue(const TGWindow * p, const TGWindow * main, int NumModules=13);
65  virtual ~TimingParamDialogue();
66  Bool_t ProcessMessage (Long_t msg, Long_t parm1, Long_t parm2);
67  int change_values (Long_t mod);
68  int load_info (Long_t mod);
69  void SetModuleNumber(int moduleNr) {
70  modNumber = (short)moduleNr;
71  numericMod->SetIntNumber(modNumber);
72  load_info(modNumber);
73  };
74 
75  short int chanNumber;
76  short int modNumber;
77  TGNumberEntry* chanCopy;
78  bool Load_Once;
79  char tmp[10];
80  float tdelay,twidth;
81 
82  void UpdateChanCoincWidthColumn();
83 
84  protected:
85  void MakeTable(TGFrame* parent, int columns, int rows, int NumModules);
86  void DoCopy();
87 
88 };
89 
90 #endif /*TIMINGPARAMDIALOGUE_H_*/
Definition: MediaLocator.h:7
Definition: TimingParamDialogue.h:26
Bool_t ProcessMessage(Long_t msg, Long_t parm1, Long_t parm2)
Definition: TimingParamDialogue.cpp:308