summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/fonts/arev/fixkernaccents.tex
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/source/fonts/arev/fixkernaccents.tex')
-rw-r--r--Master/texmf-dist/source/fonts/arev/fixkernaccents.tex44
1 files changed, 18 insertions, 26 deletions
diff --git a/Master/texmf-dist/source/fonts/arev/fixkernaccents.tex b/Master/texmf-dist/source/fonts/arev/fixkernaccents.tex
index 787cc799b96..e12e9e200b6 100644
--- a/Master/texmf-dist/source/fonts/arev/fixkernaccents.tex
+++ b/Master/texmf-dist/source/fonts/arev/fixkernaccents.tex
@@ -1,41 +1,33 @@
% fixkernaccents.tex
-% requires \thenewskewchar to be set to the new skewchar _before_ renaming
+% requires \thenewskewchar to be set to what will be the new skewchar _before_ renaming
-\setcommand\fixaccentkern#1#2#3#4%
-% parameters: character, kern, skewchar bbleft, skewchar bbright
+\setcommand\fixaccentkern#1#2%
+% parameters: character, accentpos (horiz distance from left edge of character, in ppem units)
{
- \resetint{temp}
- {
- \add
+ \ifisglyph{#1}\then % setting a kern or accessing width for a nonexistent glyph causes an error
+ \resetint{temp}
{
- #2 %\kerning{#1}{\skewchar}
- }
- {
- \half
+ \sub
{
- \add
- {
- \sub
- {
- \width{#1}
- }
- {
- \italic{#1}
- }
- }
+ #2 % accentpos
+ }
+ {
+ \half
{
- \add
+ \add % width + italic correction gives the real width for a math glyph
{
- #3 %\bbleft{\skewchar}
+ \width{#1} % distance from the left edge of glyph for positioning the subscript
}
{
- #4 %\bbright{\skewchar}
+ \italic{#1} % offset from subscript for positioning the superscript
}
}
}
}
- }
- \setkern{#1}{\thenewskewchar}{\strint{temp}}
- % Thanks to Lars Hellstrom for pointing out that the third parameter can't be just the \add macro
+ \setkern{#1}{\thenewskewchar}{\strint{temp}}
+ % Thanks to Lars Hellstrom for pointing out that the third parameter can't be just the \add macro
+
+ %\message{Setting kern for #1 to \strint{temp}. AccentPos=#2, Width=\width{#1}, Italic=\italic{#1}.}
+ \Fi
}