Skip Menu |

This queue is for tickets about the Encode CPAN distribution.

Report information
The Basics
Id: 20781
Status: resolved
Priority: 0/
Queue: Encode

People
Owner: Nobody in particular
Requestors: awkay69 [...] yahoo.com
Cc:
AdminCc:

Bug Information
Severity: Wishlist
Broken in: 2.18
Fixed in: (no value)



Subject: Thai encoding needs alias for tis-620
Some mail clients use tis-620 as an encoding name. The existing alias in Encode::Alias is tis620. It would be nice if there were an existing alias called tis-620 so programs would not have to set an extra alias.
AWKAY, Thank you for your suggestiion. Accepted and fixed as follows; Dan the Maintainer Thereof ========================================================= ========== RCS file: lib/Encode/Alias.pm,v retrieving revision 2.6 diff -u -r2.6 lib/Encode/Alias.pm --- lib/Encode/Alias.pm 2006/06/03 20:28:48 2.6 +++ lib/Encode/Alias.pm 2007/04/06 10:40:11 @@ -189,8 +189,9 @@ 'greek' => 'iso-8859-7', 'hebrew' => 'iso-8859-8', 'thai' => 'iso-8859-11', - 'tis620' => 'iso-8859-11', ); + # RT #20781 + define_alias(qr/\btis-?620\b/i => '"iso-8859-11"'); # At least AIX has IBM-NNN (surprisingly...) instead of cpNNN. # And Microsoft has their own naming (again, surprisingly). ========================================================= ========== RCS file: t/Aliases.t,v retrieving revision 2.2 diff -u -r2.2 t/Aliases.t --- t/Aliases.t 2006/05/03 18:24:10 2.2 +++ t/Aliases.t 2007/04/06 10:37:34 @@ -42,6 +42,7 @@ 'hebrew' => 'iso-8859-8', 'thai' => 'iso-8859-11', 'tis620' => 'iso-8859-11', + 'tis-620' => 'iso-8859-11', 'WinLatin1' => 'cp1252', 'WinLatin2' => 'cp1250', 'WinCyrillic' => 'cp1251', @@ -122,6 +123,7 @@ print "# alias test; \$ON_EBCDIC == $ON_EBCDIC\n"; foreach my $a (keys %a2c){ + print "# $a => $a2c{$a}\n"; my $e = Encode::find_encoding($a); is((defined($e) and $e->name), $a2c{$a},$a) or warn "alias was $a";; On Mon Jul 31 20:11:10 2006, AWKAY wrote: Show quoted text
> Some mail clients use tis-620 as an encoding name. The existing alias in > Encode::Alias is tis620. It would be nice if there were an existing > alias called tis-620 so programs would not have to set an extra alias.