Skip to content

FontAwesomeKit is a class to integrate FontAwesome Icon font library for iOS Swift3 project.

Notifications You must be signed in to change notification settings

Syndicode/FontAwesomeKitSwift3

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 

Repository files navigation

FontAwesomeKitSwift3

FontAwesomeKit Icon font library for iOS Swift3 project. Currently supports only Font-Awesome. With the same approach you can integrate other icon fonts. Ask us at http://syndicode.co if you need other fonts and we will try our best to integrate into this repo. Made in [Syndicode] (http://syndicode.co/?utm_source=github)

FonAwesome

How to install

  1. Add FontAwesome font:
  • Download FontAwesome from fontawesome.io
  • Put the FontAwesome.otf into the project: FonAwesome
  1. Add FontAwesomeKit:
  • Put the FontAwesomeKit.swift into your project
  1. Add font name into Info.plist by "Fonts provided by application": FonAwesome

How to use it?

Extensions could be used for:

  • UILabel
  • UIImageView
  • UIButton
  • UIBarButtonItem
  • UITabBarItem

Examples:

UILabel

let label = UILabel()
label.setFontAwesome(unicode: "f2cc")

or

label.setFontAwesome(unicode: "f2cc", color: .black)

UIImageView

let imageView = UIImageView()
imageView.setFontAwesome(unicode: "f2cc", color: .black)

UIButton

let button = UIButton()
button.setFontAwesome(unicode: "f2cc")

or

button.setFontAwesome(unicode: "f2cc", color: .black)

or

button.setFontAwesome(unicode: "f2cc", color: .black, forState: .normal)

UIBarButtonItem

let barButton = UIBarButtonItem()
barButton.setFontAwesome(unicode: "f2cc")

or

barButton.setFontAwesome(unicode: "f2cc", size: 10)

or

barButton.setFontAwesome(unicode: "f2cc", size: 10, forState: .normal)

UITabBarItem

let tabBarButton = UITabBarItem()
tabBarButton.setFontAwesome(unicode: "f2cc")

or

tabBarButton.setFontAwesome(unicode: "f2cc", size: 10)

or

tabBarButton.setFontAwesome(unicode: "f2cc", size: 10, forState: .normal)

Changelog

Version: 1.0

  • Initial Build

Let us know!

We’d be really happy if you sent us links to your projects where you use this code. Just send an email to [email protected] And do let us know if you have any questions or suggestion regarding the library.

License

Copyright 2016, Syndicode

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

Happy coding

About

FontAwesomeKit is a class to integrate FontAwesome Icon font library for iOS Swift3 project.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages