CTFontRef ctFont = ...;
NSString *fontName = [(NSString *)CTFontCopyName(ctFont, kCTFontPostScriptNameKey) autorelease];
CGFloat fontSize = CTFontGetSize(ctFont);
UIFont *font = [UIFont fontWithName:fontName size:fontSize];
Color and underline are not attributes of the font. Bold and italic are part of the font name.
Related Contents:
- What is the best way to deal with the NSDateFormatter locale “feechur”?
- Determine device (iPhone, iPod Touch) with iOS
- Opening the Settings app from another app
- How to navigate through textfields (Next / Done Buttons)
- How can I get current location from user in iOS
- Undefined symbols for architecture i386: _OBJC_CLASS_$_SKPSMTPMessage”, referenced from: error
- How to customize the background/border colors of a grouped table view cell?
- How to validate an url on the iPhone
- Measuring cellular signal strength
- @property retain, assign, copy, nonatomic in Objective-C
- Make UINavigationBar transparent
- How to handle different orientations in iOS
- Round two corners in UIView
- NSURLConnection and Basic HTTP Authentication in iOS
- Detecting Color of iPhone/iPad/iPod touch?
- How to NSLog into a file
- Passing parameters to addTarget:action:forControlEvents
- call exit(0) in iphone app
- How to detect iphone is on silent mode
- Stop UIWebView from “bouncing” vertically?
- How to crop a UIImageView to a new UIImage in ‘aspect fill’ mode?
- How to set lock screen , wallpaper and Ringtone programmatically in iPhone?
- Drawing UIBezierPath on code generated UIView
- ViewDidAppear is not called when opening app from background
- UITableView and UIView with keyboardWillShow
- “From View Controller” disappears using UIViewControllerContextTransitioning
- iOS memory allocation – how much memory can be used in an application? [duplicate]
- How to crop UIImage on oval shape or circle shape?
- Is it possible to reset the privacy settings in iOS?
- What is the best way to deal with the NSDateFormatter locale “feature”?
- Change the UITableViewCell Height According to Amount of Text
- Restrict to certain iOS target devices for App Store submission
- How to check if UILabel is truncated?
- How to delete all cookies of UIWebView?
- How to get UIKeyboard size with iOS
- UIPopoverPresentationController on iPhone doesn’t produce popover
- ‘Receiver () has no segue with identifier ‘addSegue’
- Rotation methods deprecated, equivalent of ‘didRotateFromInterfaceOrientation’?
- Instead of push segue how to replace view controller (or remove from navigation stack)?
- Adding Navigation Bar programmatically iOS
- Check if a UIAlertView is showing
- Handling Push Notifications when App is Terminated
- iPhone : Daily local notifications
- Is it possible to disable floating headers in UITableView with UITableViewStylePlain?
- WhatsApp image sharing iOS [closed]
- Cocoa Touch: How To Change UIView’s Border Color And Thickness?
- Dashed line border around UIView
- How can I delay a method call for 1 second?
- How to set the full width of separator in UITableView
- How can I add CGPoint objects to an NSArray the easy way?