Questions tagged [uiviewanimation]

There is no default class called UIViewAnimation, this tag refers to methods that perform animation on UIView objects.

includes a number of different ways to perform animations. One of the simplest is to use the animation support in the UIView class.

Prior to iOS 4, the only way to do UIView animation was with beginAnimations:context/commitAnimations. Those methods are discouraged in iOS 4 and later.

For iOS versions greater than 4.0, you should use the new UIView class methods whose names start with animateWithDuration:

1798 questions
11
votes
1 answer

Having problem understanding CGPathAddArc

In an iPad application, I want to move a layer anti-clockwise along an arc which has a center point of (768, 512) and radius of 512. I want it to start at 12 o'clock (which is top right corner of the screen) and finish at 6 o'clock (bottom right…
leo
  • 1,011
  • 12
  • 25
11
votes
3 answers

Add subview later to animate alongside superview

I have a container view - let's call it socket view - that has a single subview, it's content view - let's call it plug view. This plug view can be nil, i.e. the socket view is currently empty. If it does contain a plug view, it is takes up the…
Christian Schnorr
  • 10,768
  • 8
  • 48
  • 83
11
votes
4 answers

iOS: a Complete 360 Degree-Rotation Using Block, Not CABasicAnimation

It should be something really simple, but I have not been successful in getting this to work using blocks. There are questions and answers to this, but all of them I found are solved by the use of CABasicAnimation and not by UIView Block-Based…
Unheilig
  • 16,196
  • 193
  • 68
  • 98
11
votes
3 answers

UIView animation with UIPanGestureRecognizer velocity way too fast (not decelerating)

Update: Though I'd still like to solve this, I ended up switching to animateWithDuration:delay:options:animations:completion: and it works much nicer. It's missing that nice "bounce" at the end that the spring affords, but at least it's…
devios1
  • 36,899
  • 45
  • 162
  • 260
11
votes
2 answers

How to add a circular mask to a UIImageview and change the frame and centers while doing so?

I would like to add a circular mask to UIImageVIew. Here is the function that am using to add the mask.. - (void) addMaskToBounds:(CGRect) maskBounds { CAShapeLayer *maskLayer = [[CAShapeLayer alloc] init]; CGPathRef maskPath =…
akshaynhegde
  • 1,938
  • 3
  • 17
  • 36
11
votes
4 answers

UIButton inside a UIView not working after UIView is animated

I have seen many questions in this forum which gives answer to this topic "UIButton inside a UIView, when animated doesn't work", but after having tried out the answers like a) UIViewAnimationOptionAllowUserInteraction to the options b)…
thandasoru
  • 1,558
  • 2
  • 15
  • 41
10
votes
3 answers

UIVIew animation - Scaling + Translating

I have a view which I want to be scaled and translated to a new location by animating it. I tried to achieve it with the following code: [UIView beginAnimations:nil context:nil]; [UIView setAnimationDuration:kDurationForFullScreenAnimation]; [[self…
Raj Pawan Gumdal
  • 7,390
  • 10
  • 60
  • 92
10
votes
3 answers

Custom ease in animateWithDuration?

When doing UIView.animateWithDuration, I would like to define a custom curve for the ease, as opposed to the default: .CurveEaseInOut, .CurveEaseIn, .CurveEaseOut, .CurveLinear. This is an example ease that I want applied to…
brandon koopa
  • 103
  • 1
  • 4
10
votes
2 answers

Animating an `inputView` Keyboard Transition

UITextField has an inputView property that can be used to specify a custom keyboard. Clearing this to nil provides the default keyboard. If the UITextField is the first responder, no change occurs on setting inputView, but by calling [textField…
Benjohn
  • 13,228
  • 9
  • 65
  • 127
10
votes
1 answer

UIVisualEffectView blur constraint animation bug

I'm having an issue expanding and contracting a UIEffectView. Its expands fine, but when it contracts it instantly snaps to its final height and slides into position, leaving behind a faint vibrancy effect in its wake. Heres a gif to illustrate…
Travis Beck
  • 1,128
  • 9
  • 21
10
votes
4 answers

How to Make a Secret iOS App Text Animation

I'm trying to duplicate the Secret App's Text Label transition. Does anyone the best way to approach it? It looks like they have each letter start out as clear text color and then animate it to gray and then white text color. Here are some…
NatashaTheRobot
  • 6,879
  • 4
  • 32
  • 27
10
votes
3 answers

Orientation without animation giving weird result when UIAlertView is present

I am facing a weird problem here. For some reason I am disabling the animation during orientation change in my view controller using [UIView setAnimationsEnabled:NO]; But when the alert view is present and if I change the orientation then it is…
10
votes
3 answers

iOS bringSubviewToFront blocking UIView animation

I have a ViewController with a bunch of UIImageViews that I need to send to the front and animate to the center of the view. I have tried to call bringSubviewToFront before casting the UIView animation and what seems to be happening is that the view…
Salvador Mosti
  • 171
  • 2
  • 5
10
votes
1 answer

Custom Segue Animation

I am trying to use a custom segue to perform a kind of zoom animation. When the transition is executed, the sourceViewController goes black, then the zoom occurs. Tried also to set the pushViewController: into the completion block but the…
Nimrod7
  • 1,425
  • 2
  • 17
  • 30
10
votes
4 answers

How do I create a smoothly resizable circular UIView?

I'm trying to create a UIView which shows a semitransparent circle with an opaque border inside its bounds. I want to be able to change the bounds in two ways - inside a -[UIView animateWithDuration:animations:] block and in a pinch gesture…
Simon
  • 25,468
  • 44
  • 152
  • 266