[EXT] Re: AMS/CM fonts in OpenType/CFF format

Philip Taylor (Royal Holloway) P.Taylor at Rhul.Ac.Uk
Wed Nov 17 15:48:20 CET 2021


On 17/11/2021 11:04, Marcel Fabian Krüger wrote:


Looking at the code again I realized that the quotes actually *do* make
a difference: If the name is quoted XeTeX will first look for a system
font and use a TFM font only if no system font is found, if the name is
not quoted it will forst look for a TFM font.

If you want a IMO clearer syntax, you can use LuaTeX with luaotfload.
There we still emulate the XeTeX like syntax, but additionally allow you
explicitly state how the font should be looked up, e.g.

\font \cmr {name:cmr10} \cmr % Untested, LuaTeX with luaotfload only.
                             % Quotes would work too.
                             % So would omitting both in this case.

Sadly failed at first hurdle :  \input luaotfload -> "I can't find file 'luaotfload'".

Ignoring that, zillions of other errors which do not occur when using XeTeX (see attachments).  To the best of your belief, is there a standard LuaTeX file which can be input that will then cause LuaTeX to faithfully emulate the behaviour of XeTeX ?  I ask because all of my work is predicated on the use of XeTeX and the assumption that it can exploit any and all of XeTeX's documented features.

Well, if the same happens in luaotfload please write a bug report. If
you want someone to tell you that XeTeX's font lookup rules are nice,
consistent or intuitive you are talking with the wrong person...

Fair enough !
--
** Phil.

This email, its contents and any attachments are intended solely for the addressee and may contain confidential information. In certain circumstances, it may also be subject to legal privilege. Any unauthorised use, disclosure, or copying is not permitted. If you have received this email in error, please notify us and immediately and permanently delete it. Any views or opinions expressed in personal emails are solely those of the author and do not necessarily represent those of Royal Holloway, University of London. It is your responsibility to ensure that this email and any attachments are virus free.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://tug.org/pipermail/tex-live/attachments/20211117/51ee652b/attachment-0001.html>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: LuaTeX diagnostics.txt
URL: <https://tug.org/pipermail/tex-live/attachments/20211117/51ee652b/attachment-0001.txt>
-------------- next part --------------
% !TeX Program=XeTeX

\newif \iffolded
\newif \ifprint
\newif \iffulldate

\input "Hoi-An main menu (combine pages, A3, common)"
-------------- next part --------------


\immediate \write 18 {XeTeX "Hoi-An Main menu (separate pages).tex"}

\def \images {../..}
%\def \images {..}

\def \coversource {"\images/Front cover (metallic Hoi-An)"}

\ifprint
	\def \cover {\XeTeXpdffile \coversource.pdf }	
	\def \groundleft {\images/Trang doi (left, linear fade).jpg}
	\def \groundright {\images/Trang doi (right, linear fade).jpg}
\else
	\def \cover {\XeTeXpicfile \coversource.jpg }	
	\def \groundleft {\images/null.jpg}
	\def \groundright {\images/null.jpg}
\fi

\newdimen \rulewidth
\newdimen \tuckloss

\tuckloss = 1 mm
\rulewidth = 0 \tuckloss
\rulewidth = 0,5 pt 
\tuckloss = 0 mm

\hsize = 420 mm
\vsize = 297 mm

%\hsize = 500 mm
%\vsize = 353 mm

\def \rule
	{%
		\raise 0,0485 \vsize
		\hbox to -1 em
		\bgroup
			\hskip 0 pt minus 1 fill
			\special {color push rgb 0 0 0 }%
			\vrule width \rulewidth height 0,75 \vsize
			\special {color pop}%		
			\relax
			\hskip 0 pt plus 1 fill
		\egroup
	}
	
\def \norule
	{%
		\raise 0,07 \vsize
		\hbox to 0 pt
		\bgroup
			\hss
			\special {color push rgb 1 1 1 }%
			\vrule width \rulewidth height 0,765 \vsize
			\special {color pop}%		
			\relax
			\hss
		\egroup
	}
                                                                                           
\pdfpageheight = \vsize
\pdfpagewidth = \hsize
\newdimen \dekoffset
\dekoffset = 1 true in
\hoffset = \dimexpr \hoffset - \dekoffset \relax
\voffset = \dimexpr \voffset - \dekoffset \relax

\newdimen \rootdimen
\rootdimen = 0,1 \dimexpr \hsize / \numexpr \dimexpr 410 mm \relax / 65536 \relax \relax

\font \Allergens = "TeX Gyre Heros Bold Italic:color=FF0000" at 82.5 \rootdimen
\font \allergens = "TeX Gyre Heros Italic:color=FF0000" at 85 \rootdimen 

