基础工程的狮身人面像主题(基于烧瓶主题)
groundwork-sphinx-theme的Python项目详细描述
这个存储库包含sphinx样式,大多数与基础工作相关的项目都使用这些样式。 它是肯尼思·雷茨的主题在他的项目中的衍生,也是三浦彦的主题在烧瓶和烧瓶相关的项目中的衍生。 项目。要在Sphinx文档中使用此样式,请遵循以下指南:
使用pip:pip install groundwork-sphinx-theme
安装包将此添加到conf.py:
html_theme='groundwork'
配置
Groundwork Sphinx主题提供以下配置参数:
- sidebar_width: Allows the user to set the sidebar width in pixels. Good for deeply nested TOCs (Default: 220x)
- stickysidbar: If True it makes the sidebar always visible if pages get longer (Default: True)
- stickysidbarscrollable: Makes the sticky sidebar scrollable in small browser windows (Default: False)
- contribute: If True, a contribute-area with github-buttons is shown inside the sidebar
- github_user: Used the for github follow button. E.g.: useblocks
- github_fork: Used for the github fork buttons. E.g.: useblocks/groundwork
您可以在sphinx项目的文件conf.py中更改它们的值:
html_theme_options = { "sidebar_width": '240px', "stickysidebar": True, "stickysidebarscrollable": True, "contribute": True, "github_fork": "useblocks/groundwork", "github_user": "useblocks", }