00001 // @(#):$Id: TGeoTrd1Editor.h 20882 2007-11-19 11:31:26Z rdm $ 00002 // Author: M.Gheata 00003 /************************************************************************* 00004 * Copyright (C) 1995-2002, Rene Brun and Fons Rademakers. * 00005 * All rights reserved. * 00006 * * 00007 * For the licensing terms see $ROOTSYS/LICENSE. * 00008 * For the list of contributors see $ROOTSYS/README/CREDITS. * 00009 *************************************************************************/ 00010 00011 #ifndef ROOT_TGeoTrd1Editor 00012 #define ROOT_TGeoTrd1Editor 00013 00014 ////////////////////////////////////////////////////////////////////////// 00015 // // 00016 // TGeoTrd1Editor // 00017 // // 00018 // Editor for a TGeoTrd1. // 00019 // // 00020 ////////////////////////////////////////////////////////////////////////// 00021 00022 #ifndef ROOT_TGButton 00023 #include "TGWidget.h" 00024 #endif 00025 #ifndef ROOT_TGeoGedFrame 00026 #include "TGeoGedFrame.h" 00027 #endif 00028 00029 class TGeoTrd1; 00030 class TGeoTabManager; 00031 class TGTextEntry; 00032 class TGNumberEntry; 00033 class TGTab; 00034 class TGComboBox; 00035 class TGTextButton; 00036 class TGCheckButton; 00037 class TString; 00038 00039 class TGeoTrd1Editor : public TGeoGedFrame { 00040 00041 protected: 00042 00043 Double_t fDxi1; // Initial dx1 00044 Double_t fDxi2; // Initial dx2 00045 Double_t fDyi; // Initial dy 00046 Double_t fDzi; // Initial dz 00047 TString fNamei; // Initial name 00048 TGeoTrd1 *fShape; // Shape object 00049 Bool_t fIsModified; // Flag that volume was modified 00050 Bool_t fIsShapeEditable; // Flag that the shape can be changed 00051 00052 TGTextEntry *fShapeName; // Shape name text entry 00053 TGNumberEntry *fEDx1; // Number entry for DX1 00054 TGNumberEntry *fEDx2; // Number entry for DX2 00055 TGNumberEntry *fEDy; // Number entry for DY 00056 TGNumberEntry *fEDz; // Number entry for DZ 00057 TGTextButton *fApply; // Apply-Button to accept changes 00058 TGTextButton *fUndo; // Undo-Button 00059 TGCheckButton *fDelayed; // Check button for delayed draw 00060 00061 virtual void ConnectSignals2Slots(); // Connect the signals to the slots 00062 Bool_t IsDelayed() const; 00063 00064 public: 00065 TGeoTrd1Editor(const TGWindow *p = 0, 00066 Int_t width = 140, Int_t height = 30, 00067 UInt_t options = kChildFrame, 00068 Pixel_t back = GetDefaultFrameBackground()); 00069 virtual ~TGeoTrd1Editor(); 00070 virtual void SetModel(TObject *obj); 00071 00072 void DoDx1(); 00073 void DoDx2(); 00074 void DoDy(); 00075 void DoDz(); 00076 void DoModified(); 00077 void DoName(); 00078 void DoApply(); 00079 void DoUndo(); 00080 00081 ClassDef(TGeoTrd1Editor,0) // TGeoTrd1 editor 00082 }; 00083 00084 #endif