source: trunk/MagicSoft/Mars/meventdisp/MGEvtDisplay.h@ 1969

Last change on this file since 1969 was 1668, checked in by tbretz, 22 years ago
*** empty log message ***
File size: 1.8 KB
Line 
1#ifndef MARS_MGEvtDisplay
2#define MARS_MGEvtDisplay
3
4#ifndef MARS_MAGIC
5#include "MAGIC.h"
6#endif
7
8#ifndef ROOT_TGFrame
9#include <TGFrame.h>
10#endif
11
12class TGTab;
13class TList;
14class TCanvas;
15class TGLabel;
16class TGTextEntry;
17
18class MEvtLoop;
19class MParList;
20class MTaskList;
21class MReadTree;
22
23class MGEvtDisplay : public TGMainFrame/*TGTransientFrame*/
24{
25private:
26 //
27 // GUI stuff
28 //
29 TGLabel *fNumOfEvts;
30 TGLabel *fEvtInfo;
31 TGTextEntry *fTxtEvtNr;
32
33 TGTab *fEvtDisplay;
34
35 void AddMenuBar();
36 void AddTopFramePart1(TGVerticalFrame *frame,
37 const char *filename,
38 const char *treename);
39 void AddTopFramePart2(TGVerticalFrame *frame);
40 void AddMidFrame(TGHorizontalFrame *frame);
41 void AddLowFrame(TGHorizontalFrame *frame);
42
43 void AddFrames(const char *filename, const char *treename);
44
45 void SaveAsDialog() const;
46 void ReadinEvent();
47
48 Bool_t fInitOk;
49
50protected:
51 TList *fList;
52 MEvtLoop *fEvtLoop;
53
54 TCanvas *fCanvas;
55
56 TGCompositeFrame *fTab1;
57 TGCompositeFrame *fTab2;
58
59 TGVerticalFrame *fMidFrame;
60
61 MParList *GetParList() const;
62 MTaskList *GetTaskList() const;
63 MReadTree *GetReader() const;
64
65 TCanvas *AddTab(TString name);
66
67 void ReadFirstEvent();
68 Bool_t IsInitOk() { return fInitOk; }
69
70 void UpdateMcLabel();
71
72 virtual void UpdateDisplay() = 0;
73
74public:
75 MGEvtDisplay(const char *fname, const char *tname,
76 const TGWindow *p, /*const TGWindow *main,*/
77 UInt_t w, UInt_t h);
78
79 ~MGEvtDisplay();
80
81 void CloseWindow();
82
83 virtual Bool_t ProcessMessage(Long_t msg, Long_t parm1, Long_t parm2);
84
85 ClassDef(MGEvtDisplay, 0) // base class to display something event by event
86};
87
88#endif
89
90
Note: See TracBrowser for help on using the repository browser.