[tex4ht-commits] [SCM] tex4ht updated: r574 - trunk/lit

michal_h21 at gnu.org.ua michal_h21 at gnu.org.ua
Fri Jun 7 13:57:16 CEST 2019


Author: michal_h21
Date: 2019-06-07 14:57:16 +0300 (Fri, 07 Jun 2019)
New Revision: 574

Modified:
   trunk/lit/ChangeLog
   trunk/lit/Makefile
   trunk/lit/mktex4ht-cnf.tex
   trunk/lit/tex4ht-4ht.tex
Log:
added support for the imakeidx package

Modified: trunk/lit/ChangeLog
===================================================================
--- trunk/lit/ChangeLog	2019-06-06 22:04:47 UTC (rev 573)
+++ trunk/lit/ChangeLog	2019-06-07 11:57:16 UTC (rev 574)
@@ -1,3 +1,8 @@
+2019-06-07  Michal Hoftich  <michal.h21 at gmail.com>
+
+	* tex4ht-4ht.tex (usepackage.4ht, imakeidx.4ht): added support for the
+	Imakeidx package.
+
 2019-06-06  Michal Hoftich  <michal.h21 at gmail.com>
 
 	* tex4ht-4ht.tex (memoir.4ht),

Modified: trunk/lit/Makefile
===================================================================
--- trunk/lit/Makefile	2019-06-06 22:04:47 UTC (rev 573)
+++ trunk/lit/Makefile	2019-06-07 11:57:16 UTC (rev 574)
@@ -49,6 +49,7 @@
     framed.4ht frenchb.4ht floatpag.4ht \
   geometry.4ht graphics.4ht graphicx.4ht \
   hyperref.4ht \
+	imakeidx.4ht \
 	jurabib.4ht \
   latex.4ht lettrine.4ht listings.4ht \
   magyar.4ht mdframed.4ht memoir.4ht multicol.4ht multirow.4ht \

Modified: trunk/lit/mktex4ht-cnf.tex
===================================================================
--- trunk/lit/mktex4ht-cnf.tex	2019-06-06 22:04:47 UTC (rev 573)
+++ trunk/lit/mktex4ht-cnf.tex	2019-06-07 11:57:16 UTC (rev 574)
@@ -241,6 +241,7 @@
 \AddFile{9}{longdiv}
 \AddFile{7}{index}
 \AddFile{7}{multind}
+\AddFile{7}{imakeidx}
 \AddFile{9}{tugboat}
 \AddFile{9}{ltugboat}
 \AddFile{9}{ltugboat-a}

Modified: trunk/lit/tex4ht-4ht.tex
===================================================================
--- trunk/lit/tex4ht-4ht.tex	2019-06-06 22:04:47 UTC (rev 573)
+++ trunk/lit/tex4ht-4ht.tex	2019-06-07 11:57:16 UTC (rev 574)
@@ -28718,6 +28718,63 @@
   {\def\indexname{#2}\@input{#1.ind}}}
 >>>
 
+
+%%%%%%%%%%%%%%%%%%%%%%%%
+\SubSection{imakeidx.sty}
+%%%%%%%%%%%%%%%%%%%%%%%%
+
+\<imakeidx.4ht\><<<
+% imakeidx.4ht (|version), generated from |jobname.tex
+% Copyright 2019 TeX Users Group
+|<TeX4ht license text|>
+
+|<imakeidx.sty|>
+
+
+\Hinput{imakeidx}
+\endinput
+>>> \AddFile{7}{imakeidx}
+
+Patch the index writting commands to introduce the index destination and link to the
+destination to the idx file
+
+Note that the splitindex option doesn't work, as splitindex doesn't keep the
+tex4ht commands inserted in the idx file.
+
+\<imakeidx.sty\><<<
+\def\:temp#1#2#3{\html:addr%
+\hbox{\Link-{}{|<index haddr|>}\EndLink}%
+\protected at write\@indexfile{}%
+{\string\beforeentry{\RefFileNumber\FileNumber}{|<index haddr|>}{\a:makeindex}}
+\o:imki at wrindexentryunique:{#1}{#2}{#3}%
+}
+\HLet\imki at wrindexentryunique\:temp
+
+\def\:temp#1#2#3{\html:addr%
+\hbox{\Link-{}{|<index haddr|>}\EndLink}%
+\expandafter\protected at write\csname#1 at idxfile\endcsname{}%
+{\string\beforeentry{\RefFileNumber\FileNumber}{|<index haddr|>}{\a:makeindex}}%
+\o:imki at wrindexentrysplit:{#1}{#2}{#3}%
+}
+\HLet\imki at wrindexentrysplit\:temp
+
+\ifx \a:makeindex\:UnDef
+\NewConfigure{makeindex}{}\Configure{makeindex}{}
+\fi
+>>>
+
+\<use package\><<<
+imakeidx,>>>
+
+Prevent the automatic index compilation, the index produced by tex4ht
+needs a special treatment.
+
+\<add to usepackage\><<<
+\def\:temp{imakeidx}\ifx\@currname\:temp
+  \PassOptionsToPackage{noautomatic}{imakeidx}
+\fi
+>>>
+
 \<index haddr\><<<
 d|<haddr prefix|>\last:haddr
 >>>



More information about the tex4ht-commits mailing list