Package com.androidplot.ui.widget
Class LegendWidget
-
- All Implemented Interfaces:
-
com.androidplot.ui.BoxModelable,com.androidplot.ui.Resizable
public abstract class LegendWidget<ItemT extends LegendItem> extends Widget
Provides core functionality for displaying a legend widget within a com.androidplot.Plot.
-
-
Field Summary
Fields Modifier and Type Field Description public SizeiconSizepublic PainttextPaintpublic Comparator<ItemT>legendItemComparatorpublic PaintborderPaintpublic PaintbackgroundPaintpublic Sizesizepublic DisplayDimensionswidgetDimensionspublic booleanisVisiblepublic PositionMetricspositionMetricspublic Widget.Rotationrotation
-
Constructor Summary
Constructors Constructor Description LegendWidget(TableModel tableModel, LayoutManager layoutManager, Size size, Size iconSize)
-
Method Summary
Modifier and Type Method Description SizegetIconSize()voidsetIconSize(@NonNull() Size iconSize)PaintgetTextPaint()voidsetTextPaint(@NonNull() Paint textPaint)Comparator<ItemT>getLegendItemComparator()voidsetLegendItemComparator(@Nullable() Comparator<ItemT> legendItemComparator)Set a scheme for sorting the display order or legend items. booleanisDrawIconBackgroundEnabled()booleanisDrawIconBorderEnabled()synchronized voidsetTableModel(@NonNull() TableModel tableModel)voidsetDrawIconBackgroundEnabled(boolean drawIconBackgroundEnabled)voidsetDrawIconBorderEnabled(boolean drawIconBorderEnabled)-
Methods inherited from class com.androidplot.ui.widget.Widget
calculateCoordinates, containsPoint, draw, getAnchor, getAnchorCoordinates, getAnchorCoordinates, getAnchorOffset, getBackgroundPaint, getBorderPaint, getHeightMetric, getHeightPix, getMarginBottom, getMarginLeft, getMarginRight, getMarginTop, getMarginatedRect, getPaddedRect, getPaddingBottom, getPaddingLeft, getPaddingRight, getPaddingTop, getPositionMetrics, getRotation, getSize, getWidgetDimensions, getWidthMetric, getWidthPix, isClippingEnabled, isVisible, layout, onPostInit, position, position, refreshLayout, setAnchor, setBackgroundPaint, setBorderPaint, setClippingEnabled, setHeight, setHeight, setMarginBottom, setMarginLeft, setMarginRight, setMarginTop, setMargins, setPadding, setPaddingBottom, setPaddingLeft, setPaddingRight, setPaddingTop, setPositionMetrics, setRotation, setSize, setVisible, setWidth, setWidth -
Methods inherited from class com.androidplot.ui.BoxModelable
getMarginatedRect, getPaddedRect, setMarginBottom -
Methods inherited from class com.androidplot.ui.Resizable
layout -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Constructor Detail
-
LegendWidget
LegendWidget(TableModel tableModel, LayoutManager layoutManager, Size size, Size iconSize)
-
-
Method Detail
-
getIconSize
@NonNull() Size getIconSize()
-
setIconSize
void setIconSize(@NonNull() Size iconSize)
-
getTextPaint
@NonNull() Paint getTextPaint()
-
setTextPaint
void setTextPaint(@NonNull() Paint textPaint)
-
getLegendItemComparator
@Nullable() Comparator<ItemT> getLegendItemComparator()
-
setLegendItemComparator
void setLegendItemComparator(@Nullable() Comparator<ItemT> legendItemComparator)
Set a scheme for sorting the display order or legend items. By default no sorting is applied and com.androidplot.Series items typically appear in the order which the series was added to the com.androidplot.Plot.
-
isDrawIconBackgroundEnabled
boolean isDrawIconBackgroundEnabled()
-
isDrawIconBorderEnabled
boolean isDrawIconBorderEnabled()
-
setTableModel
synchronized void setTableModel(@NonNull() TableModel tableModel)
-
setDrawIconBackgroundEnabled
void setDrawIconBackgroundEnabled(boolean drawIconBackgroundEnabled)
-
setDrawIconBorderEnabled
void setDrawIconBorderEnabled(boolean drawIconBorderEnabled)
-
-
-
-