]> git.lyx.org Git - lyx.git/blobdiff - src/Text2.cpp
Fix #9792 cyrtext and textcyr in the preamble of every document.
[lyx.git] / src / Text2.cpp
index 7b3d4da8c614a6c7372f77f3f5a690eb19dfae6e..9e6ec8ee1f038c0dbf7815f11c6c34c14b67757c 100644 (file)
@@ -22,7 +22,6 @@
 
 #include "Text.h"
 
-#include "Bidi.h"
 #include "Buffer.h"
 #include "buffer_funcs.h"
 #include "BufferList.h"
@@ -199,6 +198,7 @@ void Text::setLayout(Cursor & cur, docstring const & layout)
        pit_type end = cur.selEnd().pit() + 1;
        cur.recordUndoSelection();
        setLayout(start, end, layout);
+       cur.setCurrentFont();
        cur.forceBufferUpdate();
 }
 
@@ -614,6 +614,7 @@ bool Text::checkAndActivateInset(Cursor & cur, bool front)
        if (!front)
                --cur.pos();
        inset->edit(cur, front);
+       cur.setCurrentFont();
        return true;
 }
 
@@ -632,6 +633,7 @@ bool Text::checkAndActivateInsetVisual(Cursor & cur, bool movingForward, bool mo
                return false;
        inset->edit(cur, movingForward, 
                movingLeft ? Inset::ENTRY_DIRECTION_RIGHT : Inset::ENTRY_DIRECTION_LEFT);
+       cur.setCurrentFont();
        return true;
 }