I would do the leading zero suppression inside the loop right after line 52.
If your tmp value is less that 999 then set digitBuffer[3] to a value of digit[] that is blank. You may have to add that.
Then if your tmp value is less that 99 then set digitBuffer[2] to a value of digit[] that is blank.
A negative sign can be added in a similar mannor.
If your tmp value is less that 999 then set digitBuffer[3] to a value of digit[] that is blank. You may have to add that.
Then if your tmp value is less that 99 then set digitBuffer[2] to a value of digit[] that is blank.
A negative sign can be added in a similar mannor.
