如何在Sphinx中添加删除线文本
在Sphinx文档生成器中,可以让文字有删除线效果吗?
1 个回答
10
我已经做过这个了。
在你的配置文件conf.py里需要引入一个.CSS文件。
html_style = 'mydoc.css'
在_static/mydoc.css
文件里,可以使用类似这样的内容:
@import url("default.css");
span.strikethrough { text-decoration: line-through; }
在文档中,做如下操作。
.. role:: strikethrough
make text :strikethrough:`strikethrough` in the sphinx