Questions tagged «dropshadow»

13
Android View阴影
我四处搜寻,但找不到适合的方法。我希望对我的视图具有以下阴影效果: 老实说,我不知道第二个是否通过应用阴影效果来完成。有任何想法吗?

11
带有阴影的自定义ImageView
好的,我一直在阅读和搜索,现在我把头撞在墙上试图解决这个问题。这是我到目前为止的内容: package com.pockdroid.sandbox; import android.content.Context; import android.graphics.Canvas; import android.graphics.Color; import android.graphics.Paint; import android.graphics.Rect; import android.widget.ImageView; public class ShadowImageView extends ImageView { private Rect mRect; private Paint mPaint; public ShadowImageView(Context context) { super(context); mRect = new Rect(); mPaint = new Paint(); mPaint.setAntiAlias(true); mPaint.setShadowLayer(2f, 1f, 1f, Color.BLACK); } @Override protected void onDraw(Canvas …
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.