Skip to contentSkip to conversation

docs: contain overflow from long links

PATCH Superseded Rito Rhymes 3 participants 11 messages Mar 21 – Mar 25 Documentation

lore
Share & tools
lore
#0 lore raw

cover docs: contain overflow from long links

Patch 1 allows long link text to wrap per character so unbroken links in the main document body do not force page-wide horizontal scroll overflow.

Patch 2 remains necessary for rendered reference links inside docutils tables, where the affected table case still needs an explicit selector to keep the table within the content column.

Some of these pages may also overflow for other reasons, but the examples listed under [2/2] specifically include tables containing long reference links that may still need a table-specific CSS rule to keep the table within the content column.

Examples of affected pages on docs.kernel.org this patch improves:

[1/2]
firmware-guide/acpi/non-d0-probe.html
firmware-guide/acpi/lpit.html
arch/arm/vlocks.html
arch/arm/keystone/overview.html
arch/arm/keystone/knav-qmss.html
arch/loongarch/introduction.html
arch/nios2/nios2.html
arch/x86/earlyprintk.html
arch/x86/orc-unwinder.html#etymology
arch/x86/tdx.html
arch/x86/sva.html
driver-api/xilinx/eemi.html

[2/2]
arch/openrisc/openrisc_port.html
power/apm-acpi.html
networking/devlink/stmmac.html
filesystems/ext2.html
networking/l2tp.html
process/embargoed-hardware-issues.html
arch/x86/boot.html
networking/devlink/devlink-info.html
admin-guide/sysctl/fs.html
userspace-api/ioctl/ioctl-number.html

Rito Rhymes (2):
docs: allow long links to wrap per character to prevent page overflow
docs: allow long table reference links to wrap and prevent overflow

 Documentation/sphinx-static/custom.css | 10 ++++++++++
 1 file changed, 10 insertions(+)
Signature · 1 line
2.51.0
#1 lore raw

PATCH 1/2 docs: allow long links to wrap per character to prevent page overflow

Some documentation pages contain long link text without natural break points, which can force page-wide horizontal scroll overflow on small screens.

Use overflow-wrap: anywhere for anchor text in the docs stylesheet so links can wrap per character as a fallback when normal word boundaries are unavailable.

---
 Documentation/sphinx-static/custom.css | 5 +++++
 1 file changed, 5 insertions(+)
Documentation/sphinx-static/custom.css +5 -0
index db24f4344..4ec617d40 100644
@@ -149,6 +149,11 @@ div.language-selection ul li:hover {
     background: #dddddd;
 }
 
