I recently checked out the awesomeness of VNC, using OSXvnc and Chicken of the VNC to be able to use my desktop machine from my wife's laptop on a different floor (when, for example, my baby prevents me from going downstairs to the desktop). Everything installed and connected very easily (once I remembered to open the VNC port in the Mac firewalls), but any text I typed was coming out as complete gibberish.
My wife and I both use the Dvorak keyboard mapping. After a bit of playing around, I found out that the mapping turns out to not be reversed if you "apply" it twice. So one of the keyboards had to be switched to QWERTY (which is effectively the "identity" mapping, in mathematical terms). Said differently, in a pseudo-mathematical phrasing, keyboard mapping over two computers interacting via VNC go as follows:
Mac OS X Hints
http://hints.macworld.com/article.php?story=20050516000847681