Animating UILabel Font Size Change

前端 未结 9 2080
醉话见心
醉话见心 2020-11-30 21:31

I am currently making an application that uses a custom View Controller container. Multiple views are on the screen at one time and when one is tapped, the selected view con

9条回答
  •  谎友^
    谎友^ (楼主)
    2020-11-30 21:47

    Swift 3.0 & Swift 4.0

     UIView.animate(withDuration: 0.5, delay: 0.1, options: .curveLinear, animations: { 
    
        label.transform = label.transform.scaledBy(x:4,y:4) //Change x,y to get your desired effect. 
    
        } ) { (completed) in
    
             //Animation Completed      
    
        }
    

提交回复
热议问题