From: Uwe Stöhr Date: Tue, 9 Oct 2007 00:12:48 +0000 (+0000) Subject: lyx2lyx/lyx_1_6.py: forgot to revert the encoding too in my last commit (r20859) X-Git-Tag: 1.6.10~7928 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=d44d755732dcada0b73e0437005461f93d940202;p=lyx.git lyx2lyx/lyx_1_6.py: forgot to revert the encoding too in my last commit (r20859) git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20860 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/lib/lyx2lyx/lyx_1_6.py b/lib/lyx2lyx/lyx_1_6.py index 2ace8c29eb..9f7e9408f0 100644 --- a/lib/lyx2lyx/lyx_1_6.py +++ b/lib/lyx2lyx/lyx_1_6.py @@ -438,6 +438,23 @@ def revert_japanese(document): j = j + 1 +def revert_japanese_encoding(document): + "Set input encoding form EUC-JP-plain to EUC-JP etc." + # Set input encoding form EUC-JP-plain to EUC-JP etc. + i = 0 + i = find_token(document.header, "\\inputencoding EUC-JP-plain", 0) + if i != -1: + document.header[i] = "\\inputencoding EUC-JP" + j = 0 + j = find_token(document.header, "\\inputencoding JIS-plain", 0) + if j != -1: + document.header[j] = "\\inputencoding JIS" + k = 0 + k = find_token(document.header, "\\inputencoding SJIS-plain", 0) + if k != -1: # convert to UTF8 since there is currently no SJIS encoding + document.header[k] = "\\inputencoding UTF8" + + ## # Conversion hub # @@ -461,7 +478,7 @@ convert = [[277, [fix_wrong_tables]], [292, []] ] -revert = [[291, [revert_japanese]], +revert = [[291, [revert_japanese, revert_japanese_encoding]], [290, [revert_vietnamese]], [289, [revert_wraptable]], [288, [revert_latexcommand_index]],