1
0
Fork 0
mirror of https://github.com/TerryCavanagh/VVVVVV.git synced 2024-12-23 10:09:43 +01:00

Fix brace style of Graphics::font_idx()

This really should be next-line brace, as is (most of) the rest of the
codebase.
This commit is contained in:
Misa 2021-02-15 16:21:27 -08:00 committed by Ethan Lee
parent a505059719
commit b3679ce1e5

View file

@ -243,18 +243,24 @@ void Graphics::destroy_buffers()
#undef FREE_SURFACE #undef FREE_SURFACE
} }
int Graphics::font_idx(uint32_t ch) { int Graphics::font_idx(uint32_t ch)
if (font_positions.size() > 0) { {
if (font_positions.size() > 0)
{
std::map<int, int>::iterator iter = font_positions.find(ch); std::map<int, int>::iterator iter = font_positions.find(ch);
if (iter == font_positions.end()) { if (iter == font_positions.end())
{
iter = font_positions.find('?'); iter = font_positions.find('?');
if (iter == font_positions.end()) { if (iter == font_positions.end())
{
puts("font.txt missing fallback character!"); puts("font.txt missing fallback character!");
exit(1); exit(1);
} }
} }
return iter->second; return iter->second;
} else { }
else
{
return ch; return ch;
} }
} }