I'm looking to see if there is a way, in PHP, to determine if a glyph exists for a given character in a font.
My use case is this - I'm generating small images using Imagick - essentially small "badges" given user-provided info, and I'd really like to support full Unicode, including emoji and whatnot. As of now, I have a handful of fonts that each support a "class" of characters well (e.g., my "main" font is Futura, and I have Symbola for emoji and other symbols, and I may need to add another font for Eastern glyphs), but they don't have enough overlap to only use one font.
I've seen a post that suggests the commercial PDFlib add-on can do this, but I'd like to avoid commercial add-ons if I can. I also saw that the PECL PS add-on has ps_symbol_name(), but this requires an AFM file, and as far as I can tell, I can't use that with multibyte fonts.
I've got the font switching part taken care of in Imagick - I just need to know how I can tell it, programmatically, what font to use for a given character. Thanks!