This gives access to mformat, which is useful for error
reporting (since it allows us to use the standard "can't do that in
this mf version" constructor).
Of course this is an _mf1 function so it doesn't need the actual
value - it could perhaps have made do with a proof token of const
generic type, or something. But I tried that and it was a palaver.
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
impl FaceTransform {
#[throws(LLE)]
- fn from_group_mf1(d: &GroupDetails) -> Self {
+ fn from_group_mf1(group: &GroupData) -> Self {
+ let d = &group.d;
// by this point d.size has already been scaled by scale
let scale = if ! d.orig_size.is_empty() && ! d.size.is_empty() {
izip!(&d.orig_size, &d.size)
#[throws(LibraryLoadError)]
fn load_shape(&self, svg_sz: PosC<f64>) -> (FaceTransform, Outline) {
- let xform = FaceTransform::from_group_mf1(&self.d)?;
+ let xform = FaceTransform::from_group_mf1(self)?;
let outline = self.d.outline.load_mf1(&self, svg_sz)?;
(xform, outline)
}