forked from sshadkany/Android_neumorphic
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathactivity_polygon_button.xml
38 lines (31 loc) · 1.48 KB
/
activity_polygon_button.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/backgroundLayout"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".PolygonButtonActivity">
<!-- if you do not like basin effect -> remove below polygonView and use only polygonButton -->
<com.github.sshadkany.shapes.PolygonView
android:layout_width="match_parent"
android:layout_height="match_parent"
app:shape_polygon_shadow_type="drop_shadow"
app:shape_polygon_side="4">
<com.github.sshadkany.PolygonButton
android:id="@+id/polygon_button"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_margin="2dp"
app:shape_polygon_side="4">
<ImageView
android:id="@+id/imageView3"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="center"
android:padding="60dp"
android:tint="#000000"
app:srcCompat="@drawable/abc_vector_test" />
</com.github.sshadkany.PolygonButton>
</com.github.sshadkany.shapes.PolygonView>
</androidx.constraintlayout.widget.ConstraintLayout>