Programing Language
-
iOS ) uiView 에니메이션써서 높이 늘리기 programmaticallyPrograming Language/iOS(Swift) 2019. 12. 24. 16:29
참고코드
-
iOS ) UITabBarController 페이지 Programmatically 만들기 swiftPrograming Language/iOS(Swift) 2019. 12. 5. 08:49
1. viewdidLoad에 generateNavController 메서드 호출 override func viewDidLoad() { super.viewDidLoad() itembar_height = Int(view.frame.height * 0.1) view.backgroundColor = .white //블랙모드 방지 overrideUserInterfaceStyle = .light //tabBar.barTintColor = .blue let nav = generateNavController(vc: ViewController(), title: "1", image: #imageLiteral(resourceName: "unselected_image"), image_selected: #imageLiteral..
-
iOS ) CollectionView에 수평 스크롤 넣기 Programmatically (horizon) - swiftPrograming Language/iOS(Swift) 2019. 11. 29. 01:58
예제 코드 let collectionView = UICollectionView() let layout = UICollectionViewFlowLayout() layout.scrollDirection = .horizontal self.collectionView.collectionViewLayout = layout self.collectionView.pagingEnabled = YES;
-
iOS) Scrollview Programmatically (코드로 작성)Programing Language/iOS(Swift) 2019. 11. 28. 20:31
예제 코드~ let scrollview : UIScrollView = { let sv = UIScrollView() sv.translatesAutoresizingMaskIntoConstraints = false //sv.backgroundColor = .black sv.isPagingEnabled = true //이걸해야지 한번 슬라이드할때마다 다음 화면으로 획 넘어감 return sv }() var images : [UIImage] = [#imageLiteral(resourceName: "IMG_0058"),#imageLiteral(resourceName: "IMG_0058"),#imageLiteral(resourceName: "IMG_0058")] //scrollview 크기조절은 내키는데로~~ fu..