[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[6933] luatex output encoding
From: |
Gavin D. Smith |
Subject: |
[6933] luatex output encoding |
Date: |
Mon, 11 Jan 2016 19:33:26 +0000 |
Revision: 6933
http://svn.sv.gnu.org/viewvc/?view=rev&root=texinfo&revision=6933
Author: gavin
Date: 2016-01-11 19:33:25 +0000 (Mon, 11 Jan 2016)
Log Message:
-----------
luatex output encoding
Modified Paths:
--------------
trunk/ChangeLog
trunk/doc/texinfo.tex
Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog 2016-01-09 15:33:35 UTC (rev 6932)
+++ trunk/ChangeLog 2016-01-11 19:33:25 UTC (rev 6933)
@@ -1,3 +1,10 @@
+2016-01-11 Gavin Smith <address@hidden>
+
+ * doc/texinfo.tex: For LuaTeX, output bytes instead of UTF-8
+ multi-byte characters. Add comment to say this is a problem
+ with XeTeX which we haven't fixed. Problem under LuaTeX and
+ XeTeX reported by Masamichi Hosoda.
+
2016-01-09 Gavin Smith <address@hidden>
* gnulib: Run gnulib-tool --add-import, omitting the "mkstemp"
Modified: trunk/doc/texinfo.tex
===================================================================
--- trunk/doc/texinfo.tex 2016-01-09 15:33:35 UTC (rev 6932)
+++ trunk/doc/texinfo.tex 2016-01-11 19:33:25 UTC (rev 6933)
@@ -3,7 +3,7 @@
% Load plain if necessary, i.e., if running under initex.
\expandafter\ifx\csname fmtname\endcsname\relax\input plain\fi
%
-\def\texinfoversion{2016-01-07.22}
+\def\texinfoversion{2016-01-11.19}
%
% Copyright 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995,
% 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006,
@@ -9434,13 +9434,16 @@
\else
\XeTeXdefaultencoding "bytes" % For subsequent files to be read
\XeTeXinputencoding "bytes" % Effective in texinfo.tex only
+% Unfortunately, there seems to be no corresponding XeTeX command for
+% output encoding. This is a problem for auxiliary index and TOC files.
+% The only solution would be perhaps to write out @U{...} sequences in
+% place of UTF-8 characters.
\fi
\ifx\luatexversion\thisisundefined
\else
\directlua{
local utf8_char, byte, gsub = unicode.utf8.char, string.byte, string.gsub
-
local function convert_char (char)
return utf8_char(byte(char))
end
@@ -9450,6 +9453,16 @@
end
callback.register("process_input_buffer", convert_line)
+
+local function convert_line_out (line)
+ local line_out = ""
+ for c in string.utfvalues(line) do
+ line_out = line_out .. string.char(c)
+ end
+ return line_out
+end
+
+callback.register("process_output_buffer", convert_line_out)
}
\fi
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [6933] luatex output encoding,
Gavin D. Smith <=