1

I want to view the free, publically available hvmath bitmapped fonts available here: https://ctan.org/pkg/hvmath-fonts?lang=en.

I downloaded the package, and I see that there these .pk files for some resolutions. There are no .gf or .mf files. How do I view them? I cannot open them in FontForge. I tried to run the hvmaths.dtx file from here: https://ctan.org/pkg/hvmath?lang=en. It created a .dvi file, but the file seems corrupt as I can't see anything. How do I see the glyphs of these fonts?


So even though the Micropress site is down, a pdf of hvmath is available on Wayback Machine: https://web.archive.org/web/20210517200933/http://www.micropress-inc.com/fonts/samples/hvsampl.pdf

4
  • the .dtx compiles OK for me. I can view the resulting .dvi fine. it doesn't seem to actually use the fonts, but it isn't corrupt. Commented Jan 12 at 16:28
  • @cfr Can you please share the .dvi file with me? All the files in my folder, including the .tex, .log and .dvi files are here: drive.google.com/drive/folders/… Commented Jan 12 at 16:39
  • does my answer help? as I said, the .dtx will compile anyway just using computer modern. and it is not much help in configuring anything. also, it is not possible to share a dvi here. but I imagine you can probably compile it on overleaf, if you just upload the .dtx and the .sty. I did it without the fonts. Commented Jan 12 at 20:47
  • @cfr Yes indeed. Your answer is very helpful. I wouldn't have been able to figure it out for myself. Thanks. I shall try if I can compile it at 622 dpi. Commented Jan 13 at 4:12

2 Answers 2

1

It does work after a fashion - though I would not recommend actually trying to use these fonts - but it is a bit fiddly. I finally got the following to use the fonts at 300DPI:

\documentclass{article}
\usepackage{hvmath}
\begin{document}
Text $\Pr(A/B) \frac{x^{-2}}{\sum_{i=1}^{n} y - 23\pi}$.
\end{document}

Here's a listing of my working directory:

L209/    dpi300/       hvbc10mv.vf   hvbo10mv.tfm  hvbo10ts.vf  hvmath.txt   hvmaths.out   hvrb108r.tfm  hvrb10t1.vf   hvrm10ot.tfm  hvro10ex.tfm  hvro10ts.tfm  hvsc10t1.vf   omxhvex.fd        t1hvr.fd
PLAIN/   dpi329/       hvbc10ot.tfm  hvbo10mv.vf   hvbsy10.tfm  hvmaths.aux  hvmaths.ps    hvrb10ex.tfm  hvrb10ts.tfm  hvrm10ot.vf   hvro10mv.tfm  hvro10ts.vf   hvsy10.tfm    ot1hvr.fd         ts1hvr.fd
dpi150/  dpi360/       hvbc10ot.vf   hvbo10ot.tfm  hvex10.tfm   hvmaths.dtx  hvmaths.sty   hvrb10mv.tfm  hvrb10ts.vf   hvrm10t1.tfm  hvro10mv.vf   hvsc10mv.tfm  missfont.log  prawf-hvmath.aux
dpi180/  dpi432/       hvbc10t1.tfm  hvbo10ot.vf   hvexb10.tfm  hvmaths.dvi  hvmaths.txt   hvrb10mv.vf   hvrm108r.tfm  hvrm10t1.vf   hvro10ot.tfm  hvsc10mv.vf   omlhvm.fd     prawf-hvmath.dvi
dpi210/  dpi518/       hvbc10t1.vf   hvbo10t1.tfm  hvfonts.cfg  hvmaths.hd   hvmathts.txt  hvrb10ot.tfm  hvrm10ex.tfm  hvrm10ts.tfm  hvro10ot.vf   hvsc10ot.tfm  omlhvr.fd     prawf-hvmath.log
dpi240/  dpi622/       hvbo108r.tfm  hvbo10t1.vf   hvfonts.map  hvmaths.ins  hvmi10.tfm    hvrb10ot.vf   hvrm10mv.tfm  hvrm10ts.vf   hvro10t1.tfm  hvsc10ot.vf   omshvr.fd     prawf-hvmath.ps
dpi270/  hvbc10mv.tfm  hvbo10ex.tfm  hvbo10ts.tfm  hvmath.sty   hvmaths.log  hvmib10.tfm   hvrb10t1.tfm  hvrm10mv.vf   hvro108r.tfm  hvro10t1.vf   hvsc10t1.tfm  omshvsy.fd    prawf-hvmath.tex

