Questions tagged [uipinchgesturerecognizer]

UIPinchGestureRecognizer is a concrete subclass of UIGestureRecognizer that looks for pinching gestures involving two touches.

When the user moves the two fingers toward each other, the conventional meaning is zoom-out; when the user moves the two fingers away from each other, the conventional meaning is zoom-in.

Pinching is a continuous gesture. The gesture begins (UIGestureRecognizerStateBegan) when the two touches have moved enough to be considered a pinch gesture. The gesture changes (UIGestureRecognizerStateChanged) when a finger moves (with both fingers remaining pressed). The gesture ends (UIGestureRecognizerStateEnded) when both fingers lift from the view.

Whole document - UIPinchGestureRecognizer

248 questions
1
vote
1 answer

How to transition a gesture from a UIPinchGestureRecognizer handler to a UIPanGestureRecognizer handler?

I have a handler method for a UIPinchGestureRecognizer that is used to scale a view. What I'm trying to is to make it so that while two touches are on screen for the pinch gesture, and if a finger is lifted, the remaining finger would be managed by…
1
vote
1 answer

Zooming UIScrollView under UIView which receiving touches

There are two views. The first is an UIScrollView where the view to zoom is placed. The second is an UIView which can handle taps on it. Both views have gesture recognizers attached to them. The problem is that even all gesture recognizers are…
1
vote
1 answer

Pinching in and out from UICollectionView

So I have an UICollectionView and I want the user to be able to pinch out or in to either expand and collapse a collection cell. I used this tutorial to perform the expanding and collapsing bit. Which works. I then added the code below to my…
Souljacker
  • 774
  • 1
  • 13
  • 35
1
vote
0 answers

Issue in zoom out and in from iPad?

I have to tried zoom out and zoom in function in iPad, its working fine, but the zoom clarity is not good, I didn't know that, so how to make this? please help me. Thanks in Advance // This method will handle the PINCH / ZOOM gesture -…
1
vote
0 answers

UIImageView get blurry if i draw on it after having zoomed in

I have an UIImageView displaying a picture. I registered a pinch gesture to zoom in/out and a pan gesture to draw on it (I have a good reason to use the pan gesture for that, instead of touchMoved) Here is the pinch target: -…
1
vote
1 answer

Pinch recognizer crash

I am trying to detect the touches in a UIPinchGestureRecognizer's method, because I need both the horizontal and the vertical scale. On pinch, an image should be resized accordingly. For example if the user moves the fingers only horizontally, I am…
Levi
  • 7,313
  • 2
  • 32
  • 44
1
vote
1 answer

Zooming the whole screen with UIPinchGestureRecognizer

I was trying to add a pinch gesture zoom-in zoom-out feature to a UITextView and then I decided that adding a pinch gesture which zooms the whole screen, covering the whole view hierarchy is a better and more general solution. But I am confused…
Ufuk Can Bicici
  • 3,589
  • 4
  • 28
  • 57
1
vote
1 answer

Setting UIScrollView's origin for pinch gestures

I'm creating a scroll view for displaying a very large view, and I need both scroll and zoom functionality (just like an image viewer). Here are the steps that I've taken: In interface builder, I've put a scroll viewer to the view controller. I've…
1
vote
2 answers

Circular White Pinch Gesture Overlay commonly used for Blurring Images in iOS

I have implemented the ability to blur images in my iOS app using the pinch gesture, however I would like to implement a circular white overlay that is commonly used as a reference point with the pinch gesture so that the user can adjust the amount…
deadlock
  • 7,048
  • 14
  • 67
  • 115
1
vote
1 answer

Use UIPinchGestureRecognizer to scale layer

How would I use a UIPinchGestureRecognizer to scale a CALayer using a Transform (based off an existing transform, the current state of the layer)? - (IBAction)gesturePinch:(UIPinchGestureRecognizer *)sender { float scale = sender.scale; …
Marc
  • 1,541
  • 2
  • 19
  • 29
1
vote
1 answer

What selector does UIScrollView pinch gesture recognizer call?

I have a custom pinch gesture recognizer that I am replacing UIScrollView's pinch gesture recognizer with. Let's assume I want this pinch gesture recognizer to behave exactly 100% like UIScrollView's pinch gesture recognizer. Could I set the…
1
vote
1 answer

What steps do you need to take to translate UIPanGestureRecognizer touches to ScrollView zooming?

I am creating a gesture recognizer to handle zooming in a scroll view (scrolls along only one on axis at a time). I have the gesture recognizer working but I'm having trouble using the data from the gesture recognizer to transform my views properly.…
1
vote
0 answers

(iOS) Using UIGestureRecognizer to zoom and pan around a view

I'm trying to perform zooming and panning similar to the UIScrollView by using UIGestures. My view is drawn from a matrix of ON/OFF cells and needs to be able to support thousands of cells. The drawRect: method takes care of translating the matrix…
1
vote
4 answers

Weird crash while pinching UIScrollView

This issue has been driving me nuts for the past few hours. So I've got a very simple UIScrollView setup: -UIScrollView -UIImageView That's it. The scrollview and imageview are generated in Storyboard. Now all I want to do is to have the…
1
vote
2 answers

How to limit pinch out to the default view size

I am working on the pdf based application where I am trying to implement UIPinchGestureRecognizer.I want to limit the pinch off functionality when user reaches to the default view size with 640,960. In my current implementation user is able to…
maddy
  • 4,001
  • 8
  • 42
  • 65