¿No se muestra sonriente (Emoji) en UITextView en iOS?
He almacenado todos los códigos uni (caracteres emoji) en plist soportados por iphone. Cuando escribo directamente como
- (IBAction)sendButtonSelected:(id)sender {
NSMutableArray *emoticonsArray = [[NSMutableArray alloc]initWithObjects:@"\ue415",nil];
NSString *imageNameToPass = [NSString stringWithFormat:@"%@",[emoticonsArray objectAtIndex:0]];
NSLog(@"imageNameToPass1...%@",imageNameToPass);
messageTextView.text =imageNameToPass;
}
se muestra emoji en vista de texto, pero tan pronto como recupero de plist
NSString *plistPath1 = [[NSBundle mainBundle] pathForResource:@"unicodes" ofType:@"plist"];
NSDictionary *dictionary = [[NSDictionary alloc] initWithContentsOfFile:plistPath1];
activeArray= [dictionary objectForKey:categoryString];
NSLog(@"activeArray...%@",activeArray);
emoticonsArrayForHomeEmoji = [[NSMutableArray alloc]initWithCapacity:[activeArray count]];
for(int i=0; i<[activeArray count]; i++)
{
id objects = (id)[activeArray objectAtIndex:i];
[emoticonsArrayForHomeEmoji insertObject:objects atIndex:i];
}
NSString *imageNameToPass = [NSString stringWithFormat:@"%@",[emoticonsArrayForHomeEmoji
objectAtIndex:0]];
NSLog(@"imageNameToPass1...%@",imageNameToPass);
messageTextView.text =imageNameToPass;
luego se muestra unicode como texto \ ue415 en vista de texto en lugar de emoji.
¿Que estoy haciendo mal?. ¡Por favor, ayúdame!