ascii-chat
Binary v0.16.114-28-gf5913657f
Library lib/v0.3.2-3302-gf5913657f
Video chat in your terminal
Loading...
Searching...
No Matches
src/web/common/font.c
Go to the documentation of this file.
1#include "font.h"
2#include <ascii-chat/font.h>
3#include <options/options.h>
4#include <options/rcu.h>
5
6/* Browser terminal rendering reads the embedded font directly from WASM memory. */
7const unsigned char *get_font_default_ptr(int selection) {
8 bool matrix = selection == 0 ? GET_OPTION(matrix_rain) : selection == 2;
10}
11
12unsigned int get_font_default_size(int selection) {
13 bool matrix = selection == 0 ? GET_OPTION(matrix_rain) : selection == 2;
14 return (unsigned int)(matrix ? g_font_matrix_resurrected_size : g_font_default_size);
15}
#define GET_OPTION(field)
Definition options.h:1339
Font resolution and bundled font data.
const size_t g_font_matrix_resurrected_size
const unsigned char g_font_matrix_resurrected[]
const size_t g_font_default_size
const unsigned char g_font_default[]
⚙️ Unified options parsing system for ascii-chat with builder pattern and lock-free access
unsigned int get_font_default_size(int selection)
const unsigned char * get_font_default_ptr(int selection)