- FontLibC---C library for fancy fonts on the TI-84 Plus CE
- 08 Mar 2019 06:07:45 pm
- Last edited by DrDnar on 03 May 2019 07:54:31 pm; edited 3 times in total
This project is ready for use. (3 May 2019)
Having previously complained about GRAPHX only supporting 8x8 fonts, I've finally gotten around to writing a better library for more complex text, called FontLibC. This new library supports variable-width fonts up to 24 pixels wide (it made for a nice inner-loop optimization) and 127 pixel high. Here's a sample, in two different fonts, showing additional vertical spacing enabled and colored text:
Currently supported features:
You can start testing out FontLibC right now by getting it from GitHub.
Feedback Wanted
Having previously complained about GRAPHX only supporting 8x8 fonts, I've finally gotten around to writing a better library for more complex text, called FontLibC. This new library supports variable-width fonts up to 24 pixels wide (it made for a nice inner-loop optimization) and 127 pixel high. Here's a sample, in two different fonts, showing additional vertical spacing enabled and colored text:


Currently supported features:
- Compatible with, and indeed requires, GRAPHX's 8-bit mode
- Glyphs up to 24 pixels wide
- Fonts up to 127 pixels high
- Foreground and background colors are different than GRAPHX's
- Transparent background supported (not the same as GRAPHX's transparent color index!)
- Provides a reasonable compromise between speed and powerful features:
- Customizable control codes, including newline.
- String drawing stops on reaching an unrecognized control code and you can get the address it stopped at using fontlib_GetLastCharacterRead().
- Internal text window, allowing text to be automatically confined to a portion of the screen.
- You can define an additional code point to use as a stop code. For example, you can set space as the stop code and then use fontlib_GetStringWidth() to figure out if the next word will fit on the current line.
- You can configure additional blank space to print above and below each line of text. Extra spacing helps improve readability in large blocks of text.
- Tip: You can force the glyph at code point 0 to print by passing 0 directly to fontlib_DrawGlyph().
- Supports finding fonts in font packs---appvars that contain multiple related fonts---based on size and style parameters.
You can start testing out FontLibC right now by getting it from GitHub.
Feedback Wanted