Show
Ignore:
Timestamp:
04/29/08 00:11:30 (5 years ago)
Author:
tokuhirom
Message:

hmm... hexcref is SJIS in AirHPhone.

Location:
lang/perl/HTML-ReplacePictogramMobileJp/trunk
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • lang/perl/HTML-ReplacePictogramMobileJp/trunk/lib/HTML/ReplacePictogramMobileJp/AirHPhone.pm

    r4899 r10695  
    33use warnings; 
    44use HTML::ReplacePictogramMobileJp::Base; 
     5use Encode; 
     6use Encode::JP::Mobile; 
    57 
    68filter utf8 => 'utf-8', sub { 
     
    1012filter sjis => 'x-sjis-airh', sub { 
    1113    unicode_property 'I'; 
    12     unicode_hex_cref 'I'; 
     14 
     15    # sjis hex cref 
     16    s/&#x([0-9A-F]{4});/ 
     17        callback(ord(decode 'x-sjis-docomo', pack 'H*', sprintf '%X', hex $1), 'I'); 
     18    /gei; 
    1319}; 
    1420 
  • lang/perl/HTML-ReplacePictogramMobileJp/trunk/t/01_simple.t

    r10678 r10695  
    2525is _x('V', 'utf8', "&#xE537;"), "<U+E537> V", 'softbank-utf8-hex-cref'; 
    2626 
    27 is _x('H', 'utf8', "&#xE757;"), "<U+E757> I", 'airh sjis hex cref'; 
    28 is _x('H', 'sjis', "&#xE757;"), "<U+E757> I", 'airh sjis hex cref'; 
     27is _x('H', 'utf8', "&#xE757;"), "<U+E757> I", 'airh utf8 hex cref'; 
     28is _x('H', 'sjis', "&#xF8A0;"), "<U+E63F> I", 'airh sjis hex cref'; 
    2929is _x('H', 'sjis', "\xf9\xfc"), "<U+E757> I", 'airh sjis binary'; 
    3030