menu(forSegment:)
Returns the menu for the specified segment.
Declaration
func menu(forSegment segment: Int) -> NSMenu?Parameters
- segment:
The index of the segment whose menu you want to get. This method raises an exception (Rangeexception) if the index is out of bounds.
Return Value
The menu associated with the segment; otherwise, nil.
See Also
Configuring Individual Segments
setLabel(_:forSegment:)label(forSegment:)setImage(_:forSegment:)image(forSegment:)setImageScaling(_:forSegment:)imageScaling(forSegment:)setWidth(_:forSegment:)width(forSegment:)setEnabled(_:forSegment:)isEnabled(forSegment:)setMenu(_:forSegment:)setToolTip(_:forSegment:)toolTip(forSegment:)setTag(_:forSegment:)tag(forSegment:)