This is basically the result of:

  1. Unpacking both archives and unpacking the archives inside the archive. I don't think the Schmidt archive actually helps much, so you could probably just unpack the fonts.
  2. Rename each directory of the form <nnn>DPI to dpi<nnn> where <n> is a digit. I am not sure whether this step is necessary.
  3. Moving selected files from the resulting sub-directories into the working directory. Basically, if a directory is shown above, its contents are in-place. If the directory is missing, its contents are in the working directory. So I moved the contents of L2E, METRICS, VF, CFG etc. into the working directory.

Compilation sequence (Linux, BSD, OS X etc.):

latex <filename>.tex
TEXINPUTS=.:dpi300:: dvips <filename>.dvi

Compilation sequence (Windows) - ?? can somebody confirm or correct this?:

latex <filename>.tex
set TEXINPUTS=.;dpi300;; dvips <filename>.dvi

Then open the resulting <filename>.ps in your DVI viewer. (I used Okular.) hvmath at 300DPI

As far as I can tell, there are no .mf sources, so you can only use the resolutions provided. For some reason, the resolutions provided are non-standard. For example, we have 622 but not 600. By default, Okular wants 1200 for DVI, which is why I converted to PS first.

Conversion to PS generates a bunch of checksum warnings, but dvips does use the contents of the dpi300 directory.

Obviously,

  1. You could install into a local texmf tree to avoid the need to specify TEXINPUTS etc.
  2. The result is poor quality for electronic documents, but that is just the nature of bitmap fonts. The printed result is probably OK-ish if you like Helvetica.
5
  • I still can't convert the dvi to ps. When I run dvips, it tries to run kpathsea, and complains that .mf files cannot be found Commented Jan 13 at 5:18
  • @ApoorvPotnis are you using texlive or miktex? I wonder if that path is correct in your case? do you have the files in the dpi300 sub-directory? Commented Jan 13 at 6:04
  • I am using texlive on windows 11. I used set TEXINPUTS=.:dpi300:: (I hope this is correct??). I copied everything in the dpi300 directory as well. I tried outside it, and inside it as well. Commented Jan 13 at 6:23
  • @ApoorvPotnis I'm pretty sure you have to have those .pk files in that sub-directory for it to work. that is the path I used. however, I don't know if it is correct on Windows. I don't know what set does, for example, or whether the colons are correct. try substituting a semicolon for the colons i.e. TEXINPUTS=.;dpi300;; rather than TEXINPUTS=.:dpi300::. this is just a guess based on the texmf.cnf, so if that looks like a terrible idea for any reason, don't do it. I'm thinking Windows might need ; rather than : because the .cnf supports both. Commented Jan 13 at 6:49
  • @ApoorvPotnis I've tried to provide an appropriate command for Windows (see edited answer above). I got this from l3build-file-functions.lua since it provides lists of variables for things like path separators for both Unix-ish and Windows. however, I'm not certain about the set part because I wouldn't use export here, which it says is equivalent. so I'm hoping somebody can confirm or correct it. I am reasonably confident you need ; rather than :, however. Commented Jan 13 at 19:29
1

https://ctan.org/tex-archive/fonts/micropress/hvmath has a hvmath.zip that contains the tfm metrics. TeX only needs the tfm files and then latex+dvips should be able to read the pk files to generate postscript containg type3 fonts based on the pk.

6
  • So the following file was compiled successfully `\font\hvmi=hvmi10 {\hvmi Test} \bye, and a dvi was generated, but my dvi viewer (apps.microsoft.com/detail/9wzdncrdj723?hl=en-US&gl=US) doesn't show it properly. I tried an online convertor to convert it to pdf, but it didn't work as well Commented Jan 11 at 15:36
  • @ApoorvPotnis if you are using texlive, you probably have a dvi viewer installed as part of your tex installation. however, I don't know what it might be called on windows. on linux, texlive installs xdvi. and what does 'didn't work' mean? Commented Jan 12 at 8:05
  • @cfr it is called dviout. By didn't work, I mean that dviout shows an error "Cannot open dvi file". The log file is This is TeX, Version 3.141592653 (TeX Live 2024) (preloaded format=tex 2024.9.27) 12 JAN 2025 14:11 **hvmi10test.tex (./hvmi10test.tex [1] ) Output written on hvmi10test.dvi (1 page, 256 bytes) Commented Jan 12 at 8:43
  • I copied the entirety of the contents of the hvmath and hvmath-fonts, all the .pk files, .fd, .vf, .tfm, in that directory Commented Jan 12 at 8:44
  • @ApoorvPotnis I may look later... Commented Jan 12 at 9:44

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.