Legend class

Inheritance

Constructors

Legend()
default constructor
Legend.fromList(List<LegendEntry> entries)
Constructor. Provide entries for the legend. [...]

Properties

calculatedLabelBreakPoints List<bool>
read-only
calculatedLabelSizes List<FSize>
read-only
calculatedLineSizes List<FSize>
read-only
direction LegendDirection
read / write
drawInside bool
read / write
enabled bool
read / write, inherited
entries List<LegendEntry>
read / write
extraEntries List<LegendEntry>
read-only
formLineWidth double
read / write
formSize double
read / write
formToTextSpace double
read / write
hashCode int
The hash code for this object. [...]
read-only, inherited
horizontalAlignment LegendHorizontalAlignment
read / write
isLegendCustom bool
read-only
maxSizePercent double
read / write
neededHeight double
read-only
neededWidth double
read-only
orientation LegendOrientation
read / write
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited
shape LegendForm
read / write
stackSpace double
read / write
textColor Color
read / write, inherited
textHeightMax double
read-only
textSize double
read / write, inherited
textWidthMax double
read-only
typeface TypeFace
read / write, inherited
verticalAlignment LegendVerticalAlignment
read / write
wordWrapEnabled bool
read / write
xEntrySpace double
read / write
xOffset double
read / write, inherited
yEntrySpace double
read / write
yOffset double
read / write, inherited

Methods

calculateDimensions(TextPainter labelpainter, ViewPortHandler viewPortHandler) → void
Calculates the dimensions of the Legend. This includes the maximum width and height of a single entry, as well as the total width and height of the Legend. [...]
getFormLineDashEffect() DashPathEffect
@return The line dash path effect used for shapes that consist of lines.
getMaximumEntryHeight(TextPainter p) double
returns the maximum height in pixels across all legend labels [...]
getMaximumEntryWidth(TextPainter p) double
returns the maximum length in pixels across all legend labels + formsize [...]
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
resetCustom() → void
Calling this will disable the custom legend entries (set by setCustom(...)). Instead, the entries will again be calculated automatically (after notifyDataSetChanged() is called).
setCustom(List<LegendEntry> entries) → void
Sets a custom legend's entries array. [...]
setExtra1(List<LegendEntry> entries) → void
setExtra2(List<Color> colors, List<String> labels) → void
Entries that will be appended to the end of the auto calculated entries after calculating the legend. (if the legend has already been calculated, you will need to call notifyDataSetChanged() to let the changes take effect)
setFormLineDashEffect(DashPathEffect dashPathEffect) → void
Sets the line dash path effect used for shapes that consist of lines. [...]
toString() String
Returns a string representation of this object.
inherited

Operators

operator ==(dynamic other) bool
The equality operator. [...]
inherited