MCPcopy Create free account
hub / github.com/antvis/F2Native / GetTicks

Method GetTicks

core/graphics/scale/Scale.h:71–83  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

69 void Reset() { this->ticks = this->CalculateTicks(); }
70
71 std::vector<Tick> GetTicks(XChart *chart) {
72 std::vector<Tick> ticks_;
73
74 for(size_t i = 0; i < ticks.size(); i++) {
75 nlohmann::json &item = ticks[i];
76 scale::Tick tick;
77 tick.text = this->GetTickText(item, chart, i);
78 tick.value = this->Scale(item);
79 tick.tickValue = item;
80 ticks_.push_back(std::move(tick));
81 }
82 return ticks_;
83 }
84
85 inline const std::string &GetField() const { return field; }
86

Callers 15

GetScaleTicksMethod · 0.80
GetLegendItemsMethod · 0.80
InitAxisMethod · 0.80
InitAxisConfigMethod · 0.80
TickCount0Method · 0.80
TickCountLess2Method · 0.80
TicksMethod · 0.80
TicksNiceMethod · 0.80
TicksNice2Method · 0.80
TicksNice3Method · 0.80
TicksNice4Method · 0.80
WithoutTimeRangeMethod · 0.80

Calls 4

GetTickTextMethod · 0.95
push_backMethod · 0.80
sizeMethod · 0.45
ScaleMethod · 0.45

Tested by

no test coverage detected