_ROOT Version:6.14
hi all:
if I have a TLegend;
gStyle-> SetFillColorAlpha(1,0); // not OK
TLegend * l1 …
l1-> SetFillColorAlpha(1,0); //OK
how can I Set Legend FillColorAlpha by default?
_ROOT Version:6.14
hi all:
if I have a TLegend;
gStyle-> SetFillColorAlpha(1,0); // not OK
TLegend * l1 …
l1-> SetFillColorAlpha(1,0); //OK
how can I Set Legend FillColorAlpha by default?
TColor *col3 = gROOT->GetColor(3);
col3->SetAlpha(0.3);
gStyle->SetLegendFillColor(3);
that is a way, but this would edit the default color 3 at the same time. that’s not a good way.
could I add a new color?
ci = TColor::GetFreeColorIndex();
TColor *col = gROOT->GetColor(ci);
col->SetAlpha(0.3);
gStyle->SetLegendFillColor(ci);
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.