├── .swift-version
├── FontGenerator
├── README.md
├── .gitignore
├── font.rb
├── templates
│ └── font_list.erb
├── icons
│ ├── iconic.rb
│ ├── themify.rb
│ ├── octicons.rb
│ ├── map_icons.rb
│ ├── ion_icons.rb
│ ├── font_awesome.rb
│ └── material_icons.rb
├── runner.rb
└── font_generator.rb
├── Example
├── .gitignore
├── Podfile
├── Example
│ ├── Assets.xcassets
│ │ ├── Contents.json
│ │ └── AppIcon.appiconset
│ │ │ └── Contents.json
│ ├── AppDelegate.swift
│ ├── Base.lproj
│ │ ├── LaunchScreen.storyboard
│ │ └── Main.storyboard
│ ├── Info.plist
│ ├── SceneDelegate.swift
│ └── ViewController.swift
├── Example.xcodeproj
│ ├── project.xcworkspace
│ │ ├── contents.xcworkspacedata
│ │ └── xcshareddata
│ │ │ └── IDEWorkspaceChecks.plist
│ └── xcuserdata
│ │ └── sdev.xcuserdatad
│ │ └── xcschemes
│ │ └── xcschememanagement.plist
└── Example.xcworkspace
│ ├── xcuserdata
│ └── sdev.xcuserdatad
│ │ └── xcdebugger
│ │ └── Breakpoints_v2.xcbkptlist
│ ├── contents.xcworkspacedata
│ └── xcshareddata
│ └── IDEWorkspaceChecks.plist
├── ExampleMac
├── .gitignore
├── Podfile
├── ExampleMac
│ ├── Assets.xcassets
│ │ ├── Contents.json
│ │ └── AppIcon.appiconset
│ │ │ └── Contents.json
│ ├── ExampleMac.entitlements
│ ├── AppDelegate.swift
│ ├── ViewController.swift
│ └── Info.plist
├── ExampleMac.xcodeproj
│ ├── project.xcworkspace
│ │ ├── contents.xcworkspacedata
│ │ └── xcshareddata
│ │ │ └── IDEWorkspaceChecks.plist
│ ├── xcuserdata
│ │ └── sdev.xcuserdatad
│ │ │ └── xcschemes
│ │ │ └── xcschememanagement.plist
│ └── project.pbxproj
└── ExampleMac.xcworkspace
│ ├── xcuserdata
│ └── sdev.xcuserdatad
│ │ └── xcdebugger
│ │ └── Breakpoints_v2.xcbkptlist
│ ├── contents.xcworkspacedata
│ └── xcshareddata
│ └── IDEWorkspaceChecks.plist
├── Assets
├── logo.png
├── example1.png
└── storyboard-t.gif
├── .github
└── FUNDING.yml
├── .gitmodules
├── SwiftIconFont
├── Resources
│ ├── themify.ttf
│ ├── Ionicons.ttf
│ ├── fontcustom.ttf
│ ├── map-icons.ttf
│ ├── octicons.ttf
│ ├── ElegantIcons.ttf
│ ├── captainicon.ttf
│ ├── open-iconic.ttf
│ ├── SegoeMDL2Assets.ttf
│ ├── FontAwesome5Free-Solid.ttf
│ ├── MaterialIcons-Regular.ttf
│ ├── FontAwesome5Free-Regular.ttf
│ └── FontAwesome5Brands-Regular.ttf
├── Classes
│ ├── Shared
│ │ ├── Types.swift
│ │ ├── SwiftIconFont+NSRange.swift
│ │ ├── FontLoader.swift
│ │ ├── SwiftIconFont+String.swift
│ │ ├── Fonts
│ │ │ ├── Octicon.swift
│ │ │ ├── Iconic.swift
│ │ │ ├── MapIcon.swift
│ │ │ ├── Foundation.swift
│ │ │ ├── Captain.swift
│ │ │ ├── ThemifyIcon.swift
│ │ │ └── ElegantIcon.swift
│ │ └── SwiftIconFont.swift
│ ├── UIKit
│ │ ├── SwiftIconFont+UITextView.swift
│ │ ├── SwiftIconFont+UILabel.swift
│ │ ├── SwiftIconLabel.swift
│ │ ├── SwiftIconTextView.swift
│ │ ├── SwiftIconButton.swift
│ │ ├── SwiftIconFont+UIImageView.swift
│ │ ├── SwiftIconBarButtonItem.swift
│ │ ├── SwiftIconFont+UITextField.swift
│ │ ├── SwiftIconFont+UIButton.swift
│ │ ├── SwiftIconImageView.swift
│ │ ├── SwiftIconFont+UIBarButtonItem.swift
│ │ ├── SwiftIconFont+UITabBarItem.swift
│ │ ├── SwiftIconStepper.swift
│ │ ├── SwiftIconTabBarItem.swift
│ │ ├── SwiftIconFontView.swift
│ │ ├── SwiftIconFont+UIImage.swift
│ │ └── SwiftIconTextField.swift
│ └── AppKit
│ │ ├── SwiftIconFont+NSTextField.swift
│ │ ├── SwiftIconFont+NSButton.swift
│ │ ├── SwiftIconFontNSView.swift
│ │ └── SwiftIconFont+NSImage.swift
├── SwiftIconFont.h
└── Info.plist
├── SwiftIconFont.xcodeproj
├── xcuserdata
│ ├── sdev.xcuserdatad
│ │ └── xcdebugger
│ │ │ └── Breakpoints_v2.xcbkptlist
│ └── sgc.xcuserdatad
│ │ └── xcschemes
│ │ └── xcschememanagement.plist
├── project.xcworkspace
│ ├── contents.xcworkspacedata
│ ├── xcuserdata
│ │ └── sgc.xcuserdatad
│ │ │ └── UserInterfaceState.xcuserstate
│ └── xcshareddata
│ │ └── IDEWorkspaceChecks.plist
└── xcshareddata
│ └── xcschemes
│ └── SwiftIconFont.xcscheme
├── .gitignore
├── SwiftIconFontTests
├── Info.plist
└── SwiftIconFontTests.swift
├── SwiftIconFont.podspec
├── LICENSE
├── .travis.yml
├── CHANGELOG.md
└── README.md
/.swift-version:
--------------------------------------------------------------------------------
1 | 5.0
2 |
--------------------------------------------------------------------------------
/FontGenerator/README.md:
--------------------------------------------------------------------------------
1 | ### IN DEV.
--------------------------------------------------------------------------------
/Example/.gitignore:
--------------------------------------------------------------------------------
1 | /Pods
2 | Podfile.lock
3 |
--------------------------------------------------------------------------------
/ExampleMac/.gitignore:
--------------------------------------------------------------------------------
1 | /Pods
2 | Podfile.lock
3 |
--------------------------------------------------------------------------------
/FontGenerator/.gitignore:
--------------------------------------------------------------------------------
1 | generated/*
2 | .idea/
--------------------------------------------------------------------------------
/Assets/logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/Assets/logo.png
--------------------------------------------------------------------------------
/.github/FUNDING.yml:
--------------------------------------------------------------------------------
1 | # These are supported funding model platforms
2 |
3 | github: [segecey]
4 |
--------------------------------------------------------------------------------
/Assets/example1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/Assets/example1.png
--------------------------------------------------------------------------------
/Assets/storyboard-t.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/Assets/storyboard-t.gif
--------------------------------------------------------------------------------
/.gitmodules:
--------------------------------------------------------------------------------
1 | [submodule "IconFontCss"]
2 | path = IconFontCss
3 | url = https://github.com/0x73/IconFontCss.git
4 |
--------------------------------------------------------------------------------
/Example/Podfile:
--------------------------------------------------------------------------------
1 | target 'Example' do
2 | use_frameworks!
3 | pod 'SwiftIconFont', :path => '../'
4 | end
5 |
--------------------------------------------------------------------------------
/ExampleMac/Podfile:
--------------------------------------------------------------------------------
1 | target 'ExampleMac' do
2 | use_frameworks!
3 | pod 'SwiftIconFont', :path => '../'
4 | end
5 |
--------------------------------------------------------------------------------
/SwiftIconFont/Resources/themify.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/SwiftIconFont/Resources/themify.ttf
--------------------------------------------------------------------------------
/Example/Example/Assets.xcassets/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "info" : {
3 | "author" : "xcode",
4 | "version" : 1
5 | }
6 | }
7 |
--------------------------------------------------------------------------------
/SwiftIconFont/Resources/Ionicons.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/SwiftIconFont/Resources/Ionicons.ttf
--------------------------------------------------------------------------------
/SwiftIconFont/Resources/fontcustom.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/SwiftIconFont/Resources/fontcustom.ttf
--------------------------------------------------------------------------------
/SwiftIconFont/Resources/map-icons.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/SwiftIconFont/Resources/map-icons.ttf
--------------------------------------------------------------------------------
/SwiftIconFont/Resources/octicons.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/SwiftIconFont/Resources/octicons.ttf
--------------------------------------------------------------------------------
/ExampleMac/ExampleMac/Assets.xcassets/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "info" : {
3 | "author" : "xcode",
4 | "version" : 1
5 | }
6 | }
7 |
--------------------------------------------------------------------------------
/SwiftIconFont/Resources/ElegantIcons.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/SwiftIconFont/Resources/ElegantIcons.ttf
--------------------------------------------------------------------------------
/SwiftIconFont/Resources/captainicon.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/SwiftIconFont/Resources/captainicon.ttf
--------------------------------------------------------------------------------
/SwiftIconFont/Resources/open-iconic.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/SwiftIconFont/Resources/open-iconic.ttf
--------------------------------------------------------------------------------
/SwiftIconFont/Resources/SegoeMDL2Assets.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/SwiftIconFont/Resources/SegoeMDL2Assets.ttf
--------------------------------------------------------------------------------
/SwiftIconFont/Resources/FontAwesome5Free-Solid.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/SwiftIconFont/Resources/FontAwesome5Free-Solid.ttf
--------------------------------------------------------------------------------
/SwiftIconFont/Resources/MaterialIcons-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/SwiftIconFont/Resources/MaterialIcons-Regular.ttf
--------------------------------------------------------------------------------
/SwiftIconFont/Resources/FontAwesome5Free-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/SwiftIconFont/Resources/FontAwesome5Free-Regular.ttf
--------------------------------------------------------------------------------
/FontGenerator/font.rb:
--------------------------------------------------------------------------------
1 | class Font
2 | attr_accessor :name, :icons
3 |
4 | def initialize name, icons
5 | @name = name
6 | @icons = icons
7 | end
8 | end
--------------------------------------------------------------------------------
/SwiftIconFont/Resources/FontAwesome5Brands-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/SwiftIconFont/Resources/FontAwesome5Brands-Regular.ttf
--------------------------------------------------------------------------------
/Example/Example.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/SwiftIconFont.xcodeproj/xcuserdata/sdev.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
--------------------------------------------------------------------------------
/Example/Example.xcworkspace/xcuserdata/sdev.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
--------------------------------------------------------------------------------
/SwiftIconFont.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/ExampleMac/ExampleMac.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/ExampleMac/ExampleMac.xcworkspace/xcuserdata/sdev.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
--------------------------------------------------------------------------------
/SwiftIconFont.xcodeproj/project.xcworkspace/xcuserdata/sgc.xcuserdatad/UserInterfaceState.xcuserstate:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/segecey/SwiftIconFont/HEAD/SwiftIconFont.xcodeproj/project.xcworkspace/xcuserdata/sgc.xcuserdatad/UserInterfaceState.xcuserstate
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | .DS_Store
2 | *.xcuserstate
3 | Example/Example.xcodeproj/xcuserdata/Blazej.xcuserdatad/xcschemes/Example.xcscheme
4 | Example/Example.xcodeproj/xcuserdata/Blazej.xcuserdatad/xcschemes/xcschememanagement.plist
5 | SwiftIconFont.xcodeproj/xcuserdata/Blazej.xcuserdatad/xcschemes/xcschememanagement.plist
--------------------------------------------------------------------------------
/Example/Example.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/Example/Example.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/ExampleMac/ExampleMac.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/ExampleMac/ExampleMac.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/FontGenerator/templates/font_list.erb:
--------------------------------------------------------------------------------
1 | //
2 | // NSString+<%= font_name %>.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Ciftci on <%= date %>.
6 | // Copyright © 2016 Sedat Gokbek Ciftci. All rights reserved.
7 | //
8 | import UIKit
9 |
10 | public let <%= array_name %>: [String: String] = [
11 | <%= icons %>
12 | ]
--------------------------------------------------------------------------------
/Example/Example.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/SwiftIconFont.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/ExampleMac/ExampleMac.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/ExampleMac/ExampleMac/ExampleMac.entitlements:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | com.apple.security.app-sandbox
6 |
7 | com.apple.security.files.user-selected.read-only
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/Shared/Types.swift:
--------------------------------------------------------------------------------
1 | //
2 | // Types.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat G. ÇİFTÇİ on 7.06.2020.
6 | // Copyright © 2020 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | #if os(iOS) || os(tvOS)
10 | import UIKit
11 | public typealias Font = UIFont
12 | public typealias Color = UIColor
13 | #elseif os(OSX)
14 | import AppKit
15 | public typealias Font = NSFont
16 | public typealias Color = NSColor
17 | #endif
18 |
--------------------------------------------------------------------------------
/Example/Example.xcodeproj/xcuserdata/sdev.xcuserdatad/xcschemes/xcschememanagement.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | SchemeUserState
6 |
7 | Example.xcscheme_^#shared#^_
8 |
9 | orderHint
10 | 2
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/ExampleMac/ExampleMac.xcodeproj/xcuserdata/sdev.xcuserdatad/xcschemes/xcschememanagement.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | SchemeUserState
6 |
7 | ExampleMac.xcscheme_^#shared#^_
8 |
9 | orderHint
10 | 2
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/UIKit/SwiftIconFont+UITextView.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFont+UITextView.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 13.10.2017.
6 | // Copyright © 2017 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | public extension UITextView {
12 | func parseIcon() {
13 | let text = SwiftIconFont.replace(withText: "")
14 | self.attributedText = getAttributedString(text, ofSize: self.font!.pointSize)
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/UIKit/SwiftIconFont+UILabel.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFont+UILabel.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 13.10.2017.
6 | // Copyright © 2017 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | public extension UILabel {
12 | func parseIcon() {
13 | let text = SwiftIconFont.replace(withText: (self.text! as NSString))
14 | self.attributedText = getAttributedString(text, ofSize: self.font!.pointSize)
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/AppKit/SwiftIconFont+NSTextField.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFont+NSTextField.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat G. ÇİFTÇİ on 6.06.2020.
6 | // Copyright © 2020 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 |
10 | #if os(OSX)
11 | import Cocoa
12 |
13 | public extension NSTextField {
14 | func parseIcon() {
15 | let text = SwiftIconFont.replace(withText: (self.stringValue as NSString))
16 | self.attributedStringValue = getAttributedString(text, ofSize: self.font!.pointSize)
17 | }
18 | }
19 | #endif
20 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/UIKit/SwiftIconLabel.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconLabel.swift
3 | // icon
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 08/07/16.
6 | // Copyright © 2016 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | @IBDesignable
12 | public class SwiftIconLabel: UILabel {
13 | @IBInspectable var Icon: String = "" {
14 | didSet {
15 | self.text = Icon
16 | self.parseIcon()
17 | }
18 | }
19 |
20 | public override func awakeFromNib() {
21 | self.parseIcon()
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/UIKit/SwiftIconTextView.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconTextView.swift
3 | // Exm
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 10/07/16.
6 | // Copyright © 2016 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | @IBDesignable
12 | class SwiftIconTextView: UITextView {
13 | @IBInspectable public var Icon: String = "" {
14 | didSet {
15 | self.text = Icon
16 | self.parseIcon()
17 | }
18 | }
19 |
20 | override func awakeFromNib() {
21 | self.parseIcon()
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/UIKit/SwiftIconButton.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconButton.swift
3 | // icon
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 08/07/16.
6 | // Copyright © 2016 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | @IBDesignable
12 | public class SwiftIconButton: UIButton {
13 | @IBInspectable var Icon: String = "" {
14 | didSet {
15 | self.parseIcon()
16 | self.setTitle(Icon, for: .normal)
17 | }
18 | }
19 |
20 | public override func awakeFromNib() {
21 | self.parseIcon()
22 | }
23 | }
24 |
25 |
26 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/UIKit/SwiftIconFont+UIImageView.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFont+UIImageView.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 13.10.2017.
6 | // Copyright © 2017 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | public extension UIImageView {
12 | func setIcon(from font: Fonts, code: String, textColor: Color = .black, backgroundColor: Color = .clear, size: CGSize? = nil) {
13 | self.image = UIImage(from: font, code: code, textColor: textColor, backgroundColor: backgroundColor, size: size ?? frame.size)
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/SwiftIconFont/SwiftIconFont.h:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFont.h
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 12/07/16.
6 | // Copyright © 2016 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | #import
10 |
11 | //! Project version number for SwiftIconFont.
12 | FOUNDATION_EXPORT double SwiftIconFontVersionNumber;
13 |
14 | //! Project version string for SwiftIconFont.
15 | FOUNDATION_EXPORT const unsigned char SwiftIconFontVersionString[];
16 |
17 | // In this header, you should import all the public headers of your framework using statements like #import
18 |
19 |
20 |
--------------------------------------------------------------------------------
/ExampleMac/ExampleMac/AppDelegate.swift:
--------------------------------------------------------------------------------
1 | //
2 | // AppDelegate.swift
3 | // ExampleMac
4 | //
5 | // Created by Sedat G. ÇİFTÇİ on 4.06.2020.
6 | // Copyright © 2020 Sedat G. ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import Cocoa
10 |
11 | @NSApplicationMain
12 | class AppDelegate: NSObject, NSApplicationDelegate {
13 |
14 |
15 |
16 | func applicationDidFinishLaunching(_ aNotification: Notification) {
17 | // Insert code here to initialize your application
18 | }
19 |
20 | func applicationWillTerminate(_ aNotification: Notification) {
21 | // Insert code here to tear down your application
22 | }
23 |
24 |
25 | }
26 |
27 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/UIKit/SwiftIconBarButtonItem.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconBarButtonItem.swift
3 | // Exm
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 10/07/16.
6 | // Copyright © 2016 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | @IBDesignable
12 | public class SwiftIconBarButtonItem: UIBarButtonItem {
13 | @IBInspectable public var icon: String = ""
14 | @IBInspectable public var fontSize: CGFloat = 15.00
15 |
16 | override public func awakeFromNib() {
17 | parseIcon()
18 | }
19 |
20 | @objc public func parseIcon() {
21 | self.icon(from: GetFontTypeWithSelectedIcon(icon), code: GetIconIndexWithSelectedIcon(icon), ofSize: fontSize)
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/SwiftIconFont.xcodeproj/xcuserdata/sgc.xcuserdatad/xcschemes/xcschememanagement.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | SchemeUserState
6 |
7 | SwiftIconFont.xcscheme_^#shared#^_
8 |
9 | orderHint
10 | 0
11 |
12 |
13 | SuppressBuildableAutocreation
14 |
15 | DA8D9D101D345A3800F5E693
16 |
17 | primary
18 |
19 |
20 | DA8D9D1A1D345A3800F5E693
21 |
22 | primary
23 |
24 |
25 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/UIKit/SwiftIconFont+UITextField.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFont+UITextField.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 13.10.2017.
6 | // Copyright © 2017 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | public extension UITextField {
12 | func parseIcon() {
13 | let text = SwiftIconFont.replace(withText: (self.text! as NSString))
14 | self.attributedText = getAttributedString(text, ofSize: self.font!.pointSize)
15 | }
16 |
17 | func parseIconForRuntime() {
18 | let text = SwiftIconFont.replace(withText: (self.text! as NSString))
19 | self.attributedText = getAttributedStringForRuntimeReplace(text, ofSize: self.font!.pointSize)
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/UIKit/SwiftIconFont+UIButton.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFont+UIButton.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 13.10.2017.
6 | // Copyright © 2017 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | public extension UIButton {
12 | func parseIcon() {
13 | guard let currentTitle = self.titleLabel?.text as NSString? else { return }
14 | let text = replace(withText: currentTitle)
15 | let attrTitle = getAttributedString(text, ofSize: (self.titleLabel?.font!.pointSize)!)
16 | let all = NSRange(location: 0, length: attrTitle.length)
17 | attrTitle.addAttribute(.foregroundColor, value: self.currentTitleColor, range: all)
18 | self.setAttributedTitle(attrTitle, for: UIControl.State())
19 | }
20 | }
21 |
--------------------------------------------------------------------------------
/SwiftIconFontTests/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | $(PRODUCT_BUNDLE_IDENTIFIER)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | $(PRODUCT_NAME)
15 | CFBundlePackageType
16 | BNDL
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | 1
23 |
24 |
25 |
--------------------------------------------------------------------------------
/FontGenerator/icons/iconic.rb:
--------------------------------------------------------------------------------
1 | class Iconic < FontGenerator
2 | attr_reader :font
3 |
4 | def initialize
5 | @font = Font.new "iconic", read_icons
6 | end
7 |
8 | def run
9 | self.generate_code
10 | end
11 |
12 | protected
13 |
14 | def array_name
15 | "iconicIconArr"
16 | end
17 |
18 | def read_icons
19 | icons = []
20 | File.read("./../IconFontCss/iconic.css").each_line do |line|
21 | icon_name = ''
22 | line.gsub(/(?<=oi-).*(?=:before)/i) { |match| icon_name = match }
23 | nameParts = icon_name.split('-')
24 | icon_name = nameParts.join
25 | icon_code = ''
26 | line.gsub(/'.*'/) { |match| icon_code = match[2..(match.length-2)] }
27 | icons.push({
28 | "name": icon_name,
29 | "code": "\\u{#{icon_code}}"
30 | })
31 | end
32 | icons
33 | end
34 | end
--------------------------------------------------------------------------------
/FontGenerator/icons/themify.rb:
--------------------------------------------------------------------------------
1 | class Themify < FontGenerator
2 | attr_reader :font
3 |
4 | def initialize
5 | @font = Font.new "themify", read_icons
6 | end
7 |
8 | def run
9 | self.generate_code
10 | end
11 |
12 | protected
13 |
14 | def array_name
15 | "temifyIconArr"
16 | end
17 |
18 | def read_icons
19 | icons = []
20 | File.read("./../IconFontCss/themify.css").each_line do |line|
21 | icon_name = ''
22 | line.gsub(/(?<=.ti-).*(?=:before)/i) { |match| icon_name = match }
23 | nameParts = icon_name.split('-')
24 | icon_name = nameParts.join
25 | icon_code = ''
26 | line.gsub(/".*"/) { |match| icon_code = match[2..(match.length-2)] }
27 | icons.push({
28 | "name": icon_name,
29 | "code": "\\u{#{icon_code}}"
30 | })
31 | end
32 | icons
33 | end
34 | end
--------------------------------------------------------------------------------
/FontGenerator/icons/octicons.rb:
--------------------------------------------------------------------------------
1 | class Octicons < FontGenerator
2 | attr_reader :font
3 |
4 | def initialize
5 | @font = Font.new "octicons", read_icons
6 | end
7 |
8 | def run
9 | self.generate_code
10 | end
11 |
12 | protected
13 |
14 | def array_name
15 | "octiconArr"
16 | end
17 |
18 | def read_icons
19 | icons = []
20 | File.read("./../IconFontCss/octicons.css").each_line do |line|
21 | icon_name = ''
22 | line.gsub(/(?<=octicon-).*(?=:before)/i) { |match| icon_name = match }
23 | nameParts = icon_name.split('-')
24 | icon_name = nameParts.join
25 | icon_code = ''
26 | line.gsub(/'.*'/) { |match| icon_code = match[2..(match.length-2)] }
27 | icons.push({
28 | "name": icon_name,
29 | "code": "\\u{#{icon_code}}"
30 | })
31 | end
32 | icons
33 | end
34 | end
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/UIKit/SwiftIconImageView.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconImageView.swift
3 | // icon
4 | //
5 | // Created by David Martínez on 16/11/18.
6 | // Copyright © 2016 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | @IBDesignable
12 | public class SwiftIconImageView: UIImageView {
13 | private var iconCode: String = ""
14 |
15 | @IBInspectable var Icon: String = "" {
16 | didSet {
17 | iconCode = Icon
18 | self.parseIcon()
19 | }
20 | }
21 |
22 | public override func awakeFromNib() {
23 | self.parseIcon()
24 | }
25 |
26 | private func parseIcon() {
27 | self.setIcon(from: GetFontTypeWithSelectedIcon(iconCode), code: GetIconIndexWithSelectedIcon(iconCode), textColor: self.tintColor, backgroundColor: self.backgroundColor ?? UIColor.clear, size: self.frame.size)
28 | }
29 | }
30 |
31 |
32 |
--------------------------------------------------------------------------------
/SwiftIconFont/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | $(PRODUCT_BUNDLE_IDENTIFIER)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | $(PRODUCT_NAME)
15 | CFBundlePackageType
16 | FMWK
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | $(CURRENT_PROJECT_VERSION)
23 | NSPrincipalClass
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/AppKit/SwiftIconFont+NSButton.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFont+NSButton.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat G. ÇİFTÇİ on 7.06.2020.
6 | // Copyright © 2020 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 | #if os(OSX)
9 | import Cocoa
10 |
11 | public extension NSButton {
12 | func parseIcon() {
13 |
14 | guard let currentTitle = self.title as NSString? else { return }
15 | let text = replace(withText: currentTitle)
16 | var fontSize: CGFloat = 17.0
17 |
18 | let attrs = self.attributedTitle.attributes(at: 0, effectiveRange: nil)
19 | if let font = attrs[NSAttributedString.Key(rawValue: NSAttributedString.Key.font.rawValue)] as? Font {
20 | fontSize = font.pointSize
21 | }
22 |
23 | let attrTitle = getAttributedString(text, ofSize: fontSize)
24 | self.attributedTitle = attrTitle
25 | }
26 | }
27 | #endif
28 |
--------------------------------------------------------------------------------
/FontGenerator/runner.rb:
--------------------------------------------------------------------------------
1 | require "./font"
2 | require "./font_generator"
3 | require "fileutils"
4 |
5 | class Runner
6 |
7 | autoload :Base, './font_generator'
8 | attr_accessor :main
9 |
10 | def self.load_fonts
11 | Dir[File.join(File.dirname(__FILE__), 'icons', '*.rb')].each do |file|
12 | require file
13 | end
14 | self
15 | end
16 |
17 | def self.parse_fonts
18 | create_folder
19 | fonts.each_pair do |name, opts|
20 | name = Array(name)
21 | names = [name.reverse.join('-'), name.join(' ')] if name.length > 1
22 | name = name.join(' ')
23 | object = opts[:class].new
24 | object.send("run")
25 | end
26 | end
27 |
28 | def self.add_font opts
29 | fonts[opts[:name]] = opts
30 | end
31 |
32 | def self.fonts
33 | @fonts ||= {}
34 | end
35 |
36 | def self.create_folder
37 | FileUtils.mkdir_p("./generated")
38 | end
39 | end
40 |
41 |
42 | Runner.load_fonts.parse_fonts
43 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/Shared/SwiftIconFont+NSRange.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFont+NSRange.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 13.10.2017.
6 | // Copyright © 2017 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import Foundation
10 |
11 | extension NSRange {
12 | func range(for str: String) -> Range? {
13 | guard location != NSNotFound else { return nil }
14 |
15 | guard let fromUTFIndex = str.utf16.index(str.utf16.startIndex, offsetBy: location, limitedBy: str.utf16.endIndex) else { return nil }
16 | guard let toUTFIndex = str.utf16.index(fromUTFIndex, offsetBy: length, limitedBy: str.utf16.endIndex) else { return nil }
17 | guard let fromIndex = String.Index(fromUTFIndex, within: str) else { return nil }
18 | guard let toIndex = String.Index(toUTFIndex, within: str) else { return nil }
19 |
20 | return fromIndex ..< toIndex
21 | }
22 | }
23 |
--------------------------------------------------------------------------------
/FontGenerator/icons/map_icons.rb:
--------------------------------------------------------------------------------
1 | class MapIcon < FontGenerator
2 | attr_reader :font
3 |
4 | def initialize
5 | @font = Font.new "map_icons", read_icons
6 | end
7 |
8 | def run
9 | self.generate_code
10 | end
11 |
12 | protected
13 |
14 | def array_name
15 | "mapIconArr"
16 | end
17 |
18 | def read_icons
19 | icons = []
20 | File.read("./../IconFontCss/map_icons.scss").each_line do |line|
21 | parts = line.split(' ')
22 | icon_name = parts[0]
23 | if icon_name && icon_name.start_with?('$map-icon-')
24 | icon_name = icon_name['$map-icon-'.length..(icon_name.length) -2]
25 | nameParts = icon_name.split('-')
26 | icon_name = nameParts.join
27 | icon_code = parts[1]
28 | icon_code = icon_code[2..5]
29 | icons.push({
30 | "name": icon_name,
31 | "code": "\\u{#{icon_code}}"
32 | })
33 | end
34 | end
35 | icons
36 | end
37 | end
--------------------------------------------------------------------------------
/SwiftIconFont.podspec:
--------------------------------------------------------------------------------
1 | Pod::Spec.new do |s|
2 | s.platform = :ios
3 | s.ios.deployment_target = '8.0'
4 | s.tvos.deployment_target = '9.0'
5 | s.osx.deployment_target = '10.11'
6 | s.name = "SwiftIconFont"
7 | s.summary = "Icons fonts for Swift (FontAwesome, Ionicons, Octicons, Iconic)"
8 | s.requires_arc = true
9 | s.version = "6.2.1"
10 | s.license = { :type => "MIT", :file => "LICENSE" }
11 | s.author = { "Sedat CIFTCI" => "me@sedat.ninja" }
12 | s.homepage = "http://sedat.ninja"
13 | s.source = { :git => "https://github.com/segecey/SwiftIconFont.git", :tag => "#{s.version}"}
14 | s.ios.frameworks = s.tvos.frameworks = 'UIKit'
15 | s.swift_version = "5.0"
16 | s.osx.frameworks = 'AppKit'
17 |
18 | s.ios.source_files = s.tvos.source_files = 'SwiftIconFont/Classes/UIKit/**/*'
19 | s.osx.source_files = 'SwiftIconFont/Classes/AppKit/**/*.{swift}'
20 | s.source_files = "SwiftIconFont/Classes/Shared/**/*"
21 | s.resources = "SwiftIconFont/Resources/*.{ttf}"
22 | end
23 |
--------------------------------------------------------------------------------
/FontGenerator/icons/ion_icons.rb:
--------------------------------------------------------------------------------
1 | class IonIcons < FontGenerator
2 | attr_reader :font
3 |
4 | def initialize
5 | @font = Font.new "ion_icons", read_icons
6 | end
7 |
8 | def run
9 | self.generate_code
10 | end
11 |
12 | protected
13 |
14 | def array_name
15 | "ioniconArr"
16 | end
17 |
18 | def read_icons
19 | icons = []
20 | File.read("./../IconFontCss/ion_icons.scss").each_line do |line|
21 | parts = line.split(' ')
22 | icon_name = parts[0]
23 | if icon_name && icon_name.start_with?('$ionicon-var-')
24 | icon_name = icon_name['$ionicon-var-'.length..(icon_name.length) -2]
25 | nameParts = icon_name.split('-')
26 | icon_name = nameParts.join
27 | icon_code = parts[1]
28 | icon_code = icon_code[2..5]
29 | icons.push({
30 | "name": icon_name,
31 | "code": "\\u{#{icon_code}}"
32 | })
33 | end
34 | end
35 | icons
36 | end
37 | end
--------------------------------------------------------------------------------
/FontGenerator/icons/font_awesome.rb:
--------------------------------------------------------------------------------
1 | class FontAwesome < FontGenerator
2 | attr_reader :font
3 |
4 | def initialize
5 | @font = Font.new "font_awesome", read_icons
6 | end
7 |
8 | def run
9 | self.generate_code
10 | end
11 |
12 | protected
13 |
14 | def array_name
15 | "fontAwesomeIconArr"
16 | end
17 |
18 | def read_icons
19 | icons = []
20 | File.read("./../IconFontCss/font_awesome.scss").each_line do |line|
21 | parts = line.split(' ')
22 | icon_name = parts[0]
23 | if icon_name && icon_name.start_with?('$fa-var-')
24 | icon_name = icon_name['$fa-var-'.length..(icon_name.length) -2]
25 | nameParts = icon_name.split('-')
26 | icon_name = nameParts.join
27 | icon_code = parts[1]
28 | icon_code = icon_code[2..5]
29 | icons.push({
30 | "name": icon_name,
31 | "code": "\\u{#{icon_code}}"
32 | })
33 | end
34 | end
35 | icons
36 | end
37 | end
--------------------------------------------------------------------------------
/FontGenerator/icons/material_icons.rb:
--------------------------------------------------------------------------------
1 | class MaterialIcons < FontGenerator
2 | attr_reader :font
3 |
4 | def initialize
5 | @font = Font.new "material_icons", read_icons
6 | end
7 |
8 | def run
9 | self.generate_code
10 | end
11 |
12 | protected
13 |
14 | def array_name
15 | "materialIconArr"
16 | end
17 |
18 | def read_icons
19 | icons = []
20 | File.read("./../IconFontCss/material_icons.scss").each_line do |line|
21 | parts = line.split(' ')
22 | icon_name = parts[0]
23 | if icon_name && icon_name.start_with?('$zmdi-var-')
24 | icon_name = icon_name['$zmdi-var-'.length..(icon_name.length) -2]
25 |
26 | nameParts = icon_name.split('-')
27 | icon_name = nameParts.join
28 | icon_code = parts[1]
29 | icon_code = icon_code[2..5]
30 |
31 | icons.push({
32 | "name": icon_name,
33 | "code": "\\u{#{icon_code}}"
34 | })
35 |
36 | end
37 | end
38 | icons
39 | end
40 | end
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/UIKit/SwiftIconFont+UIBarButtonItem.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFont+UIBarButtonItem.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 13.10.2017.
6 | // Copyright © 2017 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | public extension UIBarButtonItem {
12 | func icon(from font: Fonts, code: String, ofSize size: CGFloat){
13 | var textAttributes: [NSAttributedString.Key: Any] = [.font: Font.icon(from: font, ofSize: size)]
14 | let currentTextAttributes: [NSAttributedString.Key: Any]? = self.titleTextAttributes(for: UIControl.State())
15 | if currentTextAttributes != nil {
16 | for (key, value) in currentTextAttributes! where key != .font {
17 | textAttributes[key] = value
18 | }
19 | }
20 | self.setTitleTextAttributes(textAttributes, for: .normal)
21 | self.setTitleTextAttributes(textAttributes, for: .highlighted)
22 | self.setTitleTextAttributes(textAttributes, for: .disabled)
23 | self.title = String.getIcon(from: font, code: code)
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | Copyright (c) 2016 Sedat Gokbek CIFTCI
2 |
3 | Permission is hereby granted, free of charge, to any person obtaining a copy
4 | of this software and associated documentation files (the "Software"), to deal
5 | in the Software without restriction, including without limitation the rights
6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7 | copies of the Software, and to permit persons to whom the Software is
8 | furnished to do so, subject to the following conditions:
9 |
10 | The above copyright notice and this permission notice shall be included in
11 | all copies or substantial portions of the Software.
12 |
13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19 | THE SOFTWARE.
20 |
--------------------------------------------------------------------------------
/SwiftIconFontTests/SwiftIconFontTests.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFontTests.swift
3 | // SwiftIconFontTests
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 12/07/16.
6 | // Copyright © 2016 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import XCTest
10 | @testable import SwiftIconFont
11 |
12 | class SwiftIconFontTests: XCTestCase {
13 |
14 | override func setUp() {
15 | super.setUp()
16 | // Put setup code here. This method is called before the invocation of each test method in the class.
17 | }
18 |
19 | override func tearDown() {
20 | // Put teardown code here. This method is called after the invocation of each test method in the class.
21 | super.tearDown()
22 | }
23 |
24 | func testExample() {
25 | // This is an example of a functional test case.
26 | // Use XCTAssert and related functions to verify your tests produce the correct results.
27 | }
28 |
29 | func testPerformanceExample() {
30 | // This is an example of a performance test case.
31 | self.measure {
32 | // Put the code you want to measure the time of here.
33 | }
34 | }
35 |
36 | }
37 |
--------------------------------------------------------------------------------
/ExampleMac/ExampleMac/Assets.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "idiom" : "mac",
5 | "scale" : "1x",
6 | "size" : "16x16"
7 | },
8 | {
9 | "idiom" : "mac",
10 | "scale" : "2x",
11 | "size" : "16x16"
12 | },
13 | {
14 | "idiom" : "mac",
15 | "scale" : "1x",
16 | "size" : "32x32"
17 | },
18 | {
19 | "idiom" : "mac",
20 | "scale" : "2x",
21 | "size" : "32x32"
22 | },
23 | {
24 | "idiom" : "mac",
25 | "scale" : "1x",
26 | "size" : "128x128"
27 | },
28 | {
29 | "idiom" : "mac",
30 | "scale" : "2x",
31 | "size" : "128x128"
32 | },
33 | {
34 | "idiom" : "mac",
35 | "scale" : "1x",
36 | "size" : "256x256"
37 | },
38 | {
39 | "idiom" : "mac",
40 | "scale" : "2x",
41 | "size" : "256x256"
42 | },
43 | {
44 | "idiom" : "mac",
45 | "scale" : "1x",
46 | "size" : "512x512"
47 | },
48 | {
49 | "idiom" : "mac",
50 | "scale" : "2x",
51 | "size" : "512x512"
52 | }
53 | ],
54 | "info" : {
55 | "author" : "xcode",
56 | "version" : 1
57 | }
58 | }
59 |
--------------------------------------------------------------------------------
/ExampleMac/ExampleMac/ViewController.swift:
--------------------------------------------------------------------------------
1 | //
2 | // ViewController.swift
3 | // ExampleMac
4 | //
5 | // Created by Sedat G. ÇİFTÇİ on 4.06.2020.
6 | // Copyright © 2020 Sedat G. ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import Cocoa
10 | import SwiftIconFont
11 |
12 | class ViewController: NSViewController {
13 |
14 | @IBOutlet weak var textLbl: NSTextField!
15 | @IBOutlet weak var testImageView: NSImageView!
16 | @IBOutlet weak var tttImageView: NSImageView!
17 | @IBOutlet weak var button: NSButton!
18 |
19 | override func viewDidLoad() {
20 | super.viewDidLoad()
21 | let image = NSImage(from: .elegantIcon, code: "arrow-left-right", size: CGSize(width: 50, height: 50))
22 | testImageView.image = image
23 | textLbl.stringValue = "el:arrow-left-right"
24 | textLbl.parseIcon()
25 |
26 | tttImageView.image = NSImage(from: .fontAwesome5Solid, code: "coffee", textColor: .red, backgroundColor: .black, size: CGSize(width: 100, height: 100))
27 | button.title = "fa5b:500px"
28 | button.parseIcon()
29 |
30 | }
31 |
32 | override var representedObject: Any? {
33 | didSet {
34 | // Update the view, if already loaded.
35 | }
36 | }
37 |
38 |
39 | }
40 |
41 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/UIKit/SwiftIconFont+UITabBarItem.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFont+UITabBarItem.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 13.10.2017.
6 | // Copyright © 2017 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | public extension UITabBarItem {
12 | func iconWithSwiftIcon(defaultIcon: SwiftIcon) {
13 | self.image = UIImage.icon(from: defaultIcon.font, iconColor: defaultIcon.color, code: defaultIcon.code, imageSize: defaultIcon.imageSize, ofSize: defaultIcon.fontSize)
14 | }
15 |
16 | func icon(from font: Fonts, code: String, iconColor: Color, imageSize: CGSize, ofSize size: CGFloat) {
17 | self.image = UIImage.icon(from: font, iconColor: iconColor, code: code, imageSize: imageSize, ofSize: size)
18 | }
19 |
20 | func iconWithSelectedIcon(from defaultIcon: SwiftIcon, selectedIcon: SwiftIcon) {
21 | self.image = UIImage.icon(from: defaultIcon.font, iconColor: defaultIcon.color, code: defaultIcon.code, imageSize: defaultIcon.imageSize, ofSize: defaultIcon.fontSize)
22 | self.selectedImage = UIImage.icon(from: selectedIcon.font, iconColor: selectedIcon.color, code: selectedIcon.code, imageSize: selectedIcon.imageSize, ofSize: selectedIcon.fontSize)
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/ExampleMac/ExampleMac/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | $(DEVELOPMENT_LANGUAGE)
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIconFile
10 |
11 | CFBundleIdentifier
12 | $(PRODUCT_BUNDLE_IDENTIFIER)
13 | CFBundleInfoDictionaryVersion
14 | 6.0
15 | CFBundleName
16 | $(PRODUCT_NAME)
17 | CFBundlePackageType
18 | $(PRODUCT_BUNDLE_PACKAGE_TYPE)
19 | CFBundleShortVersionString
20 | 1.0
21 | CFBundleVersion
22 | 1
23 | LSMinimumSystemVersion
24 | $(MACOSX_DEPLOYMENT_TARGET)
25 | NSHumanReadableCopyright
26 | Copyright © 2020 Sedat G. ÇİFTÇİ. All rights reserved.
27 | NSMainStoryboardFile
28 | Main
29 | NSPrincipalClass
30 | NSApplication
31 | NSSupportsAutomaticTermination
32 |
33 | NSSupportsSuddenTermination
34 |
35 |
36 |
37 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/UIKit/SwiftIconStepper.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconStepper.swift
3 | // Pods
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 08/09/2017.
6 | //
7 | //
8 |
9 | import UIKit
10 |
11 | #if os(iOS)
12 | @IBDesignable
13 | class SwiftIconStepper: UIStepper {
14 | @IBInspectable var incrementIcon: String?
15 | @IBInspectable var decrementIcon: String?
16 | @IBInspectable var fontSize : CGFloat = 15.0
17 | @IBInspectable var width: CGFloat = 20.0
18 | @IBInspectable var height: CGFloat = 20.0
19 |
20 | override func awakeFromNib() {
21 | parseIcon()
22 | }
23 |
24 | fileprivate func parseIcon() {
25 | if incrementIcon != nil {
26 | let incrementIconImage = UIImage.icon(from: GetFontTypeWithSelectedIcon(incrementIcon!), iconColor: self.tintColor, code: GetIconIndexWithSelectedIcon(incrementIcon!), imageSize: CGSize(width: width, height: height), ofSize: fontSize)
27 | self.setIncrementImage(incrementIconImage, for: .normal)
28 | }
29 |
30 | if decrementIcon != nil {
31 | let decrementIconImage = UIImage.icon(from: GetFontTypeWithSelectedIcon(decrementIcon!), iconColor: self.tintColor, code: GetIconIndexWithSelectedIcon(decrementIcon!), imageSize: CGSize(width: width, height: height), ofSize: fontSize)
32 | self.setDecrementImage(decrementIconImage, for: .normal)
33 | }
34 |
35 | }
36 |
37 | }
38 | #endif
39 |
--------------------------------------------------------------------------------
/.travis.yml:
--------------------------------------------------------------------------------
1 | language: swift
2 | before_install:
3 | - gem uninstall fourflusher --force -a -q -I -x
4 | - gem install fourflusher
5 | - gem uninstall cocoapods --force -a -q -I -x
6 | - gem install cocoapods -v 1.6.1
7 | osx_image: xcode11
8 | before_script: cd Example
9 | podfile: Example/Podfile
10 | branches:
11 | only:
12 | - master
13 | env:
14 | global:
15 | - WORKSPACE=Example.xcworkspace
16 | - SCHEME=Example
17 | matrix:
18 | - DESTINATION="OS=13.0,name=iPhone 8 Plus" SCHEME="$SCHEME" RUN_TESTS="YES" POD_LINT="YES"
19 | - DESTINATION="OS=13.0,name=iPhone 11" SCHEME="$SCHEME" RUN_TESTS="YES" POD_LINT="YES"
20 | script:
21 | - set -o pipefail
22 | - xcodebuild -version
23 | - xcodebuild -showsdks
24 |
25 | # Build Framework in Debug and Run Tests if specified
26 | - if [ $RUN_TESTS == "YES" ]; then
27 | travis_retry xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "$DESTINATION" -configuration Debug ONLY_ACTIVE_ARCH=NO ENABLE_TESTABILITY=YES test | xcpretty -c;
28 | else
29 | xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "$DESTINATION" -configuration Debug ONLY_ACTIVE_ARCH=NO build | xcpretty -c;
30 | fi
31 |
32 | - xcodebuild -workspace "$WORKSPACE" -scheme "$SCHEME" -destination "$DESTINATION" -configuration Release ONLY_ACTIVE_ARCH=NO build | xcpretty -c;
33 |
34 | # Run `pod lib lint` if specified
35 | - if [ $POD_LINT == "YES" ]; then
36 | cd .. && pod lib lint --allow-warnings && cd Example;
37 | fi
38 |
--------------------------------------------------------------------------------
/Example/Example/AppDelegate.swift:
--------------------------------------------------------------------------------
1 | //
2 | // AppDelegate.swift
3 | // Example
4 | //
5 | // Created by Sedat G. ÇİFTÇİ on 3.06.2020.
6 | // Copyright © 2020 Sedat G. ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | @UIApplicationMain
12 | class AppDelegate: UIResponder, UIApplicationDelegate {
13 |
14 |
15 |
16 | func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
17 | // Override point for customization after application launch.
18 | return true
19 | }
20 |
21 | // MARK: UISceneSession Lifecycle
22 |
23 | func application(_ application: UIApplication, configurationForConnecting connectingSceneSession: UISceneSession, options: UIScene.ConnectionOptions) -> UISceneConfiguration {
24 | // Called when a new scene session is being created.
25 | // Use this method to select a configuration to create the new scene with.
26 | return UISceneConfiguration(name: "Default Configuration", sessionRole: connectingSceneSession.role)
27 | }
28 |
29 | func application(_ application: UIApplication, didDiscardSceneSessions sceneSessions: Set) {
30 | // Called when the user discards a scene session.
31 | // If any sessions were discarded while the application was not running, this will be called shortly after application:didFinishLaunchingWithOptions.
32 | // Use this method to release any resources that were specific to the discarded scenes, as they will not return.
33 | }
34 |
35 |
36 | }
37 |
38 |
--------------------------------------------------------------------------------
/FontGenerator/font_generator.rb:
--------------------------------------------------------------------------------
1 | require "erb"
2 |
3 | class FontGenerator
4 | def self.method_added method
5 | return if self == FontGenerator
6 | return if private_method_defined? method
7 | return if protected_method_defined? method
8 | prefix = get_object_name
9 | method_name = method.to_s == 'run' ? nil : method.to_s.gsub('_', '-')
10 | name = [prefix, method_name].compact
11 | Runner.add_font({
12 | name: prefix,
13 | class: self,
14 | method: method
15 | })
16 | end
17 |
18 | def self.get_object_name(value = nil)
19 | @object_name ||= begin
20 | value ||= name.split('::').last if name && !name.empty?
21 | value.to_s.split(/(?=[A-Z])/).join('-').downcase if value
22 | end
23 | end
24 |
25 | def generate_code
26 | File.open("./generated/#{self.class.name}.swift", "w+") { |f| f.write(get_template) }
27 | end
28 |
29 | private
30 |
31 | def generate_icon_items
32 | icon_items = ""
33 | self.font.icons.each do |icon|
34 | implementation_template = <
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/AppKit/SwiftIconFontNSView.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFont+NSView.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat G. ÇİFTÇİ on 7.06.2020.
6 | // Copyright © 2020 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | #if os(OSX)
10 | import Cocoa
11 |
12 | @IBDesignable class SwiftIconFontNSView: NSView {
13 | @IBInspectable var iconCode: String? = "" {
14 | didSet {
15 | setupViews()
16 | }
17 | }
18 |
19 | @IBInspectable var iconColor: Color = .red {
20 | didSet {
21 | setupViews()
22 | }
23 | }
24 |
25 |
26 | private var iconView = NSTextField()
27 | private var iconFont = Fonts.fontAwesome5
28 |
29 | override init(frame: CGRect) {
30 | super.init(frame: frame)
31 | setupViews()
32 | }
33 |
34 |
35 | required public init?(coder aDecoder: NSCoder) {
36 | super.init(coder: aDecoder)
37 | setupViews()
38 | }
39 |
40 | func setupViews() {
41 | if let iconCode = iconCode, iconCode.count > 0 {
42 | iconFont = GetFontTypeWithSelectedIcon(iconCode)
43 | let iconText = GetIconIndexWithSelectedIcon(iconCode)
44 | self.iconView.alignment = .center
45 | self.iconView.isEditable = false
46 | self.iconView.backgroundColor = .clear
47 | self.iconView.isBordered = false
48 | self.iconView.stringValue = String.getIcon(from: iconFont, code: iconText)!
49 | self.iconView.textColor = iconColor
50 | self.addSubview(iconView)
51 | }
52 | }
53 |
54 | override func draw(_ dirtyRect: NSRect) {
55 | super.draw(dirtyRect)
56 | self.iconView.font = Font.icon(from: iconFont, ofSize: bounds.size.width < bounds.size.height ? bounds.size.width : bounds.size.height)
57 | self.iconView.frame = CGRect(origin: CGPoint(x: 0, y: 0), size: CGSize(width: bounds.size.width, height: bounds.size.height))
58 | }
59 | }
60 | #endif
61 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/AppKit/SwiftIconFont+NSImage.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFont+NSImage.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat G. ÇİFTÇİ on 4.06.2020.
6 | // Copyright © 2020 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 | #if os(OSX)
9 | import AppKit
10 | import CoreGraphics
11 |
12 | public extension NSImage {
13 | convenience init(from font: Fonts, code: String, textColor: NSColor = .black, backgroundColor: NSColor = .clear, size: CGSize) {
14 |
15 | if
16 | let image = NSImage.GetSwiftIcon(from: font, code: code, textColor: textColor, backgroundColor: backgroundColor, size: size),
17 | let cgImage = image.cgImage(forProposedRect: nil, context: nil, hints: nil)
18 | {
19 | self.init(cgImage: cgImage, size: size)
20 | } else {
21 | self.init()
22 | }
23 | }
24 |
25 | static func GetSwiftIcon(from font: Fonts, code: String, textColor: Color = .black, backgroundColor: Color = .clear, size: CGSize) -> NSImage? {
26 | let paragraphStyle = NSMutableParagraphStyle()
27 | paragraphStyle.alignment = .center
28 |
29 | let fontSize = min(size.width / 1.28571429, size.height)
30 | guard let icon = String.getIcon(from: font, code: code) else { return nil }
31 |
32 | let attributes: [NSAttributedString.Key: Any] = [
33 | .font: Font.icon(from: font, ofSize: fontSize),
34 | .foregroundColor: textColor,
35 | .backgroundColor: backgroundColor,
36 | .paragraphStyle: paragraphStyle
37 | ]
38 |
39 | let attributedString = NSAttributedString(string:icon, attributes: attributes)
40 |
41 | let stringSize = attributedString.size()
42 | let image = NSImage(size: stringSize)
43 | image.lockFocus()
44 | attributedString.draw(in: CGRect(x: 0, y: (size.height - fontSize) * 0.5, width: size.width, height: fontSize))
45 | image.unlockFocus()
46 |
47 | return image
48 | }
49 | }
50 | #endif
51 |
--------------------------------------------------------------------------------
/Example/Example/Assets.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "idiom" : "iphone",
5 | "scale" : "2x",
6 | "size" : "20x20"
7 | },
8 | {
9 | "idiom" : "iphone",
10 | "scale" : "3x",
11 | "size" : "20x20"
12 | },
13 | {
14 | "idiom" : "iphone",
15 | "scale" : "2x",
16 | "size" : "29x29"
17 | },
18 | {
19 | "idiom" : "iphone",
20 | "scale" : "3x",
21 | "size" : "29x29"
22 | },
23 | {
24 | "idiom" : "iphone",
25 | "scale" : "2x",
26 | "size" : "40x40"
27 | },
28 | {
29 | "idiom" : "iphone",
30 | "scale" : "3x",
31 | "size" : "40x40"
32 | },
33 | {
34 | "idiom" : "iphone",
35 | "scale" : "2x",
36 | "size" : "60x60"
37 | },
38 | {
39 | "idiom" : "iphone",
40 | "scale" : "3x",
41 | "size" : "60x60"
42 | },
43 | {
44 | "idiom" : "ipad",
45 | "scale" : "1x",
46 | "size" : "20x20"
47 | },
48 | {
49 | "idiom" : "ipad",
50 | "scale" : "2x",
51 | "size" : "20x20"
52 | },
53 | {
54 | "idiom" : "ipad",
55 | "scale" : "1x",
56 | "size" : "29x29"
57 | },
58 | {
59 | "idiom" : "ipad",
60 | "scale" : "2x",
61 | "size" : "29x29"
62 | },
63 | {
64 | "idiom" : "ipad",
65 | "scale" : "1x",
66 | "size" : "40x40"
67 | },
68 | {
69 | "idiom" : "ipad",
70 | "scale" : "2x",
71 | "size" : "40x40"
72 | },
73 | {
74 | "idiom" : "ipad",
75 | "scale" : "1x",
76 | "size" : "76x76"
77 | },
78 | {
79 | "idiom" : "ipad",
80 | "scale" : "2x",
81 | "size" : "76x76"
82 | },
83 | {
84 | "idiom" : "ipad",
85 | "scale" : "2x",
86 | "size" : "83.5x83.5"
87 | },
88 | {
89 | "idiom" : "ios-marketing",
90 | "scale" : "1x",
91 | "size" : "1024x1024"
92 | }
93 | ],
94 | "info" : {
95 | "author" : "xcode",
96 | "version" : 1
97 | }
98 | }
99 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/UIKit/SwiftIconFontView.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFontView.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 12/07/2017.
6 | // Copyright © 2017 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | @IBDesignable public class SwiftIconFontView: UIView {
12 | @IBInspectable
13 | public var iconCode: String = "" {
14 | didSet {
15 | iconFont = GetFontTypeWithSelectedIcon(iconCode)
16 | let iconText = GetIconIndexWithSelectedIcon(iconCode)
17 | self.iconView.text = String.getIcon(from: iconFont, code: iconText)
18 | }
19 | }
20 |
21 | private var iconView = UILabel()
22 | private var iconFont = Fonts.fontAwesome5
23 |
24 | override init(frame: CGRect) {
25 | super.init(frame: frame)
26 | setupViews()
27 | }
28 |
29 |
30 | required public init?(coder aDecoder: NSCoder) {
31 | super.init(coder: aDecoder)
32 | setupViews()
33 | }
34 |
35 | override public func prepareForInterfaceBuilder() {
36 | setupViews()
37 | }
38 |
39 |
40 | func setupViews() {
41 | iconFont = GetFontTypeWithSelectedIcon(iconCode)
42 | let iconText = GetIconIndexWithSelectedIcon(iconCode)
43 | self.iconView.textAlignment = NSTextAlignment.center
44 | self.iconView.text = String.getIcon(from: iconFont, code: iconText)
45 | self.iconView.textColor = self.tintColor
46 | self.addSubview(iconView)
47 | }
48 |
49 |
50 | override public func tintColorDidChange() {
51 | self.iconView.textColor = self.tintColor
52 | }
53 |
54 | override public func layoutSubviews() {
55 | super.layoutSubviews()
56 | self.clipsToBounds = true
57 | self.iconView.font = Font.icon(from: iconFont, ofSize: bounds.size.width < bounds.size.height ? bounds.size.width : bounds.size.height)
58 | self.iconView.frame = CGRect(origin: CGPoint(x: 0, y: 0), size: CGSize(width: bounds.size.width, height: bounds.size.height))
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/Example/Example/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | $(DEVELOPMENT_LANGUAGE)
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | $(PRODUCT_BUNDLE_IDENTIFIER)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | $(PRODUCT_NAME)
15 | CFBundlePackageType
16 | $(PRODUCT_BUNDLE_PACKAGE_TYPE)
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleVersion
20 | 1
21 | LSRequiresIPhoneOS
22 |
23 | UIApplicationSceneManifest
24 |
25 | UIApplicationSupportsMultipleScenes
26 |
27 | UISceneConfigurations
28 |
29 | UIWindowSceneSessionRoleApplication
30 |
31 |
32 | UISceneConfigurationName
33 | Default Configuration
34 | UISceneDelegateClassName
35 | $(PRODUCT_MODULE_NAME).SceneDelegate
36 | UISceneStoryboardFile
37 | Main
38 |
39 |
40 |
41 |
42 | UILaunchStoryboardName
43 | LaunchScreen
44 | UIMainStoryboardFile
45 | Main
46 | UIRequiredDeviceCapabilities
47 |
48 | armv7
49 |
50 | UISupportedInterfaceOrientations
51 |
52 | UIInterfaceOrientationPortrait
53 | UIInterfaceOrientationLandscapeLeft
54 | UIInterfaceOrientationLandscapeRight
55 |
56 | UISupportedInterfaceOrientations~ipad
57 |
58 | UIInterfaceOrientationPortrait
59 | UIInterfaceOrientationPortraitUpsideDown
60 | UIInterfaceOrientationLandscapeLeft
61 | UIInterfaceOrientationLandscapeRight
62 |
63 |
64 |
65 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/Shared/FontLoader.swift:
--------------------------------------------------------------------------------
1 | //
2 | // FontLoader.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Ciftci on 18/03/16.
6 | // Copyright © 2016 Sedat Gokbek Ciftci. All rights reserved.
7 | //
8 |
9 | #if canImport(UIKit)
10 | import UIKit
11 | #else
12 | import AppKit
13 | #endif
14 |
15 |
16 | import Foundation
17 | import CoreText
18 |
19 | class FontLoader: NSObject {
20 | class func loadFont(_ fontName: String) {
21 | let bundle = Bundle(for: FontLoader.self)
22 | let paths = bundle.paths(forResourcesOfType: "ttf", inDirectory: nil)
23 | var fontURL: NSURL?
24 | var error: Unmanaged?
25 |
26 | paths.forEach {
27 | guard let filename = NSURL(fileURLWithPath: $0).lastPathComponent,
28 | filename.lowercased().range(of: fontName.lowercased()) != nil else {
29 | return
30 | }
31 |
32 | fontURL = NSURL(fileURLWithPath: $0)
33 | }
34 |
35 | guard let fontURL = fontURL else {
36 | return
37 | }
38 |
39 | guard
40 | !CTFontManagerRegisterFontsForURL(fontURL, .process, &error),
41 | let unwrappedError = error,
42 | let nsError = (unwrappedError.takeUnretainedValue() as AnyObject) as? NSError else {
43 |
44 | return
45 | }
46 |
47 | let errorDescription: CFString = CFErrorCopyDescription(unwrappedError.takeUnretainedValue())
48 |
49 | NSException(name: NSExceptionName.internalInconsistencyException,
50 | reason: errorDescription as String,
51 | userInfo: [NSUnderlyingErrorKey: nsError]).raise()
52 | }
53 | }
54 |
55 | public extension Font {
56 | #if os(iOS) || os(tvOS)
57 | static func icon(from font: Fonts, ofSize size: CGFloat) -> Font {
58 | let fontName = font.rawValue
59 | let fontNames = Font.fontNames(forFamilyName: font.fontFamilyName)
60 | if !fontNames.contains(fontName)
61 | {
62 | FontLoader.loadFont(fontName)
63 | }
64 | return Font(name: fontName, size: size)!
65 | }
66 | #elseif os(OSX)
67 | static func icon(from font: Fonts, ofSize size: CGFloat) -> Font {
68 | let fontName = font.rawValue
69 | FontLoader.loadFont(fontName)
70 | return Font(name: font.rawValue, size: size)!
71 | }
72 | #endif
73 | }
74 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/UIKit/SwiftIconFont+UIImage.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFont+UIImage.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 13.10.2017.
6 | // Copyright © 2017 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | public extension UIImage {
12 | convenience init(from font: Fonts, code: String, textColor: Color = .black, backgroundColor: Color = .clear, size: CGSize) {
13 | guard let drawText = String.getIcon(from: font, code: code) else {
14 | fatalError("\(code) not found in \(font.rawValue)")
15 | }
16 |
17 | let paragraphStyle = NSMutableParagraphStyle()
18 | paragraphStyle.alignment = NSTextAlignment.center
19 |
20 | let fontSize = min(size.width / 1.28571429, size.height)
21 | let attributes: [NSAttributedString.Key: Any] = [.font: Font.icon(from: font, ofSize: fontSize), .foregroundColor: textColor, .backgroundColor: backgroundColor, .paragraphStyle: paragraphStyle]
22 |
23 | let attributedString = NSAttributedString(string: drawText, attributes: attributes)
24 | UIGraphicsBeginImageContextWithOptions(size, false , 0.0)
25 | attributedString.draw(in: CGRect(x: 0, y: (size.height - fontSize) * 0.5, width: size.width, height: fontSize))
26 | let image = UIGraphicsGetImageFromCurrentImageContext()
27 | UIGraphicsEndImageContext()
28 |
29 | if let image = image {
30 | self.init(cgImage: image.cgImage!, scale: image.scale, orientation: image.imageOrientation)
31 | } else {
32 | self.init()
33 | }
34 | }
35 |
36 | static func icon(from font: Fonts, iconColor: Color, code: String, imageSize: CGSize, ofSize size: CGFloat) -> UIImage {
37 | guard let drawText = String.getIcon(from: font, code: code) else {
38 | fatalError("\(code) not found in \(font.rawValue)")
39 | }
40 |
41 | UIGraphicsBeginImageContextWithOptions(imageSize, false, 0)
42 | let paragraphStyle = NSMutableParagraphStyle()
43 | paragraphStyle.alignment = NSTextAlignment.center
44 |
45 | drawText.draw(in: CGRect(x:0, y:0, width:imageSize.width, height:imageSize.height), withAttributes: [.font: Font.icon(from: font, ofSize: size), .paragraphStyle: paragraphStyle, .foregroundColor: iconColor])
46 |
47 | let image = UIGraphicsGetImageFromCurrentImageContext()
48 | UIGraphicsEndImageContext()
49 |
50 | return image!
51 | }
52 | }
53 |
--------------------------------------------------------------------------------
/Example/Example/SceneDelegate.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SceneDelegate.swift
3 | // Example
4 | //
5 | // Created by Sedat G. ÇİFTÇİ on 3.06.2020.
6 | // Copyright © 2020 Sedat G. ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | class SceneDelegate: UIResponder, UIWindowSceneDelegate {
12 |
13 | var window: UIWindow?
14 |
15 |
16 | func scene(_ scene: UIScene, willConnectTo session: UISceneSession, options connectionOptions: UIScene.ConnectionOptions) {
17 | // Use this method to optionally configure and attach the UIWindow `window` to the provided UIWindowScene `scene`.
18 | // If using a storyboard, the `window` property will automatically be initialized and attached to the scene.
19 | // This delegate does not imply the connecting scene or session are new (see `application:configurationForConnectingSceneSession` instead).
20 | guard let _ = (scene as? UIWindowScene) else { return }
21 | }
22 |
23 | func sceneDidDisconnect(_ scene: UIScene) {
24 | // Called as the scene is being released by the system.
25 | // This occurs shortly after the scene enters the background, or when its session is discarded.
26 | // Release any resources associated with this scene that can be re-created the next time the scene connects.
27 | // The scene may re-connect later, as its session was not neccessarily discarded (see `application:didDiscardSceneSessions` instead).
28 | }
29 |
30 | func sceneDidBecomeActive(_ scene: UIScene) {
31 | // Called when the scene has moved from an inactive state to an active state.
32 | // Use this method to restart any tasks that were paused (or not yet started) when the scene was inactive.
33 | }
34 |
35 | func sceneWillResignActive(_ scene: UIScene) {
36 | // Called when the scene will move from an active state to an inactive state.
37 | // This may occur due to temporary interruptions (ex. an incoming phone call).
38 | }
39 |
40 | func sceneWillEnterForeground(_ scene: UIScene) {
41 | // Called as the scene transitions from the background to the foreground.
42 | // Use this method to undo the changes made on entering the background.
43 | }
44 |
45 | func sceneDidEnterBackground(_ scene: UIScene) {
46 | // Called as the scene transitions from the foreground to the background.
47 | // Use this method to save data, release shared resources, and store enough scene-specific state information
48 | // to restore the scene back to its current state.
49 | }
50 |
51 |
52 | }
53 |
54 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/UIKit/SwiftIconTextField.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconTextField.swift
3 | // icon
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 08/07/16.
6 | // Copyright © 2016 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 |
11 | @IBDesignable
12 | class SwiftIconTextField: UITextField {
13 | @IBInspectable var RuntimeParse: Bool = false
14 |
15 | override public func awakeFromNib() {
16 | self.parseIcon()
17 | if RuntimeParse {
18 | self.addTarget(self, action: #selector(textFieldDidChange(textField:)), for: .editingChanged)
19 | }
20 | }
21 |
22 | @objc public func textFieldDidChange(textField: SwiftIconTextField) {
23 | do {
24 | let input = textField.text
25 | let regex = try NSRegularExpression(pattern: "icon:\\((\\w+):(\\w+)\\)", options: NSRegularExpression.Options.caseInsensitive)
26 | let matches = regex.matches(in: input!, options: [], range: NSRange(location: 0, length: (input?.utf16.count)!))
27 |
28 |
29 | for match in matches {
30 | var fontPrefix = ""
31 | var fontCode = ""
32 | let iconLibraryNameRange = match.range(at: 1)
33 | let iconNameRange = match.range(at: 2)
34 |
35 | if let swiftRange = iconLibraryNameRange.range(for: input!) {
36 | fontPrefix = String((input?[swiftRange])!)
37 | }
38 |
39 |
40 | if let swiftRange = iconNameRange.range(for: input!) {
41 | fontCode = String((input?[swiftRange])!)
42 | }
43 |
44 | if fontPrefix.utf16.count > 0 && fontCode.utf16.count > 0 {
45 |
46 | var fontArr: [String: String] = ["": ""]
47 |
48 | if fontPrefix == "ic" {
49 | fontArr = iconicIconArr
50 | } else if fontPrefix == "io" {
51 | fontArr = ioniconArr
52 | } else if fontPrefix == "oc" {
53 | fontArr = octiconArr
54 | } else if fontPrefix == "ti" {
55 | fontArr = temifyIconArr
56 | } else if fontPrefix == "mi" {
57 | fontArr = mapIconArr
58 | } else if fontPrefix == "ma" {
59 | fontArr = materialIconArr
60 | } else if fontPrefix == "sm" {
61 | fontArr = segoeMDL2
62 | } else if fontPrefix == "fa5" {
63 | fontArr = fontAwesome5IconArr
64 | } else if fontPrefix == "fa5b" {
65 | fontArr = fontAwesome5IconArr
66 | } else if fontPrefix == "fa5s" {
67 | fontArr = fontAwesome5IconArr
68 | } else if fontPrefix == "fo" {
69 | fontArr = foundationIconArr
70 | } else if fontPrefix == "el" {
71 | fontArr = elegantIconArr
72 | } else if fontPrefix == "cp" {
73 | fontArr = captainIconArr
74 | }
75 |
76 | if let _ = fontArr[fontCode] {
77 | self.parseIconForRuntime()
78 | }
79 | }
80 | }
81 | } catch {
82 | // regex was bad!
83 | }
84 |
85 | }
86 | }
87 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/Shared/SwiftIconFont+String.swift:
--------------------------------------------------------------------------------
1 | //
2 | // SwiftIconFont+String.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 13.10.2017.
6 | // Copyright © 2017 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import Foundation
10 |
11 | public extension String {
12 | static func getIcon(from font: Fonts, code: String) -> String? {
13 | switch font {
14 | case .iconic:
15 | return fontIconicIcon(code)
16 | case .ionicon:
17 | return fontIonIcon(code)
18 | case .mapIcon:
19 | return fontMapIcon(code)
20 | case .materialIcon:
21 | return fontMaterialIcon(code)
22 | case .octicon:
23 | return fontOcticon(code)
24 | case .themify:
25 | return fontThemifyIcon(code)
26 | case .segoeMDL2:
27 | return fontSegoeMDL2Icon(code)
28 | case .fontAwesome5:
29 | return fontAwesome5Icon(code)
30 | case .fontAwesome5Brand:
31 | return fontAwesome5Icon(code)
32 | case .fontAwesome5Solid:
33 | return fontAwesome5Icon(code)
34 | case .foundation:
35 | return foundationIcon(code)
36 | case .elegantIcon:
37 | return elegantIcon(code)
38 | case .captain:
39 | return captainIcon(code)
40 | }
41 | }
42 |
43 | static func captainIcon(_ code: String) -> String? {
44 | if let icon = captainIconArr[code] {
45 | return icon
46 | }
47 |
48 | return nil
49 | }
50 |
51 | static func elegantIcon(_ code: String) -> String? {
52 | if let icon = elegantIconArr[code] {
53 | return icon
54 | }
55 |
56 | return nil
57 | }
58 |
59 | static func foundationIcon(_ code: String) -> String? {
60 | if let icon = foundationIconArr[code] {
61 | return icon
62 | }
63 |
64 | return nil
65 | }
66 |
67 | static func fontAwesome5Icon(_ code: String) -> String? {
68 | if let icon = fontAwesome5IconArr[code] {
69 | return icon
70 | }
71 |
72 | return nil
73 | }
74 |
75 | static func fontOcticon(_ code: String) -> String? {
76 | if let icon = octiconArr[code] {
77 | return icon
78 | }
79 | return nil
80 | }
81 |
82 | static func fontIonIcon(_ code: String) -> String? {
83 | if let icon = ioniconArr[code] {
84 | return icon
85 | }
86 | return nil
87 | }
88 |
89 | static func fontIconicIcon(_ code: String) -> String? {
90 | if let icon = iconicIconArr[code] {
91 | return icon
92 | }
93 | return nil
94 | }
95 |
96 | static func fontThemifyIcon(_ code: String) -> String? {
97 | if let icon = temifyIconArr[code] {
98 | return icon
99 | }
100 | return nil
101 | }
102 |
103 | static func fontMapIcon(_ code: String) -> String? {
104 | if let icon = mapIconArr[code] {
105 | return icon
106 | }
107 | return nil
108 | }
109 |
110 | static func fontMaterialIcon(_ code: String) -> String? {
111 | if let icon = materialIconArr[code] {
112 | return icon
113 | }
114 | return nil
115 | }
116 |
117 | static func fontSegoeMDL2Icon(_ code: String) -> String? {
118 | if let icon = segoeMDL2[code] {
119 | return icon
120 | }
121 | return nil
122 | }
123 | }
124 |
--------------------------------------------------------------------------------
/SwiftIconFont.xcodeproj/xcshareddata/xcschemes/SwiftIconFont.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
5 |
8 |
9 |
15 |
21 |
22 |
23 |
24 |
25 |
31 |
32 |
34 |
40 |
41 |
42 |
43 |
44 |
50 |
51 |
52 |
53 |
54 |
55 |
66 |
67 |
73 |
74 |
75 |
76 |
77 |
78 |
84 |
85 |
91 |
92 |
93 |
94 |
96 |
97 |
100 |
101 |
102 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/Shared/Fonts/Octicon.swift:
--------------------------------------------------------------------------------
1 | //
2 | // NSString+Octicon.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Ciftci on 18/03/16.
6 | // Copyright © 2016 Sedat Gokbek Ciftci. All rights reserved.
7 | //
8 |
9 | public let octiconArr: [String: String] = [
10 | "alert":"\u{f02d}",
11 | "alignment-align":"\u{f08a}",
12 | "alignment-aligned-to":"\u{f08e}",
13 | "alignment-unalign":"\u{f08b}",
14 | "arrow-down":"\u{f03f}",
15 | "arrow-left":"\u{f040}",
16 | "arrow-right":"\u{f03e}",
17 | "arrow-small-down":"\u{f0a0}",
18 | "arrow-small-left":"\u{f0a1}",
19 | "arrow-small-right":"\u{f071}",
20 | "arrow-small-up":"\u{f09f}",
21 | "arrow-up":"\u{f03d}",
22 | "beer":"\u{f069}",
23 | "book":"\u{f007}",
24 | "bookmark":"\u{f07b}",
25 | "briefcase":"\u{f0d3}",
26 | "broadcast":"\u{f048}",
27 | "browser":"\u{f0c5}",
28 | "bug":"\u{f091}",
29 | "calendar":"\u{f068}",
30 | "check":"\u{f03a}",
31 | "checklist":"\u{f076}",
32 | "chevron-down":"\u{f0a3}",
33 | "chevron-left":"\u{f0a4}",
34 | "chevron-right":"\u{f078}",
35 | "chevron-up":"\u{f0a2}",
36 | "circle-slash":"\u{f084}",
37 | "circuit-board":"\u{f0d6}",
38 | "clippy":"\u{f035}",
39 | "clock":"\u{f046}",
40 | "cloud-download":"\u{f00b}",
41 | "cloud-upload":"\u{f00c}",
42 | "code":"\u{f05f}",
43 | "color-mode":"\u{f065}",
44 | "comment":"\u{f02b}",
45 | "comment-discussion":"\u{f04f}",
46 | "credit-card":"\u{f045}",
47 | "dash":"\u{f0ca}",
48 | "dashboard":"\u{f07d}",
49 | "database":"\u{f096}",
50 | "device-camera":"\u{f056}",
51 | "device-camera-video":"\u{f057}",
52 | "device-desktop":"\u{f27c}",
53 | "device-mobile":"\u{f038}",
54 | "diff":"\u{f04d}",
55 | "diff-added":"\u{f06b}",
56 | "diff-ignored":"\u{f099}",
57 | "diff-modified":"\u{f06d}",
58 | "diff-removed":"\u{f06c}",
59 | "diff-renamed":"\u{f06e}",
60 | "ellipsis":"\u{f09a}",
61 | "eye":"\u{f04e}",
62 | "file-binary":"\u{f094}",
63 | "file-code":"\u{f010}",
64 | "file-directory":"\u{f016}",
65 | "file-media":"\u{f012}",
66 | "file-pdf":"\u{f014}",
67 | "file-submodule":"\u{f017}",
68 | "file-symlink-directory":"\u{f0b1}",
69 | "file-symlink-file":"\u{f0b0}",
70 | "file-text":"\u{f011}",
71 | "file-zip":"\u{f013}",
72 | "flame":"\u{f0d2}",
73 | "fold":"\u{f0cc}",
74 | "gear":"\u{f02f}",
75 | "gift":"\u{f042}",
76 | "gist":"\u{f00e}",
77 | "gist-secret":"\u{f08c}",
78 | "git-branch":"\u{f020}",
79 | "git-commit":"\u{f01f}",
80 | "git-compare":"\u{f0ac}",
81 | "git-merge":"\u{f023}",
82 | "git-pull-request":"\u{f009}",
83 | "globe":"\u{f0b6}",
84 | "graph":"\u{f043}",
85 | "heart":"\u{2665}",
86 | "history":"\u{f07e}",
87 | "home":"\u{f08d}",
88 | "horizontal-rule":"\u{f070}",
89 | "hourglass":"\u{f09e}",
90 | "hubot":"\u{f09d}",
91 | "inbox":"\u{f0cf}",
92 | "info":"\u{f059}",
93 | "issue-closed":"\u{f028}",
94 | "issue-opened":"\u{f026}",
95 | "issue-reopened":"\u{f027}",
96 | "jersey":"\u{f019}",
97 | "jump-down":"\u{f072}",
98 | "jump-left":"\u{f0a5}",
99 | "jump-right":"\u{f0a6}",
100 | "jump-up":"\u{f073}",
101 | "key":"\u{f049}",
102 | "keyboard":"\u{f00d}",
103 | "law":"\u{f0d8}",
104 | "light-bulb":"\u{f000}",
105 | "link":"\u{f05c}",
106 | "link-external":"\u{f07f}",
107 | "list-ordered":"\u{f062}",
108 | "list-unordered":"\u{f061}",
109 | "location":"\u{f060}",
110 | "lock":"\u{f06a}",
111 | "logo-github":"\u{f092}",
112 | "mail":"\u{f03b}",
113 | "mail-read":"\u{f03c}",
114 | "mail-reply":"\u{f051}",
115 | "mark-github":"\u{f00a}",
116 | "markdown":"\u{f0c9}",
117 | "megaphone":"\u{f077}",
118 | "mention":"\u{f0be}",
119 | "microscope":"\u{f089}",
120 | "milestone":"\u{f075}",
121 | "mirror":"\u{f024}",
122 | "mortar-board":"\u{f0d7}",
123 | "move-down":"\u{f0a8}",
124 | "move-left":"\u{f074}",
125 | "move-right":"\u{f0a9}",
126 | "move-up":"\u{f0a7}",
127 | "mute":"\u{f080}",
128 | "no-newline":"\u{f09c}",
129 | "octoface":"\u{f008}",
130 | "organization":"\u{f037}",
131 | "package":"\u{f0c4}",
132 | "paintcan":"\u{f0d1}",
133 | "pencil":"\u{f058}",
134 | "person":"\u{f018}",
135 | "pin":"\u{f041}",
136 | "playback-fast-forward":"\u{f0bd}",
137 | "playback-pause":"\u{f0bb}",
138 | "playback-play":"\u{f0bf}",
139 | "playback-rewind":"\u{f0bc}",
140 | "plug":"\u{f0d4}",
141 | "plus":"\u{f05d}",
142 | "podium":"\u{f0af}",
143 | "primitive-dot":"\u{f052}",
144 | "primitive-square":"\u{f053}",
145 | "pulse":"\u{f085}",
146 | "puzzle":"\u{f0c0}",
147 | "question":"\u{f02c}",
148 | "quote":"\u{f063}",
149 | "radio-tower":"\u{f030}",
150 | "repo":"\u{f001}",
151 | "repo-clone":"\u{f04c}",
152 | "repo-force-push":"\u{f04a}",
153 | "repo-forked":"\u{f002}",
154 | "repo-pull":"\u{f006}",
155 | "repo-push":"\u{f005}",
156 | "rocket":"\u{f033}",
157 | "rss":"\u{f034}",
158 | "ruby":"\u{f047}",
159 | "screen-full":"\u{f066}",
160 | "screen-normal":"\u{f067}",
161 | "search":"\u{f02e}",
162 | "server":"\u{f097}",
163 | "settings":"\u{f07c}",
164 | "sign-in":"\u{f036}",
165 | "sign-out":"\u{f032}",
166 | "split":"\u{f0c6}",
167 | "squirrel":"\u{f0b2}",
168 | "star":"\u{f02a}",
169 | "steps":"\u{f0c7}",
170 | "stop":"\u{f08f}",
171 | "sync":"\u{f087}",
172 | "tag":"\u{f015}",
173 | "telescope":"\u{f088}",
174 | "terminal":"\u{f0c8}",
175 | "three-bars":"\u{f05e}",
176 | "thumbsdown":"\u{f0db}",
177 | "thumbsup":"\u{f0da}",
178 | "tools":"\u{f031}",
179 | "trashcan":"\u{f0d0}",
180 | "triangle-down":"\u{f05b}",
181 | "triangle-left":"\u{f044}",
182 | "triangle-right":"\u{f05a}",
183 | "triangle-up":"\u{f0aa}",
184 | "unfold":"\u{f039}",
185 | "unmute":"\u{f0ba}",
186 | "versions":"\u{f064}",
187 | "x":"\u{f081}",
188 | "zap":"\u{26A1}",
189 | ]
190 |
--------------------------------------------------------------------------------
/Example/Example/ViewController.swift:
--------------------------------------------------------------------------------
1 | //
2 | // ViewController.swift
3 | // Example
4 | //
5 | // Created by Sedat G. ÇİFTÇİ on 3.06.2020.
6 | // Copyright © 2020 Sedat G. ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | import UIKit
10 | import SwiftIconFont
11 |
12 | class FontProviderTableViewCell: UITableViewCell {
13 | @IBOutlet weak var providerNameLbl: UILabel!
14 | }
15 |
16 | class FontTableViewCell: UITableViewCell {
17 | @IBOutlet weak var fontView: SwiftIconFontView!
18 | @IBOutlet weak var fontLbl: UILabel!
19 | }
20 |
21 | class ViewController: UIViewController {
22 | @IBOutlet weak var tableView: UITableView!
23 | let fonts = [
24 | [
25 | "title": "Font Awesome 5",
26 | "fonts": fontAwesome5IconArr,
27 | "prefix": "fa5"
28 | ],
29 | [
30 | "title": "Iconic",
31 | "fonts": iconicIconArr,
32 | "prefix": "ic"
33 | ],
34 | [
35 | "title": "Ion Icons",
36 | "fonts": ioniconArr,
37 | "prefix": "io"
38 | ],
39 | [
40 | "title": "Map Icon",
41 | "fonts": mapIconArr,
42 | "prefix": "mi"
43 | ],
44 | [
45 | "title": "Material Icon",
46 | "fonts": materialIconArr,
47 | "prefix": "ma"
48 | ],
49 | [
50 | "title": "Octicon",
51 | "fonts": octiconArr,
52 | "prefix": "oc"
53 | ],
54 | [
55 | "title": "SegoeMDL2",
56 | "fonts": segoeMDL2,
57 | "prefix": "sm"
58 | ],
59 | [
60 | "title": "Themify Icon",
61 | "fonts": temifyIconArr,
62 | "prefix": "ti"
63 | ],
64 | [
65 | "title": "Foundation",
66 | "fonts": foundationIconArr,
67 | "prefix": "fo"
68 | ],
69 | [
70 | "title": "Elegant Icon",
71 | "fonts": elegantIconArr,
72 | "prefix": "el"
73 | ],
74 | [
75 | "title": "Captain",
76 | "fonts": captainIconArr,
77 | "prefix": "cp"
78 | ]
79 | ]
80 |
81 | override func viewDidLoad() {
82 | super.viewDidLoad()
83 | tableView.delegate = self
84 | tableView.dataSource = self
85 | let label = UILabel()
86 | label.font = UIFont.icon(from: .fontAwesome5, ofSize: 15)
87 | label.text = String.fontAwesome5Icon("twitter")
88 | }
89 |
90 | override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
91 | if segue.identifier == "showList", let dest = segue.destination as? FontListViewController, let font = sender as? [String: Any] {
92 | dest.font = font
93 | }
94 | }
95 | }
96 |
97 |
98 | extension ViewController: UITableViewDelegate {
99 | func tableView(_ tableView: UITableView, didSelectRowAt indexPath: IndexPath) {
100 | let font = fonts[indexPath.row]
101 | performSegue(withIdentifier: "showList", sender: font)
102 | tableView.deselectRow(at: indexPath, animated: true)
103 | }
104 | }
105 |
106 | extension ViewController: UITableViewDataSource {
107 | func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
108 | return fonts.count
109 | }
110 |
111 | func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
112 | let cell = tableView.dequeueReusableCell(withIdentifier: "FontProviderTableViewCell", for: indexPath) as! FontProviderTableViewCell
113 | let font = fonts[indexPath.row]
114 | cell.providerNameLbl.text = font["title"] as? String
115 | return cell
116 | }
117 | }
118 |
119 |
120 | class FontListViewController: UIViewController {
121 | var font: [String: Any]!
122 | @IBOutlet weak var tableView: UITableView!
123 | @IBOutlet weak var segControl: UISegmentedControl!
124 |
125 | var faPrefix = "fa5"
126 |
127 |
128 | override func viewDidLoad() {
129 | super.viewDidLoad()
130 |
131 | self.title = font["title"] as? String
132 |
133 |
134 | if self.title != "Font Awesome 5" {
135 | segControl.isHidden = true
136 | } else {
137 | segControl.isHidden = false
138 | }
139 |
140 | tableView.delegate = self
141 | tableView.dataSource = self
142 | }
143 |
144 | @IBAction func changeFontAwesomeType(_ sender: Any) {
145 | switch segControl.selectedSegmentIndex {
146 | case 0:
147 | faPrefix = "fa5"
148 | case 1:
149 | faPrefix = "fa5s"
150 | case 2:
151 | faPrefix = "fa5b"
152 | default:
153 | faPrefix = "fa5"
154 | }
155 |
156 |
157 | tableView.reloadData()
158 |
159 | }
160 |
161 | }
162 |
163 | extension FontListViewController: UITableViewDataSource {
164 | func tableView(_ tableView: UITableView, numberOfRowsInSection section: Int) -> Int {
165 | let fonts = font["fonts"] as! [String: String]
166 | return fonts.count
167 | }
168 |
169 | func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
170 | let cell = tableView.dequeueReusableCell(withIdentifier: "FontTableViewCell", for: indexPath) as! FontTableViewCell
171 | let fonts = font["fonts"] as! [String: String]
172 | let key = Array(fonts.keys)[indexPath.row]
173 |
174 | if self.title == "Font Awesome 5" {
175 | cell.fontLbl.text = "\(faPrefix):\(key)"
176 | cell.fontView.iconCode = "\(faPrefix):\(key)"
177 | } else {
178 | let prefix = font["prefix"]!
179 | cell.fontLbl.text = "\(prefix):\(key)"
180 | cell.fontView.iconCode = "\(prefix):\(key)"
181 | }
182 | cell.fontView.tintColor = UIColor.random
183 | return cell
184 | }
185 | }
186 |
187 | extension FontListViewController: UITableViewDelegate {
188 |
189 | }
190 |
191 |
192 | extension UIColor {
193 | static var random: UIColor {
194 | return UIColor(red: .random(in: 0...1),
195 | green: .random(in: 0...1),
196 | blue: .random(in: 0...1),
197 | alpha: 1.0)
198 | }
199 | }
200 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | 
2 |
3 | [](#)
4 | [](#)
5 | [](#)
6 | [](https://travis-ci.org/segecey/SwiftIconFont)
7 | [](http://cocoapods.org/pods/SwiftIconFont)
8 | [](http://cocoapods.org/pods/SwiftIconFont)
9 | [](http://cocoapods.org/pods/SwiftIconFont)
10 | [](https://github.com/Carthage/Carthage)
11 | [](https://houndci.com)
12 |
13 | ## Installation
14 |
15 | ### SPM
16 |
17 | **Not yet supported. Please use Cocoapods or Carthage**
18 |
19 | ### Carthage
20 |
21 | ```bash
22 | github "segecey/SwiftIconFont"
23 | ```
24 |
25 | ### Cocoapods
26 |
27 | [CocoaPods](http://cocoapods.org) is a dependency manager for Cocoa projects.
28 |
29 | You can install it with the following command:
30 |
31 | ```bash
32 | gem install cocoapods
33 | ```
34 |
35 | To integrate SwiftIconFont into your Xcode project using CocoaPods, specify it in your `Podfile`:
36 |
37 | ```ruby
38 | use_frameworks!
39 |
40 | pod 'SwiftIconFont'
41 | ```
42 |
43 | ## Example
44 |
45 | To run the example project, clone the repo, and run `pod install` from the Example directory first.
46 |
47 | ## Prefixes
48 |
49 | | Font | Prefix | Cheat Sheet |
50 | | -------------------- | ------ | -------------------------------------------------------------------------------------- |
51 | | Font Awesome 5 | fa5: | [List](http://fontawesome.io/icons/) |
52 | | Font Awesome 5 Brand | fa5b: | [List](http://fontawesome.io/icons/) |
53 | | Font Awesome 5 Solid | fa5s: | [List](http://fontawesome.io/icons/) |
54 | | Ion Icons | io: | [List](http://ionicons.com) |
55 | | Octicons | oc: | [List](https://octicons.github.com) |
56 | | Open Iconic | ic: | [List](https://useiconic.com/open/) |
57 | | Material Icon | ma: | [List](https://design.google.com/icons/) |
58 | | Themify | ti: | [List](https://themify.me/themify-icons) |
59 | | Map Icons | mi: | [List](http://map-icons.com) |
60 | | Segoe MDL2 | sm: | [List](https://docs.microsoft.com/en-us/windows/uwp/design/style/segoe-ui-symbol-font) |
61 | | Foundation 3 | fo: | [List](https://zurb.com/playground/foundation-icon-fonts-3) |
62 | | Elegant Icon | el: | [List](https://www.elegantthemes.com/blog/resources/elegant-icon-font) |
63 | | Captain | cp: | Please check example project. |
64 |
65 | ## Fonts
66 |
67 | ```swift
68 | public enum Fonts: String {
69 | case fontAwesome5 = "FontAwesome5Free-Regular"
70 | case fontAwesome5Brand = "FontAwesome5Brands-Regular"
71 | case fontAwesome5Solid = "FontAwesome5Free-Solid"
72 | case iconic = "open-iconic"
73 | case ionicon = "Ionicons"
74 | case octicon = "octicons"
75 | case themify = "themify"
76 | case mapIcon = "map-icons"
77 | case materialIcon = "MaterialIcons-Regular"
78 | case segoeMDL2 = "Segoe mdl2 assets"
79 | case foundation = "fontcustom"
80 | case elegantIcon = "ElegantIcons"
81 | case captain = "captainicon"
82 | }
83 | ```
84 |
85 | ## Storyboard
86 |
87 | 
88 |
89 | ## Runtime Structure
90 |
91 | > < Prefix >:< Icon >
92 |
93 | ## Usage
94 |
95 | In your UILabel, UIButton or UITextField, set a text containing a placeholder anywhere you want the icon to be. Somethink like this
96 |
97 | > oc:logo-github
98 |
99 | Then you can choose between 3 ways you can use SwiftIconFont.
100 |
101 | #### 1. Without Custom Class
102 |
103 | Simply import SwiftIconFont and call processIcons on any UILabel, UIButton or UITextField that has a placeholder.
104 |
105 | ```swift
106 | label.parseIcon()
107 | ```
108 |
109 | #### 2. Custom Class
110 |
111 | The lazy way, just set your UILabel, UITextField, UIButton, UITextView, UIBarButtonItem class as SwiftIconLabel, SwiftIconTextField, SwiftIconButton, SwiftIconTextView, SwiftBarButtonItem, and thats it, your icons will be processed at runtime.
112 |
113 | #### 3. Programmatically
114 |
115 | ```swift
116 | import SwiftIconFont
117 |
118 | label.font = UIFont.icon(from: .fontAwesome5, ofSize: 50.0)
119 | label.text = String.fontAwesome5Icon(code: "twitter")
120 | ```
121 |
122 | #### UIBarButtonItem (Without Custom Class)
123 |
124 | ```swift
125 | import SwiftIconFont
126 |
127 | twitterBarButton.icon(from: .fontAwesome5, code: "twitter", ofSize: 20)
128 | ```
129 |
130 | #### UITabBarItem (Without Custom Class)
131 |
132 | ```swift
133 | import SwiftIconFont
134 |
135 | twitterTabBarButton.icon(from: .fontAwesome5, code: "twitter", imageSize: CGSizeMake(20, 20), ofSize: 20)
136 | ```
137 |
138 | #### UIImage
139 |
140 | ```swift
141 | import SwiftIconFont
142 |
143 | let githubLogo = UIImage(from: .octicon, code: "logo-github", textColor: .black, backgroundColor: .clear, size: CGSize(width: 150, height: 50))
144 | ```
145 |
146 | #### UIImageView
147 |
148 | ```swift
149 | import SwiftIconFont
150 |
151 | let githubLogoImageView: UIImageView = UIImageView(frame: CGRect(x: 120, y: self.view.frame.size.height - 130, width: 150, height: 50))
152 | githubLogoImageView.setIcon(from: .octicon, code: "logo-github", textColor: .black, backgroundColor: .clear, size: nil)
153 | ```
154 |
155 | #### macOS
156 |
157 | - NSTextField, NSImage, NSView
158 | - Please check **ExampleMac** project
159 |
160 | ## Author
161 |
162 | Sedat ÇİFTÇİ - me@sedat.ninja
163 |
164 | ## Contributors
165 |
166 | josejuanqm
167 |
168 | ## License
169 |
170 | SwiftIconFont is available under the MIT license. See the LICENSE file for more info.
171 |
172 | ## Contributing
173 |
174 | 1. Fork it ()
175 | 2. Create your feature branch (`git checkout -b my-new-feature`)
176 | 3. Commit your changes (`git commit -am 'Add some feature'`)
177 | 4. Push to the branch (`git push origin my-new-feature`)
178 | 5. Create new Pull Request
179 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/Shared/Fonts/Iconic.swift:
--------------------------------------------------------------------------------
1 | //
2 | // NSString+Iconic.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Ciftci on 18/03/16.
6 | // Copyright © 2016 Sedat Gokbek Ciftci. All rights reserved.
7 | //
8 |
9 | public let iconicIconArr: [String: String] = [
10 | "account-login":"\u{e000}",
11 | "account-logout":"\u{e001}",
12 | "action-redo":"\u{e002}",
13 | "action-undo":"\u{e003}",
14 | "align-center":"\u{e004}",
15 | "align-left":"\u{e005}",
16 | "align-right":"\u{e006}",
17 | "aperture":"\u{e007}",
18 | "arrow-bottom":"\u{e008}",
19 | "arrow-circle-bottom":"\u{e009}",
20 | "arrow-circle-left":"\u{e00a}",
21 | "arrow-circle-right":"\u{e00b}",
22 | "arrow-circle-top":"\u{e00c}",
23 | "arrow-left":"\u{e00d}",
24 | "arrow-right":"\u{e00e}",
25 | "arrow-thick-bottom":"\u{e00f}",
26 | "arrow-thick-left":"\u{e010}",
27 | "arrow-thick-right":"\u{e011}",
28 | "arrow-thick-top":"\u{e012}",
29 | "arrow-top":"\u{e013}",
30 | "audio-spectrum":"\u{e014}",
31 | "audio":"\u{e015}",
32 | "badge":"\u{e016}",
33 | "ban":"\u{e017}",
34 | "bar-chart":"\u{e018}",
35 | "basket":"\u{e019}",
36 | "battery-empty":"\u{e01a}",
37 | "battery-full":"\u{e01b}",
38 | "beaker":"\u{e01c}",
39 | "bell":"\u{e01d}",
40 | "bluetooth":"\u{e01e}",
41 | "bold":"\u{e01f}",
42 | "bolt":"\u{e020}",
43 | "book":"\u{e021}",
44 | "bookmark":"\u{e022}",
45 | "box":"\u{e023}",
46 | "briefcase":"\u{e024}",
47 | "british-pound":"\u{e025}",
48 | "browser":"\u{e026}",
49 | "brush":"\u{e027}",
50 | "bug":"\u{e028}",
51 | "bullhorn":"\u{e029}",
52 | "calculator":"\u{e02a}",
53 | "calendar":"\u{e02b}",
54 | "camera-slr":"\u{e02c}",
55 | "caret-bottom":"\u{e02d}",
56 | "caret-left":"\u{e02e}",
57 | "caret-right":"\u{e02f}",
58 | "caret-top":"\u{e030}",
59 | "cart":"\u{e031}",
60 | "chat":"\u{e032}",
61 | "check":"\u{e033}",
62 | "chevron-bottom":"\u{e034}",
63 | "chevron-left":"\u{e035}",
64 | "chevron-right":"\u{e036}",
65 | "chevron-top":"\u{e037}",
66 | "circle-check":"\u{e08}",
67 | "circle-x":"\u{e039}",
68 | "clipboard":"\u{e03a}",
69 | "clock":"\u{e03b}",
70 | "cloud-download":"\u{e03c}",
71 | "cloud-upload":"\u{e03d}",
72 | "cloud":"\u{e03e}",
73 | "cloudy":"\u{e03f}",
74 | "code":"\u{e040}",
75 | "cog":"\u{e041}",
76 | "collapse-down":"\u{e042}",
77 | "collapse-left":"\u{e043}",
78 | "collapse-right":"\u{e044}",
79 | "collapse-up":"\u{e045}",
80 | "command":"\u{e046}",
81 | "comment-square":"\u{e047}",
82 | "compass":"\u{e048}",
83 | "contrast":"\u{e049}",
84 | "copywriting":"\u{e04a}",
85 | "credit-card":"\u{e04b}",
86 | "crop":"\u{e04c}",
87 | "dashboard":"\u{e04d}",
88 | "data-transfer-download":"\u{e04e}",
89 | "data-transfer-upload":"\u{e04f}",
90 | "delete":"\u{e050}",
91 | "dial":"\u{e051}",
92 | "document":"\u{e052}",
93 | "dollar":"\u{e053}",
94 | "double-quote-sans-left":"\u{e054}",
95 | "double-quote-sans-right":"\u{e055}",
96 | "double-quote-serif-left":"\u{e056}",
97 | "double-quote-serif-right":"\u{e057}",
98 | "droplet":"\u{e058}",
99 | "eject":"\u{e059}",
100 | "elevator":"\u{e05a}",
101 | "ellipses":"\u{e05b}",
102 | "envelope-closed":"\u{e05c}",
103 | "envelope-open":"\u{e05d}",
104 | "euro":"\u{e05e}",
105 | "excerpt":"\u{e05f}",
106 | "expand-down":"\u{e060}",
107 | "expand-left":"\u{e061}",
108 | "expand-right":"\u{e062}",
109 | "expand-up":"\u{e063}",
110 | "external-link":"\u{e064}",
111 | "eye":"\u{e065}",
112 | "eyedropper":"\u{e066}",
113 | "file":"\u{e067}",
114 | "fire":"\u{e068}",
115 | "flag":"\u{e069}",
116 | "flash":"\u{e06a}",
117 | "folder":"\u{e06b}",
118 | "fork":"\u{e06c}",
119 | "fullscreen-enter":"\u{e06d}",
120 | "fullscreen-exit":"\u{e06e}",
121 | "globe":"\u{e06f}",
122 | "graph":"\u{e070}",
123 | "grid-four-up":"\u{e071}",
124 | "grid-three-up":"\u{e072}",
125 | "grid-two-up":"\u{e073}",
126 | "hard-drive":"\u{e074}",
127 | "header":"\u{e075}",
128 | "headphones":"\u{e076}",
129 | "heart":"\u{e077}",
130 | "home":"\u{e078}",
131 | "image":"\u{e079}",
132 | "inbox":"\u{e07a}",
133 | "infinity":"\u{e07b}",
134 | "info":"\u{e07c}",
135 | "italic":"\u{e07d}",
136 | "justify-center":"\u{e07e}",
137 | "justify-left":"\u{e07f}",
138 | "justify-right":"\u{e080}",
139 | "key":"\u{e081}",
140 | "laptop":"\u{e082}",
141 | "layers":"\u{e083}",
142 | "lightbulb":"\u{e084}",
143 | "link-broken":"\u{e085}",
144 | "link-intact":"\u{e086}",
145 | "list-rich":"\u{e087}",
146 | "list":"\u{e088}",
147 | "location":"\u{e089}",
148 | "lock-locked":"\u{e08a}",
149 | "lock-unlocked":"\u{e08b}",
150 | "loop-circular":"\u{e08c}",
151 | "loop-square":"\u{e08d}",
152 | "loop":"\u{e08e}",
153 | "magnifying-glass":"\u{e08f}",
154 | "map-marker":"\u{e090}",
155 | "map":"\u{e091}",
156 | "media-pause":"\u{e092}",
157 | "media-play":"\u{e093}",
158 | "media-record":"\u{e094}",
159 | "media-skip-backward":"\u{e095}",
160 | "media-skip-forward":"\u{e096}",
161 | "media-step-backward":"\u{e097}",
162 | "media-step-forward":"\u{e098}",
163 | "media-stop":"\u{e099}",
164 | "medical-cross":"\u{e09a}",
165 | "menu":"\u{e09b}",
166 | "microphone":"\u{e09c}",
167 | "minus":"\u{e09d}",
168 | "monitor":"\u{e09e}",
169 | "moon":"\u{e09f}",
170 | "move":"\u{e0a0}",
171 | "musical-note":"\u{e0a1}",
172 | "paperclip":"\u{e0a2}",
173 | "pencil":"\u{e0a3}",
174 | "people":"\u{e0a4}",
175 | "person":"\u{e0a5}",
176 | "phone":"\u{e0a6}",
177 | "pie-chart":"\u{e0a7}",
178 | "pin":"\u{e0a8}",
179 | "play-circle":"\u{e0a9}",
180 | "plus":"\u{e0aa}",
181 | "power-standby":"\u{e0ab}",
182 | "print":"\u{e0ac}",
183 | "project":"\u{e0ad}",
184 | "pulse":"\u{e0ae}",
185 | "puzzle-piece":"\u{e0af}",
186 | "question-mark":"\u{e0b0}",
187 | "rain":"\u{e0b1}",
188 | "random":"\u{e0b2}",
189 | "reload":"\u{e0b3}",
190 | "resize-both":"\u{e0b4}",
191 | "resize-height":"\u{e0b5}",
192 | "resize-width":"\u{e0b6}",
193 | "rss-alt":"\u{e0b7}",
194 | "rss":"\u{e0b8}",
195 | "script":"\u{e0b9}",
196 | "share-boxed":"\u{e0ba}",
197 | "share":"\u{e0bb}",
198 | "shield":"\u{e0bc}",
199 | "signal":"\u{e0bd}",
200 | "signpost":"\u{e0be}",
201 | "sort-ascending":"\u{e0bf}",
202 | "sort-descending":"\u{e0c0}",
203 | "spreadsheet":"\u{e0c1}",
204 | "star":"\u{e0c2}",
205 | "sun":"\u{e0c3}",
206 | "tablet":"\u{e0c4}",
207 | "tag":"\u{e0c5}",
208 | "tags":"\u{e0c6}",
209 | "target":"\u{e0c7}",
210 | "task":"\u{e0c8}",
211 | "terminal":"\u{e0c9}",
212 | "text":"\u{e0ca}",
213 | "thumb-down":"\u{e0cb}",
214 | "thumb-up":"\u{e0cc}",
215 | "timer":"\u{e0cd}",
216 | "transfer":"\u{e0ce}",
217 | "trash":"\u{e0cf}",
218 | "underline":"\u{e0d0}",
219 | "vertical-align-bottom":"\u{e0d1}",
220 | "vertical-align-center":"\u{e0d2}",
221 | "vertical-align-top":"\u{e0d3}",
222 | "video":"\u{e0d4}",
223 | "volume-high":"\u{e0d5}",
224 | "volume-low":"\u{e0d6}",
225 | "volume-off":"\u{e0d7}",
226 | "warning":"\u{e0d8}",
227 | "wifi":"\u{e0d9}",
228 | "wrench":"\u{e0da}",
229 | "x":"\u{e0db}",
230 | "yen":"\u{e0dc}",
231 | "zoom-in":"\u{e0dd}",
232 | "zoom-out":"\u{e0de}"
233 | ]
234 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/Shared/Fonts/MapIcon.swift:
--------------------------------------------------------------------------------
1 | //
2 | // MapIcons.swift
3 | // Exa
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 08/07/16.
6 | // Copyright © 2016 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | public let mapIconArr: [String: String] = [
10 | "map-icon-abseiling":"\u{e800}",
11 | "map-icon-accounting":"\u{e801}",
12 | "map-icon-airport":"\u{e802}",
13 | "map-icon-amusement-park":"\u{e803}",
14 | "map-icon-aquarium":"\u{e804}",
15 | "map-icon-archery":"\u{e805}",
16 | "map-icon-art-gallery":"\u{e806}",
17 | "map-icon-assistive-listening-system":"\u{e807}",
18 | "map-icon-atm":"\u{e808}",
19 | "map-icon-audio-description":"\u{e809}",
20 | "map-icon-bakery":"\u{e80a}",
21 | "map-icon-bank":"\u{e80b}",
22 | "map-icon-bar":"\u{e80c}",
23 | "map-icon-baseball":"\u{e80d}",
24 | "map-icon-beauty-salon":"\u{e80e}",
25 | "map-icon-bicycle-store":"\u{e80f}",
26 | "map-icon-bicycling":"\u{e810}",
27 | "map-icon-boat-ramp":"\u{e811}",
28 | "map-icon-boat-tour":"\u{e812}",
29 | "map-icon-boating":"\u{e813}",
30 | "map-icon-book-store":"\u{e814}",
31 | "map-icon-bowling-alley":"\u{e815}",
32 | "map-icon-braille":"\u{e816}",
33 | "map-icon-bus-station":"\u{e817}",
34 | "map-icon-cafe":"\u{e818}",
35 | "map-icon-campground":"\u{e819}",
36 | "map-icon-canoe":"\u{e81a}",
37 | "map-icon-car-dealer":"\u{e81b}",
38 | "map-icon-car-rental":"\u{e81c}",
39 | "map-icon-car-repair":"\u{e81d}",
40 | "map-icon-car-wash":"\u{e81e}",
41 | "map-icon-casino":"\u{e81f}",
42 | "map-icon-cemetery":"\u{e820}",
43 | "map-icon-chairlift":"\u{e821}",
44 | "map-icon-church":"\u{e822}",
45 | "map-icon-circle":"\u{e823}",
46 | "map-icon-city-hall":"\u{e824}",
47 | "map-icon-climbing":"\u{e825}",
48 | "map-icon-closed-captioning":"\u{e826}",
49 | "map-icon-clothing-store":"\u{e827}",
50 | "map-icon-compass":"\u{e828}",
51 | "map-icon-convenience-store":"\u{e829}",
52 | "map-icon-courthouse":"\u{e82a}",
53 | "map-icon-cross-country-skiing":"\u{e82b}",
54 | "map-icon-crosshairs":"\u{e82c}",
55 | "map-icon-dentist":"\u{e82d}",
56 | "map-icon-department-store":"\u{e82e}",
57 | "map-icon-diving":"\u{e82f}",
58 | "map-icon-doctor":"\u{e830}",
59 | "map-icon-electrician":"\u{e831}",
60 | "map-icon-electronics-store":"\u{e832}",
61 | "map-icon-embassy":"\u{e833}",
62 | "map-icon-expand":"\u{e834}",
63 | "map-icon-female":"\u{e835}",
64 | "map-icon-finance":"\u{e836}",
65 | "map-icon-fire-station":"\u{e837}",
66 | "map-icon-fish-cleaning":"\u{e838}",
67 | "map-icon-fishing-pier":"\u{e839}",
68 | "map-icon-fishing":"\u{e83a}",
69 | "map-icon-florist":"\u{e83b}",
70 | "map-icon-food":"\u{e83c}",
71 | "map-icon-fullscreen":"\u{e83d}",
72 | "map-icon-funeral-home":"\u{e83e}",
73 | "map-icon-furniture-store":"\u{e83f}",
74 | "map-icon-gas-station":"\u{e840}",
75 | "map-icon-general-contractor":"\u{e841}",
76 | "map-icon-golf":"\u{e842}",
77 | "map-icon-grocery-or-supermarket":"\u{e843}",
78 | "map-icon-gym":"\u{e844}",
79 | "map-icon-hair-care":"\u{e845}",
80 | "map-icon-hang-gliding":"\u{e846}",
81 | "map-icon-hardware-store":"\u{e847}",
82 | "map-icon-health":"\u{e848}",
83 | "map-icon-hindu-temple":"\u{e849}",
84 | "map-icon-horse-riding":"\u{e84a}",
85 | "map-icon-hospital":"\u{e84b}",
86 | "map-icon-ice-fishing":"\u{e84c}",
87 | "map-icon-ice-skating":"\u{e84d}",
88 | "map-icon-inline-skating":"\u{e84e}",
89 | "map-icon-insurance-agency":"\u{e84f}",
90 | "map-icon-jet-skiing":"\u{e850}",
91 | "map-icon-jewelry-store":"\u{e851}",
92 | "map-icon-kayaking":"\u{e852}",
93 | "map-icon-laundry":"\u{e853}",
94 | "map-icon-lawyer":"\u{e854}",
95 | "map-icon-library":"\u{e855}",
96 | "map-icon-liquor-store":"\u{e856}",
97 | "map-icon-local-government":"\u{e857}",
98 | "map-icon-location-arrow":"\u{e858}",
99 | "map-icon-locksmith":"\u{e859}",
100 | "map-icon-lodging":"\u{e85a}",
101 | "map-icon-low-vision-access":"\u{e85b}",
102 | "map-icon-male":"\u{e85c}",
103 | "map-icon-map-pin":"\u{e85d}",
104 | "map-icon-marina":"\u{e85e}",
105 | "map-icon-mosque":"\u{e85f}",
106 | "map-icon-motobike-trail":"\u{e860}",
107 | "map-icon-movie-rental":"\u{e861}",
108 | "map-icon-movie-theater":"\u{e862}",
109 | "map-icon-moving-company":"\u{e863}",
110 | "map-icon-museum":"\u{e864}",
111 | "map-icon-natural-feature":"\u{e865}",
112 | "map-icon-night-club":"\u{e866}",
113 | "map-icon-open-captioning":"\u{e867}",
114 | "map-icon-painter":"\u{e868}",
115 | "map-icon-park":"\u{e869}",
116 | "map-icon-parking":"\u{e86a}",
117 | "map-icon-pet-store":"\u{e86b}",
118 | "map-icon-pharmacy":"\u{e86c}",
119 | "map-icon-physiotherapist":"\u{e86d}",
120 | "map-icon-place-of-worship":"\u{e86e}",
121 | "map-icon-playground":"\u{e86f}",
122 | "map-icon-plumber":"\u{e870}",
123 | "map-icon-point-of-interest":"\u{e871}",
124 | "map-icon-police":"\u{e872}",
125 | "map-icon-political":"\u{e873}",
126 | "map-icon-post-box":"\u{e874}",
127 | "map-icon-post-office":"\u{e875}",
128 | "map-icon-postal-code-prefix":"\u{e876}",
129 | "map-icon-postal-code":"\u{e877}",
130 | "map-icon-rafting":"\u{e878}",
131 | "map-icon-real-estate-agency":"\u{e879}",
132 | "map-icon-restaurant":"\u{e87a}",
133 | "map-icon-roofing-contractor":"\u{e87b}",
134 | "map-icon-route-pin":"\u{e87c}",
135 | "map-icon-route":"\u{e87d}",
136 | "map-icon-rv-park":"\u{e87e}",
137 | "map-icon-sailing":"\u{e87f}",
138 | "map-icon-school":"\u{e880}",
139 | "map-icon-scuba-diving":"\u{e881}",
140 | "map-icon-search":"\u{e882}",
141 | "map-icon-shield":"\u{e883}",
142 | "map-icon-shopping-mall":"\u{e884}",
143 | "map-icon-sign-language":"\u{e885}",
144 | "map-icon-skateboarding":"\u{e886}",
145 | "map-icon-ski-jumping":"\u{e887}",
146 | "map-icon-skiing":"\u{e888}",
147 | "map-icon-sledding":"\u{e889}",
148 | "map-icon-snow-shoeing":"\u{e88a}",
149 | "map-icon-snow":"\u{e88b}",
150 | "map-icon-snowboarding":"\u{e88c}",
151 | "map-icon-snowmobile":"\u{e88d}",
152 | "map-icon-spa":"\u{e88e}",
153 | "map-icon-square-pin":"\u{e88f}",
154 | "map-icon-square-rounded":"\u{e890}",
155 | "map-icon-square":"\u{e891}",
156 | "map-icon-stadium":"\u{e892}",
157 | "map-icon-storage":"\u{e893}",
158 | "map-icon-store":"\u{e894}",
159 | "map-icon-subway-station":"\u{e895}",
160 | "map-icon-surfing":"\u{e896}",
161 | "map-icon-swimming":"\u{e897}",
162 | "map-icon-synagogue":"\u{e898}",
163 | "map-icon-taxi-stand":"\u{e899}",
164 | "map-icon-tennis":"\u{e89a}",
165 | "map-icon-toilet":"\u{e89b}",
166 | "map-icon-trail-walking":"\u{e89c}",
167 | "map-icon-train-station":"\u{e89d}",
168 | "map-icon-transit-station":"\u{e89e}",
169 | "map-icon-travel-agency":"\u{e89f}",
170 | "map-icon-unisex":"\u{e8a0}",
171 | "map-icon-university":"\u{e8a1}",
172 | "map-icon-veterinary-care":"\u{e8a2}",
173 | "map-icon-viewing":"\u{e8a3}",
174 | "map-icon-volume-control-telephone":"\u{e8a4}",
175 | "map-icon-walking":"\u{e8a5}",
176 | "map-icon-waterskiing":"\u{e8a6}",
177 | "map-icon-whale-watching":"\u{e8a7}",
178 | "map-icon-wheelchair":"\u{e8a8}",
179 | "map-icon-wind-surfing":"\u{e8a9}",
180 | "map-icon-zoo":"\u{e8aa}",
181 | "map-icon-zoom-in-alt":"\u{e8ab}",
182 | "map-icon-zoom-in":"\u{e8ac}",
183 | "map-icon-zoom-out-alt":"\u{e8ad}",
184 | "map-icon-zoom-out":"\u{e8ae}"
185 | ]
186 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/Shared/Fonts/Foundation.swift:
--------------------------------------------------------------------------------
1 | //
2 | // Foundation.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat G. ÇİFTÇİ on 4.06.2020.
6 | // Copyright © 2020 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | public let foundationIconArr: [String: String] = [
10 | "address-book": "\u{f100}",
11 | "alert": "\u{f101}",
12 | "align-center": "\u{f102}",
13 | "align-justify": "\u{f103}",
14 | "align-left": "\u{f104}",
15 | "align-right": "\u{f105}",
16 | "anchor": "\u{f106}",
17 | "annotate": "\u{f107}",
18 | "archive": "\u{f108}",
19 | "arrow-down": "\u{f109}",
20 | "arrow-left": "\u{f10a}",
21 | "arrow-right": "\u{f10b}",
22 | "arrow-up": "\u{f10c}",
23 | "arrows-compress": "\u{f10d}",
24 | "arrows-expand": "\u{f10e}",
25 | "arrows-in": "\u{f10f}",
26 | "arrows-out": "\u{f110}",
27 | "asl": "\u{f111}",
28 | "asterisk": "\u{f112}",
29 | "at-sign": "\u{f113}",
30 | "background-color": "\u{f114}",
31 | "battery-empty": "\u{f115}",
32 | "battery-full": "\u{f116}",
33 | "battery-half": "\u{f117}",
34 | "bitcoin-circle": "\u{f118}",
35 | "bitcoin": "\u{f119}",
36 | "blind": "\u{f11a}",
37 | "bluetooth": "\u{f11b}",
38 | "bold": "\u{f11c}",
39 | "book-bookmark": "\u{f11d}",
40 | "book": "\u{f11e}",
41 | "bookmark": "\u{f11f}",
42 | "braille": "\u{f120}",
43 | "burst-new": "\u{f121}",
44 | "burst-sale": "\u{f122}",
45 | "burst": "\u{f123}",
46 | "calendar": "\u{f124}",
47 | "camera": "\u{f125}",
48 | "check": "\u{f126}",
49 | "checkbox": "\u{f127}",
50 | "clipboard-notes": "\u{f128}",
51 | "clipboard-pencil": "\u{f129}",
52 | "clipboard": "\u{f12a}",
53 | "clock": "\u{f12b}",
54 | "closed-caption": "\u{f12c}",
55 | "cloud": "\u{f12d}",
56 | "comment-minus": "\u{f12e}",
57 | "comment-quotes": "\u{f12f}",
58 | "comment-video": "\u{f130}",
59 | "comment": "\u{f131}",
60 | "comments": "\u{f132}",
61 | "compass": "\u{f133}",
62 | "contrast": "\u{f134}",
63 | "credit-card": "\u{f135}",
64 | "crop": "\u{f136}",
65 | "crown": "\u{f137}",
66 | "css3": "\u{f138}",
67 | "database": "\u{f139}",
68 | "die-five": "\u{f13a}",
69 | "die-four": "\u{f13b}",
70 | "die-one": "\u{f13c}",
71 | "die-six": "\u{f13d}",
72 | "die-three": "\u{f13e}",
73 | "die-two": "\u{f13f}",
74 | "dislike": "\u{f140}",
75 | "dollar-bill": "\u{f141}",
76 | "dollar": "\u{f142}",
77 | "download": "\u{f143}",
78 | "eject": "\u{f144}",
79 | "elevator": "\u{f145}",
80 | "euro": "\u{f146}",
81 | "eye": "\u{f147}",
82 | "fast-forward": "\u{f148}",
83 | "female-symbol": "\u{f149}",
84 | "female": "\u{f14a}",
85 | "filter": "\u{f14b}",
86 | "first-aid": "\u{f14c}",
87 | "flag": "\u{f14d}",
88 | "folder-add": "\u{f14e}",
89 | "folder-lock": "\u{f14f}",
90 | "folder": "\u{f150}",
91 | "foot": "\u{f151}",
92 | "foundation": "\u{f152}",
93 | "graph-bar": "\u{f153}",
94 | "graph-horizontal": "\u{f154}",
95 | "graph-pie": "\u{f155}",
96 | "graph-trend": "\u{f156}",
97 | "guide-dog": "\u{f157}",
98 | "hearing-aid": "\u{f158}",
99 | "heart": "\u{f159}",
100 | "home": "\u{f15a}",
101 | "html5": "\u{f15b}",
102 | "indent-less": "\u{f15c}",
103 | "indent-more": "\u{f15d}",
104 | "info": "\u{f15e}",
105 | "italic": "\u{f15f}",
106 | "key": "\u{f160}",
107 | "laptop": "\u{f161}",
108 | "layout": "\u{f162}",
109 | "lightbulb": "\u{f163}",
110 | "like": "\u{f164}",
111 | "link": "\u{f165}",
112 | "list-bullet": "\u{f166}",
113 | "list-number": "\u{f167}",
114 | "list-thumbnails": "\u{f168}",
115 | "list": "\u{f169}",
116 | "lock": "\u{f16a}",
117 | "loop": "\u{f16b}",
118 | "magnifying-glass": "\u{f16c}",
119 | "mail": "\u{f16d}",
120 | "male-female": "\u{f16e}",
121 | "male-symbol": "\u{f16f}",
122 | "male": "\u{f170}",
123 | "map": "\u{f171}",
124 | "marker": "\u{f172}",
125 | "megaphone": "\u{f173}",
126 | "microphone": "\u{f174}",
127 | "minus-circle": "\u{f175}",
128 | "minus": "\u{f176}",
129 | "mobile-signal": "\u{f177}",
130 | "mobile": "\u{f178}",
131 | "monitor": "\u{f179}",
132 | "mountains": "\u{f17a}",
133 | "music": "\u{f17b}",
134 | "next": "\u{f17c}",
135 | "no-dogs": "\u{f17d}",
136 | "no-smoking": "\u{f17e}",
137 | "page-add": "\u{f17f}",
138 | "page-copy": "\u{f180}",
139 | "page-csv": "\u{f181}",
140 | "page-delete": "\u{f182}",
141 | "page-doc": "\u{f183}",
142 | "page-edit": "\u{f184}",
143 | "page-export-csv": "\u{f185}",
144 | "page-export-doc": "\u{f186}",
145 | "page-export-pdf": "\u{f187}",
146 | "page-export": "\u{f188}",
147 | "page-filled": "\u{f189}",
148 | "page-multiple": "\u{f18a}",
149 | "page-pdf": "\u{f18b}",
150 | "page-remove": "\u{f18c}",
151 | "page-search": "\u{f18d}",
152 | "page": "\u{f18e}",
153 | "paint-bucket": "\u{f18f}",
154 | "paperclip": "\u{f190}",
155 | "pause": "\u{f191}",
156 | "paw": "\u{f192}",
157 | "paypal": "\u{f193}",
158 | "pencil": "\u{f194}",
159 | "photo": "\u{f195}",
160 | "play-circle": "\u{f196}",
161 | "play-video": "\u{f197}",
162 | "play": "\u{f198}",
163 | "plus": "\u{f199}",
164 | "pound": "\u{f19a}",
165 | "power": "\u{f19b}",
166 | "previous": "\u{f19c}",
167 | "price-tag": "\u{f19d}",
168 | "pricetag-multiple": "\u{f19e}",
169 | "print": "\u{f19f}",
170 | "prohibited": "\u{f1a0}",
171 | "projection-screen": "\u{f1a1}",
172 | "puzzle": "\u{f1a2}",
173 | "quote": "\u{f1a3}",
174 | "record": "\u{f1a4}",
175 | "refresh": "\u{f1a5}",
176 | "results-demographics": "\u{f1a6}",
177 | "results": "\u{f1a7}",
178 | "rewind-ten": "\u{f1a8}",
179 | "rewind": "\u{f1a9}",
180 | "rss": "\u{f1aa}",
181 | "safety-cone": "\u{f1ab}",
182 | "save": "\u{f1ac}",
183 | "share": "\u{f1ad}",
184 | "sheriff-badge": "\u{f1ae}",
185 | "shield": "\u{f1af}",
186 | "shopping-bag": "\u{f1b0}",
187 | "shopping-cart": "\u{f1b1}",
188 | "shuffle": "\u{f1b2}",
189 | "skull": "\u{f1b3}",
190 | "social-500px": "\u{f1b4}",
191 | "social-adobe": "\u{f1b5}",
192 | "social-amazon": "\u{f1b6}",
193 | "social-android": "\u{f1b7}",
194 | "social-apple": "\u{f1b8}",
195 | "social-behance": "\u{f1b9}",
196 | "social-bing": "\u{f1ba}",
197 | "social-blogger": "\u{f1bb}",
198 | "social-delicious": "\u{f1bc}",
199 | "social-designer-news": "\u{f1bd}",
200 | "social-deviant-art": "\u{f1be}",
201 | "social-digg": "\u{f1bf}",
202 | "social-dribbble": "\u{f1c0}",
203 | "social-drive": "\u{f1c1}",
204 | "social-dropbox": "\u{f1c2}",
205 | "social-evernote": "\u{f1c3}",
206 | "social-facebook": "\u{f1c4}",
207 | "social-flickr": "\u{f1c5}",
208 | "social-forrst": "\u{f1c6}",
209 | "social-foursquare": "\u{f1c7}",
210 | "social-game-center": "\u{f1c8}",
211 | "social-github": "\u{f1c9}",
212 | "social-google-plus": "\u{f1ca}",
213 | "social-hacker-news": "\u{f1cb}",
214 | "social-hi5": "\u{f1cc}",
215 | "social-instagram": "\u{f1cd}",
216 | "social-joomla": "\u{f1ce}",
217 | "social-lastfm": "\u{f1cf}",
218 | "social-linkedin": "\u{f1d0}",
219 | "social-medium": "\u{f1d1}",
220 | "social-myspace": "\u{f1d2}",
221 | "social-orkut": "\u{f1d3}",
222 | "social-path": "\u{f1d4}",
223 | "social-picasa": "\u{f1d5}",
224 | "social-pinterest": "\u{f1d6}",
225 | "social-rdio": "\u{f1d7}",
226 | "social-reddit": "\u{f1d8}",
227 | "social-skillshare": "\u{f1d9}",
228 | "social-skype": "\u{f1da}",
229 | "social-smashing-mag": "\u{f1db}",
230 | "social-snapchat": "\u{f1dc}",
231 | "social-spotify": "\u{f1dd}",
232 | "social-squidoo": "\u{f1de}",
233 | "social-stack-overflow": "\u{f1df}",
234 | "social-steam": "\u{f1e0}",
235 | "social-stumbleupon": "\u{f1e1}",
236 | "social-treehouse": "\u{f1e2}",
237 | "social-tumblr": "\u{f1e3}",
238 | "social-twitter": "\u{f1e4}",
239 | "social-vimeo": "\u{f1e5}",
240 | "social-windows": "\u{f1e6}",
241 | "social-xbox": "\u{f1e7}",
242 | "social-yahoo": "\u{f1e8}",
243 | "social-yelp": "\u{f1e9}",
244 | "social-youtube": "\u{f1ea}",
245 | "social-zerply": "\u{f1eb}",
246 | "social-zurb": "\u{f1ec}",
247 | "sound": "\u{f1ed}",
248 | "star": "\u{f1ee}",
249 | "stop": "\u{f1ef}",
250 | "strikethrough": "\u{f1f0}",
251 | "subscript": "\u{f1f1}",
252 | "superscript": "\u{f1f2}",
253 | "tablet-landscape": "\u{f1f3}",
254 | "tablet-portrait": "\u{f1f4}",
255 | "target-two": "\u{f1f5}",
256 | "target": "\u{f1f6}",
257 | "telephone-accessible": "\u{f1f7}",
258 | "telephone": "\u{f1f8}",
259 | "text-color": "\u{f1f9}",
260 | "thumbnails": "\u{f1fa}",
261 | "ticket": "\u{f1fb}",
262 | "torso-business": "\u{f1fc}",
263 | "torso-female": "\u{f1fd}",
264 | "torso": "\u{f1fe}",
265 | "torsos-all-female": "\u{f1ff}",
266 | "torsos-all": "\u{f200}",
267 | "torsos-female-male": "\u{f201}",
268 | "torsos-male-female": "\u{f202}",
269 | "torsos": "\u{f203}",
270 | "trash": "\u{f204}",
271 | "trees": "\u{f205}",
272 | "trophy": "\u{f206}",
273 | "underline": "\u{f207}",
274 | "universal-access": "\u{f208}",
275 | "unlink": "\u{f209}",
276 | "unlock": "\u{f20a}",
277 | "upload-cloud": "\u{f20b}",
278 | "upload": "\u{f20c}",
279 | "usb": "\u{f20d}",
280 | "video": "\u{f20e}",
281 | "volume-none": "\u{f20f}",
282 | "volume-strike": "\u{f210}",
283 | "volume": "\u{f211}",
284 | "web": "\u{f212}",
285 | "wheelchair": "\u{f213}",
286 | "widget": "\u{f214}",
287 | "wrench": "\u{f215}",
288 | "x-circle": "\u{f216}",
289 | "x": "\u{f217}",
290 | "yen": "\u{f218}",
291 | "zoom-in": "\u{f219}",
292 | "zoom-out": "\u{f21a}"
293 | ]
294 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/Shared/Fonts/Captain.swift:
--------------------------------------------------------------------------------
1 | //
2 | // Captain.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat G. ÇİFTÇİ on 4.06.2020.
6 | // Copyright © 2020 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | public let captainIconArr: [String: String] = [
10 | "001":"\u{e600}",
11 | "002":"\u{e601}",
12 | "003":"\u{e602}",
13 | "004":"\u{e603}",
14 | "005":"\u{e604}",
15 | "006":"\u{e605}",
16 | "007":"\u{e606}",
17 | "008":"\u{e607}",
18 | "009":"\u{e608}",
19 | "010":"\u{e609}",
20 | "011":"\u{e60a}",
21 | "012":"\u{e60b}",
22 | "013":"\u{e60c}",
23 | "014":"\u{e60d}",
24 | "015":"\u{e60e}",
25 | "016":"\u{e60f}",
26 | "017":"\u{e610}",
27 | "018":"\u{e611}",
28 | "019":"\u{e612}",
29 | "020":"\u{e613}",
30 | "021":"\u{e614}",
31 | "022":"\u{e615}",
32 | "023":"\u{e616}",
33 | "024":"\u{e617}",
34 | "025":"\u{e618}",
35 | "026":"\u{e619}",
36 | "027":"\u{e61a}",
37 | "028":"\u{e61b}",
38 | "029":"\u{e61c}",
39 | "030":"\u{e61d}",
40 | "031":"\u{e61e}",
41 | "032":"\u{e61f}",
42 | "033":"\u{e620}",
43 | "034":"\u{e621}",
44 | "035":"\u{e622}",
45 | "036":"\u{e623}",
46 | "037":"\u{e624}",
47 | "038":"\u{e625}",
48 | "039":"\u{e626}",
49 | "040":"\u{e627}",
50 | "041":"\u{e628}",
51 | "042":"\u{e629}",
52 | "043":"\u{e62a}",
53 | "044":"\u{e62b}",
54 | "045":"\u{e62c}",
55 | "046":"\u{e62d}",
56 | "047":"\u{e62e}",
57 | "048":"\u{e62f}",
58 | "049":"\u{e630}",
59 | "050":"\u{e631}",
60 | "051":"\u{e632}",
61 | "052":"\u{e633}",
62 | "053":"\u{e634}",
63 | "054":"\u{e635}",
64 | "055":"\u{e636}",
65 | "056":"\u{e637}",
66 | "057":"\u{e638}",
67 | "058":"\u{e639}",
68 | "059":"\u{e63a}",
69 | "060":"\u{e63b}",
70 | "061":"\u{e63c}",
71 | "062":"\u{e63d}",
72 | "063":"\u{e63e}",
73 | "064":"\u{e63f}",
74 | "065":"\u{e640}",
75 | "066":"\u{e641}",
76 | "067":"\u{e642}",
77 | "068":"\u{e643}",
78 | "069":"\u{e644}",
79 | "070":"\u{e645}",
80 | "071":"\u{e646}",
81 | "072":"\u{e647}",
82 | "073":"\u{e648}",
83 | "074":"\u{e649}",
84 | "075":"\u{e64a}",
85 | "076":"\u{e64b}",
86 | "077":"\u{e64c}",
87 | "078":"\u{e64d}",
88 | "079":"\u{e64e}",
89 | "080":"\u{e64f}",
90 | "081":"\u{e650}",
91 | "082":"\u{e651}",
92 | "083":"\u{e652}",
93 | "084":"\u{e653}",
94 | "085":"\u{e654}",
95 | "086":"\u{e655}",
96 | "087":"\u{e656}",
97 | "088":"\u{e657}",
98 | "089":"\u{e658}",
99 | "090":"\u{e659}",
100 | "091":"\u{e65a}",
101 | "092":"\u{e65b}",
102 | "093":"\u{e65c}",
103 | "094":"\u{e65d}",
104 | "095":"\u{e65e}",
105 | "096":"\u{e65f}",
106 | "097":"\u{e660}",
107 | "98": "\u{e661}",
108 | "099":"\u{e662}",
109 | "100":"\u{e663}",
110 | "101":"\u{e664}",
111 | "102":"\u{e665}",
112 | "103":"\u{e666}",
113 | "104":"\u{e667}",
114 | "105":"\u{e668}",
115 | "106":"\u{e669}",
116 | "107":"\u{e66a}",
117 | "108":"\u{e66b}",
118 | "109":"\u{e66c}",
119 | "110":"\u{e66d}",
120 | "111":"\u{e66e}",
121 | "112":"\u{e66f}",
122 | "113":"\u{e670}",
123 | "114":"\u{e671}",
124 | "115":"\u{e672}",
125 | "116":"\u{e673}",
126 | "117":"\u{e674}",
127 | "118":"\u{e675}",
128 | "119":"\u{e676}",
129 | "120":"\u{e677}",
130 | "121":"\u{e678}",
131 | "122":"\u{e679}",
132 | "123":"\u{e67a}",
133 | "124":"\u{e67b}",
134 | "125":"\u{e67c}",
135 | "126":"\u{e67d}",
136 | "127":"\u{e67e}",
137 | "128":"\u{e67f}",
138 | "129":"\u{e680}",
139 | "130":"\u{e681}",
140 | "131":"\u{e682}",
141 | "132":"\u{e683}",
142 | "133":"\u{e684}",
143 | "134":"\u{e685}",
144 | "135":"\u{e686}",
145 | "136":"\u{e687}",
146 | "137":"\u{e688}",
147 | "138":"\u{e689}",
148 | "139":"\u{e68a}",
149 | "140":"\u{e68b}",
150 | "141":"\u{e68c}",
151 | "142":"\u{e68d}",
152 | "143":"\u{e68e}",
153 | "144":"\u{e68f}",
154 | "145":"\u{e690}",
155 | "146":"\u{e691}",
156 | "147":"\u{e692}",
157 | "148":"\u{e693}",
158 | "149":"\u{e694}",
159 | "150":"\u{e695}",
160 | "151":"\u{e696}",
161 | "152":"\u{e697}",
162 | "153":"\u{e698}",
163 | "154":"\u{e699}",
164 | "155":"\u{e69a}",
165 | "156":"\u{e69b}",
166 | "157":"\u{e69c}",
167 | "158":"\u{e69d}",
168 | "159":"\u{e69e}",
169 | "160":"\u{e69f}",
170 | "161":"\u{e6a0}",
171 | "162":"\u{e6a1}",
172 | "163":"\u{e6a2}",
173 | "164":"\u{e6a3}",
174 | "165":"\u{e6a4}",
175 | "166":"\u{e6a5}",
176 | "167":"\u{e6a6}",
177 | "168":"\u{e6a7}",
178 | "169":"\u{e6a8}",
179 | "170":"\u{e6a9}",
180 | "171":"\u{e6aa}",
181 | "172":"\u{e6ab}",
182 | "173":"\u{e6ac}",
183 | "174":"\u{e6ad}",
184 | "175":"\u{e6ae}",
185 | "176":"\u{e6af}",
186 | "177":"\u{e6b0}",
187 | "178":"\u{e6b1}",
188 | "179":"\u{e6b2}",
189 | "180":"\u{e6b3}",
190 | "181":"\u{e6b4}",
191 | "182":"\u{e6b5}",
192 | "183":"\u{e6b6}",
193 | "184":"\u{e6b7}",
194 | "185":"\u{e6b8}",
195 | "186":"\u{e6b9}",
196 | "187":"\u{e6ba}",
197 | "188":"\u{e6bb}",
198 | "189":"\u{e6bc}",
199 | "190":"\u{e6bd}",
200 | "191":"\u{e6be}",
201 | "192":"\u{e6bf}",
202 | "193":"\u{e6c0}",
203 | "194":"\u{e6c1}",
204 | "195":"\u{e6c2}",
205 | "196":"\u{e6c3}",
206 | "197":"\u{e6c4}",
207 | "198":"\u{e6c5}",
208 | "199":"\u{e6c6}",
209 | "200":"\u{e6c7}",
210 | "201":"\u{e6c8}",
211 | "202":"\u{e6c9}",
212 | "203":"\u{e6ca}",
213 | "204":"\u{e6cb}",
214 | "205":"\u{e6cc}",
215 | "206":"\u{e6cd}",
216 | "207":"\u{e6ce}",
217 | "208":"\u{e6cf}",
218 | "209":"\u{e6d0}",
219 | "210":"\u{e6d1}",
220 | "211":"\u{e6d2}",
221 | "212":"\u{e6d3}",
222 | "213":"\u{e6d4}",
223 | "214":"\u{e6d5}",
224 | "215":"\u{e6d6}",
225 | "216":"\u{e6d7}",
226 | "217":"\u{e6d8}",
227 | "218":"\u{e6d9}",
228 | "219":"\u{e6da}",
229 | "220":"\u{e6db}",
230 | "221":"\u{e6dc}",
231 | "222":"\u{e6dd}",
232 | "223":"\u{e6de}",
233 | "224":"\u{e6df}",
234 | "225":"\u{e6e0}",
235 | "226":"\u{e6e1}",
236 | "227":"\u{e6e2}",
237 | "228":"\u{e6e3}",
238 | "229":"\u{e6e4}",
239 | "230":"\u{e6e5}",
240 | "231":"\u{e6e6}",
241 | "232":"\u{e6e7}",
242 | "233":"\u{e6e8}",
243 | "234":"\u{e6e9}",
244 | "235":"\u{e6ea}",
245 | "236":"\u{e6eb}",
246 | "237":"\u{e6ec}",
247 | "238":"\u{e6ed}",
248 | "239":"\u{e6ee}",
249 | "240":"\u{e6ef}",
250 | "241":"\u{e6f0}",
251 | "242":"\u{e6f1}",
252 | "243":"\u{e6f2}",
253 | "244":"\u{e6f3}",
254 | "245":"\u{e6f4}",
255 | "246":"\u{e6f5}",
256 | "247":"\u{e6f6}",
257 | "248":"\u{e6f7}",
258 | "249":"\u{e6f8}",
259 | "250":"\u{e6f9}",
260 | "251":"\u{e6fa}",
261 | "252":"\u{e6fb}",
262 | "253":"\u{e6fc}",
263 | "254":"\u{e6fd}",
264 | "255":"\u{e6fe}",
265 | "256":"\u{e6ff}",
266 | "257":"\u{e700}",
267 | "258":"\u{e701}",
268 | "259":"\u{e702}",
269 | "260":"\u{e703}",
270 | "261":"\u{e704}",
271 | "262":"\u{e705}",
272 | "263":"\u{e706}",
273 | "264":"\u{e707}",
274 | "265":"\u{e708}",
275 | "266":"\u{e709}",
276 | "267":"\u{e70a}",
277 | "268":"\u{e70b}",
278 | "269":"\u{e70c}",
279 | "270":"\u{e70d}",
280 | "271":"\u{e70e}",
281 | "272":"\u{e70f}",
282 | "273":"\u{e710}",
283 | "274":"\u{e711}",
284 | "275":"\u{e712}",
285 | "276":"\u{e713}",
286 | "277":"\u{e714}",
287 | "278":"\u{e715}",
288 | "279":"\u{e716}",
289 | "280":"\u{e717}",
290 | "281":"\u{e718}",
291 | "282":"\u{e719}",
292 | "283":"\u{e71a}",
293 | "284":"\u{e71b}",
294 | "285":"\u{e71c}",
295 | "286":"\u{e71d}",
296 | "287":"\u{e71e}",
297 | "288":"\u{e71f}",
298 | "289":"\u{e720}",
299 | "290":"\u{e721}",
300 | "291":"\u{e722}",
301 | "292":"\u{e723}",
302 | "293":"\u{e724}",
303 | "294":"\u{e725}",
304 | "295":"\u{e726}",
305 | "296":"\u{e727}",
306 | "297":"\u{e728}",
307 | "298":"\u{e729}",
308 | "299":"\u{e72a}",
309 | "300":"\u{e72b}",
310 | "301":"\u{e72c}",
311 | "302":"\u{e72d}",
312 | "303":"\u{e72e}",
313 | "304":"\u{e72f}",
314 | "305":"\u{e730}",
315 | "306":"\u{e731}",
316 | "307":"\u{e732}",
317 | "308":"\u{e733}",
318 | "309":"\u{e734}",
319 | "310":"\u{e735}",
320 | "311":"\u{e736}",
321 | "312":"\u{e737}",
322 | "313":"\u{e738}",
323 | "314":"\u{e739}",
324 | "315":"\u{e73a}",
325 | "316":"\u{e73b}",
326 | "317":"\u{e73c}",
327 | "318":"\u{e73d}",
328 | "319":"\u{e73e}",
329 | "320":"\u{e73f}",
330 | "321":"\u{e740}",
331 | "322":"\u{e741}",
332 | "323":"\u{e742}",
333 | "324":"\u{e743}",
334 | "325":"\u{e744}",
335 | "326":"\u{e745}",
336 | "327":"\u{e746}",
337 | "328":"\u{e747}",
338 | "329":"\u{e748}",
339 | "330":"\u{e749}",
340 | "331":"\u{e74a}",
341 | "332":"\u{e74b}",
342 | "333":"\u{e74c}",
343 | "334":"\u{e74d}",
344 | "335":"\u{e74e}",
345 | "336":"\u{e74f}",
346 | "337":"\u{e750}",
347 | "338":"\u{e751}",
348 | "339":"\u{e752}",
349 | "340":"\u{e753}",
350 | "341":"\u{e754}",
351 | "342":"\u{e755}",
352 | "343":"\u{e756}",
353 | "344":"\u{e757}",
354 | "345":"\u{e758}",
355 | "346":"\u{e759}",
356 | "347":"\u{e75a}",
357 | "348":"\u{e75b}",
358 | "349":"\u{e75c}",
359 | "350":"\u{e75d}",
360 | "351":"\u{e75e}",
361 | "352":"\u{e75f}",
362 | "353":"\u{e760}",
363 | "354":"\u{e761}",
364 | "355":"\u{e762}",
365 | "356":"\u{e763}",
366 | "357":"\u{e764}",
367 | "358":"\u{e765}",
368 | "359":"\u{e766}",
369 | "360":"\u{e767}",
370 | "361":"\u{e768}",
371 | "362":"\u{e769}",
372 | "363":"\u{e76a}",
373 | "364":"\u{e76b}",
374 | "365":"\u{e76c}",
375 | "366":"\u{e76d}",
376 | "367":"\u{e76e}",
377 | "368":"\u{e76f}",
378 | "369":"\u{e770}",
379 | "370":"\u{e771}",
380 | "371":"\u{e772}",
381 | "372":"\u{e773}",
382 | "373":"\u{e774}",
383 | "374":"\u{e775}",
384 | "375":"\u{e776}"
385 | ]
386 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/Shared/Fonts/ThemifyIcon.swift:
--------------------------------------------------------------------------------
1 | //
2 | // Themify.swift
3 | // Exa
4 | //
5 | // Created by Sedat Gökbek ÇİFTÇİ on 08/07/16.
6 | // Copyright © 2016 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | public let temifyIconArr: [String: String] = [
10 | "wand":"\u{e600}",
11 | "volume":"\u{e601}",
12 | "user":"\u{e602}",
13 | "unlock":"\u{e603}",
14 | "unlink":"\u{e604}",
15 | "trash":"\u{e605}",
16 | "thought":"\u{e606}",
17 | "target":"\u{e607}",
18 | "tag":"\u{e608}",
19 | "tablet":"\u{e609}",
20 | "star":"\u{e60a}",
21 | "spray":"\u{e60b}",
22 | "signal":"\u{e60c}",
23 | "shopping.cart":"\u{e60d}",
24 | "shopping.cart.full":"\u{e60e}",
25 | "settings":"\u{e60f}",
26 | "search":"\u{e610}",
27 | "zoom.in":"\u{e611}",
28 | "zoom.out":"\u{e612}",
29 | "cut":"\u{e613}",
30 | "ruler":"\u{e614}",
31 | "ruler.pencil":"\u{e615}",
32 | "ruler.alt":"\u{e616}",
33 | "bookmark":"\u{e617}",
34 | "bookmark.alt":"\u{e618}",
35 | "reload":"\u{e619}",
36 | "plus":"\u{e61a}",
37 | "pin":"\u{e61b}",
38 | "pencil":"\u{e61c}",
39 | "pencil.alt":"\u{e61d}",
40 | "paint.roller":"\u{e61e}",
41 | "paint.bucket":"\u{e61f}",
42 | "na":"\u{e620}",
43 | "mobile":"\u{e621}",
44 | "minus":"\u{e622}",
45 | "medall":"\u{e623}",
46 | "medall.alt":"\u{e624}",
47 | "marker":"\u{e625}",
48 | "marker.alt":"\u{e626}",
49 | "arrow.up":"\u{e627}",
50 | "arrow.right":"\u{e628}",
51 | "arrow.left":"\u{e629}",
52 | "arrow.down":"\u{e62a}",
53 | "lock":"\u{e62b}",
54 | "location.arrow":"\u{e62c}",
55 | "link":"\u{e62d}",
56 | "layout":"\u{e62e}",
57 | "layers":"\u{e62f}",
58 | "layers.alt":"\u{e630}",
59 | "key":"\u{e631}",
60 | "import":"\u{e632}",
61 | "image":"\u{e633}",
62 | "heart":"\u{e634}",
63 | "heart.broken":"\u{e635}",
64 | "hand.stop":"\u{e636}",
65 | "hand.open":"\u{e637}",
66 | "hand.drag":"\u{e638}",
67 | "folder":"\u{e639}",
68 | "flag":"\u{e63a}",
69 | "flag.alt":"\u{e63b}",
70 | "flag.alt.2":"\u{e63c}",
71 | "eye":"\u{e63d}",
72 | "export":"\u{e63e}",
73 | "exchange.vertical":"\u{e63f}",
74 | "desktop":"\u{e640}",
75 | "cup":"\u{e641}",
76 | "crown":"\u{e642}",
77 | "comments":"\u{e643}",
78 | "comment":"\u{e644}",
79 | "comment.alt":"\u{e645}",
80 | "close":"\u{e646}",
81 | "clip":"\u{e647}",
82 | "angle.up":"\u{e648}",
83 | "angle.right":"\u{e649}",
84 | "angle.left":"\u{e64a}",
85 | "angle.down":"\u{e64b}",
86 | "check":"\u{e64c}",
87 | "check.box":"\u{e64d}",
88 | "camera":"\u{e64e}",
89 | "announcement":"\u{e64f}",
90 | "brush":"\u{e650}",
91 | "briefcase":"\u{e651}",
92 | "bolt":"\u{e652}",
93 | "bolt.alt":"\u{e653}",
94 | "blackboard":"\u{e654}",
95 | "bag":"\u{e655}",
96 | "move":"\u{e656}",
97 | "arrows.vertical":"\u{e657}",
98 | "arrows.horizontal":"\u{e658}",
99 | "fullscreen":"\u{e659}",
100 | "arrow.top.right":"\u{e65a}",
101 | "arrow.top.left":"\u{e65b}",
102 | "arrow.circle.up":"\u{e65c}",
103 | "arrow.circle.right":"\u{e65d}",
104 | "arrow.circle.left":"\u{e65e}",
105 | "arrow.circle.down":"\u{e65f}",
106 | "angle.double.up":"\u{e660}",
107 | "angle.double.right":"\u{e661}",
108 | "angle.double.left":"\u{e662}",
109 | "angle.double.down":"\u{e663}",
110 | "zip":"\u{e664}",
111 | "world":"\u{e665}",
112 | "wheelchair":"\u{e666}",
113 | "view.list":"\u{e667}",
114 | "view.list.alt":"\u{e668}",
115 | "view.grid":"\u{e669}",
116 | "uppercase":"\u{e66a}",
117 | "upload":"\u{e66b}",
118 | "underline":"\u{e66c}",
119 | "truck":"\u{e66d}",
120 | "timer":"\u{e66e}",
121 | "ticket":"\u{e66f}",
122 | "thumb.up":"\u{e670}",
123 | "thumb.down":"\u{e671}",
124 | "text":"\u{e672}",
125 | "stats.up":"\u{e673}",
126 | "stats.down":"\u{e674}",
127 | "split.v":"\u{e675}",
128 | "split.h":"\u{e676}",
129 | "smallcap":"\u{e677}",
130 | "shine":"\u{e678}",
131 | "shift.right":"\u{e679}",
132 | "shift.left":"\u{e67a}",
133 | "shield":"\u{e67b}",
134 | "notepad":"\u{e67c}",
135 | "server":"\u{e67d}",
136 | "quote.right":"\u{e67e}",
137 | "quote.left":"\u{e67f}",
138 | "pulse":"\u{e680}",
139 | "printer":"\u{e681}",
140 | "power.off":"\u{e682}",
141 | "plug":"\u{e683}",
142 | "pie.chart":"\u{e684}",
143 | "paragraph":"\u{e685}",
144 | "panel":"\u{e686}",
145 | "package":"\u{e687}",
146 | "music":"\u{e688}",
147 | "music.alt":"\u{e689}",
148 | "mouse":"\u{e68a}",
149 | "mouse.alt":"\u{e68b}",
150 | "money":"\u{e68c}",
151 | "microphone":"\u{e68d}",
152 | "menu":"\u{e68e}",
153 | "menu.alt":"\u{e68f}",
154 | "map":"\u{e690}",
155 | "map.alt":"\u{e691}",
156 | "loop":"\u{e692}",
157 | "location.pin":"\u{e693}",
158 | "list":"\u{e694}",
159 | "light.bulb":"\u{e695}",
160 | "Italic":"\u{e696}",
161 | "info":"\u{e697}",
162 | "infinite":"\u{e698}",
163 | "id.badge":"\u{e699}",
164 | "hummer":"\u{e69a}",
165 | "home":"\u{e69b}",
166 | "help":"\u{e69c}",
167 | "headphone":"\u{e69d}",
168 | "harddrives":"\u{e69e}",
169 | "harddrive":"\u{e69f}",
170 | "gift":"\u{e6a0}",
171 | "game":"\u{e6a1}",
172 | "filter":"\u{e6a2}",
173 | "files":"\u{e6a3}",
174 | "file":"\u{e6a4}",
175 | "eraser":"\u{e6a5}",
176 | "envelope":"\u{e6a6}",
177 | "download":"\u{e6a7}",
178 | "direction":"\u{e6a8}",
179 | "direction.alt":"\u{e6a9}",
180 | "dashboard":"\u{e6aa}",
181 | "control.stop":"\u{e6ab}",
182 | "control.shuffle":"\u{e6ac}",
183 | "control.play":"\u{e6ad}",
184 | "control.pause":"\u{e6ae}",
185 | "control.forward":"\u{e6af}",
186 | "control.backward":"\u{e6b0}",
187 | "cloud":"\u{e6b1}",
188 | "cloud.up":"\u{e6b2}",
189 | "cloud.down":"\u{e6b3}",
190 | "clipboard":"\u{e6b4}",
191 | "car":"\u{e6b5}",
192 | "calendar":"\u{e6b6}",
193 | "book":"\u{e6b7}",
194 | "bell":"\u{e6b8}",
195 | "basketball":"\u{e6b9}",
196 | "bar.chart":"\u{e6ba}",
197 | "bar.chart.alt":"\u{e6bb}",
198 | "back.right":"\u{e6bc}",
199 | "back.left":"\u{e6bd}",
200 | "arrows.corner":"\u{e6be}",
201 | "archive":"\u{e6bf}",
202 | "anchor":"\u{e6c0}",
203 | "align.right":"\u{e6c1}",
204 | "align.left":"\u{e6c2}",
205 | "align.justify":"\u{e6c3}",
206 | "align.center":"\u{e6c4}",
207 | "alert":"\u{e6c5}",
208 | "alarm.clock":"\u{e6c6}",
209 | "agenda":"\u{e6c7}",
210 | "write":"\u{e6c8}",
211 | "window":"\u{e6c9}",
212 | "widgetized":"\u{e6ca}",
213 | "widget":"\u{e6cb}",
214 | "widget.alt":"\u{e6cc}",
215 | "wallet":"\u{e6cd}",
216 | "video.clapper":"\u{e6ce}",
217 | "video.camera":"\u{e6cf}",
218 | "vector":"\u{e6d0}",
219 | "themify.logo":"\u{e6d1}",
220 | "themify.favicon":"\u{e6d2}",
221 | "themify.favicon.alt":"\u{e6d3}",
222 | "support":"\u{e6d4}",
223 | "stamp":"\u{e6d5}",
224 | "split.v.alt":"\u{e6d6}",
225 | "slice":"\u{e6d7}",
226 | "shortcode":"\u{e6d8}",
227 | "shift.right.alt":"\u{e6d9}",
228 | "shift.left.alt":"\u{e6da}",
229 | "ruler.alt.2":"\u{e6db}",
230 | "receipt":"\u{e6dc}",
231 | "pin2":"\u{e6dd}",
232 | "pin.alt":"\u{e6de}",
233 | "pencil.alt2":"\u{e6df}",
234 | "palette":"\u{e6e0}",
235 | "more":"\u{e6e1}",
236 | "more.alt":"\u{e6e2}",
237 | "microphone.alt":"\u{e6e3}",
238 | "magnet":"\u{e6e4}",
239 | "line.double":"\u{e6e5}",
240 | "line.dotted":"\u{e6e6}",
241 | "line.dashed":"\u{e6e7}",
242 | "layout.width.full":"\u{e6e8}",
243 | "layout.width.default":"\u{e6e9}",
244 | "layout.width.default.alt":"\u{e6ea}",
245 | "layout.tab":"\u{e6eb}",
246 | "layout.tab.window":"\u{e6ec}",
247 | "layout.tab.v":"\u{e6ed}",
248 | "layout.tab.min":"\u{e6ee}",
249 | "layout.slider":"\u{e6ef}",
250 | "layout.slider.alt":"\u{e6f0}",
251 | "layout.sidebar.right":"\u{e6f1}",
252 | "layout.sidebar.none":"\u{e6f2}",
253 | "layout.sidebar.left":"\u{e6f3}",
254 | "layout.placeholder":"\u{e6f4}",
255 | "layout.menu":"\u{e6f5}",
256 | "layout.menu.v":"\u{e6f6}",
257 | "layout.menu.separated":"\u{e6f7}",
258 | "layout.menu.full":"\u{e6f8}",
259 | "layout.media.right.alt":"\u{e6f9}",
260 | "layout.media.right":"\u{e6fa}",
261 | "layout.media.overlay":"\u{e6fb}",
262 | "layout.media.overlay.alt":"\u{e6fc}",
263 | "layout.media.overlay.alt.2":"\u{e6fd}",
264 | "layout.media.left.alt":"\u{e6fe}",
265 | "layout.media.left":"\u{e6ff}",
266 | "layout.media.center.alt":"\u{e700}",
267 | "layout.media.center":"\u{e701}",
268 | "layout.list.thumb":"\u{e702}",
269 | "layout.list.thumb.alt":"\u{e703}",
270 | "layout.list.post":"\u{e704}",
271 | "layout.list.large.image":"\u{e705}",
272 | "layout.line.solid":"\u{e706}",
273 | "layout.grid4":"\u{e707}",
274 | "layout.grid3":"\u{e708}",
275 | "layout.grid2":"\u{e709}",
276 | "layout.grid2.thumb":"\u{e70a}",
277 | "layout.cta.right":"\u{e70b}",
278 | "layout.cta.left":"\u{e70c}",
279 | "layout.cta.center":"\u{e70d}",
280 | "layout.cta.btn.right":"\u{e70e}",
281 | "layout.cta.btn.left":"\u{e70f}",
282 | "layout.column4":"\u{e710}",
283 | "layout.column3":"\u{e711}",
284 | "layout.column2":"\u{e712}",
285 | "layout.accordion.separated":"\u{e713}",
286 | "layout.accordion.merged":"\u{e714}",
287 | "layout.accordion.list":"\u{e715}",
288 | "ink.pen":"\u{e716}",
289 | "info.alt":"\u{e717}",
290 | "help.alt":"\u{e718}",
291 | "headphone.alt":"\u{e719}",
292 | "hand.point.up":"\u{e71a}",
293 | "hand.point.right":"\u{e71b}",
294 | "hand.point.left":"\u{e71c}",
295 | "hand.point.down":"\u{e71d}",
296 | "gallery":"\u{e71e}",
297 | "face.smile":"\u{e71f}",
298 | "face.sad":"\u{e720}",
299 | "credit.card":"\u{e721}",
300 | "control.skip.forward":"\u{e722}",
301 | "control.skip.backward":"\u{e723}",
302 | "control.record":"\u{e724}",
303 | "control.eject":"\u{e725}",
304 | "comments.smiley":"\u{e726}",
305 | "brush.alt":"\u{e727}",
306 | "youtube":"\u{e728}",
307 | "vimeo":"\u{e729}",
308 | "twitter":"\u{e72a}",
309 | "time":"\u{e72b}",
310 | "tumblr":"\u{e72c}",
311 | "skype":"\u{e72d}",
312 | "share":"\u{e72e}",
313 | "share.alt":"\u{e72f}",
314 | "rocket":"\u{e730}",
315 | "pinterest":"\u{e731}",
316 | "new.window":"\u{e732}",
317 | "microsoft":"\u{e733}",
318 | "list.ol":"\u{e734}",
319 | "linkedin":"\u{e735}",
320 | "layout.sidebar.2":"\u{e736}",
321 | "layout.grid4.alt":"\u{e737}",
322 | "layout.grid3.alt":"\u{e738}",
323 | "layout.grid2.alt":"\u{e739}",
324 | "layout.column4.alt":"\u{e73a}",
325 | "layout.column3.alt":"\u{e73b}",
326 | "layout.column2.alt":"\u{e73c}",
327 | "instagram":"\u{e73d}",
328 | "google":"\u{e73e}",
329 | "github":"\u{e73f}",
330 | "flickr":"\u{e740}",
331 | "facebook":"\u{e741}",
332 | "dropbox":"\u{e742}",
333 | "dribbble":"\u{e743}",
334 | "apple":"\u{e744}",
335 | "android":"\u{e745}",
336 | "save":"\u{e746}",
337 | "save.alt":"\u{e747}",
338 | "yahoo":"\u{e748}",
339 | "wordpress":"\u{e749}",
340 | "vimeo.alt":"\u{e74a}",
341 | "twitter.alt":"\u{e74b}",
342 | "tumblr.alt":"\u{e74c}",
343 | "trello":"\u{e74d}",
344 | "stack.overflow":"\u{e74e}",
345 | "soundcloud":"\u{e74f}",
346 | "sharethis":"\u{e750}",
347 | "sharethis.alt":"\u{e751}",
348 | "reddit":"\u{e752}",
349 | "pinterest.alt":"\u{e753}",
350 | "microsoft.alt":"\u{e754}",
351 | "linux":"\u{e755}",
352 | "jsfiddle":"\u{e756}",
353 | "joomla":"\u{e757}",
354 | "html5":"\u{e758}",
355 | "flickr.alt":"\u{e759}",
356 | "email":"\u{e75a}",
357 | "drupal":"\u{e75b}",
358 | "dropbox.alt":"\u{e75c}",
359 | "css3":"\u{e75d}",
360 | "rss":"\u{e75e}",
361 | "rss.alt":"\u{e75f}"
362 | ]
363 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/Shared/SwiftIconFont.swift:
--------------------------------------------------------------------------------
1 | //
2 | // UIFont+SwiftIconFont.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat Ciftci on 18/03/16.
6 | // Copyright © 2016 Sedat Gokbek Ciftci. All rights reserved.
7 | //
8 |
9 |
10 | #if os(iOS) || os(tvOS)
11 | import UIKit
12 | #elseif os(OSX)
13 | import AppKit
14 | #endif
15 |
16 | public struct SwiftIcon {
17 | let font: Fonts
18 | let code: String
19 | let color: Color
20 | let imageSize: CGSize
21 | let fontSize: CGFloat
22 | }
23 |
24 | public enum Fonts: String {
25 | case fontAwesome5 = "FontAwesome5Free-Regular"
26 | case fontAwesome5Brand = "FontAwesome5Brands-Regular"
27 | case fontAwesome5Solid = "FontAwesome5Free-Solid"
28 | case iconic = "open-iconic"
29 | case ionicon = "Ionicons"
30 | case octicon = "octicons"
31 | case themify = "themify"
32 | case mapIcon = "map-icons"
33 | case materialIcon = "MaterialIcons-Regular"
34 | case segoeMDL2 = "SegoeMDL2Assets"
35 | case foundation = "fontcustom"
36 | case elegantIcon = "ElegantIcons"
37 | case captain = "captainicon"
38 |
39 | var fontFamilyName: String {
40 | switch self {
41 | case .fontAwesome5:
42 | return "Font Awesome 5 Free"
43 | case .fontAwesome5Brand:
44 | return "Font Awesome 5 Brands"
45 | case .fontAwesome5Solid:
46 | return "Font Awesome 5 Free"
47 | case .iconic:
48 | return "Icons"
49 | case .ionicon:
50 | return "Ionicons"
51 | case .octicon:
52 | return "octicons"
53 | case .themify:
54 | return "Themify"
55 | case .mapIcon:
56 | return "map-icons"
57 | case .materialIcon:
58 | return "Material Icons"
59 | case .segoeMDL2:
60 | return "Segoe MDL2 Assets"
61 | case .foundation:
62 | return "fontcustom"
63 | case .elegantIcon:
64 | return "ElegantIcons"
65 | case .captain:
66 | return "captainicon"
67 | }
68 | }
69 |
70 | }
71 |
72 | func replace(withText string: NSString) -> NSString {
73 | if string.lowercased.range(of: "-") != nil {
74 | return string.replacingOccurrences(of: "-", with: "_") as NSString
75 | }
76 | return string
77 | }
78 |
79 | func getAttributedString(_ text: NSString, ofSize size: CGFloat) -> NSMutableAttributedString {
80 | let attributedString = NSMutableAttributedString(string: text as String)
81 |
82 | for substring in ((text as String).split{$0 == " "}.map(String.init)) {
83 | var splitArr = ["", ""]
84 | splitArr = substring.split{$0 == ":"}.map(String.init)
85 | if splitArr.count < 2 {
86 | continue
87 | }
88 |
89 |
90 | let substringRange = text.range(of: substring)
91 |
92 | let fontPrefix: String = splitArr[0].lowercased()
93 | var fontCode: String = splitArr[1]
94 |
95 | if fontCode.lowercased().range(of: "_") != nil {
96 | fontCode = (fontCode as NSString).replacingOccurrences(of: "_", with: "-")
97 | }
98 |
99 | var fontType: Fonts = .fontAwesome5
100 | var fontArr: [String: String] = ["": ""]
101 |
102 | if fontPrefix == "ic" {
103 | fontType = Fonts.iconic
104 | fontArr = iconicIconArr
105 | } else if fontPrefix == "io" {
106 | fontType = Fonts.ionicon
107 | fontArr = ioniconArr
108 | } else if fontPrefix == "oc" {
109 | fontType = Fonts.octicon
110 | fontArr = octiconArr
111 | } else if fontPrefix == "ti" {
112 | fontType = Fonts.themify
113 | fontArr = temifyIconArr
114 | } else if fontPrefix == "mi" {
115 | fontType = Fonts.mapIcon
116 | fontArr = mapIconArr
117 | } else if fontPrefix == "ma" {
118 | fontType = Fonts.materialIcon
119 | fontArr = materialIconArr
120 | } else if fontPrefix == "sm" {
121 | fontType = Fonts.segoeMDL2
122 | fontArr = segoeMDL2
123 | } else if fontPrefix == "fa5" {
124 | fontType = Fonts.fontAwesome5
125 | fontArr = fontAwesome5IconArr
126 | } else if fontPrefix == "fa5b" {
127 | fontType = Fonts.fontAwesome5Brand
128 | fontArr = fontAwesome5IconArr
129 | } else if fontPrefix == "fa5s" {
130 | fontType = Fonts.fontAwesome5Solid
131 | fontArr = fontAwesome5IconArr
132 | } else if fontPrefix == "fo" {
133 | fontType = .foundation
134 | fontArr = foundationIconArr
135 | } else if fontPrefix == "el" {
136 | fontType = .elegantIcon
137 | fontArr = elegantIconArr
138 | } else if fontPrefix == "cp" {
139 | fontType = .captain
140 | fontArr = captainIconArr
141 | }
142 |
143 | if let _ = fontArr[fontCode] {
144 | attributedString.replaceCharacters(in: substringRange, with: String.getIcon(from: fontType, code: fontCode)!)
145 | let newRange = NSRange(location: substringRange.location, length: 1)
146 | attributedString.addAttribute(.font, value: Font.icon(from: fontType, ofSize: size), range: newRange)
147 | }
148 | }
149 |
150 | return attributedString
151 | }
152 |
153 | func getAttributedStringForRuntimeReplace(_ text: NSString, ofSize size: CGFloat) -> NSMutableAttributedString {
154 | let attributedString = NSMutableAttributedString(string: text as String)
155 |
156 | do {
157 | let input = text as String
158 | let regex = try NSRegularExpression(pattern: "icon:\\((\\w+):(\\w+)\\)", options: NSRegularExpression.Options.caseInsensitive)
159 | let matches = regex.matches(in: input, options: [], range: NSRange(location: 0, length: input.utf16.count))
160 |
161 | if let match = matches.first {
162 | var fontPrefix = ""
163 | var fontCode = ""
164 | let iconLibraryNameRange = match.range(at: 1)
165 | let iconNameRange = match.range(at: 2)
166 |
167 | if let swiftRange = iconLibraryNameRange.range(for: text as String) {
168 | fontPrefix = String(input[swiftRange])
169 | }
170 |
171 |
172 | if let swiftRange = iconNameRange.range(for: text as String) {
173 | fontCode = String(input[swiftRange])
174 | }
175 |
176 | if fontPrefix.utf16.count > 0 && fontCode.utf16.count > 0 {
177 |
178 | var fontType: Fonts = .fontAwesome5
179 | var fontArr: [String: String] = ["": ""]
180 |
181 | if fontPrefix == "ic" {
182 | fontType = Fonts.iconic
183 | fontArr = iconicIconArr
184 | } else if fontPrefix == "io" {
185 | fontType = Fonts.ionicon
186 | fontArr = ioniconArr
187 | } else if fontPrefix == "oc" {
188 | fontType = Fonts.octicon
189 | fontArr = octiconArr
190 | } else if fontPrefix == "ti" {
191 | fontType = Fonts.themify
192 | fontArr = temifyIconArr
193 | } else if fontPrefix == "mi" {
194 | fontType = Fonts.mapIcon
195 | fontArr = mapIconArr
196 | } else if fontPrefix == "ma" {
197 | fontType = Fonts.materialIcon
198 | fontArr = materialIconArr
199 | } else if fontPrefix == "sm" {
200 | fontType = Fonts.segoeMDL2
201 | fontArr = segoeMDL2
202 | } else if fontPrefix == "fa5" {
203 | fontType = Fonts.fontAwesome5
204 | fontArr = fontAwesome5IconArr
205 | } else if fontPrefix == "fa5b" {
206 | fontType = Fonts.fontAwesome5Brand
207 | fontArr = fontAwesome5IconArr
208 | } else if fontPrefix == "fa5s" {
209 | fontType = Fonts.fontAwesome5Solid
210 | fontArr = fontAwesome5IconArr
211 | } else if fontPrefix == "fo" {
212 | fontType = .foundation
213 | fontArr = foundationIconArr
214 | } else if fontPrefix == "el" {
215 | fontType = .elegantIcon
216 | fontArr = elegantIconArr
217 | } else if fontPrefix == "cp" {
218 | fontType = .captain
219 | fontArr = captainIconArr
220 | }
221 |
222 |
223 | if let _ = fontArr[fontCode] {
224 | attributedString.replaceCharacters(in: match.range, with: String.getIcon(from: fontType, code: fontCode)!)
225 | let newRange = NSRange(location: match.range.location, length: 1)
226 | attributedString.addAttribute(.font, value: Font.icon(from: fontType, ofSize: size), range: newRange)
227 | }
228 |
229 | }
230 | }
231 |
232 | } catch {
233 | // regex was bad!
234 | }
235 |
236 | return attributedString
237 | }
238 |
239 | public func GetIconIndexWithSelectedIcon(_ icon: String) -> String {
240 | let text = icon as NSString
241 | var iconIndex: String = ""
242 |
243 | for substring in ((text as String).split{$0 == " "}.map(String.init)) {
244 | var splitArr = ["", ""]
245 | splitArr = substring.split{$0 == ":"}.map(String.init)
246 | if splitArr.count == 1{
247 | continue
248 | }
249 |
250 | var fontCode: String = splitArr[1]
251 |
252 | if fontCode.lowercased().range(of: "_") != nil {
253 | fontCode = fontCode.replacingOccurrences(of: "_", with: "-")
254 | }
255 | iconIndex = fontCode
256 | }
257 |
258 | return iconIndex
259 | }
260 |
261 | public func GetFontTypeWithSelectedIcon(_ icon: String) -> Fonts {
262 | let text = icon as NSString
263 | var fontType: Fonts = .fontAwesome5
264 |
265 | for substring in ((text as String).split{$0 == " "}.map(String.init)) {
266 | var splitArr = ["", ""]
267 | splitArr = substring.split{$0 == ":"}.map(String.init)
268 |
269 | if splitArr.count == 1{
270 | continue
271 | }
272 |
273 | let fontPrefix: String = splitArr[0].lowercased()
274 | var fontCode: String = splitArr[1]
275 |
276 | if fontCode.lowercased().range(of: "_") != nil {
277 | fontCode = (fontCode as NSString).replacingOccurrences(of: "_", with: "-")
278 | }
279 |
280 |
281 | if fontPrefix == "ic" {
282 | fontType = Fonts.iconic
283 | } else if fontPrefix == "io" {
284 | fontType = Fonts.ionicon
285 | } else if fontPrefix == "oc" {
286 | fontType = Fonts.octicon
287 | } else if fontPrefix == "ti" {
288 | fontType = Fonts.themify
289 | } else if fontPrefix == "mi" {
290 | fontType = Fonts.mapIcon
291 | } else if fontPrefix == "ma" {
292 | fontType = Fonts.materialIcon
293 | } else if fontPrefix == "sm" {
294 | fontType = Fonts.segoeMDL2
295 | } else if fontPrefix == "fa5" {
296 | fontType = Fonts.fontAwesome5
297 | } else if fontPrefix == "fa5b" {
298 | fontType = Fonts.fontAwesome5Brand
299 | } else if fontPrefix == "fa5s" {
300 | fontType = Fonts.fontAwesome5Solid
301 | } else if fontPrefix == "fo" {
302 | fontType = .foundation
303 | } else if fontPrefix == "el" {
304 | fontType = .elegantIcon
305 | } else if fontPrefix == "cp" {
306 | fontType = .captain
307 | }
308 | }
309 |
310 |
311 | return fontType
312 | }
313 |
--------------------------------------------------------------------------------
/SwiftIconFont/Classes/Shared/Fonts/ElegantIcon.swift:
--------------------------------------------------------------------------------
1 | //
2 | // ElegantIcon.swift
3 | // SwiftIconFont
4 | //
5 | // Created by Sedat G. ÇİFTÇİ on 4.06.2020.
6 | // Copyright © 2020 Sedat Gökbek ÇİFTÇİ. All rights reserved.
7 | //
8 |
9 | public let elegantIconArr: [String: String] = [
10 | "arrow-up": "\u{21}",
11 | "arrow-down": "\u{22}",
12 | "arrow-left": "\u{23}",
13 | "arrow-right": "\u{24}",
14 | "arrow-left-up": "\u{25}",
15 | "arrow-right-up": "\u{26}",
16 | "arrow-right-down": "\u{27}",
17 | "arrow-left-down": "\u{28}",
18 | "arrow-up-down": "\u{29}",
19 | "arrow-up-down-alt": "\u{2a}",
20 | "arrow-left-right-alt": "\u{2b}",
21 | "arrow-left-right": "\u{2c}",
22 | "arrow-expand-alt2": "\u{2d}",
23 | "arrow-expand-alt": "\u{2e}",
24 | "arrow-condense": "\u{2f}",
25 | "arrow-expand": "\u{30}",
26 | "arrow-move": "\u{31}",
27 | "arrow-carrot-up": "\u{32}",
28 | "arrow-carrot-down": "\u{33}",
29 | "arrow-carrot-left": "\u{34}",
30 | "arrow-carrot-right": "\u{35}",
31 | "arrow-carrot-2up": "\u{36}",
32 | "arrow-carrot-2down": "\u{37}",
33 | "arrow-carrot-2left": "\u{38}",
34 | "arrow-carrot-2right": "\u{39}",
35 | "arrow-carrot-up-alt2": "\u{3a}",
36 | "arrow-carrot-down-alt2": "\u{3b}",
37 | "arrow-carrot-left-alt2": "\u{3c}",
38 | "arrow-carrot-right-alt2": "\u{3d}",
39 | "arrow-carrot-2up-alt2": "\u{3e}",
40 | "arrow-carrot-2down-alt2": "\u{3f}",
41 | "arrow-carrot-2left-alt2": "\u{40}",
42 | "arrow-carrot-2right-alt2": "\u{41}",
43 | "arrow-triangle-up": "\u{42}",
44 | "arrow-triangle-down": "\u{43}",
45 | "arrow-triangle-left": "\u{44}",
46 | "arrow-triangle-right": "\u{45}",
47 | "arrow-triangle-up-alt2": "\u{46}",
48 | "arrow-triangle-down-alt2": "\u{47}",
49 | "arrow-triangle-left-alt2": "\u{48}",
50 | "arrow-triangle-right-alt2": "\u{49}",
51 | "arrow-back": "\u{4a}",
52 | "icon-minus-06": "\u{4b}",
53 | "icon-plus": "\u{4c}",
54 | "icon-close": "\u{4d}",
55 | "icon-check": "\u{4e}",
56 | "icon-minus-alt2": "\u{4f}",
57 | "icon-plus-alt2": "\u{50}",
58 | "icon-close-alt2": "\u{51}",
59 | "icon-check-alt2": "\u{52}",
60 | "icon-zoom-out-alt": "\u{53}",
61 | "icon-zoom-in-alt": "\u{54}",
62 | "icon-search": "\u{55}",
63 | "icon-box-empty": "\u{56}",
64 | "icon-box-selected": "\u{57}",
65 | "icon-minus-box": "\u{58}",
66 | "icon-plus-box": "\u{59}",
67 | "icon-box-checked": "\u{5a}",
68 | "icon-circle-empty": "\u{5b}",
69 | "icon-circle-slelected": "\u{5c}",
70 | "icon-stop-alt2": "\u{5d}",
71 | "icon-stop": "\u{5e}",
72 | "icon-pause-alt2": "\u{5f}",
73 | "icon-pause": "\u{60}",
74 | "icon-menu": "\u{61}",
75 | "icon-menu-square-alt2": "\u{62}",
76 | "icon-menu-circle-alt2": "\u{63}",
77 | "icon-ul": "\u{64}",
78 | "icon-ol": "\u{65}",
79 | "icon-adjust-horiz": "\u{66}",
80 | "icon-adjust-vert": "\u{67}",
81 | "icon-document-alt": "\u{68}",
82 | "icon-documents-alt": "\u{69}",
83 | "icon-pencil": "\u{6a}",
84 | "icon-pencil-edit-alt": "\u{6b}",
85 | "icon-pencil-edit": "\u{6c}",
86 | "icon-folder-alt": "\u{6d}",
87 | "icon-folder-open-alt": "\u{6e}",
88 | "icon-folder-add-alt": "\u{6f}",
89 | "icon-info-alt": "\u{70}",
90 | "icon-error-oct-alt": "\u{71}",
91 | "icon-error-circle-alt": "\u{72}",
92 | "icon-error-triangle-alt": "\u{73}",
93 | "icon-question-alt2": "\u{74}",
94 | "icon-question": "\u{75}",
95 | "icon-comment-alt": "\u{76}",
96 | "icon-chat-alt": "\u{77}",
97 | "icon-vol-mute-alt": "\u{78}",
98 | "icon-volume-low-alt": "\u{79}",
99 | "icon-volume-high-alt": "\u{7a}",
100 | "icon-quotations": "\u{7b}",
101 | "icon-quotations-alt2": "\u{7c}",
102 | "icon-clock-alt": "\u{7d}",
103 | "icon-lock-alt": "\u{7e}",
104 | "icon-lock-open-alt": "\u{e000}",
105 | "icon-key-alt": "\u{e001}",
106 | "icon-cloud-alt": "\u{e002}",
107 | "icon-cloud-upload-alt": "\u{e003}",
108 | "icon-cloud-download-alt": "\u{e004}",
109 | "icon-image": "\u{e005}",
110 | "icon-images": "\u{e006}",
111 | "icon-lightbulb-alt": "\u{e007}",
112 | "icon-gift-alt": "\u{e008}",
113 | "icon-house-alt": "\u{e009}",
114 | "icon-genius": "\u{e00a}",
115 | "icon-mobile": "\u{e00b}",
116 | "icon-tablet": "\u{e00c}",
117 | "icon-laptop": "\u{e00d}",
118 | "icon-desktop": "\u{e00e}",
119 | "icon-camera-alt": "\u{e00f}",
120 | "icon-mail-alt": "\u{e010}",
121 | "icon-cone-alt": "\u{e011}",
122 | "icon-ribbon-alt": "\u{e012}",
123 | "icon-bag-alt": "\u{e013}",
124 | "icon-creditcard": "\u{e014}",
125 | "icon-cart-alt": "\u{e015}",
126 | "icon-paperclip": "\u{e016}",
127 | "icon-tag-alt": "\u{e017}",
128 | "icon-tags-alt": "\u{e018}",
129 | "icon-trash-alt": "\u{e019}",
130 | "icon-cursor-alt": "\u{e01a}",
131 | "icon-mic-alt": "\u{e01b}",
132 | "icon-compass-alt": "\u{e01c}",
133 | "icon-pin-alt": "\u{e01d}",
134 | "icon-pushpin-alt": "\u{e01e}",
135 | "icon-map-alt": "\u{e01f}",
136 | "icon-drawer-alt": "\u{e020}",
137 | "icon-toolbox-alt": "\u{e021}",
138 | "icon-book-alt": "\u{e022}",
139 | "icon-calendar": "\u{e023}",
140 | "icon-film": "\u{e024}",
141 | "icon-table": "\u{e025}",
142 | "icon-contacts-alt": "\u{e026}",
143 | "icon-headphones": "\u{e027}",
144 | "icon-lifesaver": "\u{e028}",
145 | "icon-piechart": "\u{e029}",
146 | "icon-refresh": "\u{e02a}",
147 | "icon-link-alt": "\u{e02b}",
148 | "icon-link": "\u{e02c}",
149 | "icon-loading": "\u{e02d}",
150 | "icon-blocked": "\u{e02e}",
151 | "icon-archive-alt": "\u{e02f}",
152 | "icon-heart-alt": "\u{e030}",
153 | "icon-star-alt": "\u{e031}",
154 | "icon-star-half-alt": "\u{e032}",
155 | "icon-star": "\u{e033}",
156 | "icon-star-half": "\u{e034}",
157 | "icon-tools": "\u{e035}",
158 | "icon-tool": "\u{e036}",
159 | "icon-cog": "\u{e037}",
160 | "icon-cogs": "\u{e038}",
161 | "arrow-up-alt": "\u{e039}",
162 | "arrow-down-alt": "\u{e03a}",
163 | "arrow-left-alt": "\u{e03b}",
164 | "arrow-right-alt": "\u{e03c}",
165 | "arrow-left-up-alt": "\u{e03d}",
166 | "arrow-right-up-alt": "\u{e03e}",
167 | "arrow-right-down-alt": "\u{e03f}",
168 | "arrow-left-down-alt": "\u{e040}",
169 | "arrow-condense-alt": "\u{e041}",
170 | "arrow-expand-alt3": "\u{e042}",
171 | "arrow-carrot-up-alt": "\u{e043}",
172 | "arrow-carrot-down-alt": "\u{e044}",
173 | "arrow-carrot-left-alt": "\u{e045}",
174 | "arrow-carrot-right-alt": "\u{e046}",
175 | "arrow-carrot-2up-alt": "\u{e047}",
176 | "arrow-carrot-2dwnn-alt": "\u{e048}",
177 | "arrow-carrot-2left-alt": "\u{e049}",
178 | "arrow-carrot-2right-alt": "\u{e04a}",
179 | "arrow-triangle-up-alt": "\u{e04b}",
180 | "arrow-triangle-down-alt": "\u{e04c}",
181 | "arrow-triangle-left-alt": "\u{e04d}",
182 | "arrow-triangle-right-alt": "\u{e04e}",
183 | "icon-minus-alt": "\u{e04f}",
184 | "icon-plus-alt": "\u{e050}",
185 | "icon-close-alt": "\u{e051}",
186 | "icon-check-alt": "\u{e052}",
187 | "icon-zoom-out": "\u{e053}",
188 | "icon-zoom-in": "\u{e054}",
189 | "icon-stop-alt": "\u{e055}",
190 | "icon-menu-square-alt": "\u{e056}",
191 | "icon-menu-circle-alt": "\u{e057}",
192 | "icon-document": "\u{e058}",
193 | "icon-documents": "\u{e059}",
194 | "icon-pencil-alt": "\u{e05a}",
195 | "icon-folder": "\u{e05b}",
196 | "icon-folder-open": "\u{e05c}",
197 | "icon-folder-add": "\u{e05d}",
198 | "icon-folder-upload": "\u{e05e}",
199 | "icon-folder-download": "\u{e05f}",
200 | "icon-info": "\u{e060}",
201 | "icon-error-circle": "\u{e061}",
202 | "icon-error-oct": "\u{e062}",
203 | "icon-error-triangle": "\u{e063}",
204 | "icon-question-alt": "\u{e064}",
205 | "icon-comment": "\u{e065}",
206 | "icon-chat": "\u{e066}",
207 | "icon-vol-mute": "\u{e067}",
208 | "icon-volume-low": "\u{e068}",
209 | "icon-volume-high": "\u{e069}",
210 | "icon-quotations-alt": "\u{e06a}",
211 | "icon-clock": "\u{e06b}",
212 | "icon-lock": "\u{e06c}",
213 | "icon-lock-open": "\u{e06d}",
214 | "icon-key": "\u{e06e}",
215 | "icon-cloud": "\u{e06f}",
216 | "icon-cloud-upload": "\u{e070}",
217 | "icon-cloud-download": "\u{e071}",
218 | "icon-lightbulb": "\u{e072}",
219 | "icon-gift": "\u{e073}",
220 | "icon-house": "\u{e074}",
221 | "icon-camera": "\u{e075}",
222 | "icon-mail": "\u{e076}",
223 | "icon-cone": "\u{e077}",
224 | "icon-ribbon": "\u{e078}",
225 | "icon-bag": "\u{e079}",
226 | "icon-cart": "\u{e07a}",
227 | "icon-tag": "\u{e07b}",
228 | "icon-tags": "\u{e07c}",
229 | "icon-trash": "\u{e07d}",
230 | "icon-cursor": "\u{e07e}",
231 | "icon-mic": "\u{e07f}",
232 | "icon-compass": "\u{e080}",
233 | "icon-pin": "\u{e081}",
234 | "icon-pushpin": "\u{e082}",
235 | "icon-map": "\u{e083}",
236 | "icon-drawer": "\u{e084}",
237 | "icon-toolbox": "\u{e085}",
238 | "icon-book": "\u{e086}",
239 | "icon-contacts": "\u{e087}",
240 | "icon-archive": "\u{e088}",
241 | "icon-heart": "\u{e089}",
242 | "icon-profile": "\u{e08a}",
243 | "icon-group": "\u{e08b}",
244 | "icon-grid-2x2": "\u{e08c}",
245 | "icon-grid-3x3": "\u{e08d}",
246 | "icon-music": "\u{e08e}",
247 | "icon-pause-alt": "\u{e08f}",
248 | "icon-phone": "\u{e090}",
249 | "icon-upload": "\u{e091}",
250 | "icon-download": "\u{e092}",
251 | "social-facebook": "\u{e093}",
252 | "social-twitter": "\u{e094}",
253 | "social-pinterest": "\u{e095}",
254 | "social-googleplus": "\u{e096}",
255 | "social-tumblr": "\u{e097}",
256 | "social-tumbleupon": "\u{e098}",
257 | "social-wordpress": "\u{e099}",
258 | "social-instagram": "\u{e09a}",
259 | "social-dribbble": "\u{e09b}",
260 | "social-vimeo": "\u{e09c}",
261 | "social-linkedin": "\u{e09d}",
262 | "social-rss": "\u{e09e}",
263 | "social-deviantart": "\u{e09f}",
264 | "social-share": "\u{e0a0}",
265 | "social-myspace": "\u{e0a1}",
266 | "social-skype": "\u{e0a2}",
267 | "social-youtube": "\u{e0a3}",
268 | "social-picassa": "\u{e0a4}",
269 | "social-googledrive": "\u{e0a5}",
270 | "social-flickr": "\u{e0a6}",
271 | "social-blogger": "\u{e0a7}",
272 | "social-spotify": "\u{e0a8}",
273 | "social-delicious": "\u{e0a9}",
274 | "social-facebook-circle": "\u{e0aa}",
275 | "social-twitter-circle": "\u{e0ab}",
276 | "social-pinterest-circle": "\u{e0ac}",
277 | "social-googleplus-circle": "\u{e0ad}",
278 | "social-tumblr-circle": "\u{e0ae}",
279 | "social-stumbleupon-circle": "\u{e0af}",
280 | "social-wordpress-circle": "\u{e0b0}",
281 | "social-instagram-circle": "\u{e0b1}",
282 | "social-dribbble-circle": "\u{e0b2}",
283 | "social-vimeo-circle": "\u{e0b3}",
284 | "social-linkedin-circle": "\u{e0b4}",
285 | "social-rss-circle": "\u{e0b5}",
286 | "social-deviantart-circle": "\u{e0b6}",
287 | "social-share-circle": "\u{e0b7}",
288 | "social-myspace-circle": "\u{e0b8}",
289 | "social-skype-circle": "\u{e0b9}",
290 | "social-youtube-circle": "\u{e0ba}",
291 | "social-picassa-circle": "\u{e0bb}",
292 | "social-googledrive-alt2": "\u{e0bc}",
293 | "social-flickr-circle": "\u{e0bd}",
294 | "social-blogger-circle": "\u{e0be}",
295 | "social-spotify-circle": "\u{e0bf}",
296 | "social-delicious-circle": "\u{e0c0}",
297 | "social-facebook-square": "\u{e0c1}",
298 | "social-twitter-square": "\u{e0c2}",
299 | "social-pinterest-square": "\u{e0c3}",
300 | "social-googleplus-square": "\u{e0c4}",
301 | "social-tumblr-square": "\u{e0c5}",
302 | "social-stumbleupon-square": "\u{e0c6}",
303 | "social-wordpress-square": "\u{e0c7}",
304 | "social-instagram-square": "\u{e0c8}",
305 | "social-dribbble-square": "\u{e0c9}",
306 | "social-vimeo-square": "\u{e0ca}",
307 | "social-linkedin-square": "\u{e0cb}",
308 | "social-rss-square": "\u{e0cc}",
309 | "social-deviantart-square": "\u{e0cd}",
310 | "social-share-square": "\u{e0ce}",
311 | "social-myspace-square": "\u{e0cf}",
312 | "social-skype-square": "\u{e0d0}",
313 | "social-youtube-square": "\u{e0d1}",
314 | "social-picassa-square": "\u{e0d2}",
315 | "social-googledrive-square": "\u{e0d3}",
316 | "social-flickr-square": "\u{e0d4}",
317 | "social-blogger-square": "\u{e0d5}",
318 | "social-spotify-square": "\u{e0d6}",
319 | "social-delicious-square": "\u{e0d7}",
320 | "icon-printer": "\u{e103}",
321 | "icon-calulator": "\u{e0ee}",
322 | "icon-building": "\u{e0ef}",
323 | "icon-floppy": "\u{e0e8}",
324 | "icon-drive": "\u{e0ea}",
325 | "icon-search-2": "\u{e101}",
326 | "icon-id": "\u{e107}",
327 | "icon-id-2": "\u{e108}",
328 | "icon-puzzle": "\u{e102}",
329 | "icon-like": "\u{e106}",
330 | "icon-dislike": "\u{e0eb}",
331 | "icon-mug": "\u{e105}",
332 | "icon-currency": "\u{e0ed}",
333 | "icon-wallet": "\u{e100}",
334 | "icon-pens": "\u{e104}",
335 | "icon-easel": "\u{e0e9}",
336 | "icon-flowchart": "\u{e109}",
337 | "icon-datareport": "\u{e0ec}",
338 | "icon-briefcase": "\u{e0fe}",
339 | "icon-shield": "\u{e0f6}",
340 | "icon-percent": "\u{e0fb}",
341 | "icon-globe": "\u{e0e2}",
342 | "icon-globe-2": "\u{e0e3}",
343 | "icon-target": "\u{e0f5}",
344 | "icon-hourglass": "\u{e0e1}",
345 | "icon-balance": "\u{e0ff}",
346 | "icon-rook": "\u{e0f8}",
347 | "icon-printer-alt": "\u{e0fa}",
348 | "icon-calculator-alt": "\u{e0e7}",
349 | "icon-building-alt": "\u{e0fd}",
350 | "icon-floppy-alt": "\u{e0e4}",
351 | "icon-drive-alt": "\u{e0e5}",
352 | "icon-search-alt": "\u{e0f7}",
353 | "icon-id-alt": "\u{e0e0}",
354 | "icon-id-2-alt": "\u{e0fc}",
355 | "icon-puzzle-alt": "\u{e0f9}",
356 | "icon-like-alt": "\u{e0dd}",
357 | "icon-dislike-alt": "\u{e0f1}",
358 | "icon-mug-alt": "\u{e0dc}",
359 | "icon-currency-alt": "\u{e0f3}",
360 | "icon-wallet-alt": "\u{e0d8}",
361 | "icon-pens-alt": "\u{e0db}",
362 | "icon-easel-alt": "\u{e0f0}",
363 | "icon-flowchart-alt": "\u{e0df}",
364 | "icon-datareport-alt": "\u{e0f2}",
365 | "icon-briefcase-alt": "\u{e0f4}",
366 | "icon-shield-alt": "\u{e0d9}",
367 | "icon-percent-alt": "\u{e0da}",
368 | "icon-globe-alt": "\u{e0de}",
369 | "icon-clipboard": "\u{e0e6}"
370 | ]
371 |
--------------------------------------------------------------------------------
/Example/Example/Base.lproj/Main.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 |
133 |
134 |
135 |
136 |
137 |
138 |
139 |
140 |
141 |
142 |
143 |
144 |
145 |
146 |
147 |
148 |
149 |
150 |
151 |
152 |
153 |
154 |
155 |
156 |
157 |
158 |
159 |
160 |
161 |
162 |
163 |
164 |
165 |
166 |
167 |
168 |
169 |
170 |
171 |
172 |
173 |
174 |
175 |
--------------------------------------------------------------------------------
/ExampleMac/ExampleMac.xcodeproj/project.pbxproj:
--------------------------------------------------------------------------------
1 | // !$*UTF8*$!
2 | {
3 | archiveVersion = 1;
4 | classes = {
5 | };
6 | objectVersion = 50;
7 | objects = {
8 |
9 | /* Begin PBXBuildFile section */
10 | 69A3AC7647F6313117DC0FC8 /* Pods_ExampleMac.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 702A1D965B9E7A4F33545229 /* Pods_ExampleMac.framework */; };
11 | E8D081512488F0CD005A139F /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = E8D081502488F0CD005A139F /* AppDelegate.swift */; };
12 | E8D081532488F0CD005A139F /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = E8D081522488F0CD005A139F /* ViewController.swift */; };
13 | E8D081552488F0CF005A139F /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = E8D081542488F0CF005A139F /* Assets.xcassets */; };
14 | E8D081582488F0CF005A139F /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = E8D081562488F0CF005A139F /* Main.storyboard */; };
15 | /* End PBXBuildFile section */
16 |
17 | /* Begin PBXFileReference section */
18 | 19EF35E049A4BED7E00D4B18 /* Pods-ExampleMac.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-ExampleMac.release.xcconfig"; path = "Target Support Files/Pods-ExampleMac/Pods-ExampleMac.release.xcconfig"; sourceTree = ""; };
19 | 297CD01808765E621E6085CB /* Pods-ExampleMac.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-ExampleMac.debug.xcconfig"; path = "Target Support Files/Pods-ExampleMac/Pods-ExampleMac.debug.xcconfig"; sourceTree = ""; };
20 | 702A1D965B9E7A4F33545229 /* Pods_ExampleMac.framework */ = {isa = PBXFileReference; explicitFileType = wrapper.framework; includeInIndex = 0; path = Pods_ExampleMac.framework; sourceTree = BUILT_PRODUCTS_DIR; };
21 | E8D0814D2488F0CD005A139F /* ExampleMac.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = ExampleMac.app; sourceTree = BUILT_PRODUCTS_DIR; };
22 | E8D081502488F0CD005A139F /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = ""; };
23 | E8D081522488F0CD005A139F /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = ""; };
24 | E8D081542488F0CF005A139F /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; };
25 | E8D081572488F0CF005A139F /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; };
26 | E8D081592488F0CF005A139F /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
27 | E8D0815A2488F0CF005A139F /* ExampleMac.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = ExampleMac.entitlements; sourceTree = ""; };
28 | /* End PBXFileReference section */
29 |
30 | /* Begin PBXFrameworksBuildPhase section */
31 | E8D0814A2488F0CD005A139F /* Frameworks */ = {
32 | isa = PBXFrameworksBuildPhase;
33 | buildActionMask = 2147483647;
34 | files = (
35 | 69A3AC7647F6313117DC0FC8 /* Pods_ExampleMac.framework in Frameworks */,
36 | );
37 | runOnlyForDeploymentPostprocessing = 0;
38 | };
39 | /* End PBXFrameworksBuildPhase section */
40 |
41 | /* Begin PBXGroup section */
42 | 6594D6D9879C51B9660125DF /* Frameworks */ = {
43 | isa = PBXGroup;
44 | children = (
45 | 702A1D965B9E7A4F33545229 /* Pods_ExampleMac.framework */,
46 | );
47 | name = Frameworks;
48 | sourceTree = "";
49 | };
50 | E8D081442488F0CD005A139F = {
51 | isa = PBXGroup;
52 | children = (
53 | E8D0814F2488F0CD005A139F /* ExampleMac */,
54 | E8D0814E2488F0CD005A139F /* Products */,
55 | F0DCE38E58CA6E96C4BA21A2 /* Pods */,
56 | 6594D6D9879C51B9660125DF /* Frameworks */,
57 | );
58 | sourceTree = "";
59 | };
60 | E8D0814E2488F0CD005A139F /* Products */ = {
61 | isa = PBXGroup;
62 | children = (
63 | E8D0814D2488F0CD005A139F /* ExampleMac.app */,
64 | );
65 | name = Products;
66 | sourceTree = "";
67 | };
68 | E8D0814F2488F0CD005A139F /* ExampleMac */ = {
69 | isa = PBXGroup;
70 | children = (
71 | E8D081502488F0CD005A139F /* AppDelegate.swift */,
72 | E8D081522488F0CD005A139F /* ViewController.swift */,
73 | E8D081542488F0CF005A139F /* Assets.xcassets */,
74 | E8D081562488F0CF005A139F /* Main.storyboard */,
75 | E8D081592488F0CF005A139F /* Info.plist */,
76 | E8D0815A2488F0CF005A139F /* ExampleMac.entitlements */,
77 | );
78 | path = ExampleMac;
79 | sourceTree = "";
80 | };
81 | F0DCE38E58CA6E96C4BA21A2 /* Pods */ = {
82 | isa = PBXGroup;
83 | children = (
84 | 297CD01808765E621E6085CB /* Pods-ExampleMac.debug.xcconfig */,
85 | 19EF35E049A4BED7E00D4B18 /* Pods-ExampleMac.release.xcconfig */,
86 | );
87 | name = Pods;
88 | path = Pods;
89 | sourceTree = "";
90 | };
91 | /* End PBXGroup section */
92 |
93 | /* Begin PBXNativeTarget section */
94 | E8D0814C2488F0CD005A139F /* ExampleMac */ = {
95 | isa = PBXNativeTarget;
96 | buildConfigurationList = E8D0815D2488F0CF005A139F /* Build configuration list for PBXNativeTarget "ExampleMac" */;
97 | buildPhases = (
98 | B37F00511A7B8A0DD1867332 /* [CP] Check Pods Manifest.lock */,
99 | E8D081492488F0CD005A139F /* Sources */,
100 | E8D0814A2488F0CD005A139F /* Frameworks */,
101 | E8D0814B2488F0CD005A139F /* Resources */,
102 | 625734DF201490D209A16F25 /* [CP] Embed Pods Frameworks */,
103 | );
104 | buildRules = (
105 | );
106 | dependencies = (
107 | );
108 | name = ExampleMac;
109 | productName = ExampleMac;
110 | productReference = E8D0814D2488F0CD005A139F /* ExampleMac.app */;
111 | productType = "com.apple.product-type.application";
112 | };
113 | /* End PBXNativeTarget section */
114 |
115 | /* Begin PBXProject section */
116 | E8D081452488F0CD005A139F /* Project object */ = {
117 | isa = PBXProject;
118 | attributes = {
119 | LastSwiftUpdateCheck = 1150;
120 | LastUpgradeCheck = 1150;
121 | ORGANIZATIONNAME = "Sedat G. ÇİFTÇİ";
122 | TargetAttributes = {
123 | E8D0814C2488F0CD005A139F = {
124 | CreatedOnToolsVersion = 11.5;
125 | };
126 | };
127 | };
128 | buildConfigurationList = E8D081482488F0CD005A139F /* Build configuration list for PBXProject "ExampleMac" */;
129 | compatibilityVersion = "Xcode 9.3";
130 | developmentRegion = en;
131 | hasScannedForEncodings = 0;
132 | knownRegions = (
133 | en,
134 | Base,
135 | );
136 | mainGroup = E8D081442488F0CD005A139F;
137 | productRefGroup = E8D0814E2488F0CD005A139F /* Products */;
138 | projectDirPath = "";
139 | projectRoot = "";
140 | targets = (
141 | E8D0814C2488F0CD005A139F /* ExampleMac */,
142 | );
143 | };
144 | /* End PBXProject section */
145 |
146 | /* Begin PBXResourcesBuildPhase section */
147 | E8D0814B2488F0CD005A139F /* Resources */ = {
148 | isa = PBXResourcesBuildPhase;
149 | buildActionMask = 2147483647;
150 | files = (
151 | E8D081552488F0CF005A139F /* Assets.xcassets in Resources */,
152 | E8D081582488F0CF005A139F /* Main.storyboard in Resources */,
153 | );
154 | runOnlyForDeploymentPostprocessing = 0;
155 | };
156 | /* End PBXResourcesBuildPhase section */
157 |
158 | /* Begin PBXShellScriptBuildPhase section */
159 | 625734DF201490D209A16F25 /* [CP] Embed Pods Frameworks */ = {
160 | isa = PBXShellScriptBuildPhase;
161 | buildActionMask = 2147483647;
162 | files = (
163 | );
164 | inputFileListPaths = (
165 | "${PODS_ROOT}/Target Support Files/Pods-ExampleMac/Pods-ExampleMac-frameworks-${CONFIGURATION}-input-files.xcfilelist",
166 | );
167 | name = "[CP] Embed Pods Frameworks";
168 | outputFileListPaths = (
169 | "${PODS_ROOT}/Target Support Files/Pods-ExampleMac/Pods-ExampleMac-frameworks-${CONFIGURATION}-output-files.xcfilelist",
170 | );
171 | runOnlyForDeploymentPostprocessing = 0;
172 | shellPath = /bin/sh;
173 | shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-ExampleMac/Pods-ExampleMac-frameworks.sh\"\n";
174 | showEnvVarsInLog = 0;
175 | };
176 | B37F00511A7B8A0DD1867332 /* [CP] Check Pods Manifest.lock */ = {
177 | isa = PBXShellScriptBuildPhase;
178 | buildActionMask = 2147483647;
179 | files = (
180 | );
181 | inputFileListPaths = (
182 | );
183 | inputPaths = (
184 | "${PODS_PODFILE_DIR_PATH}/Podfile.lock",
185 | "${PODS_ROOT}/Manifest.lock",
186 | );
187 | name = "[CP] Check Pods Manifest.lock";
188 | outputFileListPaths = (
189 | );
190 | outputPaths = (
191 | "$(DERIVED_FILE_DIR)/Pods-ExampleMac-checkManifestLockResult.txt",
192 | );
193 | runOnlyForDeploymentPostprocessing = 0;
194 | shellPath = /bin/sh;
195 | shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n";
196 | showEnvVarsInLog = 0;
197 | };
198 | /* End PBXShellScriptBuildPhase section */
199 |
200 | /* Begin PBXSourcesBuildPhase section */
201 | E8D081492488F0CD005A139F /* Sources */ = {
202 | isa = PBXSourcesBuildPhase;
203 | buildActionMask = 2147483647;
204 | files = (
205 | E8D081532488F0CD005A139F /* ViewController.swift in Sources */,
206 | E8D081512488F0CD005A139F /* AppDelegate.swift in Sources */,
207 | );
208 | runOnlyForDeploymentPostprocessing = 0;
209 | };
210 | /* End PBXSourcesBuildPhase section */
211 |
212 | /* Begin PBXVariantGroup section */
213 | E8D081562488F0CF005A139F /* Main.storyboard */ = {
214 | isa = PBXVariantGroup;
215 | children = (
216 | E8D081572488F0CF005A139F /* Base */,
217 | );
218 | name = Main.storyboard;
219 | sourceTree = "";
220 | };
221 | /* End PBXVariantGroup section */
222 |
223 | /* Begin XCBuildConfiguration section */
224 | E8D0815B2488F0CF005A139F /* Debug */ = {
225 | isa = XCBuildConfiguration;
226 | buildSettings = {
227 | ALWAYS_SEARCH_USER_PATHS = NO;
228 | CLANG_ANALYZER_NONNULL = YES;
229 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
230 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
231 | CLANG_CXX_LIBRARY = "libc++";
232 | CLANG_ENABLE_MODULES = YES;
233 | CLANG_ENABLE_OBJC_ARC = YES;
234 | CLANG_ENABLE_OBJC_WEAK = YES;
235 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
236 | CLANG_WARN_BOOL_CONVERSION = YES;
237 | CLANG_WARN_COMMA = YES;
238 | CLANG_WARN_CONSTANT_CONVERSION = YES;
239 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
240 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
241 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
242 | CLANG_WARN_EMPTY_BODY = YES;
243 | CLANG_WARN_ENUM_CONVERSION = YES;
244 | CLANG_WARN_INFINITE_RECURSION = YES;
245 | CLANG_WARN_INT_CONVERSION = YES;
246 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
247 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
248 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
249 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
250 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
251 | CLANG_WARN_STRICT_PROTOTYPES = YES;
252 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
253 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
254 | CLANG_WARN_UNREACHABLE_CODE = YES;
255 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
256 | COPY_PHASE_STRIP = NO;
257 | DEBUG_INFORMATION_FORMAT = dwarf;
258 | ENABLE_STRICT_OBJC_MSGSEND = YES;
259 | ENABLE_TESTABILITY = YES;
260 | GCC_C_LANGUAGE_STANDARD = gnu11;
261 | GCC_DYNAMIC_NO_PIC = NO;
262 | GCC_NO_COMMON_BLOCKS = YES;
263 | GCC_OPTIMIZATION_LEVEL = 0;
264 | GCC_PREPROCESSOR_DEFINITIONS = (
265 | "DEBUG=1",
266 | "$(inherited)",
267 | );
268 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
269 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
270 | GCC_WARN_UNDECLARED_SELECTOR = YES;
271 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
272 | GCC_WARN_UNUSED_FUNCTION = YES;
273 | GCC_WARN_UNUSED_VARIABLE = YES;
274 | MACOSX_DEPLOYMENT_TARGET = 10.15;
275 | MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
276 | MTL_FAST_MATH = YES;
277 | ONLY_ACTIVE_ARCH = YES;
278 | SDKROOT = macosx;
279 | SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG;
280 | SWIFT_OPTIMIZATION_LEVEL = "-Onone";
281 | };
282 | name = Debug;
283 | };
284 | E8D0815C2488F0CF005A139F /* Release */ = {
285 | isa = XCBuildConfiguration;
286 | buildSettings = {
287 | ALWAYS_SEARCH_USER_PATHS = NO;
288 | CLANG_ANALYZER_NONNULL = YES;
289 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
290 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
291 | CLANG_CXX_LIBRARY = "libc++";
292 | CLANG_ENABLE_MODULES = YES;
293 | CLANG_ENABLE_OBJC_ARC = YES;
294 | CLANG_ENABLE_OBJC_WEAK = YES;
295 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
296 | CLANG_WARN_BOOL_CONVERSION = YES;
297 | CLANG_WARN_COMMA = YES;
298 | CLANG_WARN_CONSTANT_CONVERSION = YES;
299 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
300 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
301 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
302 | CLANG_WARN_EMPTY_BODY = YES;
303 | CLANG_WARN_ENUM_CONVERSION = YES;
304 | CLANG_WARN_INFINITE_RECURSION = YES;
305 | CLANG_WARN_INT_CONVERSION = YES;
306 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
307 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
308 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
309 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
310 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
311 | CLANG_WARN_STRICT_PROTOTYPES = YES;
312 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
313 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
314 | CLANG_WARN_UNREACHABLE_CODE = YES;
315 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
316 | COPY_PHASE_STRIP = NO;
317 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
318 | ENABLE_NS_ASSERTIONS = NO;
319 | ENABLE_STRICT_OBJC_MSGSEND = YES;
320 | GCC_C_LANGUAGE_STANDARD = gnu11;
321 | GCC_NO_COMMON_BLOCKS = YES;
322 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
323 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
324 | GCC_WARN_UNDECLARED_SELECTOR = YES;
325 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
326 | GCC_WARN_UNUSED_FUNCTION = YES;
327 | GCC_WARN_UNUSED_VARIABLE = YES;
328 | MACOSX_DEPLOYMENT_TARGET = 10.15;
329 | MTL_ENABLE_DEBUG_INFO = NO;
330 | MTL_FAST_MATH = YES;
331 | SDKROOT = macosx;
332 | SWIFT_COMPILATION_MODE = wholemodule;
333 | SWIFT_OPTIMIZATION_LEVEL = "-O";
334 | };
335 | name = Release;
336 | };
337 | E8D0815E2488F0CF005A139F /* Debug */ = {
338 | isa = XCBuildConfiguration;
339 | baseConfigurationReference = 297CD01808765E621E6085CB /* Pods-ExampleMac.debug.xcconfig */;
340 | buildSettings = {
341 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
342 | CODE_SIGN_ENTITLEMENTS = ExampleMac/ExampleMac.entitlements;
343 | CODE_SIGN_STYLE = Automatic;
344 | COMBINE_HIDPI_IMAGES = YES;
345 | INFOPLIST_FILE = ExampleMac/Info.plist;
346 | LD_RUNPATH_SEARCH_PATHS = (
347 | "$(inherited)",
348 | "@executable_path/../Frameworks",
349 | );
350 | PRODUCT_BUNDLE_IDENTIFIER = com.sdev.ExampleMac;
351 | PRODUCT_NAME = "$(TARGET_NAME)";
352 | SWIFT_VERSION = 5.0;
353 | };
354 | name = Debug;
355 | };
356 | E8D0815F2488F0CF005A139F /* Release */ = {
357 | isa = XCBuildConfiguration;
358 | baseConfigurationReference = 19EF35E049A4BED7E00D4B18 /* Pods-ExampleMac.release.xcconfig */;
359 | buildSettings = {
360 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
361 | CODE_SIGN_ENTITLEMENTS = ExampleMac/ExampleMac.entitlements;
362 | CODE_SIGN_STYLE = Automatic;
363 | COMBINE_HIDPI_IMAGES = YES;
364 | INFOPLIST_FILE = ExampleMac/Info.plist;
365 | LD_RUNPATH_SEARCH_PATHS = (
366 | "$(inherited)",
367 | "@executable_path/../Frameworks",
368 | );
369 | PRODUCT_BUNDLE_IDENTIFIER = com.sdev.ExampleMac;
370 | PRODUCT_NAME = "$(TARGET_NAME)";
371 | SWIFT_VERSION = 5.0;
372 | };
373 | name = Release;
374 | };
375 | /* End XCBuildConfiguration section */
376 |
377 | /* Begin XCConfigurationList section */
378 | E8D081482488F0CD005A139F /* Build configuration list for PBXProject "ExampleMac" */ = {
379 | isa = XCConfigurationList;
380 | buildConfigurations = (
381 | E8D0815B2488F0CF005A139F /* Debug */,
382 | E8D0815C2488F0CF005A139F /* Release */,
383 | );
384 | defaultConfigurationIsVisible = 0;
385 | defaultConfigurationName = Release;
386 | };
387 | E8D0815D2488F0CF005A139F /* Build configuration list for PBXNativeTarget "ExampleMac" */ = {
388 | isa = XCConfigurationList;
389 | buildConfigurations = (
390 | E8D0815E2488F0CF005A139F /* Debug */,
391 | E8D0815F2488F0CF005A139F /* Release */,
392 | );
393 | defaultConfigurationIsVisible = 0;
394 | defaultConfigurationName = Release;
395 | };
396 | /* End XCConfigurationList section */
397 | };
398 | rootObject = E8D081452488F0CD005A139F /* Project object */;
399 | }
400 |
--------------------------------------------------------------------------------