Dears, I 'm a novice in iphone programming. I am trying to make an iphone App that displays mainly Arabic language content. I want to use a custom arabic font for displaying that content, not the iphone default arabic font. I used the following code:
- (void)viewDidLoad {
[super viewDidLoad];
[arabicLabel setFont: [UIFont fontWithName: @"Simple Indust Shaded" size: 20]];
arabicLabel.text = @"السلام عليكم";
}
where arabicLabel is an IBOutlet UILabel. I put the label in the App resources and add it to the info.plist file as UIAppFont array item. also the font is unicode.
When I run this code on the simulator, the label displayed the default arabic font (not my custom font); however it set its size to 20 as stated in the code!.
I don't understand what I did wrong here.. I know that in the info.plist I must add the font file name with extension (ttf) and I did that. Also I know that in the previous code I had to put the actual font name not file name, so i opened the file in my mac and used the title that appeared when the file is opened (Simple Indust Shaded).
Am I missing something? Are there any extra requirements for custom fonts other than being uicode?
Appreciate your help..
NB: I did the same procedure for custom English font and it worked!..