Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-49448

Shift modifier is stripped from keys sent with XSendEvent

    XMLWordPrintable

Details

    Description

      Steps to reproduce:
      1. Create a simple QML program with only a TextInput in it.
      2. Run the xdotool utility:
      xdotool selectwindow
      (select the window with the mouse)
      (copy the window ID printed)
      sleep 3; xdotool key --window [copied window id] exclam
      3. While the sleep is running, focus the TextInput field.

      Expected result:
      ! is typed in the field

      Actual result:
      1 is typed in the field.

      I think this is a bug because I can run the same program in Qt4.8.4 and see an exclamation mark printed as expected. This affects other keys too like @, %, ^, etc. Also note, the same effect as above happens with "xdotool key --window $wid shift+1".

      I don't think it can be a bug with xdotool since I've used it with some other programs without this error.

      I am new to this topic but it seems that maybe the XSendEvent call is having its shift modifier stripped out. It's worth noting that if I use simply "xdotool key exclam" while the window is focused then it works... but for various reasons this is not an option.

      Attachments

        Issue Links

          Activity

            People

              paeglis Gatis Paeglis
              mpnolan Mike Nolan
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: