public class Snippety
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static class |
Snippety.FontStyle
FontStyle options for text
|
static class |
Snippety.Indent
Indent options for text
|
static interface |
Snippety.OnClickListener
click listener for text
|
| Constructor and Description |
|---|
Snippety()
default constructor for Snippety
|
| Modifier and Type | Method and Description |
|---|---|
Snippety |
addOnClickListener(Snippety.OnClickListener onClickListener)
add click listener to text
|
Snippety |
align(Snippety.Indent indent)
add alignment for text
|
Snippety |
backgroundColor(int color)
add background color to text
|
Snippety |
bullet()
add bullets
|
Snippety |
bullet(android.graphics.Bitmap bitmap,
int padding)
add image bullets with specified padding
|
Snippety |
bullet(int leadGap,
int gapWidth)
add bullets with specified leadGap and gapWidth
|
Snippety |
bullet(int leadGap,
int gapWidth,
java.lang.String data)
add custom bullets with specified leadGap and gapWidth
|
Snippety |
bullet(TextIndentSpan.Options options)
add bullets with specified options
|
Snippety |
bullet(TextIndentSpan.Options options,
java.lang.String data)
add bullets with specified options
|
Snippety |
fontStyle(Snippety.FontStyle fontStyle)
add font style of text
|
java.util.List<java.lang.Object> |
getSpans()
getter for spans object
|
Snippety |
hr(android.graphics.drawable.Drawable drawable)
Custom horiztontal line
|
Snippety |
hr(float lineWidth,
int lineColor)
Horizontal line
|
Snippety |
image(android.graphics.drawable.Drawable drawable)
add image drawable and align it to center
|
Snippety |
image(android.graphics.drawable.Drawable drawable,
int verticalAlignment)
add image drawable
|
Snippety |
number(int leadGap,
int gapWidth,
int number)
add numbers with specified leadGap and gapWidth
|
Snippety |
number(TextIndentSpan.Options options,
int number)
add numbers with specified options
|
Snippety |
quote(int color)
quote for text
|
Snippety |
roundedBackgroundColor(int backgroundColor,
int textColor)
add rounded background color to text
|
Snippety |
roundedBackgroundColor(int backgroundColor,
int textColor,
int cornerRadius)
add rounded background color to text with corner radius
|
Snippety |
strikethrough()
strikethrough text
|
Snippety |
subscript()
add subscript for text
|
Snippety |
suggestions(java.lang.String... suggestions)
add suggestions to @link{
EditText} |
Snippety |
superscript()
add superscript for text
|
Snippety |
textColor(int color)
add color to text
|
Snippety |
textMultiColor(int[] colors)
add multiple colors to text
|
Snippety |
textMultiColor(int[] colors,
int angle)
add multi color to text with angle
|
Snippety |
textSizeAbsolute(int size)
change absolute text size
|
Snippety |
textSizeRelative(float proportion)
change relative text size
|
Snippety |
typeface(android.graphics.Typeface typeface)
add typeface for text
|
Snippety |
underline()
add underlined text
|
Snippety |
url(java.lang.String url)
add url for text
|
public java.util.List<java.lang.Object> getSpans()
public Snippety textColor(int color)
color - of textpublic Snippety textMultiColor(int[] colors)
colors - array of textpublic Snippety textMultiColor(int[] colors, int angle)
colors - array of textangle - of colorspublic Snippety backgroundColor(int color)
color - of backgroundpublic Snippety roundedBackgroundColor(int backgroundColor, int textColor)
backgroundColor - of texttextColor - of textpublic Snippety roundedBackgroundColor(int backgroundColor, int textColor, int cornerRadius)
backgroundColor - of texttextColor - of textcornerRadius - of backgroundpublic Snippety align(Snippety.Indent indent)
indent - LEFT, RIGHT, CENTERpublic Snippety underline()
public Snippety subscript()
public Snippety superscript()
public Snippety strikethrough()
public Snippety url(java.lang.String url)
url - of textpublic Snippety quote(int color)
color - of quote linepublic Snippety fontStyle(Snippety.FontStyle fontStyle)
fontStyle - BOLD, ITALIC, NORMALpublic Snippety typeface(android.graphics.Typeface typeface)
typeface - for fontpublic Snippety addOnClickListener(Snippety.OnClickListener onClickListener)
onClickListener - for textpublic Snippety textSizeRelative(float proportion)
proportion - of text sizepublic Snippety textSizeAbsolute(int size)
size - of textpublic Snippety suggestions(java.lang.String... suggestions)
EditText}suggestions - suggestions String arraypublic Snippety bullet()
public Snippety bullet(int leadGap, int gapWidth)
leadGap - starting gap from leftgapWidth - gap between bullet and textpublic Snippety bullet(int leadGap, int gapWidth, java.lang.String data)
leadGap - starting gap from leftgapWidth - gap between bullet and textdata - data to show on bulletpublic Snippety bullet(android.graphics.Bitmap bitmap, int padding)
bitmap - bitmap to add as bulletpadding - padding between bullet and textpublic Snippety bullet(TextIndentSpan.Options options)
options - for leadGap and gapWidthpublic Snippety bullet(TextIndentSpan.Options options, java.lang.String data)
options - for leadGap and gapWidthdata - data to show on bulletpublic Snippety number(int leadGap, int gapWidth, int number)
leadGap - starting gap from leftgapWidth - gap between number and textnumber - index in list, not 0 basedpublic Snippety number(TextIndentSpan.Options options, int number)
options - for leadGap and gapWidthnumber - index in list, not 0 basedpublic Snippety image(android.graphics.drawable.Drawable drawable)
drawable - for imagepublic Snippety image(android.graphics.drawable.Drawable drawable, int verticalAlignment)
drawable - for imagepublic Snippety hr(float lineWidth, int lineColor)
public Snippety hr(android.graphics.drawable.Drawable drawable)
drawable - line drawable