It's based on the measured distance between the centers of the keys, so since the keys are taller than they are wide, it's a shorter distance between horizontal keys than vertical. As for informing the user about what colors mean, that was what the examples were meant to indicate: Q is as far as possible, and U is as close as possible (horizontally adjacent). But as was suggested I'm going to try adding a gauge next to the game board so it's more clear