• 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
Re: Display to screen but will not print
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Display to screen but will not print


  • Subject: Re: Display to screen but will not print
  • From: Mark Friedman <email@hidden>
  • Date: Fri, 16 Apr 2004 20:34:06 -0400

Thanks Louis,

That helped. I was rotating the objects with a setFrameRotation in their drawRect. I now removed that and used a rotation transform of the graphics context in the drawRect. This almost works, the objects do rotate, and appear in both display and print. But their frame does not rotate so they appear clipped in both display and print. I'm not sure how to proceed. I think I need to rotate the rect that is the parameter of the drawRect but don't know where to do that. These are objects I move around the document window by dragging and rotating them with their mouseDown method. So some time after the setNeedsDisplay in the mouseDown and their drawRect I need to rotate their frame?

On the other hand, the setFrameRotation works so nice for display, I hate to give up on that method. Can anyone tell me why that doesn't work in print?

Mark

On Apr 15, 2004, at 11:08 PM, Louis C. Sacha wrote:

Hello...

You might want to take a look at a recent thread in the archives:

Outputing rotated text
http://lists.apple.com/mhonarc/cocoa-dev/msg21931.html

Depending on how you are doing the rotation for the objects that aren't being drawn, it might help you solve the problem.

Louis



I am trying to print the content view of a document window. It has
mostly graphic type objects. I have the fairly standard print method in
my document class:
...
The content view has a couple of buttons and bezier curves (via nib).
These display and print fine. I also have some instances of an
NSTextField class that get added programatically (addSubView...). These
also display and print fine. Similarly I add subviews of an NSView type class. These have a drawRect method that determines their position
and rotation and either that they are some sort of bezier curve or a
picture read in from a file. These display ok but none of them will
appear when printing. So I'm trying to find out why. I can single step
through the debugger after selecting the Print menu and see it go
through each of these objects' drawRect method but they don't appear in
the print preview or on paper. Any ideas?
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


References: 
 >Display to screen but will not print (From: Mark Friedman <email@hidden>)
 >Re: Display to screen but will not print (From: "Louis C. Sacha" <email@hidden>)

  • Prev by Date: Help with Connect to Telnet Server code
  • Next by Date: Re: Removing *other* app default?!?
  • Previous by thread: Re: Display to screen but will not print
  • Next by thread: The bitmap image type from an NSBitmapImageRep?
  • Index(es):
    • Date
    • Thread