Unify more of the font generation logic between both paths and coalesce all fonts

This commit is contained in:
Ben V. Brown
2022-12-05 22:21:10 +11:00
parent 79eee9fc6c
commit e9a28c3671
5 changed files with 92 additions and 171 deletions

View File

@@ -149,9 +149,13 @@ struct TranslationData {
struct FontSection {
const uint8_t *font12_start_ptr;
const uint8_t *font06_start_ptr;
uint16_t font12_decompressed_size;
uint16_t font06_decompressed_size;
const uint8_t *font12_compressed_source; // Pointer to compressed data or null
const uint8_t *font06_compressed_source; // Pointer to compressed data or null
};
extern const struct FontSection FontSectionsData;
extern const FontSection FontSectionInfo;
constexpr uint8_t settings_item_index(const SettingsItemIndex i) { return static_cast<uint8_t>(i); }
// Use a constexpr function for type-checking.