FUIChartLegendView

open class FUIChartLegendView : FUIDrawingView, FUISeriesTitleComponent, UIGestureRecognizerDelegate, ChartObserver

Legend view component of FUIChartLegendTableViewCell, FUIChartFloorplanView, FUIChartFloorplanViewController, and FUIChartFloorplanTableViewCell.

Typically not used directly by developer.

Usage

let view = FUIChartLegendView()
view.seriesTitles = ["2016", "2017"]
view.seriesColor = [UIColor.preferredFioriColor(forStyle: .chart1), UIColor.preferredFioriColor(forStyle: .chart2)]

Theming

Supported class paths:

fdlFUIChartLegendView_seriesTitles {}

Supported properties:

font-color: Color; font-style: UIFontTextStyle; text-line-clamp: Integer; text-align: NSTextAlignment;

  • Array of UIColors to be used to show series data on the FUIChartView

    Declaration

    Swift

    public var seriesColors: [UIColor] { get set }
  • Flag for setting if should enable series selection when legend for series is tapped.

    Declaration

    Swift

    open var allowSelection: Bool
  • Index for selected series.

    Declaration

    Swift

    open var indexForSelectedSeries: Int? { get }
  • Selects a series in the legend view identified by index.

    Calling this method does not cause the delegate to receive a chartLegendView(_:didSelectSeriesAt:) message

    Declaration

    Swift

    open func selectSeries(at index: Int?)

    Parameters

    index

    Index for series.

  • Deselects a series in the legend view identified by index.

    Calling this method does not cause the delegate to receive a chartLegendView(_:didDeselectSeriesAt:) message

    Declaration

    Swift

    open func deselectSeries(at index: Int)

    Parameters

    index

    Index for series.

  • Delegate class for the FUIChartLegendView.

    Declaration

    Swift

    public weak var delegate: FUIChartLegendViewDelegate?
  • System formatted String to be displayed as the seriesTitle

    Declaration

    Swift

    public var seriesTitles: [FUIText] { get set }
  • Developer formatted NSAttributedString to display as the series title

    Declaration

    Swift

    public var seriesTitlesAttributedText: NSAttributedString! { get set }