Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!tut.cis.ohio-state.edu!ucbvax!decwrl!thundr.dec.com!minow From: minow@thundr.dec.com (Repent! Godot is coming soon! Repent!) Newsgroups: comp.sys.mac.programmer Subject: re: Window with no menu bar? Message-ID: <8904041337.AA01840@decwrl.dec.com> Date: 4 Apr 89 17:28:00 GMT Organization: Digital Equipment Corporation Lines: 39 I used the following to get a full-screen window. Note that the menu bar is not affected. Setup. Done once. SetRect(&window_bounds, 0, 0, screenBits.bounds.right - screenBits.bounds.left, screenBits.bounds.bottom - screenBits.bounds.top ); window = NewWindow(NIL, &window_bounds, "\p", false, plainDbox, ...); To display the window (effected by a dialog option): SelectWindow(window); ShowWindow(window); /* * This is needed to get a full-screen window. * It effectively hides the menu bar. It must * be after ShowWindow(). */ CopyRgn(window->clipRgn, window->visRgn); SetPort(window); InvalRect(&thePort->portRect); The update event causes the actual window contents to be drawn. Note: this is very fragile: the menu bar pops up if you put up a desk accessory or similar. Also, SuperClock overwrites the display. I'm using it for a display application on a dedicated Mac (reads data from the network and shows it on a display screen). I've used this on a non-networked application where the window is displayed after exiting a dialog. The main event loop hides the window after a mouse click. (Yes, I know this violates the guidelines.) Martin Minow minow%thundr.dec@decwrl.dec.com