[haiku-gsoc] Re: Rendering of Indic Languages in Haiku

  • From: digib0y <code.deepanshu@xxxxxxxxx>
  • To: haiku-gsoc@xxxxxxxxxxxxx
  • Date: Sat, 20 May 2017 12:04:59 +0530

Is boundary analysis already a part of Haiku or do we need to add it?

On 19 May 2017 2:15 p.m., "Adrien Destugues" <pulkomandy@xxxxxxxxxxxxx>
wrote:

19 mai 2017 10:25 "Stephan Aßmus" <superstippi@xxxxxx> a écrit:

You demonstrate this well in your video. I mean to say that if you
change the text rendering to use
shaping, BTextView would still allow to position the text cursor
inbetween two characters which are
actually combined by shaping.

In other text layout APIs, there are usually methods to know the "next"
and "previous" possible
caret position from a given position. We would need to offer the same
and make BTextView use it.

ICU calls this "boundary analysis" and provides the required classes
(BreakIterator). This should also be used for word boundaries, line breaks,
etc. Using ICU as a backend for this would be nice, because it would remove
quite a lot of the complexity in BTextView.

http://userguide.icu-project.org/boundaryanalysis

We should also make this part of the Locale Kit API, as other applications
(for example NetSurf) may do their own text layouting and they would want
to use it.

--
Adrien.


Other related posts: