Search results for

“swiftui”

17,488 results found

Post

Replies

Boosts

Views

Activity

Sandbox denies mach-lookup com.apple.cloudd only when app is launched outside Xcode (CKError 6)
macOS 26.6.1 on an M4 Mac mini, Xcode 26.6 (building against the macOS 26.5 SDK). Sandboxed SwiftUI app using NSPersistentCloudKitContainer. App: com.klausmack-software.NoteManagerPro Container: iCloud.com.klausmack-software.NoteManagerPro When I launch NoteManagerPro from Xcode, CloudKit sync works. When I launch the exact same build by double-clicking it — from /Applications or straight from the build products folder — CloudKit setup fails with CKError 6 (Error connecting to CloudKit daemon), and the kernel logs: Sandbox: NoteManagerPro(4338) deny(1) mach-lookup com.apple.cloudd launchd: denied lookup: name = com.apple.cloudd, requestor = NoteManagerPro[4338], error = 159: Sandbox restriction Sandbox: NoteManagerPro(4338) deny(1) mach-lookup com.apple.duetactivityscheduler Immediately before those lines: secinitd: NoteManagerPro[4338]: AppSandbox request successful kernel: (Sandbox) Sandbox apply: NoteManagerPro[4338] CloudKit additionally logs that the process may need (allow user-preference-read
4
0
184
1w
Reply to iOS 27 Beta 5: Button actions ignored inside horizontal SwiftUI ScrollView (minimal repro)
I’m seeing what appears to be the same regression on iOS 27 Beta 5 in a production SwiftUI app. In my case the affected UI is a horizontal filter/action: ScrollView(.horizontal, showsIndicators: false) { HStack(spacing: 8) { groupMenu sortMenu templatesButton voiceButton } .padding(.horizontal, 16) .padding(.vertical, 8) } The controls are a mixture of native SwiftUI Menu and Button views rather than one custom control implementation: Group: Menu Sort: Menu Templates: Button Voice: Button On iOS 27 Beta 5 the controls render normally, but taps around the centre/upper portion of the controls are frequently ignored. Tapping toward the lower edge of the same visible control can trigger it. The important part in my case is that multiple different control types in the same horizontal ScrollView exhibit the same behaviour. The actions themselves are working — when the tap is recognised, the menu opens or the button action runs normally. The surrounding screen uses a normal NavigationStack with an
Topic: UI Frameworks SubTopic: SwiftUI Tags:
1w
Custom pointer color makes -[NSCursor set] re-render from PDF on every call, pinning a CPU core across unrelated apps (macOS 27.0)
Filed as FB24344519. Posting here too because the scope is wider than any single app, and other developers may be getting your app uses too much CPU reports that are not actually their bug. Environment: macOS 27.0 (26A5406e), Apple Silicon (M5 Max). SUMMARY When a custom pointer color is set, every -[NSCursor set] call re-renders the pointer artwork from a PDF, with no caching. Any app whose UI frequently invalidates AppKit tracking areas then burns most of a CPU core continuously, with the mouse completely stationary. Trigger: defaults read com.apple.universalaccess cursorIsCustomized 1 That is System Settings > Accessibility > Display > Pointer, with a custom fill and outline color set. With default pointer colors, -[NSCursor set] is nearly free. CALL PATH (sampled with the mouse untouched) CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK -[_NSTrackingAreaAKManager _activeTrackingAreasNeedUpdate]_block_invoke -[_NSTrackingAreaAKManager _updateActiveTrackingAreasForWindowLocation:modifierFlags:] -[NSCursor set]
Topic: UI Frameworks SubTopic: AppKit
0
0
100
1w
Reply to Xcode 27: Bugs / Feedbacks
@DTS Engineer Xcode 27 Beta 5 seems to crash quite often, I think it happens when I edit code. I think SwiftUI preview was trying to render while I was editing. I have submitted the crash reports, by clicking Send to Apple button on the crash report. Hopefully they can be fixed, Xcode 27 Beta 4 didn't crash like this, seems to be happening on Xcode 27 Beta 5.
1w
Reply to Alert Closures Not Firing + Navigation Animations Broken
@astro-spacecadet, did you ever find a workaround or file a Feedback for this? If you have an FB number, I'd like to reference it in mine. I'm hitting exactly this in a production watchOS app (Apple Watch Ultra 3, watchOS 26.6): alerts present and dismiss normally on tap, but their button closures never execute - combined with every screen-transition animation going dead (pushed views snap into place, the nav-bar clock gets stuck mid-transition position). One difference from your case: mine heals on a true scene .background transition (crown press), no force-quit needed. With an active HKWorkoutSession the app never backgrounds on its own, which is why the broken state can persist for an hour of real use. I instrumented every alert (present / action-fired / dismiss edges) plus sheet lifecycle events, and caught a full wedged session in the field. Findings: 44 consecutive alert present→dismiss cycles with zero actions fired, across 4 different alerts on 3 different presenters - including one attached directly
Topic: UI Frameworks SubTopic: SwiftUI
1w
iOS 27 Beta 5: Button actions ignored inside horizontal SwiftUI ScrollView (minimal repro)
On iOS/iPadOS 27 Beta 5 (24A5408d), I can consistently reproduce SwiftUI Button actions being ignored when the buttons are placed inside a horizontal ScrollView near the top of a view. This occurs on physical iPhone and iPad devices and on an iPhone 16 Simulator. Equivalent UI was reliable on the preceding beta. Minimal shape: struct ContentView: View { @State private var selection = All var body: some View { NavigationStack { VStack(spacing: 0) { ScrollView(.horizontal, showsIndicators: false) { HStack { ForEach([All, Food, Transport], id: .self) { item in Button(item) { selection = item } .padding() } } } Text(Selected: (selection)) Button(Control below) { selection = Control } Spacer() } .navigationTitle(Touch Hit-Test Repro) .navigationBarTitleDisplayMode(.inline) } } } The standalone reproducer includes an XCUITest comparison. Results on the iOS 27 Beta 5 iPhone 16 Simulator: Horizontal ScrollView: fails; the chip is reported as hittable but tap() does not invoke its action. Remove .searchable:
4
0
295
1w
Instruments fails while processing SwiftUI recording
I’m seeing a consistent Instruments error after recording a SwiftUI profile: “Failed to stop recording session: Data Providers emitted errors: Required” The recording itself starts and runs normally. The error appears only after I stop recording, while Instruments is processing the trace. No profiling results are produced. Environment: Xcode 27.0 beta 5 (27A5237l) Instruments 27.0 (27A5237l) Physical iOS device running the latest beta I can reproduce this consistently using the SwiftUI template. I’ve also tried updating Instruments and restarting the tools, but the issue remains. Expected: The trace finishes processing and displays the collected data. Actual: Processing fails with the data-provider error above.
1
0
388
2w
Nested `Menu` (submenu) jumps / misplaces on first open when presented from a partial-height `.sheet` (iOS 26, iPhone, Liquid Glass)
On iOS 26, a nested Menu (a drill-in submenu) visibly jumps and repositions for about a second the first time a submenu is opened, when the menu lives inside a .sheet that is at any partial-height detent — .medium, or a custom .height(...)/.fraction(...) detent. Reopening the same submenu is smooth. The problem does not occur on iPad, does not occur when the sheet is at full height (.large), and does not occur for a flat (single-level) menu. It reproduces with a completely stock Menu, and also with a UIKit UIButton + UIMenu, so it does not appear to be tied to any specific app code. The trigger is purely that the sheet's presentation host is shorter than the screen — the specific detent type does not matter. Minimal reproducible example (stock SwiftUI only) import SwiftUI struct MinimalRepro: View { @State private var showSheet = false var body: some View { Button(Open sheet) { showSheet = true } .sheet(isPresented: $showSheet) { VStack { Menu(Status) { Menu(Category A) { Button(Option 1) {}
3
0
165
2w
StoreKit 2 returns zero subscription products in Sandbox/TestFlight — FB24199369
StoreKit 2 returns zero subscription products in Sandbox/TestFlight — FB24199369 I’m experiencing an issue where StoreKit 2 returns zero subscription products in both Sandbox and TestFlight for my iOS app. App: Bundle ID: com.sleeplessnight.naengbiseo Subscription group: Naengbiseo Premium Product IDs: naengbiseo_premium_monthly naengbiseo_premium_yearly Although the production app uses RevenueCat, I reproduced the same issue in a separate minimal native SwiftUI app using StoreKit 2 directly, with no RevenueCat, Expo, React Native, or other third-party SDK involved. Native StoreKit 2 call: let products = try await Product.products(for: [ naengbiseo_premium_monthly, naengbiseo_premium_yearly ]) Current native test result: STOREKIT_COUNTRY_CODE: KOR STOREKIT_STOREFRONT_ID: 143466 DIRECT_STOREKIT_COUNT: 0 Returned products: None Test environment: Physical iPhone StoreKit Configuration: None Sandbox Apple Account signed in Storefront: KOR In-App Purchase capability enabled Correct Bundle ID and Product I
2
0
278
2w
MFMailComposeViewController has incorrect navigation bar behavior when presented from SwiftUI
I'm seeing two related UI issues when presenting MFMailComposeViewController from SwiftUI using .sheet. The Cancel button disappears During the sheet presentation animation, the Cancel button is visible in the navigation bar. However, once the presentation animation completes, the Cancel button disappears. This is particularly problematic when the mail composer is presented full-screen: since the Cancel button is removed, there is no longer any way for the user to cancel composing the email and dismiss MFMailComposeViewController. The navigation bar changes abruptly when the presentation animation finishes The navigation bar has one appearance while the sheet is being presented, including the Cancel button and the layout/styling of its navigation items. As soon as the presentation animation finishes, the navigation bar abruptly changes to a different appearance. This causes a noticeable flicker/jump at the end of the animation. In other words, the appearance of MFMailComposeViewController during the
Topic: UI Frameworks SubTopic: SwiftUI
0
0
74
2w
Reply to Various menu bar NSStatusItem issues with macOS 27
UPDATE: The NSStatusItem does not receive mouse hover/movement events on macOS (FB23329983) seems to be fixed in macOS 27 dev beta 5 (build 26A5406e). The following issues still remain: inability to set NSStatusItem button highlight cannot be set programmatically (B23330269), for which expandedInterfaceDelegate gives a partial solution. NSStatusItem window occlusionState no longer reflects hidden menu bar visibility (FB23349447) Additionally, there is a somewhat serious design issue/oversight with expandedInterfaceDelegate and expandedInterfaceSession when it comes to implementing touch support. With a custom menu bar extra window implementation (when one uses a custom NSWindow or NSPanel and for the menu bar extra app's window together with the new expandedInterface..., instead of relying on the traditional NSMenu or NSPopover attached to a menubar extra status item) there is no mechanism at all to detect touch tap gesture outside of the window. This would be essential to figure out when the user wants to di
Topic: UI Frameworks SubTopic: AppKit Tags:
2w
2D Soft Shadows with SpriteKit and Metal
Hi! I'd like to share an implementation of 2D soft shadows using SpriteKit and custom Metal rendering. GitHub Repo SpriteKit-SoftShadows The demo app runs on iOS and Mac Catalyst. The soft shadow implementation is based on Scott Lembcke's algorithm. Pipeline The app uses MTKView to drive the rendering loop at the desired frame rate. Each frame: SpriteKit renders the scene into a Metal texture using SKRenderer. The CPU sends each light's properties and the relevant shape edges to a Metal vertex shader. The vertex shader projects shadow geometry from each edge. A fragment shader calculates the shadow opacity at each pixel, producing a soft shadow mask for each light. A final fragment shader combines the SpriteKit texture, lights, and shadow masks to produce the displayed image. The SwiftUI controls update variables inside the SpriteKit scene through @Observable. The rendering loop consumes the new values on its next cycle. Let me know if you have any feedback!
0
0
538
2w
Reply to App Startup with Debugger in Xcode 26 is slow
Hi @DTS Engineer and @fpiovezan, I filed FB24278299 for this issue. The problem still reproduces with Xcode 26.6 (17F113) and iOS 26.6 (23G71) on an iPhone 15 Pro Max over Wi-Fi, using an unmodified SwiftUI/SwiftData iOS App template. With “Debug executable” enabled over Wi-Fi, the first screen remains unresponsive for approximately 40 seconds. The same template has no noticeable delay over Wi-Fi with “Debug executable” disabled and becomes responsive in approximately 5 seconds over USB with LLDB attached. FB24278299 includes the minimal project, recordings, Xcode Launch Results, exact timestamps, synchronized Mac and iPhone diagnostics, CoreDevice and Xcode diagnostics, and the requested Accessibility settings evidence. Please associate it with FB20344064, FB20359822, and FB21378487 if appropriate. Thank you for looking into this and for the earlier guidance in this thread.
2w
Reply to App Launchscreen Size NOT Correct on iPadOS 26
Dear @AlexeyVasilkov, @HuijieLin, Could either of you please provide a small test project that replicates this issue? You could provide a link to download the project. If you're not familiar with preparing a test project, please take a look at Creating a test project. To answer the questions in the OP: Is it expected that iPadOS renders LaunchScreen.storyboard based on the interface orientation / size class rather than the actual window bounds in multitasking scenarios? This would not be the case, except if UIRequiresFullScreen is set to true, causing your app to be in compatibility mode, making your scene’s interface orientation to match the aspect ratio of the scene bounds. (Note: this key is deprecated as of iPadOS 26. For details, please see technote TN3192: Migrating your iPad app from the deprecated UIRequiresFullScreen key.) If not expected, what is the recommended way to ensure the Launch Screen matches the app’s actual window size/aspect ratio at launch (without using code, since Launch Screen is sta
Topic: UI Frameworks SubTopic: General Tags:
2w
Sandbox denies mach-lookup com.apple.cloudd only when app is launched outside Xcode (CKError 6)
macOS 26.6.1 on an M4 Mac mini, Xcode 26.6 (building against the macOS 26.5 SDK). Sandboxed SwiftUI app using NSPersistentCloudKitContainer. App: com.klausmack-software.NoteManagerPro Container: iCloud.com.klausmack-software.NoteManagerPro When I launch NoteManagerPro from Xcode, CloudKit sync works. When I launch the exact same build by double-clicking it — from /Applications or straight from the build products folder — CloudKit setup fails with CKError 6 (Error connecting to CloudKit daemon), and the kernel logs: Sandbox: NoteManagerPro(4338) deny(1) mach-lookup com.apple.cloudd launchd: denied lookup: name = com.apple.cloudd, requestor = NoteManagerPro[4338], error = 159: Sandbox restriction Sandbox: NoteManagerPro(4338) deny(1) mach-lookup com.apple.duetactivityscheduler Immediately before those lines: secinitd: NoteManagerPro[4338]: AppSandbox request successful kernel: (Sandbox) Sandbox apply: NoteManagerPro[4338] CloudKit additionally logs that the process may need (allow user-preference-read
Replies
4
Boosts
0
Views
184
Activity
1w
Reply to iOS 27 Beta 5: Button actions ignored inside horizontal SwiftUI ScrollView (minimal repro)
I’m seeing what appears to be the same regression on iOS 27 Beta 5 in a production SwiftUI app. In my case the affected UI is a horizontal filter/action: ScrollView(.horizontal, showsIndicators: false) { HStack(spacing: 8) { groupMenu sortMenu templatesButton voiceButton } .padding(.horizontal, 16) .padding(.vertical, 8) } The controls are a mixture of native SwiftUI Menu and Button views rather than one custom control implementation: Group: Menu Sort: Menu Templates: Button Voice: Button On iOS 27 Beta 5 the controls render normally, but taps around the centre/upper portion of the controls are frequently ignored. Tapping toward the lower edge of the same visible control can trigger it. The important part in my case is that multiple different control types in the same horizontal ScrollView exhibit the same behaviour. The actions themselves are working — when the tap is recognised, the menu opens or the button action runs normally. The surrounding screen uses a normal NavigationStack with an
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
1w
Custom pointer color makes -[NSCursor set] re-render from PDF on every call, pinning a CPU core across unrelated apps (macOS 27.0)
Filed as FB24344519. Posting here too because the scope is wider than any single app, and other developers may be getting your app uses too much CPU reports that are not actually their bug. Environment: macOS 27.0 (26A5406e), Apple Silicon (M5 Max). SUMMARY When a custom pointer color is set, every -[NSCursor set] call re-renders the pointer artwork from a PDF, with no caching. Any app whose UI frequently invalidates AppKit tracking areas then burns most of a CPU core continuously, with the mouse completely stationary. Trigger: defaults read com.apple.universalaccess cursorIsCustomized 1 That is System Settings > Accessibility > Display > Pointer, with a custom fill and outline color set. With default pointer colors, -[NSCursor set] is nearly free. CALL PATH (sampled with the mouse untouched) CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK -[_NSTrackingAreaAKManager _activeTrackingAreasNeedUpdate]_block_invoke -[_NSTrackingAreaAKManager _updateActiveTrackingAreasForWindowLocation:modifierFlags:] -[NSCursor set]
Topic: UI Frameworks SubTopic: AppKit
Replies
0
Boosts
0
Views
100
Activity
1w
Reply to Xcode 27: Bugs / Feedbacks
@DTS Engineer Xcode 27 Beta 5 seems to crash quite often, I think it happens when I edit code. I think SwiftUI preview was trying to render while I was editing. I have submitted the crash reports, by clicking Send to Apple button on the crash report. Hopefully they can be fixed, Xcode 27 Beta 4 didn't crash like this, seems to be happening on Xcode 27 Beta 5.
Replies
Boosts
Views
Activity
1w
Reply to Alert Closures Not Firing + Navigation Animations Broken
@astro-spacecadet, did you ever find a workaround or file a Feedback for this? If you have an FB number, I'd like to reference it in mine. I'm hitting exactly this in a production watchOS app (Apple Watch Ultra 3, watchOS 26.6): alerts present and dismiss normally on tap, but their button closures never execute - combined with every screen-transition animation going dead (pushed views snap into place, the nav-bar clock gets stuck mid-transition position). One difference from your case: mine heals on a true scene .background transition (crown press), no force-quit needed. With an active HKWorkoutSession the app never backgrounds on its own, which is why the broken state can persist for an hour of real use. I instrumented every alert (present / action-fired / dismiss edges) plus sheet lifecycle events, and caught a full wedged session in the field. Findings: 44 consecutive alert present→dismiss cycles with zero actions fired, across 4 different alerts on 3 different presenters - including one attached directly
Topic: UI Frameworks SubTopic: SwiftUI
Replies
Boosts
Views
Activity
1w
iOS 27 Beta 5: Button actions ignored inside horizontal SwiftUI ScrollView (minimal repro)
On iOS/iPadOS 27 Beta 5 (24A5408d), I can consistently reproduce SwiftUI Button actions being ignored when the buttons are placed inside a horizontal ScrollView near the top of a view. This occurs on physical iPhone and iPad devices and on an iPhone 16 Simulator. Equivalent UI was reliable on the preceding beta. Minimal shape: struct ContentView: View { @State private var selection = All var body: some View { NavigationStack { VStack(spacing: 0) { ScrollView(.horizontal, showsIndicators: false) { HStack { ForEach([All, Food, Transport], id: .self) { item in Button(item) { selection = item } .padding() } } } Text(Selected: (selection)) Button(Control below) { selection = Control } Spacer() } .navigationTitle(Touch Hit-Test Repro) .navigationBarTitleDisplayMode(.inline) } } } The standalone reproducer includes an XCUITest comparison. Results on the iOS 27 Beta 5 iPhone 16 Simulator: Horizontal ScrollView: fails; the chip is reported as hittable but tap() does not invoke its action. Remove .searchable:
Replies
4
Boosts
0
Views
295
Activity
1w
Instruments fails while processing SwiftUI recording
I’m seeing a consistent Instruments error after recording a SwiftUI profile: “Failed to stop recording session: Data Providers emitted errors: Required” The recording itself starts and runs normally. The error appears only after I stop recording, while Instruments is processing the trace. No profiling results are produced. Environment: Xcode 27.0 beta 5 (27A5237l) Instruments 27.0 (27A5237l) Physical iOS device running the latest beta I can reproduce this consistently using the SwiftUI template. I’ve also tried updating Instruments and restarting the tools, but the issue remains. Expected: The trace finishes processing and displays the collected data. Actual: Processing fails with the data-provider error above.
Replies
1
Boosts
0
Views
388
Activity
2w
Reply to SwiftUI.Task cancellation behaviour
Hello @MrWizardCoder, SwiftUI's .task is a view modifier that inherits the cancellation behavior of Swift.Task. For updates to the documentation, feel free to add your suggested wording in a Feedback request through Feedback Assistant.  Travis
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
2w
Nested `Menu` (submenu) jumps / misplaces on first open when presented from a partial-height `.sheet` (iOS 26, iPhone, Liquid Glass)
On iOS 26, a nested Menu (a drill-in submenu) visibly jumps and repositions for about a second the first time a submenu is opened, when the menu lives inside a .sheet that is at any partial-height detent — .medium, or a custom .height(...)/.fraction(...) detent. Reopening the same submenu is smooth. The problem does not occur on iPad, does not occur when the sheet is at full height (.large), and does not occur for a flat (single-level) menu. It reproduces with a completely stock Menu, and also with a UIKit UIButton + UIMenu, so it does not appear to be tied to any specific app code. The trigger is purely that the sheet's presentation host is shorter than the screen — the specific detent type does not matter. Minimal reproducible example (stock SwiftUI only) import SwiftUI struct MinimalRepro: View { @State private var showSheet = false var body: some View { Button(Open sheet) { showSheet = true } .sheet(isPresented: $showSheet) { VStack { Menu(Status) { Menu(Category A) { Button(Option 1) {}
Replies
3
Boosts
0
Views
165
Activity
2w
StoreKit 2 returns zero subscription products in Sandbox/TestFlight — FB24199369
StoreKit 2 returns zero subscription products in Sandbox/TestFlight — FB24199369 I’m experiencing an issue where StoreKit 2 returns zero subscription products in both Sandbox and TestFlight for my iOS app. App: Bundle ID: com.sleeplessnight.naengbiseo Subscription group: Naengbiseo Premium Product IDs: naengbiseo_premium_monthly naengbiseo_premium_yearly Although the production app uses RevenueCat, I reproduced the same issue in a separate minimal native SwiftUI app using StoreKit 2 directly, with no RevenueCat, Expo, React Native, or other third-party SDK involved. Native StoreKit 2 call: let products = try await Product.products(for: [ naengbiseo_premium_monthly, naengbiseo_premium_yearly ]) Current native test result: STOREKIT_COUNTRY_CODE: KOR STOREKIT_STOREFRONT_ID: 143466 DIRECT_STOREKIT_COUNT: 0 Returned products: None Test environment: Physical iPhone StoreKit Configuration: None Sandbox Apple Account signed in Storefront: KOR In-App Purchase capability enabled Correct Bundle ID and Product I
Replies
2
Boosts
0
Views
278
Activity
2w
MFMailComposeViewController has incorrect navigation bar behavior when presented from SwiftUI
I'm seeing two related UI issues when presenting MFMailComposeViewController from SwiftUI using .sheet. The Cancel button disappears During the sheet presentation animation, the Cancel button is visible in the navigation bar. However, once the presentation animation completes, the Cancel button disappears. This is particularly problematic when the mail composer is presented full-screen: since the Cancel button is removed, there is no longer any way for the user to cancel composing the email and dismiss MFMailComposeViewController. The navigation bar changes abruptly when the presentation animation finishes The navigation bar has one appearance while the sheet is being presented, including the Cancel button and the layout/styling of its navigation items. As soon as the presentation animation finishes, the navigation bar abruptly changes to a different appearance. This causes a noticeable flicker/jump at the end of the animation. In other words, the appearance of MFMailComposeViewController during the
Topic: UI Frameworks SubTopic: SwiftUI
Replies
0
Boosts
0
Views
74
Activity
2w
Reply to Various menu bar NSStatusItem issues with macOS 27
UPDATE: The NSStatusItem does not receive mouse hover/movement events on macOS (FB23329983) seems to be fixed in macOS 27 dev beta 5 (build 26A5406e). The following issues still remain: inability to set NSStatusItem button highlight cannot be set programmatically (B23330269), for which expandedInterfaceDelegate gives a partial solution. NSStatusItem window occlusionState no longer reflects hidden menu bar visibility (FB23349447) Additionally, there is a somewhat serious design issue/oversight with expandedInterfaceDelegate and expandedInterfaceSession when it comes to implementing touch support. With a custom menu bar extra window implementation (when one uses a custom NSWindow or NSPanel and for the menu bar extra app's window together with the new expandedInterface..., instead of relying on the traditional NSMenu or NSPopover attached to a menubar extra status item) there is no mechanism at all to detect touch tap gesture outside of the window. This would be essential to figure out when the user wants to di
Topic: UI Frameworks SubTopic: AppKit Tags:
Replies
Boosts
Views
Activity
2w
2D Soft Shadows with SpriteKit and Metal
Hi! I'd like to share an implementation of 2D soft shadows using SpriteKit and custom Metal rendering. GitHub Repo SpriteKit-SoftShadows The demo app runs on iOS and Mac Catalyst. The soft shadow implementation is based on Scott Lembcke's algorithm. Pipeline The app uses MTKView to drive the rendering loop at the desired frame rate. Each frame: SpriteKit renders the scene into a Metal texture using SKRenderer. The CPU sends each light's properties and the relevant shape edges to a Metal vertex shader. The vertex shader projects shadow geometry from each edge. A fragment shader calculates the shadow opacity at each pixel, producing a soft shadow mask for each light. A final fragment shader combines the SpriteKit texture, lights, and shadow masks to produce the displayed image. The SwiftUI controls update variables inside the SpriteKit scene through @Observable. The rendering loop consumes the new values on its next cycle. Let me know if you have any feedback!
Replies
0
Boosts
0
Views
538
Activity
2w
Reply to App Startup with Debugger in Xcode 26 is slow
Hi @DTS Engineer and @fpiovezan, I filed FB24278299 for this issue. The problem still reproduces with Xcode 26.6 (17F113) and iOS 26.6 (23G71) on an iPhone 15 Pro Max over Wi-Fi, using an unmodified SwiftUI/SwiftData iOS App template. With “Debug executable” enabled over Wi-Fi, the first screen remains unresponsive for approximately 40 seconds. The same template has no noticeable delay over Wi-Fi with “Debug executable” disabled and becomes responsive in approximately 5 seconds over USB with LLDB attached. FB24278299 includes the minimal project, recordings, Xcode Launch Results, exact timestamps, synchronized Mac and iPhone diagnostics, CoreDevice and Xcode diagnostics, and the requested Accessibility settings evidence. Please associate it with FB20344064, FB20359822, and FB21378487 if appropriate. Thank you for looking into this and for the earlier guidance in this thread.
Replies
Boosts
Views
Activity
2w
Reply to App Launchscreen Size NOT Correct on iPadOS 26
Dear @AlexeyVasilkov, @HuijieLin, Could either of you please provide a small test project that replicates this issue? You could provide a link to download the project. If you're not familiar with preparing a test project, please take a look at Creating a test project. To answer the questions in the OP: Is it expected that iPadOS renders LaunchScreen.storyboard based on the interface orientation / size class rather than the actual window bounds in multitasking scenarios? This would not be the case, except if UIRequiresFullScreen is set to true, causing your app to be in compatibility mode, making your scene’s interface orientation to match the aspect ratio of the scene bounds. (Note: this key is deprecated as of iPadOS 26. For details, please see technote TN3192: Migrating your iPad app from the deprecated UIRequiresFullScreen key.) If not expected, what is the recommended way to ensure the Launch Screen matches the app’s actual window size/aspect ratio at launch (without using code, since Launch Screen is sta
Topic: UI Frameworks SubTopic: General Tags:
Replies
Boosts
Views
Activity
2w