Hello Sam, to continue on my newsgroup questions,
I pondered your answers and solved my problems.
I also have a diff you may want to use.
On 03 jun 2000, you wrote in loki.open-source.sdl:
SDL does query the kernel for key mappings, see FB_vgainitkeymaps()
Is there a better way to do this?
This is indeed the case. HOWEVER this is only used with
Unicode, which I do not use. (Maybe the devel release has bettered
this?) My idea was to extend this to the kesym.sym value.
By the way, why in the first place, use it for Unicode alone??
Ahh, I see. I’ll take a look at the GII code sometime and try to
improve the mapping. It will probably be some time before I get a
chance to do this, so if you want to submit a patch, you are more
than welcome.
Well, I followed up to your advice. I attached a patch,
hope it’s a format you can use. With the patch, you can ditch
SDL_fbkeys.h, and the frame buffer key code should behave
more platform independant now. On my Apple powermac (type 7600,
clone keyboard) it all works swell now, but I’m afraid you need
to hack the windows keys c.s. in again, as I obviously do not have
those.
Let me say it in another way: when running a flawed program
on the framebuffer, and when it does NOT crash but instead
loops forever, then by system is essentially blocked.
I cannot type anything. I cannot switch VT’s. I may as well throw
my keyboard out of the window. I have to resort to either
log in remotely (which is not a nice option for me) or reset
the computer (which is a Bad Thing). So, my question was:
is there an elegant way to alleviate this? Apart from forgetting
fb and debugging in X11?
I see your problem, and the answer is no, you’re probably better
off debugging in X11 until your program is fully debugged. SDL
doesn’t create a watchdog thread to make sure your program is still
responding. Heheh. I’ve seen people use gpm to monitor the mouse
port and respond to certain button combinations with predefined actions.
I’ve never done this myself, so your mileage may vary, but SDL should
detect that gpm is running and if gpm was passed the -R (repeater) option,
SDL will be able to use it for mouse input.
Sheesh… This took me two days to find out I cannot get it to
work. Luckily, a following brainwave gave me a better idea. As I
switched to an USB mouse recently, I now happily use the single button
of my spare ADB mouse to signal a 'killall ’ (this is a
separate program.) Hurrah.
Good luck!
-Sam Lantinga, Lead Programmer, Loki Entertainment Software
Same to you, I hope you let me know if the patch works.
Niels Roest
-------------- next part --------------
A non-text attachment was scrubbed…
Name: diff-keycodes
Type: application/octet-stream
Size: 9916 bytes
Desc: not available
URL: http://lists.libsdl.org/pipermail/sdl-libsdl.org/attachments/20000613/ac793134/attachment.obj