On Sun, Sep 16, 2007 at 08:12:56AM +0900, Osamu Aoki wrote:
> After talking to
> Goto-san today, I feel like to replace im-switch package with something
> like im-common package in which uim, kinput2, SCIM just share X
> initialization hook or even SCIM to include hook in somewhere like
> /usr/share/gnome/autostart.

I would definitely support such an idea.  Although I am not sure we
should deviate from the X session hooks -- after all, there are quite
some non-GNOME/KDE users.

> On Sat, Sep 15, 2007 at 01:37:08AM -0500, Ming Hua wrote:
> > 
> > I am not sure what you mean by "it was there anyway".  I just tested
> > myself, by changing the line #64 of /etc/X11/Xsession.d/80im-switch from
> >     ... && eval "$XIM_PROGRAM $XIM_ARGS &" || ...
> > to
> >     ... && eval "$XIM_PROGRAM $XIM_ARGS" || ...
> > i.e., remove the trailing "&" when calling "scim -d".  With this change
> > I don't have a "[scim] <defunct>" zombie process anymore.  In other
> > words, this change in 80im-switch fixes bug #431294.
> > 
> > Osamu, can you confirm this?  If so, I think the easiest way is to make
> > im-switch configurable to not append the "&" to the IME invocation
> > command.
> 
> Yes.  I confirmed too.
> 
> The thing is many older IME interfaces such as kinput2 requires to have
> & after the command.  So removing & from im-switch breaks them.

I understand some IMEs need this "&" to put themselves into background
and we shouldn't break them.  I was proposing something similar to:

In /etc/X11/Xsession.d/80im-switch, change it to something like:
if [ -n "$XIM_PROGRAM_RUN_IN_BACKGROUND" ]; then
    [ -n "$XIM_PROGRAM" -a -x "$XIM_PROGRAM" ] && eval "$XIM_PROGRAM $XIM_ARGS" 
|| true
else
    [ -n "$XIM_PROGRAM" -a -x "$XIM_PROGRAM" ] && eval "$XIM_PROGRAM $XIM_ARGS 
-d" || true
fi
This way without $XIM_PROGRAM_RUN_IN_BACKGROUND defined (which is
default), im-switch will add "&" at the end of the command line and
nothing changes for old IMEs; while scim can define
$XIM_PROGRAM_RUN_IN_BACKGROUND in its im-switch script and get rid of
the "&".

It probably can be simplified to use && and || relations, but my
script-fu is not that great.
    
> For the moment, I suggest to fix bug #431294 by making 
> /etc/X11/xinit/xinput.d/scim to be
[snipped]

My understanding is that these long commands are there to avoid starting
scim twice if a scim-launcher process is already running.  I think this
is a separate issue and I have some problem with the implementation.
But first let me make sure I understood your intention correctly.

Ming
2007.09.17



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to