Repository navigation
titrmlib v0.4.2
Format strings for titles, list items and labels without linking the C library's printf.
New
term_snprintfandterm_vsnprintf: format into your own buffer with titrmlib's formatter, e.g.term_snprintf(title, sizeof title, "Password: %s", ssid). They follow C'ssnprintfrules: at mostsize - 1characters plus a terminator, and they return the full length. Usingsnprintfitself would link CEdev's printf again, about 8 KB.
No API changes. titrm.h now includes <stdarg.h>.
Using titrmlib
-
Unzip
titrmlib-v0.4.2.zipinto your CEdev project'slib/folder, givinglib/titrmlib/. -
Add its sources to your project's makefile:
CFLAGS = -Wall -Wextra -Oz -Ilib/titrmlib/src EXTRA_C_SOURCES = $(wildcard lib/titrmlib/src/*.c)
-
#include "titrm.h"and build withmake.
Keep the library inside your project directory: on Windows, CEdev can't build sources reached through ... The calculator needs the CE C libraries.
API reference: https://gavinhsmith.github.io/titrmlib/