*
* \author John Levon
*
- * Full author contact details are available in file CREDITS
+ * Full author contact details are available in file CREDITS.
*/
#include <config.h>
#include "paragraph.h"
#include "lyxtext.h"
#include "metricsinfo.h"
+#include "paragraph_funcs.h"
+
#include "support/LOstream.h"
+
#include "frontends/Painter.h"
#include "frontends/font_metrics.h"
using std::endl;
-void InsetNewline::read(Buffer const *, LyXLex &)
+void InsetNewline::read(Buffer const &, LyXLex &)
{
/* Nothing to read */
}
-void InsetNewline::write(Buffer const *, ostream & os) const
+void InsetNewline::write(Buffer const &, ostream & os) const
{
os << "\n\\newline \n";
}
}
-int InsetNewline::latex(Buffer const *, ostream &,
+int InsetNewline::latex(Buffer const &, ostream &,
LatexRunParams const &) const
{
lyxerr << "Eek, calling InsetNewline::latex !" << endl;
}
-int InsetNewline::ascii(Buffer const *, ostream & os, int) const
+int InsetNewline::ascii(Buffer const &, ostream & os, int) const
{
os << '\n';
return 0;
}
-int InsetNewline::linuxdoc(Buffer const *, std::ostream & os) const
+int InsetNewline::linuxdoc(Buffer const &, std::ostream & os) const
{
os << '\n';
return 0;
}
-int InsetNewline::docbook(Buffer const *, std::ostream & os, bool) const
+int InsetNewline::docbook(Buffer const &, std::ostream & os, bool) const
{
os << '\n';
return 0;
int const asc = font_metrics::maxAscent(pi.base.font);
// hack, and highly dubious
- lyx::pos_type pos = parOwner()->getPositionOfInset(this);
+ lyx::pos_type pos = ownerPar(*pi.base.bv->buffer(), this)
+ .getPositionOfInset(this);
bool const ltr_pos = (pi.base.bv->text->bidi_level(pos) % 2 == 0);
int xp[3];