1
0
Fork 0
forked from len0rd/rockbox

Text viewer: Fix red

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25516 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Tomer Shalev 2010-04-07 17:27:19 +00:00
parent 9e4bd41e41
commit 2434a92b60

View file

@ -641,10 +641,10 @@ static int glyph_width(unsigned short ch)
if (ch == 0)
ch = ' ';
#ifdef HAVE_LCD_BITMAP
if (rb->is_diacritic(ch, NULL))
return 0;
#ifdef HAVE_LCD_BITMAP
return rb->font_get_width(pf, ch);
#else
return 1;
@ -733,9 +733,11 @@ static int col = 0;
static inline void advance_conters(unsigned short ch, int* k, int* width)
{
#ifdef HAVE_LCD_BITMAP
/* diacritics do not count */
if (rb->is_diacritic(ch, NULL))
return;
#endif
*width += glyph_width(ch);
(*k)++;