Page 1 of 3

A proposal for a feature in RichEditBox control

Posted: Fri Nov 06, 2015 10:12 pm
by esgici
Hello

May be possible adding a feature to RichEditBox for writing right to left ?

Thanks in advance :)

Viva HMG :D

Re: A proposal for a feature in RichEditBox control

Posted: Sat Nov 07, 2015 12:54 am
by srvet_claudio
Ok, no problem.

Re: A proposal for a feature in RichEditBox control

Posted: Sat Nov 07, 2015 1:20 am
by esgici
srvet_claudio wrote:Ok, no problem.
Gracias amigo :) ;

I knew you would help, 8-)

I will wait eagerly :arrow:

Viva HMG :D

BTW : I need an assignable (at run time) property.

Re: A proposal for a feature in RichEditBox control

Posted: Sat Nov 07, 2015 1:40 pm
by kcarmody
esgici wrote:May be possible adding a feature to RichEditBox for writing right to left ?
Perhaps I'm missing something, but the RichEditBox control already supports right-to-left writing. It uses a standard Windows rich edit box, which has supported right-to-left scripts for many years. All the standard Windows controls support right-to-left scripts. See the attached file for a screen shot of the current Rich Edit Demo with Arabic and Hebrew text.

Re: A proposal for a feature in RichEditBox control

Posted: Sat Nov 07, 2015 4:29 pm
by esgici
kcarmody wrote: Perhaps I'm missing something, but the RichEditBox control already supports right-to-left writing. It uses a standard Windows rich edit box, which has supported right-to-left scripts for many years. All the standard Windows controls support right-to-left scripts. See the attached file for a screen shot of the current Rich Edit Demo with Arabic and Hebrew text.
Mr. Carmody;

no, no, please ! It's me who missed something :(

This is very interesting and exactly is that I'm searching :)

Could you please add this feature, by a sign (button, menu item etc) for changing writing direction to our famous RichEdit Demo ?

Thanks in advance :)

Viva HMG :D

Re: A proposal for a feature in RichEditBox control

Posted: Sat Nov 07, 2015 10:56 pm
by kcarmody
esgici wrote:
kcarmody wrote: Perhaps I'm missing something, but the RichEditBox control already supports right-to-left writing. It uses a standard Windows rich edit box, which has supported right-to-left scripts for many years. All the standard Windows controls support right-to-left scripts. See the attached file for a screen shot of the current Rich Edit Demo with Arabic and Hebrew text.
This is very interesting and exactly is that I'm searching :)

Could you please add this feature, by a sign (button, menu item etc) for changing writing direction to our famous RichEdit Demo ?
There is no need to add anything. This feature is already in the Rich Edit Demo. If you copy right-to-left text into the document, it will display properly, and you can edit it as you expect. That's what I did to get the image I posted in my last message. The cursor automatically goes from right to left when it encounters text in a right-to-left script. This is true of almost all controls in Windows.

But you cannot TYPE such text. Are you asking for a feature that would let you type this text? Do you want to press Latin keys and get Arabic or Hebrew output? That is a significant change. I have done it for Devanagari, the alphabet of Sanskrit and Hindi. I think it would not be too hard to make a similar program for Arabic or Hebrew. I don't know Arabic or Hebrew, so it would not be good for me to attempt this.

My Devanagari program is called AksharaPad and is at http://kevincarmody.com/software/aksharapad.html. It's based on my revised version of the HMG Rich Edit Demo, which is at http://kevincarmody.com/hmg/SAMPLES/Con ... chEditBox/.

Kevin

Re: A proposal for a feature in RichEditBox control

Posted: Sun Nov 08, 2015 12:13 am
by esgici
kcarmody wrote:
There is no need to add anything. This feature is already in the Rich Edit Demo. If you copy right-to-left text into the document, it will display properly, and you can edit it as you expect. That's what I did to get the image I posted in my last message. The cursor automatically goes from right to left when it encounters text in a right-to-left script. This is true of almost all controls in Windows.
OK, understood, thanks.
But you cannot TYPE such text. Are you asking for a feature that would let you type this text?


Yes; for me, this is essential.
Do you want to press Latin keys and get Arabic or Hebrew output?


The "virtual keyboard" of Windows is more practical. After set a language, physical keyboard too works for characters of selected language.
That is a significant change. I have done it for Devanagari, the alphabet of Sanskrit and Hindi. I think it would not be too hard to make a similar program for Arabic or Hebrew. I don't know Arabic or Hebrew, so it would not be good for me to attempt this.
OK, understood, thanks. I think it will be hard, because in Arabic shape of each character will change depending on position of that character in the word : beginning, inside and the end.
My Devanagari program is called AksharaPad and is at http://kevincarmody.com/software/aksharapad.html. It's based on my revised version of the HMG Rich Edit Demo, which is at http://kevincarmody.com/hmg/SAMPLES/Con ... chEditBox/.
Again thanks, I will look and work to understand your work.

Thanks again :)

Viva HMG :D

Re: A proposal for a feature in RichEditBox control

Posted: Sun Nov 08, 2015 4:39 am
by kcarmody
esgici wrote:The "virtual keyboard" of Windows is more practical. After set a language, physical keyboard too works for characters of selected language.
The virtual keyboard should let you type into any Windows control. So you can use it with any Windows software, including the Rich Edit Demo as it is now.
esgici wrote:I think it will be hard, because in Arabic shape of each character will change depending on position of that character in the word : beginning, inside and the end.
It may not be as hard as you think. Devanagari has a a similar issue with combining consonants, but Unicode takes most of the pain out of it. Unicode uses "abstract characters" which can change shape depending on the characters around them. For each Latin keystroke, you tell the program which Unicode Arabic character or characters to insert into the document, and the Unicode rendering engine in Windows takes care of selecting the right shape out of the current font.

This assumes you are NOT using a virtual keyboard, but just the ordinary Latin keyboard. This approach is best if you only type Arabic occasionally. You can also decide for yourself exactly how the program will respond to each Latin character.

How Unicode works with Arabic is described in detail in Chapter 9 of the Unicode manual, which you can download from the Unicode web site at http://www.unicode.org/versions/Unicode8.0.0/.

Kevin

Re: A proposal for a feature in RichEditBox control

Posted: Sun Nov 08, 2015 7:14 am
by bpd2000
kcarmody wrote: My Devanagari program is called AksharaPad and is at http://kevincarmody.com/software/aksharapad.html. It's based on my revised version of the HMG Rich Edit Demo, which is at http://kevincarmody.com/hmg/SAMPLES/Con ... chEditBox/.

Kevin
Dear Kevin
How to add Gujarat Language along with Devnagari

Re: A proposal for a feature in RichEditBox control

Posted: Sun Nov 08, 2015 9:57 am
by esgici
kcarmody wrote: ...
This assumes you are NOT using a virtual keyboard, but just the ordinary Latin keyboard. This approach is best if you only type Arabic occasionally. You can also decide for yourself exactly how the program will respond to each Latin character.

How Unicode works with Arabic is described in detail in Chapter 9 of the Unicode manual, which you can download from the Unicode web site at http://www.unicode.org/versions/Unicode8.0.0/.

Kevin
Many thanks to additional info, Mr. Carmody :)

I will check and will work to understand.

Viva HMG :D