# The bitmap font the Quow maps are lettered in.
#
# Read off genua.png, which is the cleanest source: its text resolves to exactly
# one shape per letter, where the busier city maps also throw up pairs of
# letters that touch each other.
#
# Format — one block per glyph:
#
#     char: A          the character this shape means ('x' quoted if it is a
#                      space, a '#', or anything else awkward)
#     offset: 5        REQUIRED for glyphs shorter than the 6px cap height, and
#                      meaningless for the rest. It is how many rows below the
#                      top of the line the shape sits, which is the only thing
#                      telling a full stop from an apostrophe.
#     .##.             the bitmap, '#' for ink
#     #..#
#
# Matching is exact — the shape is either in here or it is not. To teach it a
# new glyph, run `extract_labels.py atlas` and paste in what it prints.
#
# Shapes deliberately NOT listed: arrowheads, room dots, triangular markers and
# assorted artwork that happens to be six pixels tall. Leaving them out is what
# keeps them from being read as letters.

char: A
.##.
#..#
#..#
####
#..#
#..#

char: B
###.
#..#
###.
#..#
#..#
###.

char: C
.##.
#..#
#...
#...
#..#
.##.

char: D
###.
#..#
#..#
#..#
#..#
###.

char: E
###
#..
#..
##.
#..
###

char: F
###
#..
#..
##.
#..
#..

char: G
.###
#...
#...
#.##
#..#
.###

char: H
#..#
#..#
#..#
####
#..#
#..#

char: I
###
.#.
.#.
.#.
.#.
###

char: J
...#
...#
...#
...#
#..#
.##.

char: K
#..#
#..#
#.#.
###.
#.##
#..#

char: L
#..
#..
#..
#..
#..
###

char: N
##..#
##..#
#.#.#
#.#.#
#..##
#..##

char: M
##.##
#.#.#
#.#.#
#...#
#...#
#...#

char: O
.##.
#..#
#..#
#..#
#..#
.##.

# A wider O turns up in the larger headings.
char: O
.###.
#...#
#...#
#...#
#...#
.###.

char: P
###.
#..#
#..#
###.
#...
#...

char: R
###.
#..#
#..#
###.
#..#
#..#

char: S
.##.
#..#
##..
..##
#..#
.##.

char: T
###
.#.
.#.
.#.
.#.
.#.

char: U
#..#
#..#
#..#
#..#
#..#
.##.

char: U
#...#
#...#
#...#
#...#
#...#
.####

char: V
#...#
#...#
.#.#.
.#.#.
..#..
..#..

char: W
#...#
#...#
#.#.#
#.#.#
.#.#.
.#.#.

char: X
#..#
#..#
.##.
.##.
#..#
#..#

char: Y
#...#
#...#
.#.#.
..#..
..#..
..#..

char: Y
#.#
#.#
###
.#.
.#.
.#.

char: Z
####
...#
..#.
.#..
#...
####

char: '/'
..#
..#
.#.
.#.
#..
#..

# ── punctuation ──────────────────────────────────────────────────────────────
# Shorter than the cap height, so each needs its offset down the line. That
# offset is the whole identification: a full stop and an apostrophe are the same
# single pixel and differ only in how high they sit.

char: '.'
offset: 5
#

char: '-'
offset: 3
##

char: "'"
offset: 0
#
#

# ── further letters and digits ───────────────────────────────────────────────
# Absent from genua.png and picked up on the busier city maps.

char: Q
.##..
#..#.
#..#.
#..#.
#.##.
.####

char: '('
.#
#.
#.
#.
#.
.#

char: ')'
#.
.#
.#
.#
.#
#.

char: '1'
##
.#
.#
.#
.#
.#

char: '2'
.##.
#..#
...#
..#.
.#..
####

char: '4'
#..#
#..#
####
...#
...#
...#

# The exclamation mark is drawn as two pieces: a bar, and a dot on the baseline
# that matches as a full stop. The dot is absorbed after matching -- see
# merge_combining() -- or ARR! would come out as "ARR!.".
#
# NOTE: a bare '#' on its own line is a valid one-pixel bitmap row, so never use
# one as a spacer inside a comment block. A blank line closes a glyph, which is
# what keeps this comment from being read as pixels.
#
# Two shapes, and the order matters. The whole mark comes FIRST so it is
# variant 0 and is what gets drawn; it never matches anything, because the two
# pieces are never one component. The bar alone is variant 1 and is what
# actually matches, and merge_combining rewrites it to variant 0 once it has
# swallowed the dot -- otherwise the redrawn mark would have no dot.
char: '!'
#
#
#
#
.
#

char: '!'
offset: 0
#
#
#
#

# ── more digits ──────────────────────────────────────────────────────────────
# The guild maps number their rooms, and these turn up nowhere else.

char: '5'
####
#...
###.
...#
#..#
.##.

char: '6'
.##.
#..#
#...
###.
#..#
.##.

char: '8'
.##.
#..#
.##.
#..#
#..#
.##.

char: '3'
.##.
#..#
...#
..#.
#..#
.##.

char: '7'
####
...#
..#.
.###
..#.
..#.
