본문 바로가기
[ios] Constraint animation 주기 [ios] Constraint animation 주기 -간단하다.self.someConstraint.constant = -10; // 0.25 는 CABasicAnimation 의 Default Animation 값[UIView animateWithDuration:0.25 animations:^{ [self layoutIfNeeded];}]; animatewithduration, animation, constant, constraint, constraint animation, layoutIfNeeded, [ios] Constraint animation 주기 2017. 12. 19.
[ios/tutorial] Implicit Animation 없이 property 값 바꾸기 [ios/tutorial] Implicit Animation 없이 property 값 바꾸기 -예를 들면 버튼의 text 를 바꿀 경우, 자연스럽게 글자가 fade out - fade in animation 이 먹는다.순간적으로 버튼의 text 를 바꿀 경우 이는 원하지 않는 동작일 수 있다. -다음 코드를 수행하면 implicit animation 없이 바로 작업을 수행할 수 있다.[UIView performWithoutAnimation:^{ [self.btn setTitle:btnText forState:UIControlStateNormal]; [self.btn layoutIfNeeded];}]; [ios/tutorial] Implicit Animation -> Layer Level 에 대한 이야기 .. 2017. 12. 13.
[ios] UIView 에 대한 이야기 [ios] UIView 에 대한 이야기 참조 : https://developer.apple.com/library/ios/documentation/UIKit/Reference/UIView_Class/ -UIView 는 다른 View 를 가질 수 있다. -보통 Subview 는 superView 의 bound 에 clip 되지 않지만 clipsToBounds property 를 사용하면 clip 시킬 수 있다. -view 의 geometry 는 frame, bounds, 그리고 center property 에 의해 결정된다.frame 은 superview 기준의 position 과 size 를 결정할 때 사용된다.center 는 size 변화 없이 position 변경할 때 사용된다.bounds 는 view.. 2017. 11. 10.
반응형