You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/source/quick-start.rst
+15-15Lines changed: 15 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -43,12 +43,12 @@ Customize the theme
43
43
44
44
The following features of Nefertiti for Sphinx can be customized:
45
45
46
-
1. Fonts.
47
-
2. Color set: blue, indigo, purple, pink, red, ...
48
-
3. Pygments styles for light and dark color schemes.
49
-
4. Repository name and URL to display it in the header.
50
-
5. Project version dropdown selector.
51
-
6. Footer links.
46
+
1. Fonts.
47
+
2. Color set: blue, indigo, purple, pink, red, ...
48
+
3. Pygments styles for light and dark color schemes.
49
+
4. Repository name and URL to display it in the header.
50
+
5. Project version dropdown selector.
51
+
6. Footer links.
52
52
53
53
54
54
1. Fonts
@@ -58,16 +58,16 @@ There are 5 options related to font face customization and 2 options related to
58
58
59
59
The font face options are:
60
60
61
-
* ``sans_serif_font``: Default site font, defaults to `Nunito <https://www.fontsquirrel.com/fonts/nunito?q%5Bterm%5D=Nunito&q%5Bsearch_check%5D=Y>`_.
62
-
* ``monospace_font``: Default monospace font, for code blocks, defaults to `Red Hat Mono <https://www.fontsquirrel.com/fonts/ubuntu-mono?q%5Bterm%5D=Ubuntu+Mono&q%5Bsearch_check%5D=Y>`_.
63
-
* ``project_name_font``: The font for the Project's name. ``sans_serif_font`` otherwise.
64
-
* ``documentation_font``: reStructuredText and Markdown content. ``sans_serif_font`` otherwise.
65
-
* ``doc_headers_font``: To render documentation headers. ``documentation_font`` otherwise.
61
+
* ``sans_serif_font``: Default site font, defaults to `Nunito <https://www.fontsquirrel.com/fonts/nunito?q%5Bterm%5D=Nunito&q%5Bsearch_check%5D=Y>`_.
62
+
* ``monospace_font``: Default monospace font, for code blocks, defaults to `Red Hat Mono <https://www.fontsquirrel.com/fonts/ubuntu-mono?q%5Bterm%5D=Ubuntu+Mono&q%5Bsearch_check%5D=Y>`_.
63
+
* ``project_name_font``: The font for the Project's name. ``sans_serif_font`` otherwise.
64
+
* ``documentation_font``: reStructuredText and Markdown content. ``sans_serif_font`` otherwise.
65
+
* ``doc_headers_font``: To render documentation headers. ``documentation_font`` otherwise.
66
66
67
67
And the font size options:
68
68
69
-
* ``monospace_font_size``: The CSS ``font-size`` for the ``monospace_font``. ie: ``"1rem"``.
70
-
* ``documentation_font_size``: The CSS ``font-size`` for the ``documentation_font``. ie: ``"1.1rem"``.
69
+
* ``monospace_font_size``: The CSS ``font-size`` for the ``monospace_font``. ie: ``"1rem"``.
70
+
* ``documentation_font_size``: The CSS ``font-size`` for the ``documentation_font``. ie: ``"1.1rem"``.
71
71
72
72
Edit your ``conf.py`` file and add or modify your ``html_theme_options`` setting with the following content. By the way, the fonts referred to in this example are part of the Nefertiti for Sphinx distribution. If you want to use other Open Source licensed fonts read the section "How to add more fonts" to include them with your project.
73
73
@@ -104,8 +104,8 @@ When ``style`` is not given the theme defaults to ``cyan``.
104
104
105
105
Pygments_ is the package in charge of rendering code blocks. Sphinx supports two settings related with pygments:
106
106
107
-
* ``pygments_style``, applied when browser's ``prefers-color-scheme`` returns **light**.
108
-
* ``pygments_dark_style``, applied when browser's ``prefers-color-scheme`` returns **dark**.
107
+
* ``pygments_style``, applied when browser's ``prefers-color-scheme`` returns **light**.
108
+
* ``pygments_dark_style``, applied when browser's ``prefers-color-scheme`` returns **dark**.
109
109
110
110
Nefertiti for Sphinx extends the use of these settings in a way that their styling is applied when the user selects the scheme in the light/dark dropdown, at the right side of the header.
Copy file name to clipboardExpand all lines: docs/source/users-guide/components/index.rst
+17-14Lines changed: 17 additions & 14 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,19 +5,22 @@ Components
5
5
6
6
The following pages contain examples of visual elements that can be included in Sphinx docs. The goals of this section are:
7
7
8
-
* To show how these elements look like when using Nefertiti for Sphinx,
9
-
* to help with the development of the theme itself, and
10
-
* to serve as a reminder of how to include these elements in reStructuredText and Markdown documents.
8
+
* To show how these elements look like when using Nefertiti for Sphinx,
9
+
* to help with the development of the theme itself, and
10
+
* to serve as a reminder of how to include these elements in reStructuredText and Markdown documents.
11
11
12
-
.. toctree::
13
-
:maxdepth:1
12
+
.. toctree::
13
+
:maxdepth:1
14
14
15
-
admonitions
16
-
code-blocks
17
-
headings
18
-
images
19
-
figures
20
-
lists
21
-
tables
22
-
math
23
-
footnotes
15
+
admonitions
16
+
code-blocks
17
+
headings
18
+
images
19
+
figures
20
+
lists
21
+
tables
22
+
math
23
+
footnotes
24
+
25
+
26
+
The sphinx-themes.org project collects and tests many Sphinx themes with an extensive set of markup elements. Visit the section dedicated to `Nefertiti for Sphinx <https://sphinx-themes.org/sample-sites/sphinx-nefertiti/>`_ to see how the theme renders the testing documentation of sphinx-themes.org.
Copy file name to clipboardExpand all lines: docs/source/users-guide/customization/color-sets.rst
+11-11Lines changed: 11 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -107,11 +107,11 @@ To apply custom style changes on top of Nefertiti you can create your own styles
107
107
108
108
For example, if you wanted to use the color set **green** but using different colors in the header you would do the following:
109
109
110
-
#. Create a new stylesheet, say a new ``custom.css`` file, inside your source ``_static`` directory with the style changes you want to apply to the header, and
111
-
#. Update your ``conf.py`` file to change two entries:
110
+
#. Create a new stylesheet, say a new ``custom.css`` file, inside your source ``_static`` directory with the style changes you want to apply to the header, and
111
+
#. Update your ``conf.py`` file to change two entries:
112
112
113
-
* Set your ``html_style`` to ``["custom.css"]`` at module scope, to tell Sphinx to load the new stylesheet when building the site.
114
-
* Set ``"style"`` to ``"green"`` inside ``html_theme_options``.
113
+
+ Set your ``html_style`` to ``["custom.css"]`` at module scope, to tell Sphinx to load the new stylesheet when building the site.
114
+
+ Set ``"style"`` to ``"green"`` inside ``html_theme_options``.
115
115
116
116
The next two sections implement the changes.
117
117
@@ -181,11 +181,11 @@ A color set is basically a complete new theme created out of the content given i
181
181
182
182
To develop a new color set we need to go through the following steps:
183
183
184
-
#. Create ``.scss`` files.
185
-
#. Build the color set.
186
-
#. Test the color set.
187
-
#. Add the color set to the Sphinx theme.
188
-
#. Use the color set.
184
+
#. Create ``.scss`` files.
185
+
#. Build the color set.
186
+
#. Test the color set.
187
+
#. Add the color set to the Sphinx theme.
188
+
#. Use the color set.
189
189
190
190
As an example the following sections show how to create a new color set called **django** that tries to resemble the colors used in the Django_ website.
191
191
@@ -277,8 +277,8 @@ If you had any other changes to apply specifically to the new ``django`` color s
277
277
278
278
The ``package.json`` files offers two scripts to build style files:
279
279
280
-
* ``css-compile``: to compile all the SASS files within the ``scss/`` directory.
281
-
* ``watch-css``: to call ``css-compile`` when there are changes in the ``scss/`` directory.
280
+
* ``css-compile``: to compile all the SASS files within the ``scss/`` directory.
281
+
* ``watch-css``: to call ``css-compile`` when there are changes in the ``scss/`` directory.
Copy file name to clipboardExpand all lines: docs/source/users-guide/customization/fonts.rst
+37-37Lines changed: 37 additions & 37 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -19,16 +19,16 @@ Font settings
19
19
20
20
There are 5 font face customization settings that can be added to ``html_theme_options``, in your ``conf.py``:
21
21
22
-
* **sans_serif_font**: It is the default global site font used for everything except code blocks and inline code samples. It defaults to `Nunito`_.
23
-
* **monospace_font**: It is the default monospace font used for code blocks and inline code samples. It defaults to `Red Hat Mono`_.
24
-
* **project_name_font**: It is the font used to render the project's name in the header and the footer. When not given it default to the **sans_serif_font** option.
25
-
* **documentation_font**: It is the font used to render the actual documentation contained in reStructuredText or Markdown files. It defaults to the **sans_serif_font**.
26
-
* **doc_headers_font**: It is the font used to render documentation headers. When not given it defaults to the **Georgia** web safe font.
22
+
* **sans_serif_font**: It is the default global site font used for everything except code blocks and inline code samples. It defaults to `Nunito`_.
23
+
* **monospace_font**: It is the default monospace font used for code blocks and inline code samples. It defaults to `Red Hat Mono`_.
24
+
* **project_name_font**: It is the font used to render the project's name in the header and the footer. When not given it default to the **sans_serif_font** option.
25
+
* **documentation_font**: It is the font used to render the actual documentation contained in reStructuredText or Markdown files. It defaults to the **sans_serif_font**.
26
+
* **doc_headers_font**: It is the font used to render documentation headers. When not given it defaults to the **Georgia** web safe font.
27
27
28
28
Additionally there are two font size settings:
29
29
30
-
* **documentation_font_size**: Specifies the default font size for the documentation contained in reStructuredText or Markdown files. It defaults to ``1.0rem``, which corresponds to ``16px``.
31
-
* **monospace_font_size**: Specifies the default font size to use with code blocks and inline code samples. It defaults to ``1.0rem``, corresponding to ``16px``.
30
+
* **documentation_font_size**: Specifies the default font size for the documentation contained in reStructuredText or Markdown files. It defaults to ``1.0rem``, which corresponds to ``16px``.
31
+
* **monospace_font_size**: Specifies the default font size to use with code blocks and inline code samples. It defaults to ``1.0rem``, corresponding to ``16px``.
32
32
33
33
You can ignore these settings and let Nefertiti for Sphinx use the default font settings, or you can customize them.
34
34
@@ -37,20 +37,20 @@ Fonts bundled with Nefertiti
37
37
38
38
Nefertiti for Sphinx is bundled with a group of fonts with licenses open for free distribution:
39
39
40
-
* Assistant_
41
-
* Exo_
42
-
* Montserrat_
43
-
* Mulish_
44
-
* Nunito_
45
-
* `Open Sans`_
46
-
* `Red Hat Display`_
47
-
* `Sofia Sans`_
48
-
* Ubuntu_
49
-
* Varta_
50
-
* `Work Sans`_
51
-
* `Fira Code`_ (monospace)
52
-
* `Red Hat Mono`_ (monospace)
53
-
* `Ubuntu Mono`_ (monospace)
40
+
* Assistant_
41
+
* Exo_
42
+
* Montserrat_
43
+
* Mulish_
44
+
* Nunito_
45
+
* `Open Sans`_
46
+
* `Red Hat Display`_
47
+
* `Sofia Sans`_
48
+
* Ubuntu_
49
+
* Varta_
50
+
* `Work Sans`_
51
+
* `Fira Code`_ (monospace)
52
+
* `Red Hat Mono`_ (monospace)
53
+
* `Ubuntu Mono`_ (monospace)
54
54
55
55
Web safe fonts
56
56
**************
@@ -59,12 +59,12 @@ You can customize the font settings to use Web safe fonts. Unlike the previous f
59
59
60
60
Here is a list of font categories and their web safe fonts provided by all major web browsers:
0 commit comments