Change font and background color in ipython notebook

How to change the C: \ Python32 \ Lib \ site-packages \ IPython \ frontend \ html \ notebook \ static \ css file in the iPython notebook directory without destroying the source file?

I just want to have a black background in my notebook, and then have the text orange with blue or whatever for classes and functions.

Can anyone help with this? I know where to look for source files, but not how to change them.

I appreciate any answers. Thanks to everyone.

+4
source share
1 answer

You can use a file called custom.css in <ipython profile dir>/profile_<profilename>/static/custom/custom.css , which will be applied to your laptop. Browser caching can be aggressive, it may take you a few seconds to refresh.

Word coloring is carried out through codemirror , which supports the subject. Changing this will be a little more complicated and may require some JavaScript injection in <ipython profile dir>/profile_<profilename>/static/custom/custom.js .

I wrote a more detailed but outdated explanation that could probably be adapted to new versions.

+6
source

Source: https://habr.com/ru/post/1501363/


All Articles