[haiku-development] Re: UTF-8 BOM and StyledEdit...

  • From: "Axel Dörfler" <axeld@xxxxxxxxxxxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Sun, 30 Dec 2007 17:58:15 +0100 CET

"François Revol" <revol@xxxxxxx> wrote:
> At least we should handle files having those to not show this char.
> I'm not sure how to do that, either BTextEdit/View should account for
> it, or maybe at the font layer itself ?
> Or StyledEdit could strip it when reading a file, but it's not the
> cleanest way IMO. Maybe handle it in STXT or text Translators ?

This kind of handling belongs into the translator (for detection), and
into the text encoding library (for conversion). We should already
correctly handle UCS-2 BOM characters in the latter, but probably not
in the former.

Bye,
   Axel.


Other related posts: