Lightweight, configurable Sphinx theme. Now the Sphinx default!

Overview

What is Alabaster?

Alabaster is a visually (c)lean, responsive, configurable theme for the Sphinx documentation system. It is Python 2+3 compatible.

It began as a third-party theme, and is still maintained separately, but as of Sphinx 1.3, Alabaster is an install-time dependency of Sphinx and is selected as the default theme.

Live examples of this theme can be seen on this project's own website, paramiko.org, fabfile.org and pyinvoke.org.

For more documentation, please see http://alabaster.readthedocs.io.

Note

You can install the development version via pip install -e git+https://github.com/bitprophet/alabaster/#egg=alabaster.

Comments
  • Try switching Georgia (vs Goudy Old Style) to be explicit first font choice

    Try switching Georgia (vs Goudy Old Style) to be explicit first font choice

    I find the typeface to be too thin for continuous pleasant reading and would consider something akin to Georgia (which Flask uses for example) to be better. It's also bigger, but the typeface definitely plays a larger role.

    I suggest opening the images in new tabs for optimal viewing (github resized them).

    source: http://docs.python-requests.org/en/master/ 2016-02-23_18 31 08

    source: http://flask.pocoo.org/docs/0.10/errorhandling/ 2016-02-23_18 33 45

    bug enhancement 
    opened by FichteFoll 68
  • Enable optional links to *next* and *previous* items

    Enable optional links to *next* and *previous* items

    Fixes #18. I finally got annoyed enough at the feature not being there that I added it myself.

    The links are optional, and off by default. Under theme options, set show_relbars = True to enable them.

    The top and bottom bars can be individually toggled. The border color can also be customized. Documentation is also included.

    image

    image

    enhancement 
    opened by MinchinWeb 16
  • Tabular Bibliography Entries

    Tabular Bibliography Entries

    Dear Jeff, congrats for your alabaster ext. I love it! I encounter problems in changing the ugly border of the bibliography entries (generated by sphinx-contrib-bibtex): they appear by default in tables with 1px border and I haven't succeeded in putting it without border (but I need that regular tables to keep their border as well). This might be changed in the theme.conf file. See end of this file: http://webcom.upmf-grenoble.fr/sciedu/pdessus/sapea/innovation.html Thx for your help in advance! best philippe

    opened by pdessus 14
  • Support for

    Support for "next" and "previous" links

    It'd be great if there were links to the previous and next posts in every page (where applicable).

    (By the way, thanks for the theme! I like it a lot)

    enhancement 
    opened by gnarea 14
  • encoding error when openening readme in setup.py

    encoding error when openening readme in setup.py

    Hi

    In commit a8c8b2cd3f8546245e36976ed2c12662b0fd4117 should this be:

    with open('README.rst'), encoding='utf-8') as f:
        readme = f.read() 
    

    I'm getting the following error when building using python3 (on the opensuse build server)

     python3 setup.py build
    [   97s] Traceback (most recent call last):
    [   97s]   File "setup.py", line 13, in <module>
    [   97s]     readme = f.read()
    [   97s]   File "/usr/lib64/python3.4/encodings/ascii.py", line 26, in decode
    [   97s]     return codecs.ascii_decode(input, self.errors)[0]
    [   97s] UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 15684: ordinal not in range(128)
    [   97s] error: Bad exit status from /var/tmp/rpm-tmp.SU1PL3 (%build)
    

    see https://build.opensuse.org/package/live_build_log/home:apersaud:branches:devel:languages:python3/python3-alabaster/openSUSE_13.2/x86_64

    opened by arunpersaud 13
  • One of our fonts may become fully italicized on latest Safari tech preview release?

    One of our fonts may become fully italicized on latest Safari tech preview release?

    [@hynek] Nice, the alabaster theme is broken in Safari TP (and Safari TP only). http://attrs.readthedocs.io/en/latest/ is all italics to me. cc @bitprophet ... running Release 26 (Safari 10.2, WebKit 12604.1.12)

    [@jgelens] hmm looks fine here, using the latest TP ... I don't have these fonts though, maybe it's with that? "'goudy old style', 'minion pro', 'bell mt'"

    [@hynek] that’s my suspicion too. I’ve just checked, http://www.python-requests.org/en/master/ looks broken too. 🎉 Thanks Apple! ... yeah it’s something with goudy old style. removing it makes it look fine


    So tl;dr if this isn't some odd TP-only bug that'll get fixed before release, Apple may have switched up fonts somehow, e.g.:

    • the font-face normally selected by Safari on Hynek's Mac is now italic by default when it wasn't before
    • Safari is now choosing a different font-face from our list than it used to - one that would have appeared as italics beforehand.
      • Which could possibly be the same as what Kenneth references in this comment: https://github.com/bitprophet/alabaster/issues/73#issuecomment-188608656 ?
      • Italics isn't the same as "really thin" but it's close enough to make me suspicious that the font just generally doesn't look good, assuming we find Hynek's Safari was not choosing Goudy before.
    opened by bitprophet 12
  • Add donate_url and opencollective options to add donate buttons to the sidebar

    Add donate_url and opencollective options to add donate buttons to the sidebar

    When either are set, adds a "Donate" section to the sidebar. If donate_url is set, a "donate" shield button is used. If opencollective is set, an OpenCollective button is used.

    With donate_url = ""https://www.paypal.me/StevenLoria":

    donate button

    With opencollective = "marshmallow":

    opencollective button

    Both may be set:

    both buttons

    I also removed the underlines from badges in the sidebar, which I assumed were inadvertent:

    Before

    with underlines

    After

    without underlines

    opened by sloria 11
  • Remove Gratipay integration - gratipay has shut down

    Remove Gratipay integration - gratipay has shut down

    Gratipay shut down at the end of 2017. It's a shame because open source sustainability is an important topic. Perhaps instead of removing donate.html, we could extend it to support patreon and open collective? (are there other services?)

    bug enhancement 
    opened by joealcorn 7
  • Navigation isn't rendered

    Navigation isn't rendered

    Not sure if this issue should go to sphinx itself, but the new recommendation to use alabaster in 1.3 causes some unexpected behavior with domains providing indices: the navigation div is not visible with alabaster, unlike in classic.

    For example the httpdomain creates a routing table page, and links to it in the navigation div:

    <div class="related" role="navigation" aria-label="related navigation">
      <h3>Navigation</h3>
      <ul>
        <li class="right" style="margin-right: 10px">
          <a href="genindex.html" title="General Index"
             accesskey="I">index</a></li>
        <li class="right" >
          <a href="http-routingtable.html" title="HTTP Routing Table"
             >routing table</a> |</li>
      </ul>
    </div>
    
    bug 
    opened by hukka 7
  • Various block-level elements are 'outdented' and it looks ugly

    Various block-level elements are 'outdented' and it looks ugly

    I wrote this docstring:

    def bar(age):
        """
        this is bar function
    
        >>> import foo
        >>> foo.bar(10)
        10
    
        This function just return age.
    
        :param int age: your age
        :return: age
        :rtype: int
        """
        return age
    

    and built with using 'classic' theme, I got this image: image

    I git this image with using 'alabaster' theme: image

    It would be better to understand the document if gray box for doctest lines doesn't protrude outside the docstring content area.

    bug 
    opened by shimizukawa 7
  • Auto-hyphens show as tofu in Chromium-based browsers

    Auto-hyphens show as tofu in Chromium-based browsers

    • macOS Monterey
    • Chrome 95
    • Chrome Canary 98
    • Opera 71 (also Chromium)

    The CSS uses hyphens: auto which inserts hyphens for some words, however with the hyphen shows as an empty box aka "tofu":

    image

    https://alabaster.readthedocs.io/en/latest/changelog.html

    Non-Chromium browsers such as Firefox 94 (pictured here) and Safari 15.1 are fine:

    image

    Also reported to Chromium: https://bugs.chromium.org/p/chromium/issues/detail?id=1270110

    opened by hugovk 6
  • Bump wheel from 0.24 to 0.38.1

    Bump wheel from 0.24 to 0.38.1

    Bumps wheel from 0.24 to 0.38.1.

    Changelog

    Sourced from wheel's changelog.

    Release Notes

    UNRELEASED

    • Updated vendored packaging to 22.0

    0.38.4 (2022-11-09)

    • Fixed PKG-INFO conversion in bdist_wheel mangling UTF-8 header values in METADATA (PR by Anderson Bravalheri)

    0.38.3 (2022-11-08)

    • Fixed install failure when used with --no-binary, reported on Ubuntu 20.04, by removing setup_requires from setup.cfg

    0.38.2 (2022-11-05)

    • Fixed regression introduced in v0.38.1 which broke parsing of wheel file names with multiple platform tags

    0.38.1 (2022-11-04)

    • Removed install dependency on setuptools
    • The future-proof fix in 0.36.0 for converting PyPy's SOABI into a abi tag was faulty. Fixed so that future changes in the SOABI will not change the tag.

    0.38.0 (2022-10-21)

    • Dropped support for Python < 3.7
    • Updated vendored packaging to 21.3
    • Replaced all uses of distutils with setuptools
    • The handling of license_files (including glob patterns and default values) is now delegated to setuptools>=57.0.0 (#466). The package dependencies were updated to reflect this change.
    • Fixed potential DoS attack via the WHEEL_INFO_RE regular expression
    • Fixed ValueError: ZIP does not support timestamps before 1980 when using SOURCE_DATE_EPOCH=0 or when on-disk timestamps are earlier than 1980-01-01. Such timestamps are now changed to the minimum value before packaging.

    0.37.1 (2021-12-22)

    • Fixed wheel pack duplicating the WHEEL contents when the build number has changed (#415)
    • Fixed parsing of file names containing commas in RECORD (PR by Hood Chatham)

    0.37.0 (2021-08-09)

    • Added official Python 3.10 support
    • Updated vendored packaging library to v20.9

    ... (truncated)

    Commits
    • 6f1608d Created a new release
    • cf8f5ef Moved news item from PR #484 to its proper place
    • 9ec2016 Removed install dependency on setuptools (#483)
    • 747e1f6 Fixed PyPy SOABI parsing (#484)
    • 7627548 [pre-commit.ci] pre-commit autoupdate (#480)
    • 7b9e8e1 Test on Python 3.11 final
    • a04dfef Updated the pypi-publish action
    • 94bb62c Fixed docs not building due to code style changes
    • d635664 Updated the codecov action to the latest version
    • fcb94cd Updated version to match the release
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language

    You can disable automated security fix PRs for this repo from the Security Alerts page.

    dependencies 
    opened by dependabot[bot] 0
  • Support New Google Analytics 4

    Support New Google Analytics 4

    Alabaster supports Google Analytics UA via 'analytics_id' options. This will be deprecated in summer 2023, and for a new account, you have to jump through hoops to even get a UA id if you do not already have one, it is not at all simple. Even if you do this, it is basically a dual GA4/UA account, and kinda messy.

    https://support.google.com/analytics/answer/9304153

    This site explains the setup of an account, and then the section on 'Add the Google tag directly to your webpages' explains what you need to do. They have some site types where it seems like it can automatically add, and for others it gives manual instructions.

    I was successfully able to get this to work by adding it into the layout.html included with Alabaster as shown:

    {%- set theme_show_relbar_top = theme_show_relbar_top or theme_show_relbars %}
    {%- set theme_show_relbar_bottom = theme_show_relbar_bottom or theme_show_relbars %}
    
    {# removed existing top+bottom related nav, and embed in main content #}
    {%- block relbar1 %}{% endblock %}
    {%- block relbar2 %}{% endblock %}
    
    {# Nav should appear before content, not after #}
    {%- block content %}
    <!-- Google tag (gtag.js) -->
    <script async src="https://www.googletagmanager.com/gtag/js?id=G-3ZFF0CWSJN"></script>
            <script>
                                      window.dataLayer = window.dataLayer || [];
      function gtag(){dataLayer.push(arguments);}
      gtag('js', new Date());
    
      gtag('config', 'G-XXXXXXX');
            </script>
    {%- if theme_fixed_sidebar|lower == 'true' %}
      <div class="document">
        {{ sidebar() }}
        {%- block document %}
    

    what is in there as ''G-XXXXXXX' should be the GA4 analytics_id to be used, so would need to be a configurable option.

    opened by warmstarter 0
  • Item markers of mobile menu should have a different color

    Item markers of mobile menu should have a different color

    If you look at the theme, in a mobile mode, you will see that the markers (which are squares) of the nested menu items are black (or some very dark color), which is the same color as the background of the menu in that case, so that makes the markers not very visible. Either we can get rid of the markers or change the color to something more visible with that background.

    opened by nbro10 0
  • Fix layout of logo.

    Fix layout of logo.

    Having <h1> inside <p> led some browsers (e.g., Firefox) to believe that the HTML code was ill-formed. Thus, they inserted </p> before <h1>, causing the logo to be incorrectly pushed away from the logo name. Below are screenshots showing the issue.

    Before the pull request: before

    After the pull request: after

    opened by silene 0
  • Misaligned dd and dt in definition lists

    Misaligned dd and dt in definition lists

    In definition lists, dt and dd entries are slightly misaligned. https://github.com/bitprophet/alabaster/blob/6a0a56ffe79bd039085e1ad7ed26da5b217bd4ab/alabaster/static/alabaster.css_t#L279-L281 Adding div.body dt to the list of selected items above will fix this. Using alabaster v0.7.12 and sphinx v4.5.0. alabaster

    opened by nkr0 0
Owner
Jeff Forcier
Developer/sysadmin. Maintainer of fine Python automation tools. Tries balancing 'done right' & 'done on time'; occasionally succeeds. He/him.
Jeff Forcier
Sphinx theme for readthedocs.org

Read the Docs Sphinx Theme This Sphinx theme was designed to provide a great reader experience for documentation users on both desktop and mobile devi

Read the Docs 4.3k Dec 31, 2022
Sphinx Bootstrap Theme

Sphinx Bootstrap Theme This Sphinx theme integrates the Bootstrap CSS / JavaScript framework with various layout options, hierarchical menu navigation

Ryan Roemer 584 Nov 16, 2022
A Sublime Text plugin to select a default syntax dialect

Default Syntax Chooser This Sublime Text 4 plugin provides the set_default_syntax_dialect command. This command manipulates a syntax file (e.g.: SQL.s

null 3 Jan 14, 2022
A Material Design theme for MkDocs

A Material Design theme for MkDocs Create a branded static site from a set of Markdown files to host the documentation of your Open Source or commerci

Martin Donath 12.3k Jan 4, 2023
My Sublime Text theme

rsms sublime text theme Install: cd path/to/your/sublime/packages git clone https://github.com/rsms/sublime-theme.git rsms-theme You'll also need the

Rasmus 166 Jan 4, 2023
Main repository for the Sphinx documentation builder

Sphinx Sphinx is a tool that makes it easy to create intelligent and beautiful documentation for Python projects (or other documents consisting of mul

null 5.1k Jan 2, 2023
A curated list of awesome tools for Sphinx Python Documentation Generator

Awesome Sphinx (Python Documentation Generator) A curated list of awesome extra libraries, software and resources for Sphinx (Python Documentation Gen

Hyunjun Kim 831 Dec 27, 2022
Main repository for the Sphinx documentation builder

Sphinx Sphinx is a tool that makes it easy to create intelligent and beautiful documentation for Python projects (or other documents consisting of mul

null 5.1k Jan 4, 2023
Numpy's Sphinx extensions

numpydoc -- Numpy's Sphinx extensions This package provides the numpydoc Sphinx extension for handling docstrings formatted according to the NumPy doc

NumPy 234 Dec 26, 2022
ReStructuredText and Sphinx bridge to Doxygen

Breathe Packagers: PGP signing key changes for Breathe >= v4.23.0. https://github.com/michaeljones/breathe/issues/591 This is an extension to reStruct

Michael Jones 643 Dec 31, 2022
Type hints support for the Sphinx autodoc extension

sphinx-autodoc-typehints This extension allows you to use Python 3 annotations for documenting acceptable argument types and return value types of fun

Alex Grönholm 462 Dec 29, 2022
Watch a Sphinx directory and rebuild the documentation when a change is detected. Also includes a livereload enabled web server.

sphinx-autobuild Rebuild Sphinx documentation on changes, with live-reload in the browser. Installation sphinx-autobuild is available on PyPI. It can

Executable Books 440 Jan 6, 2023
sphinx builder that outputs markdown files.

sphinx-markdown-builder sphinx builder that outputs markdown files Please ★ this repo if you found it useful ★ ★ ★ If you want frontmatter support ple

Clay Risser 144 Jan 6, 2023
A powerful Sphinx changelog-generating extension.

What is Releases? Releases is a Python (2.7, 3.4+) compatible Sphinx (1.8+) extension designed to help you keep a source control friendly, merge frien

Jeff Forcier 166 Dec 29, 2022
📖 Generate markdown API documentation from Google-style Python docstring. The lazy alternative to Sphinx.

lazydocs Generate markdown API documentation for Google-style Python docstring. Getting Started • Features • Documentation • Support • Contribution •

Machine Learning Tooling 118 Dec 31, 2022
Seamlessly integrate pydantic models in your Sphinx documentation.

Seamlessly integrate pydantic models in your Sphinx documentation.

Franz Wöllert 71 Dec 26, 2022
Speed up Sphinx builds by selectively removing toctrees from some pages

Remove toctrees from Sphinx pages Improve your Sphinx build time by selectively removing TocTree objects from pages. This is useful if your documentat

Executable Books 8 Jan 4, 2023
python package sphinx template

python-package-sphinx-template python-package-sphinx-template

Soumil Nitin Shah 2 Dec 26, 2022
epub2sphinx is a tool to convert epub files to ReST for Sphinx

epub2sphinx epub2sphinx is a tool to convert epub files to ReST for Sphinx. It uses Pandoc for converting HTML data inside epub files into ReST. It cr

Nihaal 8 Dec 15, 2022