Skip to content

Consider switching themes #304

Closed
Closed

Description

@theacodes

(This is my first controversial idea for this project, so by all means tell me to forget it).

Sphinx now uses the Alabaster theme by default. In my opinion, Alabaster's high-contrast, large amount of whitespace, and typography lends itself to be far more readable especially for prose documentation.

I moved urllib3's documentation to Alabaster and it's largely been positively received. I also use a variant in the documentation for several other projects (nox and google-auth).

Is anyone opposed to us switching?

Activity

  1. added
    type: enhancement
    type: question
    on Apr 19, 2017
  2. ncoghlan commented on Apr 22, 2017

    @ncoghlan
    Contributor

    +1 in principle from me (as Alabaster is also closer to the current theming of the main Python documentation), but in the discussion at #62 @qwcode was keen to maintain theming consistency across the PyPA projects, and I think he has a valid point.

    In addition to packaging.python.org, the consistency in theming currently covers:

    That said, there are a few packaging related projects that don't use the default RTD theme:

  3. dstufft commented on Apr 24, 2017

    @dstufft
    Member

    I don't have any problem in switching the other documention to alabaster (www, pip, virtualenv, warehouse). The rest would need to ask their main maintainers.

  4. ncoghlan commented on Apr 24, 2017

    @ncoghlan
    Contributor

    Paging @dholth for wheel, @jaraco for setuptools, and @vsajip for distlib.

    Folks, what do you think of the idea of switching to the new default Alabaster Sphinx theme for the PyPA and PyPA-related project documentation?

  5. vsajip commented on Apr 24, 2017

    @vsajip
    Member

    I don't have very strong views about using Alabaster, though I do prefer sans-serif fonts for body text in documentation. Alabaster doesn't have this as a default.

    IMO sans-serif fonts make documentation seem less fusty and are considered by some to be better for accessibility.

    I note that @jonparrott's Alabaster variant that he mentioned above does use sans-serif fonts for body text.

    Also, Alabaster doesn't use all of the available horizontal space, though perhaps that's a less important issue, as many people don't like to read very long lines of text.

    The distlib docs will use the default Sphinx theme unless overridden with e.g. DISTLIB_DOC_THEME=pydoc make html, which I used for the pythonhosted docs. Hence, on RTD, distlib docs appear with the default RTD theme.

    I agree that consistency would be nice, and my ideal would be an Alabaster-like theme (in terms of colours, layout) with sans-serif body text.

  6. theacodes commented on Apr 24, 2017

    @theacodes
    ContributorAuthor

    IMO sans-serif fonts make documentation seem less fusty and are considered by some to be better for accessibility.

    I'm obviously +1 on sans serif fonts but I was trying to do one thing at a time. :)

  7. jaraco commented on Apr 24, 2017

    @jaraco
    Member

    Fine by me; @jonparrott, would you be willing to submit a PR to setuptools? I'm not sure what needs to be done, maybe just remove the html_theme in conf.py and remove the _theme/nature folder? That's what I would try first, not having spent any time understanding Sphinx themes.

  8. theacodes commented on Apr 24, 2017

    @theacodes
    ContributorAuthor
  9. self-assigned this
    on Apr 24, 2017
  10. theacodes commented on May 23, 2017

    @theacodes
    ContributorAuthor

    After a conversation with @ncoghlan over on #305, it seems like switching to the Python 3 theme might actually be a better choice for consistent identity across PyPA and Python projects (#62).

    The Python 3 theme offers the same benefits as Alabaster - high contrast, legible fonts, and overall cleanliness. It has the added benefit of being consistent with the Python documentation.

    I'm gonna update #305 to use that, there is one drawback - the pydoctheme isn't current distributed as a separate package. I can address that later, but I want to get a preview of what this project would look like with that theme over to you all and the distutils-sig@ mailing list.

  11. vsajip commented on May 23, 2017

    @vsajip
    Member

    I prefer the pydoc theme myself, it's what I used for the distlib docs hosted at
    https://pythonhosted.org/distlib/

  12. changed the title [-]Consider switching to Alabaster theme[/-] [+]Consider switching to themes[/+] on May 26, 2017
  13. changed the title [-]Consider switching to themes[/-] [+]Consider switching themes[/+] on May 26, 2017
  14. ncoghlan commented on May 28, 2017

    @ncoghlan
    Contributor

    At @merwok's suggestion, I started a python-dev thread to get the thoughts of other core developers on the suitability of this approach: https://mail.python.org/pipermail/python-dev/2017-May/148029.html

    Based on @brettcannon's response there, I think the sensible approach to take would be to:

    1. Create python/psf-docs-theme as the base PSF managed repo used to publish the "Official Python Documentation" theme (this will require @brettcannon to create the repo, and add @jonparrott as a contributor)
    2. Add a note to the README for that repo along the lines of: "Please limit use of this theme to projects which are closely affiliated with the Python Software Foundation, and have permission from either the CPython core development team or the PSF itself for such use. For other projects looking for a simple, high contrast, pip installable Sphinx theme, we recommend the Alabaster theme used by default in Sphinx 1.3+."
    3. Decide whether or not it will be practical for PyPA projects to just use that theme directly, or if we'd still want an intervening pypa/pypa-docs-theme to apply PyPA specific tweaks (I have no idea as to how the technical details of pip-installable Sphinx theming work, so I don't know how practical it is to base one theme on another at install time)
  15. theacodes commented on May 31, 2017

    @theacodes
    ContributorAuthor

    @ncoghlan that sounds great. @brettcannon anything I can do to help get this process started? If we can get the repo created before Friday I can make it all happen this week.

    @ncoghlan I think it's definitely worthwhile to go ahead and create pypa-docs-theme. It might just be simple inheritance from the psf theme for now, but we'll probably want some pypa-specific changes at some point. :)

  16. brettcannon commented on May 31, 2017

    @brettcannon
    Member

    I've been waiting for the discussion that @ncoghlan started to wrap up of which there was an email on the topic yesterday. Once that discussion is over I can create the repo.

  17. theacodes commented on May 31, 2017

    @theacodes
    ContributorAuthor
  18. dstufft commented on Jun 1, 2017

    @dstufft
    Member

    FWIW I think the alabaster theme looks nicer than the python docs theme, but I don't have any major objection to using either.

  19. ncoghlan commented on Jun 2, 2017

    @ncoghlan
    Contributor

    @brettcannon Waiting turned out to be a good idea, as my conclusion from that discussion is that it makes more sense to call the repo python/cpython-docs-theme: https://mail.python.org/pipermail/python-dev/2017-June/148183.html

    The suggested phrasing for the note in the README has also changed from what I wrote above to the following:

    Note that when adopting this theme, you're also borrowing an element of the trust and credibility established by the CPython core developers over the years. That's fine, and you're welcome to do so for other Python community projects if you so choose, but please keep in mind that in doing so you're also choosing to accept some of the responsibility for maintaining that collective trust.

  20. brettcannon commented on Jun 2, 2017

    @brettcannon
    Member

    Since the whole thing was slightly contentious I will give it a day to wait for replies, and if nothing comes up I will create the repo (and if I have not by Monday, feel free to ping me to remind me to do so).

  21. brettcannon commented on Jun 4, 2017

    @brettcannon
    Member

    I have created https://github.com/python/python-docs-theme (I dropped the "c" prefix as this isn't special to the CPython implementation).

    @jonparrott I made you a collaborator with write privileges.
    @ncoghlan feel free to tweak the README.

  22. ncoghlan commented on Jun 5, 2017

    @ncoghlan
    Contributor

    @brettcannon The note would look a little odd on an empty repo, so it probably makes more sense for @jonparrott to add it when filling in the extracted theme.

  23. theacodes commented on Jun 5, 2017

    @theacodes
    ContributorAuthor

    Thanks @brettcannon! I should be able to make some progress on this Friday. :)

  24. brettcannon commented on Jun 5, 2017

    @brettcannon
    Member

    @jonparrott Great! And if the description needs a tweak or anything just let me know.

  25. pradyunsg commented on Jun 15, 2017

    @pradyunsg
    Member

    This can be closed now that #305 has merged?

  26. theacodes commented on Jun 15, 2017

    @theacodes
    ContributorAuthor

    Yep. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

type: enhancementtype: question

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions