Initialize STB TrueType font system with robust font discovery
Find font by name in typical system locations
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| character(len=*), | intent(in) | :: | font_name | |||
| character(len=256), | intent(out) | :: | font_path | 
Find any available font using same priority order as system initialization
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| character(len=256), | intent(out) | :: | font_path | 
Get font ascent ratio for baseline positioning
Get font scale for a specific pixel height
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real(kind=wp), | intent(in) | :: | pixel_height | 
Clean up text system resources
Get font metrics in pixels for current font and scale
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| real(kind=wp), | intent(out) | :: | ascent_pixels | |||
| real(kind=wp), | intent(out) | :: | descent_pixels | |||
| real(kind=wp), | intent(out) | :: | line_gap_pixels | |||
| logical, | intent(out) | :: | success |