break;
}
- lyxerr[Debug::PARSER] << "Handling paragraph token: `"
+ LYXERR(Debug::PARSER) << "Handling paragraph token: `"
<< token << '\'' << endl;
if (token == "\\begin_layout" || token == "\\end_document"
|| token == "\\end_inset" || token == "\\begin_deeper"
if (isPrintable(c)) {
Language const * language = font.language();
if (language->rightToLeft()) {
- if ((lyxrc.font_norm_type == LyXRC::ISO_8859_6_8 ||
- lyxrc.font_norm_type == LyXRC::ISO_10646_1)
- && language->lang() == "arabic") {
+ if (language->lang() == "arabic") {
if (Encodings::isComposeChar_arabic(c))
return 0;
c = par.transformChar(c, pos);
// This check is necessary. Otherwise the new empty paragraph will
// be deleted automatically. And it is more friendly for the user!
if (cur.pos() != 0 || isempty)
- setCursor(cur.top(), cur.pit() + 1, 0);
+ setCursor(cur, cur.pit() + 1, 0);
else
- setCursor(cur.top(), cur.pit(), 0);
+ setCursor(cur, cur.pit(), 0);
}
bool const trackChanges = cur.buffer().params().trackChanges;
- pos_type right; // needed after the for loop
+ pos_type right = 0; // needed after the for loop
for (pit_type pit = begPit; pit <= endPit; ++pit) {
pos_type parSize = pars_[pit].size();
pos++; // step behind the changing area
}
int erasePos = pos - changes.size();
- for (int i = 0; i < changes.size(); i++) {
+ for (size_t i = 0; i < changes.size(); i++) {
pars_[pit].insertChar(pos, changes[i],
pars_[pit].getFontSettings(cur.buffer().params(),
erasePos),
return;
if (lyxerr.debugging(Debug::DEBUG)) {
- lyxerr[Debug::DEBUG]
+ LYXERR(Debug::DEBUG)
<< BOOST_CURRENT_FUNCTION
<< "draw selection at " << x
<< endl;
}
if (lyxerr.debugging(Debug::DEBUG)) {
- lyxerr[Debug::DEBUG] << " y1: " << y1 << " y2: " << y2
+ LYXERR(Debug::DEBUG) << " y1: " << y1 << " y2: " << y2
<< "X1:" << X1 << " x2: " << X2 << " wid: " << tm.width()
<< endl;
}
ParagraphMetrics const & pm = tm.parMetrics(pit);
int yy = cur.bv().coordCache().get(this, pit).y_ - pm.ascent();
- lyxerr[Debug::DEBUG]
+ LYXERR(Debug::DEBUG)
<< BOOST_CURRENT_FUNCTION
<< ": x: " << x
<< " y: " << y
Row const & row = pm.rows()[r];
- lyxerr[Debug::DEBUG]
+ LYXERR(Debug::DEBUG)
<< BOOST_CURRENT_FUNCTION
<< ": row " << r
<< " from pos: " << row.pos()
pos_type const pos = row.pos()
+ tm.getColumnNearX(pit, row, xx, bound);
- lyxerr[Debug::DEBUG]
+ LYXERR(Debug::DEBUG)
<< BOOST_CURRENT_FUNCTION
<< ": setting cursor pit: " << pit
<< " pos: " << pos