Ion
|
This struct represents the metrics for a single glyph. More...
#include "freetypefont.h"
Public Member Functions | |
GlyphMetrics () | |
The default constructor initializes everything to 0. More... | |
bool | IsZeroSize () const |
Returns true if glyph x- or y-size is zero. More... | |
Public Attributes | |
math::Vector2f | size |
Width and height of the glyph, in pixels. More... | |
math::Vector2f | bitmap_offset |
Distance in X and Y from the baseline to the top left pixel of the glyph bitmap, in pixels. More... | |
math::Vector2f | advance |
Number of pixels to advance in X and Y to draw the next glyph after this. More... | |
This struct represents the metrics for a single glyph.
Definition at line 40 of file freetypefont.h.
|
inline |
The default constructor initializes everything to 0.
Definition at line 42 of file freetypefont.h.
|
inline |
Returns true if glyph x- or y-size is zero.
Definition at line 46 of file freetypefont.h.
math::Vector2f ion::text::FreeTypeFont::GlyphMetrics::advance |
Number of pixels to advance in X and Y to draw the next glyph after this.
Definition at line 57 of file freetypefont.h.
math::Vector2f ion::text::FreeTypeFont::GlyphMetrics::bitmap_offset |
Distance in X and Y from the baseline to the top left pixel of the glyph bitmap, in pixels.
This should be added to the current position when drawing the glyph. The Y distance is positive for an upward offset.
Definition at line 54 of file freetypefont.h.
Referenced by ion::text::ComputeTextSize().
math::Vector2f ion::text::FreeTypeFont::GlyphMetrics::size |
Width and height of the glyph, in pixels.
Definition at line 49 of file freetypefont.h.
Referenced by ion::text::ComputeTextSize().