Re: [Indic-computing-devel] Re: NCST Indix Examined
Status: Alpha
Brought to you by:
jkoshy
From: Arun S. <ar...@sh...> - 2002-02-19 19:03:14
|
On Tue, Feb 19, 2002 at 10:10:41AM -0800, Arun Sharma wrote: > The proposed new algorithm: > > FindPosition(textpos, startx, pixel_width) > // Make a single request to the X Server - this doesn't exist in > // the X protocol yet > nchars = XComputeWidth(textbuf[textpos:end-of-line], startx, pixel_width, > // other args font etc) > > // everything starting from textpos to textpos + nchars is "selected" > Hmm, I don't think I needed to invent a new protocol request. XQueryTextExtents seems to be good enough. Another thought: we'll have to implement this algorithm on the X server side with Open Type fonts anyway, in order to service this particular request. Why reimplement it on a client side library ? To summarize my thoughts on the advantages of taking the client side approach: - Preserve status quo (use glyph codes) - Less pressure on the X server - good for "thin clients" = "thin X servers" - Reduced network traffic ? I think we'll have to empirically determine this one (Is XQueryTextExtents traffic >> Shipping the Open Type font info to the client once and processing XTextExtents locally ?). On the other hand, X has not been optimized for network efficiency (it always assumed a fast ethernet environment). More ? -Arun |