Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
TAnnotation.h
Go to the documentation of this file.
1// @(#)root/gpad:$Id$
2// Author: Olivier Couet 03/05/23
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_TAnnotation
13#define ROOT_TAnnotation
14
15
16#include "TLatex.h"
17
18class TAnnotation : public TLatex {
19
20protected:
21 double fZ{0}; ///< Z position of text
22
23public:
24
26 TAnnotation(Double_t x, Double_t y, Double_t z, const char *text);
27 ~TAnnotation() override;
28 virtual TAnnotation *DrawAnnotation(Double_t x, Double_t y, Double_t z, const char *text);
29 void ls(Option_t *option="") const override;
30 void Paint(Option_t *option="") override;
32 void Print(Option_t *option="") const override;
33
34 void SetZ(double z) { fZ = z; } // *MENU*
35 double GetZ() const { return fZ; }
36
37 ClassDefOverride(TAnnotation,1) //Annotation in 2d or 3D
38};
39
40#endif
size_t size(const MatrixT &matrix)
retrieve the size of a square matrix
char Char_t
Definition RtypesCore.h:37
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 angle
Option_t Option_t TPoint TPoint const char text
An annotation is a TLatex which can be drawn in a 2D or 3D space.
Definition TAnnotation.h:18
void PaintAnnotation(Double_t x, Double_t y, Double_t z, Double_t angle, Double_t size, const Char_t *text)
Paint this annotation with new coordinates.
~TAnnotation() override
annotation default destructor.
double fZ
Z position of text.
Definition TAnnotation.h:21
void ls(Option_t *option="") const override
List this annotation with its attributes.
double GetZ() const
Definition TAnnotation.h:35
void SetZ(double z)
Definition TAnnotation.h:34
void Print(Option_t *option="") const override
Dump this annotation with its attributes.
void Paint(Option_t *option="") override
Paint a TAnnotation.
virtual TAnnotation * DrawAnnotation(Double_t x, Double_t y, Double_t z, const char *text)
Draw this annotation with new coordinates.
To draw Mathematical Formula.
Definition TLatex.h:18
Double_t y[n]
Definition legend1.C:17
Double_t x[n]
Definition legend1.C:17