www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/10/22/05:31:36

Date: Thu, 22 Oct 1998 10:29:58 +0200 (IST)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
X-Sender: eliz AT is
To: is05562 AT salleURL DOT edu
cc: djgpp AT delorie DOT com
Subject: Re: problems with cprintf and 50 lines mode...
In-Reply-To: <70er73$o3p@lilith.uab.es>
Message-ID: <Pine.SUN.3.91.981022102624.2797B-100000@is>
MIME-Version: 1.0
Reply-To: djgpp AT delorie DOT com

On 19 Oct 1998 is05562 AT salleURL DOT edu wrote:

>    mov ax,0003h
>    int 10h
> 
>    mov ax,1112h
>    xor bx,bx
>    int 10h
> 
> this sets 80x50 text mode, and cprintf works flawlessly with it... BUT
> ONLY IF THE .EXE I PRODUCE STARTS FROM DOS IN 50 LINES MODE! :((( If
> I start the .EXE from DOS in 25 lines mode, then strange scroll appears at
> the bottom of the screen, like if cprintf thought that there were only 25
> lines (when I really inserted the above code, and the screen appears to be
> in 50 lines mode: 8x8 chars).

This problem happens because you don't call conio functions to change the 
screen dimensions, but instead use direct Int 10h calls.  conio functions 
have internal variables that track the screen dimensions, but you defeat 
all that machinery when you change the dimensions behind conio's back.

Use textmode(C4350) or _set_screen_lines(50) to change the screen 
dimensions, and the problem should go away.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019