Article View: comp.sys.mac
Article #40291Re: Window with no menu bar?
From: Sho Kuwamoto
Date: Tue, 04 Apr 1989 03:04
Date: Tue, 04 Apr 1989 03:04
24 lines
1872 bytes
1872 bytes
In article <11208@well.UUCP> svc@well.UUCP (Leonard Rosenthol) writes: <In article <3867@emory.mathcs.emory.edu>, phssra@mathcs.emory.edu (Scott R. Anderson) writes: < There is no CLEAN solution to the problem of using the whole screen <(ie. covering the menubar) but the one that I prefer as it does not mess with <the GrayRgn (and it is what Hypercard does) is to actually remove the MenuBar <and then let the OS redefine the GrayRgn for you. < The following outline of the procedure should give you an idea of what <to do to get rid of the menuBar - JUST REMEMBER that if the user could somehow <switch out of your application while the menuBar is gone - you had better <check for it and handle it properly! < <Get the MenuBar height (either use GetMBarHeight or check $BAA) <Set the MenuBar height to 0 (set $BAA to 0 yourself) <Call DrawMenuBar (this will get the OS to reset the GrayRgn for you) <Get the GrayRgn (use GetGrayRgn) and use it to draw the screen <Reset the MenuBar height to the saved value (set $BAA to the saved value) <Call DrawMenuBar (reset the GrayRgn back for you) Interesting. I am surprised that this is the way Hypercard does it. I assumed it screwed up the GrayRgn itself, because the rounded corners become square. Do the ROM routines just leave the GrayRgn as a rectangle if the MBarHeight is zero? If so, why? -Sho
Technical Details
Message-ID:
<2098@pur-phy>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!iuvax!pur-ee!pur-phy!shoReferences:
<15866@cup.portal.com> <2214@helios.ee.lbl.gov> <3867@emory.mathcs.emory.edu> <11208@well.UUCP>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!iuvax!pur-ee!pur-phy!sho From: sho@pur-phy (Sho Kuwamoto) Newsgroups: comp.sys.mac Subject: Re: Window with no menu bar? Message-ID: <2098@pur-phy> Date: 4 Apr 89 03:04:03 GMT References: <15866@cup.portal.com> <2214@helios.ee.lbl.gov> <3867@emory.mathcs.emory.edu> <11208@well.UUCP> Reply-To: sho@newton.physics.purdue.edu.UUCP (Sho Kuwamoto) Distribution: usa Organization: Purdue Univ. Physics Dept., W. Lafayette, IN Lines: 24