I have a dynamically created list of labels and I am using GestureRecognizer for each of the labels to detect touches/click on them. I couldn’t use UIButton as I wanted to pass some text which is unique to each label to the touch event handler and UIButton would not allow text to be passed as userinfo. I cannot use UIButton.tag to pass the additional info.
Now I want the UIButton like glow effect on touch on my UIlabel. If there are other ways to notify a user that a label was touched, that work too. I was alo thinking of using some kind of quick animation or jiggling effect. Any ideas or workarounds?
Thanks in advance.
Why dont you create buttons programmatically and make the button type as custom. Like so –
Here we have defined what the button should look like
UIControlStateNormal. You can define what it should look like forUIControlStateHighlighted.What i want to say is that using uibuttons you can get what you need. Dont have to use uilabels.