🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.readers
38 messages
38 total messages Started by Jeff-Relf.Me Thu, 15 May 2014 20:10
--
#257216
Author: Jeff-Relf.Me
Date: Thu, 15 May 2014 20:10
33 lines
2276 bytes
Micha,

At various times and places, I read raw headers...
and I prefer raw UTF·8 over raw "encoded words".

The -raw- UTF·8 BOM at the end of my "Subject:" lines
helps certain apps ( Google, MicroSoft, Mozilla )
auto·detect the charset.
http://en.wikipedia.org/wiki/Byte_order_mark

You said:
> slrn had detected the invalid encoding
> and replaced all bytes with "?"

Which version of slrn, the latest one ?

You created flnews, so you don't have to,
"replace the subject with an error message,
and I repair it manually".

You told me:
> Nobody else uses HTML for something that is not "bad" in USENET.
> WWW or other places are different worlds.

Like it or not, mainstream Usenet/email clients
use a proportional font ( it's the default ).
Apparently, most prefer it that way.

<PRE> is the -standard- solution to this "problem".

I know who can and cannot read/write the standard,
and I'm free to post "text/Plain", instead of "text/HTML".
Left·Click posts HTML, Right·Click posts PlainText... simple.
Re: I prefer raw UTF·8 over raw "encoded words". 
#257218
Author: tlvp
Date: Thu, 15 May 2014 20:58
5 lines
1874 bytes
On Thu, 15 May 2014 13:10:19 -0700 (Seattle), Jeff-Relf.Me wrote:

> Left·Click posts HTML, Right·Click posts PlainText... simple.

Ah, yes, Click and Clack (aka the Tappet brothers) :-) . Of course!
Re: [JR] I prefer raw UTF·8 over raw "encoded words".
#257635
Author: »Q«
Date: Thu, 15 May 2014 21:34
20 lines
2269 bytes
On Thu, 15 May 2014 13:10:19 -0700 (Seattle)
Jeff-Relf.Me <@.> wrote:

> I read raw headers...
> and I prefer raw UTF·8 over raw "encoded words".

Translation:  Relf is breaking things by ignoring MUSTs in RFCs because
that makes reading his own raw headers more pleasurable for him.

> The -raw- UTF·8 BOM at the end of my "Subject:" lines
> helps certain apps auto·detect the charset.

Translation:  Relf intentionally breaks *all* of his messages as a
workaround to help Google deal with *some* of his intentionally broken
messages.

> Which version of slrn, the latest one ?

It doesn't matter.  The problem is with Relf and Relf's software, not
anywhere else.
Re: I prefer raw UTF·8 over raw "encoded words".
#257219
Author: Michael Baeuerle
Date: Thu, 15 May 2014 22:24
72 lines
3776 bytes
Jeff-Relf.Me wrote:
> 
> At various times and places, I read raw headers...
> and I prefer raw UTF·8 over raw "encoded words".

Bad idea in message headers.

> The -raw- UTF·8 BOM at the end of my "Subject:" lines
> helps certain apps ( Google, MicroSoft, Mozilla )
> auto·detect the charset.
> http://en.wikipedia.org/wiki/Byte_order_mark

But why do you force the rest of the world to guess or "detect"
something if there is an official global standard how to declare what
it is?

> You said:
> > slrn had detected the invalid encoding
> > and replaced all bytes with "?"
> 
> Which version of slrn, the latest one ?

Version 1.0.1 (AFAIK it is the latest one)

> You created flnews, so you don't have to,
> "replace the subject with an error message,
> and I repair it manually".

I agree and there is an entry on the ToDo list to improve this. But I
currently tend to implement it like slrn. Already a good improvement
if I only have to delete some question marks.

Reason:
Rewriting any character with nonzero Bit 7 to "?" (or any other ASCII
replacement) makes the header field encoding known and valid in all
cases. Otherwise a guessing autodetect algorithm may think it is Unicode
but in reality it is not or vice versa. Remember the ForteAgent that
guessed wrong, this is not a trivial task. Much work for an unsafe
solution that only work sometimes. If it should work more reliable you
need a complicated pattern matching like:
- If From==Jeff-Relf.Me then Guess=UTF-8
- If User-Agent==Outlook then Guess=Windows-1252
- ...
- The pattern I overlooked and that crippled the article

This is a workaround, no solution. I am not sure if I really want to
implement it this way.

