Package-level declarations

Functions

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun CharSequence.click(paintConsumer: (TextPaint) -> Unit = {}, clickAction: () -> Unit): CharSequence
Link copied to clipboard
Link copied to clipboard

Version of String.format that works on Spanned strings to preserve rich text formatting. Both the format as well as any %s args can be Spanned and will have their formatting preserved. Due to the way Spannables work, any argument's spans will can only be included once in the result. Any duplicates will appear as text only.

Link copied to clipboard
operator fun <T> ArrayAdapter<T>.get(position: Int): T?
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun WebView.loadHTMLWithStylesheet(stylesheetName: String, htmlBody: String)

Loads html into a webview styled by a stylesheet from assets. Example AMUtil.loadStyledHTML(webview, "style.css", "

Example

");

Link copied to clipboard
fun WebView.loadStyledHTML(style: String, htmlBody: String)

Loads html into a webview with custom css styling. Example AMUtil.loadStyledHTML(webview, "{p {text-align: center;color: red;}}", "

Example

");

Link copied to clipboard
fun CharSequence.scale(relativeSize: Float): CharSequence
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun Context.themeAttrColor(@AttrRes attributeColor: Int): Int

Get a color from the attribute theme

Link copied to clipboard
fun Context.themeAttrDimen(@AttrRes attributeDimen: Int): Float

Get a dimen from the attribute theme

Link copied to clipboard
fun Context.themeAttrDrawable(@AttrRes attributeDrawable: Int): Drawable?

Get a drawable from the attribute theme

Link copied to clipboard