Print / Save an NSView in a given size
Print / Save an NSView in a given size
- Subject: Print / Save an NSView in a given size
- From: email@hidden
- Date: Sun, 14 Jan 2007 23:38:52 +0100
Hello,
how can I print / save the content of an NSView in a given size (e.g.
3 x 3cm)?
My problem is the following:
I draw a square in the drawRect:-method with:
[NSBezierPath fillRect:NSMakeRect(100, 100, 200, 200)];
Now it should be possible to:
1. save it as PDF / EPS with the square having the size of exactly 3
x 3cm,
2. save it as TIFF with choosing the resolution in dpi, with the
square having the size of exactly 3 x 3cm,
3. print the square in exactly 3 x 3 cm size.
I searched a lot in the Apple Documentation and in online forums, but
it hasn't cleared anything for me. I don't get the idea of it? Do I
have to use a transformation or is there a totally different but very
easy method for that?
The saving as PDF / TIFF / EPS and printing is not the problem! That
was very easy. The only problem is the size of the vector-object in
the PDF / EPS, the size of the TIFF and the printed size...
Thanks very much for your help
Jens Beuckenhauer
email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden