mirror of https://github.com/freetype/freetype
* src/type/t1objs.c (T1_Face_Init): Slightly improve algorithm.
This commit is contained in:
parent
d57a5e9fff
commit
cd6dcca658
|
@ -1,3 +1,7 @@
|
|||
2008-06-19 Werner Lemberg <wl@gnu.org>
|
||||
|
||||
* src/type/t1objs.c (T1_Face_Init): Slightly improve algorithm.
|
||||
|
||||
2008-06-18 Werner Lemberg <wl@gnu.org>
|
||||
|
||||
* src/type/t1objs.c (T1_Face_Init): Fix change from 2008-03-21.
|
||||
|
|
|
@ -375,6 +375,9 @@
|
|||
|
||||
if ( full )
|
||||
{
|
||||
FT_Bool the_same = TRUE;
|
||||
|
||||
|
||||
while ( *full )
|
||||
{
|
||||
if ( *full == *family )
|
||||
|
@ -390,12 +393,17 @@
|
|||
family++;
|
||||
else
|
||||
{
|
||||
the_same = FALSE;
|
||||
|
||||
if ( !*family )
|
||||
root->style_name = full;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ( the_same )
|
||||
root->style_name = (char *)"Regular";
|
||||
}
|
||||
}
|
||||
else
|
||||
|
@ -410,7 +418,7 @@
|
|||
if ( info->weight )
|
||||
root->style_name = info->weight;
|
||||
else
|
||||
/* assume "Regular" style because we don't know better */
|
||||
/* assume `Regular' style because we don't know better */
|
||||
root->style_name = (char *)"Regular";
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue