From 1aec9b6479beecd327456780ae7c711040011933 Mon Sep 17 00:00:00 2001 From: bnewbold Date: Sat, 28 Jan 2017 21:25:37 -0800 Subject: fiddling with whitespace for other reprs --- src/repr_latex.rs | 33 ++++++++++++++++++--------------- 1 file changed, 18 insertions(+), 15 deletions(-) (limited to 'src/repr_latex.rs') diff --git a/src/repr_latex.rs b/src/repr_latex.rs index b5426e8..51c9e7a 100644 --- a/src/repr_latex.rs +++ b/src/repr_latex.rs @@ -34,12 +34,13 @@ impl ReprVarsHTML for ModelicaModel { let mut rows = vec![]; for c in &self.components { - rows.push(format!(r#"\({name}\) - {prefix} - {description} - \({default}\) - {specifier} - "#, + rows.push(format!( +r#"\({name}\) + {prefix} + {description} + \({default}\) + {specifier} + "#, prefix = if let Some(ref cp) = c.prefix { format!("{:?}", cp) } else { "free".to_string() }, @@ -53,15 +54,17 @@ impl ReprVarsHTML for ModelicaModel { else { "".to_string() })); } let rows = rows.join("\n"); - Ok(format!(r#" - - - - - - {rows} -
VariableTypeDescriptionValue (default)Datatype
"#, - rows = rows)) + Ok(format!( +r#" + + {rows} +
Variable + Type + Description + Value (default) + Datatype +
"#, + rows = rows.join("\n ")) } } -- cgit v1.2.3