]> git.lyx.org Git - lyx.git/blobdiff - src/insets/InsetBibitem.cpp
pimpl not needed here
[lyx.git] / src / insets / InsetBibitem.cpp
index 454d67fdd372b4b9157acbff7bd4507734e5009c..b4a88a7d058a2e80240ae099e81e9adf967bf986 100644 (file)
@@ -18,7 +18,6 @@
 #include "Counters.h"
 #include "DispatchResult.h"
 #include "FuncRequest.h"
-#include "Font.h"
 #include "InsetIterator.h"
 #include "InsetList.h"
 #include "Lexer.h"
@@ -27,6 +26,7 @@
 
 #include "support/lstrings.h"
 #include "support/std_ostream.h"
+#include "support/docstream.h"
 #include "support/convert.h"
 
 
@@ -47,6 +47,15 @@ InsetBibitem::InsetBibitem(InsetCommandParams const & p)
 }
 
 
+CommandInfo const * InsetBibitem::findInfo(std::string const & /* cmdName */)
+{
+       static const char * const paramnames[] = {"label", "key", ""};
+       static const bool isoptional[] = {true, false};
+       static const CommandInfo info = {2, paramnames, isoptional};
+       return &info;
+}
+
+
 Inset * InsetBibitem::clone() const
 {
        InsetBibitem * b = new InsetBibitem(params());
@@ -140,11 +149,10 @@ docstring const bibitemWidest(Buffer const & buffer)
        It is very important that the result of this function is the same both with
        and without GUI. After thinking about this it is clear that no Font
        metrics should be used here, since these come from the gui. If we can't
-       easily get the LaTeX font metrics we should make our own poor mans front
+       easily get the LaTeX font metrics we should make our own poor mans font
        metrics replacement, e.g. by hardcoding the metrics of the standard TeX
        font.
        */
-       Font font;
 
        ParagraphList::const_iterator it = buffer.paragraphs().begin();
        ParagraphList::const_iterator end = buffer.paragraphs().end();