.. _sphx_glr_auto_examples_plot_text.py: text ==== Add text to your slide. By default text is processed by Latex and accept Latex syntax. .. code-block:: python from beampy import * # Remove quiet=True to get beampy compilation outputs doc = document(quiet=True) with slide('Text module'): text(r'A simple text with \LaTeX syntax so you could write equation:') text(r'$$\sqrt{\frac{x}{y}}$$') t = text(r'You could align text to center by using the \textbf{align} parameter', align='center', width=350) # add border to the text to see the effect of center alignment t.add_border() display_matplotlib(gcs()) .. image:: /auto_examples/images/sphx_glr_plot_text_001.png :align: center Module arguments ================ .. autoclass:: beampy.text :noindex: .. only :: html .. container:: sphx-glr-footer .. container:: sphx-glr-download :download:`Download Python source code: plot_text.py ` .. container:: sphx-glr-download :download:`Download Jupyter notebook: plot_text.ipynb ` .. only:: html .. rst-class:: sphx-glr-signature `Gallery generated by Sphinx-Gallery `_