Construct and manage graphical, event-driven user interfaces for iOS or tvOS apps using UIKit.

UIKit Documentation

Posts under UIKit subtopic

Post

Replies

Boosts

Views

Activity

Launch screen not refreshed after app update: is clearing Library/SplashBoard supported?
We're adding an option to our Unity SDK that gives a game a native launch screen: a launch storyboard (set through UILaunchStoryboardName) showing a full-screen image from an asset catalog. What we see On a clean install, the new launch screen shows as expected. When the same device installs an update over the existing app (tested through TestFlight), the previous launch screen keeps showing. Launching the app several times does not change it. Deleting the app, restarting the device and reinstalling shows the new launch screen straight away. We checked the build itself: the compiled storyboard, the image in Assets.car and the Info.plist keys are all correct, so this looks like the system's launch screen snapshot cache. We assume App Store updates behave the same way. What we're considering On the first launch after an update, the app would delete the cached launch screen snapshots in its own container (Library/SplashBoard), so the system regenerates them and the new launch screen shows on the next launch. This only uses public file APIs inside the app's own sandbox. But Library/SplashBoard is not documented anywhere, so we'd rather ask before shipping it. Questions Is deleting Library/SplashBoard from the app's own container a supported or acceptable practice, or could it cause problems (with the system, or in a future iOS version)? Is there a supported way to make iOS refresh a cached launch screen after an app update? If not, is the expected behaviour simply that the system refreshes the snapshot at some point? Is it documented when that happens (for example after a reboot, or after a certain time)? If clearing the folder isn't recommended, we won't ship it. Updating players would just keep the old launch screen until iOS refreshes it. Thanks!
1
0
167
15h
iOS 27b3 SDK: iOS App on Mac crashes on UISearchBar focus
Our app crashes when compiled with the iOS 27 beta 3 SDK and run as an iOS app on Mac, on both macOS 26 and macOS 27, as soon as a UISearchBar receives focus. The crash is due to this exception: *** Assertion failure in BOOL _screenBasedFocusUnsupported(void)(), UIScreen.m:3.725 Accessing the focus system through UIScreen is no longer supported. ( 0 CoreFoundation 0x000000018bea31c0 __exceptionPreprocess + 176 1 libobjc.A.dylib 0x000000018b91e91c objc_exception_throw + 88 2 Foundation 0x000000018e092644 -[NSMutableDictionary(NSMutableDictionary) initWithContentsOfFile:] + 0 3 UIKitCore 0x00000001c5dae8ec _screenBasedFocusUnsupported + 272 4 UIKitCore 0x00000001c5dae960 -[UIScreen _preferredFocusedWindow] + 24 5 UIKitCore 0x00000001c4ea3a60 -[UIScreen _mainSceneReferenceBounds] + 200 6 UIKitCore 0x00000001c4ea3914 -[UIScreen _mainSceneBoundsForInterfaceOrientation:] + 40 7 UIKitCore 0x00000001c5708134 +[UINavigationBar defaultSizeForOrientation:] + 76 8 UIKitCore 0x00000001c6222c88 -[_UISearchPresentationController _layoutPresentationWithSize:transitionCoordinator:] + 704 9 UIKitCore 0x00000001c622296c -[_UISearchPresentationController containerViewWillLayoutSubviews] + 84 10 UIKitCore 0x00000001c549304c block_destroy_helper.13 + 25112 11 UIKitCore 0x00000001c549344c block_destroy_helper.13 + 26136 12 UIKitCore 0x00000001c4ea26a8 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 1648 13 QuartzCore 0x0000000196103dbc _ZN2CA5Layer15perform_update_EPS0_P7CALayerjNS_17LayerUpdateReasonEPNS_11TransactionE + 460 14 QuartzCore 0x000000019610390c _ZN2CA5Layer17update_if_needed_EPNS_11TransactionENS_17LayerUpdateReasonE + 692 15 QuartzCore 0x0000000196035d2c _ZN2CA7Context18commit_transactionEPNS_11TransactionEdPd + 608 16 QuartzCore 0x0000000195e69520 _ZN2CA11Transaction6commitEv + 652 17 AppKit 0x0000000190fe116c __37+[NSDisplayCycle currentDisplayCycle]_block_invoke.7 + 44 18 CoreFoundation 0x000000018be34ad0 __CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ + 28 19 CoreFoundation 0x000000018be34a10 __CFRunLoopDoBlocks + 396 20 CoreFoundation 0x000000018be33e54 __CFRunLoopRun + 2356 21 CoreFoundation 0x000000018bf06234 _CFRunLoopRunSpecificWithOptions + 532 22 HIToolbox 0x0000000198c1f560 RunCurrentEventLoopInMode + 320 23 HIToolbox 0x0000000198c228bc ReceiveNextEventCommon + 488 24 HIToolbox 0x0000000198dac14c _BlockUntilNextEventMatchingListInMode + 48 25 AppKit 0x00000001909163d0 _DPSBlockUntilNextEventMatchingListInMode + 228 26 AppKit 0x000000019026a084 _DPSNextEvent + 576 27 AppKit 0x0000000190dff96c -[NSApplication(NSEventRouting) _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 688 28 AppKit 0x0000000190dff678 -[NSApplication(NSEventRouting) nextEventMatchingMask:untilDate:inMode:dequeue:] + 72 29 AppKit 0x000000019025d13c -[NSApplication run] + 368 30 AppKit 0x00000001902357b0 NSApplicationMain + 880 31 AppKit 0x000000019047c958 +[NSWindow _savedFrameFromString:] + 0 32 UIKitMacHelper 0x00000001aa2651bc UINSApplicationMain + 972 33 UIKitCore 0x00000001c4e1aed4 UIApplicationMain + 144 34 UIKitCore 0x00000001c548bda0 block_destroy_helper.31 + 8880 35 DigitalConcertHall.debug.dylib 0x0000000106e41bd8 $sSo21UIApplicationDelegateP5UIKitE4mainyyFZ + 128 36 DigitalConcertHall.debug.dylib 0x0000000106e41b4c $s18DigitalConcertHall11AppDelegateC5$mainyyFZ + 32 37 DigitalConcertHall.debug.dylib 0x0000000106e4afc0 __debug_main_executable_dylib_entry_point + 28 38 dyld 0x000000018b9ac4e4 start + 6992 ) I could not test with the iOS 27 beta 4 SDK due to this blocking issue: https://developer.apple.com/forums/thread/839012 However, when I tried to set up a simple sample project, I could not reproduce the issue. Does anybody know what might be causing this? I filed feedback FB24201508
7
2
1.8k
1d
HiraginoSans-W4/W5 availability diverges between iOS 16.5.1 and iOS 18.0.1: UIFont(name:) returns nil, XIB labels fall back to Helvetica
Background Our app previously bundled ヒラギノ角ゴシック W4.ttc and W5.ttc via UIAppFonts. App Store review flagged them under ITMS-91198 as Apple-provided fonts. We removed the bundled .ttc files and need to verify the runtime font-resolution behavior before shipping. Case C below shows the original state (with .ttc present) for comparison. Environment Same app, same code, same XIB, physical devices only. Tested OS: iOS 16.5.1 (two builds: with and without bundled .ttc) and iOS 18.0.1 (without bundled .ttc). Xcode 16.x. How to read the logs Each log has three sections: SYSTEM HIRAGINO SANS — UIFont.fontNames(forFamilyName: "Hiragino Sans"), i.e. what the OS itself provides. RAW UIFont(name:) — UIFont(name: "HiraginoSans-W4", size: 16) etc. This is the code path our App.Font wrapper uses. XIB LABEL RESOLVED — four UILabels whose XIB fontDescription specifies HiraginoSans-W3/W4/W5/W6 respectively. resolved= is label.font.fontName at runtime. Case A — iOS 18.0.1, physical device, bundled .ttc removed ===== ENV ===== systemVersion : 18.0.1 target : Physical Device ===== SYSTEM HIRAGINO SANS ===== HiraginoSans-W3 HiraginoSans-W4 HiraginoSans-W5 HiraginoSans-W6 HiraginoSans-W7 HiraginoSans-W8 ===== RAW UIFont(name:) ===== HiraginoSans-W3 OK family=Hiragino Sans HiraginoSans-W4 OK family=Hiragino Sans HiraginoSans-W5 OK family=Hiragino Sans HiraginoSans-W6 OK family=Hiragino Sans ===== XIB LABEL RESOLVED ===== W3Lab xib=HiraginoSans-W3 resolved=HiraginoSans-W3 family=Hiragino Sans W4Lab xib=HiraginoSans-W4 resolved=HiraginoSans-W4 family=Hiragino Sans W5Lab xib=HiraginoSans-W5 resolved=HiraginoSans-W5 family=Hiragino Sans W6Lab xib=HiraginoSans-W6 resolved=HiraginoSans-W6 family=Hiragino Sans ===== END =====Case B — iOS 16.5.1, physical device, bundled .ttc removed ===== ENV ===== systemVersion : 16.5.1 target : Physical Device ===== SYSTEM HIRAGINO SANS ===== HiraginoSans-W3 HiraginoSans-W6 HiraginoSans-W7 ===== RAW UIFont(name:) ===== HiraginoSans-W3 OK family=Hiragino Sans HiraginoSans-W4 nil HiraginoSans-W5 nil HiraginoSans-W6 OK family=Hiragino Sans ===== XIB LABEL RESOLVED ===== W3Lab xib=HiraginoSans-W3 resolved=HiraginoSans-W3 family=Hiragino Sans W4Lab xib=HiraginoSans-W4 resolved=Helvetica family=Helvetica W5Lab xib=HiraginoSans-W5 resolved=Helvetica family=Helvetica W6Lab xib=HiraginoSans-W6 resolved=HiraginoSans-W6 family=Hiragino Sans ===== END =====Case C — iOS 16.5.1, physical device, bundled .ttc present (original state) ===== ENV ===== systemVersion : 16.5.1 target : Physical Device ===== SYSTEM HIRAGINO SANS ===== HiraginoSans-W3 HiraginoSans-W4 HiraginoSans-W5 HiraginoSans-W6 HiraginoSans-W7 ===== RAW UIFont(name:) ===== HiraginoSans-W3 OK family=Hiragino Sans HiraginoSans-W4 OK family=Hiragino Sans HiraginoSans-W5 OK family=Hiragino Sans HiraginoSans-W6 OK family=Hiragino Sans ===== XIB LABEL RESOLVED ===== W3Lab xib=HiraginoSans-W3 resolved=HiraginoSans-W3 family=Hiragino Sans W4Lab xib=HiraginoSans-W4 resolved=HiraginoSans-W4 family=Hiragino Sans W5Lab xib=HiraginoSans-W5 resolved=HiraginoSans-W5 family=Hiragino Sans W6Lab xib=HiraginoSans-W6 resolved=HiraginoSans-W6 family=Hiragino Sans ===== END =====Observations Comparing B and C (same OS, only .ttc presence differs): removing the bundled .ttc removes HiraginoSans-W4/W5 from the system font list, makes UIFont(name:) return nil for them, and makes XIB labels naming them fall back to Helvetica — not SF, not the nearest weight in the same family. Comparing B and A (same .ttc state, only OS differs): iOS 18.0.1 ships HiraginoSans-W3–W8 in the system, so removing the bundled .ttc has no effect there. Question 1 — System font inventory by OS version Is there an official, versioned list of system-provided fonts (PostScript names) per iOS release? We need to determine which Hiragino Sans weights are available on a given OS at runtime, without hard-coding assumptions. Our observations show that iOS 16.5.1 does not provide HiraginoSans-W4/W5 in the system font set, while iOS 18.0.1 provides W3–W8. If no per-version official list exists, is UIFont.familyNames / UIFont.fontNames(forFamilyName:) the recommended runtime enumeration method? Or is there a documented recommendation to avoid relying on specific PostScript names across OS versions? Question 2 — XIB fontDescription fallback rule When a UILabel's XIB fontDescription specifies a font PostScript name that is not available at runtime (e.g. HiraginoSans-W4 on iOS 16.5.1 after removing the bundled .ttc), we observe UIKit falls back to Helvetica — not SF, not the nearest available weight in the same family. Is this fallback rule documented? Is it stable across iOS versions, or should we treat the fallback target as unspecified? If the fallback target cannot be relied upon, what is the recommended approach for XIB-based layouts that must not render with an unexpected font? Must every such label be re-assigned in code after awakeFromNib / viewDidLoad? Or is there a supported way to declare a fallback chain in Interface Builder?
0
0
45
2d
Is a scene always connected when a UIScene app is launched in the background (silent push, BGTask, background URLSession)?
Hello, We are migrating a large UIKit app from the app-delegate lifecycle to the UIScene lifecycle. (Building with Xcode 27 / iOS 27 SDK, our non-scene app crashes at launch with EXC_BREAKPOINT in _UIApplicationEvaluateRuntimeIssueForNoSceneLifecycleAdoption.) Our startup work runs from application(_:didFinishLaunchingWithOptions:), and we need to know what is guaranteed for background launches. Observed (iPhone 15 Pro, iOS 27.2, app built with Xcode 26.3; also iOS 17.5 simulator): Non-scene build, launched by a content-available push: launchOptions contained UIApplicationLaunchOptionsRemoteNotificationKey. applicationDidEnterBackground was not called during the background run. Non-scene build, launched by a BGProcessingTask: launchOptions empty. applicationDidEnterBackground was not called; the first lifecycle callback was applicationWillEnterForeground when the user opened the app 8 minutes later. Scene build, launched by a BGProcessingTask and by a content-available push: scene(_:willConnectTo:options:) was called 0.15-0.2 s after didFinishLaunching while applicationState == .background (activationState .unattached). connectionOptions had no notificationResponse, URL or shortcut item. In the push launch, scene(_:willConnectTo:options:) was called 37 ms before application(_:didReceiveRemoteNotification:fetchCompletionHandler:). sceneWillEnterForeground / sceneDidEnterBackground were not called before the process was suspended. Scene build, background URLSession relaunch (simulator): the scene also connected right after didFinishLaunching in the background, 6 ms before application(_:handleEventsForBackgroundURLSession:completionHandler:). Question: For a UIScene-based app that the system launches directly into the background (content-available push, BGTaskScheduler task, background URLSession events), is it guaranteed that UIKit connects a scene session (scene(_:willConnectTo:options:)) before the user opens the app, or can a background launch run with no connected scene until the app comes to the foreground? In the same launches, can sceneDidEnterBackground (or applicationDidEnterBackground in a non-scene app) be called for a process that never entered the foreground? Please point us to documentation that describes the guaranteed callbacks and their order for background launches. Thank you.
Topic: UI Frameworks SubTopic: UIKit
0
0
76
2d
Persistent scroll stutter on iPhone 17 Pro Max, 18 Pro Max and 18 Pro (iOS 27.2), also on Apple Store demo units
Affected devices (all show the same problem): 1x iPhone 17 Pro Max 2x iPhone 18 Pro Max 1x iPhone 18 Pro Many demo iPhones at several Apple Stores Current iOS version: 27.2 Issue: Vertical scrolling inside apps frequently stutters and drops frames. It happens in many, many apps, including Apple's own App Store and Apple Store apps. During a normal flick-and-decelerate scroll, the content repeatedly freezes for one or more frames and then jumps forward. Because this reproduces on four of my own devices and on many Apple Store demo units, I believe it is a widespread, system-level issue, not a defect of a single device or my settings. Impact: I have been living with this for more than six months. I use my iPhone heavily every day, and the constant stutter has made using it genuinely distressing. Everything else about iPhone feels excellent, which makes this problem even harder to accept. Steps to reproduce: Open the App Store app (or almost any app with a scrolling list). Scroll with a normal flick and let it decelerate. Observe repeated hitches during the scroll. Measurements: I filmed the screen with a second iPhone at 4K 120 fps and measured content movement frame by frame: iPhone 18 Pro Max, third-party video feed: about 4 hitches per second of scrolling, about 4% of frames dropped, mostly single-frame drops. iPhone 18 Pro Max, third-party social app list: about 11 hitches per second, about 12% of frames dropped, at a regular rhythm every 6-8 frames. About a third of the stalls last 2-3 frames, and the content does not catch up afterwards. iPhone 17 Pro Max, third-party comment list: about 5 hitches per second, about 8% of frames dropped, including several full freezes of 50-75 ms. Expected: Smooth 120 Hz scrolling, as ProMotion is designed to deliver. Is Apple aware of this issue? I am happy to provide videos, frame-by-frame data, or sysdiagnose logs.
3
1
191
3d
iPhone Duo: vanishing vertical toolbars; odd nav bar behavior.
Two things I've seen using the iPhone Duo simulator. I'm updating a venerable Objective-C app that dates back to iOS 4, but has been updated to be perfectly functional and appearance-appropriate on iOS 26. I'm building using the 21.1 beta SDK in Xcode 27.1 beta. TL;DR version: (1) my toolbar items vanish in vertical mode except while being tapped or dragged; and (2) the nav bar has an opaque, fixed background even as its title scrolls with underlying content. Has anyone else seen these oddities, and any ideas as to how I can fix 'em? First, with the Duo opened and taller than wide, the nav and tab bars in my app appear horizontally, as I would expect them to. But in any other pose or orientation, the bars adopt a vertical display, and aside from the left edge, their items are invisible: When I tap or drag on them, they become visible: When I stop tapping or dragging, they vanish again. Why do the vertical items go invisible, and how can I keep 'em always visible? Second, my scrolling view lies under the nav bar (in z-order) but extends to the top of the screen. If I scroll the view, it moves up onscreen, behind the opaque nav bar, although the nav bar's title scrolls up, too: If I go "far enough", the title scrolls off completely and the view's contents are visible full-height, but with the nav bar's background remaining. If I don't scroll that far, the title reappears when I stop, and the area above the nav bar goes opaque white, too, covering the content: Is it possible to disable the scrolling behavior on the nav bar title? (I'll just position my scrolling view to start below it spatially.) Alternatively, how can I turn off the background opacity? I've tried setting the background to clearColor and opacity to false... nav.navigationBar.backgroundColor = [UIColor clearColor]; nav.navigationBar.opaque = false; ...but these had no effect. Help me Obi-Wan Kenobi, you're my only hope...
Topic: UI Frameworks SubTopic: UIKit
8
0
1.7k
4d
iPhone Duo, Keyboard Events on Rotation?
In our app we're hiding and showing things based on whether the keyboard is on the screen or not so we're observing: UIResponder.keyboardWillShowNotification UIResponder.keyboardWillHideNotification And now that we've got hte iPhone Duo in house, I've been testing on there and noticed that those events are firing when the device is open and rotating? Is this by design? There's no keyboard on screen, but I'm receiving the events? This behavior is not showing on the other iPhone/iPad devices. To double-check I created a sample app and I'm seeing the same behavior 😔 enum KeyboardNotification { case willShow case didShow case willHide case didHide } extension KeyboardNotification: CustomStringConvertible { var description: String { switch self { case .willShow: "Will Show" case .didShow: "Did Show" case .willHide: "Will Hide" case .didHide: "Did Hide" } } } struct NotificationEntry { let notification: KeyboardNotification let date: Date init(_ notification: KeyboardNotification) { self.notification = notification self.date = Date() } } struct TestView: View { @State private var entries: [NotificationEntry] = [] private let dateFormatter: DateFormatter = { let formatter = DateFormatter() formatter.dateStyle = .short formatter.timeStyle = .short return formatter }() var body: some View { ZStack { if !entries.isEmpty { List { ForEach(entries, id: \.date) { entry in VStack(alignment: .leading) { Text(String(describing: entry.notification)) Text(dateFormatter.string(from: entry.date)) .font(.caption) .foregroundStyle(.gray) } } } } else { VStack(alignment: .leading) { Text("No Keyboard Events") Text("Rotate the device to test.") .font(.caption) .foregroundStyle(.gray) } } } .onReceive(NotificationCenter.default.publisher(for: UIResponder.keyboardWillShowNotification)) { _ in entries.append(NotificationEntry(.willShow)) } .onReceive(NotificationCenter.default.publisher(for: UIResponder.keyboardDidShowNotification)) { _ in entries.append(NotificationEntry(.didShow)) } .onReceive(NotificationCenter.default.publisher(for: UIResponder.keyboardWillHideNotification)) { _ in entries.append(NotificationEntry(.willHide)) } .onReceive(NotificationCenter.default.publisher(for: UIResponder.keyboardDidHideNotification)) { _ in entries.append(NotificationEntry(.didHide)) } } }In my test app, the events will not always fire but after messing with it for a little bit it will eventually get in the state where it the events fire. Sometimes I will additionally see them when bringing down the notification center, or slightly going to the app switcher.
0
0
101
4d
IOS 27 getting false response from isInterfaceOrientationLocked when autorotate is on
I have an app almost ready to submit for distribution. It is a game with a fixed background view and a token that moves around on the fixed background. The token is moved by tilting the iPhone/iPad which is translated to movement based on CMMotionManager as roll and pitch readings. This simulates a flat level playing field with gravity pulling the token when the device is tipped. The app works well only when the user has set the device to have Autorotate locked. The following code lets me sample the status of Autorate: guard let windowScene = UIApplication.shared.connectedScenes.first as? UIWindowScene else { return } print("Orientation locked: ", windowScene.effectiveGeometry.isInterfaceOrientationLocked) The problem is that I always get a reading of false regardless of whether Autorotate is locked or not. Can anyone help me understand. Is this the wrong approach for getting this information? If so, how is this achieved? Thanks for your attention to this, Mike Ricker
0
0
106
4d
UISheetPresentationController's per-detent backgroundEffect doesn't transition during interactive drags
I'm using the new per-detent backgroundEffect (iOS 26.1+) on UISheetPresentationControllerDetent. When the user drags the sheet between two detents with different effects, nothing changes during the drag; the previous detent's effect stays until the finger lifts, then a fixed-length cross-fade runs on its own, decoupled from the sheet's settle animation. It reads as a jump. Minimal setup (form sheet, nothing else): UISheetPresentationControllerDetent *medium = [UISheetPresentationControllerDetent mediumDetent]; UISheetPresentationControllerDetent *tall = [UISheetPresentationControllerDetent customDetentWithIdentifier:@"c90" resolver:^CGFloat(id<UISheetPresentationControllerDetentResolutionContext> ctx) { return ctx.maximumDetentValue * 0.9; }]; medium.backgroundEffect = nil; tall.backgroundEffect = [UIColorEffect effectWithColor:UIColor.systemBackgroundColor]; sheet.detents = @[ medium, tall ];Expected: the effect transition is driven by the drag progress between adjacent detents, or at least runs inside the same settle animation as the height change. Reproduces on iOS 26.5 (23F77) and 27.0 (24A434) Simulator with iPhone 17 Pro, iOS 27.1 (24A94401) Simulator with iPhone Duo. Xcode 27.1. Is this intended, and is there a supported way to tie the per-detent effect transition to the gesture? Filed as FB25459597.
Topic: UI Frameworks SubTopic: UIKit
0
1
47
5d
Inconsistent additionalOverflowItems layout behavior between iOS 18 and iOS 26
I am currently testing additionalOverflowItems with the expectation that it behaves as follows: Keep UIBarButtonItem instances visible directly on the toolbar as icons whenever there is sufficient space. Only move items into the overflow menu when there isn't enough screen real estate. In iOS 26, additionalOverflowItems behaves exactly as described above. However, in iOS 18, the system tends to aggressively move all UIBarButtonItem instances into the overflow menu regardless of available space. Is this change in layout behavior documented anywhere? Can we rely on iOS 26 and future releases maintaining this current behavior, or are the layout heuristics for additionalOverflowItems considered undefined implementation details? Because this behavior isn't clearly documented, I have held off on adopting additionalOverflowItems in production. I have attached screenshots and sample source code below for reference. // On iOS 26, the action mode bar buttons may not fit. iOS then moves the ones that do not fit into its own overflow // menu, listing each by title, and the more button's menu would become a nested "More" submenu there. Instead, in // note and archive action mode, the more button is not shown and its actions are added to the system overflow // menu directly. iOS shows that menu, and moves the buttons that do not fit into it, based on the available space. private var isActionModeMenuInOverflowMenu: Bool { guard #available(iOS 16, *) else { return false } guard actionMode else { return false } switch pageKind { case .notes, .archive: return true default: return false } } private func updateAdditionalOverflowItems() { guard #available(iOS 16, *) else { return } guard isActionModeMenuInOverflowMenu else { navigationItem.additionalOverflowItems = nil return } // Built when the menu is opened, so that it reflects the current selection. navigationItem.additionalOverflowItems = UIDeferredMenuElement.uncached { [weak self] completion in guard let self = self, self.isActionModeMenuInOverflowMenu else { completion([]) return } let selectedNSPlainNotes = self.selectedNSPlainNotes switch self.pageKind { case .notes: completion(self.generateNoteActionModeMenu(selectedNSPlainNotes).children) case .archive: completion(self.generateArchiveActionModeMenu(selectedNSPlainNotes).children) default: completion([]) } } }
Topic: UI Frameworks SubTopic: UIKit
0
0
64
5d
iPadOS: UITextField .phonePad popover does not reopen after dismissal while still first responder
I can reproduce a phone-keypad popover reopening issue in a standalone UIKit app, with no third-party frameworks or custom input view. Environment iPad Pro 11-inch (M4) simulator, iPadOS 26.5, landscape Xcode 27.1 Observed when UIKit presents the small telephone-keypad popover for a UITextField whose keyboardType is .phonePad. Device Hub's hardware/software keyboard settings affect whether this popover or the full-width keyboard appears. Reproduced both in a plain UIViewController inside UINavigationController and in a stock UISplitViewController. Physical-device behavior and other OS versions have not been verified. Steps Add a normal UITextField, set keyboardType = .phonePad, and call becomeFirstResponder() in viewDidAppear. With the small phone-keypad popover visible, tap blank space outside it to dismiss it. Tap the same text field again. Expected: The telephone-keypad popover reopens so the user can continue entering a phone number. Actual: The popover does not reopen. Sometimes an AutoFill edit menu appears instead. The text field still reports isFirstResponder == true. Calling becomeFirstResponder() again returns true but does not restore the keypad. The baseline has no UITextFieldDelegate, custom gesture recognizer, custom inputView, or automatic focus-recovery code. Diagnostic results in this environment Repeating becomeFirstResponder() while already first responder: returns true, keypad remains absent. Explicitly calling reloadInputViews(): keypad reappears. Explicitly calling resignFirstResponder(), then becomeFirstResponder() in a separate button action: keypad reappears. Recreating the view controller: keypad reappears. The attached animated screen recording shows initial presentation, dismissal, a failed retap, a responder-state snapshot, another becomeFirstResponder() call, and recovery after Reload inputs. The diagnostic buttons only perform the named action; no recovery runs automatically. Relevant setup/actions from the standalone app: private let phoneField = UITextField() // viewDidLoad: add phoneField to the view and set its constraints phoneField.keyboardType = .phonePad // viewDidAppear let result = phoneField.becomeFirstResponder() print(result, phoneField.isFirstResponder) // Diagnostic button A, after dismissing and retapping: let again = phoneField.becomeFirstResponder() print(again, phoneField.isFirstResponder) // true, true; keypad absent // Diagnostic button B: phoneField.reloadInputViews() // popover reappears in this testOne additional observation: keyboard hide notifications can be delivered even while the small telephone-keypad popover is visibly present. Therefore, the last keyboard notification/frame is not a reliable visibility signal for this popover in this test. Is this an expected distinction between the phone-keypad popover and the software keyboard, or a UIKit/Simulator issue? What is the recommended public-API approach to allow a user to reopen it after dismissal? In particular, is calling reloadInputViews() when the field is already first responder an appropriate workaround, and is there a supported way to detect this popover's dismissed state? I have not yet filed a Feedback Assistant report, so there is no FB number to reference. I can provide the standalone reproduction project if needed.
Topic: UI Frameworks SubTopic: UIKit Tags:
0
0
88
5d
iOS 27: FBSScene crashes in objc_release_x26 after a scene settings update
Feedback Assistant: FB25454822 On iOS 27, our app (com.netshort.abroad) crashes inside FrontBoardServices while releasing an object saved across a synchronous scene-update callout. The stack has only system frames. A build shipped in September 2025 (1.8.3) hits the same crash as soon as the device is updated to iOS 27, so this is not a recent app change. OS: iOS 27.0.0 (24A435), iOS 27.0.1 (24A446) On build 2.3.4: 1264 events, 1216 users 0 libobjc.A.dylib objc_release_x26 + 8 1 FrontBoardServices -[FBSScene updater:didUpdateSettings:withDiff:transitionContext:completion:] + 780 2 FrontBoardServices _queue_updateScene…_block_invoke_2.cold.1 + 352 3 FrontBoardServices _queue_updateScene…_block_invoke_2 + 96 4 FrontBoardServices _calloutQueue_executeCalloutFromSource:withBlock: + 168 On 27.0.0 these frames show as <redacted> in Crashlytics. FrontBoardServices 0x19a88 is this method at 0x1977c plus 780, matching symbolicated 27.0.1 reports. In the 27.0.1 FrontBoardServices binary, +776 is objc_release(x26) and +780 is the return address. x26 is transitionContext.actions. The callout into UIKit is the bl at +0x2ac. The crash happens after that callout returns. 34 Apple crash reports with register state show the same pattern: the low byte of saved x26 is 0x01. 20 reports: objc_release_x26 + 8, x26 = 0x1 14 reports: objc_release_x26 + 16, x26 ends in 0x01 (for example 0x13c373a01) A nil actions value 0x0 becomes 0x1. A real pointer only has its low byte changed, so the isa read is off by one. In the +16 reports, x16 (0x8001000001fa8d89) is that isa shifted by one byte. This looks like a one-byte store of YES into the stack slot where x26 was saved across the callout. There is no single user action that reproduces it. It happens when the system delivers a scene settings update. The frame that wrote the byte is already gone, because the crash is recorded after the callout returns. Has anyone else seen this on iOS 27? I attached three .crash files with full register state to FB25454822.
Topic: UI Frameworks SubTopic: UIKit
0
0
261
5d
Catalyst layout sizes unexpected
On a 16" M5 MBP running 26.7.2 I have the display set to "1496 x 967" in the display section of Settings.app; the native resolution of the LCD panel is 3456 wide per the "System Information" report. When I inspect DOM nodes in a full screen width browser window, nodes which span the width of the screen show the expected 1496 CSS pixel width. However, when I run a Mac Catalyst app in Xcode, with its window at full screen width, and I inspect the bounds property of a UIView with the full width of the window, it reports its width as 1943 points wide, which doesn't match the value I expect (1496, same as FF sees) or the 'native point-resolution' of the display at 2x (1728 points). Furthermore, the nativeScale property of the UIWindow is 2, which combined with the point width contradicts the actual resolution of the LCD (i.e. 2*1943 != 3456.) I've looked for documentation but haven't found any. Where is 1943 point width coming from and why is the nativeScale 2? I was expecting 1496 and 1496/3456.
2
0
361
5d
iOS 27: app is not made inactive while the ATT prompt (or other permission alerts) is shown (FB25446786)
Since iOS 27, showing a system permission alert no longer deactivates the app. On iOS 26, sceneWillResignActive / applicationWillResignActive arrive about 0.05–0.1 s after ATTrackingManager.requestTrackingAuthorization. On iOS 27.0, 27.0.1 and 27.2 they don't arrive at all while the prompt is up, and SwiftUI's scenePhase stays .active. Apps that pause on resign, like games (Unity's iOS player pauses only on applicationWillResignActive), keep running behind the prompt: tutorials start, and timers and audio keep going. Minimal repro (plain UIKit with UIScene, fresh install so the status is .notDetermined): private var askedForTracking = false func sceneDidBecomeActive(_ scene: UIScene) { print("sceneDidBecomeActive") guard !askedForTracking else { return } askedForTracking = true DispatchQueue.main.asyncAfter(deadline: .now() + 3) { print("requesting ATT") ATTrackingManager.requestTrackingAuthorization { status in print("ATT finished: \(status.rawValue)") } } } func sceneWillResignActive(_ scene: UIScene) { print("sceneWillResignActive") }iOS 26.6: 3.27s requesting ATT 3.35s willResignActive 16.81s ATT finished: authorized 17.24s didBecomeActiveiOS 27.2: 3.21s requesting ATT 16.88s ATT finished: authorized 17.32s willResignActive 17.33s didBecomeActiveSo on iOS 27 the only lifecycle events are a resign/active pair about 0.44 s after the answer. What we found: The camera and notification permission alerts behave the same. It doesn't depend on the SDK the app is linked against, or on the thread making the request. SpringBoard's log shows the systemModalAlert deactivation assertion being added, but on iOS 27 the updateAllScenesForBand - Assertion added update never reaches the app's scene. The pending reason is only applied on the next unrelated scene update, such as a notification banner arriving, the screen dimming, an unlock, or the alert being dismissed. Taps outside the alert, a Control Center swipe or a home-indicator drag don't trigger it. Filed as FB25446786, with a sample project, delay sweeps on iOS 26 vs 27 (simulator and device) and a sysdiagnose. Is anyone else seeing this? And is there a supported way to know a permission alert is on screen until it's fixed? If you're affected, please file a Feedback and mention FB25446786; duplicates help.
0
0
57
5d
Issue: Screen rotation becomes locked when updating the status bar on an iPhone Duo.
Issue: Screen rotation becomes locked when updating the status bar on an iPhone Duo. This does not appear to be a device-specific hardware issue; however, it occurs specifically on the iPhone Duo. In my app, if I change the status bar visibility (using prefersStatusBarHidden) while on the iPhone Duo’s external screen, and then immediately unfold the device to reveal the internal screen, the app’s rotation state becomes locked. Although I use prefersInterfaceOrientationLocked to manage rotation, the app remains locked even when this property returns false. The issue persists even when prefersInterfaceOrientationLocked is commented out or removed entirely. Returning to the device’s home screen, rotating the device, and then re-entering the app resolves the lock. Has anyone encountered or resolved a similar issue?
0
0
66
5d
How to get UIInputView to appear with same height as standard keyboard?
I'm creating a custom keyboard by subclassing UIInputView. This is set as a text field's inputView property. This is a simple keypad similar to the standard numeric keypad keyboard. In fact, my UI lets the user switch between the standard numeric keypad and my custom input view. Given this it would be very nice if my custom input view was the same height as the standard keypad. If there a proper way to subclass UIInputView such that its height is the same "standard" height as the numeric keypad when run on any iOS device from iOS 17 through 27.3? I do not want to have to hardcode dozens of heights for every model iPhone and iPad, not to mention the 5 different heights you get on the iPhone Duo. I've tried various combinations of setting allowsSelfSizing to true and false along with returning a height of UIView.noIntrinsicMetric in intrinsicContentSize as well as not setting intrinsicContentSize at all. The closest result is when allowsSelfSizing is set to false. In that case my custom input view's height is somewhat similar to the standard keypad but in some cases it's off by 20-30 points roughly. Has anyone implemented a custom UIInputView that gets the standard keyboard height without hardcoding device specific heights?
0
1
93
6d
UINavigationController, Nav Bar does not extend to top on iPhone Duo
When using a background color for a UINavigation controller it seems the header does not extend to the top of the device for iPhone Duo when its closed in portrait mode. See screenshot. It should fill the entire 'status' bar up to top of device, Landscape correctly works, its just Portrait. Any thoughts on if this is 'expected' behavior? Seems odd to not just extend the navbar alll the way to the top.
Topic: UI Frameworks SubTopic: UIKit Tags:
6
2
936
6d
Launch screen not refreshed after app update: is clearing Library/SplashBoard supported?
We're adding an option to our Unity SDK that gives a game a native launch screen: a launch storyboard (set through UILaunchStoryboardName) showing a full-screen image from an asset catalog. What we see On a clean install, the new launch screen shows as expected. When the same device installs an update over the existing app (tested through TestFlight), the previous launch screen keeps showing. Launching the app several times does not change it. Deleting the app, restarting the device and reinstalling shows the new launch screen straight away. We checked the build itself: the compiled storyboard, the image in Assets.car and the Info.plist keys are all correct, so this looks like the system's launch screen snapshot cache. We assume App Store updates behave the same way. What we're considering On the first launch after an update, the app would delete the cached launch screen snapshots in its own container (Library/SplashBoard), so the system regenerates them and the new launch screen shows on the next launch. This only uses public file APIs inside the app's own sandbox. But Library/SplashBoard is not documented anywhere, so we'd rather ask before shipping it. Questions Is deleting Library/SplashBoard from the app's own container a supported or acceptable practice, or could it cause problems (with the system, or in a future iOS version)? Is there a supported way to make iOS refresh a cached launch screen after an app update? If not, is the expected behaviour simply that the system refreshes the snapshot at some point? Is it documented when that happens (for example after a reboot, or after a certain time)? If clearing the folder isn't recommended, we won't ship it. Updating players would just keep the old launch screen until iOS refreshes it. Thanks!
Replies
1
Boosts
0
Views
167
Activity
15h
iOS 27b3 SDK: iOS App on Mac crashes on UISearchBar focus
Our app crashes when compiled with the iOS 27 beta 3 SDK and run as an iOS app on Mac, on both macOS 26 and macOS 27, as soon as a UISearchBar receives focus. The crash is due to this exception: *** Assertion failure in BOOL _screenBasedFocusUnsupported(void)(), UIScreen.m:3.725 Accessing the focus system through UIScreen is no longer supported. ( 0 CoreFoundation 0x000000018bea31c0 __exceptionPreprocess + 176 1 libobjc.A.dylib 0x000000018b91e91c objc_exception_throw + 88 2 Foundation 0x000000018e092644 -[NSMutableDictionary(NSMutableDictionary) initWithContentsOfFile:] + 0 3 UIKitCore 0x00000001c5dae8ec _screenBasedFocusUnsupported + 272 4 UIKitCore 0x00000001c5dae960 -[UIScreen _preferredFocusedWindow] + 24 5 UIKitCore 0x00000001c4ea3a60 -[UIScreen _mainSceneReferenceBounds] + 200 6 UIKitCore 0x00000001c4ea3914 -[UIScreen _mainSceneBoundsForInterfaceOrientation:] + 40 7 UIKitCore 0x00000001c5708134 +[UINavigationBar defaultSizeForOrientation:] + 76 8 UIKitCore 0x00000001c6222c88 -[_UISearchPresentationController _layoutPresentationWithSize:transitionCoordinator:] + 704 9 UIKitCore 0x00000001c622296c -[_UISearchPresentationController containerViewWillLayoutSubviews] + 84 10 UIKitCore 0x00000001c549304c block_destroy_helper.13 + 25112 11 UIKitCore 0x00000001c549344c block_destroy_helper.13 + 26136 12 UIKitCore 0x00000001c4ea26a8 -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 1648 13 QuartzCore 0x0000000196103dbc _ZN2CA5Layer15perform_update_EPS0_P7CALayerjNS_17LayerUpdateReasonEPNS_11TransactionE + 460 14 QuartzCore 0x000000019610390c _ZN2CA5Layer17update_if_needed_EPNS_11TransactionENS_17LayerUpdateReasonE + 692 15 QuartzCore 0x0000000196035d2c _ZN2CA7Context18commit_transactionEPNS_11TransactionEdPd + 608 16 QuartzCore 0x0000000195e69520 _ZN2CA11Transaction6commitEv + 652 17 AppKit 0x0000000190fe116c __37+[NSDisplayCycle currentDisplayCycle]_block_invoke.7 + 44 18 CoreFoundation 0x000000018be34ad0 __CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ + 28 19 CoreFoundation 0x000000018be34a10 __CFRunLoopDoBlocks + 396 20 CoreFoundation 0x000000018be33e54 __CFRunLoopRun + 2356 21 CoreFoundation 0x000000018bf06234 _CFRunLoopRunSpecificWithOptions + 532 22 HIToolbox 0x0000000198c1f560 RunCurrentEventLoopInMode + 320 23 HIToolbox 0x0000000198c228bc ReceiveNextEventCommon + 488 24 HIToolbox 0x0000000198dac14c _BlockUntilNextEventMatchingListInMode + 48 25 AppKit 0x00000001909163d0 _DPSBlockUntilNextEventMatchingListInMode + 228 26 AppKit 0x000000019026a084 _DPSNextEvent + 576 27 AppKit 0x0000000190dff96c -[NSApplication(NSEventRouting) _nextEventMatchingEventMask:untilDate:inMode:dequeue:] + 688 28 AppKit 0x0000000190dff678 -[NSApplication(NSEventRouting) nextEventMatchingMask:untilDate:inMode:dequeue:] + 72 29 AppKit 0x000000019025d13c -[NSApplication run] + 368 30 AppKit 0x00000001902357b0 NSApplicationMain + 880 31 AppKit 0x000000019047c958 +[NSWindow _savedFrameFromString:] + 0 32 UIKitMacHelper 0x00000001aa2651bc UINSApplicationMain + 972 33 UIKitCore 0x00000001c4e1aed4 UIApplicationMain + 144 34 UIKitCore 0x00000001c548bda0 block_destroy_helper.31 + 8880 35 DigitalConcertHall.debug.dylib 0x0000000106e41bd8 $sSo21UIApplicationDelegateP5UIKitE4mainyyFZ + 128 36 DigitalConcertHall.debug.dylib 0x0000000106e41b4c $s18DigitalConcertHall11AppDelegateC5$mainyyFZ + 32 37 DigitalConcertHall.debug.dylib 0x0000000106e4afc0 __debug_main_executable_dylib_entry_point + 28 38 dyld 0x000000018b9ac4e4 start + 6992 ) I could not test with the iOS 27 beta 4 SDK due to this blocking issue: https://developer.apple.com/forums/thread/839012 However, when I tried to set up a simple sample project, I could not reproduce the issue. Does anybody know what might be causing this? I filed feedback FB24201508
Replies
7
Boosts
2
Views
1.8k
Activity
1d
HiraginoSans-W4/W5 availability diverges between iOS 16.5.1 and iOS 18.0.1: UIFont(name:) returns nil, XIB labels fall back to Helvetica
Background Our app previously bundled ヒラギノ角ゴシック W4.ttc and W5.ttc via UIAppFonts. App Store review flagged them under ITMS-91198 as Apple-provided fonts. We removed the bundled .ttc files and need to verify the runtime font-resolution behavior before shipping. Case C below shows the original state (with .ttc present) for comparison. Environment Same app, same code, same XIB, physical devices only. Tested OS: iOS 16.5.1 (two builds: with and without bundled .ttc) and iOS 18.0.1 (without bundled .ttc). Xcode 16.x. How to read the logs Each log has three sections: SYSTEM HIRAGINO SANS — UIFont.fontNames(forFamilyName: "Hiragino Sans"), i.e. what the OS itself provides. RAW UIFont(name:) — UIFont(name: "HiraginoSans-W4", size: 16) etc. This is the code path our App.Font wrapper uses. XIB LABEL RESOLVED — four UILabels whose XIB fontDescription specifies HiraginoSans-W3/W4/W5/W6 respectively. resolved= is label.font.fontName at runtime. Case A — iOS 18.0.1, physical device, bundled .ttc removed ===== ENV ===== systemVersion : 18.0.1 target : Physical Device ===== SYSTEM HIRAGINO SANS ===== HiraginoSans-W3 HiraginoSans-W4 HiraginoSans-W5 HiraginoSans-W6 HiraginoSans-W7 HiraginoSans-W8 ===== RAW UIFont(name:) ===== HiraginoSans-W3 OK family=Hiragino Sans HiraginoSans-W4 OK family=Hiragino Sans HiraginoSans-W5 OK family=Hiragino Sans HiraginoSans-W6 OK family=Hiragino Sans ===== XIB LABEL RESOLVED ===== W3Lab xib=HiraginoSans-W3 resolved=HiraginoSans-W3 family=Hiragino Sans W4Lab xib=HiraginoSans-W4 resolved=HiraginoSans-W4 family=Hiragino Sans W5Lab xib=HiraginoSans-W5 resolved=HiraginoSans-W5 family=Hiragino Sans W6Lab xib=HiraginoSans-W6 resolved=HiraginoSans-W6 family=Hiragino Sans ===== END =====Case B — iOS 16.5.1, physical device, bundled .ttc removed ===== ENV ===== systemVersion : 16.5.1 target : Physical Device ===== SYSTEM HIRAGINO SANS ===== HiraginoSans-W3 HiraginoSans-W6 HiraginoSans-W7 ===== RAW UIFont(name:) ===== HiraginoSans-W3 OK family=Hiragino Sans HiraginoSans-W4 nil HiraginoSans-W5 nil HiraginoSans-W6 OK family=Hiragino Sans ===== XIB LABEL RESOLVED ===== W3Lab xib=HiraginoSans-W3 resolved=HiraginoSans-W3 family=Hiragino Sans W4Lab xib=HiraginoSans-W4 resolved=Helvetica family=Helvetica W5Lab xib=HiraginoSans-W5 resolved=Helvetica family=Helvetica W6Lab xib=HiraginoSans-W6 resolved=HiraginoSans-W6 family=Hiragino Sans ===== END =====Case C — iOS 16.5.1, physical device, bundled .ttc present (original state) ===== ENV ===== systemVersion : 16.5.1 target : Physical Device ===== SYSTEM HIRAGINO SANS ===== HiraginoSans-W3 HiraginoSans-W4 HiraginoSans-W5 HiraginoSans-W6 HiraginoSans-W7 ===== RAW UIFont(name:) ===== HiraginoSans-W3 OK family=Hiragino Sans HiraginoSans-W4 OK family=Hiragino Sans HiraginoSans-W5 OK family=Hiragino Sans HiraginoSans-W6 OK family=Hiragino Sans ===== XIB LABEL RESOLVED ===== W3Lab xib=HiraginoSans-W3 resolved=HiraginoSans-W3 family=Hiragino Sans W4Lab xib=HiraginoSans-W4 resolved=HiraginoSans-W4 family=Hiragino Sans W5Lab xib=HiraginoSans-W5 resolved=HiraginoSans-W5 family=Hiragino Sans W6Lab xib=HiraginoSans-W6 resolved=HiraginoSans-W6 family=Hiragino Sans ===== END =====Observations Comparing B and C (same OS, only .ttc presence differs): removing the bundled .ttc removes HiraginoSans-W4/W5 from the system font list, makes UIFont(name:) return nil for them, and makes XIB labels naming them fall back to Helvetica — not SF, not the nearest weight in the same family. Comparing B and A (same .ttc state, only OS differs): iOS 18.0.1 ships HiraginoSans-W3–W8 in the system, so removing the bundled .ttc has no effect there. Question 1 — System font inventory by OS version Is there an official, versioned list of system-provided fonts (PostScript names) per iOS release? We need to determine which Hiragino Sans weights are available on a given OS at runtime, without hard-coding assumptions. Our observations show that iOS 16.5.1 does not provide HiraginoSans-W4/W5 in the system font set, while iOS 18.0.1 provides W3–W8. If no per-version official list exists, is UIFont.familyNames / UIFont.fontNames(forFamilyName:) the recommended runtime enumeration method? Or is there a documented recommendation to avoid relying on specific PostScript names across OS versions? Question 2 — XIB fontDescription fallback rule When a UILabel's XIB fontDescription specifies a font PostScript name that is not available at runtime (e.g. HiraginoSans-W4 on iOS 16.5.1 after removing the bundled .ttc), we observe UIKit falls back to Helvetica — not SF, not the nearest available weight in the same family. Is this fallback rule documented? Is it stable across iOS versions, or should we treat the fallback target as unspecified? If the fallback target cannot be relied upon, what is the recommended approach for XIB-based layouts that must not render with an unexpected font? Must every such label be re-assigned in code after awakeFromNib / viewDidLoad? Or is there a supported way to declare a fallback chain in Interface Builder?
Replies
0
Boosts
0
Views
45
Activity
2d
Is a scene always connected when a UIScene app is launched in the background (silent push, BGTask, background URLSession)?
Hello, We are migrating a large UIKit app from the app-delegate lifecycle to the UIScene lifecycle. (Building with Xcode 27 / iOS 27 SDK, our non-scene app crashes at launch with EXC_BREAKPOINT in _UIApplicationEvaluateRuntimeIssueForNoSceneLifecycleAdoption.) Our startup work runs from application(_:didFinishLaunchingWithOptions:), and we need to know what is guaranteed for background launches. Observed (iPhone 15 Pro, iOS 27.2, app built with Xcode 26.3; also iOS 17.5 simulator): Non-scene build, launched by a content-available push: launchOptions contained UIApplicationLaunchOptionsRemoteNotificationKey. applicationDidEnterBackground was not called during the background run. Non-scene build, launched by a BGProcessingTask: launchOptions empty. applicationDidEnterBackground was not called; the first lifecycle callback was applicationWillEnterForeground when the user opened the app 8 minutes later. Scene build, launched by a BGProcessingTask and by a content-available push: scene(_:willConnectTo:options:) was called 0.15-0.2 s after didFinishLaunching while applicationState == .background (activationState .unattached). connectionOptions had no notificationResponse, URL or shortcut item. In the push launch, scene(_:willConnectTo:options:) was called 37 ms before application(_:didReceiveRemoteNotification:fetchCompletionHandler:). sceneWillEnterForeground / sceneDidEnterBackground were not called before the process was suspended. Scene build, background URLSession relaunch (simulator): the scene also connected right after didFinishLaunching in the background, 6 ms before application(_:handleEventsForBackgroundURLSession:completionHandler:). Question: For a UIScene-based app that the system launches directly into the background (content-available push, BGTaskScheduler task, background URLSession events), is it guaranteed that UIKit connects a scene session (scene(_:willConnectTo:options:)) before the user opens the app, or can a background launch run with no connected scene until the app comes to the foreground? In the same launches, can sceneDidEnterBackground (or applicationDidEnterBackground in a non-scene app) be called for a process that never entered the foreground? Please point us to documentation that describes the guaranteed callbacks and their order for background launches. Thank you.
Topic: UI Frameworks SubTopic: UIKit
Replies
0
Boosts
0
Views
76
Activity
2d
Persistent scroll stutter on iPhone 17 Pro Max, 18 Pro Max and 18 Pro (iOS 27.2), also on Apple Store demo units
Affected devices (all show the same problem): 1x iPhone 17 Pro Max 2x iPhone 18 Pro Max 1x iPhone 18 Pro Many demo iPhones at several Apple Stores Current iOS version: 27.2 Issue: Vertical scrolling inside apps frequently stutters and drops frames. It happens in many, many apps, including Apple's own App Store and Apple Store apps. During a normal flick-and-decelerate scroll, the content repeatedly freezes for one or more frames and then jumps forward. Because this reproduces on four of my own devices and on many Apple Store demo units, I believe it is a widespread, system-level issue, not a defect of a single device or my settings. Impact: I have been living with this for more than six months. I use my iPhone heavily every day, and the constant stutter has made using it genuinely distressing. Everything else about iPhone feels excellent, which makes this problem even harder to accept. Steps to reproduce: Open the App Store app (or almost any app with a scrolling list). Scroll with a normal flick and let it decelerate. Observe repeated hitches during the scroll. Measurements: I filmed the screen with a second iPhone at 4K 120 fps and measured content movement frame by frame: iPhone 18 Pro Max, third-party video feed: about 4 hitches per second of scrolling, about 4% of frames dropped, mostly single-frame drops. iPhone 18 Pro Max, third-party social app list: about 11 hitches per second, about 12% of frames dropped, at a regular rhythm every 6-8 frames. About a third of the stalls last 2-3 frames, and the content does not catch up afterwards. iPhone 17 Pro Max, third-party comment list: about 5 hitches per second, about 8% of frames dropped, including several full freezes of 50-75 ms. Expected: Smooth 120 Hz scrolling, as ProMotion is designed to deliver. Is Apple aware of this issue? I am happy to provide videos, frame-by-frame data, or sysdiagnose logs.
Replies
3
Boosts
1
Views
191
Activity
3d
iPhone Duo: vanishing vertical toolbars; odd nav bar behavior.
Two things I've seen using the iPhone Duo simulator. I'm updating a venerable Objective-C app that dates back to iOS 4, but has been updated to be perfectly functional and appearance-appropriate on iOS 26. I'm building using the 21.1 beta SDK in Xcode 27.1 beta. TL;DR version: (1) my toolbar items vanish in vertical mode except while being tapped or dragged; and (2) the nav bar has an opaque, fixed background even as its title scrolls with underlying content. Has anyone else seen these oddities, and any ideas as to how I can fix 'em? First, with the Duo opened and taller than wide, the nav and tab bars in my app appear horizontally, as I would expect them to. But in any other pose or orientation, the bars adopt a vertical display, and aside from the left edge, their items are invisible: When I tap or drag on them, they become visible: When I stop tapping or dragging, they vanish again. Why do the vertical items go invisible, and how can I keep 'em always visible? Second, my scrolling view lies under the nav bar (in z-order) but extends to the top of the screen. If I scroll the view, it moves up onscreen, behind the opaque nav bar, although the nav bar's title scrolls up, too: If I go "far enough", the title scrolls off completely and the view's contents are visible full-height, but with the nav bar's background remaining. If I don't scroll that far, the title reappears when I stop, and the area above the nav bar goes opaque white, too, covering the content: Is it possible to disable the scrolling behavior on the nav bar title? (I'll just position my scrolling view to start below it spatially.) Alternatively, how can I turn off the background opacity? I've tried setting the background to clearColor and opacity to false... nav.navigationBar.backgroundColor = [UIColor clearColor]; nav.navigationBar.opaque = false; ...but these had no effect. Help me Obi-Wan Kenobi, you're my only hope...
Topic: UI Frameworks SubTopic: UIKit
Replies
8
Boosts
0
Views
1.7k
Activity
4d
iPhone Duo, Keyboard Events on Rotation?
In our app we're hiding and showing things based on whether the keyboard is on the screen or not so we're observing: UIResponder.keyboardWillShowNotification UIResponder.keyboardWillHideNotification And now that we've got hte iPhone Duo in house, I've been testing on there and noticed that those events are firing when the device is open and rotating? Is this by design? There's no keyboard on screen, but I'm receiving the events? This behavior is not showing on the other iPhone/iPad devices. To double-check I created a sample app and I'm seeing the same behavior 😔 enum KeyboardNotification { case willShow case didShow case willHide case didHide } extension KeyboardNotification: CustomStringConvertible { var description: String { switch self { case .willShow: "Will Show" case .didShow: "Did Show" case .willHide: "Will Hide" case .didHide: "Did Hide" } } } struct NotificationEntry { let notification: KeyboardNotification let date: Date init(_ notification: KeyboardNotification) { self.notification = notification self.date = Date() } } struct TestView: View { @State private var entries: [NotificationEntry] = [] private let dateFormatter: DateFormatter = { let formatter = DateFormatter() formatter.dateStyle = .short formatter.timeStyle = .short return formatter }() var body: some View { ZStack { if !entries.isEmpty { List { ForEach(entries, id: \.date) { entry in VStack(alignment: .leading) { Text(String(describing: entry.notification)) Text(dateFormatter.string(from: entry.date)) .font(.caption) .foregroundStyle(.gray) } } } } else { VStack(alignment: .leading) { Text("No Keyboard Events") Text("Rotate the device to test.") .font(.caption) .foregroundStyle(.gray) } } } .onReceive(NotificationCenter.default.publisher(for: UIResponder.keyboardWillShowNotification)) { _ in entries.append(NotificationEntry(.willShow)) } .onReceive(NotificationCenter.default.publisher(for: UIResponder.keyboardDidShowNotification)) { _ in entries.append(NotificationEntry(.didShow)) } .onReceive(NotificationCenter.default.publisher(for: UIResponder.keyboardWillHideNotification)) { _ in entries.append(NotificationEntry(.willHide)) } .onReceive(NotificationCenter.default.publisher(for: UIResponder.keyboardDidHideNotification)) { _ in entries.append(NotificationEntry(.didHide)) } } }In my test app, the events will not always fire but after messing with it for a little bit it will eventually get in the state where it the events fire. Sometimes I will additionally see them when bringing down the notification center, or slightly going to the app switcher.
Replies
0
Boosts
0
Views
101
Activity
4d
IOS 27 getting false response from isInterfaceOrientationLocked when autorotate is on
I have an app almost ready to submit for distribution. It is a game with a fixed background view and a token that moves around on the fixed background. The token is moved by tilting the iPhone/iPad which is translated to movement based on CMMotionManager as roll and pitch readings. This simulates a flat level playing field with gravity pulling the token when the device is tipped. The app works well only when the user has set the device to have Autorotate locked. The following code lets me sample the status of Autorate: guard let windowScene = UIApplication.shared.connectedScenes.first as? UIWindowScene else { return } print("Orientation locked: ", windowScene.effectiveGeometry.isInterfaceOrientationLocked) The problem is that I always get a reading of false regardless of whether Autorotate is locked or not. Can anyone help me understand. Is this the wrong approach for getting this information? If so, how is this achieved? Thanks for your attention to this, Mike Ricker
Replies
0
Boosts
0
Views
106
Activity
4d
Using SF Symbols with a changed global locale
When changing the global locale by std::locale::global(std::locale(NAME)) where NAME is a valid and supported name of a locale all access using [UIImage systemImageNamed:@"..."] fails. Is there a way to modify the global locale and still have access to the SF Symbols?
Replies
0
Boosts
0
Views
90
Activity
4d
UISheetPresentationController's per-detent backgroundEffect doesn't transition during interactive drags
I'm using the new per-detent backgroundEffect (iOS 26.1+) on UISheetPresentationControllerDetent. When the user drags the sheet between two detents with different effects, nothing changes during the drag; the previous detent's effect stays until the finger lifts, then a fixed-length cross-fade runs on its own, decoupled from the sheet's settle animation. It reads as a jump. Minimal setup (form sheet, nothing else): UISheetPresentationControllerDetent *medium = [UISheetPresentationControllerDetent mediumDetent]; UISheetPresentationControllerDetent *tall = [UISheetPresentationControllerDetent customDetentWithIdentifier:@"c90" resolver:^CGFloat(id<UISheetPresentationControllerDetentResolutionContext> ctx) { return ctx.maximumDetentValue * 0.9; }]; medium.backgroundEffect = nil; tall.backgroundEffect = [UIColorEffect effectWithColor:UIColor.systemBackgroundColor]; sheet.detents = @[ medium, tall ];Expected: the effect transition is driven by the drag progress between adjacent detents, or at least runs inside the same settle animation as the height change. Reproduces on iOS 26.5 (23F77) and 27.0 (24A434) Simulator with iPhone 17 Pro, iOS 27.1 (24A94401) Simulator with iPhone Duo. Xcode 27.1. Is this intended, and is there a supported way to tie the per-detent effect transition to the gesture? Filed as FB25459597.
Topic: UI Frameworks SubTopic: UIKit
Replies
0
Boosts
1
Views
47
Activity
5d
Inconsistent additionalOverflowItems layout behavior between iOS 18 and iOS 26
I am currently testing additionalOverflowItems with the expectation that it behaves as follows: Keep UIBarButtonItem instances visible directly on the toolbar as icons whenever there is sufficient space. Only move items into the overflow menu when there isn't enough screen real estate. In iOS 26, additionalOverflowItems behaves exactly as described above. However, in iOS 18, the system tends to aggressively move all UIBarButtonItem instances into the overflow menu regardless of available space. Is this change in layout behavior documented anywhere? Can we rely on iOS 26 and future releases maintaining this current behavior, or are the layout heuristics for additionalOverflowItems considered undefined implementation details? Because this behavior isn't clearly documented, I have held off on adopting additionalOverflowItems in production. I have attached screenshots and sample source code below for reference. // On iOS 26, the action mode bar buttons may not fit. iOS then moves the ones that do not fit into its own overflow // menu, listing each by title, and the more button's menu would become a nested "More" submenu there. Instead, in // note and archive action mode, the more button is not shown and its actions are added to the system overflow // menu directly. iOS shows that menu, and moves the buttons that do not fit into it, based on the available space. private var isActionModeMenuInOverflowMenu: Bool { guard #available(iOS 16, *) else { return false } guard actionMode else { return false } switch pageKind { case .notes, .archive: return true default: return false } } private func updateAdditionalOverflowItems() { guard #available(iOS 16, *) else { return } guard isActionModeMenuInOverflowMenu else { navigationItem.additionalOverflowItems = nil return } // Built when the menu is opened, so that it reflects the current selection. navigationItem.additionalOverflowItems = UIDeferredMenuElement.uncached { [weak self] completion in guard let self = self, self.isActionModeMenuInOverflowMenu else { completion([]) return } let selectedNSPlainNotes = self.selectedNSPlainNotes switch self.pageKind { case .notes: completion(self.generateNoteActionModeMenu(selectedNSPlainNotes).children) case .archive: completion(self.generateArchiveActionModeMenu(selectedNSPlainNotes).children) default: completion([]) } } }
Topic: UI Frameworks SubTopic: UIKit
Replies
0
Boosts
0
Views
64
Activity
5d
iPadOS: UITextField .phonePad popover does not reopen after dismissal while still first responder
I can reproduce a phone-keypad popover reopening issue in a standalone UIKit app, with no third-party frameworks or custom input view. Environment iPad Pro 11-inch (M4) simulator, iPadOS 26.5, landscape Xcode 27.1 Observed when UIKit presents the small telephone-keypad popover for a UITextField whose keyboardType is .phonePad. Device Hub's hardware/software keyboard settings affect whether this popover or the full-width keyboard appears. Reproduced both in a plain UIViewController inside UINavigationController and in a stock UISplitViewController. Physical-device behavior and other OS versions have not been verified. Steps Add a normal UITextField, set keyboardType = .phonePad, and call becomeFirstResponder() in viewDidAppear. With the small phone-keypad popover visible, tap blank space outside it to dismiss it. Tap the same text field again. Expected: The telephone-keypad popover reopens so the user can continue entering a phone number. Actual: The popover does not reopen. Sometimes an AutoFill edit menu appears instead. The text field still reports isFirstResponder == true. Calling becomeFirstResponder() again returns true but does not restore the keypad. The baseline has no UITextFieldDelegate, custom gesture recognizer, custom inputView, or automatic focus-recovery code. Diagnostic results in this environment Repeating becomeFirstResponder() while already first responder: returns true, keypad remains absent. Explicitly calling reloadInputViews(): keypad reappears. Explicitly calling resignFirstResponder(), then becomeFirstResponder() in a separate button action: keypad reappears. Recreating the view controller: keypad reappears. The attached animated screen recording shows initial presentation, dismissal, a failed retap, a responder-state snapshot, another becomeFirstResponder() call, and recovery after Reload inputs. The diagnostic buttons only perform the named action; no recovery runs automatically. Relevant setup/actions from the standalone app: private let phoneField = UITextField() // viewDidLoad: add phoneField to the view and set its constraints phoneField.keyboardType = .phonePad // viewDidAppear let result = phoneField.becomeFirstResponder() print(result, phoneField.isFirstResponder) // Diagnostic button A, after dismissing and retapping: let again = phoneField.becomeFirstResponder() print(again, phoneField.isFirstResponder) // true, true; keypad absent // Diagnostic button B: phoneField.reloadInputViews() // popover reappears in this testOne additional observation: keyboard hide notifications can be delivered even while the small telephone-keypad popover is visibly present. Therefore, the last keyboard notification/frame is not a reliable visibility signal for this popover in this test. Is this an expected distinction between the phone-keypad popover and the software keyboard, or a UIKit/Simulator issue? What is the recommended public-API approach to allow a user to reopen it after dismissal? In particular, is calling reloadInputViews() when the field is already first responder an appropriate workaround, and is there a supported way to detect this popover's dismissed state? I have not yet filed a Feedback Assistant report, so there is no FB number to reference. I can provide the standalone reproduction project if needed.
Topic: UI Frameworks SubTopic: UIKit Tags:
Replies
0
Boosts
0
Views
88
Activity
5d
iOS 27: FBSScene crashes in objc_release_x26 after a scene settings update
Feedback Assistant: FB25454822 On iOS 27, our app (com.netshort.abroad) crashes inside FrontBoardServices while releasing an object saved across a synchronous scene-update callout. The stack has only system frames. A build shipped in September 2025 (1.8.3) hits the same crash as soon as the device is updated to iOS 27, so this is not a recent app change. OS: iOS 27.0.0 (24A435), iOS 27.0.1 (24A446) On build 2.3.4: 1264 events, 1216 users 0 libobjc.A.dylib objc_release_x26 + 8 1 FrontBoardServices -[FBSScene updater:didUpdateSettings:withDiff:transitionContext:completion:] + 780 2 FrontBoardServices _queue_updateScene…_block_invoke_2.cold.1 + 352 3 FrontBoardServices _queue_updateScene…_block_invoke_2 + 96 4 FrontBoardServices _calloutQueue_executeCalloutFromSource:withBlock: + 168 On 27.0.0 these frames show as <redacted> in Crashlytics. FrontBoardServices 0x19a88 is this method at 0x1977c plus 780, matching symbolicated 27.0.1 reports. In the 27.0.1 FrontBoardServices binary, +776 is objc_release(x26) and +780 is the return address. x26 is transitionContext.actions. The callout into UIKit is the bl at +0x2ac. The crash happens after that callout returns. 34 Apple crash reports with register state show the same pattern: the low byte of saved x26 is 0x01. 20 reports: objc_release_x26 + 8, x26 = 0x1 14 reports: objc_release_x26 + 16, x26 ends in 0x01 (for example 0x13c373a01) A nil actions value 0x0 becomes 0x1. A real pointer only has its low byte changed, so the isa read is off by one. In the +16 reports, x16 (0x8001000001fa8d89) is that isa shifted by one byte. This looks like a one-byte store of YES into the stack slot where x26 was saved across the callout. There is no single user action that reproduces it. It happens when the system delivers a scene settings update. The frame that wrote the byte is already gone, because the crash is recorded after the callout returns. Has anyone else seen this on iOS 27? I attached three .crash files with full register state to FB25454822.
Topic: UI Frameworks SubTopic: UIKit
Replies
0
Boosts
0
Views
261
Activity
5d
Catalyst layout sizes unexpected
On a 16" M5 MBP running 26.7.2 I have the display set to "1496 x 967" in the display section of Settings.app; the native resolution of the LCD panel is 3456 wide per the "System Information" report. When I inspect DOM nodes in a full screen width browser window, nodes which span the width of the screen show the expected 1496 CSS pixel width. However, when I run a Mac Catalyst app in Xcode, with its window at full screen width, and I inspect the bounds property of a UIView with the full width of the window, it reports its width as 1943 points wide, which doesn't match the value I expect (1496, same as FF sees) or the 'native point-resolution' of the display at 2x (1728 points). Furthermore, the nativeScale property of the UIWindow is 2, which combined with the point width contradicts the actual resolution of the LCD (i.e. 2*1943 != 3456.) I've looked for documentation but haven't found any. Where is 1943 point width coming from and why is the nativeScale 2? I was expecting 1496 and 1496/3456.
Replies
2
Boosts
0
Views
361
Activity
5d
iOS 27: app is not made inactive while the ATT prompt (or other permission alerts) is shown (FB25446786)
Since iOS 27, showing a system permission alert no longer deactivates the app. On iOS 26, sceneWillResignActive / applicationWillResignActive arrive about 0.05–0.1 s after ATTrackingManager.requestTrackingAuthorization. On iOS 27.0, 27.0.1 and 27.2 they don't arrive at all while the prompt is up, and SwiftUI's scenePhase stays .active. Apps that pause on resign, like games (Unity's iOS player pauses only on applicationWillResignActive), keep running behind the prompt: tutorials start, and timers and audio keep going. Minimal repro (plain UIKit with UIScene, fresh install so the status is .notDetermined): private var askedForTracking = false func sceneDidBecomeActive(_ scene: UIScene) { print("sceneDidBecomeActive") guard !askedForTracking else { return } askedForTracking = true DispatchQueue.main.asyncAfter(deadline: .now() + 3) { print("requesting ATT") ATTrackingManager.requestTrackingAuthorization { status in print("ATT finished: \(status.rawValue)") } } } func sceneWillResignActive(_ scene: UIScene) { print("sceneWillResignActive") }iOS 26.6: 3.27s requesting ATT 3.35s willResignActive 16.81s ATT finished: authorized 17.24s didBecomeActiveiOS 27.2: 3.21s requesting ATT 16.88s ATT finished: authorized 17.32s willResignActive 17.33s didBecomeActiveSo on iOS 27 the only lifecycle events are a resign/active pair about 0.44 s after the answer. What we found: The camera and notification permission alerts behave the same. It doesn't depend on the SDK the app is linked against, or on the thread making the request. SpringBoard's log shows the systemModalAlert deactivation assertion being added, but on iOS 27 the updateAllScenesForBand - Assertion added update never reaches the app's scene. The pending reason is only applied on the next unrelated scene update, such as a notification banner arriving, the screen dimming, an unlock, or the alert being dismissed. Taps outside the alert, a Control Center swipe or a home-indicator drag don't trigger it. Filed as FB25446786, with a sample project, delay sweeps on iOS 26 vs 27 (simulator and device) and a sysdiagnose. Is anyone else seeing this? And is there a supported way to know a permission alert is on screen until it's fixed? If you're affected, please file a Feedback and mention FB25446786; duplicates help.
Replies
0
Boosts
0
Views
57
Activity
5d
Issue: Screen rotation becomes locked when updating the status bar on an iPhone Duo.
Issue: Screen rotation becomes locked when updating the status bar on an iPhone Duo. This does not appear to be a device-specific hardware issue; however, it occurs specifically on the iPhone Duo. In my app, if I change the status bar visibility (using prefersStatusBarHidden) while on the iPhone Duo’s external screen, and then immediately unfold the device to reveal the internal screen, the app’s rotation state becomes locked. Although I use prefersInterfaceOrientationLocked to manage rotation, the app remains locked even when this property returns false. The issue persists even when prefersInterfaceOrientationLocked is commented out or removed entirely. Returning to the device’s home screen, rotating the device, and then re-entering the app resolves the lock. Has anyone encountered or resolved a similar issue?
Replies
0
Boosts
0
Views
66
Activity
5d
How to get UIInputView to appear with same height as standard keyboard?
I'm creating a custom keyboard by subclassing UIInputView. This is set as a text field's inputView property. This is a simple keypad similar to the standard numeric keypad keyboard. In fact, my UI lets the user switch between the standard numeric keypad and my custom input view. Given this it would be very nice if my custom input view was the same height as the standard keypad. If there a proper way to subclass UIInputView such that its height is the same "standard" height as the numeric keypad when run on any iOS device from iOS 17 through 27.3? I do not want to have to hardcode dozens of heights for every model iPhone and iPad, not to mention the 5 different heights you get on the iPhone Duo. I've tried various combinations of setting allowsSelfSizing to true and false along with returning a height of UIView.noIntrinsicMetric in intrinsicContentSize as well as not setting intrinsicContentSize at all. The closest result is when allowsSelfSizing is set to false. In that case my custom input view's height is somewhat similar to the standard keypad but in some cases it's off by 20-30 points roughly. Has anyone implemented a custom UIInputView that gets the standard keyboard height without hardcoding device specific heights?
Replies
0
Boosts
1
Views
93
Activity
6d
UINavigationController, Nav Bar does not extend to top on iPhone Duo
When using a background color for a UINavigation controller it seems the header does not extend to the top of the device for iPhone Duo when its closed in portrait mode. See screenshot. It should fill the entire 'status' bar up to top of device, Landscape correctly works, its just Portrait. Any thoughts on if this is 'expected' behavior? Seems odd to not just extend the navbar alll the way to the top.
Topic: UI Frameworks SubTopic: UIKit Tags:
Replies
6
Boosts
2
Views
936
Activity
6d