I want to implement a clipboard app using UIPasteboard, which can copy plain text and also rich format , web content in to the pasteboard , and then display on my TextView or WebView. how can i do that?
i have following code and it can get the plain text , but what if i copy a web content?
if ([pasteboard containsPasteboardTypes:[NSArray arrayWithObjects:@"public.utf8-plain-text", @"public.text", nil]]){
if (![_contentList containsObject:pasteboard.string]){
NSLog(@"String representation present: %@", pasteboard.string);
[self addContentList:pasteboard.string];
[pasteboard setValue:@"" forPasteboardType:UIPasteboardNameGeneral];
}
}