fix possible text truncation issues (eg: pings on the scoreboard). reported by kt.

git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@5045 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
Spoike 2017-01-22 17:10:25 +00:00
parent c4cd754b91
commit 9055d674eb

View file

@ -216,7 +216,8 @@ void Draw_FunStringWidth(float x, float y, const void *str, int width, int right
int fw = 0;
unsigned int codeflags, codepoint;
width = (width*vid.rotpixelwidth)/vid.width;
//be generous and round up, to avoid too many issues with truncations
width = ceil((width*(float)vid.rotpixelwidth)/vid.width);
codeflags = (highlight&1)?CON_ALTMASK:CON_WHITEMASK;
if (highlight&2)