Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

How to identify input keycode and output keycode (Taken from FS)

If you don't want to go into details then go directly to section Find the input_keycode and output_keycode for a particular key

The journey of a key

When a key is pressed on the user keyboard, before it reaches its destination and displays a key output on the user VM, it passes through the browser the client uses, the client OS, the console proxy, the server side hypervisor, host OS, and displays a key on the VM. Even when console proxy does the key translation correctly according to the standard and keyboard layout, any component in this path can change the key translation, hence it can make the key output at the end user VM incorrect. 

...

However, for the value of output_keycode, it is tricky. It is more of a trial and error process. We can search the keyboard standard key document, and try various values. We can try pressing different keys and see what input_keycode  generates what output on console. Using these trials we can get the output_code of the key

For example:

User pressed Key "$", for this say input_keycode is 36 but on screen we are getting "&". Now user tries different key

say User pressed Key "^", and say its input_keycode is 40 but on screen we are getting "$"

so we can safely deduce from that output_keycode (If it already exists in key mapping) of "^" should be but in output_code of "$".

If key mapping doesn't exist then we can try putting input_keycode itself.

Changes to be done in ajaxviewer.js

...