On Thu, May 20, 2021, at 13:02, Yuuki Harano wrote:
Key events are handled in key_press_event() in pgtkterm.c.
I think `keysym` contains a character code, which is already
interpreted.
I stepped through the code with gdb and watched the keysym values.
I observed the following values for keysym in this order when pressing "C-L3-i" (sends "C-{") (working case):
65507 (state goes to 4 --> state to 0 and modifiers to 4)
65027 (state becomes 132 --> modifiers becomes 132 and state 128)
123 (no changes to state and modifiers)
65515 (should be me using Super+o to switch workspaces in xmonad)
And these for the non working case "C-L3-n" (which sends "(" and should send "C-("):
65507 (state to 4 --> state to 0 and modifiers to 4)
65027 (both state and modifiers become 0)
65515
I was unable to get the keysym of the key itself in the non-working cases.
Used breakpoints in pgtkterm.c:
5669
5687
5701
5710
5731
5809
5860
5876
I sadly do not know enough C to understand why this happens. Does this help you at all? Any further information I could provide that would be helpful?