Sphinx–Python Docstring Package

What is Sphinx

Sphinx is written in Python and supports Python 3.6+. It builds upon the shoulders of many third-party libraries such as Docutils and Jinja, which are installed when Sphinx is installed.

Text Formatting

List and Number

  • Use * for List

  • Use #. for Numbered List

Admonitions

Caution

This is a caution box.

Danger

This is a danger box.

Tip

This is a tip box.

Note

This is a note box.

Images

Use this code:

.. image:: /Images/homepage.png

Codes

  • Simple

    Note

    Use :: to note the following sections are codes.

    Example:

    Here’s a simple sample to input codes, type in:

    #Write your codes Here
    #i.e. Python
    print("Hello Sphinx!")
    
  • Specific

    Note

    Use .. code-block:: python to note the following sections are python codes.

    Example:

Tabels

Student Information 1

Name

Sex

Age

Address

Lisa

Female

20

160 Chapel st.

John

Male

23

172 Albert st.

Tip

You can click on View page source to checkout how these functions work in rst file.