\def \ALLERGENS {{\Allergens \hyphenchar \font = -1 ALLERGENS\/} }
\def \ALLERGIC {{\Allergens  \hyphenchar \font = -1 ALLERGIC\/} }

\font \introfont = "Calibri" at 116 \rootdimen

\def \source {"Hoi-An main menu (separate pages).pdf" }

\setbox 1 = \vbox {\XeTeXpdffile \source page 1 width \dimexpr \hsize / 4 - \tuckloss - 0,666 \rulewidth \relax}\relax
\setbox 2 = \vbox {\XeTeXpdffile \source page 2 width \dimexpr \hsize / 4 - 0,666 \rulewidth \relax}\relax
\setbox 3 = \vbox {\XeTeXpdffile \source page 3 width \dimexpr \hsize / 4 - 0,666 \rulewidth \relax}\relax
\setbox 4 = \vbox {\XeTeXpdffile \source page 4 width \dimexpr \hsize / 4 - \tuckloss \relax}\relax

\font \Algerian = "Algerian:color=381808" at \numexpr 7000 * 925 / 10000 \relax \rootdimen
\font \algerian = "Algerian:color=381808" at \numexpr 5800 * 925 / 10000 \relax \rootdimen

\font \SmallAlgerian = "Algerian/I:color=381808;slant=0.2" at \numexpr 3500 * 925 / 10000 \relax \rootdimen
\font \smallalgerian = "Algerian/I:color=381808;slant=0.2" at \numexpr 2500 * 925 / 10000 \relax \rootdimen

\font \SmallAlgerian = "Algerian/I:color=381808;slant=0.2" at \numexpr 2190 * 925 / 10000 \relax \rootdimen
\font \smallalgerian = "Algerian/I:color=381808;slant=0.2" at \numexpr 2190 * 925 / 10000 \relax \rootdimen
\let \SmallAlgerian = \smallalgerian


