Oops forgot the public function to register fonts.
This commit is contained in:
parent
6c1566b137
commit
e4975b1569
|
@ -9,6 +9,12 @@ public let fontBundle = Bundle.module
|
|||
// _ = UIFont.registerFont(bundle: .module, fontName: "VeganStyle-Regular", fontExtension: "ttf")
|
||||
//}
|
||||
|
||||
public func registerFonts() {
|
||||
registerFont("BeautifulPeople-Regular", fileExtension: "ttf")
|
||||
registerFont("VeganStyle-Regular", fileExtension: "ttf")
|
||||
}
|
||||
|
||||
|
||||
func registerFont(_ name: String, fileExtension: String) {
|
||||
guard let fontURL = Bundle.module.url(forResource: name, withExtension: fileExtension) else {
|
||||
print("No font named \(name).\(fileExtension) was found in the module bundle")
|
||||
|
|
Loading…
Reference in New Issue