public class CursorMode
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected int |
cachedLegendWidth |
protected java.util.Map<BaseSeries,DataPointInterface> |
mCurrentSelection |
protected double |
mCurrentSelectionX |
protected boolean |
mCursorVisible |
protected GraphView |
mGraphView |
protected Paint |
mPaintLine |
protected float |
mPosX |
protected float |
mPosY |
protected Paint |
mRectPaint |
protected com.jjoe64.graphview.CursorMode.Styles |
mStyles |
protected Paint |
mTextPaint |
Constructor and Description |
---|
CursorMode(GraphView graphView) |
Modifier and Type | Method and Description |
---|---|
void |
draw(Canvas canvas) |
protected void |
drawLegend(Canvas canvas) |
protected java.lang.String |
getTextForSeries(Series s,
DataPointInterface value) |
void |
onDown(MotionEvent e) |
void |
onMove(MotionEvent e) |
boolean |
onUp(MotionEvent event) |
void |
resetStyles()
resets the styles to the defaults
and clears the legend width cache
|
void |
setBackgroundColor(int color) |
void |
setMargin(int s) |
void |
setPadding(int s) |
void |
setSpacing(int s) |
void |
setTextColor(int color) |
void |
setTextSize(float t) |
void |
setWidth(int s) |
protected final Paint mPaintLine
protected final GraphView mGraphView
protected float mPosX
protected float mPosY
protected boolean mCursorVisible
protected final java.util.Map<BaseSeries,DataPointInterface> mCurrentSelection
protected final Paint mRectPaint
protected final Paint mTextPaint
protected double mCurrentSelectionX
protected com.jjoe64.graphview.CursorMode.Styles mStyles
protected int cachedLegendWidth
public CursorMode(GraphView graphView)
public void resetStyles()
public void onDown(MotionEvent e)
public void onMove(MotionEvent e)
public void draw(Canvas canvas)
protected java.lang.String getTextForSeries(Series s, DataPointInterface value)
protected void drawLegend(Canvas canvas)
public boolean onUp(MotionEvent event)
public void setTextSize(float t)
public void setTextColor(int color)
public void setBackgroundColor(int color)
public void setSpacing(int s)
public void setPadding(int s)
public void setMargin(int s)
public void setWidth(int s)