// @(#):$Id$
// Author: M.Gheata 
/*************************************************************************
 * Copyright (C) 1995-2002, Rene Brun and Fons Rademakers.               *
 * All rights reserved.                                                  *
 *                                                                       *
 * For the licensing terms see $ROOTSYS/LICENSE.                         *
 * For the list of contributors see $ROOTSYS/README/CREDITS.             *
 *************************************************************************/

#ifndef ROOT_TGeoSphereEditor
#define ROOT_TGeoSphereEditor

//////////////////////////////////////////////////////////////////////////
//                                                                      //
//  TGeoSphereEditor                                                      //
//                                                                     //
//  Editor for a TGeoSphere.                                              //
//                                                                      //
//////////////////////////////////////////////////////////////////////////

#ifndef ROOT_TGButton
#include "TGWidget.h"
#endif
#ifndef ROOT_TGeoGedFrame
#include "TGeoGedFrame.h"
#endif

class TGeoSphere;
class TGeoTabManager;
class TGTextEntry;
class TGNumberEntry;
class TGTab;
class TGComboBox;
class TGDoubleVSlider;
class TGTextButton;
class TGCheckButton;
class TString;

class TGeoSphereEditor : public TGeoGedFrame {

protected:

   Double_t        fRmini;             // Initial inner radius
   Double_t        fRmaxi;             // Initial outer radius
   Double_t        fTheta1i;           // Initial lower theta limit
   Double_t        fTheta2i;           // Initial higher theta limit   
   Double_t        fPhi1i;             // Initial lower phi limit
   Double_t        fPhi2i;             // Initial higher phi limit   
   TString         fNamei;             // Initial name
   TGeoSphere     *fShape;             // Shape object
   Bool_t          fIsModified;        // Flag that volume was modified
   Bool_t          fIsShapeEditable;   // Flag that the shape can be changed
   Bool_t          fLock;              // Lock

   TGTextEntry    *fShapeName;         // Shape name text entry
   TGNumberEntry  *fERmin;             // Number entry for rmin
   TGNumberEntry  *fERmax;             // Number entry for rmax
   TGNumberEntry  *fETheta1;           // Number entry for Theta1
   TGNumberEntry  *fETheta2;           // Number entry for Theta2
   TGNumberEntry  *fEPhi1;             // Number entry for phi1
   TGNumberEntry  *fEPhi2;             // Number entry for phi2
   TGDoubleVSlider  *fSPhi;            // Phi slider
   TGDoubleVSlider  *fSTheta;          // Theta slider  
   TGTextButton   *fApply;             // Apply-Button to accept changes
   TGTextButton   *fUndo;              // Undo-Button
   TGCheckButton  *fDelayed;           // Check button for delayed draw

   virtual void ConnectSignals2Slots();   // Connect the signals to the slots
   Bool_t       IsDelayed() const;   

public:
   TGeoSphereEditor(const TGWindow *p = 0,
                  Int_t width = 140, Int_t height = 30,
                  UInt_t options = kChildFrame,
                  Pixel_t back = GetDefaultFrameBackground());
   virtual ~TGeoSphereEditor();
   virtual void   SetModel(TObject *obj);

   void           DoRmin();
   void           DoRmax();
   void           DoPhi();
   void           DoTheta();
   void           DoTheta1();
   void           DoTheta2();
   void           DoPhi1();
   void           DoPhi2();
   void           DoModified();
   void           DoName();
   virtual void   DoApply();
   virtual void   DoUndo();
   
   ClassDef(TGeoSphereEditor,0)   // TGeoSphere editor
};   

#endif                    
 TGeoSphereEditor.h:1
 TGeoSphereEditor.h:2
 TGeoSphereEditor.h:3
 TGeoSphereEditor.h:4
 TGeoSphereEditor.h:5
 TGeoSphereEditor.h:6
 TGeoSphereEditor.h:7
 TGeoSphereEditor.h:8
 TGeoSphereEditor.h:9
 TGeoSphereEditor.h:10
 TGeoSphereEditor.h:11
 TGeoSphereEditor.h:12
 TGeoSphereEditor.h:13
 TGeoSphereEditor.h:14
 TGeoSphereEditor.h:15
 TGeoSphereEditor.h:16
 TGeoSphereEditor.h:17
 TGeoSphereEditor.h:18
 TGeoSphereEditor.h:19
 TGeoSphereEditor.h:20
 TGeoSphereEditor.h:21
 TGeoSphereEditor.h:22
 TGeoSphereEditor.h:23
 TGeoSphereEditor.h:24
 TGeoSphereEditor.h:25
 TGeoSphereEditor.h:26
 TGeoSphereEditor.h:27
 TGeoSphereEditor.h:28
 TGeoSphereEditor.h:29
 TGeoSphereEditor.h:30
 TGeoSphereEditor.h:31
 TGeoSphereEditor.h:32
 TGeoSphereEditor.h:33
 TGeoSphereEditor.h:34
 TGeoSphereEditor.h:35
 TGeoSphereEditor.h:36
 TGeoSphereEditor.h:37
 TGeoSphereEditor.h:38
 TGeoSphereEditor.h:39
 TGeoSphereEditor.h:40
 TGeoSphereEditor.h:41
 TGeoSphereEditor.h:42
 TGeoSphereEditor.h:43
 TGeoSphereEditor.h:44
 TGeoSphereEditor.h:45
 TGeoSphereEditor.h:46
 TGeoSphereEditor.h:47
 TGeoSphereEditor.h:48
 TGeoSphereEditor.h:49
 TGeoSphereEditor.h:50
 TGeoSphereEditor.h:51
 TGeoSphereEditor.h:52
 TGeoSphereEditor.h:53
 TGeoSphereEditor.h:54
 TGeoSphereEditor.h:55
 TGeoSphereEditor.h:56
 TGeoSphereEditor.h:57
 TGeoSphereEditor.h:58
 TGeoSphereEditor.h:59
 TGeoSphereEditor.h:60
 TGeoSphereEditor.h:61
 TGeoSphereEditor.h:62
 TGeoSphereEditor.h:63
 TGeoSphereEditor.h:64
 TGeoSphereEditor.h:65
 TGeoSphereEditor.h:66
 TGeoSphereEditor.h:67
 TGeoSphereEditor.h:68
 TGeoSphereEditor.h:69
 TGeoSphereEditor.h:70
 TGeoSphereEditor.h:71
 TGeoSphereEditor.h:72
 TGeoSphereEditor.h:73
 TGeoSphereEditor.h:74
 TGeoSphereEditor.h:75
 TGeoSphereEditor.h:76
 TGeoSphereEditor.h:77
 TGeoSphereEditor.h:78
 TGeoSphereEditor.h:79
 TGeoSphereEditor.h:80
 TGeoSphereEditor.h:81
 TGeoSphereEditor.h:82
 TGeoSphereEditor.h:83
 TGeoSphereEditor.h:84
 TGeoSphereEditor.h:85
 TGeoSphereEditor.h:86
 TGeoSphereEditor.h:87
 TGeoSphereEditor.h:88
 TGeoSphereEditor.h:89
 TGeoSphereEditor.h:90
 TGeoSphereEditor.h:91
 TGeoSphereEditor.h:92
 TGeoSphereEditor.h:93
 TGeoSphereEditor.h:94
 TGeoSphereEditor.h:95
 TGeoSphereEditor.h:96