Why does QLPreviewRequestSetDataRepresentation on Mavericks return error “ CGImageCreate: invalid image size: 0 x 0” for png
My quick look generator used to work properly but is now broken. Is it a bug or am I doing something wrong? Here’s my code: OSStatus GeneratePreviewForURL(void *thisInterface, QLPreviewRequestRef preview, CFURLRef url, CFStringRef contentTypeUTI, CFDictionaryRef options) { NSDictionary * myDoc = [NSDictionary dictionaryWithContentsOfURL:(NSURL *)url]; if (myDoc) { NSData * pngData = [myDoc valueForKey:@"pngPreview"]; if (pngData) { QLPreviewRequestSetDataRepresentation(preview,(__bridge CFDataRef)pngData, kUTTypeImage,NULL); } } } My doc is a normal plist with a png preview stored as data in