natiny_font_get_descent
C
float natiny_font_get_descent(NatinyFont font);
Returns how far the font reaches below the baseline, in drawing units.
Parameters
Returns
| Type |
Description |
float |
Non-negative distance below the baseline in drawing units, or 0.0f for an invalid handle |
Example
C
float ascent = natiny_font_get_ascent(font);
float descent = natiny_font_get_descent(font);
float width = 0.0f;
natiny_font_measure_text(font, text, &width, NULL);
natiny_render_line(x, y + ascent + descent,
x + width, y + ascent + descent, 1.0f);