]> git.lyx.org Git - lyx.git/blobdiff - src/insets/InsetNewline.cpp
InsetTabular.cpp: fix #6585 also for wrapped floats - thanks Vincent
[lyx.git] / src / insets / InsetNewline.cpp
index 7cb2e70e1f9b5891cc1ec88ccbd1cfbb68da20ba..bb9d714680b9f8ebc6b82d308a7004dae20382aa 100644 (file)
@@ -19,6 +19,7 @@
 #include "Lexer.h"
 #include "MetricsInfo.h"
 #include "OutputParams.h"
+#include "output_xhtml.h"
 
 #include "frontends/Application.h"
 #include "frontends/FontMetrics.h"
@@ -89,7 +90,7 @@ void InsetNewline::metrics(MetricsInfo & mi, Dimension & dim) const
 
 void InsetNewline::doDispatch(Cursor & cur, FuncRequest & cmd)
 {
-       switch (cmd.action) {
+       switch (cmd.action()) {
 
        case LFUN_INSET_MODIFY: {
                InsetNewlineParams params;
@@ -108,7 +109,7 @@ void InsetNewline::doDispatch(Cursor & cur, FuncRequest & cmd)
 bool InsetNewline::getStatus(Cursor & cur, FuncRequest const & cmd,
        FuncStatus & status) const
 {
-       switch (cmd.action) {
+       switch (cmd.action()) {
        // we handle these
        case LFUN_INSET_MODIFY:
                if (cmd.getArg(0) == "newline") {
@@ -173,9 +174,10 @@ int InsetNewline::docbook(odocstream & os, OutputParams const &) const
 }
 
 
-docstring InsetNewline::xhtml(odocstream & os, OutputParams const &) const
+docstring InsetNewline::xhtml(XHTMLStream & xs, OutputParams const &) const
 {
-       os << "<br />\n";
+       xs << html::CompTag("br");
+       xs.cr();
        return docstring();
 }