Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我知道您可以创建一个 UISearchBar,将其放入 UIBarButtonItem,然后在代码中将其设置为 rightBarButtonItem,但我想知道现在在 IB 中是否有办法做到这一点?谢谢!
您可以在 UIBarButtonItem 中放置一个 UIView。然后,您可以将任何 UIView 子类作为子视图放入该 UIView。