From: Uwe Stöhr Date: Sun, 19 Jul 2009 20:01:39 +0000 (+0000) Subject: Length.cpp: take care of percent units also for glue lengths, with this change, ... X-Git-Tag: 2.0.0~5957 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=969a8356b8e9e93c37a855f3402b55f582f8831d;p=features.git Length.cpp: take care of percent units also for glue lengths, with this change, #6091 and #6098 can be fixed git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30693 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/Length.cpp b/src/Length.cpp index af61d0fe76..4b269aa315 100644 --- a/src/Length.cpp +++ b/src/Length.cpp @@ -427,13 +427,12 @@ string const GlueLength::asString() const string const GlueLength::asLatexString() const { ostringstream buffer; - - buffer << len_.value() << unit_name[len_.unit()]; - + // use Length::asLatexString() to handle also the percent lengths + buffer << len_.Length::asLatexString(); if (!plus_.zero()) - buffer << " plus " << plus_.value() << unit_name[plus_.unit()]; + buffer << " plus " << plus_.Length::asLatexString(); if (!minus_.zero()) - buffer << " minus " << minus_.value() << unit_name[minus_.unit()]; + buffer << " minus " << minus_.Length::asLatexString(); return buffer.str(); }