aboutsummaryrefslogtreecommitdiff
path: root/scripts/gen_help_html.lua
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/gen_help_html.lua')
-rw-r--r--scripts/gen_help_html.lua9
1 files changed, 7 insertions, 2 deletions
diff --git a/scripts/gen_help_html.lua b/scripts/gen_help_html.lua
index d65f3aace2..7432f5ecc4 100644
--- a/scripts/gen_help_html.lua
+++ b/scripts/gen_help_html.lua
@@ -1093,14 +1093,19 @@ local function gen_css(fname)
padding-bottom: 10px;
/* Tabs are used for alignment in old docs, so we must match Vim's 8-char expectation. */
tab-size: 8;
- white-space: normal;
+ white-space: pre-wrap;
font-size: 16px;
font-family: ui-monospace,SFMono-Regular,SF Mono,Menlo,Consolas,Liberation Mono,monospace;
word-wrap: break-word;
}
- .old-help-para pre {
+ .old-help-para pre, .old-help-para pre:hover {
/* Text following <pre> is already visually separated by the linebreak. */
margin-bottom: 0;
+ /* Long lines that exceed the textwidth should not be wrapped (no "pre-wrap").
+ Since text may overflow horizontally, we make the contents to be scrollable
+ (only if necessary) to prevent overlapping with the navigation bar at the right. */
+ white-space: pre;
+ overflow-x: auto;
}
/* TODO: should this rule be deleted? help tags are rendered as <code> or <span>, not <a> */