* Re: Re: emacs + unicode + hebrew + bidi
@ 2008-11-04 11:44 cyberkm
0 siblings, 0 replies; 4+ messages in thread
From: cyberkm @ 2008-11-04 11:44 UTC (permalink / raw)
To: help-gnu-emacs
[-- Attachment #1: Type: text/plain, Size: 1660 bytes --]
Thank you, but unforunatly, it is not a solution -
Hebrew is not simple right to left
its a BI-Directional. Then text is written from rtl the number ltr, what
about the punctuation signs, spaces and etc..
the bi-di code is very complex
On Nov 4, 2008 5:05am, "BT Raven" <nihil@nihilo.net> wrote:
> BT Raven wrote:
>
>
> BT Raven wrote:
>
>
> Pavel wrote:
>
>
> Hi everybody, i would like to know if the combination i mentioned in the
>
> subject is possible.
>
> I would like to write Hebrew latex documents in emacs, but unfortunately
the
>
> Hebrew is reversed.
>
> Thanx
>
>
>
>
>
>
> As a kludge you could type everything left to right and then apply this
function to the whole buffer:
>
>
>
> (defun reverse-bstring (str)
>
> (apply #'string (nreverse (string-to-list (buffer-string))))
>
>
>
> There is something perverse about it since it doesn't seem to need to be
passed a string but, anyway, evaluating it in *Scratch* produces this:
>
>
>
> "
>
> ))))gnirts-reffub( tsil-ot-gnirts( esrevern( gnirts'# ylppa(
>
> )rts( gnirtsb-esrever nufed(
>
>
>
> ..reffub nwo s'elif taht ni txet eht retne neht ;;
>
> ,fC xC htiw elif taht tisiv ,elif a etaerc ot tnaw uoy fI ;;
>
> ..noitaulave psiL rof dna ,evas ot tnaw t'nod uoy seton rof si reffub
sihT ;;"
>
>
>
> Ed
>
>
>
>
> Of course you want to do this line by line, not to the whole buffer,
since in Hebrew and Arabic you start at the back of the book but not at the
bottom of the page. O well, back to the drawing board.
>
>
>
>
> You could then demarcate the above text as a region and then run Mx
reverse-region on it. It's still a kludge but it might work on multi-byte
buffers.
>
[-- Attachment #2: Type: text/html, Size: 2309 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: Re: emacs + unicode + hebrew + bidi
@ 2008-11-04 13:06 Bourgneuf Francois
2008-11-04 14:55 ` Jonathan Groll
0 siblings, 1 reply; 4+ messages in thread
From: Bourgneuf Francois @ 2008-11-04 13:06 UTC (permalink / raw)
To: help-gnu-emacs
[-- Attachment #1: Type: text/plain, Size: 2503 bytes --]
Just a precision, in arabic and hebrew both text and numbers are written right to left.
In western languages text is written left to right and numbers right to left.
You can't tell the value of the left digit of a number if you havent read how many digit are at his right.
We solve additions from the right to the left.
Bour9
_____
De : help-gnu-emacs-bounces+francois.bourgneuf=groupe-mma.fr@gnu.org [mailto:help-gnu-emacs-bounces+francois.bourgneuf=groupe-mma.fr@gnu.org] De la part de cyberkm@gmail.com
Envoyé : mardi 4 novembre 2008 12:45
À : help-gnu-emacs@gnu.org
Objet : Re: Re: emacs + unicode + hebrew + bidi
Thank you, but unforunatly, it is not a solution -
Hebrew is not simple right to left
its a BI-Directional. Then text is written from rtl the number ltr, what
about the punctuation signs, spaces and etc..
the bi-di code is very complex
On Nov 4, 2008 5:05am, "B. T. Raven" <nihil@nihilo.net> wrote:
> B. T. Raven wrote:
>
>
> B. T. Raven wrote:
>
>
> Pavel wrote:
>
>
> Hi everybody, i would like to know if the combination i mentioned in the
>
> subject is possible.
>
> I would like to write Hebrew latex documents in emacs, but unfortunately the
>
> Hebrew is reversed.
>
> Thanx
>
>
>
>
>
>
> As a kludge you could type everything left to right and then apply this function to the whole buffer:
>
>
>
> (defun reverse-bstring (str)
>
> (apply #'string (nreverse (string-to-list (buffer-string))))
>
>
>
> There is something perverse about it since it doesn't seem to need to be passed a string but, anyway, evaluating it in *Scratch* produces this:
>
>
>
> "
>
> ))))gnirts-reffub( tsil-ot-gnirts( esrevern( gnirts'# ylppa(
>
> )rts( gnirtsb-esrever nufed(
>
>
>
> ..reffub nwo s'elif taht ni txet eht retne neht ;;
>
> ,f-C x-C htiw elif taht tisiv ,elif a etaerc ot tnaw uoy fI ;;
>
> ..noitaulave psiL rof dna ,evas ot tnaw t'nod uoy seton rof si reffub sihT ;;"
>
>
>
> Ed
>
>
>
>
> Of course you want to do this line by line, not to the whole buffer, since in Hebrew and Arabic you start at the back of the book but not at the bottom of the page. O well, back to the drawing board.
>
>
>
>
> You could then demarcate the above text as a region and then run M-x reverse-region on it. It's still a kludge but it might work on multi-byte buffers.
>
[-- Attachment #2: Type: text/html, Size: 4016 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Re: emacs + unicode + hebrew + bidi
2008-11-04 13:06 Re: emacs + unicode + hebrew + bidi Bourgneuf Francois
@ 2008-11-04 14:55 ` Jonathan Groll
0 siblings, 0 replies; 4+ messages in thread
From: Jonathan Groll @ 2008-11-04 14:55 UTC (permalink / raw)
To: help-gnu-emacs
On Tue, Nov 04, 2008 at 02:06:09PM +0100, Bourgneuf Francois wrote:
>Just a precision, in arabic and hebrew both text and numbers are written right to left.
>In western languages text is written left to right and numbers right to left.
>You can't tell the value of the left digit of a number if you havent read how many digit are at his right.
>We solve additions from the right to the left.
>
In all the Hebrew I've seen numbers were left to right:
http://en.wikipedia.org/wiki/Hebrew_punctuation#Math
Regards,
Jonathan
^ permalink raw reply [flat|nested] 4+ messages in thread
* RE: Re: emacs + unicode + hebrew + bidi
@ 2008-11-04 15:15 Bourgneuf Francois
0 siblings, 0 replies; 4+ messages in thread
From: Bourgneuf Francois @ 2008-11-04 15:15 UTC (permalink / raw)
To: help-gnu-emacs
I just wanted to point that "english numbers" (i.e. arabic) numbers are in fact right to left.
We're used to use them so we think they are written left to right but it's wrong. Even though you don't
realize it, you read numbers from the right to the left.
I disagree with what's written in the Wikipedia article.
For example, in the number 1.234 how can you tell 1 represents one thousand ? Because there are
three digits on the right. You have to read the right part of the number first.
Other example, which of these calculations is the easiest to solve :
12345
+23
Or
12345
+ 23
Regards
Bour9
> -----Message d'origine-----
> De :
> help-gnu-emacs-bounces+francois.bourgneuf=groupe-mma.fr@gnu.or
> g
> [mailto:help-gnu-emacs-bounces+francois.bourgneuf=groupe-mma.f
> r@gnu.org] De la part de Jonathan Groll
> Envoyé : mardi 4 novembre 2008 15:56
> À : help-gnu-emacs@gnu.org
> Objet : Re: Re: emacs + unicode + hebrew + bidi
>
> On Tue, Nov 04, 2008 at 02:06:09PM +0100, Bourgneuf Francois wrote:
> >Just a precision, in arabic and hebrew both text and numbers
> are written right to left.
> >In western languages text is written left to right and
> numbers right to left.
> >You can't tell the value of the left digit of a number if
> you havent read how many digit are at his right.
> >We solve additions from the right to the left.
> >
>
> In all the Hebrew I've seen numbers were left to right:
> http://en.wikipedia.org/wiki/Hebrew_punctuation#Math
>
> Regards,
> Jonathan
>
>
>
>
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2008-11-04 15:15 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-11-04 13:06 Re: emacs + unicode + hebrew + bidi Bourgneuf Francois
2008-11-04 14:55 ` Jonathan Groll
-- strict thread matches above, loose matches on Subject: below --
2008-11-04 15:15 Bourgneuf Francois
2008-11-04 11:44 cyberkm
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.