incompatible change in XIMPreeditCallbacks

Alan Coopersmith alan.coopersmith at oracle.com
Sun Oct 2 22:54:55 UTC 2022


On 10/2/22 00:00, Po Lu wrote:
> Also, there has been at least one recent change to Xlib that (if my
> memory of the documentation is correct) goes against the documentation,
> notably allowing the client to send XNSpotLocation when
> XIMPreeditCallbacks is specified in the input method style:
> 
>    The XNSpotLocation argument specifies to the input method the
>    coordinates of the spot to be used by an input method executing with
>    XNInputStyle set to XIMPreeditPosition. When specified to any input
>    method other than XIMPreeditPosition, this XIC value is ignored. <=====
> 
>    The x coordinate specifies the position where the next character would
>    be inserted. The y coordinate is the position of the baseline used by
>    the current text line in the focus window. The x and y coordinates are
>    relative to the focus window, if it has been set; otherwise, they are
>    relative to the client window. If neither the focus window nor the
>    client window has been set, the results are undefined.
> 
>    The value of the argument is a pointer to a structure of type XPoint.
> 
> That is an incompatible change and should at least be documented.  I
> remember having written input servers and clients in the past that
> expect things to work the old way.

Unfortunately, there is no one left reviewing Xlib patches who knows how
input methods work or what might be a breaking change, or who could write
documentation of such changes.  We'd love for someone to step up and
take on such work.

It sounds like you're commenting on this change:
   https://gitlab.freedesktop.org/xorg/lib/libx11/-/merge_requests/127
but nothing in that merge request notes any compatibility issues, and
the prior bugzilla discussion at
   https://bugs.freedesktop.org/show_bug.cgi?id=1580
has positive comments from people who know far more about input methods
than I do, and apparently I verified almost two decades ago (so long ago
that I'd forgotten) that we already shipped it in the Solaris libX11,
so I saw no issue in merging it.

If I thought it was viable, I'd be tempted to split all the XIM code
off into a separate repo for folks with knowledge/interest to maintain,
but I'm pretty sure that would just result in XIM becoming unmaintained
and dying, leaving many X11 users unable to input text in the languages
they write in.

-- 
         -Alan Coopersmith-                 alan.coopersmith at oracle.com
          Oracle Solaris Engineering - https://blogs.oracle.com/solaris


More information about the xorg-devel mailing list