I am attempting to make a macOS app to show a large popup with no titlebar and a transparent background that spans the entire active display.
Currently, I am attempting the last part, with the sizing. I used an example on the relevant developer documentation page. This is the code I am using in my App struct:
@main
struct MakeGoodChoicesApp: App {
...
var body: some Scene {
...
Window("Make Good Choices", id:"popup") {
PopupWindowContentView()
.ignoresSafeArea(.all)
}
.windowIdealPlacement {_, context in
return WindowPlacement(
x: context.defaultDisplay.bounds.minX,
y: context.defaultDisplay.bounds.minY,
width: context.defaultDisplay.bounds.width,
height: context.defaultDisplay.bounds.height
)
}
}
}
When running my application and using some code to open the popup
window, I get the following result:
I would expect the window to expand past the safe area, but it seems as if macOS clamped the window's size down to inside the safe areas.
I would appreciate any help, many thanks!