开发者

Easy way to blur label

Need to create blurred shadow under UILabel. Same text but with blur and offset. Since NSShadow not supported in the iPhone SDK only way I see is Quartz render. Is there simpliest solution ? 开发者_开发技巧Thanks


I provide code to draw a shadow around a UILabel in my answer to this question. For an example of this in action, see the sample project I've created. A shadow of the same color as the text provides a nice blurring effect to the text in a label.


For 3.1 and below, no. You must use CoreGraphics.

For 3.2 and above, you can get the layer, and set the shadowRadius property.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