SimpleTagImageView

本文介绍如何在Android应用中使用SimpleTagImageView组件,它是一个带有标签的ImageView,提供了丰富的自定义选项,如文本大小、颜色、背景色、圆角距离等。包括组件的快速入门、Gradle/Maven依赖导入、XML布局使用示例和许可证信息。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

https://github.com/wujingchao/SimpleTagImageView

SimpleTagImageView

ImageView with a tag in android. So it's a ImageView.

Demo

Warning:When you set the round radius,the simpletagimageview scale type just support fitXY now!

SimpleTagImageView.zip 

Usage

<net.wujingchao.android.view.SimpleTagImageView
        xmlns:simple="http://schemas.android.com/apk/res-auto"
        android:id="@+id/stiv"
        android:layout_margin="18dip"
        android:layout_width="256dip"
        android:layout_height="192dip"
        android:src="@drawable/qwer"
        simple:simple_tag_textSize="18sp"
        simple:simple_corner_distance="30dp"
        simple:simple_tag_text="AB"
        simple:simple_tag_background_color="#af27CDC0"
        simple:simple_tag_orientation="left_bottom"
        simple:simple_tag_width="20dip"
        simple:simple_tag_textColor="@android:color/white"
        simple:simple_tag_enable="true"
        simple:simple_tag_round_radius="20dp"/>

Quick Start

Gradle
compile 'net.wujingchao.android.view:simple-tag-imageview:1.0.0'
Maven
<dependency>
    <groupId>net.wujingchao.android.view</groupId>
    <artifactId>simple-tag-imageview</artifactId>
    <version>1.0.0</version>
    <type>aar</type>
</dependency> 
Ivy
<dependency org='simple-tag-imageview' name='net.wujingchao.android.view' rev='1.0.0'>
    <artifact name='net.wujingchao.android.view' ext='aar'></artifact>
</dependency>

Developed By

License

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.

转载于:https://www.cnblogs.com/eustoma/p/4472557.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值