Hi ! Tuomo Valkonen wrote:
On Mon, Jun 30, 2003 at 11:30:58AM +0100, Sam Mason wrote:Compatibility, anyone ? BTW, "blurred" (antialiased) fonts aren't just translucensy (and, BTW, I just can't understand "it's only a cheap hack" claims - have you considered a possibility that not every X driver supports hardware alpha channel natively, and/or properly ?) Software fallbacks are ugly for most parts, yes. ). Your suggestion would lead to all sorts of incompatibility problems or doublecode - if, f.e, you're talking to XWin32 Xserver, which has no support for _Ext line of requests (X is a client-server, right ?), you would either fail or fall back to standart X proto - with two almost identical drawing/window management function sets. XRender, OTOH, as a client-side lib, avoids this issue very nice, falling back to (very expensive, though) software emulation.
I couldn't comment on the right place to put them - but translucent
primitives could be easily incorporated into the X framework.
My suggestion would be an extended graphics context attributes structure
XGCValuesExt and new versions of the functions that use this: XCreateGCExt,
XChangeGCExt and so on. This way no extra drawing APIs would be needed for translucent drawing, AA fonts and whatever and e.g. converting apps to use blurred fonts would be trivial (just set an extended GC attribute)
unless they expect drawing new text with another colour to erase old. Similarly I would add support for window translucency by introducing an
XSetWindowAttributesExt structure and related functions.
With all the best, yarick at relex dot ru
