Place characters of right-to-left alphabets correctly.

This commit is contained in:
Ben "root" Anderson
2015-02-22 22:05:27 -06:00
parent fd8a1bb69a
commit bde705ab0b
+2
View File
@@ -294,6 +294,7 @@ void BitmapText::BuildChars()
RageSpriteVertex v[4];
const glyph &g = m_pFont->GetGlyph( sLine[j] );
// Advance the cursor early for RTL(?)
if( m_pFont->IsRightToLeft() )
iX -= g.m_iHadvance;
@@ -304,6 +305,7 @@ void BitmapText::BuildChars()
v[3].p = RageVector3( iX+g.m_fHshift+g.m_fWidth, iY+g.m_pPage->m_fVshift, 0 ); // top right
// Advance the cursor.
if( !m_pFont->IsRightToLeft() )
iX += g.m_iHadvance;
// set texture coordinates