Hi,
Right, does your languague is realy some complex one??
As from some advice on list previous, if the language is not very complex, it is
much more worth to using the xkb / compose to solve the problem
BTW, I don't know much on xkb/compose, if you still need the XIM info, here it is.
> I am trying to write one basic/simple XIM for any one of the Indian
> Language ( Tamil ). But the problem is I cun't find any basic info
> abt XIM Server programming infos.
You should see the XIM and X library technical references.
>From here : ftp.xfree86.org/pub/XFree86/4.2.0/doc/
you can get the xim spec and the xlib references,
as well as some other very very useful resources like i18n frame work, x locale
database, etc
> I need help from the people those who working or worked with XIM Server
> programming. Help me for writing some BASIC XIM, Which will return two
> char for every single English char OR something like this.
>
> Already I wasted nearly 3 months in this. I have downloaded XCIN to
> find out the what is happening inside the XIM. But it is very difficult
> for me to understand the code. :(
>
> I downloaded IMdkit, I found a sampleIM program in doc folder. Presently
> I going thru the CODE.
>
> Still I can't able to find the tech behind, How the event from app is
> transfered to XIM and what are the ENV variables used for that etc.
>
> Can anyone give clear idea about XIM Server programming....
The most basic rationale of a XIM server is using the IMOpenIM to register the main
callback function for the whole XIm server to work.
For example, you registered a function xim_proto_hdlr like this
this_xims = IMOpenIM(display,
IMServerWindow, window1, //input window
IMModifiers, "Xi18n", //X11R6 protocol
IMServerName, imname, //XIM server name
IMLocale, imlocale, //XIM server locale
IMServerTransport, transport, //Comm. protocol
IMInputStyles, input_styles, //faked styles
IMEncodingList, encodings,
IMProtocolHandler, xim_proto_hdlr,
^^^^^^^^^^
IMFilterEventMask, filter_mask,
NULL);
Then, inside the xim_proto_hdlr, by examine the IMProtocol *calldata, being passed
from IMdkit, checking the field call_data->major_code, you can dispatch the functions.
There is a lot of XIM event, you can see them in the XIM spec, among those functions,
some are quite more important IMO likes:
xim open, (xim close)
xim create ic (xim distroy ic)
xim set ic values (xim get ic values)
xim set ic focus
xim forward event
For the first three event, you only need to handle the call back data properly, you
have
to configure the data structure associated with each IC, and some similar stuff.
For the set ic focus event, you need to "pop up" the input window which the properties
should determined by the setting from the internal status which is also actually
stored by
xim open, xim create ic and xim set ic values event.
For the xim forward event, it is the most frequently called function, and possibly
most
complicated, at last for chinese. Whenever a key event is forward to xim server, we
need to marshal the key press event, and do all neccessary stuff, until we can
return something like a composed characters, or some signal to indicated nothing
is returned.
And most of the xim server operation is doing about the above work.
Sure you add a lot of extra functionality to a xim server~~
Zenith Lau
_______________________________________________
I18n mailing list
[EMAIL PROTECTED]
http://XFree86.Org/mailman/listinfo/i18n