CompuServe Messages

Setmap in C

    21-Jan-92 19:12:01
Sb: #19270-Setmap in C
Fm: John Toebes/SYSOP 70007,3467
To: Henry Williams 73527,1446
Actually, I was expecting you to say this. If you are going to the trouble of forcing the keymap to a particular one, I might suggest that either (a) the existing keymap for the language is deficient and should be improved or (b) you might want to look at the problem differently. In general, keymaps are there to provide a mapping of keycaps to the represention of data. In a number of cases we have keycaps that are swapped (like z and y on the german keyboard). You might want to seriously look at rawkeys as your input mechanism and using rawkeyconvert to get the data that you want. WHat this gives you is the ability to prefilter things like ALT or Control but still allow whatever keymapping is in force. This is the much more system friendly way of making things happen. I actually wrote a program called GSETMAP that will set the keymap on everything in the system at once. It is not a pretty task to do, but you can draw from it to do your own task. I STRONGLY recommend that you do not take this route however because of the potential confusion to the user in switching keymaps on the fly. If you are only trying to add some guarenteed shortcut keys, the rawkey/keyconvert is the way to go.