]> git.lyx.org Git - lyx.git/blobdiff - src/text2.C
citation patch from Angus
[lyx.git] / src / text2.C
index bbd6061d3732657d817e0875b1617a28d1854da9..f2d5876271b9c893568cc9d97e6e3dc1ed909ef5 100644 (file)
@@ -1376,7 +1376,11 @@ void LyXText::MeltFootnoteEnvironment(BufferView * bview)
                tmppar->next->MakeSameLayout(cursor.par());
 
        // first the end
-       if ((!tmppar->GetLayout() && !tmppar->table)
+       if ((!tmppar->GetLayout()
+#ifndef NEW_TABULAR
+            && !tmppar->table
+#endif
+               )
            || (tmppar->Next()
                && (!tmppar->Next()->Last()
                    || tmppar->Next()->HasSameLayout(tmppar)))) {
@@ -1393,7 +1397,11 @@ void LyXText::MeltFootnoteEnvironment(BufferView * bview)
        /* if there is no space between the text and the footnote, so we insert
         * a blank 
         * (only if the previous par and the footnotepar are not empty!) */
-       if ((!firsttmppar->next->GetLayout() && !firsttmppar->next->table)
+       if ((!firsttmppar->next->GetLayout()
+#ifndef NEW_TABULAR
+            && !firsttmppar->next->table
+#endif
+               )
            || firsttmppar->HasSameLayout(firsttmppar->next)) {
                if (firsttmppar->size()
                    && !firsttmppar->IsSeparator(firsttmppar->size() - 1)
@@ -2027,8 +2035,10 @@ void LyXText::SetCounter(Buffer const * buf, LyXParagraph * par) const
                int i = LABEL_COUNTER_ENUMI - LABEL_COUNTER_CHAPTER + par->enumdepth;
                par->incCounter(i);
                int number = par->getCounter(i);
-               if (!par->bibkey)
-                       par->bibkey = new InsetBibKey();
+               if (!par->bibkey) {
+                       InsetCommandParams p( "bibitem" );
+                       par->bibkey = new InsetBibKey(p);
+               }
                par->bibkey->setCounter(number);
                par->labelstring = layout.labelstring();