Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
TPaveLabel.h
Go to the documentation of this file.
1// @(#)root/graf:$Id$
2// Author: Rene Brun 17/10/95
3
4/*************************************************************************
5 * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
6 * All rights reserved. *
7 * *
8 * For the licensing terms see $ROOTSYS/LICENSE. *
9 * For the list of contributors see $ROOTSYS/README/CREDITS. *
10 *************************************************************************/
11
12#ifndef ROOT_TPaveLabel
13#define ROOT_TPaveLabel
14
15
16#include "TPave.h"
17#include "TAttText.h"
18
19
20class TPaveLabel : public TPave, public TAttText {
21
22protected:
23 TString fLabel; ///< Label written at the center of Pave
24
25public:
26 TPaveLabel();
27 TPaveLabel(Double_t x1, Double_t y1,Double_t x2 ,Double_t y2, const char *label, Option_t *option="br");
28 TPaveLabel(const TPaveLabel &pavelabel);
29 TPaveLabel& operator=(const TPaveLabel &pavelabel);
30 ~TPaveLabel() override;
31
32 void Copy(TObject &pavelabel) const override;
33 void Draw(Option_t *option="") override;
35 const char *label, Option_t *option="");
36 const char *GetLabel() const {return fLabel.Data();}
37 const char *GetTitle() const override {return fLabel.Data();}
38 void Paint(Option_t *option="") override;
40 const char *label, Option_t *option="");
41 void SavePrimitive(std::ostream &out, Option_t *option = "") override;
42 virtual void SetLabel(const char *label) {fLabel = label;} // *MENU*
43
44 ClassDefOverride(TPaveLabel,1) //PaveLabel. A Pave with a label
45};
46
47#endif
48
double Double_t
Definition RtypesCore.h:59
const char Option_t
Definition RtypesCore.h:66
#define ClassDefOverride(name, id)
Definition Rtypes.h:341
Option_t Option_t option
Option_t Option_t TPoint TPoint const char x2
Option_t Option_t TPoint TPoint const char x1
Option_t Option_t TPoint TPoint const char y2
Option_t Option_t TPoint TPoint const char y1
Text Attributes class.
Definition TAttText.h:18
Mother of all ROOT objects.
Definition TObject.h:41
A Pave (see TPave) with a text centered in the Pave.
Definition TPaveLabel.h:20
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save primitive as a C++ statement(s) on output stream out.
void Copy(TObject &pavelabel) const override
Copy this pavelabel to pavelabel.
virtual void PaintPaveLabel(Double_t x1, Double_t y1, Double_t x2, Double_t y2, const char *label, Option_t *option="")
Draw this pavelabel with new coordinates.
~TPaveLabel() override
TPaveLabel default destructor.
virtual TPaveLabel * DrawPaveLabel(Double_t x1, Double_t y1, Double_t x2, Double_t y2, const char *label, Option_t *option="")
Draw this pavelabel with new coordinates.
const char * GetLabel() const
Definition TPaveLabel.h:36
void Paint(Option_t *option="") override
Paint this pavelabel with its current attributes.
TPaveLabel()
Pavelabel default constructor.
TString fLabel
Label written at the center of Pave.
Definition TPaveLabel.h:23
virtual void SetLabel(const char *label)
Definition TPaveLabel.h:42
TPaveLabel & operator=(const TPaveLabel &pavelabel)
TPaveLabel assign operator.
const char * GetTitle() const override
Returns title of object.
Definition TPaveLabel.h:37
A TBox with a bordersize and a shadow option.
Definition TPave.h:19
Basic string class.
Definition TString.h:139
const char * Data() const
Definition TString.h:380
th1 Draw()