xref: /openbsd-src/gnu/usr.bin/perl/cpan/Encode/KR/KR.pm (revision b39c515898423c8d899e35282f4b395f7cad3298)
1package Encode::KR;
2BEGIN {
3    if ( ord("A") == 193 ) {
4        die "Encode::KR not supported on EBCDIC\n";
5    }
6}
7use strict;
8use warnings;
9use Encode;
10our $VERSION = do { my @r = ( q$Revision: 2.3 $ =~ /\d+/g ); sprintf "%d." . "%02d" x $#r, @r };
11use XSLoader;
12XSLoader::load( __PACKAGE__, $VERSION );
13
14use Encode::KR::2022_KR;
15
161;
17__END__
18
19=head1 NAME
20
21Encode::KR - Korean Encodings
22
23=head1 SYNOPSIS
24
25    use Encode qw/encode decode/;
26    $euc_kr = encode("euc-kr", $utf8);   # loads Encode::KR implicitly
27    $utf8   = decode("euc-kr", $euc_kr); # ditto
28
29=head1 DESCRIPTION
30
31This module implements Korean charset encodings.  Encodings supported
32are as follows.
33
34
35  Canonical   Alias		Description
36  --------------------------------------------------------------------
37  euc-kr      /\beuc.*kr$/i	EUC (Extended Unix Character)
38          /\bkr.*euc$/i
39  ksc5601-raw			Korean standard code set (as is)
40  cp949	      /(?:x-)?uhc$/i
41              /(?:x-)?windows-949$/i
42              /\bks_c_5601-1987$/i
43                                Code Page 949 (EUC-KR + 8,822
44                                (additional Hangul syllables)
45  MacKorean			EUC-KR + Apple Vendor Mappings
46  johab       JOHAB             A supplementary encoding defined in
47                                             Annex 3 of KS X 1001:1998
48  iso-2022-kr                   iso-2022-kr                  [RFC1557]
49  --------------------------------------------------------------------
50
51To find how to use this module in detail, see L<Encode>.
52
53=head1 BUGS
54
55When you see C<charset=ks_c_5601-1987> on mails and web pages, they really
56mean "cp949" encodings.  To fix that, the following aliases are set;
57
58  qr/(?:x-)?uhc$/i         => '"cp949"'
59  qr/(?:x-)?windows-949$/i => '"cp949"'
60  qr/ks_c_5601-1987$/i     => '"cp949"'
61
62The ASCII region (0x00-0x7f) is preserved for all encodings, even
63though this conflicts with mappings by the Unicode Consortium.
64
65=head1 SEE ALSO
66
67L<Encode>
68
69=cut
70