migueldeicaza / SwiftTermApp

MIT License
305 stars 29 forks source link

iPad Default Look #131

Closed migueldeicaza closed 2 years ago

migueldeicaza commented 2 years ago

The default look on the iPad hides the sidebar on portrait mode.

The story is that UISplitViewControllers have two capabilities that control the behavior: preferredSplitBehavior and preferredDisplayMode, documented on the UISplitViewController page

The problem is that these capabilities are not exposed in the automatic SwiftUI system that wires this up, as documented by Hacking with Swift.

The options seem to be:

The hack can be made to work, but comes with assorted caveats, like need to take over the various policies, even for those where the defaults of SwiftUI are sensible.

migueldeicaza commented 2 years ago

The new landing page avoids the discoverability issues. Also the swift-introspect can be used to do this with SwiftUI if necessary in the future