I love blur effects and because of this, one of the first things I tried when I started learning AppKit, was how to implement a beautiful blurry background to elements. This is something that's super easy in HTML and CSS, and while it's also quite easy in AppKit, you don't get anywhere near as much customization - something as basic as blur radius cannot be changed in the `NSVisualEffectView` API provided by Apple. I always found this super annoying so I began looking for hacks to workaround this problem.
Unfortunately, I never got very far with it... AppKit is complex and a lot of it is poorly documented, so for a beginner, it's a big and hardcore task. And therefore, I just decided to live with the default `NSVisualEffect`... But just now, I found this repository:
This repository seems to have found a workaround to the _custom blur radius_ issue. However, they work in UIKit and I work in AppKit, so it's not quite the same, but should still be very useful as I think they use `CAFilter` which I believe works in both AppKit and UIKit.
I've never worked with `CAFilter` before, so should be interesting. Apparently it's a super old thing, and also, it's a private API so I don't expect to be able to find any official documentation about it... #dev
GitHub
GitHub - dominicstop/VisualEffectBlurView: `UIVisualEffectView` with support for `UIBlurEffect` blur w/ custom blur radius/intensity, and custom animatable filters
`UIVisualEffectView` with support for `UIBlurEffect` blur w/ custom blur radius/intensity, and custom animatable filters - dominicstop/VisualEffect...



The website objects are live, meaning that if the user double-clicks on an object, they can scroll, zoom, select text, and click links - just as they would in a real browser.
I need to show the actual website inside the minimap in the bottom-left corner. Currently, it just shows a dark box with a Safari logo.
#dev #Swift #SwiftUI #AppKit #macOS

