引用,链接,图片¶
引用, 链接¶
形式1:
`链接显示名 <http://blog.programfan.info/>`_
形式2:
Test hyperlink: SO_
.. _SO: http://stackoverflow.com/
This is a paragraph that contains `a link`_.
.. _a link: https://domain.invalid/
站内链接¶
:ref:`链接显示,右面是文件开头的索引 <header_1>`
这是链接的另一形式,链接到ablog.rst
:doc:`ablog`
引用:
使用: xxxxx [1]_
展示: .. [1] xxxxx
// 章节引用
.. _my-reference-label:
Section to cross-reference
--------------------------
This is the text of the section.
It refers to the section itself, see :ref:`my-reference-label`.
下载专用¶
示例:
:download:`图片/文件下载 <../files/image/photo.jpg>`
会呈现出点击后下载文件的效果。
注意这种引用方式在生成 pdf 文件时链接会无效
示例:
* See :download:`this example script <./code.rst>`
.. only:: builder_html
See :download:`this example script <./code.rst>`.
See this example script
.
图片引用¶
(参考):
.. _my-figure:
.. figure:: whatever
Figure caption