From e6d8e23ede6d45727c4a0968ec356ac5f9792ba7 Mon Sep 17 00:00:00 2001 From: Po Lu Date: Thu, 21 Dec 2023 14:35:18 +0800 Subject: [PATCH] * src/sfnt.c (GETINFO): Implement undocumented selector bit 5. --- src/sfnt.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/sfnt.c b/src/sfnt.c index 4d377ddf5e5..0e2308bcbac 100644 --- a/src/sfnt.c +++ b/src/sfnt.c @@ -7605,9 +7605,12 @@ sfnt_interpret_trap (struct sfnt_interpreter *interpreter, interpreter->state.scan_control = value; \ } -/* Selector bit 8 is undocumented, but present in the Macintosh +/* Selector bit 3 is undocumented, but present in the Macintosh rasterizer. 02000 is returned if there is a variation axis in - use. */ + use. + + Selector bit 5 is undocumented, but relied on by several fonts. + 010000 is returned if a grayscale rasterizer is in use. */ #define GETINFO() \ { \ @@ -7624,6 +7627,9 @@ sfnt_interpret_trap (struct sfnt_interpreter *interpreter, && interpreter->norm_coords) \ k |= 02000; \ \ + if (selector & 32) \ + k |= 010000; \ + \ PUSH_UNCHECKED (k); \ } -- 2.39.2