I'm working on a custom keyboard input routine. Again, thanks for the help yesterday with _getch(). I now have a loop that assigns a key press to a variable and uses printf to print it to the screen if it is a standard writing character. I also used the FAQ to find how to trap the cursor arrow keys in C.
When I type: 123 to the screen, I see...
...in the console. Now, here's the trick...how to tell the code in the SWITCH conditional statement for arrow key left that when I hit the left arrow key to move back one space, I will have:
displayed in the console?
I have seen the gotoxy() example in the FAQ, but I cannot get it to LINK. It compiles but it gives the LINK error message:
C:\DEV-C_~1\LIB\\libmingw32.a(main.o)(.text+0x8e): undefined reference to `WinMain@16'
I must be missing something. I am using Dev-C++ version 4.0 and not the latest beta 5 (184.108.40.206) version.
I have downloaded Win32API and I know that there is a console cursor routine that has a library I could use. (Sorry, long statement name and I cannot recall it now, but I can find it later.)
Anyway, what would be the best way to keep the code as portable as possible and manipulate the cursor? Also, any ideas as to what I am missing that causes the gotoxy() sample in the FAQ not to link in my compiler?