Used DuckDuckGo’s favicon service as per ohdear.app/blog/how-we-added-a. Did not, however, use the Spatie Media Library.

The biggest pain? Detecting whether we’ve got an ICO (which Imagick, it seems, isn’t particularly fond of) or something else (PNG, usually), and then extracting the (preferably) 32×32 “frame.”

With an emoji inside it! That explains why the final PNG (I’m converting all of these to PNG, by the way) shows the “weird byte sequence” block thingy. Don’t think I can get Imagick (or my install) to support emoji, so I might just have to detect SVG files and keep them as is. (Possible security issues, though ... Might just drop SVGs instead.)

The “missing emoji” character may in fact mean Imagick handles SVG just fine, and it’s the emoji (or SVGs containing emoji) we should somehow learn to deal with.

Now, I might also be able to merge, e.g., the Noto and Noto Emoji fonts, and try to use this new font for all of my “Imagick typesetting,” including emoji.

Sign in to participate in the conversation
Mastodon

The social network of the future: No ads, no corporate surveillance, ethical design, and decentralization! Own your data with Mastodon!