Re: [Dev-C++] How to get a ... gotoxy() equivalence in devC++ mingw ????
Open Source C & C++ IDE for Windows
Brought to you by:
claplace
|
From: Jason H. <jas...@nt...> - 2002-05-31 02:29:20
|
Hi, I've attached something I wrote a while back. It's a simple demo of how to manipulate the
console parameters using the windows api. It's important to note that this is non-portable code, it
won't work in dos, linux, etc... only Windows. I am not aware of any way of writing a gotoxy
function that is portable, because the underlying way of writing to the screen buffers in an OS will
vary.
You can look up the various calls I made in the Win32 API documentation. Also you will note that I
get the console handle everytime at the beginning of the funciton, you could rewrite it so the
handle is stored in some permanent variable, and then reused. This would reduce overhead for the
functions, but would require an initialisation phase to be introduced, which probably lends itself
to the creation of a Console class(?).
Similar functions may have been supplied by the Dev-C++ team, but if not I think it would be
worthwhile adding them as standard, because this question is asked so many times!
The ANSI C/C++ standard makes no provision for "gotoxy" or "clrscr" functions, they were created as
part of the Borland Turbo IDE's. (AFAIK)
Jason.
----- Original Message -----
From: "Roberto Ricardi" <rob...@ar...>
To: <Dev...@li...>
Sent: Friday, May 31, 2002 3:08 AM
Subject: [Dev-C++] How to get a ... gotoxy() equivalence in devC++ mingw ????
Hi all,
Ok, I have not experience in c++ themes ( I dont want at this time)
.Just want c works
There are any single squeleton to do some like ...
( my code here )
.....
gotoxy(a,b) ; prinft("Hi world"); /* or wathever equivalence */
....
(more my code code and so on)
Thanks in advance
Rob
_______________________________________________________________
Don't miss the 2002 Sprint PCS Application Developer's Conference
August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm
_______________________________________________
Dev-cpp-users mailing list
Dev...@li...
https://lists.sourceforge.net/lists/listinfo/dev-cpp-users
|