}
-pos_type Row::Element::x2pos(int &x, bool const select) const
+pos_type Row::Element::x2pos(int &x) const
{
//lyxerr << "x2pos: x=" << x << " w=" << width() << " " << *this;
size_t i = 0;
x = isRTL() ? int(full_width()) : 0;
break;
case INSET:
- case SPACE: {
- int const boundary = select ? (full_width() + 1) / 2 : full_width();
+ case SPACE:
// those elements contain only one position. Round to
// the closest side.
- if (x > boundary) {
+ if (x > (full_width() + 1) / 2) {
x = int(full_width());
i = !isRTL();
} else {
i = isRTL();
}
}
- }
//lyxerr << "=> p=" << pos + i << " x=" << x << endl;
return pos + i;
}