Character encoding scheme converter
mbconv [options] <file> ...
This is an application of a library to handle multiple octets character encoding:
http://pub.ks-and-ks.ne.jp/prog/libmoe/ mainly written for debugging of the library.
It reads octet by octet from files given on command line (or standard input if no file is specified), converts character encoding scheme (\s-1CES\s0) as specified by command line options (described below), and output to standard output (or a file specified by -t option or -a option).
\$1
display summary of options and exits.
output is appended to file.
specifies character encoding conversion. converters must be comma separated list of words described in \*(L"Conversion specifiers\*(R".
specifies flags to change behavior of conversion. flags must be comma separated list of words describe in \*(L"Flag specifiers\*(R".
succeeding options apply to input stream.
mime encoding conforming to \s-1RFC2047\s0 is performed. <string> is used as charset name.
line number (>= 1) is inserted to beginning of each line.
succeeding options apply to output stream.
output to file (truncated).
output width of each line.
specifies charset name. Some language specifications are also accepted as well as \s-1MIME\s0 charset names, which are used to restrict candidates of encoding scheme of input stream. Acceptable languages are listed in \*(L"Acceptable languages\*(R".
specifies output format
output charset name of each input stream to stderr, in the form file name\*(C`:\*(C' charset name if two or more files are specifed on the command line, or charset name otherwise.
specifies regeular expression to filter output. Character encoding of regular expression can be specified by putting string of the form \*(C`*\*(C'charset name\*(C`*\*(C' at the beginning of the regular expression, otherwise \s-1UTF-8\s0. Character encoding of the expression is converted to that of output stream before matching. Conversion is applied just before each character is output to stream. Conversion setup is automatically performed based on \s-1CES\s0. So in most cases, yo need not to specify converters explicitly.
domestic \s-1ASCII\s0 converted to \s-1US-ASCII\s0,
converted appropriately according to the \s-1CES\s0 bound to input/output stream,
converted to Unicode,
Fullwidth compatibility characters are converted to corresponding halfwidth ones,
Halfwidth compatibility characters are converted to corresponding fullwidth ones,
Codepoints in \s-1JIS\s0 C 6226 or in \s-1JIS\s0 X 0208 which are bound to no character are converted into \s-1JIS\s0 X 0213 plane 1,
All codepoints in \s-1JIS\s0 C 6226 or in \s-1JIS\s0 X 0208 are converted into \s-1JIS\s0 X 0213 plane 1,
Unicode characters of code point between 0x80 and 0x9F (both inclusive) are converted to other Unicode characters as if they are characters of those code point in Microsoft Windows Codepage 1252.
Converters between some \s-1JIS\s0 X 0208 and Unicode characters having similar glyphs (by the courtesy of Ambrose Li <[email protected]>).
use \*(L"1/11 2/4 2/8 F\*(R" instead of \*(L"1/11 2/4 F\*(R" to designate charsets with final octet 4/0, 4/1, or 4/2 to G0,
escape sequence \*(L"1/11 2/8 4/2\*(R" is output before every control character,
escape sequence for 7 bit single shift is ignored,
discard characters which \s-1CES\s0 bound to output stream can not decode. The following words may be given instead of \s-1MIME\s0 charset name for input stream. In that case, encoding scheme is automatically detected (hopefully) among succeeding ones.
x-gb-18030-2000, cn-big5, utf-8, or x-euc-tw.
euc-jp, shift_jis, or utf-8.
euc-kr, x-johab, utf-8, or x-unified-hangul.
iso-8859-1, x-gb-18030-2000, cn-big5, x-euc-tw, euc-jp, shift_jis, euc-kr, x-johab, x-unified-hangul, or utf-8.
Kiyokazu \s-1SUTO\s0 <[email protected]>
This program is distributed with absolutely no warranty.
Anyone can use, modify, and re-distibute this program without any restriction.