3 This file is part of libmspstrings
4 Copyright © 2006-2007 Mikko Rasa
5 Distributed under the LGPL
14 void JisX0201::Encoder::encode_char(wchar_t c_)
16 // Win32 has typedef unsigned short wchar_t
18 if(c>=0 && c<=0x7F && c!=0x5C && c!=0x7E)
24 else if(c>=0xFF61 && c<=0xFF9F)
27 error("Can't express character in JIS X 0201");
30 void JisX0201::Decoder::decode_char(const string &str, string::const_iterator &i)
42 else if(c>=0xA1 && c<=0xDF)
45 error("Invalid JIS X 0201 string (undefined character)");