Hello,

I found a small problem of rxvt-2.7.5/6/7. In XFree86-4.1.0 system  
(and maybe in all the 4.0.X systems), when rxvt starts before the XIM
(X Input Method) server, then it cannot connect to the XIM server and
accept from its input when it starts. However, this problem is not
seen in the XFree86-3.3.6 system.
  
Because in the X11R6 standard, the XIM client should always has the
ability to accept the input from the XIM server, no matter which one
starts first, so I looked into the source of rxvt and found that there
is a missed function call when rxvt is under initialization. General
speaking, when a XIM client is under initialization, it should call
the following sequence of functions:

        setlocale(LC_CTYPE, "");
        XSupportsLocale();
        XSetLocaleModifiers("");
        XRegisterIMInstantiateCallback(display, NULL, NULL, NULL,
                                       im_callback, NULL);
   
But now in rxvt the call of "XSetLocaleModifiers" is missing. So I made
the following patch for rxvt-2.7.7 to fix this problem. I also tested
that the similar change for rxvt-2.7.5, 2.7.6 also fix this problem.
So I hope that this patch could be accepted in the future releases.  


Best Regards,
  
T.H.Hsieh

diff -r --unified orig/rxvt-2.7.7/src/init.c rxvt-2.7.7/src/init.c
--- orig/rxvt-2.7.7/src/init.c  Tue Aug  7 13:45:45 2001
+++ rxvt-2.7.7/src/init.c       Tue Oct  9 08:57:55 2001
@@ -563,6 +563,10 @@
                        (unsigned char *)r->h->locale, STRLEN(r->h->locale));
 
        rxvt_setTermFontSet(r, 0);
+       if (XSetLocaleModifiers("") == NULL) {
+           rxvt_print_error("Initially XSetLocaleModifiers false.");
+           exit(0);
+       }
        /* To avoid Segmentation Fault in C locale: Solaris only? */
        if (STRCMP(r->h->locale, "C"))
            XRegisterIMInstantiateCallback(r->Xdisplay, NULL, NULL, NULL,

Reply via email to