From b1e5fd4301a249e238e8f2d4e6bccd35f3ed1bed Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Sun, 2 Nov 2014 15:53:42 -0800 Subject: [PATCH] Now all pass with fonts too. --- dump.c | 37 ++++++++++++++++++++++++++++++++++++- notes | 5 +++++ 2 files changed, 41 insertions(+), 1 deletion(-) diff --git a/dump.c b/dump.c index 310b6a15f5..ac51919753 100644 --- a/dump.c +++ b/dump.c @@ -1567,6 +1567,40 @@ dump_title(void) } } +static void +dump_fonts(void) +{ + int i; + + printf("fonts: offset=%08x\n", pos); + match_byte(0); + for (i = 1; i <= 8; i++) + { + printf("%08x: font %d, ", pos, i); + match_byte_assert(i); + match_byte_assert(0x31); + printf("%s, ", get_string()); + match_byte_assert(0); + match_byte_assert(0); + if (!match_byte(0x40) && !match_byte(0x20) && !match_byte(0x80) && !match_byte(0x10)) + match_byte_assert(0x50); + if (!match_byte(0x41)) + match_byte_assert(0x51); + pos += 13; + printf ("%s, ", get_string()); + printf ("%s, ", get_string()); + match_u32_assert(0); + match_u32_assert(0); + pos++; + get_u32(); + get_u32(); + get_u32(); + get_u32(); + putchar('\n'); + } + +} + int main(int argc, char *argv[]) { @@ -1649,8 +1683,9 @@ main(int argc, char *argv[]) pos = start; dump_dims (); dump_data (); + dump_title (); if (!strcmp(argv[1], "all")) - dump_title (); + dump_fonts(); exit(0); } else diff --git a/notes b/notes index 772dbb8a6a..3699abdbc8 100644 --- a/notes +++ b/notes @@ -412,6 +412,11 @@ tdump1 to tdump18: 07 31 "SansSerif" 00 00 40 41 i0 00 i64173 i0 "#000000" "#ffffff" i0 i0 00 i8 i11 i1 i1 08 31 "SansSerif" 00 00 40 41 i0 00 i2 i3 "#000000" "#ffffff" i0 i0 00 i8 i11 i1 i4 +i1 i0 -> 01 00 00 00 00 00 00 00 +i0 00 -> 00 00 00 00 00 +i0 i0 -> 00 00 00 00 00 00 00 00 + + tdump19 to tdump27: 01 31 "SansSerif" 00 00 40 41 i1 i0 i0 00 "#000000" "#ffffff" i0 i0 00 i8 i11 i1 i8 02 31 "SansSerif" 00 00 40 41 i0 00 i2 i1 "#000000" "#ffffff" i0 i0 00 i8 i11 i1 i1 -- 2.30.2