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

michal_h21 at gnu.org.ua michal_h21 at gnu.org.ua
Wed Jun 15 15:54:03 CEST 2016


Author: michal_h21
Date: 2016-06-15 16:54:03 +0300 (Wed, 15 Jun 2016)
New Revision: 173

Modified:
   trunk/lit/ChangeLog
   trunk/lit/Makefile
   trunk/lit/tex4ht-4ht.tex
   trunk/lit/tex4ht-sty.tex
Log:
Added support for package loading blocking. Block savetrees package

Modified: trunk/lit/ChangeLog
===================================================================
--- trunk/lit/ChangeLog	2016-06-15 12:33:58 UTC (rev 172)
+++ trunk/lit/ChangeLog	2016-06-15 13:54:03 UTC (rev 173)
@@ -23,6 +23,16 @@
 	* tex4ht-4ht.tex: enable new protex option CodeLineNo.
 	http://puszcza.gnu.org.ua/bugs/?136
 
+2016-06-09  Michal Hoftich  <michal.h21 at gmail.com>
+
+	* tex4ht-sty.tex:  added \:dontusepackage macro for package loading
+	preventing. Changed \@onefilewithoptions patching, second argument is read
+	and saved.
+	* tex4ht-4ht.tex:  added savetrees.sty to list of packages detected upon
+	their loading. It is blocked from loading, as it causes tex4ht to fail
+	* Makefile: added derived files
+	https://puszcza.gnu.org.ua/bugs/?309
+
 2016-05-24  Michal Hoftich  <michal.h21 at gmail.com>
 
 	* tex4ht-4ht.tex (geometry.4ht): new file to turn off frame-drawing.

Modified: trunk/lit/Makefile
===================================================================
--- trunk/lit/Makefile	2016-06-15 12:33:58 UTC (rev 172)
+++ trunk/lit/Makefile	2016-06-15 13:54:03 UTC (rev 173)
@@ -19,7 +19,7 @@
   geometry.4ht graphicx.4ht hyperref.4ht listings.4ht \
   memoir.4ht multicol.4ht quoting.4ht reading.4ht \
   scrartcl.4ht scrbook.4ht scrreprt.4ht spanish.4ht subscript.4ht \
-  titlesec.4ht tocloft.4ht wrapfig.4ht 
+  titlesec.4ht tocloft.4ht wrapfig.4ht usepackage.4ht
 # and many, many more.
 
 derived += $(tex4ht_bibtex2_derived)
@@ -46,6 +46,10 @@
 derived += $(tex4ht_fonts_cjk_utf8_derived)
 tex4ht_fonts_cjk_utf8_derived = tex4ht-fonts-cjk-utf8.html # and lots more
 
+
+derived += $(tex4ht_sty_derived)
+tex4ht_sty_derived = tex4ht.sty
+
 # noncjk.tex \input's modern, but seems more maintainable
 # to have separate lists.
 derived += $(tex4ht_fonts_noncjk_derived)

Modified: trunk/lit/tex4ht-4ht.tex
===================================================================
--- trunk/lit/tex4ht-4ht.tex	2016-06-15 12:33:58 UTC (rev 172)
+++ trunk/lit/tex4ht-4ht.tex	2016-06-15 13:54:03 UTC (rev 173)
@@ -3431,6 +3431,21 @@
 >>>
 
 %%%%%%%%%%%%%%%%%%
+\Section{savetrees.sty}
+%%%%%%%%%%%%%%%%%%
+
+\<use package\><<<
+savetrees,>>>
+
+\<add to usepackage\><<<
+\def\:temp{savetrees}\ifx \@currname\:temp
+\:dontusepackage{savetrees}
+\fi
+>>>
+
+
+
+%%%%%%%%%%%%%%%%%%
 \Section{url.sty}
 %%%%%%%%%%%%%%%%%%
 

Modified: trunk/lit/tex4ht-sty.tex
===================================================================
--- trunk/lit/tex4ht-sty.tex	2016-06-15 12:33:58 UTC (rev 172)
+++ trunk/lit/tex4ht-sty.tex	2016-06-15 13:54:03 UTC (rev 173)
@@ -560,6 +560,7 @@
    |<try taking care of hyperref.sty|>
    |<early latex subs/sups|> 
 \fi
+|<block package loading|>
 |<hook at usepackage|>
 >>>
 
@@ -570,18 +571,26 @@
 \expandafter\def\csname opt at hyperref.sty\endcsname{tex4ht}
 >>>
 
+\<block package loading\><<<
+\def\:dontusepackage#1{%
+  \typeout{tex4ht warning: package #1 was prevented from loading}
+  \@namedef{ver@#1.sty}{9999/12/31}%
+  \@namedef{opt@#1.sty}{\:currentoptions}
+}
+>>>
+
 \<hook at usepackage\><<<
 \let\:onefilewithoptions\@onefilewithoptions
-\def\@onefilewithoptions#1[{%
+\def\@onefilewithoptions#1[#2]{%
    \let\:temp\@reset at ptions
    \def\@reset at ptions{%
       \let\@reset at ptions\:temp
       |<cats for usepackage|>\a:usepackage
       |<recall usepackage cats|>}%
-   \:onefilewithoptions#1[}
+      \def\:currentoptions{#2}
+ \:onefilewithoptions#1[#2]}
 \def\a:usepackage{\input usepackage.4ht }
 >>>
-
 \<cats for usepackage\><<<
 \edef\TivhTcats{%
    \catcode`:=\the\catcode`:%
@@ -593,7 +602,6 @@
 \TivhTcats
 >>>
 
-
 %%%%%%%%%%%%%%%%%%%%%%%%%
 \Section{Second Pass}
 %%%%%%%%%%%%%%%%%%%%%%%%%



More information about the tex4ht-commits mailing list