Bug 583716

Summary: Need additional runtime detecting in ibus.conf for Kimpanel
Product: [Fedora] Fedora Reporter: Robin Lee <robinlee.sysu>
Component: ibusAssignee: fujiwara <tfujiwar>
Status: CLOSED NEXTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: low    
Version: rawhideCC: i18n-bugs, kevin, rdieter, supercyper1, tfujiwar, yshao
Target Milestone: ---Keywords: EasyFix, FutureFeature, Improvement, Patch
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2018-03-02 09:39:18 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 583545    
Bug Blocks: 1250207    
Attachments:
Description Flags
Additional runtime detecting in ibus.conf for Kimpanel
none
Additional runtime detecting in ibus.conf for Kimpanel
none
Additional runtime detecting in ibus.conf for Kimpanel
none
Enable building Kimpanel and make a subpackage for it
none
Additional runtime detecting in ibus.conf for Kimpanel
none
Additional runtime detecting in ibus.conf for Kimpanel
none
Additional runtime detecting in ibus.conf for Kimpanel
none
Additional runtime detecting in ibus.conf for Kimpanel none

Description Robin Lee 2010-04-19 14:24:18 UTC
Created attachment 407608 [details]
Additional runtime detecting in ibus.conf for Kimpanel

Have Kimpanel be the default IBus frontend IF AND ONLY IF the user is running
KDE and Kimpanel is installed.

The attachment is a patch for this purpose.

Comment 1 Robin Lee 2010-04-19 17:17:34 UTC
Created attachment 407641 [details]
Additional runtime detecting in ibus.conf for Kimpanel

Test for any kind of KDE session including something like 'openbox-kde'.

Comment 2 fujiwara 2010-04-20 03:09:58 UTC
I also guess a enable/disable shell environment value might be useful while I'm not sure if all people always want to use Kimpanel when it's installed.

Comment 3 Robin Lee 2010-04-20 04:18:01 UTC
Created attachment 407720 [details]
Additional runtime detecting in ibus.conf for Kimpanel

Test for any kind of KDE session including something like 'openbox-kde'.

Comment 4 Robin Lee 2010-04-20 04:31:01 UTC
I propose to make things out of box. And people who use KDE and do not want to use Kimpanel, then can just remove the Kimpanel package.

More discussion in KDE SIG may be necessary, and as my personal experience, the IBus backend of Kimpanel is not yet stable enough. So this bug may be considered as FutureFeature by now.

(In reply to comment #2)
> I also guess a enable/disable shell environment value might be useful while I'm
> not sure if all people always want to use Kimpanel when it's installed.

Comment 5 Robin Lee 2010-04-20 04:38:52 UTC
Created attachment 407724 [details]
Enable building Kimpanel and make a subpackage for it

Test for any kind of KDE session including something like 'openbox-kde'.

Comment 6 Robin Lee 2010-04-20 04:41:52 UTC
Created attachment 407725 [details]
Additional runtime detecting in ibus.conf for Kimpanel

Test for any kind of KDE session including something like 'openbox-kde'.

Comment 7 fujiwara 2010-04-20 05:01:58 UTC
legacy grep doesn't have -q.

Comment 8 Robin Lee 2010-04-20 05:15:27 UTC
Created attachment 407728 [details]
Additional runtime detecting in ibus.conf for Kimpanel

Redirect output to /dev/null instead

Comment 9 fujiwara 2010-04-20 08:05:11 UTC
Looks good with me :).

Comment 10 Peng Huang 2010-04-20 08:12:07 UTC
which package kimpanel is included in?

Comment 11 Peng Huang 2010-04-20 08:36:36 UTC
BTW, I am also thinking if it is better that kimpanel installs another ibus-kde.conf. And the user could make choice with imchooser.

