www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/08/26/18:46:28.1

From: Damian Yerrick <Bullcr_pd_yerrick AT hotmail DOT comRemoveBullcr_p>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: printf, cprintf and CR/LF problem
Organization: Pin Eight Software http://pineight.8m.com/
Message-ID: <k5hgqs8ue64hfjp8m6r3ijgmmpbikrqcum@4ax.com>
References: <s2fgqs8iobmdvbfrjfl2tfm57i2o9e2mov AT 4ax DOT com>
X-Newsreader: Forte Agent 1.7/32.534
MIME-Version: 1.0
Lines: 36
X-Trace: /bCCZGi+PTL+/M8DIOkcrM/AogmHddIyTqBuMXZXWH4/vbwdOOAgbP+3+wsNMNZDmwfdmSGvWqG/!ErLP2r111jxPOE35fDeZumMhVgbb+Skki2Swhew6dhr5hueDFm1SIyQ8WoLKPHHaej39XgX3UrDY!Hw==
X-Complaints-To: abuse AT gte DOT net
X-Abuse-Info: Please be sure to forward a copy of ALL headers
X-Abuse-Info: Otherwise we will be unable to process your complaint properly
NNTP-Posting-Date: Sat, 26 Aug 2000 22:32:35 GMT
Distribution: world
Date: Sat, 26 Aug 2000 22:32:35 GMT
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

On Sat, 26 Aug 2000 17:59:26 -0400, Radical NetSurfer
<radsmail AT juno DOT com> wrote:

>Todays latest discoveries, with no work-around to date:
>
>Apparently, 
>  printf
> and
>  cprintf
>
>are immediately outputting a cr/lf, and scrolling, once it reaches the
>line limit, before it may actually be necessary to do so (issue cr/lf
>and scrolling).   Other screen I/O routines actually WAIT for the NEXT
>line to actually begin printing, and then do NOT actually insert a
>BLANK line (as if CR/LF is actually a part of the line itself)
>(allowing all 80 characters of a standard text screen to be printed,
>and seeing the CR/LF as simply going to the next line).
>
>Is there any way to get this proper (and apparently expected) behavior
>from printf, and cprintf, in DJGPP and other compilers?

printf() simply sends all its output to the console, as is written in
the ISO C standard.

cprintf() is not defined in the ISO C standard; it's a holdover from
Borland.  Most DJGPP programs that need to access the bottom line of
the screen use direct screen writes (ScreenUpdateLine() or just
_farpokew() through _dos_ds) or the pdcurses library.

-- 
MS (n)  1. A debilitating and surprisingly widespread affliction
  that renders the sufferer barely able to perform the simplest
  task.  2. A disease, multiple sclerosis (see).

This is McAfee VirusScan. Add these two lines to your signature to
prevent the spread of signature viruses.  http://www.mcafee.com/

- Raw text -


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