]> git.lyx.org Git - lyx.git/blobdiff - src/insets/InsetListings.cpp
Pure HTML output for math macros.
[lyx.git] / src / insets / InsetListings.cpp
index ba7de456e1897416134d66722ca1cdebd424034d..de0e26ae45c4b04bc3b24dd8fa839eead056c1ee 100644 (file)
@@ -24,7 +24,7 @@
 #include "FuncStatus.h"
 #include "InsetCaption.h"
 #include "Language.h"
-#include "MetricsInfo.h"
+#include "Lexer.h"
 #include "output_latex.h"
 #include "output_xhtml.h"
 #include "TextClass.h"
@@ -71,7 +71,7 @@ Inset::DisplayType InsetListings::display() const
 }
 
 
-void InsetListings::updateLabels(ParIterator const & it, bool out)
+void InsetListings::updateBuffer(ParIterator const & it, UpdateType utype)
 {
        Counters & cnts = buffer().masterBuffer()->params().documentClass().counters();
        string const saveflt = cnts.current_float();
@@ -79,7 +79,7 @@ void InsetListings::updateLabels(ParIterator const & it, bool out)
        // Tell to captions what the current float is
        cnts.current_float("listing");
 
-       InsetCollapsable::updateLabels(it, out);
+       InsetCollapsable::updateBuffer(it, utype);
 
        //reset afterwards
        cnts.current_float(saveflt);
@@ -275,27 +275,27 @@ docstring InsetListings::xhtml(XHTMLStream & os, OutputParams const & rp) const
 
        bool const isInline = params().isInline();
        if (isInline) 
-               out << CompTag("br");
+               out << html::CompTag("br");
        else {
-               out << StartTag("div", "class='float float-listings'");
+               out << html::StartTag("div", "class='float float-listings'");
                docstring caption = getCaptionHTML(rp);
                if (!caption.empty())
-                       out << StartTag("div", "class='float-caption'") 
-                           << caption << EndTag("div");
+                       out << html::StartTag("div", "class='float-caption'") 
+                           << caption << html::EndTag("div");
        }
 
-       out << StartTag("pre");
+       out << html::StartTag("pre");
        OutputParams newrp = rp;
        newrp.html_disable_captions = true;
        docstring def = InsetText::insetAsXHTML(out, newrp, InsetText::JustText);
-       out << EndTag("pre");
+       out << html::EndTag("pre");
 
        if (isInline) {
-               out << CompTag("br");
+               out << html::CompTag("br");
                // escaping will already have been done
                os << XHTMLStream::NextRaw() << ods.str();
        } else {
-               out << EndTag("div");
+               out << html::EndTag("div");
                // In this case, this needs to be deferred, but we'll put it
                // before anything the text itself deferred.
                def = ods.str() + '\n' + def;