[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Aw: Re: Re: Native TTF name sometimes contains crap
From: |
Werner LEMBERG |
Subject: |
Re: Aw: Re: Re: Native TTF name sometimes contains crap |
Date: |
Fri, 03 Sep 2021 13:16:24 +0000 (UTC) |
> OK, so let's go through the font: when I decode it with ftdump, I
> get the following entires for name and family:
>
> font family (ID 1) [Microsoft] (language=0x0804):
> "\U+009E\U+004F"
> full name (ID 4) [Microsoft] (language=0x0804):
> "\U+009E\U+004F"
>
> When I read the related data via the freetype-functions, I get back
>
> string=žÑOSýýýýØ8hW
Uh, oh, please tell us the byte values (in '0xXX' notation)!
Everything else won't survice e-mail encoding/decoding without
distortions.
> string_len=4
>
> ...means the žÑOS-part of the string is valid. But this in no case
> decodes to 0x9E 0x00 0x4F 0x00!
Welcome to Mojibake hell. The following possibilities come to my
mind; there are certainly even more possibilities to screw up.
(1) Wrong byte order.
(2) Wrong encoding, for example interpreting GB2312 characters as
UTF-8.
(3) Ditto, but mixing up with UCS4 – or vice versa.
It can also be combination of (1) to (3).
My advice: Forget it. Either suppress invalid data, or simply follow
the 'garbage in, garbage out' principle.
Werner
- Get the original, native name of a TTF?, virtual_worlds, 2021/09/01
- Get the original, native name of a TTF?, virtual_worlds, 2021/09/01
- Re: Get the original, native name of a TTF?, Werner LEMBERG, 2021/09/01
- Re: Get the original, native name of a TTF?, Adam Twardoch (Lists), 2021/09/01
- Re: Get the original, native name of a TTF?, virtual_worlds, 2021/09/02
- Native TTF name sometimes contains crap, virtual_worlds, 2021/09/02
- Re: Native TTF name sometimes contains crap, Werner LEMBERG, 2021/09/02
- Aw: Re: Native TTF name sometimes contains crap, virtual_worlds, 2021/09/02
- Re: Aw: Re: Native TTF name sometimes contains crap, Werner LEMBERG, 2021/09/02
- Aw: Re: Re: Native TTF name sometimes contains crap, virtual_worlds, 2021/09/03
- Re: Aw: Re: Re: Native TTF name sometimes contains crap,
Werner LEMBERG <=
- Aw: Re: Re: Re: Native TTF name sometimes contains crap, virtual_worlds, 2021/09/04
- Re: Aw: Re: Re: Re: Native TTF name sometimes contains crap, Werner LEMBERG, 2021/09/04
- Aw: Re: Re: Re: Re: Native TTF name sometimes contains crap, virtual_worlds, 2021/09/06
- Re: Aw: Re: Re: Re: Re: Native TTF name sometimes contains crap, Werner LEMBERG, 2021/09/06
- Aw: Re: Re: Re: Re: Re: Native TTF name sometimes contains crap, virtual_worlds, 2021/09/06
- Re: Aw: Re: Re: Re: Re: Re: Native TTF name sometimes contains crap, Werner LEMBERG, 2021/09/06
- Aw: Re: Re: Re: Re: Re: Re: Native TTF name sometimes contains crap, virtual_worlds, 2021/09/07
- Re: Aw: Re: Re: Re: Re: Re: Re: Native TTF name sometimes contains crap, Werner LEMBERG, 2021/09/17