[dvipdfmx] dvipdfmx: how to use PK fonts instead of Type1?

Igor Liferenko igor.liferenko at gmail.com
Sun Dec 13 07:12:36 CET 2020


Hi all,

I need to use PK fonts instead of Type1. dvipdfmx does not allow to do this.
Is it possible to add an option to use PK fonts?

Consider this x.tex:

    hello \bye

Process it with tex and then with dvipdfmx:

    $ dvipdfmx -vv x
    <FONTMAP:/var/lib/texmf/fonts/map/pdftex/updmap/pdftex.map><FONTMAP:/var/lib/texmf/fonts/map/dvipdfmx/updmap/kanjix.map><FONTMAP:/usr/share/texlive/texmf-dist/fonts/map/dvipdfmx/ckx.map>x
-> x.pdf
DVI Comment:  TeX output 2020.12.13:1305
    <AGL:texglyphlist.txt><AGL:pdfglyphlist.txt><AGL:glyphlist.txt>[1<cmr10 at 9.96pt(TFM:cmr10[/usr/share/texlive/texmf-dist/fonts/tfm/public/cm/cmr10.tfm])
fontmap: cmr10 -> cmr10.pfb

    pdf_font>> Simple font "cmr10.pfb" enc_id=<builtin,-1> opened at
font_id=<cmr10,0>.
>](cmr10.pfb[CMR10][built-in][Type1][6 glyphs][766 bytes])
    Compression saved 455 bytes
    2129 bytes written

We see that cmr10.pfb is used. Now comment all lines beginning with
`f' in dvipdfmx.cfg
and run dvipdfmx again:

    $ dvipdfmx -vv x
    x -> x.pdf
    DVI Comment:  TeX output 2020.12.13:1305
    <AGL:texglyphlist.txt><AGL:pdfglyphlist.txt><AGL:glyphlist.txt>[1<cmr10 at 9.96pt(TFM:cmr10[/usr/share/texlive/texmf-dist/fonts/tfm/public/cm/cmr10.tfm])
pdf_font>> Simple font "cmr10" enc_id=<builtin,-1> opened at font_id=<cmr10,0>.
>](cmr10[CMR10][built-in][Type1][6 glyphs][766 bytes])
    Compression saved 459 bytes
    2125 bytes written

We see that "Type1" font is used again. Now we remove cmr10.pfb and run
dvipdfmx again:

    $ dvipdfmx -vv x
    x -> x.pdf
    DVI Comment:  TeX output 2020.12.13:1305
    <AGL:texglyphlist.txt><AGL:pdfglyphlist.txt><AGL:glyphlist.txt>[1<cmr10 at 9.96pt(TFM:cmr10[/usr/share/texlive/texmf-dist/fonts/tfm/public/cm/cmr10.tfm])
pdf_font>> Simple font "cmr10" enc_id=<builtin,-1> opened at font_id=<cmr10,0>.
>](cmr10[cmr10][built-in][Type3/PK])
    Compression saved 1036 bytes
    2063 bytes written

Now we see that PK font is used, as desired.

How to achieve the same effect without removing cmr10.pfb?

Greetings

Igor


More information about the dvipdfmx mailing list.