Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

TGo4MainWindow.h

Go to the documentation of this file.
00001 //-------------------------------------------------------------
00002 //        Go4 Release Package v3.04-01 (build 30401)
00003 //                      28-November-2008
00004 //---------------------------------------------------------------
00005 //   The GSI Online Offline Object Oriented (Go4) Project
00006 //   Experiment Data Processing at EE department, GSI
00007 //---------------------------------------------------------------
00008 //
00009 //Copyright (C) 2000- Gesellschaft f. Schwerionenforschung, GSI
00010 //                    Planckstr. 1, 64291 Darmstadt, Germany
00011 //Contact:            http://go4.gsi.de
00012 //----------------------------------------------------------------
00013 //This software can be used under the license agreements as stated
00014 //in Go4License.txt file which is part of the distribution.
00015 //----------------------------------------------------------------
00016 #ifndef TGO4MAINWINDOW_H
00017 #define TGO4MAINWINDOW_H
00018 
00019 #include "qmainwindow.h"
00020 
00021 class QApplication;
00022 
00023 class QGo4Widget;
00024 class TGo4FitPanel;
00025 class TGo4ParaEdit;
00026 class TGo4HistogramInfo;
00027 class TGo4ConditionInfo;
00028 class TGo4EditDynEntry;
00029 class TGo4EventInfo;
00030 class TGo4ConditionEditor;
00031 class TGo4AnalysisConfiguration;
00032 class TGo4AnalysisWindow;
00033 class TGo4AnalysisStatusMonitor;
00034 class TGo4SetScaleValues;
00035 
00036 class QPopupMenu;
00037 class TGo4WorkSpace;
00038 class TGo4ViewPanel;
00039 class TPad;
00040 class TGo4Slot;
00041 class TGo4ObjectManager;
00042 class TGo4AnalysisProxy;
00043 class TGo4BrowserProxy;
00044 class TGo4WidgetProxy;
00045 
00051 class TGo4MainWindow : public QMainWindow {
00052    Q_OBJECT
00053 
00054    public:
00055       TGo4MainWindow(QApplication*, bool);
00056       virtual ~TGo4MainWindow();
00057 
00058       void HotStart(const char* fname);
00059       void ProcessQtEvents();
00060       void StatusMessage(const QString& mess);
00061       const char* LastTypedPassword() const;
00062       TGo4ViewPanel* FindViewPanel(const char* name);
00063       TGo4ViewPanel* DisplayBrowserItem(const char* itemname, TGo4ViewPanel* panel, TPad* pad, bool activate, int updatelevel, const char* drawopt);
00064 
00065       TGo4ObjectManager* OM();
00066       TGo4BrowserProxy* Browser();
00067 
00068    public slots:
00069 
00070       void about();
00071       void aboutQt();
00072       void aboutROOT();
00073       void windowsMenuAboutToShow();
00074       void AddAnalysisBar();
00075       void AddAnalysisMenu();
00076       void AddFileMenu();
00077       void AddFileToolBar();
00078       void AddSettingMenu();
00079       void AddToolsBar();
00080       void AddToolsMenu();
00081       void UserPanelSlot();
00082       TGo4ViewPanel* MakeNewPanel(int div = 0);
00083       void LoadLibrarySlot();
00084       void CloseAllFilesSlot();
00085       void OpenFileSlot();
00086       void OpenRemoteFileSlot();
00087       void ConnectHServerSlot();
00088       void SaveFileSlot();
00089 
00090       void InputTerminalParametersSlot();
00091       void LogSettingsSlot();
00092 
00093       void IntroHelpSlot();
00094       void RefHelpSlot();
00095       void FitHelpSlot();
00096       void InterfaceHelpSlot();
00097       void CloseAllWindows();
00098       void MinAllWindows();
00099       void SaveSettingsSlot();
00100       void ChangeFontSlot();
00101       void MakeStyleSlot(const QString&);
00102       void windowsMenuActivated( int id );
00103       void ForseCloseSlot();
00104 
00105       void ChangeFetchWhenDrawSlot();
00106       void ChangeFetchWhenCopySlot();
00107       void ChangeFetchWhenSaveSlot();
00108       void CanvasColorSlot();
00109       void CrosshairSlot();
00110       void EventStatusSlot();
00111       void MarkerSettingsSlot();
00112       void OptStatsSlot();
00113       void ChangeCloneFlagSlot();
00114       void ChangeDrawTimeFlagSlot();
00115       void ChangeDrawDateFlagSlot();
00116       void ChangeDrawItemFlagSlot();
00117 
00118       void PrepareForClientConnectionSlot();
00119       void LaunchClientSlot(bool interactive = true);
00120       void ConnectServerSlot(bool interactive = true, const char* password = "");
00121       void DisconnectAnalysisSlot(bool interactive = true);
00122       void ShutdownAnalysisSlot(bool interactive = true);
00123       void ToggleAnalysisConfiguration();
00124       void ToggleAnalysisWindow();
00125       void CloseAnalysisWindow();
00126 
00127       void SubmitAnalysisSettings();
00128       void SubmitStartAnalysisSlot();
00129       void StartAnalysisSlot();
00130       void StopAnalysisSlot();
00131 
00132       void CreateNewHistSlot(int isremote = -1);
00133       void CreateNewConditionSlot(bool forothereditor = false);
00134       void CreateNewDynEntrySlot(bool forothereditor = false);
00135 
00136       // starting editros slots
00137       TGo4FitPanel* StartFitPanel();
00138       TGo4ParaEdit* StartParaEdit(const char* itemname = 0);
00139       TGo4HistogramInfo* StartHistogramInfo();
00140       TGo4ConditionInfo* StartConditionInfo();
00141       TGo4EditDynEntry* StartEditDynEntry();
00142       TGo4EventInfo* StartEventInfo();
00143       TGo4ConditionEditor* StartConditionEditor();
00144 
00145       TGo4AnalysisConfiguration* FindAnalysisConfiguration();
00146       TGo4AnalysisWindow* FindAnalysisWindow();
00147 
00148       // slots connected to editors
00149       void editorServiceSlot(QGo4Widget* editor, int serviceid, const char* str, void* par);
00150 
00151       void ProcessHotStart();
00152       void StopGUIScriptSlot();
00153       void CreateGUIScriptSlot();
00154       void CheckConnectingCounterSlot();
00155       void checkPanelRepaintSlot();
00156 
00157    protected:
00158 
00159       virtual void closeEvent( QCloseEvent * ce );
00160 
00161       void ConnectGo4Widget(QGo4Widget* editor);
00162 
00163       void UpdateCaptionButtons();
00164 
00165       bool startUserGUI(const char*);
00166       TGo4AnalysisProxy* AddAnalysisProxy(bool isserver, bool needoutput);
00167       bool RemoveAnalysisProxy(int waittime = 30, bool servershutdown = false);
00168       TGo4AnalysisStatusMonitor* EstablishRatemeter(int level);
00169       TGo4AnalysisConfiguration* EstablishAnalysisConfiguration(int level);
00170 
00171       QGo4Widget* FindGo4Widget(const char* name, bool activate);
00172       TGo4Slot* GetWidgetTopSlot(QGo4Widget* widget, bool force);
00173 
00174       bool SaveBrowserItemToFile(const char* itemname, const char* subfolder);
00175 
00176       void UpdateDockAnalysisWindow();
00177       void TerminateAnalysis();
00178 
00179       void ToggleMbsMonitor(const char* nodename);
00180       TGo4SetScaleValues*  ToggleScaleValues();
00181 
00182       void SavePanelCanvas(TGo4ViewPanel* panel);
00183 
00184       void HelpWindow(const char* filename,
00185                       const char* dir = "",
00186                       const char* msg = 0);
00187 
00188       QApplication*      fApp;
00189 
00190       QPopupMenu*        windowsMenu;
00191       TGo4WorkSpace*     fxTGo4WorkSpace;
00192       bool               fbServerMode;
00193 
00194       TGo4ObjectManager* fxOM;
00195       QString            fOMDataPath;
00196       QString            fOMBrowserPath;
00197       QString            fOMEditorsPath;
00198 
00199       QString            fKillCommand;
00200 
00201       int                fCloseCounter;
00202       int                fConnectingCounter;
00203       QString            fLastPassword;
00204       QString            fLastFileDir;
00205 
00206       bool               fbPanelTimerActive;
00207 };
00208 
00209 #endif
00210 
00211 //----------------------------END OF GO4 SOURCE FILE ---------------------

Generated on Fri Nov 28 12:59:21 2008 for Go4-v3.04-1 by  doxygen 1.4.2