Commit Graph

17 Commits

Author SHA1 Message Date
Bartosz Taudul
107975c8de
Fix time rounding logic.
PrintSmallInt() expects values in the 0-999 range, but the in+1 may produce
1000 here. This is invalid and it either asserted, or outputted an empty
string.

Workaround by simple outputting "1000" as the value here.

This function is only used in context of printing time, and only in specific
context. The end result will be that values like "1000 us" or "1000 ms" may
appear, where they would be otherwise shortened to "1 ms" or "1 s". This may
be a bit unusual, but is acceptable, as the real time value has not yet
crossed the threshold required for such shortening.
2022-08-28 14:50:38 +02:00
Bartosz Taudul
361782f3fd
Fix edge case triggered by mouse being out-of-window. 2022-01-29 15:53:50 +01:00
Bartosz Taudul
91f1845d92
Add LocationToString() helper. 2021-06-19 12:33:23 +02:00
Bartosz Taudul
c69cf5bd3f
Cosmetics. 2021-06-19 12:33:16 +02:00
Bartosz Taudul
58bb5d40c5 Remove support for non-extended font builds. 2020-03-26 23:04:44 +01:00
Bartosz Taudul
d262ca53ea Add missing zeros to exact time printout. 2020-03-21 16:13:41 +01:00
Bartosz Taudul
b1342a10b0 Exact time printing functionality. 2020-02-02 15:13:20 +01:00
Bartosz Taudul
b418c55e89 Verify tiny int printing input. 2020-02-02 14:31:59 +01:00
Bartosz Taudul
8627a31912 Maximum time range is 1.6 days. 2020-02-02 14:11:42 +01:00
Bartosz Taudul
289637384d Perform less work if printing integers. 2020-01-31 02:32:12 +01:00
Bartosz Taudul
1475635382 Use std::to_chars() in RealToString(). 2020-01-31 02:02:47 +01:00
Bartosz Taudul
f017b27ae2 RealToString() is always called with separator set to true. 2020-01-31 01:43:24 +01:00
Bartosz Taudul
36fb1f96e2 Custom float-printing function. 2020-01-31 01:19:08 +01:00
Rokas Kupstys
b391e4c21a Fix multiple build errors when compiling with MinGW. 2019-08-04 15:49:46 +03:00
Bartosz Taudul
37c76edcd8 Explicitly require long long abs(). 2019-07-25 18:36:27 +02:00
Bartosz Taudul
eb4c7ca9ea Ignore useless warnings. 2019-06-22 13:40:00 +02:00
Bartosz Taudul
1a32edebf2 Extract text printing functions. 2019-06-18 20:43:28 +02:00