Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change Sphinx documentation theme from Readthedocs to Furo #373

Merged
merged 7 commits into from
Jun 19, 2021

Conversation

hakonanes
Copy link
Member

Description of the change

Progress of the PR

For reviewers

  • The PR title is short, concise, and will make sense 1 year later.
  • New functions are imported in corresponding __init__.py.
  • New features, API changes, and deprecations are mentioned in the
    unreleased section in doc/changelog.rst.

@hakonanes hakonanes added the documentation This relates to the documentation label Jun 19, 2021
@hakonanes hakonanes added this to the v0.4.0 milestone Jun 19, 2021
@hakonanes
Copy link
Member Author

@onatlandsmyr and @friedkitteh (or anyone else who feel like it!), could you give your thoughts, if you have any, on how the documentation looks in the furo theme vs. the Readthedocs theme?

@friedkitteh
Copy link
Collaborator

@onatlandsmyr and @friedkitteh (or anyone else who feel like it!), could you give your thoughts, if you have any, on how the documentation looks in the furo theme vs. the Readthedocs theme?

In general I think the furo theme is a lot easier on the eyes. However, for plots it becomes worse (imo) as the title of the plots blends with the background e.g.

image

compared to the Readthedocs equivalent
image

Another example:

image
image

@hakonanes
Copy link
Member Author

Thanks for the quick feedback, @friedkitteh! Yeah, Furo uses your browser's (OS') preferred light or dark theme. I have light enabled, so this is no problem for me, while I assume you have dark enabled, and so it is a problem. Apparently, we cannot at the moment force either mode (pradyunsg/furo#24).

A solution could be to add a white background to all headers, perhaps... I think it is worth doing this to start using the Furo theme.

@hakonanes
Copy link
Member Author

By adding this to the Sphinx configuration file conf.py:

nbsphinx_execute_arguments = [
    "--InlineBackend.rc=figure.facecolor='w'",
]

and using

>>> print(s.axes_manager)
<Axes manager, axes: (3, 3|60, 60)>
            Name |   size |  index |  offset |   scale |  units
================ | ====== | ====== | ======= | ======= | ======
               x |      3 |      0 |       0 |     1.5 |     um
               y |      3 |      0 |       0 |     1.5 |     um
---------------- | ------ | ------ | ------- | ------- | ------
              dx |     60 |        |       0 |       1 |     um
              dy |     60 |        |       0 |       1 |     um

in user guide notebook cells instead of just s.axes_manager, I think the documentation looks OK against a dark background.

@hakonanes
Copy link
Member Author

Will merge after checks pass. Thanks for the feedback @friedkitteh and @onatlandsmyr!

@hakonanes hakonanes merged commit d5f34f4 into pyxem:master Jun 19, 2021
@hakonanes hakonanes deleted the change-documentation-style branch June 19, 2021 18:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation This relates to the documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Should list pycotem in the list of related software that might be useful to users of kikuchipy
2 participants