jj3341332/RoundImageView


仿淘宝购物车商品图的RoundImageView控件

Download


Step 1. Add the JitPack repository to your build file

Add it in your root settings.gradle at the end of repositories:

	dependencyResolutionManagement {
		repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
		repositories {
			mavenCentral()
			maven { url 'https://jitpack.io' }
		}
	}

Add it in your settings.gradle.kts at the end of repositories:

	dependencyResolutionManagement {
		repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
		repositories {
			mavenCentral()
			maven { url = uri("https://jitpack.io") }
		}
	}

Add to pom.xml

	<repositories>
		<repository>
		    <id>jitpack.io</id>
		    <url>https://jitpack.io</url>
		</repository>
	</repositories>

Add it in your build.sbt at the end of resolvers:

 
    resolvers += "jitpack" at "https://jitpack.io"
        
    

Add it in your project.clj at the end of repositories:

 
    :repositories [["jitpack" "https://jitpack.io"]]
        
    

Step 2. Add the dependency

	dependencies {
		implementation 'com.github.jj3341332:RoundImageView:1.0'
	}
	dependencies {
		implementation("com.github.jj3341332:RoundImageView:1.0")
	}
	<dependency>
	    <groupId>com.github.jj3341332</groupId>
	    <artifactId>RoundImageView</artifactId>
	    <version>1.0</version>
	</dependency>

                            
    libraryDependencies += "com.github.jj3341332" % "RoundImageView" % "1.0"
        
        

                            
    :dependencies [[com.github.jj3341332/RoundImageView "1.0"]]
        
        

Readme


Android RoundImageView控件


高仿淘宝的商品图 微信朋友圈个人头像 效果如下

image image

联系方式

image

如何使用?

第一步

在项目的build.gradle中添加如下代码

allprojects {
		repositories {
			...
			maven { url 'https://jitpack.io' }
		}
	}

##第二步 在模块的build.gradle中添加如下代码

dependencies {
	        compile 'com.github.jj3341332:RoundImageView:1.0'
	}

实例代码

<com.mrj.library.RoundImageView
    android:layout_marginTop="40dp"
    android:layout_gravity="center_horizontal"
    android:layout_width="150dp"
    android:layout_height="250dp"
    app:border_color="#ffffff"
    app:radius="10dp"
    app:border_width="10dp"
    app:border_alpha="255"
    app:shadow_color="#000"
    android:src="@mipmap/jieyi2"/>

Attributes属性说明

Attributes | format | describe ---|---|--- border_color | color | 边框颜色 radius | dimension | 圆角边框 border_width | dimension | 边框长度 border_alpha | integer | 边框颜色透明度 shadow_color | color | 阴影颜色