* [PATCH 0/3] docs: improve readability with left padding adjustments
@ 2026-03-30 5:21 Rito Rhymes
2026-03-30 5:21 ` [PATCH 1/3] docs: add left padding to TOC lists Rito Rhymes
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Rito Rhymes @ 2026-03-30 5:21 UTC (permalink / raw)
To: corbet, skhan; +Cc: linux-doc, linux-kernel, Rito Rhymes
These changes address a few different places where the first
character of rendered text sits too close to the left edge of a
contrasting container, which affects readability.
Add a small amount of left padding to those areas to create
clearer visual separation from the contrasting edge and improve
readability.
Demo site example (all changes visible here):
https://kernel-docs-pl.ritovision.com/userspace-api/liveupdate.html
Screenshots for this series are here:
https://github.com/ritovision/linux-kernel-docs/issues/5
For convenience, anyone is welcome to post additional screenshots
in that GitHub issue for hosting and reference them in discussion
of this series.
TOC lists - before:
https://github.com/user-attachments/assets/994ec5b6-c044-4f5a-bb58-fbf561481ffe
TOC lists - after:
https://github.com/user-attachments/assets/2bced41d-d0b6-44e8-ae28-3e4f721f47d5
Pre and signature - before:
https://github.com/user-attachments/assets/ec063580-9f5c-460d-afc6-3498917c863c
Pre and signature - after:
https://github.com/user-attachments/assets/b5f87275-e4cc-4687-8ca2-42fabb767c2d
Rito Rhymes (3):
docs: add left padding to TOC lists
docs: restore left padding in preformatted blocks
docs: add left padding to C API signature rows
Documentation/sphinx-static/custom.css | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
--
2.51.0
^ permalink raw reply [flat|nested] 4+ messages in thread* [PATCH 1/3] docs: add left padding to TOC lists
2026-03-30 5:21 [PATCH 0/3] docs: improve readability with left padding adjustments Rito Rhymes
@ 2026-03-30 5:21 ` Rito Rhymes
2026-03-30 5:21 ` [PATCH 2/3] docs: restore left padding in preformatted blocks Rito Rhymes
2026-03-30 5:21 ` [PATCH 3/3] docs: add left padding to C API signature rows Rito Rhymes
2 siblings, 0 replies; 4+ messages in thread
From: Rito Rhymes @ 2026-03-30 5:21 UTC (permalink / raw)
To: corbet, skhan; +Cc: linux-doc, linux-kernel, Rito Rhymes
Add a small amount of left padding to the kernel TOC lists.
This improves readability because the TOC lists and their
container use different background colors, and when the first
character sits too close to that contrasting edge it is harder to
read.
Signed-off-by: Rito Rhymes <rito@ritovision.com>
Assisted-by: Codex:GPT-5.4
---
Documentation/sphinx-static/custom.css | 1 +
1 file changed, 1 insertion(+)
diff --git a/Documentation/sphinx-static/custom.css b/Documentation/sphinx-static/custom.css
index db24f4344..6ba3e48bf 100644
--- a/Documentation/sphinx-static/custom.css
+++ b/Documentation/sphinx-static/custom.css
@@ -64,6 +64,7 @@ div.kerneltoc li.toctree-l2,li.toctree-l3 { font-size: small;
margin-left: 1em;
list-style-type: none;
}
+div.kerneltoc ul { padding-left: 10px; }
div.kerneltoc li.current ul { margin-left: 0; }
div.kerneltoc { background-color: #eeeeee; }
div.kerneltoc li.current ul { background-color: white; }
--
2.51.0
^ permalink raw reply related [flat|nested] 4+ messages in thread* [PATCH 2/3] docs: restore left padding in preformatted blocks
2026-03-30 5:21 [PATCH 0/3] docs: improve readability with left padding adjustments Rito Rhymes
2026-03-30 5:21 ` [PATCH 1/3] docs: add left padding to TOC lists Rito Rhymes
@ 2026-03-30 5:21 ` Rito Rhymes
2026-03-30 5:21 ` [PATCH 3/3] docs: add left padding to C API signature rows Rito Rhymes
2 siblings, 0 replies; 4+ messages in thread
From: Rito Rhymes @ 2026-03-30 5:21 UTC (permalink / raw)
To: corbet, skhan; +Cc: linux-doc, linux-kernel, Rito Rhymes
Restore a small amount of left padding to preformatted blocks.
This improves readability because the preformatted block and its
container use different background colors, and when the first
character sits too close to that contrasting edge it is harder to
read.
This only changes the rendered left padding around the block. It
does not change the code itself or what gets copied from it.
Signed-off-by: Rito Rhymes <rito@ritovision.com>
Assisted-by: Codex:GPT-5.4
---
Documentation/sphinx-static/custom.css | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/Documentation/sphinx-static/custom.css b/Documentation/sphinx-static/custom.css
index 6ba3e48bf..64ea94879 100644
--- a/Documentation/sphinx-static/custom.css
+++ b/Documentation/sphinx-static/custom.css
@@ -50,7 +50,8 @@ div.kernelindent { margin-left: 2em; margin-right: 4em; }
dl.py { margin-top: 2em; background-color: #ecf0f3; }
dl.py.class { margin-left: 2em; text-indent: -2em; padding-left: 2em; }
dl.py.method, dl.py.attribute { margin-left: 2em; text-indent: -2em; }
-dl.py li, pre { text-indent: 0em; padding-left: 0 !important; }
+dl.py li { text-indent: 0em; }
+pre { text-indent: 0em; padding-left: 10px !important; }
/*
* Tweaks for our local TOC
--
2.51.0
^ permalink raw reply related [flat|nested] 4+ messages in thread* [PATCH 3/3] docs: add left padding to C API signature rows
2026-03-30 5:21 [PATCH 0/3] docs: improve readability with left padding adjustments Rito Rhymes
2026-03-30 5:21 ` [PATCH 1/3] docs: add left padding to TOC lists Rito Rhymes
2026-03-30 5:21 ` [PATCH 2/3] docs: restore left padding in preformatted blocks Rito Rhymes
@ 2026-03-30 5:21 ` Rito Rhymes
2 siblings, 0 replies; 4+ messages in thread
From: Rito Rhymes @ 2026-03-30 5:21 UTC (permalink / raw)
To: corbet, skhan; +Cc: linux-doc, linux-kernel, Rito Rhymes
Add a small amount of left padding to rendered C API signature
rows.
This improves readability because the signature row and its
container use different background colors, and when the first
character sits too close to that contrasting edge it is harder to
read.
Signed-off-by: Rito Rhymes <rito@ritovision.com>
Assisted-by: Codex:GPT-5.4
---
Documentation/sphinx-static/custom.css | 1 +
1 file changed, 1 insertion(+)
diff --git a/Documentation/sphinx-static/custom.css b/Documentation/sphinx-static/custom.css
index 64ea94879..41413b683 100644
--- a/Documentation/sphinx-static/custom.css
+++ b/Documentation/sphinx-static/custom.css
@@ -40,6 +40,7 @@ li { text-indent: 0em; }
dl.function, dl.struct, dl.enum { margin-top: 2em; background-color: #ecf0f3; }
/* indent lines 2+ of multi-line function prototypes */
dl.function dt { margin-left: 10em; text-indent: -10em; }
+dl.c > dt { padding-left: 10px; }
dt.sig-object { font-size: larger; }
div.kernelindent { margin-left: 2em; margin-right: 4em; }
--
2.51.0
^ permalink raw reply related [flat|nested] 4+ messages in thread
end of thread, other threads:[~2026-03-30 5:22 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-30 5:21 [PATCH 0/3] docs: improve readability with left padding adjustments Rito Rhymes
2026-03-30 5:21 ` [PATCH 1/3] docs: add left padding to TOC lists Rito Rhymes
2026-03-30 5:21 ` [PATCH 2/3] docs: restore left padding in preformatted blocks Rito Rhymes
2026-03-30 5:21 ` [PATCH 3/3] docs: add left padding to C API signature rows Rito Rhymes
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox