[XeTeX] Flipping parentheses/brackets in RTL context

2013-12-06 Thread Alexey Kryukov
Dear All,

I am preparing a book with small fragments of Hebrew and Arabic embedded
into a Russian text. In the process of this work I have upgraded from
XeTeX, Version 3.1415926-2.2-0.9997.4 I used previously to  XeTeX,
Version 3.1415926-2.5-0..3 from TeXLive 2013 which goes with
openSUSE 11.3. Everything seems OK, except that parentheses in RTL
context are no longer mirrorred, as they used to. I am attaching a
minimal example which demonstrates the problem.

I also have attempted to compile the same file with LuaLaTeX (defining
\beginR as \luatexpardir TRT\luatextextdir TRT), but it produces
essentially the same result (which is natural, since luaTeX, unlike
XeTeX, seems to know absolutely nothing about the difference between
LTR, RTL and neutral characters).

Googling and searching the archives of this list gave me no clues. So
does anybody know if it is possible to resolve the problem and get the
same output as with older XeTeX?

-- 
Regards,
Alexey Kryukov 

Moscow State University
Faculty of History
\documentclass{book}

\TeXXeTstate=1
\usepackage{fontspec}

\newfontfamily{\hebrewfont}[
  Script=Hebrew
]{Ezra SIL}

%\def\beginR{\luatexpardir TRT\luatextextdir TRT}

\begin{document}

\hebrewfont

\beginR ‫כַּאֲשֶׁר כַּתַבְנוּ ()כְּשֶׁכָּתַבְנוּ() הוא ישׁב ושׁתק.

\end{document}


--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] xetex and the unicode bidirectional algorithm.

2013-12-06 Thread Dominik Wujastyk
I'm sensing, I think, that you don't like that font, Khaled?

Dominik :-)


2013/12/5 Khaled Hosny :
>


> >> > Please, please, please, never ever use GNU free font for Arabic; it is
> >> > the most hideous, crappy and useless un-Arabic font ever created, my
> >> > blood boils every time I see it in use.
> >> >
> >> Could you summarize what is wrong and report it?
> >
> > All of it, the Arabic range is utter crap.
> >
> >> Steve White will
> >> certainly fix it (unless it is better toreplace the whole Arabic
> >> block).
> >
> > I did, and even offered to work on replacement, but the offer was turned
> > down.
> >
> >> I see problems with dochachmee he, Urdu words as بھآرت and ؔٹھیک are
> >> not displayed properly.
> >
> > There is no point in looking at the microlevel, the whole thing is
> > worthless garbage and should be tossed in the nearest trash bin. Whoever
> > designed it has absolutely no idea about Arabic and its design, I take
> > it personally and find this garbage an insult to the Arabic script. Show
> > a text typeset with it to an Urdu speaker and he is likely to vomit in
> > disgust.
> >
>
>


--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] Seeking short examples of complex renderings

2013-12-06 Thread Simon Cozens

On 06/12/2013 20:18, Khaled Hosny wrote:

Both Pango and XeTeX use HarfBuzz which in turn can use Graphite, so I
think HarfBuzz and Graphite are the proper places for these tests (and
both already have test suites in place)


This is true, but there *are* higher level applications, like XeTeX and SILE 
and Gtk and Firefox and so on...



Instead of comparing images, which can be affected by things unrelated
to layout like hinting, it would be better to compare glyph IDs with or
without glyph positioning, check HarfBuzz and Graphite test suites for
examples.


...and so I don't think that having low-level tests obviates the need for 
high-level ones.


"My script is meant to look like *this* but your application renders it like 
*that*" is as much a meaningful test as 
f499fbc23865022234775c43503bba2e63978fe1.ttf:U+09B0,U+09CD,U+09A5,U+09CD,U+09AF,U+09C0:[gid1=0+1320|gid13=0+523|gid18=0+545] 
- and possibly more accessible too.


And in fact it's precisely because, say, SILE uses Pango which uses Harfbuzz 
which uses Graphite, it's useful to have an easy way to see who's getting it 
wrong. If SILE messes up a rendering, I want to have some text I can throw at 
pango-view to see if that gets it right. Sorting out the layers is important.


For instance, I see that Harfbuzz already has some tests for Hebrew vowel 
pointings, [*] but running pango-view on these tests produces erroneous 
output. So how should I describe the problem to Pango developers, other than 
by having a picture of what Pango *is* generating and what I think it *should* 
be generating...


...which is basically what I am putting together.

[*] or at least it has some files with some pointed Hebrew in it - but I don't 
see the test suite doing anything with it, nor do I see any expected shapings 
for any of the texts/ directory.



--
Subscriptions, Archive, and List information, etc.:
 http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] Seeking short examples of complex renderings

2013-12-06 Thread Khaled Hosny
On Fri, Dec 06, 2013 at 07:55:07PM +0900, Simon Cozens wrote:
> Hello XeTeXers,
> 
> Sorry for a not-entirely-XeTeX-related request but I think there may be some
> merit in it for XeTeX in the future.
> 
> I have recently been toying around implementing my own layout engine, and
> have started to check that it works nicely with non-Roman scripts. This has
> already thrown up a few bugs in pango (which I'm using to do the shaping),
> and that's just with scripts that I can read. I am sure there are other
> problems in scripts I can't read.
> 
> So I thought it would be a useful thing for people like
> pango/xetex/graphite/harfbuzz/other layout and rendering tool developers to
> have a visual test suite, a collection of short strings which stress-test
> their engines in interesting ways: placement of composing characters,
> mandatory ligatures, mixed LTR/RTL, that sort of thing.

Both Pango and XeTeX use HarfBuzz which in turn can use Graphite, so I
think HarfBuzz and Graphite are the proper places for these tests (and
both already have test suites in place), so I’d forward this to the
respective developers.

> I have started putting a collection together but my own knowledge and
> experience is pretty limited. If you can contribute some short Unicode
> strings from a language you know which show an interesting rendering
> feature, I hope this will be something that can be beneficial to the text
> layout community as a whole.
> 
> The test suite at the moment is at
> http://simoncozens.github.io/visual-testsuite/testsuite.html
> 
> and you can contribute via github at
> http://github.com/simoncozens/visual-testsuite

Instead of comparing images, which can be affected by things unrelated
to layout like hinting, it would be better to compare glyph IDs with or
without glyph positioning, check HarfBuzz and Graphite test suites for
examples.

Regards,
Khaled


--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


Re: [XeTeX] Seeking short examples of complex renderings

2013-12-06 Thread Zdenek Wagner
Hi,

I have an extensive test of Devanagari at
http://hroch486.icpf.cas.cz/xetex-test/, the same test was repeated
with the different revisions of the GNU FreeFont and a few more fonts
for comparison. The page contains both the results of the tests that
failed as well as the tests that past (now all bugs are fixed). Notice
that Indic rendering is really complex and a short test using a single
word will not help. There are quite complex words.

I can also send you a few Urdu words containing characters not present
in Arabic. And Urdu is typeset with Nastaleeq style which causes a lot
of difficulties for the engine.

2013/12/6 Simon Cozens :
> Hello XeTeXers,
>
> Sorry for a not-entirely-XeTeX-related request but I think there may be some
> merit in it for XeTeX in the future.
>
> I have recently been toying around implementing my own layout engine, and
> have started to check that it works nicely with non-Roman scripts. This has
> already thrown up a few bugs in pango (which I'm using to do the shaping),
> and that's just with scripts that I can read. I am sure there are other
> problems in scripts I can't read.
>
> So I thought it would be a useful thing for people like
> pango/xetex/graphite/harfbuzz/other layout and rendering tool developers to
> have a visual test suite, a collection of short strings which stress-test
> their engines in interesting ways: placement of composing characters,
> mandatory ligatures, mixed LTR/RTL, that sort of thing.
>
> I have started putting a collection together but my own knowledge and
> experience is pretty limited. If you can contribute some short Unicode
> strings from a language you know which show an interesting rendering
> feature, I hope this will be something that can be beneficial to the text
> layout community as a whole.
>
> The test suite at the moment is at
> http://simoncozens.github.io/visual-testsuite/testsuite.html
>
> and you can contribute via github at
> http://github.com/simoncozens/visual-testsuite
>
> (or just send me an email)
>
> Thanks!
> Simon
>
>
> --
> Subscriptions, Archive, and List information, etc.:
>  http://tug.org/mailman/listinfo/xetex



-- 
Zdeněk Wagner
http://hroch486.icpf.cas.cz/wagner/
http://icebearsoft.euweb.cz



--
Subscriptions, Archive, and List information, etc.:
  http://tug.org/mailman/listinfo/xetex


[XeTeX] Seeking short examples of complex renderings

2013-12-06 Thread Simon Cozens

Hello XeTeXers,

Sorry for a not-entirely-XeTeX-related request but I think there may be some 
merit in it for XeTeX in the future.


I have recently been toying around implementing my own layout engine, and have 
started to check that it works nicely with non-Roman scripts. This has already 
thrown up a few bugs in pango (which I'm using to do the shaping), and that's 
just with scripts that I can read. I am sure there are other problems in 
scripts I can't read.


So I thought it would be a useful thing for people like 
pango/xetex/graphite/harfbuzz/other layout and rendering tool developers to 
have a visual test suite, a collection of short strings which stress-test 
their engines in interesting ways: placement of composing characters, 
mandatory ligatures, mixed LTR/RTL, that sort of thing.


I have started putting a collection together but my own knowledge and 
experience is pretty limited. If you can contribute some short Unicode strings 
from a language you know which show an interesting rendering feature, I hope 
this will be something that can be beneficial to the text layout community as 
a whole.


The test suite at the moment is at
http://simoncozens.github.io/visual-testsuite/testsuite.html

and you can contribute via github at
http://github.com/simoncozens/visual-testsuite

(or just send me an email)

Thanks!
Simon


--
Subscriptions, Archive, and List information, etc.:
 http://tug.org/mailman/listinfo/xetex