Skip to content

Latest commit

 

History

History
31 lines (24 loc) · 1.54 KB

File metadata and controls

31 lines (24 loc) · 1.54 KB

License

:string-annotations:views

Artifact of StringAnnotations library for Android Views UI.

Configuration

General configuration is described in repository's README.

ClickableTextAppearance

You should define default appearance of your Clickable annotations text.

  1. (optional) Define your own style for clickable text appearance. You can use Base.ClickableTextAppearance style as a parent.
  2. Specify default clickable text appearance style in your application theme via clickableTextAppearance attribute.

Example:

<style name="YourApplicationTheme" parent="">
   <!-- other theme attributes omitted -->
   <item name="clickableTextAppearance">@style/TextAppearance.ClickableTextAppearance</item>
</style>

<style name="TextAppearance.ClickableTextAppearance" parent="Base.ClickableTextAppearance">
    <item name="android:textColor">#21834B</item> <!-- let clickable text be green by default -->
</style>

Note Specified clickableTextAppearance can be obtained in code via ClicableTextAppearance.Companion.from(…) extension function.