Martin Vermeer wrote:

> This bug is apparently not related to the patch. Oldfashioned \frac
> crashes too. It is again a case of "cursor pos in mid-air": create a
> \frac, type a character into the numerator, then into the denominator
> (leaving cur.pos() = 1), then move out of the fraction to the right.
> Then, repeatedly undo.
> 
> At some point you will get a cursor at pos=1, in a cell having only 0
> character positions.

Maybe we should disallow direct write access to DocIterator::pit() and
DocIterator::idx() and provide setter methods that reset pos() if needed.
Or would this be a performance problem?

> Is the FIXME in undo.h related to this?
>  * FIXME: We need something to record undo in partial grids for mathed.
>  * Right now we use recordUndoInset if more than one cell is changed,
>  * but that puts the cursor in front of the inset after undo. We would
>  need * something like
>  * recordUndoGrid(LCursor & cur, Undo::undo_kind kind, idx_type from,
>  idx_type to); * and store the cell information in class Undo.

Not directly. The reason for this FIXME is the fact that the cursor jumps
out of a grid inset after undo, but that is simply an UI issue, the
structure in memory is correct. Maybe we need recordUndoInset instead of
recordUndo at more places?

> I have a backtrace but it is not useful. It looks the same as in earlier
> Are all these in bugzilla?

IIRC not.


Georg

Reply via email to