Add a Process_printPercentage helper routine

Replace several open-coded variants of percentage formatting.
This function has been ported from Hishams old 'next' branch.
This commit is contained in:
Hisham Muhammad
2021-09-03 12:44:19 +10:00
committed by BenBE
parent 0925c54caa
commit 556d7c03e8
3 changed files with 29 additions and 44 deletions

View File

@ -356,6 +356,8 @@ void Process_fillStarttimeBuffer(Process* this);
void Process_printLeftAlignedField(RichString* str, int attr, const char* content, unsigned int width);
void Process_printPercentage(float val, char* buffer, int n, int* attr);
void Process_display(const Object* cast, RichString* out);
void Process_done(Process* this);