Class: TouchBarSegmentedControl

    Process:
    This class is not exported from the 'electron' module. It is only available as a return value of other methods in the Electron API.

    • options Object
      • - An array of segments to place in this control.
      • selectedIndex Integer (optional) - The index of the currently selected segment, will update automatically with user interaction. When the mode is multiple it will be the last selected item.
      • change Function (optional) - Called when the user selects a new segment.
        • selectedIndex Integer - The index of the segment the user selected.
        • isSelected boolean - Whether as a result of user selection the segment is selected or not.

    Instance Properties

    touchBarSegmentedControl.segmentStyle

    A string representing the controls current segment style. Updating this value immediately updates the control in the touch bar.

    touchBarSegmentedControl.segments

    touchBarSegmentedControl.selectedIndex

    An Integer representing the currently selected segment. Changing this value immediately updates the control in the touch bar. User interaction with the touch bar will update this value automatically.

    touchBarSegmentedControl.mode