{
switch(unit)
{
- case BTC: return 10; // 21,000,000 (# digits, without commas)
- case mBTC: return 13; // 21,000,000,000
- case uBTC: return 16; // 21,000,000,000,000
+ case BTC: return 8; // 21,000,000 (# digits, without commas)
+ case mBTC: return 11; // 21,000,000,000
+ case uBTC: return 14; // 21,000,000,000,000
default: return 0;
}
}
QString quotient_str = QString::number(quotient);
QString remainder_str = QString::number(remainder).rightJustified(num_decimals, '0');
- // Right-trim excess 0's after the decimal point
+ // Right-trim excess zeros after the decimal point
int nTrim = 0;
for (int i = remainder_str.size()-1; i>=2 && (remainder_str.at(i) == '0'); --i)
++nTrim;