Summ:  Constr. Methods    Details:  Constr. Methods      Class:  Prev Next
com.artfulbits.aiCharts.Annotations
Class ChartDrawableAnnotation

java.lang.Object com.artfulbits.aiCharts.Annotations.ChartAnnotation com.artfulbits.aiCharts.Annotations.ChartDrawableAnnotation

Declaration: public class ChartDrawableAnnotation extends ChartAnnotation

 

Represents drawable annotation. Instance of this class is considered to be added to chart's collection.

 

Since: 1.0

 

 

Constructors Summary
ChartDrawableAnnotation(android.graphics.drawable.Drawable drawable)
    
Initializes a new instance of drawable annotation.
ChartDrawableAnnotation(android.graphics.drawable.Drawable drawable, java.lang.String description)
    
Initializes a new instance of drawable annotation with specified description.

 

 

Methods Summary
void draw(android.graphics.Canvas canvas, ChartEngine chart)
    
Draws annotation of specified canvas.
android.graphics.drawable.Drawable getDrawable()
    
Gets drawable object that is to be used to present this annotation.
Alignment getHorizontalAlignment()
    
Gets the horizontal alignment for this annotation.
Alignment getVerticalAlignment()
    
Gets the vertical alignment for this annotation.
void setAlignment(Alignment horizontalAlignment, Alignment verticalAlignment)
    
Sets alignment for this annotation.
void setHorizontalAlignment(Alignment alignment)
    
Sets the vertical alignment for annotation.
void setVerticalAlignment(Alignment alignment)
    
Sets the vertical alignment for annotation.

 

Methods inherited from class: com.artfulbits.aiCharts.Annotations.ChartAnnotation
getDescription, getOffset, getPosition, setDescription, setOffset, setPosition

 

Methods inherited from class: java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

 

 

 

ChartDrawableAnnotation

 

public ChartDrawableAnnotation( android.graphics.drawable.Drawable drawable)

 

Initializes a new instance of drawable annotation.

 

Parameters:
drawable-
instance of android.graphics.drawable.Drawable that is to be used to present annotation.

 

Since: 1.0

 

 

 

ChartDrawableAnnotation

 

public ChartDrawableAnnotation( android.graphics.drawable.Drawable drawable,
java.lang.String description)

 

Initializes a new instance of drawable annotation with specified description.

 

Parameters:
drawable-
instance of android.graphics.drawable.Drawable that is to be used to present annotation.
description-
text description of annotation.
Throws:
java.lang.NullPointerException - for drawable that is.

 

Since: 1.0

 

 

 

 

setAlignment

 

public void setAlignment( Alignment horizontalAlignment,
Alignment verticalAlignment)

 

Sets alignment for this annotation.

 

Parameters:
horizontalAlignment-
verticalAlignment-

 

Since: 1.0

 

 

 

setVerticalAlignment

 

public void setVerticalAlignment( Alignment alignment)

 

Sets the vertical alignment for annotation.

 

Parameters:
alignment-
instance of Alignment enumeration containing current alignment value.

 

Since: 1.0

 

 

 

getVerticalAlignment

 

public Alignment getVerticalAlignment( )

 

Gets the vertical alignment for this annotation.

 

Returns:
instance of Alignment enumeration containing current alignment value.

 

Since: 1.0

 

 

 

setHorizontalAlignment

 

public void setHorizontalAlignment( Alignment alignment)

 

Sets the vertical alignment for annotation.

 

Parameters:
alignment-
instance of Alignment enumeration containing current alignment value.

 

Since: 1.0

 

 

 

getHorizontalAlignment

 

public Alignment getHorizontalAlignment( )

 

Gets the horizontal alignment for this annotation.

 

Returns:
instance of Alignment enumeration containing current alignment value.

 

Since: 1.0

 

 

 

getDrawable

 

public android.graphics.drawable.Drawable getDrawable( )

 

Gets drawable object that is to be used to present this annotation.

 

Returns:
instance of android.graphics.drawable.Drawable.

 

Since: 1.0

 

 

 

draw

 

public void draw( android.graphics.Canvas canvas,
ChartEngine chart)

 

[ description from ChartAnnotation.draw(android.graphics.Canvas,ChartEngine) ]
 
Draws annotation of specified canvas.

 

Parameters:
canvas-
instance of canvas that is used to draw annotation.
chart-
instance of parent chart.

 

Implements: ChartAnnotation.draw(Canvas,ChartEngine)

 

 

© 2005 - 2010 ArtfulBits. All rights reserved.