/* * LogableMainFrame.h * * Created on: Mar 16, 2016 * Author: Hovanes Egiyan */ #ifndef LOGABLEMAINFRAME_H_ #define LOGABLEMAINFRAME_H_ #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include #include "TSystem.h" #include "TError.h" #include "TGTextBuffer.h" #include "LogEntryFrame.hh" class LogableMainFrame: public TGMainFrame { protected: // Image file type used by the mainframe // static TImage::EImageFileTypes lmeImageFileTyp; // Maximum size of the log entry body static unsigned lmfLogEntryBodySize; static std::string lmfLogbookName; TGMenuBar* lmfMenuBar; // Menu bar pointer // LogableMainFrame() {} // LogableMainFrame( const LogableMainFrame& frame ); virtual void MakeMenuBar(); public: enum { kM_FILE_NEW, kM_FILE_OPEN, kM_FILE_REOPEN, kM_FILE_CLOSE, kM_FILE_SAVE, kM_FILE_SAVEAS, kM_FILE_PRINT, kM_FILE_PRINTSETUP, kM_FILE_EXIT, kM_FILE_LOG }; LogableMainFrame(const TGWindow *p, UInt_t width, UInt_t height); virtual ~LogableMainFrame(); // LogableMainFrame( const LogableMainFrame& frame ) ; virtual void HandleMenu(Int_t choice) ; virtual void ExitApplication(); // Create an image file with a file name in the argument and return the full filename. // If no argument is given a file will be created in the /tmp directory. std::string SaveAsImage( const std::string fileName = "" ); // Make a log entry virtual void MakeLogEntry(); // Get an image filename in the /tmp directory virtual std::string GetTempImageFileName(); virtual std::string GetLogEntryBody(); ClassDef(LogableMainFrame,0) }; #endif /* LOGABLEMAINFRAME_H_ */