diff options
author | Christian Göttsche <cgzones@googlemail.com> | 2020-11-29 14:14:46 +0100 |
---|---|---|
committer | BenBE <BenBE@geshi.org> | 2020-11-29 15:06:08 +0100 |
commit | cd305b4325cc9ea9c21cbdaad570ffcff1f1ecd7 (patch) | |
tree | d59e6febc1f02cc2e8912a8b21bd72b95632df41 | |
parent | c1563337ae366ca66f25ed71a2f462a486df1337 (diff) |
Print G in gigabyte color
When printing a size like 27.2G print the G like the 27 in the gigabyte color.
-rw-r--r-- | Process.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -101,8 +101,9 @@ void Process_humanNumber(RichString* str, unsigned long long number, bool colori len = xSnprintf(buffer, sizeof(buffer), "%2llu", number/10); RichString_appendn(str, processGigabytesColor, buffer, len); number %= 10; - len = xSnprintf(buffer, sizeof(buffer), ".%1lluG ", number); + len = xSnprintf(buffer, sizeof(buffer), ".%1llu", number); RichString_appendn(str, processMegabytesColor, buffer, len); + RichString_append(str, processGigabytesColor, "G "); } else if (number < 1000 * ONE_M) { //3 digit GB number /= ONE_M; |