[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [ft] bitmap_left description
From: |
Werner LEMBERG |
Subject: |
Re: [ft] bitmap_left description |
Date: |
Sat, 27 Sep 2014 06:25:47 +0200 (CEST) |
> The docs for bitmap_left say:
>
> This is the bitmap's left bearing expressed in integer
> pixels. Of course, this is only valid if the format is
> FT_GLYPH_FORMAT_BITMAP.
>
> I'm rendering individual glyphs from a TrueType font using
> FT_Load_Glyph() followed by FT_Render_Glyph(). Having done that I
> had been struggling to work out the metrics for the result. Then I
> discovered that bitmap_left and bitmap_top seem to tell me exactly
> what I need to know - but I had been avoiding them because this not
> a bitmap font and the description quoted above.
Well, after calling FT_Render_Glyph, `face->glyph' *does* hold a
bitmap, as specified by the `face->glyph->format' field. Please read
the documentation of its type, `FT_GlyphSlotRec'.
> Is it OK to use bitmap_left/top after FT_Render_Glyph()?
Yes.
> Is this a documentation issue?
Obviously. Please suggest an improvement.
Werner