* lib/encodings: Explain that only single byte encodings can be

added easily

	* src/encoding.C
	(Encoding::Encoding): Better test for utf8


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17313 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Georg Baum 2007-02-23 20:13:06 +00:00
parent 3a64f157b7
commit 0c26507890
2 changed files with 6 additions and 1 deletions

View File

@ -1,6 +1,11 @@
# FIXME: Have a look at the encodings known by the inputenc package and add # FIXME: Have a look at the encodings known by the inputenc package and add
# missing ones. Caution: File format change! # missing ones. Caution: File format change!
# Note that you can only add single byte encodings to this file without
# changing some C++ code.
# The only multibyte encoding that is currently supported is utf8, and this
# support is hardcoded to the iconv name "UTF-8".
# Order of names: LyX name LaTeX name iconv name # Order of names: LyX name LaTeX name iconv name
Encoding utf8 utf8 UTF-8 Encoding utf8 utf8 UTF-8

View File

@ -214,7 +214,7 @@ Encoding::Encoding(string const & n, string const & l, string const & i)
if (n == "ascii") if (n == "ascii")
// ASCII can encode 128 code points and nothing else // ASCII can encode 128 code points and nothing else
start_encodable_ = 128; start_encodable_ = 128;
if (n == "utf8" || n == "utf8x") else if (i == "UTF-8")
// UTF8 can encode all 1<<20 + 1<<16 UCS4 code points // UTF8 can encode all 1<<20 + 1<<16 UCS4 code points
start_encodable_ = 0x110000; start_encodable_ = 0x110000;
else { else {