> You told me:
> > Nobody else uses HTML for something that is not "bad" in USENET.
> > WWW or other places are different worlds.
> 
> Like it or not, mainstream Usenet/email clients
> use a proportional font ( it's the default ).
> Apparently, most prefer it that way.
> 
> <PRE> is the -standard- solution to this "problem".

I can't agree.

> I know who can and cannot read/write the standard,
> and I'm free to post "text/Plain", instead of "text/HTML".
> Left·Click posts HTML, Right·Click posts PlainText... simple.

flnews always use a monospaced font, therefore text/plain for me please.

[Xpost preserved and Fup2 news.software.readers]


Micha
-- 
http://micha.freeshell.org/
--
#257637
Author: Jeff-Relf.Me
Date: Thu, 15 May 2014 23:42
51 lines
3219 bytes
Micha,  Monospaced is -not- the default,
nor is it the preferred choice, for most.

So, you're -wrong- to assume others will
see your posts as you do, monospaced; to wit:
                          .
                       .  !\  _
                       l\/ ( /(_
                      _ \`--" _/ .
                      \~")   (_,/)
                      _)/.   ,\,/
             _____,-"~    \ /   "~"-._____
         ,-~"     "~-.  .  "  .  ,-~"     "~-.
       ,^             ^. `. .' ,^             ^.
      /                 \  ^  /                 \
     Y___________________Y   Y___________________Y
     | |^~"|^   _ ^|"~^| |   | |"~"|^ _   ^|"~"| |
     | !   l   (_) !   ! l   | !   l (_)   !   ! |
     l  \  `\.___,/'  /  !   l  \  `\.___,/'  /  !
      \  ^.         ,^  /!   !\  ^.         ,^  /
       ^.  ~-------~  ,^\`v-v'/^.  ~-------~  ,^
       _)~-._______,-~   }---{   ~-._______,-~(_
  .--"~           ,-^7' /     \ `Y^-,           ~"--.
 /               (_,/ ,/'     `\. \._)    ___        \
 \_____.,--"~~~"--..,__        ___,..--<"~   ~"-.,___/
     / (    __,--~ _.._""~~~~"" ,-"  "-.`\     /~.-"
     `._"--~_,.--"~    \       /        \ `---' /
        "~""            \     /          "-.__,/
                        `L   ]'
                         l   !
                         j___L              -Row
                        (_____)
                         |   |

Far and wide, <PRE> is the solution to this "problem".

Fear of HTML is irrational,
and something only a Linux·head would think.
Linux is -not- famous for getting the graphics right.

Google, MicroSoft and Mozilla have to
auto·detect the charset of the "Subject:" line;
e.g. for a bunch of Koreans, using Outlook.

You don't have to do that, so you don't care.
Still, you're wrong.

You don't encounter raw headers like I do
( at Google Groups, for example );
so you don't understand why raw UTF·8 is
preferable to raw "encoded words".
Re: I prefer raw UTF·8 over raw "encoded words".
#257638
Author: Michael Moroney
Date: Fri, 16 May 2014 01:19
41 lines
2880 bytes
Michael Baeuerle <michael.baeuerle@gmx.net> writes:

>Jeff-Relf.Me wrote:
>>
>> At various times and places, I read raw headers...
>> and I prefer raw UTF·8 over raw "encoded words".

>Bad idea in message headers.

As I stated, good luck with that.  Jeff thinks he's better than RFCs even
if he claims he isn't.

>> The -raw- UTF·8 BOM at the end of my "Subject:" lines
>> helps certain apps ( Google, MicroSoft, Mozilla )

Always amusing he's using the most broken newsposter on the planet (Google
Groups) as an example of anything other than what not to do.

>> auto·detect the charset.
>> http://en.wikipedia.org/wiki/Byte_order_mark

And that article tells how to use it correctly, which you don't.

>But why do you force the rest of the world to guess or "detect"
>something if there is an official global standard how to declare what
>it is?

yeah, why guess Relf wants UTF-8 when he can explicitly say it's UTF-8?

>> Like it or not, mainstream Usenet/email clients
>> use a proportional font ( it's the default ).
>> Apparently, most prefer it that way.
>>
>> <PRE> is the -standard- solution to this "problem".

>I can't agree.

MIME "format=fixed" is the solution. Although that's supposedly the
default, bad newsreaders such as Google Groups need a whack on the nose
to do what's right, but I bet it's still ignored.
Re: I prefer raw UTF·8 over raw "encoded words".
#257636
Author: Michael Baeuerle
Date: Fri, 16 May 2014 09:32
39 lines
2884 bytes
Michael Moroney wrote:
> Michael Baeuerle wrote:
> > Jeff-Relf.Me wrote:
> > > 
> > > [...]
> > > The -raw- UTF?8 BOM at the end of my "Subject:" lines
> > > helps certain apps ( Google, MicroSoft, Mozilla )
> 
> Always amusing he's using the most broken newsposter on the planet (Google
> Groups) as an example of anything other than what not to do.

Google Groups is broken. But Microsoft and Mozilla programs have fairly
(Outlook Express) to really good (Thunderbird) MIME support. If they are
configured wrong by the user that doesn't mean that they can't do it
right.

> > > [...]
> > > Like it or not, mainstream Usenet/email clients
> > > use a proportional font ( it's the default ).
> > > Apparently, most prefer it that way.
> > > 
> > > <PRE> is the -standard- solution to this "problem".
> > 
> > I can't agree.
> 
> MIME "format=fixed" is the solution. Although that's supposedly the
> default, bad newsreaders such as Google Groups need a whack on the nose
> to do what's right, but I bet it's still ignored.

It seems like Google intentionally degrade their USENET support a bit
more with every update of their software. For me it looks like they
want to push the users away from USENET and to their own services.
Remember they are a company and must earn money. On USENET you don't
need a Google account and harvesting your data (the product that Google
offer to earn money) is much harder for them compared to their own
services.


Micha
Re: Fear of HTML is irrational.
#257641
Author: Michael Baeuerle
Date: Fri, 16 May 2014 12:18
41 lines
2958 bytes
Jeff-Relf.Me wrote:
> 
> [...]
> So, you're -wrong- to assume others will
> see your posts as you do, monospaced; to wit:
>                           .
>                        .  !\  _
>                        l\/ ( /(_
>                       _ \`--" _/ .
>                       \~")   (_,/)
>                       _)/.   ,\,/
>              _____,-"~    \ /   "~"-._____
>          ,-~"     "~-.  .  "  .  ,-~"     "~-.
>        ,^             ^. `. .' ,^             ^.
>       /                 \  ^  /                 \
>      Y___________________Y   Y___________________Y
>      | |^~"|^   _ ^|"~^| |   | |"~"|^ _   ^|"~"| |
>      | !   l   (_) !   ! l   | !   l (_)   !   ! |
>      l  \  `\.___,/'  /  !   l  \  `\.___,/'  /  !
>       \  ^.         ,^  /!   !\  ^.         ,^  /
>        ^.  ~-------~  ,^\`v-v'/^.  ~-------~  ,^
>        _)~-._______,-~   }---{   ~-._______,-~(_
>   .--"~           ,-^7' /     \ `Y^-,           ~"--.
>  /               (_,/ ,/'     `\. \._)    ___        \
>  \_____.,--"~~~"--..,__        ___,..--<"~   ~"-.,___/
>      / (    __,--~ _.._""~~~~"" ,-"  "-.`\     /~.-"
>      `._"--~_,.--"~    \       /        \ `---' /
>         "~""            \     /          "-.__,/
>                         `L   ]'
>                          l   !
>                          j___L              -Row
>                         (_____)
>                          |   |
> [...]

Maybe we should ask the readers here. Who gets the picture above
displayed correctly?

======================================================================

flnews (all versions): OK
Re: Fear of HTML is irrational. 
#257644
Author: Steve Crook
Date: Fri, 16 May 2014 13:15
18 lines
2077 bytes
On Thu, 15 May 2014 16:42:46 -0700 (Seattle), Jeff-Relf.Me wrote in
Message-Id: <Jeff-Relf.Me@May.15{16.42.Seattle.2014}>:

> Fear of HTML is irrational,
> and something only a Linux·head would think.
A very high percentage of the world's html is delivered from Linux.  It
would take a very brave corporation to present a Windows server to the
Internet.

> Linux is -not- famous for getting the graphics right.
Perhaps you mean, Linux isn't great at talking to graphics cards that
rely on proprietary drivers that are closed source?  If that's what you
mean, I agree.

-- 
What shall we use 
To fill the empty spaces 
Where we used to talk?
Re: I prefer raw UTF·8 over raw "encoded words".
#257646
Author: Sn!pe
Date: Sat, 17 May 2014 10:39
29 lines
4007 bytes
Michael Baeuerle <michael.baeuerle@stz-e.de> wrote:

> Michael Moroney wrote:

[Google Groups]

> > MIME "format=fixed" is the solution. Although that's supposedly the
> > default, bad newsreaders such as Google Groups need a whack on the nose
> > to do what's right, but I bet it's still ignored.
> 
> It seems like Google intentionally degrade their USENET support a bit
> more with every update of their software. For me it looks like they
> want to push the users away from USENET and to their own services.
> Remember they are a company and must earn money. On USENET you don't
> need a Google account and harvesting your data (the product that Google
> offer to earn money) is much harder for them compared to their own
> services.

I concur, I have thought this for ages. As you say, Google cannot
advertise on Usenet therefore they want everyone to access "Groups" 
via their web pages. 

Google view us as livestock rather than as users.

-- 
^Ï^.      Sn!pe      <snipe@notforspam.fsnet.co.uk> 
 
My pet rock Gordon just is. 
 
Re: I prefer raw UTF·8 over raw "encoded words".
#257647
Author: Paul Sture
Date: Sun, 18 May 2014 08:28
48 lines
3606 bytes
On 2014-05-17, Sn!pe <snipe@spambin.fsnet.co.uk> wrote:
> Michael Baeuerle <michael.baeuerle@stz-e.de> wrote:
>
>> Michael Moroney wrote:
>
> [Google Groups]
>
>> > MIME "format=fixed" is the solution. Although that's supposedly the
>> > default, bad newsreaders such as Google Groups need a whack on the nose
>> > to do what's right, but I bet it's still ignored.
>> 
>> It seems like Google intentionally degrade their USENET support a bit
>> more with every update of their software. For me it looks like they
>> want to push the users away from USENET and to their own services.
>> Remember they are a company and must earn money. On USENET you don't
>> need a Google account and harvesting your data (the product that Google
>> offer to earn money) is much harder for them compared to their own
>> services.
>
> I concur, I have thought this for ages. As you say, Google cannot
> advertise on Usenet therefore they want everyone to access "Groups" 
> via their web pages. 

The sad thing is that some of us switched to Google in the first place
as a result of them rescuing the DejaVue archives from oblivion.

Point 17 here:
<http://searchenginewatch.com/article/2059398/25-Things-I-Love-About-Google#17>

"17. Saving the internet's early discussions: Google Groups is far from a
Usenet archive these days, but I still love the fact that Google way back
saved the Deja archives so that we can read early discussions of the
internet that happened on the internet."

Unfortunately they have forgotten how much credibility that gave them back
in 2001.

> Google view us as livestock rather than as users.

Yep.  When I briefly had a Google+ account, they would force a login if
I wanted to view Google Groups. Clearing cookies solved that problem.

-- 
Paul Sture

"Hell hath no fury like a Usenet user scorned"
Paraphrased from William Congreve's The Mourning Bride (1697)
<https://en.wikipedia.org/wiki/William_Congreve#Famous_lines>
--
#257648
Author: Jeff-Relf.Me
Date: Sun, 18 May 2014 09:11
5 lines
1440 bytes
<PRE Style='White-Space: PRE !important; Font-Size: 18px !important;Font-Family: monospace !important;'> 
Amazingly, Usenet is now -less- searchable····
what with Google Groups dying and all.

I like that, I like the added privacy.
Re: Amazingly, Usenet is now -less- searchable.
#257649
Author: Michael Baeuerle
Date: Sun, 18 May 2014 09:47
18 lines
2001 bytes
Jeff-Relf.Me wrote:
> 
> Amazingly, Usenet is now -less- searchable····
> what with Google Groups dying and all.
> 
> I like that, I like the added privacy.

There were options around for many years that allow you to declare that
an article should not be archived. The current one is the "Archive: no"
header field from RFC5536 (if you omit it, the default value is "yes").

In some cases archiving may really be intended (e.g. so that other
people can find answers to technical questions given in the past).

AFAIK Google honour "Archive" and "X-No-Archive" header fields.


Micha
Re: Amazingly, Usenet is now -less- searchable.
#257650
Author: Sn!pe
Date: Sun, 18 May 2014 11:46
27 lines
3715 bytes
Michael Baeuerle <michael.baeuerle@gmx.net> wrote:

> Jeff-Relf.Me wrote:
> > 
> > Amazingly, Usenet is now -less- searchable····
> > what with Google Groups dying and all.
> > 
> > I like that, I like the added privacy.
> 
> There were options around for many years that allow you to declare that
> an article should not be archived. The current one is the "Archive: no"
> header field from RFC5536 (if you omit it, the default value is "yes").
> 
> In some cases archiving may really be intended (e.g. so that other
> people can find answers to technical questions given in the past).
> 
> AFAIK Google honour "Archive" and "X-No-Archive" header fields.

I use XNA: Yes. When I last checked Google displayed my posts 
for one week, then hid them, but they were still used in their 
profile of my posts.

-- 
^Ï^.      Sn!pe      <snipe@notforspam.fsnet.co.uk> 
 
My pet rock Gordon just is. 
 
Re: Amazingly, Usenet is now -less- searchable.
#257653
Author: Michael Baeuerle
Date: Mon, 19 May 2014 09:03
13 lines
2116 bytes
Sn!pe wrote:
> Michael Baeuerle wrote:
> > 
> > AFAIK Google honour "Archive" and "X-No-Archive" header fields.
> 
> I use XNA: Yes. When I last checked Google displayed my posts 
> for one week, then hid them, but they were still used in their 
> profile of my posts.

flnews 0.7 will have support for "Archive" (like in this article).


Micha
Re: [JR] I prefer raw UTF·8 over raw "encoded words".
#257654
Author: Shmuel Metz
Date: Mon, 19 May 2014 15:55
15 lines
2557 bytes
In <20140515163447.48794605@sepulchrave.remarqs>, on 05/15/2014
   at 04:34 PM, »Q« <boxcars@gmx.net> said:

>Translation:  Relf intentionally breaks *all* of his messages

No! The correct translation is that Relf doesn't know what a BOM is.

-- 
Shmuel (Seymour J.) Metz, SysProg and JOAT  <http://patriot.net/~shmuel>

Unsolicited bulk E-mail subject to legal action.  I reserve the
right to publicly post or ridicule any abusive E-mail.  Reply to
domain Patriot dot net user shmuel+news to contact me.  Do not
reply to spamtrap@library.lspace.org
Re: I prefer raw UTF·8 over raw "encoded words".
#257655
Author: Shmuel Metz
Date: Mon, 19 May 2014 16:00
22 lines
2757 bytes
In <AABTdT6Y83UAAEau.A1.flnews@WStation4.micha.freeshell.org>, on
05/15/2014
   at 10:24 PM, Michael Baeuerle <michael.baeuerle@gmx.net> said:

>Jeff-Relf.Me wrote:
>> 
>> At various times and places, I read raw headers...
>> and I prefer raw UTF·8 over raw "encoded words".

>Bad idea in message headers.

The Devil is in the details. Of course, Relf never gets those right,
and I know of no equivalent of RFC 6531 for news..

-- 
Shmuel (Seymour J.) Metz, SysProg and JOAT  <http://patriot.net/~shmuel>

Unsolicited bulk E-mail subject to legal action.  I reserve the
right to publicly post or ridicule any abusive E-mail.  Reply to
domain Patriot dot net user shmuel+news to contact me.  Do not
reply to spamtrap@library.lspace.org
Re: I prefer raw UTF·8 over raw "encoded words".
#257656
Author: Michael Baeuerle
Date: Mon, 19 May 2014 16:35
21 lines
2311 bytes
Shmuel Metz wrote:
> Michael Baeuerle wrote:
> > Jeff-Relf.Me wrote:
> > > 
> > > At various times and places, I read raw headers...
> > > and I prefer raw UTF·8 over raw "encoded words".
> 
> > Bad idea in message headers.
> 
> The Devil is in the details. Of course, Relf never gets those right,
> and I know of no equivalent of RFC 6531 for news..

There may be an option to put the message/global content into a news
article with multipart/mixed type. It is allowed that such an article
contains only one part, but its even more complicated than the use of
RFC2047 (and more likely to be rejected by the server the same way as
HTML). And not to forget: It looks even more ugly if the receiver don't
have support for it.


Micha
Re: I prefer raw UTF·8 over raw "encoded words".
#257657
Author: Shmuel Metz
Date: Mon, 19 May 2014 23:13
19 lines
2790 bytes
In <AABTejLuQ3kAACG8.A1.flnews@WStation2.stz-e.de>, on 05/19/2014
   at 04:35 PM, Michael Baeuerle <michael.baeuerle@stz-e.de> said:

>There may be an option to put the message/global content into a 
>news article with multipart/mixed type.

That wouldn't be an equivalent to RFC 6531, which allows UTF-8 without
MIME encoding. Again, though, were the IETF to issue Usenet
equivalents of RFC6530, RFC6531, RFC6532 and RFC6533, I wouldn't
expect Relf to follow them. 

-- 
Shmuel (Seymour J.) Metz, SysProg and JOAT  <http://patriot.net/~shmuel>

Unsolicited bulk E-mail subject to legal action.  I reserve the
right to publicly post or ridicule any abusive E-mail.  Reply to
domain Patriot dot net user shmuel+news to contact me.  Do not
reply to spamtrap@library.lspace.org
Re: I prefer raw UTF·8 over raw "encoded words".
#257659
Author: Michael Bäuerle
Date: Wed, 21 May 2014 07:51
39 lines
3568 bytes
Shmuel Metz wrote:
> Michael Baeuerle wrote:
> > 
> > There may be an option to put the message/global content into a 
> > news article with multipart/mixed type.
> 
> That wouldn't be an equivalent to RFC 6531, which allows UTF-8 without
> MIME encoding. Again, though, were the IETF to issue Usenet
> equivalents of RFC6530, RFC6531, RFC6532 and RFC6533, I wouldn't
> expect Relf to follow them. 

IMHO the IETF should think twice about this topic. Netnews don't have
the problems created by the 7 Bit transport system, but it is obvious
that Unicode is not well suited for identifiers because the raw encoding
is ambigous by definition. Look at the header of this message that
contain my correctly written name in two "canonically equivalent", but
differently encoded representations. This means you have to normalize
every Unicode identifier before bytewise matching really work.

Think about Newsgroup names, Message-IDs, etc. in Unicode ... this is
hell on earth after looking at the really nontrivial normalization
algorithms of Unicode:
http://www.unicode.org/reports/tr15/
Note that there is a composition exclusion table too. Not all
compositions that are defined are really used for NFC normalization.

In addition, with Unicode in UTF-8 representation you need to check
anything for encoding validity in multiple levels. Windows programs
that are internally using UTF-16 tend to simply convert the codepoints
to UTF-8 and fail with codepoints above U+FFFF. I have tested this with
the G clef sign:
http://www.fileformat.info/info/unicode/char/1d11e/index.htm
Sending it as UTF-8 (0xF09D849E) give citations from Outlook and Dialog
containing UTF-16 surrogate code points that are invalid for UTF-8.
Therefore you have to check again for sematic errors, simply checking
the encoding is not sufficient.


Micha
Re: I prefer raw UTF·8 over raw "encoded words".
#257660
Author: Shmuel Metz
Date: Wed, 21 May 2014 21:34
49 lines
4197 bytes
In <AABTfFr7YfEAAAFB.A1.flnews@WStation2.stz-e.de>, on 05/21/2014
   at 07:51 AM, Michael Ba uerle <michael.baeuerle@stz-e.de> said:

>IMHO the IETF should think twice about this topic. Netnews don't 
>have the problems created by the 7 Bit transport system, but it 
>is obvious that Unicode is not well suited for identifiers because 
>the raw encoding is ambigous by definition.

It is certainly true that two distinct sequence of Unicode characters
may be equivalent, but UTF-8 itself is unambigous. Under what
cercumstances would someone key in or generate distinct but equivalent
Unicode sequences for, e.g., a mailbox, a message id?

>Think about Newsgroup names,

I would expect the news client to select the newsgroup from an
existing list.

>Message-IDs,

I would expect the news client to copy the message-id intact from
Message_is to References. I don't see what role normalization would
play.

>In addition, with Unicode in UTF-8 representation you need to 
>check anything for encoding validity in multiple levels.

Why?

>Windows programs that are internally using UTF-16 tend to simply 
>convert the codepoints to UTF-8 and fail with codepoints above 
>U+FFFF.

Then those programs are in error.

Besides, the disagreement wasn't over whether to use Unicode at all,
but rather how to represent it in Internet messages, more specifically
how to represent it in news articles. Using UTF-8 only with a protocol
that allows it is certainly no worse than what Relf wants to do, which
is to use UTF-8 with a protocol that does not allow it.

-- 
Shmuel (Seymour J.) Metz, SysProg and JOAT  <http://patriot.net/~shmuel>

Unsolicited bulk E-mail subject to legal action.  I reserve the
right to publicly post or ridicule any abusive E-mail.  Reply to
domain Patriot dot net user shmuel+news to contact me.  Do not
reply to spamtrap@library.lspace.org
Re: I prefer raw UTF·8 over raw "encoded words".
#257698
Author: Michael Baeuerle
Date: Thu, 22 May 2014 15:51
96 lines
5721 bytes
Shmuel Metz wrote:
> Michael Bäuerle wrote:
> > 
> > IMHO the IETF should think twice about this topic. Netnews don't 
> > have the problems created by the 7 Bit transport system, but it 
> > is obvious that Unicode is not well suited for identifiers because 
> > the raw encoding is ambigous by definition.
> 
> It is certainly true that two distinct sequence of Unicode characters
> may be equivalent, but UTF-8 itself is unambigous. Under what
> cercumstances would someone key in or generate distinct but equivalent
> Unicode sequences for, e.g., a mailbox, a message id?

It is the same problem as with Unicode filenames. Take a NFS server and
create a file with GNU/Linux on it over the network. Then take a Mac
and do the same (in the same directory). Now it's likely that you have
two files with the same name in this directory (because the common
normalization form is different on these 2 systems).

> > Think about Newsgroup names,
> 
> I would expect the news client to select the newsgroup from an
> existing list.

The problem start if you try to search the list (and maybe not
find existing groups even if you correctly typed in the name).
 
> > Message-IDs,
> 
> I would expect the news client to copy the message-id intact from
> Message_is to References. I don't see what role normalization would
> play.

Again, you may want to search for a Message-ID and type the name
in an input field (think about Google in the good older days).
 
> > In addition, with Unicode in UTF-8 representation you need to 
> > check anything for encoding validity in multiple levels.
> 
> Why?

Level one is the transformation format ("UTF"). There are invalid codes
or code sequences for all newer versions like UTF-8, UTF-16 and UTF-32.

Level two is the semantical meaning. An example are the surrogate
codepoints that are invalid for UTF-8 and UTF-32 (and even for UTF-16
if not used in the defined way):
https://en.wikipedia.org/wiki/Surrogate_pair
Another aspect of level two are forbidden codepoints (the ones above
U+10FFFF) that *can* be encoded with UTF-8 and UTF-32 (but not with
UTF-16).

Level three is the ordering of the codepoints. Some glyphs are canonical
compositions of multiple codepoints (more than two as in my example with
the decomposed "ä"). Because the number is not limited by the Unicode
standard, there may exist an unlimited number of non-canonical orders
for the components of results that *are* canonically equivalent. This is
the area where normalization comes into play.

A good example is this greek glyph:
http://www.fileformat.info/info/unicode/char/1f85/index.htm
with 6 canonically equivalent representations:
U+1F85 (NFC)
U+1F05 U+345
U+1F01 U+301 U+345
U+03B1 U+314 U+301 U+345 (NFD)
U+03B1 U+345 U+314 U+301
U+03B1 U+314 U+345 U+301

Text with mixed representations may easily result from operations like
cut & pase from different sources or manual input.

> > Windows programs that are internally using UTF-16 tend to simply 
> > convert the codepoints to UTF-8 and fail with codepoints above 
> > U+FFFF.
> 
> Then those programs are in error.

Yes, but because it's so hard to implement Unicode correctly, most
if not all programs are more or less broken when handling it.

> Besides, the disagreement wasn't over whether to use Unicode at all,
> but rather how to represent it in Internet messages, more specifically
> how to represent it in news articles. Using UTF-8 only with a protocol
> that allows it is certainly no worse than what Relf wants to do, which
> is to use UTF-8 with a protocol that does not allow it.

Full acknowledge. If it was defined correctly and anybody comply with
that definition it will surely work.

My question was: How likely will this be?
Maybe things are not much better than with MIME at the end (most things
are well defined but it's not easy to implement correctly).


Micha
--
#257716
Author: Jeff-Relf.Me
Date: Fri, 23 May 2014 00:26
18 lines
1807 bytes
When posting plain·text tables and/or indented code/text
to CraigsList, Usenet, Wikipedia and/or help forums...
HTML's <PRE> tag is a ·good· idea.

Disagree with me, if you want... it's your loss, not mine.

I play to mainstream clients, like Mozilla Thunderbird,
gmail, Google Groups, Windows Live Mail, etc.

RFC's say ·nothing· about how to read HTML and/or UTF·8.

That's their problem, not mine.
If your newsreader isn't mainstream...
I may, or may not, dumb it down for you.

Raw UTF·8 ( not encoded ) works in the "Subject:" line,
and it's easier to read raw ( compared to encoded words );
that's why I use it.
Re: I prefer raw UTF·8 over raw "encoded words".
#257717
Author: Shmuel Metz
Date: Fri, 23 May 2014 16:10
49 lines
3823 bytes
In <AABTfh0HF+UAAAbo.A1.flnews@WStation1.micha.freeshell.org>, on
05/22/2014
   at 03:51 PM, Michael Baeuerle <michael.baeuerle@gmx.net> said:

>It is the same problem as with Unicode filenames. Take a NFS server
>and create a file with GNU/Linux on it over the network. Then take 
>a Mac and do the same (in the same directory).

With the same name or with different names?

>(because the common normalization form is different on these 2 
>systems).

Do they normalize names? 

>Again, you may want to search for a Message-ID and type

Do people do that instead of cut-and-paste? That seems error prone
even in ASCII.

>(think about Google in the good older days).

See above.

>Level one is the transformation format ("UTF"). There are invalid
>codes or code sequences for all newer versions like UTF-8, UTF-16
>and UTF-32.

There are certainly octet sequences that are not valid UTF-8, but the
transformation from valid Unicode to UTF-8 is 1-1.

>Text with mixed representations

The issues in text are different from the issues in the header, where
identifiers are normally generated or copied. Also, are there cases
where normalization form NFC is ambiguous?

>Maybe things are not much better than with MIME

How is raw UTF-8 worse than MIME encoded UTF-8?

-- 
Shmuel (Seymour J.) Metz, SysProg and JOAT  <http://patriot.net/~shmuel>

Unsolicited bulk E-mail subject to legal action.  I reserve the
right to publicly post or ridicule any abusive E-mail.  Reply to
domain Patriot dot net user shmuel+news to contact me.  Do not
reply to spamtrap@library.lspace.org
Re: I prefer raw UTF·8 over raw "encoded words".
#257752
Author: Michael Baeuerle
Date: Sun, 25 May 2014 09:45
74 lines
4595 bytes
Shmuel Metz wrote:
> Michael Baeuerle wrote:
> > 
> > It is the same problem as with Unicode filenames. Take a NFS server
> > and create a file with GNU/Linux on it over the network. Then take 
> > a Mac and do the same (in the same directory).
> 
> With the same name or with different names?

The same name as types on the keyboard or cut&paste (but with potential
different, but canonically equivalent representation in the filesystem).

> > (because the common normalization form is different on these 2 
> > systems).
> 
> Do they normalize names?

On GNU/Linux systems there is normally no normalization at all. Names
are bytestreams and are handled "as is". There are good chances that you
have precomposed data here because things like "ä" (with an own key on
the german keyboard) are stored in the ISO8859-1 equivalent
representation.

The VFS API on MacOS X use the NFD normalization as default:
https://developer.apple.com/qa/qa2001/qa1173.html

The NFS network protocol has no normalization rules.
(but the local filesystems of the server may have them again).

> > Again, you may want to search for a Message-ID and type
> 
> Do people do that instead of cut-and-paste? That seems error prone
> even in ASCII.

With cut&paste the same problem can occur (if some normalization was
applied before displaying the text). Note that it is allowed for
every layer to normalize because the representations are canonically
equivalent in the sense of Unicode.

> > Level one is the transformation format ("UTF"). There are invalid
> > codes or code sequences for all newer versions like UTF-8, UTF-16
> > and UTF-32.
> 
> There are certainly octet sequences that are not valid UTF-8, but the
> transformation from valid Unicode to UTF-8 is 1-1.

A more precise definition of what "Unicode" means is required here.

One thing is not the case:
Not every codepoint sequence that is valid in UTF-16 representation is
also a valid codepoint sequence in UTF-8 representation: The surrogate
codepoint pairs must be converted to the corresponding target
codepoints first to be valid again.

> > Text with mixed representations
> 
> The issues in text are different from the issues in the header, where
> identifiers are normally generated or copied. Also, are there cases
> where normalization form NFC is ambiguous?

No, the standard normalization forms are unambigous.

But a news server don't want to normalize every header itself before
processing it (because of performance reasons).
 
> > Maybe things are not much better than with MIME
> 
> How is raw UTF-8 worse than MIME encoded UTF-8?

It's not worse. But it's not better than MIME encoded ISO8859 too
(in the sense of being easier to handle).


Micha
Re: I prefer raw UTF·8 over raw "encoded words".
#257733
Author: Shmuel Metz
Date: Sun, 25 May 2014 14:57
36 lines
3973 bytes
In <AABTgbui+zwAAAIC.A1.flnews@WStation1.micha.freeshell.org>, on
05/25/2014
   at 09:45 AM, Michael Baeuerle <michael.baeuerle@gmx.net> said:

>A more precise definition of what "Unicode" means is required here.

Sequences of 32-bit codepoints defined by the Unicode consrtium as
valid Unicode.

>One thing is not the case:
>Not every codepoint sequence that is valid in UTF-16 representation
>is also a valid codepoint sequence in UTF-8 representation:

If you mean that not every valid UTF-16 octet sequence is not a valid
UTF-8 octet sequence, I don't see how that is relevant. If you mean
that surrogate pairs in UTF-8 are transforms of Unicode characters
rather than Unicode characters themselves, that's inherent in the
definition of a transform. If you mean that UCS-2 and UTF-16 are
different, I don't see how that is relevant.

>But a news server don't want to normalize every header itself 
>before processing it (because of performance reasons).

What the mail people did was to require that specific fields be
normalized in the original message; after that it's just a question of
not renormalizing.


-- 
Shmuel (Seymour J.) Metz, SysProg and JOAT  <http://patriot.net/~shmuel>

Unsolicited bulk E-mail subject to legal action.  I reserve the
right to publicly post or ridicule any abusive E-mail.  Reply to
domain Patriot dot net user shmuel+news to contact me.  Do not
reply to spamtrap@library.lspace.org
Unicode G clef: 𝄞 (was: I prefer raw UTF·8 over raw "encoded words".)
#257751
Author: Michael Baeuerle
Date: Mon, 26 May 2014 08:06
46 lines
3626 bytes
Shmuel Metz wrote:
> Michael Baeuerle wrote:
> > 
> > A more precise definition of what "Unicode" means is required here.
> 
> Sequences of 32-bit codepoints defined by the Unicode consrtium as
> valid Unicode.
> 
> > One thing is not the case:
> > Not every codepoint sequence that is valid in UTF-16 representation
> > is also a valid codepoint sequence in UTF-8 representation:
> 
> [...] If you mean
> that surrogate pairs in UTF-8 are transforms of Unicode characters
> rather than Unicode characters themselves, that's inherent in the
> definition of a transform. [...]

I mean that it is not allowed to simply convert the codepoints
(UTF-16 surrogate pairs use valid Unicode codepoints) to another UTF
in all cases.

Yes, this is inherent to the definition of a transform, but it's widely
implemented wrong. Newsreaders like Outlook Express and Dialog cripple
replies to correct UTF-8 content containing codepoints above U+FFFF by
using UTF-8 encoded surrogate codepoints.

Step 1: Valid UTF
Step 2: Valid codepoints
Step 3: Normalization

Looks like many programs don't even process to Step 2. I have added
U+1D11E (G clef) to the subject. If somebody use Outlook Express or,
Dialog please reply for demonstration.

> > But a news server don't want to normalize every header itself 
> > before processing it (because of performance reasons).
> 
> What the mail people did was to require that specific fields be
> normalized in the original message; after that it's just a question of
> not renormalizing.

Some clients seem to have no Unicode normalization engine at all.
Therefore I predict that this will not be done in all cases.


Micha
Re: Unicode G clef: ­Øä× (was: I prefer raw UTF·8 over raw "encoded words".)
#257756
Author: Shmuel Metz
Date: Mon, 26 May 2014 16:28
20 lines
3213 bytes
In <AABTgvX5CpQAAAVK.A1.flnews@WStation2.stz-e.de>, on 05/26/2014
   at 08:06 AM, Michael Baeuerle <michael.baeuerle@stz-e.de> said:

>Some clients seem to have no Unicode normalization engine at all.

Do any of them claim support for RFC 6530-6533?

>Therefore I predict that this will not be done in all cases.

My take is that anybody adding code to recognize the SMTPUTF8
extension is likely to read the defining RFCs.

-- 
Shmuel (Seymour J.) Metz, SysProg and JOAT  <http://patriot.net/~shmuel>

Unsolicited bulk E-mail subject to legal action.  I reserve the
right to publicly post or ridicule any abusive E-mail.  Reply to
domain Patriot dot net user shmuel+news to contact me.  Do not
reply to spamtrap@library.lspace.org
Re: Unicode G clef: 𝄞
#257757
Author: Michael Baeuerle
Date: Mon, 26 May 2014 20:19
23 lines
2637 bytes
Shmuel Metz wrote:
> Michael Baeuerle wrote:
> > 
> > Some clients seem to have no Unicode normalization engine at all.
> 
> Do any of them claim support for RFC 6530-6533?

I don't know. But RFC5198 specify general rules for text based protocols
that use Unicode too.

> > Therefore I predict that this will not be done in all cases.
> 
> My take is that anybody adding code to recognize the SMTPUTF8
> extension is likely to read the defining RFCs.

Yes, but not necessarily implement them as intended ...

BTW: The G clef was broken:
|
| Subject: Re: Unicode G clef: =?ISO-8859-15?Q?=AD=D8=E4=D7?=


Micha
Re: Unicode G clef: ­Øä×
#257759
Author: Shmuel Metz
Date: Tue, 27 May 2014 12:17
22 lines
3234 bytes
In <AABTg6HPaOQAAAHs.A1.flnews@WStation1.micha.freeshell.org>, on
05/26/2014
   at 08:19 PM, Michael Baeuerle <michael.baeuerle@gmx.net> said:

>I don't know. But RFC5198 specify general rules for text based
>protocols that use Unicode too.

New and updated protocols, not old ones.

>BTW: The G clef was broken:

Alas, my mail/news client only has partial suppoert for UTF-8. That's
why I use ISO-8859-15.

-- 
Shmuel (Seymour J.) Metz, SysProg and JOAT  <http://patriot.net/~shmuel>

Unsolicited bulk E-mail subject to legal action.  I reserve the
right to publicly post or ridicule any abusive E-mail.  Reply to
domain Patriot dot net user shmuel+news to contact me.  Do not
reply to spamtrap@library.lspace.org
--
#257758
Author: Jeff-Relf.Me
Date: Tue, 27 May 2014 13:23
11 lines
1641 bytes
You need a special font to display "Unicode G clef".

Few, if any (here), have it on their PC.

Unless you're talking to a super·select group of people,
people who have installed certain, select fonts,
you shouldn't concern yourself with UTF·16 surrogate pairs.

Ask yourself: What does my audience have/need ?

For me, the answer is: Simple HTML and Simple Unicode.
Re: Unicode G clef: 𝄞
#257866
Author: tlvp
Date: Sun, 08 Jun 2014 02:09
56 lines
4316 bytes
On 26 May 2014 08:06:17 -0000, Michael Baeuerle wrote:

> Shmuel Metz wrote:
>> Michael Baeuerle wrote:
>>> 
>>> A more precise definition of what "Unicode" means is required here.
>> 
>> Sequences of 32-bit codepoints defined by the Unicode consrtium as
>> valid Unicode.
>> 
>>> One thing is not the case:
>>> Not every codepoint sequence that is valid in UTF-16 representation
>>> is also a valid codepoint sequence in UTF-8 representation:
>> 
>> [...] If you mean
>> that surrogate pairs in UTF-8 are transforms of Unicode characters
>> rather than Unicode characters themselves, that's inherent in the
>> definition of a transform. [...]
> 
> I mean that it is not allowed to simply convert the codepoints
> (UTF-16 surrogate pairs use valid Unicode codepoints) to another UTF
> in all cases.
> 
> Yes, this is inherent to the definition of a transform, but it's widely
> implemented wrong. Newsreaders like Outlook Express and Dialog cripple
> replies to correct UTF-8 content containing codepoints above U+FFFF by
> using UTF-8 encoded surrogate codepoints.
> 
> Step 1: Valid UTF
> Step 2: Valid codepoints
> Step 3: Normalization
> 
> Looks like many programs don't even process to Step 2. I have added
> U+1D11E (G clef) to the subject. If somebody use Outlook Express or,
> Dialog please reply for demonstration.

This reply is coming to you via 40tude Dialog (which evidently failed to
render any G clef from the outset, so it'd surprise me to find if there
were a recognizable G clef anywhere in this reply :-) ) .
 
>>> But a news server don't want to normalize every header itself 
>>> before processing it (because of performance reasons).
>> 
>> What the mail people did was to require that specific fields be
>> normalized in the original message; after that it's just a question of
>> not renormalizing.
> 
> Some clients seem to have no Unicode normalization engine at all.
> Therefore I predict that this will not be done in all cases.
> 
> 
> Micha

HTH. Cheers, -- tlvp
-- 
Avant de repondre, jeter la poubelle, SVP.
Re: Unicode G clef: 𝄞
#257873
Author: Michael Baeuerle
Date: Tue, 10 Jun 2014 09:07
72 lines
4990 bytes
tlvp wrote:
> Michael Baeuerle wrote:
> > Shmuel Metz wrote:
> > > Michael Baeuerle wrote:
> > > > 
> > > > A more precise definition of what "Unicode" means is required here.
> > > 
> > > Sequences of 32-bit codepoints defined by the Unicode consrtium as
> > > valid Unicode.
> > > 
> > > > One thing is not the case:
> > > > Not every codepoint sequence that is valid in UTF-16 representation
> > > > is also a valid codepoint sequence in UTF-8 representation:
> > > 
> > > [...] If you mean
> > > that surrogate pairs in UTF-8 are transforms of Unicode characters
> > > rather than Unicode characters themselves, that's inherent in the
> > > definition of a transform. [...]
> > 
> > I mean that it is not allowed to simply convert the codepoints
> > (UTF-16 surrogate pairs use valid Unicode codepoints) to another UTF
> > in all cases.
> > 
> > Yes, this is inherent to the definition of a transform, but it's widely
> > implemented wrong. Newsreaders like Outlook Express and Dialog cripple
> > replies to correct UTF-8 content containing codepoints above U+FFFF by
> > using UTF-8 encoded surrogate codepoints.
> > 
> > Step 1: Valid UTF
> > Step 2: Valid codepoints
> > Step 3: Normalization
> > 
> > Looks like many programs don't even process to Step 2. I have added
> > U+1D11E (G clef) to the subject. If somebody use Outlook Express or,
> > Dialog please reply for demonstration.
> 
> This reply is coming to you via 40tude Dialog (which evidently failed to
> render any G clef from the outset, so it'd surprise me to find if there
> were a recognizable G clef anywhere in this reply :-) ) .

Result:
| 
| Subject: Re: Unicode G =?utf-8?Q?clef=3A_=ED=A0=B4=ED=B4=9E?=
                                       ^^^^
                                  Colon + Space

The rest of the data are the following two UTF-8 sequences (In a 3-byte
sequence 4 LSBs from the first byte and 6 LSBs from the continuation
bytes respectively are used as payload):

UTF-8       Codepoint
====================================
0xEDA0B4 => U+D834 => High surrogate
0xEDB49E => U+DD1E => Low surrogate

This is a UTF-16 surrogate pair (representing U+1D11E - the G clef - in
UTF-16, and only in UTF-16!):
http://www.fileformat.info/info/unicode/char/1D11E/index.htm
This is exactly the case I had described above. Surrogate codepoints
are invalid for all other transformation formats (including UTF-8).

Looks like Dialog use UTF-16 representation internally (or UCS-2 because
it can't display the surrogate pair). In any case the conversion back
to UTF-8 is invalid. The surrogate pair must be combined to the real
codepoint U+1D11E first and then UTF-8 encoded to 0xF09D849E.

I guess the reason is an old Windows conversion function that can only
handle UCS-2 and not UTF-16 (older versions of Windows had used UCS-2
representation for Unicode internally).


Micha
Re: Unicode G clef: 𝄞
#257876
Author: tlvp
Date: Wed, 11 Jun 2014 04:56
78 lines
5505 bytes
On 10 Jun 2014 09:07:37 -0000, Michael Baeuerle wrote:

> tlvp wrote:
>> Michael Baeuerle wrote:
>>> Shmuel Metz wrote:
>>> > Michael Baeuerle wrote:
>>> > > 
>>> > > A more precise definition of what "Unicode" means is required here.
>>> > 
>>> > Sequences of 32-bit codepoints defined by the Unicode consrtium as
>>> > valid Unicode.
>>> > 
>>> > > One thing is not the case:
>>> > > Not every codepoint sequence that is valid in UTF-16 representation
>>> > > is also a valid codepoint sequence in UTF-8 representation:
>>> > 
>>> > [...] If you mean
>>> > that surrogate pairs in UTF-8 are transforms of Unicode characters
>>> > rather than Unicode characters themselves, that's inherent in the
>>> > definition of a transform. [...]
>>> 
>>> I mean that it is not allowed to simply convert the codepoints
>>> (UTF-16 surrogate pairs use valid Unicode codepoints) to another UTF
>>> in all cases.
>>> 
>>> Yes, this is inherent to the definition of a transform, but it's widely
>>> implemented wrong. Newsreaders like Outlook Express and Dialog cripple
>>> replies to correct UTF-8 content containing codepoints above U+FFFF by
>>> using UTF-8 encoded surrogate codepoints.
>>> 
>>> Step 1: Valid UTF
>>> Step 2: Valid codepoints
>>> Step 3: Normalization
>>> 
>>> Looks like many programs don't even process to Step 2. I have added
>>> U+1D11E (G clef) to the subject. If somebody use Outlook Express or,
>>> Dialog please reply for demonstration.
>> 
>> This reply is coming to you via 40tude Dialog (which evidently failed to
>> render any G clef from the outset, so it'd surprise me to find if there
>> were a recognizable G clef anywhere in this reply :-) ) .
> 
> Result:
>| 
>| Subject: Re: Unicode G =?utf-8?Q?clef=3A_=ED=A0=B4=ED=B4=9E?=
>                                        ^^^^
>                                   Colon + Space
> 
> The rest of the data are the following two UTF-8 sequences (In a 3-byte
> sequence 4 LSBs from the first byte and 6 LSBs from the continuation
> bytes respectively are used as payload):
> 
> UTF-8       Codepoint
> ====================================
> 0xEDA0B4 => U+D834 => High surrogate
> 0xEDB49E => U+DD1E => Low surrogate
> 
> This is a UTF-16 surrogate pair (representing U+1D11E - the G clef - in
> UTF-16, and only in UTF-16!):
> http://www.fileformat.info/info/unicode/char/1D11E/index.htm
> This is exactly the case I had described above. Surrogate codepoints
> are invalid for all other transformation formats (including UTF-8).
> 
> Looks like Dialog use UTF-16 representation internally (or UCS-2 because
> it can't display the surrogate pair). In any case the conversion back
> to UTF-8 is invalid. The surrogate pair must be combined to the real
> codepoint U+1D11E first and then UTF-8 encoded to 0xF09D849E.
> 
> I guess the reason is an old Windows conversion function that can only
> handle UCS-2 and not UTF-16 (older versions of Windows had used UCS-2
> representation for Unicode internally).
> 
> 
> Micha

Interesting, Micha -- thanks for that analysis. Cheers, -- tlvp
-- 
Avant de repondre, jeter la poubelle, SVP.
Re: Unicode G clef: ������
#257880
Author: coyo
Date: Thu, 12 Jun 2014 02:18
56 lines
4920 bytes
On 6/7/2014 9:09 PM, tlvp wrote:
> On 26 May 2014 08:06:17 -0000, Michael Baeuerle wrote:
> 
>> Shmuel Metz wrote:
>>> Michael Baeuerle wrote:
>>>>
>>>> A more precise definition of what "Unicode" means is required here.
>>>
>>> Sequences of 32-bit codepoints defined by the Unicode consrtium as
>>> valid Unicode.
>>>
>>>> One thing is not the case:
>>>> Not every codepoint sequence that is valid in UTF-16 representation
>>>> is also a valid codepoint sequence in UTF-8 representation:
>>>
>>> [...] If you mean
>>> that surrogate pairs in UTF-8 are transforms of Unicode characters
>>> rather than Unicode characters themselves, that's inherent in the
>>> definition of a transform. [...]
>>
>> I mean that it is not allowed to simply convert the codepoints
>> (UTF-16 surrogate pairs use valid Unicode codepoints) to another UTF
>> in all cases.
>>
>> Yes, this is inherent to the definition of a transform, but it's widely
>> implemented wrong. Newsreaders like Outlook Express and Dialog cripple
>> replies to correct UTF-8 content containing codepoints above U+FFFF by
>> using UTF-8 encoded surrogate codepoints.
>>
>> Step 1: Valid UTF
>> Step 2: Valid codepoints
>> Step 3: Normalization
>>
>> Looks like many programs don't even process to Step 2. I have added
>> U+1D11E (G clef) to the subject. If somebody use Outlook Express or,
>> Dialog please reply for demonstration.
> 
> This reply is coming to you via 40tude Dialog (which evidently failed to
> render any G clef from the outset, so it'd surprise me to find if there
> were a recognizable G clef anywhere in this reply :-) ) .
>  
>>>> But a news server don't want to normalize every header itself 
>>>> before processing it (because of performance reasons).
>>>
>>> What the mail people did was to require that specific fields be
>>> normalized in the original message; after that it's just a question of
>>> not renormalizing.
>>
>> Some clients seem to have no Unicode normalization engine at all.
>> Therefore I predict that this will not be done in all cases.

I still say everyone should use UTF-32 instead of UTF-8. There is no
kill like overkill, and four bytes per character isn't that bad.
Besides, imagine how much more efficient Base64 encoding would be if you
could use Unicode codepoints with a full static codepoint-to-byte mapping?
--
#257877
Author: Jeff-Relf.Me
Date: Thu, 12 Jun 2014 07:13
50 lines
3733 bytes
<PRE Style='White-Space: PRE !important; Font-Size: 18px !important;Font-Family: monospace !important;'> 
@coyo,  You wrote:
> I still say everyone should use UTF-32 instead of UTF-8. 

UTF·32 has few advantages, I think.
Few have the fonts for it... very few.

> imagine how much more efficient Base64 encoding would be 
> if you could use Unicode codepoints with 
> a full static codepoint-to-byte mapping?

I use Base·360.

Note, however, I do it for the shorter strings,
on the display... it doesn't save diskspace.

>From &lt;http://Jeff-Relf.Me/X.CPP>:

  const wchar_t Digits[] = //  In code·point order, for binary search.
    L"0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz"
    L"ȴȵȶȷȸȹȺȻȼȽȾȿɀɁɄɅɌɍɐɑɒɓɔɕɖɗɘəɚɛɜɝɞɟɠɡɢɣɤɥɦɧɨɩɪɫɬɭɮɯɰɱɲɳɴɵɶɷɸɹɺɻɼɽɾɿʀʁʂ"
    L"ʃʄʅʆʇʈʉʊʋʌʍʎʏʐʑʒʓʔʕʖʗʘʙʚʛʜʝʞʟʠʡʢʣʤʥʦʧʨʩʪʫʬʭʮʯ"

    L"ΑΒΓΔΕΖΗΘΙΚΛΜΝΞΟΠΡΣΤΥΦΧΨΩαβγδεζηθικλμνξοπρςστυφχψω"
    L"ϐϑϒϓϕϖϗϘϙϚϛϜϝϞϟϠϡϰϱϲϳϴϵ϶ϷϸϹϺϻϼϽϾϿ"

    L"АБВГДЕЖЗИЙКЛМНОПРСТУФХЦЧШЩЪЫЬЭЮЯабвгдежзийклмнопрстуфхцчшщъыьэюя"
    L"აბგდევზთიკლმნოპჟრსტუფქღყშჩცძწჭხჯჰჱჲჳჴჵ";
  const uint Base·360 = ( sizeof Digits - 1 ) / szChr ;
  const int  mxDigits = 9 ;  //  ln(2^64)/ln(360) + 2 = 

  LnP u64·toBase·360( u64 N ) { int K ;  

    static wchar_t Uni [ mxDigits + 1 ];  LnP  Left = Uni + mxDigits ;  *Left = 0 ;
    
    do { K = N % Base·360, N /= Base·360, *--Left = Digits[ K ];  } while( N );
    return  Left ;  }

  float Base·360·To·DaysAgo( LnP B·Num·Ln ) {
    wchar_t Ch0, Ch, Ch2, Ch3 ;  u64 i = 0 ; 
   
    LnP  B0 = (LnP)Digits, p, E0 = B0 + Base·360, B·Num, B = B·Num·Ln, P, E = 0 ;
    WhileBac( Ch != L'·' && Ch != 32 );  
    if ( !Ch ) return 0 ;  B·Num = ++P ;
    While( Ch ) { p = B = B0, E = E0 ;
    
      Find:    if ( B >= E0 ) return 0 ;  p = B + ( E - B ) / 2, Ch3 = *p ;
      if ( Ch > Ch3 ) { if ( B = ++p, B > E ) return 0 ; goto Find ;  }
      if ( Ch < Ch3 ) { if ( E = --p, E < B ) return 0 ; goto Find ;  } 
      i *= Base·360, i += p - B0 ;  }  return gDaysAgo( i ) ;  }
Re: Unicode G clef: 𝄞
#257879
Author: Michael Baeuerle
Date: Thu, 12 Jun 2014 09:53
68 lines
4820 bytes
coyo wrote:
> tlvp wrote:
> > Michael Baeuerle wrote:
> > > Shmuel Metz wrote:
> > > > 
> > > > [...] If you mean
> > > > that surrogate pairs in UTF-8 are transforms of Unicode characters
> > > > rather than Unicode characters themselves, that's inherent in the
> > > > definition of a transform. [...]
> > > 
> > > I mean that it is not allowed to simply convert the codepoints
> > > (UTF-16 surrogate pairs use valid Unicode codepoints) to another UTF
> > > in all cases.
> > > 
> > > Yes, this is inherent to the definition of a transform, but it's widely
> > > implemented wrong. Newsreaders like Outlook Express and Dialog cripple
> > > replies to correct UTF-8 content containing codepoints above U+FFFF by
> > > using UTF-8 encoded surrogate codepoints.
> > > [...]
> > 
> > This reply is coming to you via 40tude Dialog (which evidently failed to
> > render any G clef from the outset, so it'd surprise me to find if there
> > were a recognizable G clef anywhere in this reply :-) ) .
> >
> > > [Normalization stuff]
> 
> I still say everyone should use UTF-32 instead of UTF-8. There is no
> kill like overkill, and four bytes per character isn't that bad.

For latin based languages it would be really bad.

> Besides, imagine how much more efficient Base64 encoding would be if you
> could use Unicode codepoints with a full static codepoint-to-byte mapping?

This will only eliminate the code sequences of the UTF-8 and UTF-16
transfer encodings and the problem that they can be invalid.

All the other complex Unicode stuff will always stay with you:
- Invalid codepoints
  Not every representable codepoint is mapped in Unicode
  (but it may become mapped in the future).
  Some mapped codepoints are only valid for the UTF-16 transfer encoding
  (this is like Dialog breaks the subject here).
- Normalization
  Many glyphs are compositions of multiple codepoints and there can be
  multiple "canonically equivalent" representations of a glyph.

The possibility for canonical equivalence of different codepoint
sequences is a fundamental Unicode property. You can't work around
it regardless of what transfer encoding you use (or newly invent).


Your Thunderbird have done this with the subject:
| 
| Subject: Re: Unicode G clef: =?UTF-8?B?77+977+977+977+977+977+9?=

Decode base64 and print as hexadecimal bytes:
| 
| $ printf "77+977+977+977+977+977+9" | base64 -d | hexdump -e '18/1 "%02X ""\n"'
| EF BF BD EF BF BD EF BF BD EF BF BD EF BF BD EF BF BD
  ^^^^^^^^
The UTF-8 sequence 0xEFBFBD decodes to the Unicode codepoint U+FFFD:
http://www.fileformat.info/info/unicode/char/fffd/index.htm

Result: 6 replacement characters instead of a G clef.


Micha
Re: UTF·32 has few advantages, I think.
#257878
Author: Michael Baeuerle
Date: Thu, 12 Jun 2014 10:55
19 lines
2212 bytes
Jeff-Relf.Me wrote:
> coyo wrote:
> > 
> > I still say everyone should use UTF-32 instead of UTF-8. 
> 
> UTF·32 has few advantages, I think.
> Few have the fonts for it... very few.

You mean the glyph population of the fonts.
The transformation format itself has nothing to do with this. If the
font has a glyph for the Unicode codepoint sequence, this codepoint
sequence can be represented with every official transformation format
(UTF-8, UTF-16, UTF-32). If there is no glyph, it obviously can't be
printed in any case.

Only the obsolete UCS-2 transformation format is limited here.


Micha
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads