• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Content incomplete when calling dataWithPDFInsideRect
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Content incomplete when calling dataWithPDFInsideRect


  • Subject: Content incomplete when calling dataWithPDFInsideRect
  • From: Tito Ciuro <email@hidden>
  • Date: Sat, 3 Jun 2006 13:52:46 -0700

Hello,

My app has an NSImageView where I drop PDF files. I would like to retrieve the PDF representation of the imageview content, so I've tried:

NSData *imageData = [_mapImageView dataWithPDFInsideRect: [_mapImageView frame]];

The problem is that I get the snapshot of the imageview itself + the visible portion of the content. In other words, as if I had made a screen capture of the imageview.

Ideally, I'd like to output the content of the imageview to a new file and see the exact contents and format (PDF) as the original one. Something like this:

- (IBAction)savePDFData:(id)sender
{
NSData *imageData = [_mapImageView dataWithPDFInsideRect: [_mapImageView frame]];


// Save to Desktop...
NSString *filePath = [[NSString alloc]initWithFormat:@"%@/ Desktop/TempImageOut.pdf", NSHomeDirectory()];
[imageData writeToFile:filePath atomically:YES];
[filePath release];
}


Thanks for the help,

-- Tito
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


  • Prev by Date: Re: Can NSMailDelivery be configured programmatically?
  • Next by Date: Re: why doesn't my scrollview scroll ... solved
  • Previous by thread: Re: incompatible Pointer...
  • Next by thread: Fwd: Content incomplete when calling dataWithPDFInsideRect
  • Index(es):
    • Date
    • Thread