
Patoline: A modern digital typesetting system (2012) - Tomte
http://patoline.org/
======
nerdponx
The first things I want to see when evaluating a new tool are:

1) a toy usage example

2) why I should use this over whatever I already use (La/Xe/Con/Luatex,
Markdown, rST, Pandoc)

3) who is developing it and why I should trust them (e.g. "this is a hobby
project", or "this is free-as-in-freedom with a grant from the Gates
Foundation", or "we are a startup intending to sell your user metadata to
Facebook when we are acquired in a few years")

I'm not sure this site addresses any of those

~~~
paulclinger
There is also SILE
([https://github.com/simoncozens/sile](https://github.com/simoncozens/sile)),
which has been in development since 2012 and addresses these points in the
docs: SILE is similar to TeX—from which it borrows some concepts and even
syntax and algorithms—but the similarities end there. Rather than being a
derivative of the TeX family SILE is a new typesetting and layout engine
written from the ground up using modern technologies and borrowing some ideas
from graphical systems such as InDesign.

The documentation includes "SILE versus TeX" section; some of the quotes from
it: "one of the things that TeX can’t do particularly well is typesetting on a
grid. This is something of a must have feature for anyone typesetting bibles.
Typesetting on a grid means that each line of text will line up between the
front and back of each piece of paper producing much less visual bleed-through
when printed on thin paper. This is virtually impossible to accomplish in TeX.
There are various hacks to try to make it happen, but they’re all horrible. In
SILE, you can alter the behaviour of the typesetter and write a very short
add-on package to enable grid typesetting."

"SILE does not benefit from the large ecosystem and community that has grown
up around TeX; in that sense, TeX will remain streets ahead of SILE for some
time to come. But in terms of core capabilities, SILE is already certainly
equivalent to, if not somewhat more advanced than, TeX."

~~~
jimhefferon
ConTeXt does grid typesetting, so it is not a limitation of TeX.
[http://wiki.contextgarden.net/Grid_typesetting](http://wiki.contextgarden.net/Grid_typesetting)

~~~
fusiongyro
I'm surprised at how often limitations of LaTeX are taken as limitations of
TeX.

------
soyiuz
I appreciate the defecating duck automaton on the cover. See "The Defecating
Duck, or, the Ambiguous Origins of Artificial Life" by Jessica Riskin Critical
Inquiry for the importance of that robot.

Like others have said, an audience who understands what a "typesetting system"
is, would immediately need to be convinced as to why they should use your tool
over existing ones like LaTeX or Markdown + Pandoc. Do you really expect your
users to read someone dissertation to get that info?

~~~
FlorianRappl
I agree - but the dissertation was just a "demo" or "showcase" of the
typesetting system (I actually found it quite neatly, but I did not see
anything that I could not have done without much trouble in TeX; would have
loved to see the sources, though).

I really think the choice of using OCaml is not a very smart one (w.r.t. a
roadmap / scale). Just looking at, e.g., Facebook's Flow reminds me that it
can be a blocker in the long run (performance + not cross platform friendly).

~~~
pvitz
> I really think the choice of using OCaml is not a very smart one (w.r.t. a
> roadmap / scale). Just looking at, e.g., Facebook's Flow reminds me that it
> can be a blocker in the long run (performance + not cross platform
> friendly).

So can be C# or any other language you might prefer. OCaml can have
exceptional performance and the reasons why they are using OCaml sound quite
good.

~~~
guitarbill
I'm a bit sceptical on the reasons. I feel like "We like OCaml" might have
been more honest. Let's see the justifications.

> Our choice was constrained by the goal to let the user program inside the
> document, if they wished to do so. To achieve the long-term goals of
> modularity, backwards compatibility, and portability, we decided to use a
> functionnal [sic] programming language, with types checked by the compiler
> (ensuring modularity and portability), and whose authors would also have
> backwards compatibility in mind.

So maybe functional languages get you more fine grain modularity, but
otherwise I don't buy it. And what has type checking got to do with either? As
for OCaml programs not segfaulting or crashing, that doesn't seem unique. E.g.
javascript doesn't do this either, if it is pre-processed/"compiled". (I'm not
saying JS is a better choice.)

It's the same with darcs vs git. Yes, there maybe "better" systems than git,
and easier to learn, but you're still making it harder to contribute.

IDK, but with sentences like "If you do not like the idea of a free
decentralized internet, you can also do", it seems like they're going for
ideology over usability.

~~~
Yoric
Fwiw, OCaml has pretty exceptional modularity – for some definition of
modularity. Check out "functors".

Also, for backwards compatibility, this might be a reference to the pretty
unusual legal obligations that OCaml has as one of the reference languages of
the French Atomic Energy Agency.

~~~
guitarbill
I didn't know that, but that makes sense! I couldn't find any more info on
this, even when searching for "Commissariat à l'Énergie Atomique OCaml". Do
you have more details?

(I still think it's a bit rich to assume people will learn OCaml or write
their own transpiler just to typeset stuff though.)

~~~
fermigier
[https://caml.inria.fr/consortium/](https://caml.inria.fr/consortium/)

------
dang
Discussed in 2014:
[https://news.ycombinator.com/item?id=8024067](https://news.ycombinator.com/item?id=8024067)

~~~
nerdponx
It's frustrating to see that my criticism of the homepage was raised three
years ago, and still has not been addressed in that time. That does not make
me want to start using this tool, let alone contributing to it.

------
microcolonel
I have no idea what makes this "modern"; according to the book it seems like
TeX with _maybe_ some inline OCaml. Maybe something about OpenType?

~~~
blipmusic
Wouldn't Xetex + fontspec take care of that, including unicode needs?

Though, I'm curious what comes of this.

Currently the "official" install/build method via make fails on my mac (sierra
- could be some other issue) and on top of that 'opam init' (?) completely
broke the fish path evaluation (not Patoline's fault, I guess). Manual fish
fix:
[https://github.com/ocaml/opam/issues/2255](https://github.com/ocaml/opam/issues/2255).

~~~
microcolonel
Yeah, I found both of those issues. I couldn't get it to build on Linux
either.

------
junke
Oh no, Chapter 5 (Understanding the typesetting model) and 6 (Extending
Patoline) of the book
([https://patoline.org/patobook.pdf](https://patoline.org/patobook.pdf)) are
not yet finished, that's what I wanted to read :-)

Did the author try to reverse engineer TeX? Is there anything that Patoline
can do better w.r.t. typesetting, for some definition of "better"?

~~~
dubya
No reverse engineering required: [http://www-cs-
faculty.stanford.edu/~uno/abcde.html](http://www-cs-
faculty.stanford.edu/~uno/abcde.html) It would be interesting to know at least
if it was using the same algorithms.

~~~
junke
Well, not "reverse engineering", sorry, but that's the idea: did they use the
same algorithms and rewrote them exactly as same in OCaml? did they find
anything that could be done better? etc.

------
mcguire
Wow, a click through banner page. Haven't seen one of those in a while.

------
ionforce
Some demos would be nice.

