-
- All Implemented Interfaces:
public class Annotation.TextDisplayInfo
* This class is used to set textual display information. It also includes offsets to control where the text will be displayed in relation to the annotation
-
-
Constructor Summary
Constructors Constructor Description Annotation.TextDisplayInfo(String text, int offsetX, int offsetY)
* Annotation.TextDisplayInfo(String text)
-
Method Summary
Modifier and Type Method Description String
getText()
int
getOffsetX()
Get the horizontal offset of text int
getOffsetY()
Get the vertical offset of text int
getTextColor()
* to get the color of the text in relation to annotation void
setTextColor(@ColorInt() int textColor)
* to set the color of the text in relation to annotation static Annotation.TextDisplayInfo
Centered(@NonNull() String text)
void
setTextSize(float text_size)
* to set the size of the text in relation to annotation float
getTextSize()
* to get the size of the text in relation to annotation -
-
Constructor Detail
-
Annotation.TextDisplayInfo
Annotation.TextDisplayInfo(String text, int offsetX, int offsetY)
*- Parameters:
text
- the text to be displayed with the annotationoffsetX
- the horizontal offset of the text in relation to the annotation, the unit is px.offsetY
- the vertical offset of the text in relation to the annotation, the unit is px.
-
Annotation.TextDisplayInfo
Annotation.TextDisplayInfo(String text)
-
-
Method Detail
-
getOffsetX
int getOffsetX()
Get the horizontal offset of text
-
getOffsetY
int getOffsetY()
Get the vertical offset of text
-
getTextColor
@ColorInt() int getTextColor()
* to get the color of the text in relation to annotation
-
setTextColor
void setTextColor(@ColorInt() int textColor)
* to set the color of the text in relation to annotation
- Parameters:
textColor
- the color of the text.
-
Centered
static Annotation.TextDisplayInfo Centered(@NonNull() String text)
-
setTextSize
void setTextSize(float text_size)
* to set the size of the text in relation to annotation
- Parameters:
text_size
- the size of the text in relation to annotation, value range [0.0pt, 32.
-
getTextSize
float getTextSize()
* to get the size of the text in relation to annotation
-
-
-
-