
.. DO NOT EDIT.
.. THIS FILE WAS AUTOMATICALLY GENERATED BY SPHINX-GALLERY.
.. TO MAKE CHANGES, EDIT THE SOURCE PYTHON FILE:
.. "gallery/text_labels_and_annotations/stix_fonts_demo.py"
.. LINE NUMBERS ARE GIVEN BELOW.

.. only:: html

    .. meta::
        :keywords: codex

    .. note::
        :class: sphx-glr-download-link-note

        :ref:`Go to the end <sphx_glr_download_gallery_text_labels_and_annotations_stix_fonts_demo.py>`
        to download the full example code.

.. rst-class:: sphx-glr-example-title

.. _sphx_glr_gallery_text_labels_and_annotations_stix_fonts_demo.py:


==========
STIX Fonts
==========

Demonstration of `STIX Fonts <https://www.stixfonts.org/>`_ used in LaTeX
rendering.

.. GENERATED FROM PYTHON SOURCE LINES 9-32



.. image-sg:: /gallery/text_labels_and_annotations/images/sphx_glr_stix_fonts_demo_001.png
   :alt: stix fonts demo
   :srcset: /gallery/text_labels_and_annotations/images/sphx_glr_stix_fonts_demo_001.png, /gallery/text_labels_and_annotations/images/sphx_glr_stix_fonts_demo_001_2_00x.png 2.00x
   :class: sphx-glr-single-img





.. code-block:: Python


    import matplotlib.pyplot as plt

    circle123 = "\N{CIRCLED DIGIT ONE}\N{CIRCLED DIGIT TWO}\N{CIRCLED DIGIT THREE}"

    tests = [
        r'$%s\;\mathrm{%s}\;\mathbf{%s}$' % ((circle123,) * 3),
        r'$\mathsf{Sans \Omega}\;\mathrm{\mathsf{Sans \Omega}}\;'
        r'\mathbf{\mathsf{Sans \Omega}}$',
        r'$\mathtt{Monospace}$',
        r'$\mathcal{CALLIGRAPHIC}$',
        r'$\mathbb{Blackboard\;\pi}$',
        r'$\mathrm{\mathbb{Blackboard\;\pi}}$',
        r'$\mathbf{\mathbb{Blackboard\;\pi}}$',
        r'$\mathfrak{Fraktur}\;\mathbf{\mathfrak{Fraktur}}$',
        r'$\mathscr{Script}$',
    ]

    fig = plt.figure(figsize=(8, len(tests) + 2))
    for i, s in enumerate(tests[::-1]):
        fig.text(0, (i + .5) / len(tests), s, fontsize=32)

    plt.show()


.. _sphx_glr_download_gallery_text_labels_and_annotations_stix_fonts_demo.py:

.. only:: html

  .. container:: sphx-glr-footer sphx-glr-footer-example

    .. container:: sphx-glr-download sphx-glr-download-jupyter

      :download:`Download Jupyter notebook: stix_fonts_demo.ipynb <stix_fonts_demo.ipynb>`

    .. container:: sphx-glr-download sphx-glr-download-python

      :download:`Download Python source code: stix_fonts_demo.py <stix_fonts_demo.py>`

    .. container:: sphx-glr-download sphx-glr-download-zip

      :download:`Download zipped: stix_fonts_demo.zip <stix_fonts_demo.zip>`


.. only:: html

 .. rst-class:: sphx-glr-signature

    `Gallery generated by Sphinx-Gallery <https://sphinx-gallery.github.io>`_
