[comp.sys.next] grabbing arbitrary rectangle from Yap, Preview, or Draw

shannon@iuvax.cs.indiana.edu (Greg Shannon) (06/10/89)

I need to grab an arbitrary rectangle from one of the graphics
windows above and paste it into Writenow or Draw.
Is this possible?
Will it be possible in .9?

Thanks,
Greg Shannon
Computer Science Dept.
Indiana University, Bloomington

ali@polya.Stanford.EDU (Ali T. Ozer) (06/10/89)

In article <21866@iuvax.cs.indiana.edu> Greg Shannon writes:
>I need to grab an arbitrary rectangle from one of the graphics
>windows above and paste it into Writenow or Draw.

Both Icon and Scene have "screen grab" features that let you grab an arbitrary
rectangle off the screen and save it as encapsulated PS (which can then be
read into WriteNow (using "Paste File Graphic") or Draw (by dragging the
file icon from a Workspace Browser window into a Draw window)).

If you are creating your drawings in Draw, you can actually use the
pasteboard to transfer the drawings rather than having to use screen
grab (which ends up reducing the drawings to bitmaps). To accomplish
this in Draw, simply select the desired objects (for instance, by drawing
a rectangle around the desired area or by shift-selecting multiple objects),
and do a "copy."  Then do a "paste" in your destination program... 

Draw is capable of providing the drawings in three forms: its own
format, PostScript format, and TIFF format. If the destination program
understands any of the above, the drawing will be pasted in. (WriteNow,
for instance, can paste PostScript. Yap can too, but it pastes the
PostScript code into the text window. You can then do an "execute" to
see what it looks like. Preview can also read PostScript from the
pasteboard.)

Mathematica is also capable of copying PostScript onto the pasteboard, by 
the way. Thus importing Mathematica graphics into WriteNow is easy (and
doesn't require screen grabbing)...

Ali Ozer, NeXT Developer Support
aozer@NeXT.com