#ifndef ROOT_TAxis
#define ROOT_TAxis
#ifndef ROOT_TNamed
#include "TNamed.h"
#endif
#ifndef ROOT_TAttAxis
#include "TAttAxis.h"
#endif
#ifndef ROOT_TArrayD
#include "TArrayD.h"
#endif
class THashList;
class TAxis : public TNamed, public TAttAxis {
private:
Int_t fNbins;
Double_t fXmin;
Double_t fXmax;
TArrayD fXbins;
Int_t fFirst;
Int_t fLast;
UShort_t fBits2;
Bool_t fTimeDisplay;
TString fTimeFormat;
TObject *fParent;
THashList *fLabels;
TAxis& operator=(const TAxis&);
public:
enum { kTickPlus = BIT(9),
kTickMinus = BIT(10),
kAxisRange = BIT(11),
kCenterTitle = BIT(12),
kCenterLabels = BIT(14),
kRotateTitle = BIT(15),
kPalette = BIT(16),
kNoExponent = BIT(17),
kLabelsHori = BIT(18),
kLabelsVert = BIT(19),
kLabelsDown = BIT(20),
kLabelsUp = BIT(21),
kIsInteger = BIT(22),
kMoreLogLabels = BIT(23),
kDecimals = BIT(11)};
TAxis();
TAxis(Int_t nbins, Double_t xmin, Double_t xmax);
TAxis(Int_t nbins, const Double_t *xbins);
TAxis(const TAxis &axis);
virtual ~TAxis();
virtual void CenterLabels(Bool_t center=kTRUE);
virtual void CenterTitle(Bool_t center=kTRUE);
const char *ChooseTimeFormat(Double_t axislength=0);
virtual void Copy(TObject &axis) const;
virtual void Delete(Option_t * ="") { }
virtual Int_t DistancetoPrimitive(Int_t px, Int_t py);
virtual TObject *DrawClone(Option_t * ="") const {return 0;}
virtual void ExecuteEvent(Int_t event, Int_t px, Int_t py);
virtual Int_t FindBin(Double_t x);
virtual Int_t FindBin(const char *label);
virtual Int_t FindFixBin(Double_t x) const;
virtual Double_t GetBinCenter(Int_t bin) const;
virtual Double_t GetBinCenterLog(Int_t bin) const;
const char *GetBinLabel(Int_t bin) const;
virtual Double_t GetBinLowEdge(Int_t bin) const;
virtual Double_t GetBinUpEdge(Int_t bin) const;
virtual Double_t GetBinWidth(Int_t bin) const;
virtual void GetCenter(Double_t *center) const;
Bool_t GetCenterLabels() const;
Bool_t GetCenterTitle() const;
THashList *GetLabels() {return fLabels;}
virtual void GetLowEdge(Double_t *edge) const;
Bool_t GetMoreLogLabels() const;
Int_t GetNbins() const { return fNbins; }
Bool_t GetNoExponent() const;
Bool_t GetDecimals() const;
virtual TObject *GetParent() const {return fParent;}
Bool_t GetRotateTitle() const;
virtual const char *GetTicks() const;
virtual Bool_t GetTimeDisplay() const {return fTimeDisplay;}
virtual const char *GetTimeFormat() const {return fTimeFormat.Data();}
virtual const char *GetTimeFormatOnly() const;
const char *GetTitle() const {return fTitle.Data();}
const TArrayD *GetXbins() const {return &fXbins;}
Int_t GetFirst() const;
Int_t GetLast() const;
Double_t GetXmin() const {return fXmin;}
Double_t GetXmax() const {return fXmax;}
virtual void ImportAttributes(const TAxis *axis);
Bool_t IsVariableBinSize() const {
return (fXbins.GetSize() != 0);
}
virtual void LabelsOption(Option_t *option="h");
virtual void RotateTitle(Bool_t rotate=kTRUE);
virtual void SaveAttributes(ostream &out, const char *name, const char *subname);
virtual void Set(Int_t nbins, Double_t xmin, Double_t xmax);
virtual void Set(Int_t nbins, const Float_t *xbins);
virtual void Set(Int_t nbins, const Double_t *xbins);
virtual void SetBinLabel(Int_t bin, const char *label);
virtual void SetDefaults();
virtual void SetDrawOption(Option_t * ="") { }
virtual void SetLimits(Double_t xmin, Double_t xmax);
virtual void SetMoreLogLabels(Bool_t more=kTRUE);
virtual void SetNoExponent(Bool_t noExponent=kTRUE);
virtual void SetDecimals(Bool_t dot=kTRUE);
virtual void SetParent(TObject *obj) {fParent = obj;}
virtual void SetRange(Int_t first=0, Int_t last=0);
virtual void SetRangeUser(Double_t ufirst, Double_t ulast);
virtual void SetTicks(Option_t *option="+");
virtual void SetTimeDisplay(Int_t value) {fTimeDisplay = (value != 0);}
virtual void SetTimeFormat(const char *format="");
virtual void SetTimeOffset(Double_t toffset, Option_t *option="local");
virtual void UnZoom();
virtual void ZoomOut(Double_t factor=0, Double_t offset=0);
ClassDef(TAxis,9)
};
#endif