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;
|
return;
|
||||||
|
|
||||||
LyXText * text = bv_->getLyXText();
|
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)
|
if (owner_->getIntl()->keymap == Intl::PRIMARY)
|
||||||
owner_->getIntl()->KeyMapSec();
|
owner_->getIntl()->KeyMapSec();
|
||||||
} else {
|
} 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>
|
2002-05-03 Lars Gullik Bjønnes <larsbj@birdstep.com>
|
||||||
|
|
||||||
* version.C.in: pre 5
|
* version.C.in: pre 5
|
||||||
|
@ -1984,7 +1984,9 @@ Paragraph::getParLanguage(BufferParams const & bparams) const
|
|||||||
bool Paragraph::isRightToLeftPar(BufferParams const & bparams) const
|
bool Paragraph::isRightToLeftPar(BufferParams const & bparams) const
|
||||||
{
|
{
|
||||||
return lyxrc.rtl_support
|
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;
|
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_start = row->pos();
|
||||||
bidi_end = rowLastPrintable(row);
|
bidi_end = rowLastPrintable(row);
|
||||||
|
|
||||||
@ -306,7 +313,7 @@ void LyXText::computeBidiTables(Buffer const * buf, Row * row) const
|
|||||||
|
|
||||||
pos_type stack[2];
|
pos_type stack[2];
|
||||||
bool const rtl_par =
|
bool const rtl_par =
|
||||||
row->par()->getParLanguage(buf->params)->RightToLeft();
|
row->par()->isRightToLeftPar(buf->params);
|
||||||
int level = 0;
|
int level = 0;
|
||||||
bool rtl = false;
|
bool rtl = false;
|
||||||
bool rtl0 = false;
|
bool rtl0 = false;
|
||||||
|
Loading…
Reference in New Issue
Block a user