Post

Replies

Boosts

Views

Activity

SwiftUI Form (Grouped) with Table
Hi everyone, I’m having an issue with a SwiftUI Table inside a Form in a macOS app. When the Form style is set to .grouped, the Table does not resize to the full width of the Form or Sheet. However, when I switch to a .plain style, it resizes correctly. Here’s a simplified version of my code: Section(header: Text("Header")) { Table(data) { TableColumn("Column 1", value: \.col1) TableColumn("Column 2", value: \.col2) // Add more columns as needed } .frame(height: 100) } } .formStyle(.grouped) // Issue occurs only with this style Has anyone else experienced this? Any workarounds or suggestions would be greatly appreciated! Thanks!
3
0
260
Sep ’24
What happened to primaryAction in Menu?
According to WWDC video and documentation this code should work: Menu { Button(action: addCurrentTabToReadingList) { Label("Add to Reading List", systemImage: "eyeglasses") } Button(action: bookmarkAll) { Label("Add Bookmarks for All Tabs", systemImage: "book") } Button(action: show) { Label("Show All Bookmarks", systemImage: "books.vertical") } } label: { Label("Add Bookmark", systemImage: "book") } primaryAction: { addBookmark() } However when I try it, it throws an error: Extra argument in call for primaryAction any ideas? (latest beta MacOS, and latest Xcode)
4
0
550
Sep ’21
App freezes on Launch Screen for several minutes
This started all of a sudden one day. Latest Xcode (stable) Latest iOS (stable) When building and running from Xcode the app will freeze on launch screen for several minutes (average about 2min) and then after wakes up and all is good. Tried all known tricks: reinstall iOS reinstall Xcode standing upside down drinking coca cola with a straw (ok I didn't try that). Nothing works... (changing the scheme as suggested here does work but this is not ideal of course as I loose all my debugging tools). https://stackoverflow.com/questions/54091746/app-freezes-on-launch-screen-when-installed-from-xcode-10-1-to-ios-12 Anyone can help?
4
0
3.6k
Nov ’20
Swift Playgrounds Author Template for xcode
Hi guys,the latest template from Apple (Swift Playgrounds Author Template for xcode 11.1) is not working and has not been updated for months.Even with the release of Xcode 11.3 the template is not supported.we are getting an error:Module compiled with Swift 5.1 cannot be imported by the Swift 5.1.2 compiler: .....PlaygroundSupport.framework/Modules/PlaygroundSupport.swiftmodule/arm64-apple-ios.swiftmoduleany solutions? thank you
6
0
2.3k
Dec ’19