| | |
Using cout with graphic screens
Please support our C++ advertiser: Intel Parallel Studio Home
![]() |
•
•
Join Date: Nov 2007
Posts: 390
Reputation:
Solved Threads: 39
•
•
•
•
If I initialize graphics in my program and then use cout the font appears bigger than normal and the cursor doesn't blink on the screen as it does when the graphics are not initialized.Is there any way I can use graphics as well as cout in my program?If yes how to do that.
•
•
Join Date: Oct 2006
Posts: 38
Reputation:
Solved Threads: 0
•
•
•
•
If I initialize graphics in my program and then use cout the font appears bigger than normal and the cursor doesn't blink on the screen as it does when the graphics are not initialized.Is there any way I can use graphics as well as cout in my program?If yes how to do that.
There are two modes of programming in Borland C++.
1. text mode
2. graphics mode.
In text mode, we have 80 columns and 50 rows in windows xp but in graphics mode, we have 640 columns and 480 rows.
Every mode has its own define functions. We cannot use text mode function and graphics mode similarly, its opposite is too.
"cout " works only in text mode. It cannot be used in graphics mode instead you have to use graphics function to print some text in graphics mode.
try this function in graphics mode. outtextxy(x,y,"string to write");
C++ Syntax (Toggle Plain Text)
int x = 300; int y=200; outtextxy(x,y,"Hello World"); //output:- The text will be printed approximately in the center of the graphic mode screen
--
Regards,
Asif
![]() |
Other Threads in the C++ Forum
- Previous Thread: Help with a rot13 encrypter
- Next Thread: [Borland C++ Builder] ListBox Multiple Selection
| Thread Tools | Search this Thread |
api application array arrays based beginner binary bmp c++ c/c++ calculator char char* class classes code coding compile compiler console conversion convert count database delete deploy developer dll download dynamiccharacterarray email encryption error file format forms fstream function functions game generator givemetehcodez graph gui homeworkhelp iamthwee ifstream image input int java lib library linker list loop looping loops map math matrix memory multiple newbie news number numbertoword output pointer problem program programming project python random read recursion recursive reference rpg simple sorting string strings temperature template text text-file tree url variable vector video visual visualstudio win32 windows winsock wordfrequency wxwidgets





