Making Glow effect to font

Go To StackoverFlow.com

0

I wonder if anybody have an example for Glow effect for font? I tried to look in NSAttributedString but I don't find in attribute for glowing text.

2012-04-05 23:15
by user836026
possible duplicate of Is there an easy way or library available to let text glow?jrturton 2012-06-02 14:15


2

Try this:

#include <Quartzcore/Quartzcore.h>
.......
yourLabel.layer.shadowColor = [[UIColor glowColor] CGColor]; //Replace glowColor with the desired color (redColor, greenColor, etc.)
yourLabel.layer.shadowOffset = CGSizeMake(0.0, 0.0); //The glow starts from the center

yourLabel.layer.shadowRadius = 20.0; //You can change this to the desired amount
yourLabel.layer.shadowOpacity = 0.5; //You can change this to the desired amount

yourLabel.layer.masksToBounds = NO; //Keep this the same to avoid shadow being clipped by the label bounds

Hope this helps!

2012-06-21 21:20
by pasawaya
Ads