SegmentedControl
public struct SegmentedControl : Element, Measurable
Allows users to pick from an array of options.
-
Declaration
Swift
public var items: [Item]
-
Declaration
Swift
public var selection: Selection
-
Declaration
Swift
public var font: UIFont
-
Declaration
Swift
public var roundingScale: CGFloat
-
Declaration
Swift
public init(items: [Item] = [], configure: (inout SegmentedControl) -> Void = { _ in })
-
Declaration
Swift
public mutating func appendItem(title: String, width: Item.Width = .automatic, onSelect: @escaping () -> Void)
-
Declaration
Swift
public var content: ElementContent { get }
-
Declaration
Swift
public func measure(in constraint: SizeConstraint) -> CGSize
-
Declaration
Swift
public func backingViewDescription(with context: ViewDescriptionContext) -> ViewDescription?
-
Declaration
Swift
public enum Selection
-
Declaration
Swift
public struct Item