mirror of
https://github.com/ByteWelder/Tactility.git
synced 2026-10-17 19:05:07 +00:00
app-module: - Implement `AppStartContext` to reduce amount of `app_start_` and `app_exec` functions: replace them with `app_start_with_context()` - Add support for environment variables when starting apps - Implement support for environment variables for apps graphics-module: - Add this new module - Move font-module code into this module - Implement pixel_buffer apps: - Terminal app: reduce memory usage by only buffering a single row of characters, and try to buffer in IRAM when possible. Implement new pixel_buffer. - App List: Mark apps as favourite to pin them on top. Use touch or press "x" key. - App List: Add toolbar button that shows alert dialog with info about using favourites
30 lines
782 B
C
30 lines
782 B
C
// SPDX-License-Identifier: Apache-2.0
|
|
#pragma once
|
|
|
|
#include <stdint.h>
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
/**
|
|
* A fixed-width bitmap font: monospaced glyphs covering a contiguous codepoint range, one row of
|
|
* glyph_bytes_per_row bytes per pixel row (bit 7 of the first byte is the leftmost pixel).
|
|
*
|
|
* glyph_bitmap is indexed as glyph_bitmap[(ch - first_codepoint) * glyph_height *
|
|
* glyph_bytes_per_row + row * glyph_bytes_per_row + byte]; a codepoint outside
|
|
* [first_codepoint, last_codepoint] has no entry.
|
|
*/
|
|
typedef struct FixedWidthFont {
|
|
uint8_t glyph_width;
|
|
uint8_t glyph_height;
|
|
uint8_t glyph_bytes_per_row;
|
|
uint8_t first_codepoint;
|
|
uint8_t last_codepoint;
|
|
const uint8_t* glyph_bitmap;
|
|
} FixedWidthFont;
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|