TextImageView
TextImageView copied to clipboard
An ImageView subclass that draws a spannable text on top of the image
TextImageView
An ImageView subclass that draws one or more spannable, rotable, scalable texts on top of the image.
Provided that this is an ImageView subclass, you can use Picasso, Glide, or any Image loader that you like to load the image into TextImageView.
New in 4.0
Rewritten in kotlin+androidx
Requirements
Android 4.0, API 14
Usage
Gradle dependency
dependencies {
implementation 'com.antonionicolaspina:textimageview:4.0'
}
Sample layout
<com.antonionicolaspina.textimageview.TextImageView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:text="my text"
android:textSize="30sp"
android:textColor="#ff0000"
app:tiv_panEnabled="true"
app:tiv_scaleEnabled="true"
app:tiv_rotationEnabled="true"
android:src="@drawable/sample"/>
License
Copyright 2020 YaikoStudio
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.