]> git.lyx.org Git - features.git/commitdiff
Small clean-up of natbib code
authorAngus Leeming <leeming@lyx.org>
Thu, 26 Jul 2001 09:47:36 +0000 (09:47 +0000)
committerAngus Leeming <leeming@lyx.org>
Thu, 26 Jul 2001 09:47:36 +0000 (09:47 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@2356 a592a061-630c-0410-9148-cb99ea01b6c8

src/ChangeLog
src/LaTeXFeatures.C
src/insets/insetbib.h

index 20633b9e2851e5aad2b75bbbff74f22a70cfa698..2430c4e776f452a9101f407747d190d1cba110e7 100644 (file)
@@ -1,3 +1,7 @@
+2001-07-25  Angus Leeming  <a.leeming@ic.ac.uk>
+
+       * LaTeXFeatures.C (getPackages): clean-up a little of the natbib code.
+
 2001-07-26  Lars Gullik Bjønnes  <larsbj@birdstep.com>
 
        * buffer.C (parseSingleLyXformat2Token): a more general fix for
index 9b4d15f29a230bd6db1730529615485b2c4c3d08..6c9de09ef720c4433dc57ac4e9893b188135945e 100644 (file)
@@ -278,15 +278,15 @@ string const LaTeXFeatures::getPackages() const
 
        // natbib.sty
        if (natbib) {
-               string options("[]");
-               if (params.use_numerical_citations)
-                       options.insert(1, "numbers");
-               else
-                       options.insert(1, "authoryear");
-               packages << "\\usepackage" << options << "{natbib}\n";
+               packages << "\\usepackage[";
+               if (params.use_numerical_citations) {
+                       packages << "numbers";
+               } else {
+                       packages << "authoryear";
+               }
+               packages << "]{natbib}\n";
        }
        
-
        packages << externalPreambles;
 
        return packages.str().c_str();
index f870f636ed246d526f9082fa157dd4a134cc1988..50cf26f368cb19c7627fdbce6c86a11570828513 100644 (file)
@@ -47,9 +47,7 @@ public:
        ///
        void edit(BufferView * bv, bool front = true);
        ///
-       EDITABLE editable() const {
-               return IS_EDITABLE;
-       }
+       EDITABLE editable() const { return IS_EDITABLE; } 
        /// A user can't neither insert nor delete this inset
        bool deletable() const {
                return false;