Click here to Skip to main content
15,868,340 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Hello guys
I was writing a code that exract words from a text file one by one and making some modification ..etc .. but text file with arabic words is written from right to left and the peek() and read() methodes reads characters from left to right.
is there a solution for my issue ?
any suggestion is very appreciated thanks
Posted
Comments
Sergey Alexandrovich Kryukov 31-Dec-12 17:41pm    
Wow! Who taught you to "think" this way?
—SA

1 solution

This is a big conceptual misunderstanding.

There is no difference between left-to-right and right-to-left languages as the presentation of the text in the file is concerned. There is no such thing as "left" or "right" before you present the text as some page (control, screen, whatever). You cannot deny that in Arabic texts, the text flows from the "beginning" to the "end". From earlier moment of time to later moment of time. And so do the characters in a file. "Left" and "right" are totally insignificant. You read Arabic text from file in exact same way as English or any other.

Happy New Year!

—SA
 
Share this answer
 
v4
Comments
PIEBALDconsult 31-Dec-12 18:23pm    
I'm with you. It's not "left-to-right"; it's "beginning-to-end". Where on a display/page you put those is up to you. I would also state that even with English, if I display text "right-to-left", "top-to-bottom", or mirrored I would probably be understood.
Sergey Alexandrovich Kryukov 31-Dec-12 18:24pm    
Exactly. Thank you.
—SA
ZangetsuZ 3-Jan-13 18:04pm    
thanks a lot for your help guys .. I did not know that information sorry :(
Sergey Alexandrovich Kryukov 3-Jan-13 18:13pm    
Please, no need to apologize. It seems to me it just required some thinking. But I hope now you understand it, as you accepted the answer, thank you.
Best wishes in New Year,
—SA

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900