I do contract work for a living, which could include writing a program such as this. However, I don’t do people’s homework for them. That just robs them of an education.
You have my full permission to implement this project any way you please.
Here is how it would work. You would find some drawing program to create *.gifs or jpgs of various shapes of keyboard keys. Perhaps having some with darker backgrounds. Your general purpose Applet would read a file describing the keyboard to be drawn and render it realistically. The keyboard configuration file, passed as an Applet parameter, would give the shapes of each key, and its legend, and perhaps some rough positioning clues. Ideally the program automatically computes the precise x,y co-ordinates of each key (perhaps using a custom layout manager).
You might allow a list of keyboard descriptor files. Then the user could select which one she wanted to view, or which ones she wanted to view simultaneously, with a pull-down selector.
You could then use screen capture to create *.gifs, or embed the Applet directly in HTML to generate displays dynamically.
If you want to go for something more challenging, create a state machine that lets the user type on the keyboard with mouse clicks, or with the real keyboard and see the keys depress, and the type appear in a window. It has to pay attention to things like shift and alt keys, and possibly dead keys if you want to simulate European keyboards. You might look at some of my keyboard remapping TSRs written in heavily commented assembler such as ESPAN, DVORAK and QUEBEC to get some ideas on how they work.
You might eventually evolve this project into a full-scale platform-independent typing tutor modeled after Kriya Typing Tutor or Mavis Beacon. You could use it to help people learn which finger to use to hit which key. For an advanced project, figure out a way to determine which finger the novice used to hit each key, and beep and refuse to accept the keystroke when he uses the wrong finger, even if he gets the right key. This requires the invention of some hardware to detect hand or finger positions.
The other way this project could evolve is to aid in preparing documentation to teach novices to use a keyboard. For this you need to find or create a font with glyphs to represent the various keys. You might want alternate glyphs to discriminate between keys that you hit and release, and those that you press and hold while you hit some other key. Alternatively you might simply generate screen displays representing the sample keystrokes that can be captured as *.gif images and embedded in the documentation. That technique gets around the problem of creating and distributing the keycap images as a font. The drawback is the *.gifs are much bulkier.
Unicode now has a keycap enclosing character \u20E3, but no font has it, and nothing I know of will render text inside it.
![]() |
and suggestions to improve this page to Roedy Green : | ||
| Canadian Mind Products | |||
| mindprod.com IP:[65.110.21.43] | |||
| Your face IP:[38.103.63.61] | The information on this page is for non-military use only. | ||
| You are visitor number 5,950. | Military use includes use by defence contractors. | ||
| You can get a fresh copy of this page from: | or possibly from your local J: drive (Java virtual drive/mindprod.com website mirror) | ||
| http://mindprod.com/project/keyboardillustrator.html | J:\mindprod\project\keyboardillustrator.html | ||