On Wed, Mar 28, 2007 at 10:53:08AM +0200, Jean-Marc Lasgouttes wrote: > >>>>> "Richard" == Richard Heck <[EMAIL PROTECTED]> writes: > > Richard> I suppose that's possible, but the problem seems to me to be > Richard> the opposite. The way the code was, editXY was being called > Richard> in BufferView::workAreaDispatch for the sole purpose of > Richard> finding the deepest inset over which the mouse pointer is > Richard> located. But editXY does a lot else---it resets the cursor > Richard> and calls LyXText::setCurrentFont, in particular. So it's not > Richard> so much the lack of such a call as the presence of one in > Richard> this method that was causing the problem. > > What I do not understand is why this bug is not present in 1.4 (or is > it?). > > Richard> So it seems to me that, as Bo has said, the best thing to do > Richard> here would certainly be to separate these two aspects: have > Richard> one method that locates the deepest inset and another that > Richard> will reset the cursor and font when that is required. But > Richard> that seems like a lot of work right now. > > I agree this would be the right thing to do. Or rather move the > current font to the cursor.
Why do we need to cache the current font at all? I recreating it so expensive? Andre'