Instance Property


The item to display for a group when space is constrained.


var representativeItem: UIBarButtonItem? { get set }


When space is constrained on the shortcuts bar, UIKit may display a group’s representative item in place of its actual items. The representative item is a single bar button item that is unique from the other items in the group. Tapping the representative item calls its action method normally. If you omit that action method, UIKit responds by automatically displaying the group’s items in a standard interface.

If you do not specify a representative item for a group, UIKit tries to display the group’s items in the shortcuts bar. If space is still constrained, UIKit may modify the appearance of items in the group to make room for all of the items. For example, UIKit may truncate the titles of textual bar button items. When space is severely constrained, UIKit may not even display a group’s representative item.

See Also

Configuring the Group

var barButtonItems: [UIBarButtonItem]

The bar button items to display on the shortcuts bar.