Add text outline as an accessibility option

This commit is contained in:
Ethan Lee
2020-01-17 12:37:53 -05:00
parent 05229255f6
commit 6e9712f113
5 changed files with 60 additions and 23 deletions

View File

@@ -31,6 +31,7 @@ Graphics::Graphics()
showcutscenebars = false;
cutscenebarspos = 0;
notextoutline = false;
flipmode = false;
setflipmode = false;
@@ -380,19 +381,22 @@ void Graphics::bprint( int x, int y, std::string t, int r, int g, int b, bool ce
{
//printmask(x, y, t, cen);
Print(x, y - 1, t, 0, 0, 0, cen);
if (cen)
if (!notextoutline)
{
//TODO find different
PrintOff(-1, y, t, 0, 0, 0, cen);
PrintOff(1, y, t, 0, 0, 0, cen);
Print(x, y - 1, t, 0, 0, 0, cen);
if (cen)
{
//TODO find different
PrintOff(-1, y, t, 0, 0, 0, cen);
PrintOff(1, y, t, 0, 0, 0, cen);
}
else
{
Print(x -1, y, t, 0, 0, 0, cen);
Print(x +1, y, t, 0, 0, 0, cen);
}
Print(x, y+1, t, 0, 0, 0, cen);
}
else
{
Print(x -1, y, t, 0, 0, 0, cen);
Print(x +1, y, t, 0, 0, 0, cen);
}
Print(x, y+1, t, 0, 0, 0, cen);
Print(x, y, t, r, g, b, cen);
}