box-drawings: implement octants

This commit is contained in:
Daniel Eklöf 2024-12-08 09:05:41 +01:00
parent 768f254286
commit 9a1b59adae
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F
5 changed files with 467 additions and 12 deletions

View file

@ -801,7 +801,15 @@ render_cell(struct terminal *term, pixman_image_t *pix, pixman_region32_t *damag
* Note, the full range is U+1FB00 - U+1FBF9
*/
(base >= GLYPH_LEGACY_FIRST &&
base <= GLYPH_LEGACY_LAST)) &&
base <= GLYPH_LEGACY_LAST) ||
/*
* Unicode 16 "Symbols for Legacy Computing Supplement"
*
* Note, the full range is U+1CC00 - U+1CEAF
*/
(base >= GLYPH_OCTANTS_FIRST &&
base <= GLYPH_OCTANTS_LAST)) &&
likely(!term->conf->box_drawings_uses_font_glyphs))
{
@ -809,7 +817,11 @@ render_cell(struct terminal *term, pixman_image_t *pix, pixman_region32_t *damag
size_t count;
size_t idx;
if (base >= GLYPH_LEGACY_FIRST) {
if (base >= GLYPH_OCTANTS_FIRST) {
arr = &term->custom_glyphs.octants;
count = GLYPH_OCTANTS_COUNT;
idx = base - GLYPH_OCTANTS_FIRST;
} else if (base >= GLYPH_LEGACY_FIRST) {
arr = &term->custom_glyphs.legacy;
count = GLYPH_LEGACY_COUNT;
idx = base - GLYPH_LEGACY_FIRST;