freetype
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bugs?


From: Lidia Mirkin
Subject: bugs?
Date: Tue, 11 Jul 2000 18:19:31 +0200

    hello !
i use freetype library in order to have some properties for different kinds
of font formats.
for ttf , i need know some names
my code is:
----------------------------------------------------------------------------
--
     FT_Library library;
     FT_Error   error;

     TT_FaceRec*    face;

     error=FT_Init_FreeType(&library);

     cSTRING pathname="c:\\winnt\\fonts\\arial.ttf";

     error = FT_New_Face( library , pathname.getStr() , 0,
(FT_Face*)(&face) );

     cMEMORY buff(100);
     for ( int i=0;i<8;i++)
     {
          TT_NameRec* name=face->name_table.names + i;

strncpy((char*)buff.getPtr(),(char*)(name->string),name->stringLength);
        *(buff.getPtr()+name->stringLength)=0;
          M_DBGMSG("I=" << i << " name=" << buff.getPtr())
       }

     FT_Done_Face((FT_Face)face);
     FT_Done_FreeType(library);
----------------------------------------------------------------------------
------
1.for some fonts it works OK , but it fails on memory for standart Arial.ttf
2.face->num_names field always is 0.Is this bug or feature?
3.is there some examples for different  modules using? I am interesting on
psnames module...
            thanks a lot , Lidia.







reply via email to

[Prev in Thread] Current Thread [Next in Thread]