Replace com.example
with your package name.
<com.example.ImageSpannedTextView
android:id="@+id/text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:text="@string/image_text"/>
Replace ic_span
with your drawable resource image name. Here ic_span
is a ic_span.png
file.
<string name="image_text">This is [img src=ic_span/] an inline image</string>