rename texmessage.loadfd to texmessage.loaddef and allow for .def and .fd files
[PyX/mjg.git] / examples / text / texrunner.txt
blob0cdf432e18f9b6dcb261c7b218b9bea89350300a
1 Usually all you will ever need is a single `texrunner` instance which controls
2 a single running TeX or LaTeX instance at the time. To make live easy to our
3 users, such an instance is created automatically upon startup and its called
4 the `defaulttexrunner`. Whenever you use the function shortcuts like
5 `text.text()` and most to be emphasized `text.set()` you are accessing this
6 `defaulttexrunner` instance. Also, the shortcut method `text` of any canvas
7 instance uses this `defaulttexrunner` by default.
9 However, this example shows you how to create a second `texrunner` instance. To
10 make it a little interesting, we switch the `defaulttexrunner` to use LaTeX,
11 while keeping TeX for the `plaintexrunner` instance. It is you turn to try
12 expressions which are valid on TeX or LaTeX only at the different `texrunner`
13 instances.
15 Note that you do not have to worry about mixing the results of different
16 texrunners into a single output. Even the embedded fonts in the output are
17 shared when they are equal. You can, by the way, also restart a `texrunner`
18 instance including the `defaulttexrunner` and change its configuration on that
19 occasion.