Sets the selection state of the specified segment.
YES if you want to select the segment; otherwise,
The index of the segment whose selection state you want to set. This method raises an exception (
NSRangeException) if the index is out of bounds.
If the control allows only a single selection, this method deselects any other selected segments.
trackingMode property of the segment is set to
NSSegmentSwitchTrackingMomentary, then attempting to set the selected state of the segment will have no effect.
Managing the Selected Segment
The index of the selected segment of the control, or
-1 if no segment is selected.
When the tracking mode for the control is set to use a momentary accelerator, returns a value for the selected segment.