+2005-06-06 Jürgen Spitzmüller <j.spitzmueller@gmx.de>
+
+ * text.C (redoParagraph): move cursor right after a bibitem
+ has been inserted.
+
+ * text3.C: disable LFUN_BIBITEM_INSERT outside Bibliography.
+
2005-06-02 Jean-Marc Lasgouttes <lasgouttes@lyx.org>
* buffer_funcs.C (bufferErrors): fix computation of the end of an
// Add bibitem insets if necessary
if (par.layout()->labeltype == LABEL_BIBLIO) {
bool hasbibitem(false);
- if (!par.insetlist.empty()
+ if (!par.insetlist.empty()
// Insist on it being in pos 0
&& par.getChar(0) == Paragraph::META_INSET) {
InsetBase * inset = par.insetlist.begin()->inset;
InsetBibitem * inset(new
InsetBibitem(InsetCommandParams("bibitem")));
par.insertInset(0, static_cast<InsetBase *>(inset));
+ bv()->cursor().posRight();
}
}
flag.setOnOff(cur.paragraph().params().startOfAppendix());
return true;
+ case LFUN_INSERT_BIBITEM:
+ enable = (cur.paragraph().layout()->labeltype == LABEL_BIBLIO);
+ break;
+
#if 0
// the functions which insert insets
InsetBase::Code code = InsetBase::NO_CODE;
case LFUN_INSERT_LABEL:
case LFUN_INSERT_NOTE:
case LFUN_INSERT_CHARSTYLE:
- case LFUN_INSERT_BIBITEM:
case LFUN_INSET_FLOAT:
case LFUN_INSET_FOOTNOTE:
case LFUN_INSET_MARGINAL: