1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!--
Copyright (C) 2001 Information-technology Promotion Agency (IPA)
Copyright (C) 2001-2004
National Institute of Advanced Industrial Science and Technology (AIST)
This file is part of the m17n library documentation.
See the end for copying conditions.
-->
<html><head><meta http-equiv="Content-Type" content="text/html;charset="UTF-8">
<title>The m17n Library</title>
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head>
<body bgcolor="#ffffff">
<a name="top-of-page"></a>
<hr><center>
<a class="qindex" href="index.html">Main Page</a>
<a class="qindex" href="modules.html">Modules</a>
<!-- <a class="qindex" href="classes.html">Alphabetical List</a> -->
<a class="qindex" href="annotated.html">Data Structures</a>
<!-- <a class="qindex" href="files.html">File List</a> -->
<!-- <a class="qindex" href="functions.html">Data Fields</a> -->
<a class="qindex" href="globals.html">Globals</a>
<a class="qindex" href="pages.html">Appendix</a>
</center>
<hr>
<!-- Generated by Doxygen 1.3.9.1 -->
<h1>Input Method (GUI)<br>
<small>
[<a class="el" href="group__m17nGUI.html">GUI API</a>]</small>
</h1>Input method support on window systems.
<a href="#_details">More...</a><table border="0" cellpadding="0" cellspacing="0">
<tr><td></td></tr>
<tr><td colspan="2"><br><h2>Data Structures</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct </td><td class="memItemRight" valign="bottom"><a class="el" href="structMInputGUIArgIC.html">MInputGUIArgIC</a></td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Type of the argument to the function <a class="el" href="group__m17nInputMethod.html#ga36">minput_create_ic()</a>. <a href="structMInputGUIArgIC.html#_details">More...</a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct </td><td class="memItemRight" valign="bottom"><a class="el" href="structMInputXIMArgIM.html">MInputXIMArgIM</a></td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Structure pointed to by the argument <b>arg</b> of the function <a class="el" href="group__m17nInputMethod.html#ga34">minput_open_im()</a>. <a href="structMInputXIMArgIM.html#_details">More...</a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top">struct </td><td class="memItemRight" valign="bottom"><a class="el" href="structMInputXIMArgIC.html">MInputXIMArgIC</a></td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Structure pointed to by the argument <b>arg</b> of the function <a class="el" href="group__m17nInputMethod.html#ga36">minput_create_ic()</a>. <a href="structMInputXIMArgIC.html#_details">More...</a><br></td></tr>
<tr><td colspan="2"><br><h2>Functions</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="group__m17nSymbol.html#ga0">MSymbol</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nInputMethodWin.html#ga3">minput_event_to_key</a> (<a class="el" href="group__m17nFrame.html#ga0">MFrame</a> *frame, void *event)</td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Convert an event to an input key. <a href="#ga3"></a><br></td></tr>
<tr><td colspan="2"><br><h2>Variables</h2></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="structMInputDriver.html">MInputDriver</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nInputMethodWin.html#ga0">minput_gui_driver</a></td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Input driver for internal input methods on window systems. <a href="#ga0"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="group__m17nSymbol.html#ga0">MSymbol</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nInputMethodWin.html#ga1">Mxim</a></td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Symbol of the name "xim". <a href="#ga1"></a><br></td></tr>
<tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="structMInputDriver.html">MInputDriver</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="group__m17nInputMethodWin.html#ga2">minput_xim_driver</a></td></tr>
<tr><td class="mdescLeft"> </td><td class="mdescRight">Input method driver for XIM. <a href="#ga2"></a><br></td></tr>
</table>
<hr><a name="_details"></a><h2>Detailed Description</h2>
The input driver <code>minput_gui_driver</code> is provided for internal input methods that is useful on window systems. It displays preedit text and status text at the inputting spot. See the documentation of <code>minput_gui_driver</code> for more details.<p>
In the m17n-X library, the foreign input method of name <code>Mxim</code> is provided. It uses XIM (X Input Method) as a background input engine. The symbol <code>Mxim</code> has a property <code>Minput_driver</code> whose value is a pointer to the input driver <code>minput_xim_driver</code>. See the documentation of <code>minput_xim_driver</code> for more details. <hr><h2>Function Documentation</h2>
<a class="anchor" name="ga3" doxytag="input-gui.c::minput_event_to_key"></a><p>
<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"><a class="el" href="group__m17nSymbol.html#ga0">MSymbol</a> minput_event_to_key </td>
<td class="md" valign="top">( </td>
<td class="md" nowrap valign="top"><a class="el" href="group__m17nFrame.html#ga0">MFrame</a> * </td>
<td class="mdname" nowrap> <em>frame</em>, </td>
</tr>
<tr>
<td class="md" nowrap align="right"></td>
<td class="md"></td>
<td class="md" nowrap>void * </td>
<td class="mdname" nowrap> <em>event</em></td>
</tr>
<tr>
<td class="md"></td>
<td class="md">) </td>
<td class="md" colspan="2"></td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
</td>
<td>
<p>
The <a class="el" href="group__m17nInputMethodWin.html#ga3">minput_event_to_key()</a> function returns the input key corresponding to event <b>event</b> on <b>frame</b> by a window system dependent manner.<p>
In the m17n-X library, <b>event</b> must be a pointer to the structure <code>XKeyEvent</code>, and it is handled as below.<p>
At first, the keysym name of <b>event</b> is acquired by the function <code>XKeysymToString</code>. Then, the name is modified as below.<p>
If the name is one of "a" .. "z" and <b>event</b> has a Shift modifier, the name is converted to "A" .. "Z" respectively, and the Shift modifier is cleared.<p>
If the name is one byte length and <b>event</b> has a Control modifier, the byte is bitwise anded by 0x1F and the Control modifier is cleared.<p>
If <b>event</b> still has Shift, Control, Meta, Alt, Super, and/or Hyper modifiers, the name is preceded by "S-", "C-", "M-", "A-", "s-", and/or "H-" respectively in this order.<p>
For instance, if the keysym name is "a" and the event has Shift, Meta, and Hyper modifiers, the resulting name is "H-M-A".<p>
At last, a symbol who has the name is returned. </td>
</tr>
</table>
<hr><h2>Variable Documentation</h2>
<a class="anchor" name="ga0" doxytag="input-gui.c::minput_gui_driver"></a><p>
<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"><a class="el" href="structMInputDriver.html">MInputDriver</a> <a class="el" href="group__m17nInputMethodWin.html#ga0">minput_gui_driver</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
</td>
<td>
<p>
The input driver <code>minput_gui_driver</code> is for internal input methods to be used on window systems.<p>
It creates sub-windows for a preedit text and a status text, and displays them at the input spot set by the function <a class="el" href="group__m17nInputMethod.html#ga40">minput_set_spot()</a>.<p>
The macro <a class="el" href="group__m17nIntro.html#ga5">M17N_INIT()</a> set the variable <code>minput_driver</code> to the pointer to this driver so that all internal input methods use it.<p>
Therefore, unless <code>minput_driver</code> is changed from the default, the driver dependent arguments to the functions whose name begin with minput_ must are treated as follows.<p>
The argument <b>arg</b> of the function <a class="el" href="group__m17nInputMethod.html#ga34">minput_open_im()</a> is ignored.<p>
The argument <b>arg</b> of the function <a class="el" href="group__m17nInputMethod.html#ga36">minput_create_ic()</a> must be a pointer to the structure <code><a class="el" href="structMInputGUIArgIC.html">MInputGUIArgIC</a></code>. See the documentation of <code><a class="el" href="structMInputGUIArgIC.html">MInputGUIArgIC</a></code> for more details.<p>
If the argument <b>key</b> is <code>Mnil</code>, the argument <b>arg</b> of the function <a class="el" href="group__m17nInputMethod.html#ga38">minput_filter()</a> must be a pointer to the object of type <code>XEvent</code>. In that case, <b>key</b> is generated from <b>arg</b>.<p>
The argument <b>arg</b> of the function <a class="el" href="group__m17nInputMethod.html#ga39">minput_lookup()</a> must be the same one as that of the function <a class="el" href="group__m17nInputMethod.html#ga38">minput_filter()</a>. </td>
</tr>
</table>
<a class="anchor" name="ga1" doxytag="input-gui.c::Mxim"></a><p>
<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"><a class="el" href="group__m17nSymbol.html#ga0">MSymbol</a> <a class="el" href="group__m17nInputMethodWin.html#ga1">Mxim</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
</td>
<td>
<p>
The variable Mxim is a symbol of name "xim". It is a name of the input method driver <a class="el" href="group__m17nInputMethodWin.html#ga2">minput_xim_driver</a>. </td>
</tr>
</table>
<a class="anchor" name="ga2" doxytag="m17n-X.c::minput_xim_driver"></a><p>
<table class="mdTable" width="100%" cellpadding="2" cellspacing="0">
<tr>
<td class="mdRow">
<table cellpadding="0" cellspacing="0" border="0">
<tr>
<td class="md" nowrap valign="top"><a class="el" href="structMInputDriver.html">MInputDriver</a> <a class="el" href="group__m17nInputMethodWin.html#ga2">minput_xim_driver</a> </td>
</tr>
</table>
</td>
</tr>
</table>
<table cellspacing="5" cellpadding="0" border="0">
<tr>
<td>
</td>
<td>
<p>
<b>Initial value:</b><div class="fragment"><pre class="fragment">
{ xim_open_im, xim_close_im, xim_create_ic, xim_destroy_ic,
xim_filter, xim_lookup, NULL }
</pre></div>The driver <a class="el" href="group__m17nInputMethodWin.html#ga2">minput_xim_driver</a> is for the foreign input method of name <a class="el" href="group__m17nInputMethodWin.html#ga1">Mxim</a>. It uses XIM (X Input Methods) as a background input engine.<p>
As the symbol <a class="el" href="group__m17nInputMethodWin.html#ga1">Mxim</a> has property <a class="el" href="group__m17nInputMethod.html#ga33">Minput_driver</a> whose value is a pointer to this driver, the input method of language <a class="el" href="group__m17nSymbol.html#ga1">Mnil</a> and name <a class="el" href="group__m17nInputMethodWin.html#ga1">Mxim</a> uses this driver.<p>
Therefore, for such input methods, the driver dependent arguments to the functions whose name begin with minput_ must be as follows.<p>
The argument <b>arg</b> of the function <a class="el" href="group__m17nInputMethod.html#ga34">minput_open_im()</a> must be a pointer to the structure <a class="el" href="structMInputXIMArgIM.html">MInputXIMArgIM</a>. See the documentation of <a class="el" href="structMInputXIMArgIM.html">MInputXIMArgIM</a> for more details.<p>
The argument <b>arg</b> of the function <a class="el" href="group__m17nInputMethod.html#ga36">minput_create_ic()</a> must be a pointer to the structure <a class="el" href="structMInputXIMArgIC.html">MInputXIMArgIC</a>. See the documentation of <a class="el" href="structMInputXIMArgIC.html">MInputXIMArgIC</a> for more details.<p>
The argument <b>arg</b> of the function <a class="el" href="group__m17nInputMethod.html#ga38">minput_filter()</a> must be a pointer to the structure <code>XEvent</code>. The argument <b>key</b> is ignored.<p>
The argument <b>arg</b> of the function <a class="el" href="group__m17nInputMethod.html#ga39">minput_lookup()</a> must be the same one as that of the function <a class="el" href="group__m17nInputMethod.html#ga38">minput_filter()</a>. The argument <b>key</b> is ignored. </td>
</tr>
</table>
<hr>
<center>
<a href="#top-of-page">Top of this page</a><br><br>
<a class="qindex" href="index.html">Main Page</a>
<a class="qindex" href="modules.html">Modules</a>
<!-- <a class="qindex" href="classes.html">Alphabetical List</a> -->
<a class="qindex" href="annotated.html">Data Structures</a>
<!-- <a class="qindex" href="files.html">File List</a> -->
<!-- <a class="qindex" href="functions.html">Data Fields</a> -->
<a class="qindex" href="globals.html">Globals</a>
<a class="qindex" href="pages.html">Appendix</a>
</center>
<hr>
<ADDRESS>
<a href="http://www.m17n.org/m17n-lib/index.html" target="mulewindow"><img src="parrot.png" align=bottom alt="mulemark" border=0></a>
<A HREF="mailto:mule-aist@m17n.org">mule-aist@m17n.org</a>
</ADDRESS>
</body>
</HTML>
<!-- Copyright information
Copyright (C) 2001 Information-technology Promotion Agency (IPA)
Copyright (C) 2001-2004
National Institute of Advanced Industrial Science and Technology (AIST)
This file is part of the m17n library documentation.
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.2 or
any later version published by the Free Software Foundation; with no
Invariant Section, Front-Cover Texts "The m17n library documentation",
and no Back-Cover Texts. A copy of the license is included in the
appendix entitled "GNU Free Documentation License".
-->
|