home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.sys.mac.programmer
- Path: sparky!uunet!zaphod.mps.ohio-state.edu!uwm.edu!linac!uchinews!grass
- From: grass@cs.uchicago.edu (Joshua Grass)
- Subject: Re: GWorlds and Windows - a problem....
- Message-ID: <1993Jan10.225929.1773@midway.uchicago.edu>
- Sender: news@uchinews.uchicago.edu (News System)
- Organization: Department of Computer Science, University of Chicago
- References: <1993Jan8.233136.18543@cs.ucla.edu> <1ililcINNo5d@cat.cis.Brown.EDU>
- Date: Sun, 10 Jan 1993 22:59:29 GMT
- Lines: 32
-
- In article <1ililcINNo5d@cat.cis.Brown.EDU> ST202153@brownvm.brown.edu () writes:
- >In article <1993Jan8.233136.18543@cs.ucla.edu>, tj@kona.cs.ucla.edu (Tom
- >Johnson) said:
- >>When WORKING is defined as TRUE, the program executes successfully. When
- >>it is FALSE, the program crashes at the NewCWindow() call.
- >
- >> SetGWorld(offWorld, nil);
- >> PaintRect(&offR); // Just fill it w/ black
- >>
- >>#if !WORKING // this will crash spectacularly
- >> wind = NewCWindow(nil, &windR, "\p", TRUE, zoomDocProc,
- >> (WindowPtr) -1, TRUE, 0);
- >>#endif
- >>
- >> SetGWorld(SavePort, SaveGD);
- >
- >You probably need to move the SetGWorld call before NewCWindow. QuickDraw
- >does an amazingly good job of crashing when the port is set to an offscreen
- >GWorld at the wrong time. (I had a TCL app which drew in an offscreen port
- >while updating a progress bar. The number of times I restarted while
- >debugging is best left unsaid.)
- >
- >Andrew Shearer
- >st202153@brown.edu
-
- One problem might also be the think c has an error in its mac library with
- NewCWindow, namely that it returns a window, not a cwindow. I've fixed mine
- and recompiled it and alot of color window stuff works now. This is with
- ver 5.0. newer versions might have fixed this fairly glaring problem.
-
- Joshua
-
-