How can we customize the image of the text name?
The following code is for displaying text in the input representation:
[self.textDocumentProxy insertText:[key currentTitle]]
My paste code to display the image:
NSData *imgData = UIImagePNGRepresentation(image);
[pasteBoard setData:imgData forPasteboardType:[UIPasteboardTypeListImage objectAtIndex:0]];
NSString* newStr = [[NSString alloc] initWithData:imgData encoding:NSUTF8StringEncoding];
[self.textDocumentProxy insertText:[pasteBoard string]];
I created a cartography with images, I just need to display the images in the input window.
See this image for a concept:

Note:
I need to select an image from the keyboard and show in the inputview so as not to copy the insert from the library.
If someone knows, answer as an answer or any suggestion would also be acceptable.
Thank!
source
share