face->size->metrics->ascender seems to be unreliable for some fonts,
additionally the freetype documentation says that it may be used
differently for different fonts.
Therefore it may happen that the ascender of a font face is less then
the glyphs bounding box resulting in accessing invalid memory.
The fix is to use the bbox attribute instead of the ascender
This patch fixed the size calculations for true type fonts (especially for
italic fonts)
Additinally a very simple greedy line break algorithm has been added for
true type labels.
As FcFontMach is quite an expensive call the results of getFontFile() are
now cached in an std::map if either a ttf file is packed with the app or
if a font file has been found by using fontconfig
We should use CCFileUtils to get the full path to font resources.
Additionally the input font is converted to lowercase for checking if it is
a ttf file. So we can also load .TTF or .tTf files.
This patch fixes the black pixels
around fonts when rendered using
CCLabelTTF.
see http://www.cocos2d-x.org/issues/706
This fix is for linux only, but may
be applied to other platforms as well
This patch removes the hardcoded font paths
from the linux project and uses fontconfig
to find the best match for a given font-family
The implementation also adds the possibility
to load a font file from the applications
resource directory