Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!gatech!hao!ames!oliveb!pyramid!voder!apple!dgold From: dgold@apple.UUCP (David Goldsmith) Newsgroups: comp.sys.mac Subject: Re: VBL tasks, offscreen bitmaps, Lightspeed Pascal, etc. Message-ID: <738@apple.UUCP> Date: Fri, 8-May-87 19:29:16 EDT Article-I.D.: apple.738 Posted: Fri May 8 19:29:16 1987 Date-Received: Sun, 10-May-87 00:55:09 EDT References: <18736@ucbvax.BERKELEY.EDU> <971@randvax.UUCP> Reply-To: dgold@apple.UUCP (David Goldsmith) Organization: Apple Computer Inc., Cupertino, USA Lines: 25 In article <971@randvax.UUCP> florman@randvax.UUCP (Bruce Florman) writes: >jmm@miro.Berkeley.EDU (James Moore) writes: >>1. How does one get mBarHeight from Lightspeed Pascal? > > According to Inside Mac, p I-341, "The menu bar is white, 20 pixels >high, and as wide as the screen, with a 1-pixel black lower border. The >menu titles in it are always in the system font and the system font size." >So it sounds like you can just declare a constant. This actually isn't a good idea; after Inside Macintosh (vol. I-III) were published, changes to the system software were made such that the menu bar height is no longer a constant (this is also the case on the Radius FPD). The best way to get MBarHeight is to declare a type pInt = ^INTEGER, then cast the constant address of MBarHeight ($BAA - only on 128K ROMs - assume "20" if not on 128K ROMs) to type pInt and dereference it. In MPW Pascal, this would be: theHeight := pInt($BAA)^; in other Pascals you may have to use intermediate variables. -- David Goldsmith Apple Computer, Inc. MacApp Group AppleLink: GOLDSMITH1 UUCP: {nsc,dual,sun,voder,ucbvax!mtxinu}!apple!dgold CSNET: dgold@apple.CSNET, dgold%apple@CSNET-RELAY BIthe fis k3UHXp