# 20130116¶

## Sphinx tools¶

I wrote a textimage directive which I will need to write /tutorials/layouts. Thanks to:

Usage:

.. textimage:: 0114a.jpg
:scale: 40 %

**This is a test**.
We start by including a .py file:

.. literalinclude:: 0116a.py

Here are some explanations.


This directive (an InsertInputDirective) will generate the following intermediate rst markup:

+-----------------------------------+----------------------+
| **This is a test**.               | .. image:: 0114a.jpg |
| We start by including a .py file: |   :scale: 40 %       |
|                                   |                      |
| .. literalinclude:: 0116a.py      |                      |
|                                   |                      |
| Here are some explanations.       |                      |
+-----------------------------------+----------------------+


… leading to the final result:

 This is a test. We start by including a .py file: # test for i in range(10): print i  Here are some explanations. 0114a.jpg

To implement this, I also had to optimize lino.utils.rstgen : it supports now cells containing newlines.

A similar thing is complextable:

 This is a test. We start by including a .py file: # test for i in range(10): print i  Here are some explanations. complextable is of more general use.

Now that north.dpy can automatically handle a change in the lino.Lino.languages settings, I made a Double Dump Test (DDT) on Jana using a dump of production data. Miscellaneous optimizations during the upgrade:
• lino.Lino.using() didn’t yet yield Sphinx.