#include "Color.h"
#include "Length.h"
#include "LyXRC.h"
-#include "LyXText.h"
+#include "Text.h"
#include "MetricsInfo.h"
#include "ParagraphParameters.h"
#include "VSpace.h"
} // namespace anon
-TextMetrics::TextMetrics(BufferView * bv, LyXText * text)
+TextMetrics::TextMetrics(BufferView * bv, Text * text)
: bv_(bv), text_(text)
{
BOOST_ASSERT(bv_);
BOOST_ASSERT(mi.base.textwidth);
max_width_ = mi.base.textwidth;
- //lyxerr << "LyXText::metrics: width: " << mi.base.textwidth
+ //lyxerr << "Text::metrics: width: " << mi.base.textwidth
// << " maxWidth: " << max_width_ << "\nfont: " << mi.base.font << endl;
bool changed = false;
result.x = text_->leftMargin(buffer, max_width_, pit, row.pos());
// is there a manual margin with a manual label
- LyXLayout_ptr const & layout = par.layout();
+ Layout_ptr const & layout = par.layout();
if (layout->margintype == MARGIN_MANUAL
&& layout->labeltype == LABEL_MANUAL) {
return;
}
- LyXLayout_ptr const & layout = par.layout();
+ Layout_ptr const & layout = par.layout();
if (layout->margintype == MARGIN_RIGHT_ADDRESS_BOX) {
row.endpos(addressBreakPoint(pos, par));
// ok, let us initialize the maxasc and maxdesc value.
// Only the fontsize count. The other properties
// are taken from the layoutfont. Nicer on the screen :)
- LyXLayout_ptr const & layout = par.layout();
+ Layout_ptr const & layout = par.layout();
// as max get the first character of this row then it can
// increase but not decrease the height. Just some point to
// is it a top line?
if (row.pos() == 0) {
BufferParams const & bufparams = buffer.params();
- // some parksips VERY EASY IMPLEMENTATION
+ // some parskips VERY EASY IMPLEMENTATION
if (bufparams.paragraph_separation
== BufferParams::PARSEP_SKIP
+ && par.ownerCode() != Inset::ERT_CODE
&& pit > 0
&& ((layout->isParagraph() && par.getDepth() == 0)
|| (pars[pit - 1].layout()->isParagraph()
// FIXME: the correct way is to do the following is to move the
// following code in another method specially tailored for the
- // main LyXText. The following test is thus bogus.
+ // main Text. The following test is thus bogus.
// Top and bottom margin of the document (only at top-level)
if (main_text_) {
if (pit == 0 && row.pos() == 0)
{
Buffer const & buffer = *bv_->buffer();
- /// For the main LyXText, it is possible that this pit is not
+ /// For the main Text, it is possible that this pit is not
/// yet in the CoordCache when moving cursor up.
/// x Paragraph coordinate is always 0 for main text anyway.
int const xo = main_text_? 0 : bv_->coordCache().get(text_, pit).x_;
pos_type vc = row.pos();
pos_type end = row.endpos();
pos_type c = 0;
- LyXLayout_ptr const & layout = par.layout();
+ Layout_ptr const & layout = par.layout();
bool left_side = false;
}
-//int LyXText::pos2x(pit_type pit, pos_type pos) const
+//int Text::pos2x(pit_type pit, pos_type pos) const
//{
// ParagraphMetrics const & pm = parMetrics(pit);
// Row const & r = pm.rows()[row];