[tex4ht] [bug #307] make4ht removes spaces in \href in LUA mode when using mathdesign package

Michal Hoftich michal.h21 at gmail.com
Tue May 31 17:28:28 CEST 2016

Follow-up Comment #3, bug #307 (project tex4ht):

> first: use of dvi's w vs. right commands is not related to kerns vs. glue.
> the two are equivalent. w is simply more efficient (it reuses the given
> instead of repeating it).

> second: what dvi command is used, and/or whether kerns or glue are in use
> the tex level (interword space can't be a kern item, anyway), is not up to
> font. the engine determines this. luatex implements dvi output differently
> the rest. for example, take this one-line plain tex file: \nopagenumbers x
> z.\end run through tex foo.tex && dvitype foo.dvi >/tmp/pl.typ, compare to
> luatex --output-format=dvi foo.tex && dvitype foo.dvi >/lu.typ.  You'll see
> that luatex does uses dvi "right" commands where the original tex uses "w"
> commands, even with CMR.  Neither is wrong.

Ah, you are right, it seems that DVI export from pdftex and luatex differs in
this thing. And it tex4ht recognizes `right` commands as spaces with other
fonts, so it must be issue with this particular one.

> third: it is not surprising that pdf(la)tex and lua(la)tex would find
> fonts. i've never understood lualatex font lookup, and can't help there.
> furthermore, the actions taken by the two engines after a font is found are
> different. so little can be said there.  

It is different when OpenType fonts are involved, but it should be identical
for TFM fonts. I think either Mathdesign or Hyperref must select the
fonts with different engines. I grepped the whole Mathdesign source tree and
can't find any `lua` string, so it seems to be caused rather by Hyperref.

> fourth: neverthless, what is true is that part of the definition of a (tex)
> math font is that the interword space parameter (\fontdimen2) is set to
> (that parameter is for text setting, and math spacing is totally
> therefore, my wild guess is that whatever font is being found by lualatex as
> result of lualatex+tex4ht interpreting
> \usepackage[bitstream-charter]{mathdesign}
> is, at some level, a math font. I cannot guess whether it's an issue with
> wrong font being found by lualatex, or tex4ht wrongly considering the font
> math font, or a bug in tex4ht's .htf file, or ... something else entirely

The  md-chr8y doesn't seem to be math font:

    md-chr8y CharterBT-Roman "TeXnANSIEncoding ReEncodeFont" <texnansi.enc

it doesn't have the .htf file, but the space doesn't show even when I created
one using Htfgen.  


Reply to this item at:


  Message sent via/by Puszcza

More information about the tex4ht mailing list