Am 08.03.2011 um 17:36 schrieb Ronen Abravanel:

> My most common situation in which this is a problem is the following
> 
> Hebrew text (English translation) more hebrew..
> 
> For most language, you wouldn't mind if the " ( )" will be in English or in 
> other language, but Hebrew is written from right to left, which means the 
> Parentheses  are written in reverse. Meaning, if the closing parentheses will 
> be in English, it will apear as:
> 
> Hebrew text ((English Hebrew
> 
> (Or something like that)
> 
> there fore, the following parentheses or comma must be at the same language 
> as the paragraph language, and not as the last-word language.

I believe you.

The attached patch changes this to restore the old behavior when cursor is at 
the word end.
Ok to apply?

Stephan

/Users/Shared/LyX ~/cvs/lyx /Users/Shared/LyX/lyx-build/LyX-2.0.0svn.build
Index: src/Text3.cpp
===================================================================
--- src/Text3.cpp       (Revision 37877)
+++ src/Text3.cpp       (Arbeitskopie)
@@ -1890,7 +1890,8 @@
                Language const * lang = 
languages.getLanguage(to_utf8(cmd.argument()));
                if (!lang)
                        break;
-               selectWordWhenUnderCursor(cur, WHOLE_WORD);
+               if (!cur.paragraph().isWordSeparator(cur.pos()))
+                       selectWordWhenUnderCursor(cur, WHOLE_WORD);
                Font font(ignore_font, lang);
                toggleAndShow(cur, this, font);
                break;

Reply via email to