void gradients(
bool gl =
true)
{
auto c =
new TCanvas(
"cpie",
"Gradient colours demo", 700, 700);
if (!
c->UseGL() && !
c->IsWeb())
::Warning(
"gradients",
"This macro requires either OpenGL or Web canvas to correctly handle gradient colors");
auto t =
new TText(0.05, 0.7,
"Can you see the text?");
t->Draw();
auto pad =
new TPad(
"p",
"p", 0., 0., 1., 1.);
pie->SetEntryRadiusOffset(2, 0.05);
pie->SetLabelsOffset(-0.08);
}
int Int_t
Signed integer 4 bytes (int)
unsigned int UInt_t
Unsigned integer 4 bytes (unsigned int)
float Float_t
Float 4 bytes (float)
double Double_t
Double 8 bytes.
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
void Warning(const char *location, const char *msgfmt,...)
Use this function in warning situations.
R__EXTERN TStyle * gStyle
static Int_t GetLinearGradient(Double_t angle, const std::vector< Int_t > &colors, const std::vector< Double_t > &positions={})
Static function: Returns the linear gradient color number corresponding to specified parameters.
static Int_t GetRadialGradient(Double_t r, const std::vector< Int_t > &colors, const std::vector< Double_t > &positions={})
Static function: Returns the radial gradient color number corresponding to specified parameters.
static Int_t GetColor(const char *hexcolor)
Static method returning color number for color specified by hex color string of form: "#rrggbb",...
The most important graphics class in the ROOT system.
void SetCanvasPreferGL(Bool_t prefer=kTRUE)
Base class for several text objects.