aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2021-06-02 17:51:38 +0000
committerIngo Schwarze <schwarze@openbsd.org>2021-06-02 17:51:38 +0000
commitde34761a7b7b86c9539f9b86dbaf2bd789153ba1 (patch)
treebe095eb47a4b701e3006678b8fd9253221fcfbdb
parent0dce3131993c994af48b64e6895eb6bb24b7340f (diff)
downloadmandoc-de34761a7b7b86c9539f9b86dbaf2bd789153ba1.tar.gz
mandoc-de34761a7b7b86c9539f9b86dbaf2bd789153ba1.tar.zst
mandoc-de34761a7b7b86c9539f9b86dbaf2bd789153ba1.zip
In revision 1.157 of cgi.c, a meta viewport element was added to
the HTML output. Let `mandoc -Thtml' behave the same, making the generated HTML a bit more pleasant to view on a mobile device. Patch from anton@.
-rw-r--r--html.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/html.c b/html.c
index f81b251f..6ce204bb 100644
--- a/html.c
+++ b/html.c
@@ -1,4 +1,4 @@
-/* $Id: html.c,v 1.272 2021/05/16 18:11:20 schwarze Exp $ */
+/* $Id: html.c,v 1.273 2021/06/02 17:51:38 schwarze Exp $ */
/*
* Copyright (c) 2011-2015, 2017-2020 Ingo Schwarze <schwarze@openbsd.org>
* Copyright (c) 2008-2011, 2014 Kristaps Dzonsons <kristaps@bsd.lv>
@@ -196,6 +196,8 @@ print_gen_head(struct html *h)
struct tag *t;
print_otag(h, TAG_META, "?", "charset", "utf-8");
+ print_otag(h, TAG_META, "??", "name", "viewport",
+ "content", "width=device-width, initial-scale=1.0");
if (h->style != NULL) {
print_otag(h, TAG_LINK, "?h??", "rel", "stylesheet",
h->style, "type", "text/css", "media", "all");