+/* Let long link text wrap instead of forcing overflow. */
+a {
+    overflow-wrap: anywhere;
+}
+
 /* Make xrefs more universally visible */
 a.reference, a.reference:hover {
     border-bottom: none;
Signature · 1 line
2.51.0
#2 lore raw

PATCH 2/2 docs: allow long table reference links to wrap and prevent overflow

In reply to Rito Rhymes

Some documentation pages contain docutils tables with reference links that use long unbroken strings. Those strings can expand the table width beyond the content column and cause page-wide horizontal overflow.

Allow reference links in docutils tables in the main document body to wrap when needed so the table stays within the content column and does not break page layout.

---
 Documentation/sphinx-static/custom.css | 5 +++++
 1 file changed, 5 insertions(+)
Documentation/sphinx-static/custom.css +5 -0
index 4ec617d40..b41c54c71 100644
@@ -154,6 +154,11 @@ a {
     overflow-wrap: anywhere;
 }
 
+/* Let rendered reference links in tables wrap when needed. */
+div.body table.docutils a.reference {
+    overflow-wrap: anywhere;
+}
+
 /* Make xrefs more universally visible */
 a.reference, a.reference:hover {
     border-bottom: none;
Signature · 1 line
2.51.0
#3 lore raw

v2 cover docs: contain overflow from long links

In reply to Rito Rhymes

Patch 1 allows long link text to wrap per character so unbroken links in the main document body do not force page-wide horizontal scroll overflow.

Patch 2 remains necessary for rendered reference links inside docutils tables, where the affected table case still needs an explicit selector to keep the table within the content column.

Some of these pages may also overflow for other reasons, but the examples listed under [2/2] specifically include tables containing long reference links that may still need a table-specific CSS rule to keep the table within the content column.

Examples of affected pages on docs.kernel.org this patch improves:

[1/2]
firmware-guide/acpi/non-d0-probe.html
firmware-guide/acpi/lpit.html
arch/arm/vlocks.html
arch/arm/keystone/overview.html
arch/arm/keystone/knav-qmss.html
arch/loongarch/introduction.html
arch/nios2/nios2.html
arch/x86/earlyprintk.html
arch/x86/orc-unwinder.html#etymology
arch/x86/tdx.html
arch/x86/sva.html
driver-api/xilinx/eemi.html

[2/2]
arch/openrisc/openrisc_port.html
power/apm-acpi.html
networking/devlink/stmmac.html
filesystems/ext2.html
networking/l2tp.html
process/embargoed-hardware-issues.html
arch/x86/boot.html
networking/devlink/devlink-info.html
admin-guide/sysctl/fs.html
userspace-api/ioctl/ioctl-number.html

Rito Rhymes (2):
docs: allow long links to wrap per character to prevent page overflow
docs: allow long table reference links to wrap and prevent overflow

 Documentation/sphinx-static/custom.css | 10 ++++++++++
 1 file changed, 10 insertions(+)
Signature · 1 line
2.51.0
#4 lore raw

PATCH v2 1/2 docs: allow long links to wrap per character to prevent page overflow

Some documentation pages contain long link text without natural break points, which can force page-wide horizontal scroll overflow on small screens.

Use overflow-wrap: anywhere for anchor text in the docs stylesheet so links can wrap per character as a fallback when normal word boundaries are unavailable.

Assisted-by Codex:GPT-5.4

---
v2: add Assisted-by attribution

 Documentation/sphinx-static/custom.css | 5 +++++
 1 file changed, 5 insertions(+)
Documentation/sphinx-static/custom.css +5 -0
index db24f4344..4ec617d40 100644
@@ -149,6 +149,11 @@ div.language-selection ul li:hover {
     background: #dddddd;
 }
 
+/* Let long link text wrap instead of forcing overflow. */
+a {
+    overflow-wrap: anywhere;
+}
+
 /* Make xrefs more universally visible */
 a.reference, a.reference:hover {
     border-bottom: none;
Signature · 1 line
2.51.0
#5 lore raw

PATCH v2 2/2 docs: allow long table reference links to wrap and prevent overflow

In reply to Rito Rhymes

Some documentation pages contain docutils tables with reference links that use long unbroken strings. Those strings can expand the table width beyond the content column and cause page-wide horizontal overflow.

Allow reference links in docutils tables in the main document body to wrap when needed so the table stays within the content column and does not break page layout.

Assisted-by Codex:GPT-5.4

---
v2: add Assisted-by attribution

 Documentation/sphinx-static/custom.css | 5 +++++
 1 file changed, 5 insertions(+)
Documentation/sphinx-static/custom.css +5 -0
index 4ec617d40..b41c54c71 100644
@@ -154,6 +154,11 @@ a {
     overflow-wrap: anywhere;
 }
 
+/* Let rendered reference links in tables wrap when needed. */
+div.body table.docutils a.reference {
+    overflow-wrap: anywhere;
+}
+
 /* Make xrefs more universally visible */
 a.reference, a.reference:hover {
     border-bottom: none;
Signature · 1 line
2.51.0
#6 lore raw

PATCH v3 1/2 docs: allow long links to wrap per character to prevent page overflow

In reply to Rito Rhymes

Some documentation pages contain long link text without natural break points, which can force page-wide horizontal scroll overflow on small screens.

Use overflow-wrap: anywhere for anchor text in the docs stylesheet so links can wrap per character as a fallback when normal word boundaries are unavailable.

Examples:
https://docs.kernel.org/6.15/firmware-guide/acpi/non-d0-probe.html
https://docs.kernel.org/6.15/arch/x86/earlyprintk.html

Assisted-by Codex:GPT-5.4

---
v3: add latest public versioned URL examples to the patchlog

 Documentation/sphinx-static/custom.css | 5 +++++
 1 file changed, 5 insertions(+)
Documentation/sphinx-static/custom.css +5 -0
index db24f4344..4ec617d40 100644
@@ -149,6 +149,11 @@ div.language-selection ul li:hover {
     background: #dddddd;
 }
 
+/* Let long link text wrap instead of forcing overflow. */
+a {
+    overflow-wrap: anywhere;
+}
+
 /* Make xrefs more universally visible */
 a.reference, a.reference:hover {
     border-bottom: none;
Signature · 1 line
2.51.0
#7 lore raw

PATCH v3 2/2 docs: allow long table reference links to wrap and prevent overflow

Some documentation pages contain docutils tables with reference links that use long unbroken strings. Those strings can expand the table width beyond the content column and cause page-wide horizontal overflow.

Allow reference links in docutils tables in the main document body to wrap when needed so the table stays within the content column and does not break page layout.

Examples:
https://docs.kernel.org/6.15/arch/openrisc/openrisc_port.html
https://docs.kernel.org/6.15/filesystems/ext2.html

Assisted-by Codex:GPT-5.4

---
v3: add latest public versioned URL examples to the patchlog

 Documentation/sphinx-static/custom.css | 5 +++++
 1 file changed, 5 insertions(+)
Documentation/sphinx-static/custom.css +5 -0
index 4ec617d40..b41c54c71 100644
@@ -154,6 +154,11 @@ a {
     overflow-wrap: anywhere;
 }
 
+/* Let rendered reference links in tables wrap when needed. */
+div.body table.docutils a.reference {
+    overflow-wrap: anywhere;
+}
+
 /* Make xrefs more universally visible */
 a.reference, a.reference:hover {
     border-bottom: none;
Signature · 1 line
2.51.0
reviewer Tested-by Acked-by on v3 2/2
#8 lore raw

Re: [PATCH v3 2/2] docs: allow long table reference links to wrap and prevent overflow

Quoted 9 lines · Rito Rhymes

Some documentation pages contain docutils tables with reference links that use long unbroken strings. Those strings can expand the table width beyond the content column and cause page-wide horizontal overflow.

Allow reference links in docutils tables in the main document body to wrap when needed so the table stays within the content column and does not break page layout.

Quoted 6 lines

Examples:
https://docs.kernel.org/6.15/arch/openrisc/openrisc_port.html
https://docs.kernel.org/6.15/filesystems/ext2.html

Assisted-by Codex:GPT-5.4

thanks.

Quoted 22 lines

---
v3: add latest public versioned URL examples to the patchlog

 Documentation/sphinx-static/custom.css | 5 +++++
 1 file changed, 5 insertions(+)
Documentation/sphinx-static/custom.css +5 -0
index 4ec617d40..b41c54c71 100644
@@ -154,6 +154,11 @@ a {
     overflow-wrap: anywhere;
 }
 
+/* Let rendered reference links in tables wrap when needed. */
+div.body table.docutils a.reference {
+    overflow-wrap: anywhere;
+}
+
 /* Make xrefs more universally visible */
 a.reference, a.reference:hover {
     border-bottom: none;
Signature · 1 line
~Randy
reviewer Tested-by Acked-by on v3 1/2
#9 lore raw

Re: [PATCH v3 1/2] docs: allow long links to wrap per character to prevent page overflow

In reply to Rito Rhymes
Quoted 8 lines · Rito Rhymes

Some documentation pages contain long link text without natural break points, which can force page-wide horizontal scroll overflow on small screens.

Use overflow-wrap: anywhere for anchor text in the docs stylesheet so links can wrap per character as a fallback when normal word boundaries are unavailable.

Quoted 6 lines

Examples:
https://docs.kernel.org/6.15/firmware-guide/acpi/non-d0-probe.html
https://docs.kernel.org/6.15/arch/x86/earlyprintk.html

Assisted-by Codex:GPT-5.4

thanks.

Quoted 22 lines

---
v3: add latest public versioned URL examples to the patchlog

 Documentation/sphinx-static/custom.css | 5 +++++
 1 file changed, 5 insertions(+)
Documentation/sphinx-static/custom.css +5 -0
index db24f4344..4ec617d40 100644
@@ -149,6 +149,11 @@ div.language-selection ul li:hover {
     background: #dddddd;
 }
 
+/* Let long link text wrap instead of forcing overflow. */
+a {
+    overflow-wrap: anywhere;
+}
+
 /* Make xrefs more universally visible */
 a.reference, a.reference:hover {
     border-bottom: none;
Signature · 1 line
~Randy
maintainer
#10 lore raw

Re: [PATCH v3 1/2] docs: allow long links to wrap per character to prevent page overflow

In reply to Rito Rhymes
Quoted 12 lines · Rito Rhymes

Some documentation pages contain long link text without natural break points, which can force page-wide horizontal scroll overflow on small screens.

Use overflow-wrap: anywhere for anchor text in the docs stylesheet so links can wrap per character as a fallback when normal word boundaries are unavailable.

Examples:
https://docs.kernel.org/6.15/firmware-guide/acpi/non-d0-probe.html
https://docs.kernel.org/6.15/arch/x86/earlyprintk.html

Quoted 7 lines
Assisted-by Codex:GPT-5.4

---
v3: add latest public versioned URL examples to the patchlog

 Documentation/sphinx-static/custom.css | 5 +++++
 1 file changed, 5 insertions(+)

With these two I at least see the problem - on Chrome, at least; Firefox does a better job of it. Again I'm not convinced this is optimal, but I've applied them as being better than what we have.

Thanks,

jon