// simple editor to allow user to directly modify config file from GUI // based on root simple editor // M. Pallavicini 31-12-2001 created // mostly based on class Editor in "guitest" by F. Rademakers, root.cern.ch #ifndef __CONFIGEDITORDLG_HH_ #define __CONFIGEDITORDLG_HH_ #include "TGFrame.h" #include "TGButton.h" #include "TGTextEdit.h" class SimuApplication; class ConfigEditorDlg : public TGTransientFrame { public: ConfigEditorDlg(SimuApplication*, const char*, TGWindow*); virtual ~ConfigEditorDlg(); virtual void CloseWindow(); virtual Bool_t ProcessMessage(Long_t, Long_t, Long_t ); private: char *buffer; char fname[500]; TGTextEdit *fEdit; TGTextButton *fSave, *fSaveAs, *fMem, *fCancel; TGLayoutHints *fL1, *fL2, *fL3; TGCompositeFrame *fFrame; void SaveBuffer(const char *fn=0); enum { EDIT_SAVE_BUTTON, EDIT_SAVEAS_BUTTON, EDIT_MEMORY_BUTTON, EDIT_CANCEL_BUTTON }; SimuApplication *theApp; ClassDef(ConfigEditorDlg,0) }; #endif