TransWikia.com

Font shape undefined when using autoinst

TeX - LaTeX Asked by user49121 on March 27, 2021

I want to create my fonts using autoinst script for use with pdflatex.

For this I run the commands autoinst example-regular.otf autoinst example-italic.otf autoinst example-bold.otf and autoinst example-bolditalic.otf.

Now I’m running texhashand updmap --enable Map example.map and all works.
But when I try to use the font in all installed shapes like in the MWE

documentclass[11pt,a4paper]{article}
usepackage[utf8]{inputenc}
usepackage[ngerman]{babel}
%usepackage{microtype}
usepackage{example}
%pdfmapfile{=example.map}
usepackage[LY1,T1]{fontenc}
usepackage{lipsum}
begin{document}
testenspacetextit{test}enspacetextbf{test}enspacetextit{textbf{test}}
end{document}

I’ll only get the regular font shape and for the other shapes warnings like LaTeX Font Warning: Font shape 'T1/example-TLF/m/it' undefined (Font) using 'T1/example-TLF/m/n' instead on input line 10. and this for all shapes so the result looks like the following:

test

One Answer

To create a single family with several shapes/weights, you need to run autoinst once on all the relevant fonts, rather than running it on each font separately. If the fonts are <example-regular>.otf, <example-italic>.otf, <example-bold>.otf and <example-bold-italic>.otf, for instance, run

autoinst <example-regular>.otf <example-italic>.otf <example-bold>.otf <example-bold-italic>.otf

Otherwise, I think you'll end up with a different font family for each shape which will not support standard shape-switching and weight-switching commands such as textit{} and bfseries.

Correct answer by cfr on March 27, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP