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

Re: PuTTY Bidi - final points

--- Owen Dunn <owend at chiark dot greenend dot org dot uk> wrote:
> Nadim Shaikli <shaikli at yahoo dot com> writes:
> >  2. We have 2 display issues which are a mystery,
> > 
> >     a. There are instances in which 2 glyphs need to be combined and
> >        shown as one.  Namely LAM (0x0644) and ALEF (0x0627) get combined
> >        and replaced by LAA (0xFEFB) along with various permutations.
> This isn't surprising at all.  You're replacing two single-width
> glyphs in positions n and n+1 with just one single-width glyph in
> position n, but as far as PuTTY's internals are concerned the next
> character is still at position n+2.  You need to work out a way of
> dealing with this, moving the following word so that it starts to
> display at n+1 even though the terminal emulator should still believe
> it starts at n+2.
> It would be good if you then preserved the word's visual length by
> sticking some tatweel in to make up the space there.  (Note for
> non-Arabic-speaking folk: tatweel is a meaningless mark that can be
> used to stretch Arabic words.)

Adding tatweel (or anything for that matter that is not part of the
document one is viewing) is not an option.  What needs to happen is
the visual buffer needs to be adjusted and shifted by one to account
for this "absorption" or "combining" - the question was really how
best to do this from an implementation point of view.

NOTE: this is how many other application (including mlterm) deal with
      it and it is the prim-n-proper method.  Adding our own "filler"
      characters is a recipe for disaster and file non-integrity.

I'd guess we can look into making that space a zero-width character
and play with that concept.

> Yes.  PuTTY doesn't currently support Unicode combining characters.
> See: 

Ouch !!  I would guess we can simply ask for that "wishlist" item to
be elevated from a medium priority to maximum (unless someone is willing
to shed some light on what is needed to make it happen).  A quick note,
from what I've seen other applications do, the number of composing
characters that most allow is 2.  I believe that is the maximum number
that all languages use/require (so I'm unsure of the statement I read
on the link above that notes, "PuTTY should support an arbitrary sequence
of diacritics in any character cell").

The topic of Bidi still looms large overhead.  Which code should we use ?

Regards (thanks Owen for replying),

 - Nadim

Do you Yahoo!?
Yahoo! Search - Find what you’re looking for faster