dcdev mailing list

Direct Connect developers, 2003 to 2005
← All threads

UTF-8 Chat for NMDC Hubs

6 messages · Todd Pederzani, Fredrik Tolf, John Bäckstrand, Jernej SimonÄ�iÄ�
10 September 2004, 02:46Todd Pederzani <[email protected]>

If UTF-8 encoded text is sent to a hub for chat (or otherwise used in
$MyINFO) whose software will support it?  Whose software will break?

 - Todd
--
19 September 2004, 02:10Fredrik Tolf <[email protected]>
to Direct Connect developers

On Sun, 2004-09-19 at 11:33 +0200, Jernej Simon�i� wrote:
> On Sunday, September 19, 2004, 3:55:10, Fredrik Tolf wrote:
> 
> > As an alternative, have you considered using SGML entities (hexadecimal
> > encodings, that is, not the entire readable library)? Some other
> > programs seem to already be using it for things like dollar signs and
> > the like, so it may be a good idea to go on using it.
> 
> Wouldn't that take too much space - at least 5 bytes per character?

Well, only for non-CP1252 characters. I can agree that UTF-8 would be
better - I was just thinking that since some programs are already using
SGML entities it would be quite nice not to create yet another way of
chatting. It's not really a bad problem until everyone starts chatting
in Japanese, and even then, it doesn't seem to me that chatting would be
the greatest bandwidth consumer.

In any case, though - I'd be pleased to see UTF-8 chatting, so please do
go ahead with that, but please indicate UTF-8 chat messages in some way.

Fredrik Tolf


--
19 September 2004, 02:41John Bäckstrand <[email protected]>
to Todd Pederzani <[email protected]>, Direct Connect developers <[email protected]>
Todd Pederzani wrote:

If UTF-8 encoded text is sent to a hub for chat (or otherwise used in
$MyINFO) whose software will support it?  Whose software will break?

I think utf-8 should be kept out of NMDC-chat/myinfo, ADC is there for a reason. Suddenly we have transformed NMDC into ADC, and the protocol is one big kludge built ontop of NMDC.

---
John Bäckstrand
19 September 2004, 03:55Fredrik Tolf <[email protected]>
to Todd Pederzani <[email protected]>, Direct Connect developers <[email protected]>

On Fri, 2004-09-10 at 08:46 -0400, Todd Pederzani wrote:
> If UTF-8 encoded text is sent to a hub for chat (or otherwise used in
> $MyINFO) whose software will support it?  Whose software will break?

I doubt anyone's software will break, since Windows CP-1252, which is
the default DC encoding, decodes all bytes that UTF-8 uses. It will just
look ugly.

You may want to mark up those UTF-8 characters, though, so that a layer
of compatibility is maintained even if someone else wants to decode it.

As an alternative, have you considered using SGML entities (hexadecimal
encodings, that is, not the entire readable library)? Some other
programs seem to already be using it for things like dollar signs and
the like, so it may be a good idea to go on using it.

Fredrik Tolf


--
19 September 2004, 04:40Todd Pederzani <[email protected]>
to DCDevelopers

On Sun, 19 Sep 2004 14:41:03 +0200, John Bäckstrand <[email protected]> wrote:
> I think utf-8 should be kept out of NMDC-chat/myinfo, ADC is there for a
> reason. Suddenly we have transformed NMDC into ADC, and the protocol is
> one big kludge built ontop of NMDC.

Nice point.  Plus, at the time I asked, it wasn't apparent which way
DC++ would go (the big change in current CVS source is to use UTF-8
internally).  What it does currently is to translate the UTF-8
internals to the active code page when sending to a NMDC protocol hub
(and vice versa when receiving).  This should keep users from
countries such as China [1] happy.

- Todd

[1] http://www.hublist.org/?p=search&country=CN
--
19 September 2004, 11:33Jernej SimonÄ�iÄ� <[email protected]>
to "Fredrik Tolf on [dcdev]" <[email protected]>

On Sunday, September 19, 2004, 3:55:10, Fredrik Tolf wrote:

> As an alternative, have you considered using SGML entities (hexadecimal
> encodings, that is, not the entire readable library)? Some other
> programs seem to already be using it for things like dollar signs and
> the like, so it may be a good idea to go on using it.

Wouldn't that take too much space - at least 5 bytes per character?

-- 
< Jernej Simoncic ><><><><>< http://deepthought.ena.si/ >

Clearly stated instructions will consistently produce multiple interpretations.
       -- Boyle's Fourteenth Law

--