Page 1 of 1

ADDNL problem with RightToLeft mode

Posted: Sun Dec 18, 2005 5:35 pm
by eddy_mar
I made very simple example with following settings:
- RichViewEdit BiDiMode is set to rvbdRightToLeft
- Paragraph BiDiMode is set to rvbdRightToLeft
- Paragraph Alignment is set to rvaRight
- TextStyle BiDiMode is set to rvbdRightToLeft

I have a button with follwing procedure on button click:

AddNL(Edit1.Text, rvsDefStyle, -1);
Format;

Edit1.Text contains some Hebrew values that are changed every time before click.

On my XP machine it works fine, every click adds chars according to RightToLeft scenario.

When I run the same compiled application on Windows 2000 machine, it works different. It always puts added chars to the first position on the right side. I evaluated CurItemNo in inspector and it was always 0. When I just edit a text in the component, it works perfect.

What can be a problem?

Posted: Sun Dec 18, 2005 6:35 pm
by Sergey Tkachenko
Did I understand you right - on Win2000, initially text is displayed wrong, but after making some changes in text all comes to normal?

Posted: Sun Dec 18, 2005 7:06 pm
by Guest
No, A text doesn't come normal. I just wanted to say that manual editing was working, but adding text programmatically does not.

Posted: Sun Dec 18, 2005 7:43 pm
by Sergey Tkachenko
I.e., if (in Win2000) you create a new document by typing, it is created correctly (?) If yes, what happens if you save it as RVF and then reload?

Posted: Sun Dec 18, 2005 8:08 pm
by Guest
Reload doesn't fix the problem.
I made another test: File which I produced on XP machine (it looked correct), I reloaded on Windows 2000 machine and I got the same problem: Order of chars became wrong.

Posted: Sun Dec 18, 2005 8:19 pm
by Sergey Tkachenko
Make sure that Hebrew support is installed in this Windows 2000.
Control Panel, options about language (something like "Regional and Language Options"), find Hebrew in the list of languages and check it.

Posted: Sun Dec 18, 2005 9:16 pm
by Guest
I definetly have full Hebrew support installed on Windows 2000 machine.

I made another test:
I saved the same content from XP machine in two formats (RVF, RTF) and loaded it after on Windows 2000 machine. RTF file was loaded OK, but rvf as I described in my previous post.

Posted: Mon Dec 19, 2005 8:43 am
by Guest
I found today that it works, when "your locale" is set to Hebrew, regardless is it XP or Windows 2000.

Thank you, Sergey!