I want to detect alert view when scratching particular area of image - ios

STScratchView : i have used this github demo for scratchView.
I cant find particular area of scratching image.
when i scratch particular area of image and then call event like alertview.
scratching image is display over UILabel.
now my problem is when i starting scratch the image and when display UILable text then automatically call event like alertview.
so please help me what can i do for that?

Related

Using single UIView I want to manage tap action based on location and update specific object

enter image description here
I am making app like sudoku (9*9 boxes) but it has only binary choices (on/off) and using button gave me horrible results. Can anyone give me demo version of 9*9 (or 3*3) box where depending upon the tap location, that specific box gets toggled (on/off)
You could create a custom subclass of UIView that had an attached tap gesture recognizer and interpreted the tap location to figure out which cell is being tapped, but it would be a lot of work.
It would be better to have custom view that contains a grid of buttons and set up the button actions to do what you want.
You said "...using button gave me horrible results." Can you elaborate? That should be a good way to go, so any "horrible results" are likely the result of something you did wrong, rather than that being the wrong way to go.

UIbutton highlight part of the image

I want to have a UIButton that has an image as the button itself, to have a nice highlight when pressed but not on the entire rectangle but on the object in the image (quite similar to what Twitter is doing on the status bar buttons)
I thought that making an image with the background as transparent will solve the problem, the thing is that on one it works, and on one it doesn't and they are exactly the same property wise.
So my general question:
What are the steps I need to do in order to get this done?

iOS Add Image to TextField

I am experimenting a little bit witch apps programming.
How I can add a UIImage to a UITextField"?
Like Whats App or the most other Chat Apps.
I have search some time but doesn't find a solution, also i have tried to search in side of XCode with the auto complete but I have not found a function. So I hope you can help me.
The easiest way to add an image to a text field is to have a UIView that contains both UITextField and a UIImageView as subviews.
Next up, you can have a UIButton with both an image and text, and just set userInteractionEnabled to "NO" and it'll behave like a text view with an image next to it.
Now to get more complicated, if you want a chat-like text field that allows text (that you can type into) and images next to each other, you need to start thinking about custom subclasses. Other people have asked and have gotten answers for this same approach.

How to make an Instagram-like error label

So, I have been banging my head against a wall trying to figure out a way to accomplish this. My goal is to have an error label that appears when a username/password is entered incorrectly, but I want something different than just unhiding a label with red text (which is what I currently have). If you use Instagram, I am trying to get a label to show up like when you enter your password correctly and the label gets pushed (slid) down from under the navigation bar.
So far I have tried creating a label programatically and moving it, but the label always starts under the navigation bar so it doesn't seem to "slide" like in Instagram. I have also tried to create a new VC with a clear background and just the label and present it with a segue but that didn't work either.
If anyone can let me know how this is done, I would be very grateful.
Thanks,
Brandon
Check out YRDropdownView. It is a library, with which you can easily create notifications very similar to those used by Instagram.
http://buildinternet.com/2012/02/yrdropdownview-a-polite-uialertview-alternative-for-ios/

send thumbnail image to another view for bigger image view

i have 3 images in my display where i use CoreData to store them images and to view them in the display. Now i would like to touch these images and it goes large in another view. Ive tried using touch events bt nothing seems to work. Can anyone assist me please
You can put a transparent UIButton over the image and declare a IBAction on the button and get the image according to button tag. Then pass the image to next controller.

Resources