「IBus」の版間の差分

提供: ArchWiki
ナビゲーションに移動 検索に移動
imported>Blowback
(他言語へのリンクを修正)
 
(4人の利用者による、間の33版が非表示)
1行目: 1行目:
[[Category:Internationalization (日本語)]]
+
[[Category:インプットメソッド]]
 
[[en:IBus]]
 
[[en:IBus]]
[[zh-CN:IBus]]
+
[[zh-hans:IBus]]
  +
{{Related articles start}}
[[zh-TW:IBus]]
 
  +
{{Related|Fcitx}}
{{Article summary start|概要}}
 
  +
{{Related|Fcitx5}}
{{Article summary text|この記事では、IBus の使用について、インストール・設定・トラブルシューティングの手順を説明します。}}
 
  +
{{Related|インプットメソッド}}
{{Article summary heading|関連項目}}
 
  +
{{Related|SCIM}}
{{Article summary wiki|Fcitx}}
 
  +
{{Related|UIM}}
{{Article summary wiki|SCIM}}
 
{{Article summary wiki|UIM}}
+
{{Related articles end}}
{{Article summary end}}
 
 
'''IBus''' ("Intelligent Input Bus") は様々な言語の文字を入力するためのシステムである、[[Wikipedia:ja:インプットメソッド|インプットメソッドフレームワーク]]のひとつです。IBus は [[Fcitx]], [[SCIM]], [[UIM]] と同等の機能を持っています。
 
'''IBus''' ("Intelligent Input Bus") は様々な言語の文字を入力するためのシステムである、[[Wikipedia:ja:インプットメソッド|インプットメソッドフレームワーク]]のひとつです。IBus は [[Fcitx]], [[SCIM]], [[UIM]] と同等の機能を持っています。
   
 
==インストール==
 
==インストール==
[[Official Repositories (日本語)|公式リポジトリ]]から {{pkg|ibus}} パッケージをインストールしてください。
 
   
さらに、Qt アプリケーションで IBus を有効にするために、{{pkg|ibus-qt}} ライブラリをインストールしましょう
+
{{pkg|ibus}} パッケージをインストールしてください
   
  +
さらに、Qt アプリケーションで IBus を有効にするために、{{AUR|ibus-qt}} ライブラリをインストールしましょう。
===インプットメソッドエンジン===
 
あなたが入力したい言語にあわせて、最低ひとつのインプットメソッドが必要です。利用できるインプットメソッドは以下の通り:
 
   
  +
== 統合 ==
* ibus-anthy: {{Pkg|anthy}} ベースの日本語 IME。
 
* [[mozc (日本語)|ibus-mozc]]: Google によって開発されている日本語 IME。
 
* {{Pkg|ibus-kkc}}: {{Pkg|libkkc}} ベースの日本語 IME。
 
* ibus-pinyin: 拼音と注音(字母)ユーザーのためのインテリジェント中国語フォネティック IME。IBus のメイン開発者によって設計されており英語のスペルチェックなど高度な機能を持っています。
 
* {{Pkg|ibus-rime}}: パワフル・スマートな中国人のための中国語インプットメソッド (pinyin, zhuyin, double pinyin, Jyutping, Wugniu, Cangjie5, Wubi 86)。
 
* ibus-chewing: {{Pkg|libchewing}} ベースの注音(字母)ユーザーのためのインテリジェント中国語フォネティック IME。
 
* ibus-hangul: {{Pkg|libhangul}} ベースの韓国語 IME。
 
* ibus-unikey: ベトナム文字を入力するための IME。
 
* ibus-table: テーブルベースの IM を使うための IME。
 
* ibus-m17n: m17n-db のインプットメソッドを使って多くの言語を入力できる m17n IME。
 
* ibus-keymagic: レイアウトスクリプト (kms) によって生成されたキーボードレイアウト (km2) を使って全ての言語で動作するように設計された複雑でスマートなインプットメソッド。
 
   
  +
少なくとも以下の [[環境変数]] を設定してください。
全ての利用可能なインプットメソッドを見るには:
 
