mirror of
https://github.com/elasota/Aerofoil.git
synced 2025-12-14 12:09:36 +00:00
Get scoreboard bar working
This commit is contained in:
@@ -897,7 +897,11 @@ short StringWidth(const PLPasStr &str)
|
||||
if (!rfont)
|
||||
return 0;
|
||||
|
||||
return rfont->MeasureString(str.UChars(), str.Length());
|
||||
const size_t width = rfont->MeasureString(str.UChars(), str.Length());
|
||||
if (width > SHRT_MAX)
|
||||
return SHRT_MAX;
|
||||
|
||||
return static_cast<short>(width);
|
||||
}
|
||||
|
||||
void GetMouse(Point *point)
|
||||
|
||||
Reference in New Issue
Block a user