yvw@gs3.UUCP (Yvo Van Wezemael) (03/17/89)
OK, I have to admit that my previous question was unclear, so I try again by deviding it into two (related?) parts: As I said in my previous posting, I'm using CLX. 1) Would someone be so kind to explain the difference and the usage of the 16-bit elems that can be passed to the draw-glyph(s) function? I read the documentation, but didn't understand it fully. 2) Is there a way to implement 'multiple-font-strings' on the CLX base? My lisp (Lucid CL) has char-font-limit equal to 1, but perhaps by shadowing and redefining some functions it could be possible to use the ability of different fonts in X. I hope that I have been more clear (precise) this time. Thanks (and sorry for the first attempt) --- Yvo Van Wezemael
rws@EXPO.LCS.MIT.EDU (Bob Scheifler) (03/20/89)
1) Would someone be so kind to explain the difference and the usage of the
16-bit elems that can be passed to the draw-glyph(s) function?
Do you understand the 8-bit case? If so, then the 16-bit case is identical,
except that a larger index space is used. The way you display glyphs is to
specify indices into a font array/matrix. The font array might have a size
that can be encoded in 8 bits, or it might have a size that can be encoded in
16 bits. The font matrix has a size for which each dimension can be encoded in
8 bits. However, this size is essentially orthogonal to the encoding size you
use in a draw-glyphs/PolyText request. Think of this as the difference between
using a variable of type (integer 0 255) and (integer 0 65535), or (for C folk)
using a variable of type unsigned char and unsigned short. What matters are
the values you pass, not the number of bytes they occupy.
2) Is there a way to implement 'multiple-font-strings' on the CLX base? My
lisp (Lucid CL) has char-font-limit equal to 1, but perhaps by shadowing
and redefining some functions it could be possible to use the ability of
different fonts in X.
Fonts are (pardon me) a mess in CL; char-font seems pretty useless as a decent
abstraction. I doubt there is any way in Lucid to up the limit. You will note
that draw-glyphs is not restricted to taking a string, but rather can take any
sequence. This allows you the freedom to use any "multi" representation you
want, and provide the appropriate :translate routine to decompose it into
fonts and glyph indices.