X Input Method

X Input Method (XIM) はX Window Systemにおけるテキスト入力のためのインプットメソッド (IM) である。

X Input Method

X Input Method (XIM) はX Window Systemにおけるテキスト入力のためのインプットメソッド (IM) である。

概要

XIMはマルチバイト文字を入力する際に使われ、Xlibがその関数インタフェースを提供する。テキスト入力を扱うXIMに対して、テキスト出力を扱うAPIはXOMである。X Window Systemの代表的なライブラリであるGTKQtではimmoduleが実装されている[1]ので、これらのライブラリを用いればアプリケーション開発者が直接XIMを扱わなくても、作成したアプリケーションで日本語入力が行える。

入力スタイル

インプットメソッドの要求する可能性のある領域にはstatusやpreeditなどがある。これらの領域の設定によって入力スタイルが変わる。入力スタイルにはon-the-spot、over-the-spot、off-the-spotやrootがある[2]。GTK2[3]やQt[4]などのライブラリでは初期設定でon-the-spotになっており、on-the-spotスタイルが一般的に用いられる。しかし、on-the-spotスタイルではコールバック関数を定義する必要がある[5]ので、GUIライブラリにおける実装は他のスタイルに比べて複雑になる。

脚注

  1. ^ 「日本語入力システムの構造の概要」『UNIX USER』、ソフトバンクパブリッシング、2004年5月。 
  2. ^ 日本語入力システムの概要とセットアップ
  3. ^ 「XIMのプリエディット描画スタイル」『UNIX USER』、ソフトバンクパブリッシング、2004年5月。 
  4. ^ Choosing the input style[リンク切れ]
  5. ^ Internationalized Text Input,"Xlib Programming Manual" (O'Reilly & Associates, Inc.)

関連項目

外部リンク

Content Disclaimer

Informasi ini disarikan dari Wikipedia dan disajikan kembali untuk tujuan edukasi. Konten tersedia di bawah lisensi CC BY-SA 3.0. Kami tidak bertanggung jawab atas ketidakakuratan data yang bersumber dari kontribusi publik tersebut.

  1. The information displayed on this website is sourced in part or in whole from Wikipedia and has been adapted for the purpose of restating it. We strive to provide accurate and relevant information, however:
  2. There is no guarantee of absolute accuracy. Wikipedia is an open, collaborative project that can be edited by anyone, so information is subject to change.
  3. It is not intended to constitute professional advice. The content displayed is for informational and educational purposes only. For important decisions (e.g., medical, legal, or financial), please consult a professional.
  4. Content copyright. Wikipedia is licensed under the Creative Commons Attribution-ShareAlike License (CC BY-SA). This means that content may be reused with appropriate attribution and shared under a similar license.
  5. Responsible use. Any risk arising from the use of information from this website is entirely the responsibility of the user.