Bug 4363 - enabled-im-list
Summary: enabled-im-list
Status: RESOLVED FIXED
Alias: None
Product: UIM
Classification: Unclassified
Component: generic Scheme codes (show other bugs)
Version: unspecified
Hardware: All All
: high normal
Assignee: uim-bugs
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-09-06 00:08 UTC by Etsushi Kato
Modified: 2005-09-08 04:53 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Etsushi Kato 2005-09-06 00:08:57 UTC
Currently (from uim-0.4.8), uim-module-manager can manipulate enabled-im-list in
the [system data dir]/uim/installed-modules.scm.

This cause a problem on uim-pref's behavior if unregistering some modules listed
in the enabled-im-list of ~/.uim.d/customs/custom-global.scm.

For example, if 'anthy' is not listed on system's installed-modules.scm but
listed on ~/.uim.d/customs/custom-global.scm, uim-pref shows only 'direct' in
the 'Enabled input methods' in Global settings because custom-valid? fails, and
user cannot edit the list unless saving the setting to the file.

So I propose adding new variable `system-enabled-im-list to the
installed-modules.scm.  Also replace `direct with 'usable-im-list' for default
value when custom-valid? on enabled-im-list fails.

I mean, 

(define system-enabled-im-list enabled-im-list)

  in installed-modules.scm, and

(define usable-im-list
  (lambda ()
    (let ((imlist (filter (lambda (name)
                    (memq name system-enabled-im-list)) enabled-im-list)))
         (if (not (null? imlist))
             imlist
             '(direct)))))

(define-custom 'enabled-im-list (usable-im-list)
    ...
    ...)

  in im-custom.scm.

What do you think?

Cheers,
-- 
Etsushi Kato
ekato@ees.hokudai.ac.jp
Comment 1 Etsushi Kato 2005-09-07 09:06:11 UTC
I've committed the changes in r1452.

Additionally, I've disabled using $prefix/share/uim/modules file in r1451, since
it seems using the file is totally redundant for me.  I think
installed-im-module-list in $prefix/share/uim/installed-modules.scm is sufficient.

Any comments?

Cheers,
Comment 2 Etsushi Kato 2005-09-07 22:03:36 UTC
If there is no objection, I'll port these changes into 0.4 branch tomorrow.

Cheers,
-- 
Etsushi Kato
ekato@ees.hokudai.ac.jp
Comment 3 Etsushi Kato 2005-09-08 21:53:12 UTC
Fixed in r1457.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.