Comment 12 Robin Lee 2010-04-20 08:40:11 UTC
Refer to: https://bugzilla.redhat.com/show_bug.cgi?id=583545
This bug depends on that one.
Kimpanel is not yet included in any package by now.
(In reply to comment #10)
> which package kimpanel is included in?

Comment 13 Robin Lee 2010-04-20 08:42:56 UTC
I tried this in the second proposal in https://bugzilla.redhat.com/show_bug.cgi?id=583545  .
(In reply to comment #11)
> BTW, I am also thinking if it is better that kimpanel installs another
> ibus-kde.conf. And the user could make choice with imchooser.

Comment 14 Chen Lei 2010-04-20 09:31:06 UTC
test -f /usr/share/ibus/ui/panel.py -a "x$DESKTOP_SESSION" = "xkde"

is enough.

Comment 15 Chen Lei 2010-04-20 09:37:27 UTC
s/ui/ui\/kimpanel/.
panel.py is not a exec lib and also a generic name and should be installed into %{_datadir}

Comment 16 Robin Lee 2010-04-20 10:37:01 UTC
Because there are some kde variations like openbox-kde, so we should test sub-string and not identity.
(In reply to comment #14)
> test -f /usr/share/ibus/ui/panel.py -a "x$DESKTOP_SESSION" = "xkde"
> 
> is enough.

Comment 17 Kevin Kofler 2010-04-20 14:17:25 UTC
Indeed, panel.py should be in something like /usr/share/ibus-kimpanel/, not in /usr/libexec.

Comment 18 Robin Lee 2010-04-21 14:38:22 UTC
Created attachment 408091 [details]
Additional runtime detecting in ibus.conf for Kimpanel

Patch updated.

Comment 19 fujiwara 2010-04-22 01:34:53 UTC
The following would be another idea to get third party IBus panels.

IBUS_SUBFILES=`(ls /etc/X11/xinit/xinput.d/ibus-*.conf 2>/dev/null; echo ok > /dev/null;)`
for FILE in $IBUS_SUBFILES ; do
  . $FILE
done

XIM_ARGS=${XIM_ARGS:-"--xim -j 60"}

Comment 20 Robin Lee 2010-04-22 15:09:12 UTC
Created attachment 408353 [details]
Additional runtime detecting in ibus.conf for Kimpanel

panel.py moved

Comment 21 Robin Lee 2010-04-22 15:17:57 UTC
(In reply to comment #19)
> IBUS_SUBFILES=`(ls /etc/X11/xinit/xinput.d/ibus-*.conf 2>/dev/null; echo ok >

I think 'ibus-*.conf' may not be a good pattern for third-party additional setting files, because this pattern has special meaning for imsettings.

Comment 22 fujiwara 2010-04-23 01:00:25 UTC
(In reply to comment #21)
> I think 'ibus-*.conf' may not be a good pattern for third-party additional
> setting files, because this pattern has special meaning for imsettings.    

I don't understand what is the special meaning.
There are many updates so it looks wrong to update ibus.conf directly to describe a specific UI(kimpanel) in upstream because it means you may ask to update it in the future again.
The previous idea means to have a fix to support general ibus arguments.
The /etc/X11/xinit/xinput.d could be for XIM but not a specific IM setting so the idea is the main conf specifies the XIM name and I also think it might be a similar way with xim.conf. The directory of the sub conf is an idea but also /usr/share/ibus might be another option.

or I also think just simply will not fix. It would be no big problem to add an additional main conf for kimpanel. Users also can add $HOME/.xinputrc instead.

Comment 23 Robin Lee 2010-04-23 03:01:32 UTC
(Quoted from /usr/share/doc/imsettings-0.108.0/README)
> Information files for Input Method
> ======================================
> To make Input Methods available from IMSettings, every Input
> Methods that hopes so has to have the information file to
> let IMSettings know. those files is usually put under a
> directory where you can change the default value with
> --with-xinputdir. the filename has to contain .conf or
> something that you can also change the default value with
> --with-xinput-suffix to avoid listing every Input Methods
> that might not work for some languages. Input Methods
> doesn't support multiple languages such as XIM doesn't have
> to have .conf suffix or so. xim.conf can deals with such
> configuration files properly for appropriate languages
> according to current locale.

Of cause using third party additional setting file is also a solution. All I hope is to make Kimpanel useful out of box.

Comment 24 Kevin Kofler 2010-04-23 15:44:35 UTC
The idea of the pluggable ibus-*.conf scriptlets for things like kimpanel to plug into is interesting. I'd suggest putting them somewhere other than /etc/X11/xinit/xinput.d/ so they don't interfere with toplevel Xinput scriptlets though. Maybe /usr/share/ibus/ibus.conf.d/*.conf?

What's sure is that we need some solution, whether it's pluggable scriptlets or the patch to ibus.conf itself, for kimpanel to work as expected.

Comment 25 Kevin Kofler 2010-04-23 15:54:04 UTC
Or maybe /etc/ibus.conf.d/*.conf might be a better location? It depends on whether we want our users to be able to tweak those files or not.

Comment 26 fujiwara 2010-05-14 03:16:45 UTC
BTW, I think the bugfix timeline will be set up after bug 583545 is fixed.

Comment 27 Fedora Admin XMLRPC Client 2010-08-02 06:17:32 UTC
This package has changed ownership in the Fedora Package Database.  Reassigning to the new owner of this component.

Comment 28 fujiwara 2011-09-29 01:28:32 UTC
It seems bug 583545 is not fixed yet.
I'd want the kimpanel sub package at first.

Comment 29 fujiwara 2018-03-02 09:39:18 UTC
kimpanel is launched by plasma-desktop now in f27.