code: def keycode_to_keysym(self, keycode, index):
          
          try:
              return self._keymap_codes[keycode][index]
          except IndexError:
              return X.NoSymbol
docs: Convert a keycode to a keysym, looking in entry index.
          Normally index 0 is unshifted, 1 is shifted, 2 is alt grid, and 3
          is shift+alt grid. If that key entry is not bound, X.NoSymbol is
          returned.