public abstract class ComponentBase
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
protected boolean |
mEnabled
flag that indicates if this axis / legend is enabled or not
|
protected int |
mTextColor
the text color to use for the labels
|
protected float |
mTextSize
the text size of the labels
|
protected android.graphics.Typeface |
mTypeface
the typeface used for the labels
|
protected float |
mXOffset
the offset in pixels this component has on the x-axis
|
protected float |
mYOffset
the offset in pixels this component has on the Y-axis
|
| Constructor and Description |
|---|
ComponentBase() |
| Modifier and Type | Method and Description |
|---|---|
int |
getTextColor()
Returns the text color that is set for the labels.
|
float |
getTextSize()
returns the text size that is currently set for the labels, in pixels
|
android.graphics.Typeface |
getTypeface()
returns the Typeface used for the labels, returns null if none is set
|
float |
getXOffset()
Returns the used offset on the x-axis for drawing the axis or legend
labels.
|
float |
getYOffset()
Returns the used offset on the x-axis for drawing the axis labels.
|
boolean |
isEnabled()
Returns true if this comonent is enabled (should be drawn), false if not.
|
void |
setEnabled(boolean enabled)
Set this to true if this component should be enabled (should be drawn),
false if not.
|
void |
setTextColor(int color)
Sets the text color to use for the labels.
|
void |
setTextSize(float size)
sets the size of the label text in density pixels min = 6f, max = 24f, default
10f
|
void |
setTypeface(android.graphics.Typeface tf)
sets a specific Typeface for the labels
|
void |
setXOffset(float xOffset)
Sets the used x-axis offset for the labels on this axis.
|
void |
setYOffset(float yOffset)
Sets the used y-axis offset for the labels on this axis.
|
protected boolean mEnabled
protected float mXOffset
protected float mYOffset
protected android.graphics.Typeface mTypeface
protected float mTextSize
protected int mTextColor
public float getXOffset()
public void setXOffset(float xOffset)
xOffset - public float getYOffset()
public void setYOffset(float yOffset)
yOffset - public android.graphics.Typeface getTypeface()
public void setTypeface(android.graphics.Typeface tf)
tf - public void setTextSize(float size)
size - the text size, in DPpublic float getTextSize()
public void setTextColor(int color)
color - public int getTextColor()
public void setEnabled(boolean enabled)
enabled - public boolean isEnabled()