Sphinx“示例”或“参考”标题

时间:2019-08-14 11:41:23

标签: python-sphinx restructuredtext heading

我正在为Python项目编写Sphinx文档,我想有一个名为“示例”的部分,但是它的格式不正确。

# -*- coding: utf-8 -*-
r"""
.. My Python Module

This is my Python module.

.. contents:: Table of Contents
  :local:

Description
***********

This is the module description

Examples
********

This are the module examples
"""
# My module code

构建文档时,我会获得第一种情况的所需标题(“描述”),但目录中既未包含“示例”标题,也未将其正确格式化为标题(仅粗体)。

“ {References”和automodapi使用的其他关键字也是如此。

0 个答案:

没有答案