25 auto canvas = RCanvas::Create(
"RAxis examples");
27 auto x1 = 0.08_normal, w1 = 0.36_normal,
x2 = 0.57_normal, w2 = 0.36_normal;
31 draw0->axis.ticks.size = 0.02_normal;
32 draw0->axis.title =
"vertical";
40 draw2->axis.ticks.size = 0.02_normal;
41 draw2->axis.title =
"both side ticks";
42 draw2->axis.title.SetCenter();
46 draw3->axis.labels.center =
true;
51 draw4->axis.SetTimeDisplay(
"%d/%m/%y %H:%M");
52 draw4->axis.title =
"time display";
53 draw4->axis.labels.size = 0.01;
54 draw4->axis.labels.color = RColor::kRed;
56 std::vector<std::string> labels = {
"first",
"second",
"third",
"forth",
"fifth"};
60 draw5->axis.title =
"labels, swap ticks side";
61 draw5->axis.title.SetLeft();
66 draw6->axis.ending.SetArrow();
67 draw6->axis.title =
"vertical negative length";
71 draw7->axis.max = 100;
73 draw7->axis.title =
"log10 scale";
74 draw7->axis.title.SetCenter();
75 draw7->axis.title.font = RAttrFont::kVerdana;
76 draw7->axis.title.color = RColor::kGreen;
77 draw7->axis.ending.SetCircle();
81 draw8->axis.max = 128;
83 draw8->axis.title =
"log2 scale";
84 draw8->axis.title.SetCenter();
88 draw9->axis.max = 100;
89 draw9->axis.log = 2.7182;
90 draw9->axis.title =
"ln scale";
91 draw9->axis.title.SetCenter();
95 draw10->axis.title =
"horizontal negative length";
96 draw10->axis.title.SetCenter();
100 draw11->axis.reverse =
true;
101 draw11->axis.title =
"horizontal reverse";
102 draw11->axis.title.SetCenter();
106 draw12->axis.ending.size = 0.01_normal;
107 draw12->axis.ticks.SetBoth();
108 draw12->axis.ticks.color = RColor::kBlue;
109 draw12->axis.ticks.size = 0.01_normal;
110 draw12->axis.title =
"vertical axis with arrow";
111 draw12->axis.title.SetCenter();
113 canvas->SetSize(1000, 800);
Option_t Option_t TPoint TPoint const char x2
Option_t Option_t TPoint TPoint const char x1
RAttrAxisTicks ticks
! ticks attributes
RAttrAxisTitle title
! title attributes
RAttrLineEnding ending
! ending attributes
RAttrValue< double > min
! axis min
RAttrAxis axis
! axis attributes
RAxisDrawable & SetLabels(const std::vector< std::string > &lbls)
A position (horizontal and vertical) in a RPad.
This class stores the date and time with a precision of one second in an unsigned 32 bit word (950130...
UInt_t Convert(Bool_t toGMT=kFALSE) const
Convert fDatime from TDatime format to the standard time_t format.