|
2026-10-22
| ||
| 17:19 | • Ticket [7f6005a867] Magic <meta> viewport tag in generated HTML for mobile... artifact: 30e71c12ca user: serhiy.storchaka | |
|
2026-10-21
| ||
| 08:37 | • Closed ticket [7f6005a867]. artifact: 94cb1fcd81 user: serhiy.storchaka | |
| 08:20 | Fix [7f6005a867]: Magic <meta> viewport tag in generated HTML for mobile browsers check-in: f5ead41df2 user: serhiy.storchaka tags: core-8-6-branch | |
| 08:20 | Fix [7f6005a867]: Magic <meta> viewport tag in generated HTML for mobile browsers check-in: 432dc52d5b user: serhiy.storchaka tags: core-9-0-branch | |
| 08:19 | Fix [7f6005a867]: Magic <meta> viewport tag in generated HTML for mobile browsers check-in: 785fa0c704 user: serhiy.storchaka tags: trunk, main | |
| 07:59 | • Ticket [7f6005a867] Magic <meta> viewport tag in generated HTML for mobile... artifact: c8046f6b96 user: oehhar | |
|
2026-10-20
| ||
| 21:48 | • Ticket [7f6005a867]: 3 changes artifact: 8005d48571 user: serhiy.storchaka | |
| 21:48 | • Ticket [1c722347fe] Tool generate wrong links for targets containing spaces/newl... artifact: bc4d085dd0 user: serhiy.storchaka | |
| 21:45 | Fix [7f6005a867]: add a viewport meta tag to the generated HTML pages, so they render properly on mo... closed check-in: 66f0f3eaa0 user: serhiy.storchaka tags: man2html-meta-viewport | |
| 21:08 | • Ticket [7f6005a867] Magic <meta> viewport tag in generated HTML for mobile... artifact: e06ecfa006 user: anonymous | |
| 12:57 | • Ticket [1c722347fe] Tool generate wrong links for targets containing spaces/newl... artifact: 1bcf5e6b06 user: serhiy.storchaka | |
|
2021-06-18
| ||
| 18:20 | • New ticket [7f6005a867] Magic <meta> viewport tag in generated HTML for mo... artifact: 7b25b41a16 user: anonymous | |
Magic <meta> viewport tag in generated HTML for mobile browsers
Closed / Fixed7f6005a867a432cc5a83fff7b7866fabd5f677ebCreated 5 years agoUpdated 41 days ago
Descriptionplain2021-06-18 18:20:45
Currently, the HTML-format reference pages (as available from
https://www.tcl.tk/man/) tend to look a bit odd on mobile browsers (Android,
iOS). The exact misbehavior differs from device to device and browser to
browser, but tends to involve rendering certain elements with extremely small
font sizes. This occurs because mobile browsers pretend, by default, that their
viewports are much larger than they really are, unless the page includes a
special <meta> tag to tell them otherwise. The following adds such a tag to the
generated reference pages, and makes them render more nicely, at least on my
Android devices:
Index: tools/tcltk-man2html-utils.tcl
==================================================================
--- tools/tcltk-man2html-utils.tcl
+++ tools/tcltk-man2html-utils.tcl
@@ -78,11 +78,11 @@
set level ""
if {[lindex $args end] eq "../[indexfile]"} {
# XXX hack - assume same level for CSS file
set level "../"
}
- set out "<!DOCTYPE html>\n<html lang=\"en\">\n<head><meta charset=\"utf-8\"><title>$title</title>\n[CSS $level]</head>\n"
+ set out "<!DOCTYPE html>\n<html lang=\"en\">\n<head><meta charset=\"utf-8\"><meta name=\"viewport\" content=\"width=device-width, initial-scale=1\"><title>$title</title>\n[CSS $level]</head>\n"
foreach {uptitle url} $args {
set header "<a href=\"$url\">$uptitle</a> <small>></small> $header"
}
append out "<body><h2>$header</h2>"
global manual
Referenced by6
f5ead41df2Fix [7f6005a867]: Magic <meta> viewport tag in generated HTML for mobile browsers check-in2026-10-21 08:20:34432dc52d5bFix [7f6005a867]: Magic <meta> viewport tag in generated HTML for mobile browsers check-in2026-10-21 08:20:03785fa0c704Fix [7f6005a867]: Magic <meta> viewport tag in generated HTML for mobile browsers check-in2026-10-21 08:19:47bc4d085dd0Ticket [1c722347fe] Tool generate wrong links for targets containing spaces/newlines status still Open with 3 other changes ticket2026-10-20 21:48:5666f0f3eaa0Fix [7f6005a867]: add a viewport meta tag to the generated HTML pages, so they render properly on mobile browsers. check-in2026-10-20 21:45:381bcf5e6b06Ticket [1c722347fe] Tool generate wrong links for targets containing spaces/newlines status still Open with 4 other changes ticket2026-10-20 12:57:54
anonymous (claiming to be Thomas [TWu])plain2026-10-20 21:08:28
I request this change too, rerouted by my ticket https://core.tcl-lang.org/tcl/info/1c722347fe Thanks for include it in the next release (9.1.0).
serhiy.storchakawiki2026-10-20 21:48:56
Proposed in branch [man2html-meta-viewport]: the patch from this ticket, which adds <meta name="viewport" content="width=device-width, initial-scale=1"> to the head of every generated page (checked on the Tcl and Tk HTML: all 471 pages have it).
oehharwiki2026-10-21 07:59:02
Serhiy, just merge, thanks, Harald
serhiy.storchakawiki2026-10-21 08:37:31
Merged to [trunk], [core-9-0-branch] and [core-8-6-branch] (in 8.6, which still generates HTML 4.01, as <META name="viewport" ...> after <HEAD>).
serhiy.storchaka Ticket [7f6005a867]: 3 changes
[History diff]2026-10-22 17:19:28
Log in (anonymous is fine) to add a comment.