I thought I would try one more time because I knew I've seen
an example of what I was looking for. Steve Van Voorst wrote
a demo called "HITheme_demos". In it, it draw primitives of
many HIView/Controls. If you don't have it, I'll see if I can
get it to you tonight. I have my Mac but its not connected to
a network. Hmmm, its got some interesting things in it. I may
need to look at this a little deeper for myself.
W.
-----Original Message-----
From: Edwards, Waverly
Sent: Thursday, October 01, 2009 5:14 PM
To: 'futurebasic@...'
Subject: RE: [FB] Combining CoreText and CG
I tried really hard to find the code I remember for solution #2.
I thought I remembered the demo but I couldn't find it anywhere.
I believe it involved the use of DrawInPort but I couldn't find
anything on that either. In retrospect I'm not sure that would
work anyway. DrawInPort involved changing the port then forcing
the control to display in that port. Controls/HIViews have
owners but I don't know how you would change the owner. Also,
the controls and view may need a CGContextRef which a printer
port doesn't have but RP was able to print CG graphics to the
printer using "How to Print Coregraphics".
I've got a long shot. You could add a carbon event (kDrawControl)
to the controls you want to print , and maybe you could redirect
the drawing. That may only enable you to add to what is being
drawn though. I'm grasping at straws.
W.