MCPcopy Create free account
hub / github.com/aethersdr/AetherSDR / formatFlagFrequency

Function formatFlagFrequency

src/gui/SpectrumWidget.cpp:634–644  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

632}
633
634static QString formatFlagFrequency(double freqMhz)
635{
636 const long long hz = static_cast<long long>(std::llround(freqMhz * 1.0e6));
637 const int mhzPart = static_cast<int>(hz / 1000000);
638 const int khzPart = static_cast<int>((hz / 1000) % 1000);
639 const int hzPart = static_cast<int>(hz % 1000);
640 return QString("%1.%2.%3")
641 .arg(mhzPart)
642 .arg(khzPart, 3, 10, QChar('0'))
643 .arg(hzPart, 3, 10, QChar('0'));
644}
645
646static QString formatFreqScaleLabel(double freqMhz, int decimals)
647{

Callers 2

mousePressEventMethod · 0.85
updateTnfHoverPopupMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected