我如何添加自定义css文件?以下配置对我不起作用:
# conf.py
html_static_path = ['_static']
html_theme = 'default'
html_theme_options = {
'cssfiles': ['_static/style.css']
}
Run Code Online (Sandbox Code Playgroud)
结果:
C:\temp\test-docs\docs>make html
Running Sphinx v1.2.2
loading pickled environment... not yet created
building [html]: targets for 2 source files that are out of date
updating environment: 2 added, 0 changed, 0 removed
reading sources... [ 50%] help
reading sources... [100%] index
looking for now-outdated files... none found
pickling environment... done
checking consistency... done
preparing documents...
Theme error:
unsupported theme option 'cssfiles' given
Run Code Online (Sandbox Code Playgroud) 我正在使用"阅读文档"Sphinx主题作为我的文档.在原始主题中,给出如下
http://read-the-docs.readthedocs.org/en/latest/theme.html
内容或主要布局宽度设计为移动友好.但是,对于我的项目,我希望这会更广泛.我不知道HTML,因此如果任何人可以给我一些线索来增加内容(布局)宽度,我将不胜感激.
我的 .rst 文件中有以下文本:
Some text.
* Heading
| The first topic.
| Another topic which is very verbose and spans multiple lines ad infinitum.
Topic continued......................................
Run Code Online (Sandbox Code Playgroud)
我希望它呈现为:
Some text.
* Heading
The first topic.
Another topic which is very verbose and spans multiple lines ad infinitum....................
Topic continued.............
Run Code Online (Sandbox Code Playgroud)
然而,它在 Html 中呈现如下:
Some text.
* Heading| The first topic.| Another topic which is very verbose and spans multiple lines ad infinitum .................... Topic continued
Run Code Online (Sandbox Code Playgroud)
Sphinx 文档建议使用该|符号来表示换行符,就像 Stackoverflow 上的几篇文章一样,但我一直无法让它工作。我想要一种独立于所使用的 Sphinx …