Friday, June 28, 2024

Rounded Quick Look Corners

Robin Allen (via Hacker News):

For whatever reason, QuickLook will now remove the corners of your images before showing them to you.

It doesn’t matter if they’re photos, game assets, or UI elements you’re designing. Everything will be rounded off before you see it.

[…]

We can click through these views and get info about them, including their addresses so we can mess with them in the debugger. And we can see straight away that the frontmost view, which Xcode tells us is a QLBorderView, is a border with rounded corners!

[…]

We now have all the building blocks we need to make a nice script that attaches to all running QuickLook processes and patches them.

-[NSObject fp_shortMethodDescription] was new to me. QuickTime Player has also hidden the corners for for a long time. I think it also used to hide part of a paused video with the player controls, but now it hides those when you move the cursor out of the window.

1 Comment RSS · Twitter · Mastodon

These are copies of the UIKit methods with a similar name. On iOS they are implemented in UIKit, but in macOS, for whatever reason, they are implemented in FileProvider.

These are:

fp_methodDescription
fp_shortMethodDescription
fp_ivarDescription

Leave a Comment