Path: utzoo!utgpu!news-server.csri.toronto.edu!clyde.concordia.ca!uunet!jarthur!jmerrill From: jmerrill@jarthur.Claremont.EDU (Confusion Reigns) Newsgroups: comp.sys.ibm.pc Subject: Re: detection of 43/50/... line modes Message-ID: <5534@jarthur.Claremont.EDU> Date: 28 Mar 90 09:09:16 GMT References: <58consult@physc1.byu.edu> Organization: Harvey Mudd College, Claremont, CA 91711 Lines: 17 In article <58consult@physc1.byu.edu> consult@physc1.byu.edu writes: > Is there a standard way to detect the number of lines an EGA or VGA display >adapter is currently using? It seems to me that there should be an address in >the ROM data area that contains this info... Anybody know where? What about >querying the ansi/nansi/(etc) driver? Yes. Check memory location 0040:0084; it contains the number of screen lines minus 1 (a 25-line display is 18 hex, a 50-line display is 31 hex). NOTE to users of DESQview 2.26: When DESQview forces a program to remain in 50-line mode, it fails to set this byte properly. I discovered this when using MS-Kermit's Tek emulation; when I came out, the display would only cover the top half of the screen. As it turns out, Kermit sets 40:84 to 18 as it leaves Tek mode, and DESQview doesn't set it back. -- Jason Merrill jmerrill@jarthur.claremont.edu