From: Mike Bayer Date: Mon, 28 Nov 2022 20:54:11 +0000 (-0500) Subject: add width + overflow to keep toc from flowing out of sidebar X-Git-Tag: rel_1_9_0~4 X-Git-Url: http://git.ipfire.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=edd64ea2a322049a4a536c1a9ae8e498db73be23;p=thirdparty%2Fsqlalchemy%2Falembic.git add width + overflow to keep toc from flowing out of sidebar also add sphinx-autobuild to the makefile Change-Id: I7abd08cefe98d6b57394fad20bd06c3e0b928465 References: https://github.com/sphinx-doc/sphinx/issues/11000 (cherry picked from commit 9eafd483018775d9e1144512ed820ba2a80d2e61) --- diff --git a/docs/build/Makefile b/docs/build/Makefile index 8762826f..c87a87a4 100644 --- a/docs/build/Makefile +++ b/docs/build/Makefile @@ -4,6 +4,7 @@ # You can set these variables from the command line. SPHINXOPTS = SPHINXBUILD = sphinx-build +AUTOBUILD = sphinx-autobuild --port 8080 --watch ../../lib PAPER = BUILDDIR = output @@ -12,11 +13,12 @@ PAPEROPT_a4 = -D latex_paper_size=a4 PAPEROPT_letter = -D latex_paper_size=letter ALLSPHINXOPTS = -d $(BUILDDIR)/doctrees $(PAPEROPT_$(PAPER)) $(SPHINXOPTS) . -.PHONY: help clean html dirhtml pickle json htmlhelp qthelp latex changes linkcheck doctest +.PHONY: help clean html autobuild dirhtml pickle json htmlhelp qthelp latex changes linkcheck doctest help: @echo "Please use \`make ' where is one of" @echo " html to make standalone HTML files" + @echo " autobuild autobuild and run a webserver" @echo " dist-html same as html, but places files in /doc" @echo " dirhtml to make HTML files named index.html in directories" @echo " pickle to make pickle files" @@ -36,6 +38,9 @@ html: @echo @echo "Build finished. The HTML pages are in $(BUILDDIR)/html." +autobuild: + $(AUTOBUILD) $(ALLSPHINXOPTS) $(BUILDDIR)/html + dist-html: $(SPHINXBUILD) -b html $(ALLSPHINXOPTS) $(BUILDDIR)/html cp -R $(BUILDDIR)/html/* ../ diff --git a/docs/build/_static/nature_override.css b/docs/build/_static/nature_override.css index 33c0d055..57798ad1 100644 --- a/docs/build/_static/nature_override.css +++ b/docs/build/_static/nature_override.css @@ -14,3 +14,11 @@ font-style: italic; } +div.documentwrapper div.bodywrapper { margin-left: 350px;} +div.document div.sphinxsidebar { width: 350px; } + +div.sphinxsidebarwrapper div { + overflow: auto; +} + + diff --git a/docs/build/conf.py b/docs/build/conf.py index ba76b825..11a0e7f0 100644 --- a/docs/build/conf.py +++ b/docs/build/conf.py @@ -150,6 +150,7 @@ html_style = "nature_override.css" # Theme options are theme-specific and customize the look and feel of a theme # further. For a list of options available for each theme, see the # documentation. +# NOTE: use nature_override.css, not this # html_theme_options = {} # Add any paths that contain custom themes here, relative to this directory.