mirror of
https://github.com/storytold/designcraft.git
synced 2026-10-24 10:16:59 -06:00
fix(compose): revert slice conversion in tests and remove unused var in warichu
This commit is contained in:
@@ -2892,7 +2892,7 @@ fn test_font(family: &str, os2_fields: Option<&[(usize, i16)]>) -> Vec<u8> {
|
||||
|
||||
/// [`test_font`] with OS/2 `sTypoAscender` set to `typo_ascender`, or without OS/2 for `None`.
|
||||
fn typo_test_font(family: &str, typo_ascender: Option<i16>) -> Vec<u8> {
|
||||
test_font(family, typo_ascender.map(|v| [(TYPO_ASCENDER, v)]).as_ref().map(<[_]>::as_slice))
|
||||
test_font(family, typo_ascender.map(|v| [(TYPO_ASCENDER, v)]).as_ref().map(|f| f.as_slice()))
|
||||
}
|
||||
|
||||
/// First baseline (frame space) of a 20 pt line in `family` in a frame at y = 36 with a 4 pt top
|
||||
|
||||
@@ -217,7 +217,6 @@ fn layout(styles: &[RunStyle], line: &mut [PlacedGlyph], members: &[usize]) -> f
|
||||
restore(line, members, &saved);
|
||||
return 0.0;
|
||||
}
|
||||
let rows = counts.len().max(1);
|
||||
let small = st.size * scale;
|
||||
// 0 is the default (one small em). Any other value, including a negative one, is added to
|
||||
// that em and then clamped so the rows cannot swap order.
|
||||
|
||||
Reference in New Issue
Block a user