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

Characters entered in English instead of Japanese, when in a QWidgetAction, with a Widget that contains a QLineEdit

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P2: Important
    • None
    • 5.6.0, 5.9.0, 6.5
    • My environment is a 16.04.2 LTS Ubuntu Linux, tested with with Qt 5.6.0 and Qt 5.9.0.

    Description

      Hello, thanks for the great work on Qt. I am a Java/Python developer, but user or tools that use Qt and C++ like Krita and QGIS. And every now and then try to fix issues that I may find on these tools.

      Krita has a bug reported, where when a user has set the keyboard input to Japanese, and while it works in other QLineEdit fields, there is one case where it doesn't work, and instead, the input appears in English.

      The bug has been reported on KDE's BugZilla: https://bugs.kde.org/show_bug.cgi?id=362967 Here's a GIF of what the bug looks like with the latest version of Krita (3.1.4).

      Interesting, if you copy and paste, the correct content appears on the field. I tried a few different ways, using different parents, overriding the `createWidget` method in a custom `QWidgetAction`, but none worked.

      Even though I am not much of a C++ programmer, and don't know much about Qt, I tried setting up a project as example.

      https://github.com/kinow/qt-japanese-submenu

      There is a Python project, that you can simply start the `main.py` if you have PyQt5. Or there is a C++ project that - hopefully - should be helpful too, under the cpp/ folder. Just go to the build/ folder, and then run `cmake ../cpp`.

      Let me know if there is any information I forgot to include here, please. Looked for issues related to QWidgetAction, and to Japanese, but could not find any exactly like this one.

      Thank you in advance!

      Bruno

      Attachments

        1. bug-qt-krita.gif
          bug-qt-krita.gif
          231 kB
        2. QTBUG-61152.cpp
          3 kB
        3. qt-japanese-submenu.tar.gz
          3.32 MB
        4. qt-japanese-submenu.tar.gz
          3.32 MB

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              qt.team.quick.subscriptions Qt Quick and Widgets Team
              kinow Bruno Kinoshita
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:

                Gerrit Reviews

                  There are no open Gerrit changes