MCPcopy Create free account
hub / github.com/IENT/YUView / getValueTxt

Method getValueTxt

YUViewLib/src/statistics/StatisticsType.cpp:235–243  ·  view source on GitHub ↗

If the internal valueMap can map the value to text, text and value will be returned. Otherwise just the value as QString will be returned.

Source from the content-addressed store, hash-verified

233// If the internal valueMap can map the value to text, text and value will be returned.
234// Otherwise just the value as QString will be returned.
235QString StatisticsType::getValueTxt(int val) const
236{
237 if (valMap.count(val) > 0)
238 {
239 // A text for this value van be shown.
240 return QString("%1 (%2)").arg(valMap.at(val)).arg(val);
241 }
242 return QString("%1").arg(val);
243}
244
245void StatisticsType::setMappingValues(std::vector<QString> values)
246{

Callers 2

paintStatisticsDataMethod · 0.80
getValuesAtMethod · 0.80

Calls 1

atMethod · 0.45

Tested by

no test coverage detected