Computer Science Canada get using mouse |
Author: | ElimPi [ Sun Jun 18, 2006 2:42 pm ] |
Post subject: | get using mouse |
Hello, I'm wondering if there's any way to use the mouse to complete a get. What I want is for the user to be able to click a part of the screen after typing in an integer instead of hitting enter. Is this possible? |
Author: | TheOneTrueGod [ Sun Jun 18, 2006 2:45 pm ] |
Post subject: | |
You would have to design your own input system using hasch and getch. Using standard turing commands there is no way to do this. (That I know of) |
Author: | ElimPi [ Sun Jun 18, 2006 2:48 pm ] |
Post subject: | |
A friend of mine told me to use "fork", but I'm not quite sure how that works, any ideas? |
Author: | TheOneTrueGod [ Sun Jun 18, 2006 3:12 pm ] |
Post subject: | |
Its using processes, and you should generally avoid those unless you know exactly what you are doing. (You dont ![]() Either way, I don't think you can do this with processes. Like I said before, use getch to get one character at a time, concatenate the "gotched" characters into one large string, and then instead of stopping "getching" characters when they press enter, instead stop when they press a button (Mouse is in a certain area and they press the button down) |