Skip to Content
The Alchemy Project

include/window/text_font.h

The Japanese font's kanji, and the voiced marks drawn over its kana.

Included by clear.c, articles.c, glyph_arm.c and window_internal.h.

Macros

NameDescription
#defineKANJI_GLYPH_SIZE 24In Japanese, the glyphs of character codes from KANJI_FIRST_CODE: KANJI_GLYPH_SIZE bytes each, drawn KANJI_WIDTH pixels wide.
#defineKANJI_WIDTH 10
#defineTEXT_MARK_SHIFT 14Japanese text carries a kana's mark in the top bits of its code, as its index in FontMarkGlyphCodes.

Enumerations

NameDescription
enumTEXT_MARK_GLYPH { TEXT_MARK_NONE, TEXT_MARK_VOICED, TEXT_MARK_SEMIVOICED }The marks a kana is drawn with: their character codes.

Variables

NameDescription
extern const Uint8FontKanjiGlyphs []The Japanese font's kanji, from KANJI_FIRST_CODE on.
extern const Uint16FontMarkGlyphCodes []The mark each of a kana's top-bit values stands for (TEXT_MARK_SHIFT): none, voiced, semi-voiced, none.

Description

The Japanese font's kanji, and the voiced marks drawn over its kana.

Macros in detail

KANJI_GLYPH_SIZE

#define KANJI_GLYPH_SIZE 24

In Japanese, the glyphs of character codes from KANJI_FIRST_CODE: KANJI_GLYPH_SIZE bytes each, drawn KANJI_WIDTH pixels wide.

Referenced by mnGlyphDrawArm().

Definition at line 11 of file text_font.h.

KANJI_WIDTH

#define KANJI_WIDTH 10

Referenced by mnGlyphDrawArm(), mnTextDrawGlyphPair() and mnTextDrawGlyphToCanvas().

Definition at line 12 of file text_font.h.

TEXT_MARK_SHIFT

#define TEXT_MARK_SHIFT 14

Japanese text carries a kana's mark in the top bits of its code, as its index in FontMarkGlyphCodes.

Referenced by mnGlyphDraw(), mnTextDrawGlyphPair(), mnTextDrawGlyphToCanvas(), mnTextDrawMessageToCanvas() and mnTextDrawWideStringAtOffset().

Definition at line 30 of file text_font.h.

Enumerations in detail

TEXT_MARK_GLYPH

enum TEXT_MARK_GLYPH

The marks a kana is drawn with: their character codes.

EnumeratorValueDescription
TEXT_MARK_NONE0
TEXT_MARK_VOICED222the voiced mark (dakuten)
TEXT_MARK_SEMIVOICED223the semi-voiced mark (handakuten)

Definition at line 21 of file text_font.h.

Variables in detail

FontKanjiGlyphs

extern const Uint8 FontKanjiGlyphs[]

The Japanese font's kanji, from KANJI_FIRST_CODE on.

Referenced by mnGlyphDrawArm(), mnTextDrawGlyphPair() and mnTextDrawGlyphToCanvas().

Definition at line 14 of file text_font.h.