$ pacman -Ss ^ibus-*
 
   
  +
{{hc|/etc/environment|2=
[[Arch User Repository (日本語)|AUR]] から利用できるパッケージもあります。
 
  +
GTK_IM_MODULE=ibus
  +
QT_IM_MODULE=ibus
  +
XMODIFIERS=@im=ibus
  +
}}
   
  +
{{Note|[[GNOME]] はバージョン 3.6 から IBus を [https://help.gnome.org/misc/release-notes/3.6/i18n-ibus.html 統合] しており、デフォルトで利用しているので、[[デスクトップ環境]] として利用している場合は次の部分を読み飛ばしても構いません。}}
===最初のセットアップ===
 
まず、(IBus を使うユーザーで) ibus-setup を実行:
 
$ ibus-setup
 
デーモンが起動し以下のメッセージが表示されます:
 
IBus has been started! If you cannot use IBus, please add below lines in $HOME/.bashrc, and relogin your desktop.
 
export GTK_IM_MODULE=ibus
 
export XMODIFIERS=@im=ibus
 
export QT_IM_MODULE=ibus
 
{{Note|IBus はデーモンを使っていますが、これは systemctl によって管理されるようなデーモンではありません: 通常ユーザーとしてログインしたときに実行される類のものです。}}
 
{{Note|もし、ibus がログインしたときに''自動では起動しない''場合、“export …” の部分を .bashrc から $HOME/.[[xprofile (日本語)|xprofile]] (もしくは .[[xinitrc (日本語)|xinitrc]]) に移動し、同じファイルに次の行を加えて下さい: “ibus-daemon -drx”、そしてデスクトップに再ログインしてください。}}
 
それから設定画面が表示されるはずです; IBus が起動している間はシステムトレイのアイコンからいつでもこの設定画面を開くことができます(右クリック→設定)。[[#設定]] を見て下さい。
 
   
  +
ユーザーログイン時に IBus を起動するには、以下のコマンドで [[自動起動]] エントリを作成します。
IBus が Qt/KDE アプリケーションで動作しない場合、ibus-qt ライブラリがインストールされているか確認して Qt の設定エディタから IBus をデフォルトの IME に設定してください:
 
$ qtconfig
 
"インターフェース" -> "デフォルトのインプットメソッド" から、{{ic|xim}} のかわりに {{ic|ibus}} を選択です。
 
   
  +
ibus-daemon -drxR
==設定==
 
=== Ibus ===
 
{{Note|中国語、日本語、韓国語、ベトナム語の文字を入力するには[[Fonts (日本語)#漢字、日本語、ハングル、ベトナム語|東アジアのフォント]]をインストールする必要があります。}}
 
"一般" の設定はデフォルトのままでかまいませんが、"インプットメソッド"タブではドロップダウンボックスからあなたのインプットメソッドを選び、"追加"を押してください。必要なら複数のインプットメソッドを使うこともできます。
 
一度 IBus をセットアップすれば、Ctrl+Space を押すことでインプットメソッドを使うことができます(押すたびにインプットメソッドが変わります)。IBus はどのインプットメソッドが使われているかをそれぞれのウィンドウ毎に記憶するので、ウィンドウ毎にインプットメソッドを有効にする必要があります。
 
   
  +
次のログイン時に、IBus はユーザーセッションと一緒に起動します。
=== Ibus-rime ===
 
==== インストール ====
 
If you have decided to use the great ibus-rime IME, here are some help to install it and to configure it.
 
   
  +
{{Tip|
First, you should install it from [community] : {{Pkg|ibus-rime}}.
 
  +
* {{AUR|ibus-autostart}} パッケージはこれを [[自動起動]] するエントリを提供します。
  +
* {{AUR|ibus-daemon}} パッケージは {{ic|ibus@$DISPLAY.service}} を提供し、これを [[有効化]] することで実現できます。
  +
* [[KDE]] には Input Method Panel という plasmoid があり、IBus のフロントエンドとして動作し、より良い統合体験を提供できる可能性があります。
  +
** Input Method Panel で IBus を起動するには、上記の ''ibus-daemon'' コマンドで {{ic|1=--panel=/usr/lib/kimpanel-ibus-panel}} オプションを使用します。入力メソッドパネル ウィジェットを設定するには、[https://userbase.kde.org/Tutorials/Kimpanel KDE UserBase Wiki] と [[KDE#ウィジェット]] を参照してください。
  +
** {{AUR|ibus-autostart-kimpanel}} パッケージは、[[自動起動]] するエントリを提供します。
  +
* [[KDE]] での追加機能は {{Pkg|kimtoy}} で提供されるかもしれません。しかし、このプロジェクトは [https://invent.kde.org/unmaintained/kimtoy アーカイブ] されており、期待通りに動作しないかもしれません。
  +
}}
   
  +
== 設定方法 ==
In order to work, Rime is based on schemas that should be edited by the user. However, it comes installed with a default pinyin input schema so you can use it as it.
 
   
  +
システムに非ラテン語の言語をサポートするためのヘルプは [[ロケール]] を参照してください。
==== 設定 ====
 
   
  +
利用可能な非ラテン語フォントの非網羅的なリストについては [[フォント#ラテン文字]] を参照してください。
If you want it for another input method, here they are:
 
* Luna Pinyin (Standard Mandarin)
 
* Terra Pinyin (with tones)
 
* Bopomofo (Mandarin Phonetic Symbol)
 
* Double Pinyin (Ziranma, MSPY)
 
* Jyutping (Cantonese)
 
* Wugniu (Wuu)
 
* Cangjie5
 
* Wubi86
 
   
  +
=== GNOME ===
For example, if you want to be able to type pinyin with tones, you want to use the Terra Pinyin input method.
 
To do so, you have to first create a directory:
 
$ mkdir ~/.config/ibus/rime
 
   
  +
[[GNOME]] はデフォルトで IBus を使用しているので、''設定 > キーボード > 入力ソース'' で好きな言語のキーボードレイアウトを追加することができます。
In this directory, create a file entitled {{Ic|default.custom.yaml}} and add the following lines to it:
 
{{hc|default.custom.yaml|
 
patch:
 
schema_list:
 
- schema: terra_pinyin
 
}}
 
Note that the indentation level is important. Your file says to Rime to replace the schema list with a list that only contains Terra Pinyin.
 
   
  +
=== その他のデスクトップ環境 ===
Eventually, if the changes aren't taken automatically, run:
 
rm ~/.config/ibus/rime/default.yaml && ibus-daemon -drx
 
   
  +
IBus の環境設定ウィンドウを起動するには、以下の方法があります。
Note: Tones are optionals but you can type them to filter the list very well. Here are how to type them:
 
1st tone: -
 
2nd tone: /
 
3rd tone: <
 
4th tone: \
 
   
  +
* IBus のトレイアイコンを右クリックし、''Preferences''を選択します。
Example: if one wants to type {{Ic|hǎo}} to display only Chinese characters that are pronounced this way, one must type {{Ic|hao<}} and it will be automatically converted to hǎo.
 
  +
* GUI アプリケーションの IBus Preferences を見つけて起動するか、または
  +
* ターミナルでコマンド {{ic|ibus-setup}} を実行する。
   
  +
ここで注目すべき点は、''次のインプットメソッド'' (デスクトップ環境が提供するデフォルトのショートカットの代わりに使用したいもの) のキーボードショートカットと、異なるキーボードレイアウトを追加または削除できる ''インプットメソッド'' タブ (デスクトップ環境のデフォルトレイアウトマネージャの代わりに実行したいもの) です。
==== 使用方法 ====
 
Rime provides some great features that allow you to write good Chinese and all its punctuation.
 
   
  +
== ヒントとテクニック ==
===== 基本的な設定 =====
 
At any time, while running Rime, you can access some basic options with {{Ic|F4}}. The displayed options look like this:
 
1. Method name
 
2. 中文 -› 西文
 
3. 全角 -› 半角
 
4. 漢字 -› 汉字
 
etc.
 
   
  +
=== 絵文字入力 ===
The first one indicate the name of the method you can select (Ex: 地球拼音 for Terra Pinyin). If you want many methods, you'll have them in this menu.
 
   
  +
IBus は絵文字アイコンの入力をサポートしています。{{ic|Ctrl+.}} または {{ic|Ctrl+;}} と入力すると、入力プロンプトが下線付きの <u>'''e'''</u> 文字に変わります。次に、必要な絵文字の記号または名前 (例''' :)''' または '''face''') を入力し、{{ic|Space}} を押してレンダリングします。結果に満足したら、{{ic|Enter}} を押して送信し、絵文字入力モードを終了するか、もう一度 {{ic|Space}} を押してダイアログを開き、目的の絵文字をさらにカスタマイズできます。
The second one lets you select which language you want to type in.
 
   
  +
詳細については、{{man|7|ibus-emoji}} を参照してください。
The third one lets you select if you want to type the punctuation in full width (全角) or in half width (半角).
 
   
  +
=== Unicode 入力 ===
The last one allows you to type in traditional Chinese (漢字) or in simplified Chinese (汉字).
 
   
  +
IBus は複雑な Unicode 文字の入力をサポートしています。 {{ic|Ctrl+Shift+u}} と入力すると、入力プロンプトが下線付きの <u>'''u'''</u> 文字に変わります。次に、必要な Unicode 文字のコードを入力し、{{ic|Space}} または {{ic|Enter}} を押して、レンダリングして送信します。
===== Chinese punctuation =====
 
You can access to all the Chinese punctuation thanks to Rime. Here is a little table showing you how to type some of them:
 
[ -> 「 【 〔 [
 
] -> 」 】 〕 ]
 
{ -> 『 〖 {
 
} -> 』 〗 }
 
< -> 《 〈 « ‹
 
> -> 》 〉 » ›
 
@ -> @ @ ☯
 
/ -> / / ÷
 
* -> * * ・ × ※
 
% -> % % ° ℃
 
$ -> ¥ $ € £ ¥
 
| -> ・ | | § ¦
 
_ -> ——
 
\ -> 、 \ \
 
^ -> ……
 
~ -> 〜 ~ ~ 〰
 
   
===== 高度な設定 =====
+
=== トレイアイコンの色 ===
Rime allows you to change everything you can imagine and more examples are provided on the website of the project: (in Chinese) https://code.google.com/p/rimeime/wiki/CustomizationGuide
 
   
  +
デフォルトでは、IBus は濃い青色を使用して、現在アクティブなレイアウトの言語記号を表示します(例:'''EN''')色の値は [[GNOME#設定|gsettings schema]] に保存されているため、変更する場合は次のコマンドを実行できます。
==Tips and tricks==
 
===Pinyin usage===
 
When using ibus-pinyin,
 
* First type the pinyin (sans tones) for the characters you wish to enter.
 
* Press Up and Down repeatedly to select a character (going on to the next page if necessary).
 
* Press Space to use a character.
 
* You can also use PageUp or PageDown to scroll pages, and use the number keys 1-5 to select the character you need.
 
* You can enter multiple characters that form a word or phrase at a time (such as "zhongwen" to enter "中文"). ibus-pinyin will remember which characters you type most frequently and over time make suggestions that are more tuned to your typing profile.
 
   
  +
$ gsettings set org.freedesktop.ibus.panel xkb-icon-rgba 'COLOR'
==トラブルシューティング==
 
   
  +
文字列 ''COLOR'' は​​、次のガイドラインに準拠している必要があります。
===Kimpanel===
 
IBus main interface is currently only available in GTK, but {{Pkg|Kimpanel}} provides a native Qt/KDE input interface. The package '''kdeplasma-addons-applets-kimpanel''' is compiled to support ibus, but ibus needs to be launched as following to be able to communicate with the panel:
 
   
  +
The RGBA value can be 1. a color name from X11, 2. a hex value in form '#rrggbb' where 'r', 'g' and 'b' are hex digits of the red, green, and blue, 3. a RGB color in form 'rgb(r,g,b)' or 4. a RGBA color in form 'rgba(r,g,b,a)' where 'r', 'g', and 'b' are either integers in the range 0 to 255 or percentage values in the range 0% to 100%, and 'a' is a floating point value in the range 0 to 1 of the alpha.
$ ibus-daemon --xim --panel=/usr/lib/kde4/libexec/kimpanel-ibus-panel
 
   
  +
{{Tip|{{Pkg|dconf-editor}} を使用して、よりユーザーフレンドリーな方法で gsettings テーマを編集することもできます。}}
To get a menu entry for launching ibus this way, save the following file to ~/.local/share/applications/ibus-kimpanel.desktop
 
[Desktop Entry]
 
Encoding=UTF-8
 
Name=IBus (KIMPanel)
 
Name[ar]=IBus (KIMPanel)
 
Name[as]=IBus (KIMPanel)
 
Name[bn_IN]=IBus (KIMPanel)
 
Name[ca]=IBus (KIMPanel)
 
Name[da]=IBus (KIMPanel)
 
Name[de]=IBus (KIMPanel)
 
Name[en_GB]=IBus (KIMPanel)
 
Name[es]=IBus (KIMPanel)
 
Name[fr]=IBus (KIMPanel)
 
Name[gu]=IBus (KIMPanel)
 
Name[hi]=IBus (KIMPanel)
 
Name[hu]=IBus (KIMPanel)
 
Name[it]=IBus (KIMPanel)
 
Name[ja]=IBus (KIMPanel)
 
Name[kn]=IBus (KIMPanel)
 
Name[ko]=IBus (KIMPanel)
 
Name[ml]=IBus (KIMPanel)
 
Name[mr]=IBus (KIMPanel)
 
Name[nl]=IBus (KIMPanel)
 
Name[or]=IBus (KIMPanel)
 
Name[pa]=IBus (KIMPanel)
 
Name[pl]=iBus (KIMPanel)
 
Name[pt_BR]=IBus (KIMPanel)
 
Name[ru]=IBus (KIMPanel)
 
Name[sr]=IBus (KIMPanel)
 
Name[sr@latin]=IBus (KIMPanel)
 
Name[ta]=IBus (KIMPanel)
 
Name[te]=IBus (KIMPanel)
 
Name[uk]=IBus (KIMPanel)
 
Name[vi]=IBus (KIMPanel)
 
Name[zh_CN]=IBus (KIMPanel)
 
Name[zh_HK]=IBus (KIMPanel)
 
Name[zh_TW]=IBus (KIMPanel)
 
GenericName=Input Method Framework
 
GenericName[as]=ইনপুট পদ্ধতি গাথনি
 
GenericName[bn_IN]=ইনপুট পদ্ধতির পরিকাঠামো
 
GenericName[da]=Framework for inputmetode
 
GenericName[de]=Eingabemethode-Framework
 
GenericName[en_GB]=Input Method Framework
 
GenericName[es]=Marco de trabajo para métodos de entrada
 
GenericName[fr]=Framework de méthode de saisie
 
GenericName[gu]=ઇનપુટ પદ્દતિ ફ્રેમવર્ક
 
GenericName[hi]=IBus विधि फ्रेमवर्क
 
GenericName[it]=Framework del metodo di input
 
GenericName[ja]=インプットメソッドフレームワーク
 
GenericName[kn]=IBus ವಿಧಾನದ ಫ್ರೇಮ್‌ವರ್ಕ್
 
GenericName[ko]=입력 방식 프레임워크
 
GenericName[ml]=ഇന്‍പുട്ട് മെഥേഡ് ആകൃതി
 
GenericName[mr]=इन्पुट पद्धत फ्रेमवर्क
 
GenericName[nl]=Invoer methode kader
 
GenericName[or]=ନିବେଶ ପ୍ରଣାଳୀ ଫ୍ରେମୱର୍କ
 
GenericName[pa]=ਇੰਪੁੱਟ ਢੰਗ ਫਰੇਮਵਰਕ
 
GenericName[pl]=Struktura metody wprowadzania
 
GenericName[pt_BR]=Framework do método de entrada
 
GenericName[ru]=Система методов ввода
 
GenericName[ta]=உள்ளீடு முறை ஃபிரேம்வொர்க்
 
GenericName[te]=ఇన్‌పుట్ పద్ధతి ఫ్రేమ్‌వర్క్
 
GenericName[uk]=Оболонка способів введення
 
GenericName[zh_CN]=输入法框架
 
GenericName[zh_TW]=輸入法框架
 
Comment=Start IBus Input Method Framework
 
Comment[as]=IBus ইনপুট পদ্ধতি গাথনি আৰম্ভ কৰা
 
Comment[bn_IN]=IBus ইনপুট পদ্ধতির পরিকাঠামো আরম্ভ করা হবে
 
Comment[da]=Start IBus, framework for inputmetode
 
Comment[de]=IBus-Eingabemethode-Framework starten
 
Comment[en_GB]=Start IBus Input Method Framework
 
Comment[es]=Inicie el marco de trabajo para métodos de entrada IBus
 
Comment[fr]=Démarrer le framework de méthode de saisie IBus
 
Comment[gu]=IBus ઇનપુટ પદ્દતિ ફ્રેમવર્કને શરૂ કરો
 
Comment[hi]=IBus इनपुट विधि फ्रेमवर्क आरंभ करें
 
Comment[it]=Avvia il framework del metodo di input di IBus
 
Comment[ja]=IBus インプットメソッドフレームワークを起動
 
Comment[kn]=IBus ಇನ್‌ಪುಟ್ ವಿಧಾನದ ಫ್ರೇಮ್‌ವರ್ಕ್ ಅನ್ನು ಆರಂಭಿಸು
 
Comment[ko]=IBus 입력 방식 프레임워크 시작
 
Comment[ml]=IBus ഇന്‍പുട്ട് മെഥേഡ് ആകൃതി ആരംഭിയ്ക്കുക
 
Comment[mr]=IBus इन्पुट पद्धती फ्रेमवर्क सुरू करा
 
Comment[nl]=Start IBus invoer methode kader
 
Comment[or]=IBus ନିବେଶ ପ୍ରଣାଳୀ ଫ୍ରେମୱର୍କକୁ ଆରମ୍ଭ କରନ୍ତୁ
 
Comment[pa]=ਆਈਬਸ ਇੰਪੁੱਟ ਢੰਗ ਫਰੇਮਵਰਕ ਸ਼ੁਰੂ ਕਰੋ
 
Comment[pl]=Uruchomienie struktury metody wprowadzania iBus
 
Comment[pt_BR]=Iniciar Framework do método de entrada IBus
 
Comment[ru]=Запустить систему методов ввода IBus
 
Comment[ta]=IBus உள்ளீடு முறை ஃபிரேம்வொர்க்கை துவக்கு
 
Comment[te]=IBus ఇన్‌పుట్ పద్ధతి ఫ్రేమ్‌వర్కును ప్రారంభించుము
 
Comment[uk]=Запуск оболонки способів введення IBus
 
Comment[zh_CN]=启动IBus 输入法框架
 
Comment[zh_TW]=啟動 IBus 輸入法框架
 
Exec=ibus-daemon --xim --panel=/usr/lib/kde4/libexec/kimpanel-ibus-panel
 
Icon=ibus
 
Terminal=false
 
Type=Application
 
Categories=System;Utility;
 
X-GNOME-Autostart-Phase=Applications
 
X-GNOME-AutoRestart=false
 
X-GNOME-Autostart-Notify=true
 
X-KDE-autostart-after=panel
 
   
  +
{{Note|これは、[[GNOME]] と [[KDE]] のどちらにも KDE 入力方式パネルでは適用されません。どちらも IBus に独自のアイコンを提供するためです。}}
Then you can either let KDE autostart ibus, or set it as the input method application in Kimpanel, and manually click on the kimpanel icon to start it. In either case, choose Utility/Ibus (Kimpanel) in the Choose Application dialog.
 
   
  +
=== レイアウトスイッチャーの表示遅延 ===
===rxvt-unicode===
 
If anyone has any issues with iBus and rxvt-unicode, the following steps should solve it.
 
   
  +
'''次の入力方法''' ホットキーを押すと、IBus はレイアウトスイッチを示す小さなダイアログを表示します。デフォルトでは、このダイアログはキーを押してから400ミリ秒後に表示されますが、この値はユーザーが変更できます。興味深い選択肢として、ダイアログをすぐに表示するための ''0'' または負の値(''-1'' など)があります。ウィンドウをまったく表示せずにレイアウトを切り替える (2つのレイアウトのみを使用し、一方から他方に切り替える場合に便利な場合があります。)
Add the following to your .Xdefaults (possibly not required -- try first without):
 
URxvt.inputMethod: ibus
 
URxvt.preeditType: OverTheSpot
 
   
  +
値は [[GNOME#設定|gsettings schema]] に保存されるため、変更する場合は次のコマンドを実行できます。
And start ibus with:
 
ibus-daemon --xim
 
   
  +
$ gsettings set org.freedesktop.ibus.general switcher-delay-time 'VALUE'
If you start ibus-daemon automatically (e.g. in ~/.xinitrc or ~/.xsession) but used to use `ibus-daemon &' without the `--xim' option, make sure to kill the existing process before testing the new command.
 
   
  +
現在保存されている値を表示するには、次のコマンドを実行します。
===GTK アプリケーション===
 
GTK アプリケーションでインプットメソッドを使うと問題がおこることがあります。おそらくそれは gtk.immodules ファイルが見つけられないことが原因です。
 
問題を修正するには、$HOME/.bashrc に以下の行のどちらかを追加してください:
 
(gtk2) export GTK_IM_MODULE_FILE=/etc/gtk-2.0/gtk.immodules
 
(gtk3) export GTK_IM_MODULE_FILE=/usr/lib/gtk-3.0/3.0.0/immodules.cache
 
   
  +
$ gsettings get org.freedesktop.ibus.general switcher-delay-time
{{note|gtk2 に設定すると、gedit などの gtk3 アプリケーションが使えなくなります。gtk3 に設定すると xfce などの gtk2 アプリケーションが使えなくなります。}}
 
   
  +
文字列 'VALUE' は、次のガイドラインに準拠している必要があります。
===中国語の入力===
 
If you encounter problems when using chinese input, check your locale settting. For example in Hong Kong, export LANG=zh_HK.utf8.
 
   
  +
Set popup delay milliseconds to show IME switcher window. The default is 400. 0 = Show the window immediately. 0 < Delay milliseconds. 0 > Do not show the window and switch prev/next engines.
{{Note| There are large revisions after ibus1.4, you might not be able to input chinese words with ibus-pinyin or ibus-sunpinyin, which are written in C. So the solution is:
 
   
  +
{{Tip|{{Pkg|dconf-editor}} を使用して、よりユーザーフレンドリーな方法で gsettings テーマを編集することもできます。}}
* Install ibus-libpinyin.
 
}}
 
You can install {{Pkg|ibus-libpinyin}}.
 
   
  +
=== 修飾キーの組み合わせを使用してレイアウトを切り替える ===
To start ibus with gnome, add this in ~/.profile and restart the gnome.
 
   
  +
何らかの理由で、IBus 設定 GUI では、修飾キーの組み合わせのサブセット({{ic|Alt+Shift_R}} など)をレイアウト切り替えホットキーとして使用できません。ただし、IBus はホットキーを文字列として [[GNOME#設定|gsettings schema]] に保存するため、その文字列を直接編集することで、このような組み合わせを引き続き使用できます。
export GTK_IM_MODULE=ibus
 
  +
export XMODIFIERS=@im=ibus
 
  +
$ gsettings set org.freedesktop.ibus.general.hotkey triggers "['VALUE']"
export QT_IM_MODULE=ibus
 
  +
ibus-daemon -d -x
 
  +
文字列 {{ic|'VALUE'}} は、IBus が認識できる形式で記述された有効な修飾キーの組み合わせである必要があります。{{ic|AltShift_R}}
  +
  +
{{Tip|{{Pkg|dconf-editor}} を使用して、よりユーザーフレンドリーな方法で gsettings テーマを編集することもできます。}}
  +
  +
=== rxvt-unicode ===
  +
  +
''rxvt-unicode'' が IBus で正しく機能するためには、次の行を {{ic|~/.Xresources}} に追加する必要がある場合があります。
  +
  +
URxvt.inputMethod: ibus
  +
URxvt.preeditType: OverTheSpot
  +
  +
==トラブルシューティング==
  +
  +
=== pyenvが原因でパッケージが欠落している ===
  +
  +
python のバージョンと設定を管理するために {{ic|pyenv}} を使用している場合、 {{ic|ibus}} の依存関係が設定されたグローバルな python バージョンにインストールされないことがあります。これは、グローバルバージョンがシステムで管理されているもの (ibusが依存する依存関係、例えば {{ic|gi}} がインストールされるもの) ではない場合に起こり得ます。その結果、ibus のセットアップが起動しているが機能しない (システムトレイに ibus があるが、環境設定が開けない、など) ことがあります。この問題を確認する一つの方法は、{{ic|ibus-setup}}を実行してみて、依存関係の欠如のエラーが発生するかどうかを確認することです。
  +
  +
この問題を修正するには、pyenv グローバルバージョンをシステムバージョンに変更します。:
  +
  +
pyenv global system
  +
  +
=== 再起動後に設定が削除される ===
  +
  +
再起動後に設定が一貫して削除されている (入力メソッドが元に戻されている) 場合は、プリロードされるように設定されているエンジンと、それらがロードされる順序を確認します:
  +
  +
$ gsettings get org.freedesktop.ibus.general preload-engines
  +
['xkb:us::eng']
  +
$ gsettings get org.freedesktop.ibus.general engines-order
  +
['xkb:us::eng', 'anthy']
  +
  +
この場合に {{ic|anthy}} が確実に読み込まれるようにするには、{{ic|org.freedesktop.ibus.preload-engines}} リストに追加します。
  +
  +
$ gsettings set org.freedesktop.ibus.general preload-engines "['xkb:us::eng', 'anthy']"
  +
  +
変更はすぐに反映され、再起動後も保持されます。
  +
  +
=== Ibus IME のパッケージはキーボードのネイティブ文字セットのみを入力します ===
  +
  +
考えられる修正は、GTK_IM_MODULE [[環境変数]] を ibus ではなく xim に設定することです。
  +
  +
{{hc|/etc/environment|2=
  +
GTK_IM_MODULE=xim
  +
QT_IM_MODULE=ibus
  +
XMODIFIERS=@im=ibus
  +
}}
   
  +
=== キーを押し続けると "固着" する ===
Chinese users can refer to this [http://forum.ubuntu.org.cn/viewtopic.php?f=155&t=346639 page] for detailed solution concerning this bug.
 
   
  +
特定のゲーム、特に Proton 経由で実行されるゲームでは、キーを数秒間押し続けると、そのキーが再度押されて離されるまで "固着" (押されたものとして押され続ける) することがあります。限られたテスト [https://github.com/ValveSoftware/Proton/issues/5294#issuecomment-1455434318] では、IBus デーモンを kill するだけでこの問題が解決することがわかりました。
===LibreOffice===
 
IBus がロードされているのに LibreOffice にインプットウィンドウが出ない場合、以下を ~/.bashrc に追加してください:
 
export XMODIFIERS=@im=ibus
 
それから、ibus を "--xim -d" で起動する必要があります。例えば、以下を ~/.xinitrc に追加してください:
 
ibus-daemon --xim -d
 
ただしこの修正を適用するにはターミナルから LibreOffice を起動しなくてはなりません。
 
   
  +
== 参照 ==
KDE を使っていて上述の修正がきかない場合、"libreoffice-gnome" をインストールして以下の行を ~/.xprofile に追加してください。ただし LibreOffice が GTK2 モードで起動するようになります:
 
export OOO_FORCE_DESKTOP="gnome"
 
   
  +
* [https://github.com/ibus/ibus GitHub リポジトリ]
後者の修正では LibreOffice をターミナル以外からも起動できます。
 

2023年11月28日 (火) 04:08時点における最新版

関連記事

IBus ("Intelligent Input Bus") は様々な言語の文字を入力するためのシステムである、インプットメソッドフレームワークのひとつです。IBus は Fcitx, SCIM, UIM と同等の機能を持っています。

インストール

ibus パッケージをインストールしてください。

さらに、Qt アプリケーションで IBus を有効にするために、ibus-qtAUR ライブラリをインストールしましょう。

統合

少なくとも以下の 環境変数 を設定してください。

/etc/environment
GTK_IM_MODULE=ibus
QT_IM_MODULE=ibus
XMODIFIERS=@im=ibus
ノート: GNOME はバージョン 3.6 から IBus を 統合 しており、デフォルトで利用しているので、デスクトップ環境 として利用している場合は次の部分を読み飛ばしても構いません。

ユーザーログイン時に IBus を起動するには、以下のコマンドで 自動起動 エントリを作成します。

ibus-daemon -drxR

次のログイン時に、IBus はユーザーセッションと一緒に起動します。

ヒント:
  • ibus-autostartAUR パッケージはこれを 自動起動 するエントリを提供します。
  • ibus-daemonAUR パッケージは ibus@$DISPLAY.service を提供し、これを 有効化 することで実現できます。
  • KDE には Input Method Panel という plasmoid があり、IBus のフロントエンドとして動作し、より良い統合体験を提供できる可能性があります。
    • Input Method Panel で IBus を起動するには、上記の ibus-daemon コマンドで --panel=/usr/lib/kimpanel-ibus-panel オプションを使用します。入力メソッドパネル ウィジェットを設定するには、KDE UserBase WikiKDE#ウィジェット を参照してください。
    • ibus-autostart-kimpanelAUR パッケージは、自動起動 するエントリを提供します。
  • KDE での追加機能は kimtoy で提供されるかもしれません。しかし、このプロジェクトは アーカイブ されており、期待通りに動作しないかもしれません。

設定方法

システムに非ラテン語の言語をサポートするためのヘルプは ロケール を参照してください。

利用可能な非ラテン語フォントの非網羅的なリストについては フォント#ラテン文字 を参照してください。

GNOME

GNOME はデフォルトで IBus を使用しているので、設定 > キーボード > 入力ソース で好きな言語のキーボードレイアウトを追加することができます。

その他のデスクトップ環境

IBus の環境設定ウィンドウを起動するには、以下の方法があります。

  • IBus のトレイアイコンを右クリックし、Preferencesを選択します。
  • GUI アプリケーションの IBus Preferences を見つけて起動するか、または
  • ターミナルでコマンド ibus-setup を実行する。

ここで注目すべき点は、次のインプットメソッド (デスクトップ環境が提供するデフォルトのショートカットの代わりに使用したいもの) のキーボードショートカットと、異なるキーボードレイアウトを追加または削除できる インプットメソッド タブ (デスクトップ環境のデフォルトレイアウトマネージャの代わりに実行したいもの) です。

ヒントとテクニック

絵文字入力

IBus は絵文字アイコンの入力をサポートしています。Ctrl+. または Ctrl+; と入力すると、入力プロンプトが下線付きの e 文字に変わります。次に、必要な絵文字の記号または名前 (例 :) または face) を入力し、Space を押してレンダリングします。結果に満足したら、Enter を押して送信し、絵文字入力モードを終了するか、もう一度 Space を押してダイアログを開き、目的の絵文字をさらにカスタマイズできます。

詳細については、ibus-emoji(7) を参照してください。

Unicode 入力

IBus は複雑な Unicode 文字の入力をサポートしています。 Ctrl+Shift+u と入力すると、入力プロンプトが下線付きの u 文字に変わります。次に、必要な Unicode 文字のコードを入力し、Space または Enter を押して、レンダリングして送信します。

トレイアイコンの色

デフォルトでは、IBus は濃い青色を使用して、現在アクティブなレイアウトの言語記号を表示します(例:EN)色の値は gsettings schema に保存されているため、変更する場合は次のコマンドを実行できます。

$ gsettings set org.freedesktop.ibus.panel xkb-icon-rgba 'COLOR'

文字列 COLOR は​​、次のガイドラインに準拠している必要があります。

The RGBA value can be 1. a color name from X11, 2. a hex value in form '#rrggbb' where 'r', 'g' and 'b' are hex digits of the red, green, and blue, 3. a RGB color in form 'rgb(r,g,b)' or 4. a RGBA color in form 'rgba(r,g,b,a)' where 'r', 'g', and 'b' are either integers in the range 0 to 255 or percentage values in the range 0% to 100%, and 'a' is a floating point value in the range 0 to 1 of the alpha.
ヒント: dconf-editor を使用して、よりユーザーフレンドリーな方法で gsettings テーマを編集することもできます。
ノート: これは、GNOMEKDE のどちらにも KDE 入力方式パネルでは適用されません。どちらも IBus に独自のアイコンを提供するためです。

レイアウトスイッチャーの表示遅延

次の入力方法 ホットキーを押すと、IBus はレイアウトスイッチを示す小さなダイアログを表示します。デフォルトでは、このダイアログはキーを押してから400ミリ秒後に表示されますが、この値はユーザーが変更できます。興味深い選択肢として、ダイアログをすぐに表示するための 0 または負の値(-1 など)があります。ウィンドウをまったく表示せずにレイアウトを切り替える (2つのレイアウトのみを使用し、一方から他方に切り替える場合に便利な場合があります。)

値は gsettings schema に保存されるため、変更する場合は次のコマンドを実行できます。

$ gsettings set org.freedesktop.ibus.general switcher-delay-time 'VALUE'

現在保存されている値を表示するには、次のコマンドを実行します。

$ gsettings get org.freedesktop.ibus.general switcher-delay-time

文字列 'VALUE' は、次のガイドラインに準拠している必要があります。

Set popup delay milliseconds to show IME switcher window. The default is 400. 0 = Show the window immediately. 0 < Delay milliseconds. 0 > Do not show the window and switch prev/next engines.
ヒント: dconf-editor を使用して、よりユーザーフレンドリーな方法で gsettings テーマを編集することもできます。

修飾キーの組み合わせを使用してレイアウトを切り替える

何らかの理由で、IBus 設定 GUI では、修飾キーの組み合わせのサブセット(Alt+Shift_R など)をレイアウト切り替えホットキーとして使用できません。ただし、IBus はホットキーを文字列として gsettings schema に保存するため、その文字列を直接編集することで、このような組み合わせを引き続き使用できます。

$ gsettings set org.freedesktop.ibus.general.hotkey triggers "['VALUE']"

文字列 'VALUE' は、IBus が認識できる形式で記述された有効な修飾キーの組み合わせである必要があります。AltShift_R

ヒント: dconf-editor を使用して、よりユーザーフレンドリーな方法で gsettings テーマを編集することもできます。

rxvt-unicode

rxvt-unicode が IBus で正しく機能するためには、次の行を ~/.Xresources に追加する必要がある場合があります。

URxvt.inputMethod: ibus
URxvt.preeditType: OverTheSpot

トラブルシューティング

pyenvが原因でパッケージが欠落している

python のバージョンと設定を管理するために pyenv を使用している場合、 ibus の依存関係が設定されたグローバルな python バージョンにインストールされないことがあります。これは、グローバルバージョンがシステムで管理されているもの (ibusが依存する依存関係、例えば gi がインストールされるもの) ではない場合に起こり得ます。その結果、ibus のセットアップが起動しているが機能しない (システムトレイに ibus があるが、環境設定が開けない、など) ことがあります。この問題を確認する一つの方法は、ibus-setupを実行してみて、依存関係の欠如のエラーが発生するかどうかを確認することです。

この問題を修正するには、pyenv グローバルバージョンをシステムバージョンに変更します。:

pyenv global system

再起動後に設定が削除される

再起動後に設定が一貫して削除されている (入力メソッドが元に戻されている) 場合は、プリロードされるように設定されているエンジンと、それらがロードされる順序を確認します:

$ gsettings get org.freedesktop.ibus.general preload-engines
['xkb:us::eng']
$ gsettings get org.freedesktop.ibus.general engines-order
['xkb:us::eng', 'anthy']

この場合に anthy が確実に読み込まれるようにするには、org.freedesktop.ibus.preload-engines リストに追加します。

$ gsettings set org.freedesktop.ibus.general preload-engines "['xkb:us::eng', 'anthy']"

変更はすぐに反映され、再起動後も保持されます。

Ibus IME のパッケージはキーボードのネイティブ文字セットのみを入力します

考えられる修正は、GTK_IM_MODULE 環境変数 を ibus ではなく xim に設定することです。

/etc/environment
GTK_IM_MODULE=xim
QT_IM_MODULE=ibus
XMODIFIERS=@im=ibus

キーを押し続けると "固着" する

特定のゲーム、特に Proton 経由で実行されるゲームでは、キーを数秒間押し続けると、そのキーが再度押されて離されるまで "固着" (押されたものとして押され続ける) することがあります。限られたテスト [1] では、IBus デーモンを kill するだけでこの問題が解決することがわかりました。

参照