The generated font files contained an ID that could depend on the
configuration settings for the build. That caused the font file on
DM32 to be incorrect, which caused a crash when editing text.
Fixes: #458
Signed-off-by: Christophe de Dinechin <christophe@dinechin.org>
The idea is to keep the same symbols that the DM42 software uses in
a compatible location, to make it possible to alternatively load the
DM42 and DB48X program.
This seems to work relatively well, but there is a strange behavior
from the DM42 program that complains about being unable to open
the STATE directory of the calculator. It is possible that it is
confused by the presence of .48S files there.
Signed-off-by: Christophe de Dinechin <christophe@dinechin.org>
This is lifted from the WP43 project.
The idea is to be able to move "heavy" and rarely moving data, like fonts, into
the QSPI, so that we have more room for the main program in Flash.
Signed-off-by: Christophe de Dinechin <christophe@dinechin.org>
Reset the vertical font positions in the table to what they were initially,
add -y option to ttf2font to perform the adjustment in code.
This preserves the relative positions of lowercase 'a' and 'g' much better,
and allows the guides in the font editor to show at the right position.
Signed-off-by: Christophe de Dinechin <christophe@dinechin.org>
Depending on your compiler, <cerrno> (or <errno.h>) may not be implicitly
included by the existing system includes. Add it.
Reported-by: Nigel (UK)
Signed-off-by: Christophe de Dinechin <christophe@dinechin.org>
This makes it possible to reference them directly, instead of through an
indirect pointer. Pointer initialization order proves to be a tricky business,
and in the end, we may want to have adjustable fonts, so not much sense making
the pointers read-only anyway.
Signed-off-by: Christophe de Dinechin <christophe@dinechin.org>
Add references to the UI fonts from font.h
Also add font::height() to compute the height of the font
Signed-off-by: Christophe de Dinechin <christophe@dinechin.org>
An RPL font is an RPL object containing font data.
There are two kinds of font: dense and sparse (see code for details).
Internally, there is a third kind, designed to read built-in DM42 fonts.
Signed-off-by: Christophe de Dinechin <christophe@dinechin.org>