File tree Expand file tree Collapse file tree 1 file changed +17
-8
lines changed Expand file tree Collapse file tree 1 file changed +17
-8
lines changed Original file line number Diff line number Diff line change 24
24
![ image] ( https://github.com/DingMouRen/PaletteImageView/raw/master/screenshot/p2.png )
25
25
##### 3.图片颜色主题解析
26
26
![ image] ( https://github.com/DingMouRen/PaletteImageView/raw/master/screenshot/p3.png )
27
- ## 使用
27
+ ### 使用
28
28
29
29
```
30
30
<com.dingmouren.paletteimageview.PaletteImageView
31
- android:id="@+id/palette2"
32
- android:layout_width="180dp"
33
- android:layout_height="180dp"
34
- app:cornerRadis="50dp"
35
- app:paletteSrc="@mipmap/yellow"
36
- />
31
+ android:id="@+id/palette"
32
+ android:layout_width="match_parent"
33
+ android:layout_height="wrap_content"
34
+ app:palettePadding="20dp"
35
+ app:paletteOffsetX="15dp"
36
+ app:paletteOffsetY="15dp"
37
+ />
37
38
```
39
+ ### xml属性
38
40
39
- 欢迎大家提Issues.
41
+ xml属性 | 描述
42
+ ---|---
43
+ app: palettePadding | 表示阴影显示最大空间距离。值为0,没有阴影,大于0,才有阴影。
44
+ app: paletteOffsetX | 表示阴影在x方向上的偏移量
45
+ app: paletteOffsetY | 表示阴影在y方向上的偏移量
46
+ app: paletteSrc | 表示图片资源
47
+ app: paletteRadius | 表示圆角半径
48
+ app: paletteShadowRadius | 表示阴影半径
40
49
41
50
## License
42
51
```
You can’t perform that action at this time.
0 commit comments