library: libGpad #include "TDrawPanelHist.h"

# TDrawPanelHist

class description - source file - inheritance tree (.pdf)

## class TDrawPanelHist : public TDialogCanvas

| Inheritance Chart:
`TObject`
`TAttLine`
`TAttFill`
`TAttPad`
`TQObject`
| <- | `TVirtualPad`
| <- | `TPad`
| <- | `TCanvas`
`TAttText`
| <- | `TDialogCanvas`
| <- | `TDrawPanelHist` |

        public:

                          TDrawPanelHist()
                          TDrawPanelHist(const char* name, const char* title, UInt_t ww, UInt_t wh, const TVirtualPad* pad, const TObject* obj)
                  virtual ~TDrawPanelHist()
             virtual void AddOption(Option_t* option)
             virtual void Apply(const char* action = "")
             virtual void BuildStandardButtons()
           static TClass* Class()
             virtual void ExecuteEvent(Int_t event, Int_t px, Int_t py)
                 TObject* GetHistogram() const
          virtual TClass* IsA() const
             virtual void RecursiveRemove(TObject* obj)
             virtual void SavePrimitive(ofstream& out, Option_t* option)
             virtual void SetDefaults()
             virtual void SetSame()
             virtual void ShowMembers(TMemberInspector& insp, char* parent)
             virtual void Streamer(TBuffer& b)
                     void StreamerNVirtual(TBuffer& b)

### Data Members

        protected:

           TString fOption     Fitting options
          TSlider* fSlider     Pointer to fitpanel slider
          TObject* fHistogram  Pointer to histogram

## Class Description

      A TDrawPanelHist is a TDialogCanvas specialized to control
      histogram drawing options.
       With the mouse, the user can control:
         - the drawing range in X and Y
         - the drawing options
       When the DRAW button is executed, the selected histogram is drawn
       with the current parameters.

       Use the slider to control the range of the histogram to be drawn.

       The options are documented in TH1::Draw.

/* */

TDrawPanelHist() : TDialogCanvas()

     DrawPanelHist default constructor.

TDrawPanelHist(const char *name, const char *title, UInt_t ww, UInt_t wh, const TVirtualPad *pad, const TObject *obj) : TDialogCanvas(name, title,ww,wh)

     DrawPanelHist constructor.

~TDrawPanelHist()

     DrawPanelHist destructor.

void AddOption(Option_t *option)

     Add option to the current list of options.

void Apply(const char *action)

     Collect all options and draw histogram.

void BuildStandardButtons()

     Create Draw, Defaults and Close buttons.

void ExecuteEvent(Int_t event, Int_t px, Int_t py)

     Control mousse events when slider is used in a drawpanel

     This function is called by TPad::ExecuteEvent or TSliderBox::ExecuteEvent
     We return in the first case.
     When called by the slider,  px = 0 and py = 0

void RecursiveRemove(TObject *obj)

      when obj is deleted, clear fHistogram if fHistogram=obj

void SavePrimitive(ofstream &, Option_t *)

     Save this drawpanel in a macro.

void SetDefaults()

     Set default draw panel options.

void SetSame()

     Set graphics option "same".

### Inline Functions

               TObject* GetHistogram() const
                TClass* Class()
                TClass* IsA() const
                   void ShowMembers(TMemberInspector& insp, char* parent)
                   void Streamer(TBuffer& b)
                   void StreamerNVirtual(TBuffer& b)

Author: Rene Brun 26/11/96
Last update: root/gpad:$Name: $:$Id: TDrawPanelHist.cxx,v 1.6 2004/07/20 07:23:34 brun Exp $
Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *