Re: "fribidi_remove_special_chars" function?
Evgeny Grin <[email protected]> Wed, 14 Aug 2013 03:27:02 +0400
| Newsgroups | gmane.comp.internationalization.fribidi |
|---|---|
| Message-ID | <[email protected]> |
14.08.2013, 02:26, "Behdad Esfahbod" <[email protected]>: > On 13-08-13 04:24 PM, Evgeny Grin wrote: >> I'm going to implement it in the following way: >> * convert to UTF-32 >> * call fribidi_get_bidi_types >> * call fribidi_get_par_embedding_levels >> * call fribidi_get_joining_types >> * call fribidi_join_arabic >> * call fribidi_shape >> * split result into lines, for each line call fribidi_reorder_line, combine resulting lines back to paragraph > > You need fribidi_reorder_line() here. > Check out fribidi_log2vis() implementation. fribidi_log2vis works only with single lines. So I'm going here to: * split paragraph into single lines, * process each line with fribidi_reorder_line(), * combine result back to paragraph. Is it right? I suppose that "off" parameter of fribidi_reorder_line() is equal to size of all previous lines (with line breaks) in paragraph. Is it correct? >> * call fribidi_remove_bidi_marks >> * convert result to needed encoding (UTF-8 in my case) >> * use result for display >> Correct? Besides minors, is it right? >> >> Is it possible to detect on early stage ability to skip arabic joining and shaping? > No. I suggest you don't worry about performance. It wouldn't make any > measurable difference. Nice! Thanks. I was trying to find any example with fribidi and multiline paragraphs, but without any success. Do you know any? Best wishes, Evgeny _______________________________________________ fribidi mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/fribidi