0

"Andalus" custom font not work in UITableViewCell. Steps followed:

  • Add font file name "Andalus.ttf" to "Fonts provided by application" key in app-info.plist

  • Get font name using NSLog(@"%@", [UIFont familyNames]); // it return "Andalus"

  • Set font name using: cell.textLabel.font = [UIFont fontWithName:@"Andalus" size:10];

    cell.detailTextLabel.font = [UIFont fontWithName:@"Andalus" size:10];
    

in

- (void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath 

and

- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath

but a word like 'حمل' not appear as in a textedit with the same font

I get data using UTF8 from sqlite

thank you for advance

DShah
  • 9,768
  • 11
  • 71
  • 127
user807146
  • 103
  • 8

2 Answers2

1

Does Andalus have more than one variant, e.g. Andalus Strong and Andalus Sharp? If that is the case you have to specify the name of the variant you wish to use.

Check the array returned by [UIFont fontNamesForFamilyName:@"Andalus"]

BojanG
  • 1,872
  • 1
  • 15
  • 23
  • thank you for reply. but it doesn't. and [UIFont fontNamesForFamilyName:@"Andalus"] just return Andalus – user807146 Oct 24 '11 at 19:21
  • http://stackoverflow.com/questions/3691567/custom-arabic-font-in-ios This is my question with misunderstanding answer. can every one make answer more clear and how to integrate with ios app. – user807146 Oct 24 '11 at 19:46
1

Here you can find the updated list of font can be used:

http://iosfonts.com/

Also, there is an app you can see how the fonts look like:

http://itunes.apple.com/app/fonts/id285217489?mt=8

RGML
  • 3,429
  • 2
  • 22
  • 18