Fix text direction issue for InsetInfo in RTL context

Fixes: #10463
This commit is contained in:
Juergen Spitzmueller 2018-07-25 11:00:00 +02:00
parent 99aefa5fd2
commit 79cf3f5ec1
2 changed files with 9 additions and 0 deletions

View File

@ -21,6 +21,7 @@
#include "InsetSpecialChar.h"
#include "KeyMap.h"
#include "LaTeXFeatures.h"
#include "Language.h"
#include "LayoutFile.h"
#include "Length.h"
#include "LyXAction.h"
@ -296,6 +297,12 @@ void InsetInfo::setText(docstring const & str)
}
bool InsetInfo::forceLTR() const
{
return !buffer().params().language->rightToLeft();
}
void InsetInfo::updateBuffer(ParIterator const & it, UpdateType utype) {
// If the Buffer is a clone, then we neither need nor want to do any
// of what follows. We want, rather, just to inherit how things were

View File

@ -125,6 +125,8 @@ public:
bool getStatus(Cursor &, FuncRequest const &, FuncStatus &) const;
///
void doDispatch(Cursor & cur, FuncRequest & cmd);
/// Force inset into LTR environment if surroundings are RTL
bool forceLTR() const;
///
void setInfo(std::string const & info);
///