]> git.lyx.org Git - features.git/commitdiff
Do not remove spaces of keys inside \cite
authorDekel Tsur <dekelts@tau.ac.il>
Wed, 21 Aug 2002 09:14:16 +0000 (09:14 +0000)
committerDekel Tsur <dekelts@tau.ac.il>
Wed, 21 Aug 2002 09:14:16 +0000 (09:14 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@5054 a592a061-630c-0410-9148-cb99ea01b6c8

src/insets/ChangeLog
src/insets/insetcite.C

index db2c69af6e1d72823715604c8a75467c0d5d4bc2..73bd5ad5df2648f41a575fa63e7159a439221483 100644 (file)
@@ -1,3 +1,7 @@
+2002-08-21  Dekel Tsur  <dekelts@tau.ac.il>
+
+       * insetcite.C (latex): Remove spaces only after commmas.
+
 2002-08-21  Lars Gullik Bjønnes  <larsbj@gullik.net>
 
        * insettext.C: remove NO_COMPABILITY stuff
index 7cefcfa783fd5580186610cb497994cf20d34177..0105ddac3650503b22e5b667a38000360f7c55bf 100644 (file)
@@ -373,8 +373,12 @@ int InsetCitation::latex(Buffer const * buffer, ostream & os,
        string::const_iterator end = getContents().end();
        // Paranoia check: make sure that there is no whitespace in here
        string content;
+       char last = ',';
        for (; it != end; ++it) {
-               if (*it != ' ') content += *it;
+               if (*it != ' ')
+                       last = *it;
+               if (*it != ' ' || last != ',')
+                       content += *it;
        }
 
        os << "{" << content << "}";