revert hazardous part of r26957 and add a comment.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@27169 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Abdelrazak Younes 2008-10-28 17:51:08 +00:00
parent bc79c203a9
commit 070d75f1c6

View File

@ -914,8 +914,8 @@ void replaceSelectionWithString(Cursor & cur, docstring const & str, bool backwa
cur.recordUndo();
DocIterator selbeg = cur.selectionBegin();
// Get font setting before we cut
Font const & font =
// Get font setting before we cut, we need a copy here, not a bare reference.
Font const font =
selbeg.paragraph().getFontSettings(cur.buffer().params(), selbeg.pos());
// Insert the new string