# [tex4ht] graphics Images no longer resize in TL 2015 with tex4ht, need help finding why

Nasser M. Abbasi nma at 12000.org
Wed Jul 22 10:21:44 CEST 2015

Spend 6 hrs on this and I gave up. For some reason, the images
no longer resize in the web pages as before. This
used to work.

I made earlier a small document that describes this
resizing method here (layout)

http://12000.org/my_notes/faq/LATEX/layout/index.htm

But when I tried this method now, I found that the images
do not resize anymore ! Something changed and I can't find
what. I used to use 32 bit TL 2014 before. Now I am on
64 bit Linux and TL 2015.

I show the steps I did below, which is the same as in the layout
document, and I also put everything in one zip file at :

http://12000.org/tmp/072215/image_do_not_resize.zip

Here is MWE:
-------------------------------------
\documentclass[11pt,notitlepage]{article}%
\usepackage{graphicx}
\begin{document}
\includegraphics[width=0.1\paperwidth]{1_pic}
\includegraphics[width=0.2\paperwidth]{1_pic}
\includegraphics[width=0.3\paperwidth]{1_pic}
\includegraphics[width=0.4\paperwidth]{1_pic}
\end{document}
--------------------------------------

The folder contains 1_pic.pdf and 1_pic.svg. The SVG image
was obtained _from_ the pdf file using

pdfcrop --margins 10 --clip 1_pic.pdf 1_pic.pdf
pdf2svg 1_pic.pdf 1_pic.svg

The command used to compile is:

make4ht -u -c nma.cfg foo.tex "htm,pic-align,notoc*"
I also tried
htlatex foo.tex "nma,htm,pic-align,notoc*"

the nma.cfg is :

-----------------
\Preamble{ext=htm,charset="utf-8",p-width,pic-align}
\Configure{VERSION}{}
\Configure{DOCTYPE}{\HCode{<!DOCTYPE html>\Hnewline}}
\Configure{HTML}{\HCode{<html>\Hnewline}}{\HCode{\Hnewline</html>}}
\begin{document}
\DeclareGraphicsExtensions{.svg,.png}
\Configure{Picture}{.svg}
\makeatletter
% Various helper functions
% default font size
\newcommand\emwidth{16}
\let\emwidth\f at size
% convert pt to rem
\newcommand\CalcRem[1]{\strip at pt\dimexpr(#1)/\emwidth}
\Configure{graphics*}
{svg}
{\Picture[pict]{\csname Gin at base\endcsname.svg
\space style="width:\CalcRem{\Gin at req@width}em;"
}%
\special{t4ht+ at File: \csname Gin at base\endcsname.svg}%
}
\makeatother
\EndPreamble
------------------------------

All of the above, is exactly what is described in my layout document.

But the images come out all the same size. Which is not what is supposed
to happen. I do not want to use natural sizes. I use [width=0.7\paperwidth]{image}
and such for all the images.

Could someone please try this and see if they get different image sizes?
Simply unzip the folder, and just type the compile command and see if
you get different size images.

I am using TL 2015, 64 bit, on Linux mint 7.2, 64 bits.

thank you,
--Nasser