delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/11/05/16:29:28

Sender: nate AT cartsys DOT com
Message-ID: <36421552.616612BD@cartsys.com>
Date: Thu, 05 Nov 1998 13:14:58 -0800
From: Nate Eldredge <nate AT cartsys DOT com>
X-Mailer: Mozilla 4.05 [en] (X11; I; Linux 2.0.35 i486)
MIME-Version: 1.0
To: djgpp AT delorie DOT com
Subject: Re: I cant get textattr to work
References: <71sogc$pkq$1 AT nnrp1 DOT dejanews DOT com>
Reply-To: djgpp AT delorie DOT com

jackstinchcombe AT my-dejanews DOT com wrote:
> 
> I cant get textattr, textcolor or textbackground to work, the colour
> combination on the screen stays the same. The following code just puts "this
> is a test" on the screen in the normal white-on-black, rather than the
> red-on-white i expected.
> 
> Any ideas what im doing wrong?
> 
> #include <stdio.h>
> #include <conio.h>
> void main(void) {
> textcolor (12);
> textbackground (15);
> printf("\nthis is a test\n");
> }

See FAQ section 9.4.  Basically, use `cprintf'.
-- 

Nate Eldredge
nate AT cartsys DOT com

- Raw text -


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