Sorry, the issue is the icons will not show up, no matter the order of the Image/Text, or format of the Image() in the .tabItem{}. I've tried using .PNG files of size 32x32px, per the macOS Human Interface Guidelines (https://developer.apple.com/design/human-interface-guidelines/macos/icons-and-images/custom-icons/).I'm looking to create a TabView with the "Freestanding Toolbar Icons" like you would get using NSTabViewController.TabStyle.toolbarIs this a known limitation or a SwiftUI bug? If it's a limitation, and a "text segmented control style" is the only possibility on macOS, I think .tabItem{} should only accept Text on that platform.
Post
Replies
Boosts
Views
Activity
No problem, happy to help!
I think it's just your brackets.You should have one more on the `var body` block, and one less on the `PreviewProvider` block.
SelectionShapeStyle (macOS only) is not usable, since it has no public initializers.Bug Report: FB7511755
Thanks for filing a radar, the docs missing definitely seems like a bug. I wouldn't expect the new SwiftUI tutorials, but I think Button.onTapGesture, etc., should be there.I use the Xcode Developer Documentation sometimes too, since it can be faster to look things up. I probably ran into this and just thought the docs didn't exist 😮.