mirror of
https://github.com/love2d/love.git
synced 2026-08-17 19:23:38 +02:00
made fonts actually print from the top-left.
This commit is contained in:
@@ -76,7 +76,7 @@ namespace opengl
|
|||||||
int g = (int)text[i];
|
int g = (int)text[i];
|
||||||
if (!glyphs[g]) g = 32; // space
|
if (!glyphs[g]) g = 32; // space
|
||||||
glPushMatrix();
|
glPushMatrix();
|
||||||
glTranslatef(0, height, 0);
|
glTranslatef(0, getHeight(), 0);
|
||||||
glyphs[g]->draw(0, 0, 0, 1, 1, 0, 0);
|
glyphs[g]->draw(0, 0, 0, 1, 1, 0, 0);
|
||||||
glPopMatrix();
|
glPopMatrix();
|
||||||
glTranslatef(spacing[g], 0, 0);
|
glTranslatef(spacing[g], 0, 0);
|
||||||
@@ -88,7 +88,7 @@ namespace opengl
|
|||||||
{
|
{
|
||||||
if (!glyphs[character]) character = ' ';
|
if (!glyphs[character]) character = ' ';
|
||||||
glPushMatrix();
|
glPushMatrix();
|
||||||
glTranslatef(x, y+height, 0.0f);
|
glTranslatef(x, y+getHeight(), 0.0f);
|
||||||
glCallList(list+character);
|
glCallList(list+character);
|
||||||
glPopMatrix();
|
glPopMatrix();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user