summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/teubner/teubner.dtx
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/teubner/teubner.dtx')
-rw-r--r--macros/latex/contrib/teubner/teubner.dtx63
1 files changed, 39 insertions, 24 deletions
diff --git a/macros/latex/contrib/teubner/teubner.dtx b/macros/latex/contrib/teubner/teubner.dtx
index 6a3e029252..bd656ecbda 100644
--- a/macros/latex/contrib/teubner/teubner.dtx
+++ b/macros/latex/contrib/teubner/teubner.dtx
@@ -43,7 +43,7 @@ See the end of the file.
%<package>\ProvidesPackage{teubner}[%
%<tbtx>\ProvidesPackage{teubnertx}[%
%<*driver,package,tbtx>
-2022/10/01 v.5.7.1
+2022/10/03 v.5.7.3
%<package>Extensions for Greek philology]
%<tbtx>Access to the LGR encoded Greek fonts that match the TX fonts]
%</driver,package,tbtx>
@@ -84,7 +84,7 @@ See the end of the file.
%</driver>
% \fi
%
-% \CheckSum{4190}
+% \CheckSum{4206}
% \begin{multicols}{2}\tableofcontents\end{multicols}
%
%
@@ -618,7 +618,9 @@ Type X <return> to exit.}%
\DeclareFontShape{U}{mtr}{m}{it}{<->ssub*mtr/m/n}{}%
\DeclareFontShape{U}{mtr}{b}{it}{<->ssub*mtr/m/n}{}%
\DeclareFontShape{U}{mtr}{bx}{n}{<->ssub*mtr/m/n}{}%
-\newcommand*\metricsfont{\fontencoding{U}\fontfamily{mtr}\normalshape}
+\DeclareRobustCommand*\metricsfont{%
+ \fontencoding{U}\fontfamily{mtr}\normalshape}
+\DeclareTextFontCommand{\textmtr}{\metricsfont}
% \end{macrocode}
% \end{macro} Next we require the package for extensible math fonts;
% it might be strange to use extensible math fonts in Greek philology,
@@ -1024,16 +1026,16 @@ Type X <return> to exit.}%
\ProvideDocumentEnvironment{GRL}{m}{}{}
\RenewDocumentEnvironment{GRL}{o}{\begin{otherlanguage*}{greek}%
-\@ifclassloaded{memoir}{\def\bfseries{\fontseries{bx}\selectfont}}{\relax}
-\@ifclassloaded{scrbook}{\def\bfseries{\fontseries{bx}\selectfont}}{\relax}
+\@ifclassloaded{memoir}{\def\bfseries{\fontseries{bx}\selectfont}}{\relax}%
+\@ifclassloaded{scrbook}{\def\bfseries{\fontseries{bx}\selectfont}}{\relax}%
\IfValueTF{#1}{\fontseries{#1}}{}%
- \fontshape{li}\selectfont}{\end{otherlanguage*}}
+ \fontshape{li}\selectfont}{\end{otherlanguage*}}%
\RenewDocumentEnvironment{GRD}{o}{\begin{otherlanguage*}{greek}%
-\@ifclassloaded{memoir}{\def\bfseries{\fontseries{bx}\selectfont}}{\relax}
-\@ifclassloaded{scrbook}{\def\bfseries{\fontseries{bx}\selectfont}}{\relax}
+\@ifclassloaded{memoir}{\def\bfseries{\fontseries{bx}\selectfont}}{\relax}%
+\@ifclassloaded{scrbook}{\def\bfseries{\fontseries{bx}\selectfont}}{\relax}%
\IfValueTF{#1}{\fontseries{#1}}{}%
- \fontshape{up}\selectfont}{\end{otherlanguage*}}
+ \fontshape{up}\selectfont}{\end{otherlanguage*}}%
}
% \end{macrocode}
%\end{environment}
@@ -1066,9 +1068,9 @@ Type X <return> to exit.}%
%\begin{macro}{\textui}
%\begin{macro}{\rsshape}
%\begin{macro}{\textrs}
-% The other switching font macros for using the other shapes that are available
-% with the CB fonts are working only when typesetting in Greek and the default
-% encoding is therefore LGR.
+% The other switching font macros for using the other shapes that are
+% available with the CB fonts are working only when typesetting in
+% Greek and the default encoding is therefore LGR.
% \begin{macrocode}
\DeclareRobustCommand\uishape{%
\ifthenelse{\equal{\f@encoding}{\GRenc@name}}%
@@ -2220,7 +2222,9 @@ Type X <return> to exit.}%
% designed as to be higher and deeper than the font total height, so as
% not to interfere with Greek accents and to accomodate for at least one
% level of nesting (for example square brackets enclosing lower part of
-% square brackets. The single glyphs may be used directly by the
+% square brackets.
+%
+% The single glyphs may be used directly by the
% typesetter, but we think that the commands requiring some text are
% far more useful. |\Ladd| and its double version |\LLadd| enclose text
% that should be added for sure. |\ladd| and its double version |\lladd|
@@ -2229,20 +2233,29 @@ Type X <return> to exit.}%
% with the lower part of open and closed square brackets. |\mqs| surrounds
% some text with the upper part of open and closed square brackets.
% See \texttt{teubenr-doc.pdf} for samples of such commands.
+%
% Command |\LLadd| has been modified since |teubner| previous version
-% because it contained a spurios space; in addition it has been
+% because it contained a spurious space; in addition it has been
% rewritten with the |\NewDocumentCommand| in \LaTeX\,3 language, so as
% to accept two optional kerning values so as to get the double square
-% brackets closer to the enclosed text; it syntax is now
+% brackets closer to the enclosed text; its syntax is now
%\begin{sintassi}
%\cs{LLadd}\oarg{left kerning}\marg{text}\oarg{right kerning}
%\end{sintassi}
-% Both kerning values are positive in order to get the square brackets
+% Both kerning values are positive in order to get the angle brackets
% closer to the text; this facility is especially useful with slanted
% text. In any case such kernings should be set only while reviewing the
% document draft. We suggest to use units of measure depending on the
-% font body (|ex| or |em|) so that if the body is changed the corrections
-% keep working properly.
+% font size (|ex| or |em|) so that if the size is changed the corrections
+% keep working properly. Some settings are already part of the code in
+% order to kern the angle brackets and the \meta{text} depending on the
+% font slant; but, when capital letters appear at the beginning or at
+% the end of the \meta{text} string, some small correction might be
+% necessary; similar small corrections might be different if the capital
+% is inscribed in a triangle, as A, T, Y, V, and the like; in substance
+% such small corrections might result necessary while reviewing the
+% document drafts, because they depend too much from the particular
+% \meta{text} string.
% \begin{macrocode}
\DeclareRobustCommand{\lbrk}{{\metricsfont\posthindspace[\negthinspace}}
\DeclareRobustCommand{\rbrk}{{\metricsfont]}}
@@ -2253,13 +2266,15 @@ Type X <return> to exit.}%
\DeclareRobustCommand\mqi[1]{\posthinspace\lmqi\negthinspace
{#1\/}\rmqi}\let\mezzeq\mqi
\DeclareRobustCommand\mqs[1]{\lmqs{#1\/}\rmqs}
-\DeclareRobustCommand{\Ladd}[1]{{\metricsfont<}{\!\!#1\/}%
- {\metricsfont>}}% litterae certe addendae
+\DeclareRobustCommand{\Ladd}[1]{%
+ \textmtr{<}{\!\!#1\/}\textmtr{>}}% litterae certe addendae
\providecommand\LLadd{}
-\RenewDocumentCommand{\LLadd}{O{0pt}m O{0pt}}{%
- {\metricsfont<\kern-0.3ex<\kern-0.3ex}{\kern-#1\relax#2\kern-#3}%
- {\metricsfont>\kern-0.3ex>}%
-}% litterae certe addendae
+\DeclareRobustCommand\LLaddKern[2]%
+ {\ifdim\fontdimen1\font=\z@\kern#1\else\kern#2\fi}
+\RenewDocumentCommand{\LLadd}{O{0pt} m O{0pt}}{% litterae certe addendae
+ \textmtr{<\kern-0.3ex<}{\LLaddKern{-0.1ex}{-0.3ex}%
+ \kern-#1\relax#2\/\LLaddKern{\z@}{0.1ex}\kern-#3}\textmtr{>\kern-0.3ex>}%
+}%
\DeclareRobustCommand{\ladd}[1]{{\metricsfont\kern.15ex[\negthinspace}%
{#1\/}{\metricsfont]\kern-.15ex}}% litterae addendae
\DeclareRobustCommand{\lladd}[1]{{\metricsfont\kern.15ex[\kern-.3ex[%