\catcode `\ộ = \active
\def ộ{{ô}\llap {\lower 0,2 em \hbox to 0,6 em {\hss .\hss}}}

\setbox 0 = \hbox {\XeTeXpicfile "\groundleft" width 0,5 \hsize height \vsize}
\setbox 0 = \hbox {\box 0 \XeTeXpicfile "\groundright" width 0,5 \hsize height \vsize}
\setbox 0 = \vbox to \vsize
	\bgroup
		\copy 0 
		\vss
		\toks 0 = {\hbox to 0,5 \hsize {\algerian \kern 0,4 em {\Algerian H}ội-\kern -0,1 em {\Algerian A}n $\,${\Algerian R}est\kern -0,1 em a\kern -0,055 em urant\hss }\hss \raise 2 ex \hbox to 0,5 \hsize {\smallalgerian \kern 0,2 em \llap {— }{\SmallAlgerian S}erving {\SmallAlgerian C}ontemporary {\SmallAlgerian O}riental \& {\SmallAlgerian W}estern {\SmallAlgerian C}uisine\hss}}
		\setbox 0 = \hbox to \hsize {\the \toks 0}
		\centerline {\hbox to \wd 0 {\raise 0,975 \vsize \box 0 \hss}}
		\vss
		\vskip -5 ex
		\hbox to \hsize {\hss \box 1 \rule \box 2 \rule \box 3 \rule \box 4 \hss}\relax
		\vskip 5 ex
	\egroup
\box 0 

\def \source {"Hoi-An vegan menu (separate pages).pdf" }
\setbox 1 = \vbox {\XeTeXpdffile \source page 1 height 0,88 \vsize width \dimexpr \hsize / 4 - \tuckloss - 0,666 \rulewidth \relax}\relax
\setbox 2 = \vbox {\XeTeXpdffile \source page 2 height 0,88 \vsize width \dimexpr \hsize / 4 - 0,666 \rulewidth \relax}\relax

\def \rule
	{%
		\raise 0,155 \vsize
		\hbox to -3 em
		\bgroup
			\hss \hss \hss \hss
			\special {color push rgb 0 0 0 }%
			\vrule width \rulewidth height 0,72 \vsize
			\special {color pop}%		
			\relax
			\hss
		\egroup
	}
	
\def \norule
	{%
		\raise 0,07 \vsize
		\hbox to 0 pt
		\bgroup
			\hss
			\special {color push rgb 1 1 1 }%
			\vrule width \rulewidth height 0,765 \vsize
			\special {color pop}%		
			\relax
			\hss
		\egroup
	}
	
\font \white = "Calibri":color=FEFEFE scaled 1732

\let \sentinel = \relax
\def \lasttwo #1#2#3\sentinel{\ifx \relax #3\relax #1#2\else #2#3\fi}
\def \zeropad #1#2{\expandafter \expandafter \expandafter \lasttwo \expandafter 0#1#2\sentinel}

\newcount \hours
\newcount \minutes

\hours = \time \divide \hours by 60 \relax
\minutes = \numexpr \time - \hours * 60 \relax

\def \fullmonth
	{%
		\ifcase \the \month 
			Gawdaboveknows
			\or January
			\or February
			\or March
			\or April
			\or May
			\or June
			\or July
			\or August
			\or September
			\or October
			\or November
			\or December
		\else
			Gawdaboveknows
		\fi
	}

\iffulldate
	\def \timestamp {\zeropad \the \hours:\zeropad \the \minutes~\zeropad \the \day-\zeropad \the \month-\the \year}
\else
	\def \timestamp {\fullmonth~\the \year}
\fi

\setbox 4 = \vbox {\cover width \dimexpr \hsize / 2 - 0,666 \rulewidth height \vsize}\relax
\setbox 4 = \vbox {\offinterlineskip \copy 4 \smash {\hbox {\raise 0,0835 \ht 4 \hbox to \wd 4 {\white \hss \timestamp \hss}}}}

\setbox 0 = \hbox {\XeTeXpicfile "\groundright" width 0,5 \hsize height \vsize}
\setbox 0 = \hbox {\box 0 \XeTeXpicfile "\groundleft" width 0,5 \hsize height \vsize}
\setbox 3 = \vbox to 0,9 \vsize 
\bgroup
	\hsize = 0,5 \hsize 
	\hbox to \hsize
	\bgroup
		\vbox
		\bgroup
			\parindent = 0 pt \introfont \leftskip 0,055 \hsize \rightskip = 1,2 \leftskip 
			\vskip 1 ex 
			\baselineskip = 2,2 ex \tolerance = 499 \hyphenchar \font = -1
			On the days of the full and new moons, the old town of Hội An is lit by lanterns, while locals and visitors alike are encouraged to eat
			vegetarian or vegan food and release captive birds or fish.   With this in mind, our Hội-An restaurant offers ‘Vegan Thursday’ every week to		
			encourage more vegan eating by offering a~20\% discount on our whole Vegan range.   We hope that you will enjoy these special dishes,
			which are unique to our restaurant; if~you like them,  do please share news of them with others in your vegan community{\rlap {.}\parfillskip = 0 pt \par}
		\egroup
	\egroup
	\kern -6 ex 
	\line {\hss \hss \raise 0,05 \vsize \box 1 \rule \raise 0,05 \vsize \box 2 \hss}
	\kern -28 ex 
	\baselineskip = 0,9 \baselineskip 
	\parindent = 0 pt 
	\parfillskip = 0 pt 
	\leftskip = 3.95 em plus 0\hsize 
	\rightskip = \leftskip 
	\newdimen \hadjustment
	\hadjustment = 0,3 em
	\advance \leftskip by    -\hadjustment
	\advance \rightskip by +\hadjustment
	\Allergens \ALLERGENS — PLEASE NOTE: \allergens  Whilst we make every effort to prevent  \ALLERGENS from creeping into dishes of which they are
	 not an integral  part,  the very nature of our business means that we cannot offer a~100\%~guaran\-tee that these are not present%
	 {\rlap {.}\parfillskip = 0 pt \par}
	 Please inform your waiter or waitress at the time of ordering if you are \ALLERGIC  to any known \ALLERGENS or other ingredients%
	 {\rlap {.}\parfillskip = 0 pt \par}
	 \vss
\egroup

\font \Algerian = "Algerian:color=008000" at \numexpr 7000 * 925 / 10000 \relax \rootdimen
\font \algerian = "Algerian:color=008000" at \numexpr 5800 * 925 / 10000 \relax \rootdimen

\iffolded
	\def \leftmasthead {\hss \the \toks 0 \hss}
	\def \rightmasthead {}
	\def \leftbox {\box 3 }
	\def \rightbox {\box 4 }
\else
	\def \leftmasthead {}
	\def \rightmasthead {\hss \the \toks 0 \hss}
	\def \leftbox {\box 4 }
	\def \rightbox {\box 3 }
\fi

\setbox 0 = \vbox to \vsize
	\bgroup
		\copy 0 
		\vss
		\toks 0 = {\raise 0,875 \vsize \hbox {\algerian {\Algerian V}egan {\Algerian M}enu}}
		\centerline {\hbox to 0,5 \hsize {\leftmasthead}\hbox to 0,5 \hsize {\rightmasthead}}
		\vss
		\hbox to \hsize {\leftbox \hss \norule \hss \rightbox}\relax
	\egroup
\box 0 

\end


More information about the tex-live mailing list.