IPieDataSet<D> class abstract

What the pie chart renderer reads from a data set: slice spacing, selection shift and the placement of value labels with their connector lines. Implemented by PieDataSet.

D is the type of the payload attached to each entry.

Inheritance
Implementers

Constructors

IPieDataSet()

Properties

axisDependency ↔ AxisDependency
The y axis this data set is plotted against. Default AxisDependency.LEFT.
getter/setter pairinherited
color → Color
The first of colors, the color used when only one is set.
no setterinherited
colors → List<Color>
Colors used to draw the entries, cycled by getColor when there are fewer colors than entries.
no setterinherited
entryCount → int
Number of entries in this data set.
no setterinherited
form → LegendForm
Shape drawn for this data set in the legend. LegendForm.DEFAULT uses the legend's form.
no setterinherited
formLineDashEffect → DashPathEffect?
Dash effect for legend forms drawn as lines. Null uses the legend's dash effect.
no setterinherited
formLineWidth → double
Line width in dp for legend forms drawn as lines. NaN uses the legend's line width.
no setterinherited
formSize → double
Size of the legend form in dp. NaN uses the legend's form size.
no setterinherited
hashCode → int
The hash code for this object.
no setterinherited
hasNonFiniteY → bool
True when an entry's y may not be a finite number, so a renderer has to look for gaps before drawing a line. The default is true, which is always safe; answer false only when every y is known to be finite.
no setterinherited
highlightColor → Color?
Color of a highlighted slice, null to keep the slice color.
no setter
iconsOffset ↔ MPPointF
Offset of the icons from their entry position in dp. For pie and radar charts x moves the icon along the value direction and y moves it towards or away from the center.
getter/setter pairinherited
isAutomaticallyDisableSliceSpacingEnabled → bool
True to drop the slice space when the smallest slice would be narrower than the space itself. Default false.
no setter
isDrawIconsEnabled ↔ bool
True to draw the entry icons. Default true. Not drawn when more entries are visible than the chart's maxVisibleCount allows.
getter/setter pairinherited
isDrawValuesEnabled ↔ bool
True to draw the value labels at the entries. Default true. Not drawn when more entries are visible than the chart's maxVisibleCount allows.
getter/setter pairinherited
isHighlightEnabled ↔ bool
True if entries of this data set can be highlighted by touch or chart.highlightValue(...). Default true.
getter/setter pairinherited
isUseValueColorForLineEnabled → bool
True to draw the connector line in the slice color instead of valueLineColor. Default false.
no setter
isValueLineVariableLength → bool
True to shorten the connector line for slices near the horizontal center. Default true.
no setter
isVisible ↔ bool
True if this data set is drawn. Default true. Hidden data sets still count for the axis ranges.
getter/setter pairinherited
label ↔ String
Name shown in the legend for this data set.
getter/setter pairinherited
needsFormatter → bool
True if no formatter was set, so the chart should supply its default formatter.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
selectionShift → double
Distance in dp a highlighted slice is pushed outwards from the center. Default 9 dp.
no setter
sliceSpace → double
Gap between neighbouring slices in dp, from 0 to 20. Default 0.
no setter
valueFormatter ↔ IValueFormatter
Formatter for the value labels drawn at the entries. Until one is set, the chart's default formatter is returned and needsFormatter is true.
getter/setter pairinherited
valueLineColor → Color
Color of the connector line for values drawn outside the slice. Default black.
no setter
valueLinePart1Length → double
Length of the first, outward pointing part of the connector line as a fraction of the radius. Default 0.3.
no setter
valueLinePart1OffsetPercentage → double
Where the connector line starts, as a percentage of the radius measured from the slice edge. Default 75.
no setter
valueLinePart2Length → double
Length of the second, horizontal part of the connector line as a fraction of the radius. Default 0.4.
no setter
valueLineWidth → double
Stroke width of the connector line in dp. Default 1 dp.
no setter
valueTextColor ↔ Color
Color of the value labels. Reading it returns the first of valueTextColors; writing replaces the whole list.
getter/setter pairinherited
valueTextColors ↔ List<Color>
Colors of the value labels, cycled by getValueTextColor when there are fewer colors than entries.
getter/setter pairinherited
valueTextSize ↔ double
Text size of the value labels in dp. Default 7 dp.
getter/setter pairinherited
valueTypeface ↔ Typeface?
Typeface of the value labels, null for the default.
getter/setter pairinherited
xMax → double
Largest x value in this data set, -Float.MAX_VALUE when empty.
no setterinherited
xMin → double
Smallest x value in this data set, Kotlin Float.MAX_VALUE when empty.
no setterinherited
xValuePosition → ValuePosition
Where the entry labels are drawn, inside or outside the slice. Default ValuePosition.INSIDE_SLICE.
no setter
yMax → double
Largest y value in this data set, -Float.MAX_VALUE when empty.
no setterinherited
yMin → double
Smallest y value in this data set, Kotlin Float.MAX_VALUE when empty.
no setterinherited
yValuePosition → ValuePosition
Where the values are drawn, inside or outside the slice. Default ValuePosition.INSIDE_SLICE.
no setter

Methods

addEntry(PieEntry<D> e) → bool
Appends e at the end of the entry list and updates the min and max values.
inherited
addEntryOrdered(PieEntry<D> e) → void
Inserts e at the position matching its x value and updates the min and max values.
inherited
calcMinMax() → void
Recomputes xMin, xMax, yMin and yMax from all entries.
inherited
calcMinMaxY(double fromX, double toX) → void
Recomputes yMin and yMax from the entries between the x values fromX and toX only. Used when the chart auto scales its y axis to the visible range.
inherited
clear() → void
Removes all entries and resets the min and max values.
inherited
contains(PieEntry<D> entry) → bool
True if entry is in this data set. Scans all entries.
inherited
getColor(int index) → Color
Returns the color for entry index, wrapping around colors with modulo.
inherited
getEntriesForXValue(double xValue) → List<PieEntry<D>>
Returns all entries whose x value equals xValue, or an empty list if there is none.
inherited
getEntryForIndex(int index) → PieEntry<D>
Returns the entry at position index in the entry list.
inherited
getEntryForXValue(double xValue, [double closestToY = double.nan, Rounding rounding = Rounding.CLOSEST]) → PieEntry<D>?
Returns the entry at xValue, or the entry at the nearest x value according to rounding if there is none.
inherited
getEntryIndex(double xValue, [double closestToY = double.nan, Rounding rounding = Rounding.CLOSEST]) → int
Returns the index of the entry at xValue, or of the entry at the nearest x value according to rounding.
inherited
getEntryIndexOf(Entry e) → int
Returns the index of e in the entry list, or -1 if it is not contained.
inherited
getIndexInEntries(int xIndex) → int
Returns the index of the first entry whose x value equals xIndex by scanning all entries, or -1 if there is none.
inherited
getValueTextColor(int index) → Color
Returns the value label color for entry index, wrapping around valueTextColors with modulo.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
removeEntry(PieEntry<D> e) → bool
Removes e and updates the min and max values. Returns false if e is not contained.
inherited
removeEntryByIndex(int index) → bool
Removes the entry at index and returns true. Throws when index is out of range.
inherited
removeEntryByXValue(double xValue) → bool
Removes the entry at or closest to xValue. Returns false if the data set is empty.
inherited
removeFirst() → bool
Removes the entry at index 0. Returns false if the data set is empty.
inherited
removeLast() → bool
Removes the last entry. Returns false if the data set is empty.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited