Honor pdfTeX character program tags and qualify PLOS ONE
This commit is contained in:
1 parent
84ad682939
commit
a1585339b9
21 files changed
+308
-28
No files matched your search
@@ -125,7 +125,7 @@ impl Converter<'_> {
|
||||
continue;
|
||||
}
|
||||
let id = self.state.fonts.glyph_font(font)?;
|
||||
let m = id.metrics();
|
||||
let m = self.state.fonts.program(font)?;
|
||||
let Ok(mut slot) = u8::try_from(c.slot) else {
|
||||
continue;
|
||||
};
|
||||
@@ -134,7 +134,7 @@ impl Converter<'_> {
|
||||
if !visited.insert(slot) {
|
||||
return Err("cyclic native delimiter size list".into());
|
||||
}
|
||||
if m.extensible_recipe(char::from(slot)).is_some() {
|
||||
if m.extensible_recipe(slot).is_some() {
|
||||
opentype_best = None;
|
||||
best = Some((id, slot));
|
||||
break 'search;
|
||||
@@ -148,7 +148,7 @@ impl Converter<'_> {
|
||||
break 'search;
|
||||
}
|
||||
}
|
||||
let Some(next) = m.next_larger(char::from(slot)) else {
|
||||
let Some(next) = m.next_larger(slot) else {
|
||||
break;
|
||||
};
|
||||
slot = next;
|
||||
@@ -163,7 +163,7 @@ impl Converter<'_> {
|
||||
metrics.width, metrics.height, metrics.depth,
|
||||
)
|
||||
} else if let Some((id, slot)) = best {
|
||||
if let Some(recipe) = id.metrics().extensible_recipe(char::from(slot)) {
|
||||
if let Some(recipe) = self.state.fonts.program(id.id)?.extensible_recipe(slot) {
|
||||
let repeat = character(id, recipe.repeat, source)?;
|
||||
let unit = repeat.metrics.height + repeat.metrics.depth;
|
||||
let mut extent = 0;
|
||||
|
||||
Reference in new issue
Block a user