[comp.sys.mac.programmer] clipping to visRgn

nenicola@ndsuvax.UUCP (Steven Nicolai) (01/29/89)

In article <2534@pegasus.ATT.COM> ech@pegasus.ATT.COM (Edward C Horvath) writes:
>In article <24307@apple.Apple.COM> parent@Apple.COM (Sean Parent) writes:
>>There is no way to tell for sure that there are not any windows in front of
>>your window. The system owns the screen.
[The discussion goes on to talk about limiting drawing to the visRgn, is
 a perfectly legal way to optimize screen drawing]

I have an additional comment to make on this.  This technique works very
well for screen drawing, but can be a real problem for printing.  Since
printing is done into a grafPort, and the visRgn is part of the grafPort,
you would think that it would be set up to the visible portion of the page.
Some printer drivers do this, but some do not.  I forget which one I ran
into the problem on, either the LaserWriter IISC or the ImageWriter LQ.
This means that checking the visRgn has to be disabled while printing.

It would be really nice if Apple would publish a set of specifications that
all printer drivers should adhere too.  Given the sparse documentation,
its a wonder anyone outside Apple has written one that works with a majority
of applications.  These specs would also be useful for applications to make
their printing 100% portable, rather than having to make changes whenever
a new printer needs to be supported.

STeve
--
Steve Nicolai                    USMAIL:   1717 40th St SW Apt 106
ARPA & UUCP: nenicola@plains.NoDak         Fargo, ND  58103
BITNET:      nenicola@ndsuvax              (701)-281-1230