lopspower / Circleview
Licence: apache-2.0
Create circular view in android (change color, border & shadow) ⚫
Stars: ✭ 147
Labels
Projects that are alternatives of or similar to Circleview
Headerview
Create an header for com.google.android.material.navigation.NavigationView
Stars: ✭ 107 (-27.21%)
Mutual labels: customview
Flutter Shopping Airi
一款基于Flutter开发的购物App,涵盖了购物App的常见功能
Stars: ✭ 128 (-12.93%)
Mutual labels: customview
Statelayout
StateLayout is a simple-use Android layout library which handles Loading, Content and Error states
Stars: ✭ 88 (-40.14%)
Mutual labels: customview
Stepbarview
Step Bar View (make your own customized StepBar)
Stars: ✭ 97 (-34.01%)
Mutual labels: customview
Neumorphismview Android
A Neumorphism library for Android, supporting customizations for shadows/highlights to selected child views.
Stars: ✭ 121 (-17.69%)
Mutual labels: customview
Codeeditor
A cool code editor library on Android with syntax-highlighting and auto-completion.
Stars: ✭ 84 (-42.86%)
Mutual labels: customview
Simpleratingbar
SimpleRatingBar allows us to create a RatingBar with margin between items
Stars: ✭ 144 (-2.04%)
Mutual labels: customview
Tileprogressview
Simple Progress View with Tile Animation
Stars: ✭ 126 (-14.29%)
Mutual labels: customview
Crescento
Add curve at bottom of image views and relative layouts.
Stars: ✭ 1,289 (+776.87%)
Mutual labels: customview
Arcchartview
Arc Chart View (Draw Creative Statistic Arc Charts)
Stars: ✭ 96 (-34.69%)
Mutual labels: customview
Zigzagview
a zigzag view for using for ticket or invoice
Stars: ✭ 121 (-17.69%)
Mutual labels: customview
Androidnote
Android基础知识、Android进阶知识、Android自定义View相关、面试相关的知识,欢迎fork,star~
Stars: ✭ 1,279 (+770.07%)
Mutual labels: customview
Photoviewindicator
Indicator for PhotoView Library https://github.com/chrisbanes/PhotoView
Stars: ✭ 125 (-14.97%)
Mutual labels: customview
CircleView
This is an Android project allowing to realize a circular View in the simplest way possible. Finish the oval shapes of all colors in your projects.
USAGE
To make a circular View add CircleView in your layout XML and add CircleView library in your project or you can also grab it via Gradle:
implementation 'com.mikhaellopez:circleview:1.3.2'
XML
<com.mikhaellopez.circleview.CircleView
android:id="@+id/circleView"
android:layout_width="300dp"
android:layout_height="300dp"
app:cv_border="true"
app:cv_border_color="#000000"
app:cv_border_width="8dp"
app:cv_color="#3f51b5"
app:cv_shadow="true"
app:cv_shadow_color="#3f51b5"
app:cv_shadow_radius="10" />
You must use the following properties in your XML to change your CircleView.
Properties | Type | Default |
---|---|---|
app:cv_color |
color | WHITE |
app:cv_color_start |
color | cv_color |
app:cv_color_end |
color | cv_color |
app:cv_color_direction |
left_to_right, right_to_left, top_to_bottom or bottom_to_top | left_to_right |
app:cv_border |
boolean | false |
app:cv_border_width |
dimension | 4dp |
app:cv_border_color |
color | BLACK |
app:cv_border_color_start |
color | cv_border_color |
app:cv_border_color_end |
color | cv_border_color |
app:cv_border_color_direction |
left_to_right, right_to_left, top_to_bottom or bottom_to_top | left_to_right |
app:cv_shadow |
boolean | false |
app:cv_shadow_color |
color | BLACK |
app:cv_shadow_radius |
float | 8.0f |
app:cv_shadow_gravity |
center, top, bottom, start or end | bottom |
ℹ️ You can also use android:elevation
instead of app:cv_shadow
to have default Material Design elevation.
KOTLIN
val circleView = findViewById<CircleView>(R.id.circleView)
circleView.apply {
// Set Color
circleColor = Color.WHITE
// or with gradient
circleColorStart = Color.BLACK
circleColorEnd = Color.RED
circleColorDirection = CircleView.GradientDirection.TOP_TO_BOTTOM
// Set Border
borderWidth = 10f
borderColor = Color.BLACK
// or with gradient
borderColorStart = Color.BLACK
borderColorEnd = Color.RED
borderColorDirection = CircleView.GradientDirection.TOP_TO_BOTTOM
// Add Shadow with default param
shadowEnable = true
// or with custom param
shadowRadius = 15f
shadowColor = Color.RED
shadowGravity = CircleView.ShadowGravity.CENTER
}
JAVA
CircleView circleView = findViewById(R.id.circleView);
// Set Color
circleView.setCircleColor(Color.WHITE);
// or with gradient
circleView.setCircleColorStart(Color.BLACK);
circleView.setCircleColorEnd(Color.RED);
circleView.setCircleColorDirection(CircleView.GradientDirection.TOP_TO_BOTTOM);
// Set Border
circleView.setBorderWidth(10f);
circleView.setBorderColor(Color.BLACK);
// or with gradient
circleView.setBorderColorStart(Color.BLACK);
circleView.setBorderColorEnd(Color.RED);
circleView.setBorderColorDirection(CircleView.GradientDirection.TOP_TO_BOTTOM);
// Add Shadow with default param
circleView.setShadowEnable(true);
// or with custom param
circleView.setShadowRadius(15f);
circleView.setShadowColor(Color.RED);
circleView.setShadowGravity(CircleView.ShadowGravity.CENTER);
SUPPORT ❤️
Find this library useful? Support it by joining stargazers for this repository ⭐️
And follow me for my next creations 👍
LICENCE
CircleView by Lopez Mikhael is licensed under a Apache License 2.0.
Note that the project description data, including the texts, logos, images, and/or trademarks,
for each open source project belongs to its rightful owner.
If you wish to add or remove any projects, please contact us at [email protected].