Edmund GRIMLEY EVANS wrote on 2000-09-12 16:46 UTC:
> According to glibc's iswprint(160), a non-breaking space is not
> printable. Is this correct?

Certainly not. NBSP is most definitely a printable character.

The only non-printable characters in Unicode are control characters
whose general category code in the Unicode database starts with C, i.e.
those characters that get printed with

$ egrep '^[^;]*;[^;]*;C' UnicodeData-Latest.txt

http://www.unicode.org/Public/UNIDATA/UnicodeData-Latest.txt
http://www.unicode.org/Public/UNIDATA/UnicodeData.html

For the soft hyphen (SHY, 173=0xAD), the discussion might be a bit more
tricky (see <http://www.hut.fi/~jkorpela/shy.html> for a good
discussion), but I would also classify that one as printable as well,
and so does Unicode.

(Note that some of the X11 fonts lack character 160, so with these
broken fonts, NBSP is indeed non-printable, but this font bug will be
fixed soon. I can only guess, that knowledge this font problem might
have been the origin of iswprint(160) == 0 in glibc.)

Markus

-- 
Markus G. Kuhn, Computer Laboratory, University of Cambridge, UK
Email: mkuhn at acm.org,  WWW: <http://www.cl.cam.ac.uk/~mgk25/>

-
Linux-UTF8:   i18n of Linux on all levels
Archive:      http://mail.nl.linux.org/lists/

Reply via email to