From a70200c1af882e38c81f15ecd1a7dcef6751b8ba Mon Sep 17 00:00:00 2001 From: Wasim Malek Date: Sun, 26 Jul 2020 20:06:27 +0530 Subject: [PATCH] resolve issue with Xcode stuck and pdf image --- .../UserInterfaceState.xcuserstate | Bin 28908 -> 37204 bytes .../open_now.imageset/Contents.json | 12 ++ .../open_now.imageset/open_now.pdf | Bin 0 -> 2789 bytes .../phone_number.imageset/Contents.json | 12 ++ .../phone_number.imageset/phone_number.pdf | Bin 0 -> 2813 bytes WMSegmentControl/Base.lproj/Main.storyboard | 24 +-- WMSegmentControl/Source/WMSegment.swift | 201 +++++------------- 7 files changed, 88 insertions(+), 161 deletions(-) create mode 100644 WMSegmentControl/Assets.xcassets/open_now.imageset/Contents.json create mode 100644 WMSegmentControl/Assets.xcassets/open_now.imageset/open_now.pdf create mode 100644 WMSegmentControl/Assets.xcassets/phone_number.imageset/Contents.json create mode 100644 WMSegmentControl/Assets.xcassets/phone_number.imageset/phone_number.pdf diff --git a/WMSegmentControl.xcodeproj/project.xcworkspace/xcuserdata/wasim.xcuserdatad/UserInterfaceState.xcuserstate b/WMSegmentControl.xcodeproj/project.xcworkspace/xcuserdata/wasim.xcuserdatad/UserInterfaceState.xcuserstate index 4fd646a4754fe9b41117469dca62be9e435196f0..96c328ab08b1b9bd344993254d90d97b967668c2 100644 GIT binary patch literal 37204 zcmeFa2Ygh;_BeiLZr#*Pmh`p|Lh2@)?4}1u*)&Rk6iO&@NjAws8k>YFdM^S>Q9%#^ zQAp^Bq9ENu6_p}gMMV^mA}SWd&hO0L-4sBc@BQBQ{l5Rt|0SPf@7`%=X3m^BZO)8t zs4+J-X|<;*L}7}i7>cDhil-cgb{}uDG@9${hIKbu%B#)rt+;zreZ$c1^`pm_%9|S9 zDKv9MnbNhOsIO^~sUpLc=>#QEijtxxW0Oflo80hT%8_!Sd?;VakMgIYsTfL2#ZqyU zj?z={R07q9>Pz*b`cnne0BRsLh$^Its50sS%1Di-%BgXbg=(alsAg(B^&mBs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Sxv>qhD(>!#^u=w|8W>gMU1bj`YDx=(ap z>Ne@V(rwjk*L|nEru$uYS9f3cQV;dC-bF9a3-z9QZ+)abQ*YH5>ig+S_2v3Xn|`8x zuKs=f0{ut&CHkfMjrwi+J^Fq6gZd--WBN<_U-Z}YH}p64_w^6;kM&RVPYtwzZ}2dP z3|y9!M4q?!?4q^+pyQL-*Cuq)NtHz(s0^vGmoE_ke88Hn>QwJ zcHV}(U3tG538UDUV9YY+8udn_(PGRumKm#z)y7)m5aU?mMB`-RRO58xT;n|BeB+14 zkBrNWUl_kKeq;RBxZU`@ai8&k@v!lz@vQNh@w)L><8Q{7Cc;G8Oti_xSZc2 zm6*y+{Y?W+HKrk^2GcOpNYfY-GL1J)G|ecPByXC&+q2;;dm6fmtSwpP~tJ12r zYOFEV_STNp3~RPkXEj(&R*SX7I?!5U9b&UKSch3hSSMMhTBlpzv#zjiux_?~W&Osw z&w9Xm$a=(j!Ft(x#rm`LaX!c=^XYtEe*64{{IvXx{H*+(d|iHie&76l`6c;f`4#!K z`E~gX`9t$R&p(iVIsaDvqx?Ve|IGg@|78JF;99^h@F?&s@GfXq(4ioyAfq6=Kv!VP zD=-%n7nBy17gQEh6$~txTCk$vK*805dj$^*{wR1_@K?c$LQ!GcLRn!*VOU{AVPs+Z z!uZ0jg*^%r3bP9H3QdKU!u-OL!m`4O!v2K=3WpVrEkuRm3MUj!FMO|XR^gmNd*PxI Wua>+QIzM?WSMUj(>pET~KK}!ZapzzF diff --git a/WMSegmentControl/Assets.xcassets/open_now.imageset/Contents.json b/WMSegmentControl/Assets.xcassets/open_now.imageset/Contents.json new file mode 100644 index 0000000..263e8c5 --- /dev/null +++ b/WMSegmentControl/Assets.xcassets/open_now.imageset/Contents.json @@ -0,0 +1,12 @@ +{ + "images" : [ + { + "filename" : "open_now.pdf", + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/WMSegmentControl/Assets.xcassets/open_now.imageset/open_now.pdf b/WMSegmentControl/Assets.xcassets/open_now.imageset/open_now.pdf new file mode 100644 index 0000000000000000000000000000000000000000..f4501065b7c7ffd57ebc2b73e8b062a9a06faf7c GIT binary patch literal 2789 zcmb_eeQXnD7zbenD-(sO6aMg09P2FC_wIVV(ylA6A18x#%yzIvhU0qowmWvct9RF| zn;`;|=#Uuv2q8uyAx6Rgyj}ZM6ET51h8U9A|gGrXPA`<&)8^q^>VXNXKyA>oaN z*t{Y7S7+_i^|Tj&?(S|!x6`4hNkDo$9zallqHtt^Ydx~gWpPHlR%-!ADjkUwH;^@liORt%DUjvTfOHTbl`4VD#bT`SHprUJ$vkWb`7;?& z@Dfy*VqJt257fJ9Jj@12+!-KQoC%Qu#>qNamy`7Y#KPpYCOw8*gCuh@r0|&(l=XsR zHyv~2qi=s&W z$q7ASe?>Ltr>-sJ!fipw=Z$Gwbo4)&M}_0Y%%cf(Go4eeB^vb>N`wCfm0?<8sPTbG zYwjR!l-~KAos?2&yX=jTXTAAK>^BRsiL5ksr;rJJ5m!2+N@gVycmO46B%FqzkyA(& zc&~2M{Zh`DnQCNIy`)bb&F7OO8nwkMadNWGn#Bc};4+eK_5T;)$lV}GoV-zPbjtod zFdgenFJNv0RoR?llnjOX?6;JvJd%t$t7_D6^fp;l4b8}@D&;9k3t5sDQ%!r5nBG^%H^%f7Xu@dJtEifeQAA0qvS*wz zVvJft42)4x;{7qIg`k-W1BXBFK4^P(o}*!DL)pODzVeF32j^C7y|j78@Vo;{SA=b! z&HF8~bmXhwKN(#W9=`jrcl%!2_vMlKWx<_mH(k7TWIpy@+tBP&b3-W%ZAWs7$*dl%05@p zB8i251@&V$i@Yrg6QFe+iBTA}9>m06h>Ot5ZOfDKSVf(p7B#^rW-JpNl-tVf-W(F8VgYDz=cf{K($$r|PY%_9zH)Kn)Ps?!Idm_HLKm zz4TfH8!$nBOt3*DAx#V@1|u4pkPvAE62+P#e<6*aXc2-W5{ZI8BuIR_y`TPoV5GV9 z-o2SOZ{~Y5^G!(|7sg44$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entControl/Base.lproj/Main.storyboard b/WMSegmentControl/Base.lproj/Main.storyboard index e626f55..eb6692c 100644 --- a/WMSegmentControl/Base.lproj/Main.storyboard +++ b/WMSegmentControl/Base.lproj/Main.storyboard @@ -1,11 +1,9 @@ - - - - + + - + @@ -21,7 +19,7 @@ - + @@ -88,7 +86,7 @@ - + @@ -145,7 +143,7 @@ - + @@ -203,7 +201,7 @@ - + @@ -225,7 +223,7 @@ - + @@ -262,7 +260,7 @@ - + @@ -321,7 +319,7 @@ - + @@ -407,7 +405,7 @@ - + diff --git a/WMSegmentControl/Source/WMSegment.swift b/WMSegmentControl/Source/WMSegment.swift index fb4986c..6f524e3 100644 --- a/WMSegmentControl/Source/WMSegment.swift +++ b/WMSegmentControl/Source/WMSegment.swift @@ -9,93 +9,64 @@ import UIKit @IBDesignable open class WMSegment: UIControl { - public var onValueChanged: ((_ index: Int)->())? var buttons = [UIButton]() var selector: UIView! public var selectedSegmentIndex: Int = 0 - - public var type: SegmentType = .normal { + + public var type: SegementType = .normal { didSet { updateView() } } - @available(*, unavailable, message: "This property is reserved for Interface Builder. Use 'selectorType' instead.") - @IBInspectable var typeNum: Int = 0 { - willSet { - // Ensure user enters a valid value - // Ignore input if not valid. - if let newType = SegmentType(rawValue: newValue) { - type = newType - } - } - } - + public var selectorType: SelectorType = .normal { didSet { updateView() } } - @available(*, unavailable, message: "This property is reserved for Interface Builder. Use 'selectorType' instead.") - @IBInspectable var selectorTypeNum: Int = 0 { - willSet { - // Ensure user enters a valid value - // Ignore input if not valid. - if let newSelectorType = SelectorType(rawValue: newValue) { - selectorType = newSelectorType - } - } - } - + @IBInspectable public var borderWidth: CGFloat = 0 { didSet { layer.borderWidth = borderWidth } } - + @IBInspectable public var borderColor: UIColor = .clear { didSet { layer.borderColor = borderColor.cgColor } } - + @IBInspectable public var cornerRadius: CGFloat = 0 { didSet { layer.cornerRadius = cornerRadius } } - @IBInspectable public var buttonTitles: String = ""{ didSet { updateView() } } - + @IBInspectable public var buttonImages: String = ""{ didSet { updateView() } } - - @IBInspectable - public var buttonSelectedImages: String = ""{ - didSet { - updateView() - } - } - + @IBInspectable public var textColor: UIColor = .lightGray { didSet { updateView() } } - + @IBInspectable public var selectorTextColor: UIColor = .white { didSet { @@ -108,65 +79,43 @@ open class WMSegment: UIControl { updateView() } } - + @IBInspectable public var isRounded: Bool = false { didSet { if self.isRounded == true { - if roundedRadius == 0 { - layer.cornerRadius = frame.height/2 - } - else { - layer.cornerRadius = roundedRadius - } + layer.cornerRadius = frame.height/2 } updateView() } } - - @IBInspectable - public var roundedRadius: CGFloat = 0 { // default 0 gir full bue - didSet { - if self.isRounded == true { - if roundedRadius == 0 { - layer.cornerRadius = frame.height/2 - } - else { - layer.cornerRadius = roundedRadius - } - } - updateView() - } - } - + @IBInspectable public var bottomBarHeight : CGFloat = 5.0 { didSet { updateView() } } - + public var normalFont : UIFont = UIFont.systemFont(ofSize: 15) { didSet { updateView() } } - + public var SelectedFont : UIFont = UIFont.systemFont(ofSize: 15) { didSet { updateView() } } - + public var animate: Bool = true - let bundle = Bundle(for: WMSegment.self) // for making images show in interface uilder - + func updateView() { - self.clipsToBounds = true buttons.removeAll() subviews.forEach({$0.removeFromSuperview()}) - + if self.type == .normal { buttons = getButtonsForNormalSegment() } else if self.type == .imageOnTop { @@ -174,11 +123,9 @@ open class WMSegment: UIControl { } else if self.type == .onlyImage { buttons = getButtonsForOnlyImageSegment() } - + if selectedSegmentIndex < buttons.count { - if buttonSelectedImages.count == 0 { - buttons[selectedSegmentIndex].tintColor = selectorTextColor - } + buttons[selectedSegmentIndex].tintColor = selectorTextColor buttons[selectedSegmentIndex].setTitleColor(selectorTextColor, for: .normal) buttons[selectedSegmentIndex].titleLabel?.font = SelectedFont } @@ -190,31 +137,27 @@ open class WMSegment: UIControl { sv.distribution = .fillEqually//.fillProportionally addSubview(sv) sv.translatesAutoresizingMaskIntoConstraints = false - + sv.topAnchor.constraint(equalTo: self.topAnchor).isActive = true sv.bottomAnchor.constraint(equalTo: self.bottomAnchor).isActive = true sv.leftAnchor.constraint(equalTo: self.leftAnchor).isActive = true sv.rightAnchor.constraint(equalTo: self.rightAnchor).isActive = true } - + func setupSelector() { - + let titles = buttonTitles.components(separatedBy: ",") let images = buttonImages.components(separatedBy: ",") var selectorWidth = frame.width / CGFloat(titles.count) if self.type == .onlyImage { selectorWidth = frame.width / CGFloat(images.count) } - + + if selectorType == .normal { selector = UIView(frame: CGRect(x: 0, y: 0, width: selectorWidth, height: frame.height)) if isRounded { - if roundedRadius == 0 { - selector.layer.cornerRadius = frame.height / 2 - } - else { - selector.layer.cornerRadius = roundedRadius - } + selector.layer.cornerRadius = frame.height / 2 } else { selector.layer.cornerRadius = 0 } @@ -222,10 +165,10 @@ open class WMSegment: UIControl { selector = UIView(frame: CGRect(x: 0, y: frame.height - bottomBarHeight, width: selectorWidth, height: bottomBarHeight)) selector.layer.cornerRadius = 0 } - + selector.backgroundColor = selectorColor } - + //MARK : Get Button as per segment type func getButtonsForNormalSegment(_ isImageTop: Bool = false) -> [UIButton] { var btn = [UIButton]() @@ -235,9 +178,7 @@ open class WMSegment: UIControl { let button = UIButton(type: .system) button.setTitle(buttonTitle, for: .normal) button.tag = index - if buttonSelectedImages.count == 0 { - button.tintColor = textColor - } + button.tintColor = textColor button.setTitleColor(textColor, for: .normal) button.titleLabel?.font = normalFont button.titleLabel?.textAlignment = .center @@ -245,42 +186,36 @@ open class WMSegment: UIControl { btn.append(button) if index < images.count { if images[index] != ""{ - button.setImage(UIImage(named: images[index], in: bundle, compatibleWith: nil), for: .normal) - if buttonSelectedImages.count != 0 { - button.setImage(UIImage(named: images[index], in: bundle, compatibleWith: nil)?.withRenderingMode(.alwaysOriginal), for: .normal) - } + button.setImage(UIImage(named: images[index]), for: .normal) if isImageTop == false { button.imageEdgeInsets = UIEdgeInsets(top: 0, left: 0, bottom: 0, right: 10) } else { button.centerImageAndButton(5, imageOnTop: true) } } + + } } - + return btn } - + func getButtonsForOnlyImageSegment() -> [UIButton] { var btn = [UIButton]() let images = buttonImages.components(separatedBy: ",") for (index, buttonImage) in images.enumerated() { let button = UIButton(type: .system) - button.setImage(UIImage(named: buttonImage, in: bundle, compatibleWith: nil), for: .normal) - if buttonSelectedImages.count != 0 { - button.setImage(UIImage(named: buttonImage, in: bundle, compatibleWith: nil)?.withRenderingMode(.alwaysOriginal), for: .normal) - } + button.setImage(UIImage(named: buttonImage), for: .normal) button.tag = index - if buttonSelectedImages.count == 0 { - button.tintColor = textColor - } + button.tintColor = textColor button.addTarget(self, action: #selector(buttonTapped(_:)), for: .touchUpInside) btn.append(button) - + } return btn } - + open override func layoutSubviews() { super.layoutSubviews() updateView() @@ -289,14 +224,11 @@ open class WMSegment: UIControl { setSelectedIndex(self.selectedSegmentIndex) self.animate = _animated } - + @objc func buttonTapped(_ sender: UIButton) { - let images = buttonImages.components(separatedBy: ",") - let selectedImages = buttonSelectedImages.components(separatedBy: ",") + for (buttonIndex, btn) in buttons.enumerated() { - if buttonSelectedImages.count == 0 { - btn.tintColor = textColor - } + btn.tintColor = textColor btn.setTitleColor(textColor, for: .normal) btn.titleLabel?.font = normalFont if btn == sender { @@ -310,22 +242,9 @@ open class WMSegment: UIControl { self.selector.frame.origin.x = startPosition } btn.titleLabel?.font = SelectedFont - if buttonSelectedImages.count == 0 { - btn.tintColor = selectorTextColor - } + btn.tintColor = selectorTextColor btn.setTitleColor(selectorTextColor, for: .normal) } - if buttonIndex < images.count && images[buttonIndex] != ""{ - btn.setImage(UIImage(named: images[buttonIndex], in: bundle, compatibleWith: nil), for: .normal) - if buttonSelectedImages.count != 0 { - btn.setImage(UIImage(named: images[buttonIndex], in: bundle, compatibleWith: nil)?.withRenderingMode(.alwaysOriginal), for: .normal) - } - } - } - - if selectedSegmentIndex < selectedImages.count && selectedImages[selectedSegmentIndex] != "" { - let img = UIImage(named: selectedImages[selectedSegmentIndex], in: bundle, compatibleWith: nil)?.withRenderingMode(.alwaysOriginal) - buttons[selectedSegmentIndex].setImage(img, for: .normal) } onValueChanged?(selectedSegmentIndex) sendActions(for: .valueChanged) @@ -333,11 +252,9 @@ open class WMSegment: UIControl { //MARK: set Selected Index open func setSelectedIndex(_ index: Int) { for (buttonIndex, btn) in buttons.enumerated() { - if buttonSelectedImages.count == 0 { - btn.tintColor = textColor - } + btn.tintColor = textColor btn.setTitleColor(textColor, for: .normal) - + if btn.tag == index { selectedSegmentIndex = buttonIndex let startPosition = frame.width/CGFloat(buttons.count) * CGFloat(buttonIndex) @@ -348,51 +265,39 @@ open class WMSegment: UIControl { }else{ self.selector.frame.origin.x = startPosition } - if buttonSelectedImages.count == 0 { - btn.tintColor = selectorTextColor - } + + btn.tintColor = selectorTextColor btn.setTitleColor(selectorTextColor, for: .normal) } } - let selectedImages = buttonSelectedImages.components(separatedBy: ",") - if selectedSegmentIndex < selectedImages.count && selectedImages[selectedSegmentIndex] != "" { - let img = UIImage(named: selectedImages[selectedSegmentIndex], in: bundle, compatibleWith: nil)?.withRenderingMode(.alwaysOriginal) - buttons[selectedSegmentIndex].setImage(img, for: .normal) - } } - + //MARK: chage Selector Color open func changeSelectedColor(_ color: UIColor) { self.selector.backgroundColor = color } - - open override func prepareForInterfaceBuilder() { - super.prepareForInterfaceBuilder() - updateView() - } - + } - -//MARK: UIButton Extension +//MARK: UIbutton Extesion extension UIButton { func centerImageAndButton(_ gap: CGFloat, imageOnTop: Bool) { - + guard let imageView = self.currentImage, let titleLabel = self.titleLabel?.text else { return } - + let sign: CGFloat = imageOnTop ? 1 : -1 self.titleEdgeInsets = UIEdgeInsets(top: (imageView.size.height + gap) * sign, left: -imageView.size.width, bottom: 0, right: 0); - + let titleSize = titleLabel.size(withAttributes:[NSAttributedString.Key.font: self.titleLabel!.font!]) self.imageEdgeInsets = UIEdgeInsets(top: -(titleSize.height + gap) * sign, left: 0, bottom: 0, right: -titleSize.width) } } - //MARK: Enums -public enum SegmentType: Int { +public enum SegementType: Int { case normal = 0, imageOnTop, onlyImage } public enum SelectorType: Int { case normal = 0, bottomBar } +