カテゴリー
iOS Swift

iOSで使用可能なFontを表示する

func getFontInfo() {
  let fontFamily = UIFont.familyNames
  for i in 0..<fontFamily.count {
    let family = fontFamily[i]
    let fontName = UIFont.fontNames(forFamilyName: family)
    print("\(family) : \(fontName)")
  }
}