From b3788c283fecf7a68f2d054ada12eaa5339d9323 Mon Sep 17 00:00:00 2001 From: Matthias Geier Date: Sat, 26 Mar 2016 14:34:12 +0100 Subject: [PATCH] Add custom.css --- docs/source/_static/custom.css | 9 +++++++++ docs/source/conf.py | 4 ++++ 2 files changed, 13 insertions(+) create mode 100644 docs/source/_static/custom.css diff --git a/docs/source/_static/custom.css b/docs/source/_static/custom.css new file mode 100644 index 000000000..893609a4d --- /dev/null +++ b/docs/source/_static/custom.css @@ -0,0 +1,9 @@ +/* 24px margin from readthedocs theme */ +div.nblast { + margin-bottom: 19px !important; /* padding has already 5px */ +} + +/* ... except between notebook cells! */ +div.nblast + div.nbinput { + margin-top: -19px !important; +} diff --git a/docs/source/conf.py b/docs/source/conf.py index 6d50a9618..0802ab2d5 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -186,6 +186,10 @@ html_theme = 'sphinx_rtd_theme' # since it is needed to properly generate _static in the build directory html_static_path = ['_static'] +html_context = { + 'css_files': ['_static/custom.css'], +} + # Add any extra paths that contain custom files (such as robots.txt or # .htaccess) here, relative to this directory. These files are copied # directly to the root of the documentation.