freetype
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: unicode?


From: Antoine Leca
Subject: Re: unicode?
Date: Wed, 16 Aug 2000 11:13:11 +0200

Matthew Feinberg wrote:
> 
> AFAIK, FreeType just renders glyphs in the font based on character
> indicies.  It doesn't render entire text strings; that's up to the
> application to do.  That means you'll need to write a function to read
> characters from a UTF8 string and render them.
> 
> For Unicode text in UCS-2 or UCS-4 format, it's just a straight array of
> character codes.

Emmm... that would be a bit too easy.
For most scripts, things are more or less this way. However,
some complications can be added, named "combining characters"
for example.

Now some scripts, among them Arabic and Hebrew, are written
right to left. Since glyphs are always written left to right,
the reversal has to be done some day... The whole process is
quite a bit complex, and is named "the bidi algorithm".
Easy to find numerous implementations of it.

Next, some scripts have a pretty complex relation between the
characters (unit of meaning, usually a sound) and the glyphs
(unit of writing). The most known example are the Indic scripts.
The process to go from the characters as encoded in Unicode
(any flavour) to the glyphs as encoded in the fonts, is not yet
standardized.


Freetype does not care of anything of the above, mainly to avoid
to clutter a small library with all these complexities which are
of no or little use to many people. But to allow proper use of
the library for the people that do want to render "complex script"
(as they are called), the level of mapping from character(s) to
glyph(s) have been removed from the library and left to the calling
process.


Is it clearer to you, now, Allen?


Antoine



reply via email to

[Prev in Thread] Current Thread [Next in Thread]