texlive[60738] trunk: make4ht (11oct21)

commits+karl at tug.org commits+karl at tug.org
Mon Oct 11 22:26:10 CEST 2021


Revision: 60738
          http://tug.org/svn/texlive?view=revision&revision=60738
Author:   karl
Date:     2021-10-11 22:26:10 +0200 (Mon, 11 Oct 2021)
Log Message:
-----------
make4ht (11oct21)

Modified Paths:
--------------
    trunk/Build/source/texk/texlive/linked_scripts/make4ht/make4ht
    trunk/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl
    trunk/Build/source/texk/texlive/linked_scripts/tlshell/tlshell.tcl
    trunk/Master/texmf-dist/doc/support/make4ht/changelog.tex
    trunk/Master/texmf-dist/doc/support/make4ht/make4ht-doc.pdf
    trunk/Master/texmf-dist/scripts/make4ht/domfilters/make4ht-mathmlfixes.lua
    trunk/Master/texmf-dist/scripts/make4ht/formats/make4ht-odt.lua
    trunk/Master/texmf-dist/scripts/make4ht/make4ht

Modified: trunk/Build/source/texk/texlive/linked_scripts/make4ht/make4ht
===================================================================
--- trunk/Build/source/texk/texlive/linked_scripts/make4ht/make4ht	2021-10-11 20:25:38 UTC (rev 60737)
+++ trunk/Build/source/texk/texlive/linked_scripts/make4ht/make4ht	2021-10-11 20:26:10 UTC (rev 60738)
@@ -29,7 +29,7 @@
 
 -- set version number. the template should be replaced by the
 -- actual version number by the build script
-local version = "v0.3i"
+local version = "v0.3j"
 mkparams.version_number = version
 
 local args = mkparams.get_args()

Modified: trunk/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl
===================================================================
--- trunk/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl	2021-10-11 20:25:38 UTC (rev 60737)
+++ trunk/Build/source/texk/texlive/linked_scripts/texlive/tlmgr.pl	2021-10-11 20:26:10 UTC (rev 60738)
@@ -1,12 +1,12 @@
 #!/usr/bin/env perl
-# $Id: tlmgr.pl 60557 2021-09-20 10:46:43Z preining $
+# $Id: tlmgr.pl 60693 2021-10-04 02:24:25Z preining $
 #
 # Copyright 2008-2021 Norbert Preining
 # This file is licensed under the GNU General Public License version 2
 # or any later version.
 
-my $svnrev = '$Revision: 60557 $';
-my $datrev = '$Date: 2021-09-20 12:46:43 +0200 (Mon, 20 Sep 2021) $';
+my $svnrev = '$Revision: 60693 $';
+my $datrev = '$Date: 2021-10-04 04:24:25 +0200 (Mon, 04 Oct 2021) $';
 my $tlmgrrevision;
 my $tlmgrversion;
 my $prg;
@@ -63,7 +63,7 @@
   }
   if (-r "$bindir/$kpsewhichname") {
     # if not in bootstrapping mode => kpsewhich exists, so use it to get $Master
-    chomp($Master = `kpsewhich -var-value=SELFAUTOPARENT`);
+    chomp($Master = `kpsewhich -var-value=TEXMFROOT`);
   }
 
   # if we have no directory in which to find our modules,
@@ -10239,7 +10239,7 @@
 distribution (L<https://tug.org/texlive>) and both are licensed under the
 GNU General Public License Version 2 or later.
 
-$Id: tlmgr.pl 60557 2021-09-20 10:46:43Z preining $
+$Id: tlmgr.pl 60693 2021-10-04 02:24:25Z preining $
 =cut
 
 # test HTML version: pod2html --cachedir=/tmp tlmgr.pl >/tmp/tlmgr.html

Modified: trunk/Build/source/texk/texlive/linked_scripts/tlshell/tlshell.tcl
===================================================================
--- trunk/Build/source/texk/texlive/linked_scripts/tlshell/tlshell.tcl	2021-10-11 20:25:38 UTC (rev 60737)
+++ trunk/Build/source/texk/texlive/linked_scripts/tlshell/tlshell.tcl	2021-10-11 20:26:10 UTC (rev 60738)
@@ -1760,7 +1760,7 @@
     tk_messageBox -message [__ "No backup directory defined"]
     return
   }
