C Board  

Go Back   C Board > General Programming Boards > C Programming

Reply
 
LinkBack Thread Tools Display Modes
Old 07-30-2006, 02:56 AM   #1
Registered User
 
Join Date: Jul 2006
Posts: 4
Changing font style and color of text in C

The text color and font is the same throughout the whole exe file. How can I call library and change them?
I want to set the given numbers to red in a sudoku.

P.S. Are there any online sudoku source codes in C?
Thank you.
bigKIDmarie is offline   Reply With Quote
Old 07-30-2006, 03:36 AM   #2
and the hat of Jobseeking
 
Salem's Avatar
 
Join Date: Aug 2001
Location: The edge of the known universe
Posts: 21,710
> How can I call library and change them?
Well that would depend on your OS / Compiler and project type (none of which you state).
In the meantime, try the FAQ
http://faq.cprogramming.com/cgi-bin/...&id=1043284392

> Are there any online sudoku source codes in C?
Have you tried google?
__________________
If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.

Salem is offline   Reply With Quote
Old 07-30-2006, 03:44 AM   #3
Registered User
 
Join Date: Jul 2006
Posts: 4
Does this code change color of all the text? Can I change color of certain words only?
Thank you
bigKIDmarie is offline   Reply With Quote
Old 07-30-2006, 03:47 AM   #4
Registered User
 
Join Date: Jul 2006
Posts: 4
When I compile the following code, an error occurs.
I use Dev-C++. Does this software have the library conio.h?
Thank you.


#include <stdio.h>
#include <conio.h>

int main ( void )
{
textcolor ( MAGENTA );
cprintf ( "This is a test\n" );

return 0;
}
bigKIDmarie is offline   Reply With Quote
Old 07-30-2006, 04:21 AM   #5
Registered User
 
Join Date: Jul 2006
Posts: 4
Thanks MDofRockyView, I have done this but an error occurs. My Dev-c++ doesn't say what error it is...
bigKIDmarie is offline   Reply With Quote
Old 07-30-2006, 05:04 AM   #6
and the hat of Jobseeking
 
Salem's Avatar
 
Join Date: Aug 2001
Location: The edge of the known universe
Posts: 21,710
> I use Dev-C++. Does this software have the library conio.h?
Scroll down the FAQ to where it describes the Win32 console API functions.

conio is a hack for backward compatibility with DOS.

Oh, and be more specific than "an error occurs".
Paste error messages.
__________________
If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.

Salem is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Forum Jump


All times are GMT -6. The time now is 09:20 PM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.3.2

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22