I’m creating a UITabBarController with a simple array of UITab instances. I’m setting the mode to .tabSideBar
. How do I prevent editing? I don’t want the Edit button to appear at all. I’ve tried setting the tab controller’s customizableViewControllers
property to both nil
and an empty array but neither is preventing the Edit button from appearing. I scanned the various delegates and I don‘t see any relevant methods.
So far I’ve tested this on a simulated iPad running iPadOS 26 using Xcode 26 RC.
The 'Edit' button will show up in the sidebar as long as editing is supported in UITabBarController
for the current set of tabs.
Editing is supported if any of the following are true:
- Any tab has a customizable
preferredPlacement
(i.e. not.fixed
or.pinned
) - If a tab can be hidden:
allowsHiding = true
- If a tab group can be reordered:
allowsReordering = true
By default , the preferredPlacement
is automatic
which does support editing. Set it to .fixed
to disable customization for them.