Skip Menu |

This queue is for tickets about the Imager CPAN distribution.

Report information
The Basics
Id: 122225
Status: open
Priority: 90/
Queue: Imager

People
Owner: Nobody in particular
Requestors: ckuskie [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Wishlist
Broken in: (no value)
Fixed in: (no value)



Subject: RFE: Automatic font type detection
It looks like Imager uses file extensions to detect what kind of font is being supplied to Imager::Font. It would be really nice if it used something like Image::Exiftool to do that detection instead.
On Sun Jun 25 12:22:24 2017, COLINK wrote: Show quoted text
> It looks like Imager uses file extensions to detect what kind of font > is being supplied to Imager::Font. It would be really nice if it used > something like Image::Exiftool to do that detection instead.
Sorry about the delay in noticing this. I assume you mean some sort of magic number detection like Imager already does for images. Image::Exiftool sounds a little heavy for that though. It's an idea, but it may slow down creating a new font object, since Imager would need to open the file, check for magic, close the file, then hand off to the correct font handler. You can get pretty much the detection behaviour by always using the FT2 handler, since Freetype 2 supports and overwhelming superset of the fonts the other drivers support. I'll leave this open as a wishlist item, but it's pretty unlikely I'll implement it. Thanks, Tony