mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-26 11:16:55 +00:00
Fix for insetERT in RTL docs.
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@4132 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
fab4e282c5
commit
93828a784d
@ -1390,7 +1390,10 @@ void BufferView::Pimpl::setState()
|
||||
return;
|
||||
|
||||
LyXText * text = bv_->getLyXText();
|
||||
if (text->real_current_font.isRightToLeft()) {
|
||||
if (text->real_current_font.isRightToLeft()
|
||||
&& !(bv_->theLockingInset()
|
||||
&& bv_->theLockingInset()->lyxCode()== Inset::ERT_CODE))
|
||||
{
|
||||
if (owner_->getIntl()->keymap == Intl::PRIMARY)
|
||||
owner_->getIntl()->KeyMapSec();
|
||||
} else {
|
||||
|
@ -1,3 +1,13 @@
|
||||
2002-05-05 Dekel Tsur <dekelts@tau.ac.il>
|
||||
|
||||
* paragraph.C (isRightToLeftPar): Return false for a paragraph
|
||||
inside insetERT.
|
||||
|
||||
* text.C (computeBidiTables): No bidi in insetERT.
|
||||
|
||||
* BufferView_pimpl.C (setState): Fix keymap handling inside insetERT
|
||||
in RTL documents.
|
||||
|
||||
2002-05-03 Lars Gullik Bjønnes <larsbj@birdstep.com>
|
||||
|
||||
* version.C.in: pre 5
|
||||
|
@ -1984,7 +1984,9 @@ Paragraph::getParLanguage(BufferParams const & bparams) const
|
||||
bool Paragraph::isRightToLeftPar(BufferParams const & bparams) const
|
||||
{
|
||||
return lyxrc.rtl_support
|
||||
&& getParLanguage(bparams)->RightToLeft();
|
||||
&& getParLanguage(bparams)->RightToLeft()
|
||||
&& !(inInset() && inInset()->owner() &&
|
||||
inInset()->owner()->lyxCode() == Inset::ERT_CODE);
|
||||
}
|
||||
|
||||
|
||||
|
@ -283,6 +283,13 @@ void LyXText::computeBidiTables(Buffer const * buf, Row * row) const
|
||||
return;
|
||||
}
|
||||
|
||||
Inset * inset = row->par()->inInset();
|
||||
if (inset && inset->owner() &&
|
||||
inset->owner()->lyxCode() == Inset::ERT_CODE) {
|
||||
bidi_start = -1;
|
||||
return;
|
||||
}
|
||||
|
||||
bidi_start = row->pos();
|
||||
bidi_end = rowLastPrintable(row);
|
||||
|
||||
@ -306,7 +313,7 @@ void LyXText::computeBidiTables(Buffer const * buf, Row * row) const
|
||||
|
||||
pos_type stack[2];
|
||||
bool const rtl_par =
|
||||
row->par()->getParLanguage(buf->params)->RightToLeft();
|
||||
row->par()->isRightToLeftPar(buf->params);
|
||||
int level = 0;
|
||||
bool rtl = false;
|
||||
bool rtl0 = false;
|
||||
|
Loading…
Reference in New Issue
Block a user