RBMenuSegmentSchema Class Reference

Inherits from NSObject
Declared in RBMenuSegmentSchema.h

Overview

A schema describing a menu segment.

  identifier

The unique identifier of the segment. Identifier is also used as theme identifier within the menu theme.

@property (nonatomic, readonly, nullable) NSString *identifier

Discussion

The unique identifier of the segment. Identifier is also used as theme identifier within the menu theme.

Declared In

RBMenuSegmentSchema.h

  themeOverrides

Theme values to apply after any other prior theming has been applied.

@property (nonatomic, readonly, nullable) NSDictionary<NSString*id> *themeOverrides

Discussion

Theme values to apply after any other prior theming has been applied.

Declared In

RBMenuSegmentSchema.h

  headerView

The header view to display above the items in the segment. Note RBMenuSegmentHeaderView may serve for most purposes.

@property (nonatomic, readonly, nullable) UIView *headerView

Discussion

The header view to display above the items in the segment. Note RBMenuSegmentHeaderView may serve for most purposes.

Declared In

RBMenuSegmentSchema.h

  items

An array of RBMenuSegmentButton schemas. The following types are supported: RBMenuSegmentButtonSchema, RBMenuSegmentToggleButtonSchema, RBMenuSegmentCustomItemSchema.

@property (nonatomic, readonly, nonnull) NSArray *items

Discussion

An array of RBMenuSegmentButton schemas. The following types are supported: RBMenuSegmentButtonSchema, RBMenuSegmentToggleButtonSchema, RBMenuSegmentCustomItemSchema.

Declared In

RBMenuSegmentSchema.h

  exclusiveToggleButtons

Whether or not only one of the toggle buttons can be selected at any one time in the segment. When the user selects an item, the others in the segment will unselect.

@property (nonatomic, readonly) BOOL exclusiveToggleButtons

Discussion

Whether or not only one of the toggle buttons can be selected at any one time in the segment. When the user selects an item, the others in the segment will unselect.

Declared In

RBMenuSegmentSchema.h

– initWithIdentifier:headerView:items:exclusiveToggleButtons:themeOverrides:

Initializes the menu segment schema.

- (nonnull instancetype)initWithIdentifier:(nonnull NSString *)identifier headerView:(nullable UIView *)headerView items:(nonnull NSArray *)items exclusiveToggleButtons:(BOOL)exclusiveToggleButtons themeOverrides:(nullable NSDictionary<NSString*,id> *)themeOverrides

Parameters

identifier

The unique identifier of the segment.

headerView

The header view to display above the items in the segment. Note RBMenuSegmentHeaderView may serve for most purposes.

items

An array of segment button schemas (of type RBMenuSegmentButtonSchema, RBMenuSegmentToggleButtonSchema).

exclusiveToggleButtons

Whether or not the selection of toggle buttons is exclusive (single selection).

themeOverrides

Theme values to apply after any other prior theming has been applied.

Return Value

The initialized menu segment schema.

Discussion

Initializes the menu segment schema.

Declared In

RBMenuSegmentSchema.h