Skip to content

Commit 9fde728

Browse files
committed
Oops, fixed is a float
1 parent 7ef0a64 commit 9fde728

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

ttj/src/serializefont.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ impl<'a> ToValue for FieldType<'a> {
2929
Self::MajorMinor(arg0) => Value::String(format!("{}.{}", arg0.major, arg0.minor)),
3030
Self::Version16Dot16(arg0) => Value::String(format!("{}", *arg0)),
3131
Self::F2Dot14(arg0) => Value::Number(Number::from_f64(arg0.to_f32() as f64).unwrap()),
32-
Self::Fixed(arg0) => Value::Number(Number::from(arg0.to_i32())),
32+
Self::Fixed(arg0) => Value::Number(Number::from_f64(arg0.to_f32() as f64).unwrap()),
3333
Self::LongDateTime(arg0) => Value::Number(arg0.as_secs().into()),
3434
Self::GlyphId16(arg0) => Value::String(format!("g{}", arg0.to_u16())),
3535
Self::NameId(arg0) => Value::String(arg0.to_string()),

0 commit comments

Comments
 (0)