qtconfig can't start in GNOME with XMODIFIERS="@im=SCIM" and scim running

Bug #28590 reported by Ming Hua
8
Affects Status Importance Assigned to Milestone
qt-x11-free (Ubuntu)
Invalid
Medium
Unassigned

Bug Description

After qt-x11-free 3:3.3.5-1ubuntu14 fixing the XIM support in Qt, I can activate XIM in Qt/KDE apps in KDE environments. However, now with the same XIM program (scim), Qt/KDE apps don't work anymore in GNOME environment.

Take qtconfig for example, if I set the XIM environment variable XMODIFIERS="@im=SCIM", then start my scim program in GNOME, with "scim -d", qtconfig doesn't work anymore:

$ qtconfig
Failed to create XIM input context!
Aborted

Running qtconfig without XIM environment variable set is fine, i.e.
$ XMODIFIERS="" qtconfig
works. If I don't start scim, but only set XMODFIERS, qtconfig works fine too, although complaining that it can't find input context or something.

The QT_IM_MODULE can also control Qt/KDE apps' behavior with regard of input methods. In my test QT_IM_MODULE is not set, but if I explicitly set it to empty:
$ QT_IM_MODULE="" qtconfig
will work. And setting it to xim:
$ QT_IM_MODULE="xim" qtconfig
will abort in the same way. So it seems when QT_IM_MODULE is not set, it defaults to xim.

Revision history for this message
Ming Hua (minghua) wrote : gdb backtrace

This is a gdb backtrace for qtconfig aborting in GNOME with scim running and XMODIFIERS set to "@im=SCIM"

Revision history for this message
Ming Hua (minghua) wrote :

How to reproduce:

1. Install scim from universe.
2. Before logging into GNOME, set the XIM environment variable XMODIFIERS to "@im=SCIM". Adding a line ``export XMODIFIERS="@im=SCIM"'' in ~/.gnomerc should work.
3. After logging into GNOME, open an X terminal and make sure XMODIFIERS is set. Now run qtconfig, it should work.
4. Start scim by "scim -d". An icon of a little keyboard should appear in system tray.
5. Run qtconfig again, it would abort.
6. Try different environments, like ``XMODIFIERS="" qtconfig'', ``QT_IM_MODULE="" qtconfig'', see the different behaviours.

I hope this can help developers not familar with input methods to reproduce this bug sucessfully.

Revision history for this message
Ming Hua (minghua) wrote :

I will build qt-x11-free without the immodule patch and test again soon. I am starting to be more and more skeptical about the quality of this immodule for Qt 3 patch. :-(

Revision history for this message
Ming Hua (minghua) wrote : strace

The strace output for qtconfig per \sh's request

Revision history for this message
Ming Hua (minghua) wrote :

I tried to take out the immodule patch and rebuild qt-x11-free, but qtconfig still aborts in GNOME. I probably didn't disable the patch correctly, maybe I should use an older version of qt-x11-free instead. Anyway, I probably don't have more time to investigate this recently.

One thing I didn't mention is that with the same environment settings, all KDE apps just plainly crash (including the KCrash program that gets started after the first app crashes). I choose to use qtconfig as the example just because it's simpler.

Revision history for this message
Ming Hua (minghua) wrote : Re: [Bug 28590] qtconfig can't start in GNOME with XMODIFIERS="@im=SCIM" and scim running

On Sun, Jan 15, 2006 at 06:08:01AM -0000, Ming Hua wrote:
>
> I will build qt-x11-free without the immodule patch and test again soon.
> I am starting to be more and more skeptical about the quality of this
> immodule for Qt 3 patch. :-(

As reported, I took out the immodule patch and this bug still exists.
Recently I talked with an SCIM user on IRC and he told me that this bug
also exists in Debian (which means it's unrelated to immodule patch),
and only happen when Qt XIM input style is set to "over the spot", so a
workaround can be using "on the spot" style. He also said this is not
specific to scim, but also happens for all XIM programs.

Will test the workaround and other input methods soon.

Ming
2006.01.20

Revision history for this message
Ming Hua (minghua) wrote :

On Fri, Jan 20, 2006 at 08:36:05PM -0000, Ming Hua wrote:
>
> Recently I talked with an SCIM user on IRC and he told me that this bug
> also exists in Debian (which means it's unrelated to immodule patch),
> and only happen when Qt XIM input style is set to "over the spot", so a
> workaround can be using "on the spot" style.

Setting both scim and Qt to "on the spot" style indeed makes this bug
disappear.

Ming
2006.01.21

Revision history for this message
atie (atie-at-matrix) wrote :

What is default value for Qt (mine is "on the spot") and where can set the value for scim? (I couldn't find it from the GUI setup)
And, do scim (or XIM) users need to know this or will be defaulted on the package?

Revision history for this message
Ming Hua (minghua) wrote :

On Sat, Jan 21, 2006 at 09:53:06AM -0000, atie wrote:
> What is default value for Qt (mine is "on the spot")

I think it's "on the spot".

> and where can set the value for scim? (I couldn't find it from the GUI
> setup)

It is in the scim-setup GUI [1]:
    "To change the style in SCIM, run scim-setup (or choose "SCIM Input
    Method Setup" from your menu), and go to the "FrontEnd -> Global
    Setup" page. The option to change XIM style is "Embed Preedit
    String into client window", when it is selected, you are using "on
    the spot" style; and when it is not selected, you are using "over
    the spot" style."

> And, do scim (or XIM) users need to know this or will be defaulted on
> the package?

I am not aware of any universal way to set the default style for an XIM
program. But I am by no means an expert, and I didn't look hard.

1. http://svn.debian.org/wsvn/pkg-ime/scim/trunk/debian/README.Qt?op=file&rev=0&sc=0

Ming
2006.01.21

Revision history for this message
nahs (nahs777) wrote :

try QT_IM_MODULE=scim not xim.
dapper has QT_IMMODULE patch so it works.

Revision history for this message
Ming Hua (minghua) wrote :

On Sat, Jan 21, 2006 at 12:42:06PM -0000, nahs wrote:
>
> Comment:
> try QT_IM_MODULE=scim not xim.
> dapper has QT_IMMODULE patch so it works.

Well, that doesn't solve the problem, just work around it, right?

Thanks for testing QT_IM_MODULE=scim anyway.

Ming
2006.01.21

Matt Zimmerman (mdz)
Changed in qt-x11-free:
assignee: nobody → jr
Revision history for this message
Connor Imes (ckimes) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. You reported this bug a while ago and there hasn't been any activity in it recently. We were wondering if this is still an issue for you. Can you try with the latest Ubuntu release? Thanks in advance.

Changed in qt-x11-free:
status: New → Incomplete
Revision history for this message
Jonathan Thomas (echidnaman) wrote :

We are closing this bug report because it lacks the information we need to investigate the problem, as described in the previous comments. Please reopen it if you can give us the missing information, and don't hesitate to submit bug reports in the future. To reopen the bug report you can click on the current status, under the Status column, and change the Status back to "New". Thanks again!

Changed in qt-x11-free:
assignee: jr → nobody
status: Incomplete → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.