emacs-bidi
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [emacs-bidi] Display routines


From: Matan Ninio
Subject: Re: [emacs-bidi] Display routines
Date: 06 Nov 2001 20:29:43 +0200
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.1

"Ehud Karni" <address@hidden> writes:

> > Do you envision a possibility of buffers with visual order?  If so,
> > could you tell why do you think such buffers are required?

say, you want to write an TCL_TK program that has some Hebrew buttons.
your tcl-tk dose not support bidi, and you really don't need it to, as
all you want is some static buttons and or texts.
you edit the source code, put the Hebrew stuff in strings, and they
print just fine with the right font.
or you want to write a web page in visual, or whatever.
(one needs to remember that some of us are forced to work outside of
emacs from time to time.:)

> 
> I think he meant pasting from other applications through the clipboard.
> And I think this is needed as a special "visual-hebrew-paste" function.

That's the main idea here.  This dose happen.  In many cases, you don't
even know if the other application you just marked is logical of
visual.  you past, it looks like yeddish, and you now want to reverse
the region.  or you may want to go the other way, cut from Emacs and
paste elsewhere.

> 
> > > -> an algorithm for some support for "rectangle" in bidi texts
> > > (may be a pain, that last one)
> > 
> > There has been some discussion on the Emacs development list (or was
> > it bug-gnu-emacs? I forget which one) about the need for
> > non-contiguous regions.  If something like that gets added to Emacs,
> > we could use it for bidi.
> 
> I'm not sure what he wants here, but the functions in hebeng.el has the
> ability to work on rectangles through another package I wrote (which
> uses 3 kinds of marked areas - characters, lines & Block).
> 
> May be Matan will make his intentions clearer (with example, please).
think of using kill-rectangle and yank-rectangle in a bidi environment,
where some of the texts intersecting the rectangle are R2L and some L2R.
It's not trivial to chose the right things to cut, nor is it trivial to
paste this in a similar environment, without messing things up.

as for Eli's comments:
>  > -> auto detect of 8859-8 vise 8859-8-i
>  > should probably be based on the frequency of pairs of letters.  I can
>  > give you an algorithm that, given some body of texts, can give a
>  > probability for each direction.
>  
>  Please post this algorithm.

if you can read Hebrew postscript, check this address out
http://www.cs.huji.ac.il/labs/learning/Info/Ps_Files/lecture2.ps
but think of orders pairs of letter.  with SOFIOT in hebrew, this should
work very nicely.


>  > -> W3 mode ???
>  
>  Not sure what you mean: is it HTML bidi directives?

and visual/logical Hebrew tags and so on.  This is mainly relevant if W3
mode is still alive.
>  
>  > that's it for now, but there probably are many others (Word->displayable
>  > form??)
>  
>  You mean, to read Word .doc files?  What's the bidi-specific aspects
>  of that?  MS-Word implements UAX#9 (in fact, MS are behind most of
>  the mess in the bidi algorithm in its present form ;-), so, after
>  conversion from their proprietary format, what you have is
>  logical-order text.  Did I miss something?

yah.  they have some internal representation which may, or may not, be
Unicode.  I know I'm a tad bit hackerish, but I would want to at least
 be able to look into such files with Emacs. (I have done this more then
 once, mainly while saving corrupt DOC files.)  I can't say this looks
like high priority stuff, but I at least find it interesting.



-- 
Matan Ninio             
-----------------------------------------
VI VI VI - The Roman Number of The Beast



reply via email to

[Prev in Thread] Current Thread [Next in Thread]