Coder Social home page Coder Social logo

blurshape's Introduction

BlurShape

介绍

Android空间毛玻璃、磨砂、高斯模糊背景,带彩色边框,自定义shape

软件架构

给view添加磨砂背景drawable,自定义的shape

示例图片

安装教程

1、gradle集成
	//项目根目录的build.gradle中
	allprojects {
		repositories {
			...
			maven { url 'https://jitpack.io' }
		}
	}
	
	//app的build.gradle中
	dependencies {
	        implementation 'com.github.zcxshare:BlurShape:1.1'
	}
2、自行下载
获取blur_shape module的代码依赖即可,比较简单

使用说明

        val shape = BlurShape(clBg, tvContent).apply {//第一个参数是以该view为基础进行模糊处理,第二个是需要添加该背景view
            setStroke(DensityUtil.dp2px(3f).toFloat(),getColor(R.color.bg_treat_colours2))//添加边框线
            setRadius(DensityUtil.dp2px(10f).toFloat())//添加倒角
        }
        tvContent.background = ShapeDrawable(shape)

参与贡献

  1. Fork 本仓库
  2. 新建 Feat_xxx 分支
  3. 提交代码
  4. 新建 Pull Request

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.