From 933ec6f60484c242cc3cb7b56ececfd47b0797c4 Mon Sep 17 00:00:00 2001 From: ef3d0c3e Date: Wed, 24 Jul 2024 13:34:00 +0200 Subject: [PATCH] Fix graph width --- src/elements/graphviz.rs | 48 ++++++++++++++++++++++++++++++++++++++-- 1 file changed, 46 insertions(+), 2 deletions(-) diff --git a/src/elements/graphviz.rs b/src/elements/graphviz.rs index 9ecb080..6af8b1a 100644 --- a/src/elements/graphviz.rs +++ b/src/elements/graphviz.rs @@ -38,6 +38,7 @@ struct Graphviz { pub location: Token, pub dot: String, pub layout: Layout, + pub width: String, pub caption: Option, } @@ -66,9 +67,13 @@ impl Graphviz { ) { Ok(svg) => { let out = String::from_utf8_lossy(svg.as_slice()); - let split_at = out.find("