Lines Matching refs:Units
46 template <RangeSelector::Units>
50 struct UnitTraits<RangeSelector::Units::kPercentage> {
62 struct UnitTraits<RangeSelector::Units::kIndex> {
256 static constexpr Units gUnitMap[] = { in Make()
257 Units::kPercentage, // 'r': 1 in Make()
258 Units::kIndex, // 'r': 2 in Make()
282 new RangeSelector(ParseEnum<Units> (gUnitMap , (*jrange)["r" ], abuilder, "units" ), in Make()
302 RangeSelector::RangeSelector(Units u, Domain d, Mode m, Shape sh) in RangeSelector()
310 case Units::kPercentage: in RangeSelector()
311 std::tie(fStart, fEnd, fOffset) = UnitTraits<Units::kPercentage>::Defaults(); in RangeSelector()
313 case Units::kIndex: in RangeSelector()
314 std::tie(fStart, fEnd, fOffset) = UnitTraits<Units::kIndex >::Defaults(); in RangeSelector()
322 SkASSERT(fUnits == Units::kPercentage || fUnits == Units::kIndex); in resolve()
323 const auto resolver = (fUnits == Units::kPercentage) in resolve()
324 ? UnitTraits<Units::kPercentage>::Resolve in resolve()
325 : UnitTraits<Units::kIndex >::Resolve; in resolve()