-  set bdir [file join [exec kpsewhich -var-value SELFAUTOPARENT] $bdir]
+  set bdir [file join [exec kpsewhich -var-value TEXMFROOT] $bdir]
   if {! [file isdirectory $bdir]} {
     tk_messageBox -message [__ "Backup directory %s does not exist" $bdir]
     return

Modified: trunk/Master/texmf-dist/doc/support/make4ht/changelog.tex
===================================================================
--- trunk/Master/texmf-dist/doc/support/make4ht/changelog.tex	2021-10-11 20:25:38 UTC (rev 60737)
+++ trunk/Master/texmf-dist/doc/support/make4ht/changelog.tex	2021-10-11 20:26:10 UTC (rev 60738)
@@ -3,6 +3,25 @@
 
 \begin{itemize}
 \item
+  2021/10/11
+
+  \begin{itemize}
+  \tightlist
+  \item
+    version \texttt{0.3j} released.
+  \end{itemize}
+\item
+  2021/10/09
+
+  \begin{itemize}
+  \tightlist
+  \item
+    fixed wrong DOM object name in the ODT format.
+  \item
+    add addtional \texttt{\textless{}mrow\textgreater{}} elements when
+    necessary.
+  \end{itemize}
+\item
   2021/09/30
 
   \begin{itemize}

Modified: trunk/Master/texmf-dist/doc/support/make4ht/make4ht-doc.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/scripts/make4ht/domfilters/make4ht-mathmlfixes.lua
===================================================================
--- trunk/Master/texmf-dist/scripts/make4ht/domfilters/make4ht-mathmlfixes.lua	2021-10-11 20:25:38 UTC (rev 60737)
+++ trunk/Master/texmf-dist/scripts/make4ht/domfilters/make4ht-mathmlfixes.lua	2021-10-11 20:26:10 UTC (rev 60738)
@@ -37,6 +37,30 @@
   end
 end
 
+-- if element contains 
+-- wrap everything in <mrow>
+local function top_mrow(math)
+  local children = math:get_children()
+  local put_mrow = false
+  -- don't process elements with one or zero children
+  -- don't process elements that already are mrow
+  if #children < 2 or  math:get_element_name() == "mrow" then return nil end
+  for _,v in ipairs(children) do
+    if v:is_element() and is_token_element(v) then
+      put_mrow = true
+      break
+    end
+  end
+  if put_mrow then
+    local mrow = math:create_element("mrow")
+    for _, el in ipairs(children) do
+      mrow:add_child_node(el)
+    end
+    math._children = {mrow}
+  end
+
+end
+
 local function get_fence(el, attr, form)
   -- convert fence attribute to <mo> element
   -- attr: open | close
@@ -108,6 +132,7 @@
     end
     fix_token_elements(el)
     fix_nested_mstyle(el)
+    top_mrow(el)
   end)
   return dom
 end

Modified: trunk/Master/texmf-dist/scripts/make4ht/formats/make4ht-odt.lua
===================================================================
--- trunk/Master/texmf-dist/scripts/make4ht/formats/make4ht-odt.lua	2021-10-11 20:25:38 UTC (rev 60737)
+++ trunk/Master/texmf-dist/scripts/make4ht/formats/make4ht-odt.lua	2021-10-11 20:26:10 UTC (rev 60738)
@@ -127,7 +127,7 @@
   end
   local content = f:read("*all") or ""
   f:close()
-  local status, domobject = pcall(function()
+  local status, dom= pcall(function()
     return domobject.parse(content)
   end)
   if not status then 
@@ -224,13 +224,13 @@
   -- expanded in tex4ht.env in Miktex or Debian
   call_xtpipes(make)
   -- fix the image dimensions wrongly set by xtpipes
-  local domfilters = domfilter {"t4htlinks", "odtpartable"}
+  local domfilters = domfilter({"t4htlinks", "odtpartable"}, "odtfilters")
   make:match("4oo$", domfilters)
+  -- execute it before xtpipes, because we don't want xtpipes to mess with t4htlink elements
+  move_matches(make)
   -- fixes for mathml
-  local mathmldomfilters = domfilter {"joincharacters","mathmlfixes"}
+  local mathmldomfilters = domfilter({"joincharacters","mathmlfixes"}, "mathmlfilters")
   make:match("4om$", mathmldomfilters)
-  -- execute it before xtpipes, because we don't want xtpipes to mess with t4htlink elements
-  move_matches(make)
   -- convert XML entities for Unicode characters produced by Xtpipes to characters
   local fixentities = filter {"entities-to-unicode", remove_xtpipes}
   make:match("4oo", fixentities)

Modified: trunk/Master/texmf-dist/scripts/make4ht/make4ht
===================================================================
--- trunk/Master/texmf-dist/scripts/make4ht/make4ht	2021-10-11 20:25:38 UTC (rev 60737)
+++ trunk/Master/texmf-dist/scripts/make4ht/make4ht	2021-10-11 20:26:10 UTC (rev 60738)
@@ -29,7 +29,7 @@
 
 -- set version number. the template should be replaced by the
 -- actual version number by the build script
-local version = "v0.3i"
+local version = "v0.3j"
 mkparams.version_number = version
 
 local args = mkparams.get_args()



More information about the tex-live-commits mailing list.