Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 0739c44

Browse files
committed
Suppress more online-only navigation in the printed HTML.
1 parent ecbfceb commit 0739c44

2 files changed

Lines changed: 15 additions & 9 deletions

File tree

Doc/html/style.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,5 +146,5 @@ div.note .label { margin-right: 0.5em;
146146
* Some specialization for printed output.
147147
*/
148148
@media print {
149-
#bottom-navigation-panel { display: none; }
149+
.online-navigation { display: none; }
150150
}

Doc/perl/l2hinit.perl

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ package main;
2626
$AUTO_NAVIGATION = 0;
2727

2828
$BODYTEXT = '';
29-
$CHILDLINE = "\n<p></p><hr />\n";
29+
$CHILDLINE = "\n<p><br /></p><hr class='online-navigation' />\n";
3030
$VERBOSITY = 0;
3131

3232
# default # of columns for the indexes
@@ -180,20 +180,23 @@ ()
180180
$s = ('<table align="center" width="100%" cellpadding="0" cellspacing="2">'
181181
. "\n<tr>"
182182
# left-hand side
183-
. "\n<td>$PREVIOUS</td>"
184-
. "\n<td>$UP</td>"
185-
. "\n<td>$NEXT</td>"
183+
. "\n<td class='online-navigation'>$PREVIOUS</td>"
184+
. "\n<td class='online-navigation'>$UP</td>"
185+
. "\n<td class='online-navigation'>$NEXT</td>"
186186
# title box
187187
. "\n<td align=\"center\" width=\"100%\">$t_title</td>"
188188
# right-hand side
189-
. "\n<td>$CONTENTS</td>"
190-
. "\n<td>$CUSTOM_BUTTONS</td>" # module index
191-
. "\n<td>$INDEX</td>"
189+
. "\n<td class='online-navigation'>$CONTENTS</td>"
190+
# module index
191+
. "\n<td class='online-navigation'>$CUSTOM_BUTTONS</td>"
192+
. "\n<td class='online-navigation'>$INDEX</td>"
192193
. "\n</tr></table>\n"
193194
# textual navigation
195+
. "<div class='online-navigation'>\n"
194196
. make_nav_sectref("Previous", "prev", $PREVIOUS_TITLE)
195197
. make_nav_sectref("Up", "parent", $UP_TITLE)
196198
. make_nav_sectref("Next", "next", $NEXT_TITLE)
199+
. "</div>\n"
197200
);
198201
# remove these; they are unnecessary and cause errors from validation
199202
$s =~ s/ NAME="tex2html\d+"\n */ /g;
@@ -205,6 +208,9 @@ sub add_child_links {
205208
$toc =~ s|\s*</[aA]>|</a>|g;
206209
$toc =~ s/ NAME=\"tex2html\d+\"\s*href=/ href=/gi;
207210
$toc =~ s|</UL>(\s*<BR( /)?>)?|</ul>|gi;
211+
if ($toc =~ / NAME=["']CHILD_LINKS["']/) {
212+
return "<div class='online-navigation'>\n$toc</div>\n";
213+
}
208214
return $toc;
209215
}
210216

@@ -233,7 +239,7 @@ ()
233239
}
234240

235241
sub bot_navigation_panel() {
236-
return "\n<div id='bottom-navigation-panel'>\n"
242+
return "\n<div class='online-navigation'>\n"
237243
. "<p></p><hr />\n"
238244
. make_nav_panel()
239245
. "</div>\n"

0 commit comments

Comments
 (0)