diff options
author | Kristo <kristo.ilmari@gmail.com> | 2022-01-22 18:00:22 +0000 |
---|---|---|
committer | Ori Bernstein <ori@eigenstate.org> | 2022-01-22 18:00:22 +0000 |
commit | 8dc8e3a0198f9127c3d48aa2e079ac078aec73e3 (patch) | |
tree | 5fa5f50ba07521bf89152da0a85fd7fd0b510c2f /sys/src/cmd/mothra | |
parent | 33231f9222486b50e7cfe621fb41a4b7e32e47c1 (diff) |
mothra: fix rendering of <samp> tag
Mothra does not currently render text inside <samp> tags inline
similar to <code>, but instead treats them like <pre> which is actually
incorrect behavior. The following small patch should fixes issue.
Diffstat (limited to 'sys/src/cmd/mothra')
-rw-r--r-- | sys/src/cmd/mothra/rdhtml.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/sys/src/cmd/mothra/rdhtml.c b/sys/src/cmd/mothra/rdhtml.c index 1197b33a0..cf5d137a7 100644 --- a/sys/src/cmd/mothra/rdhtml.c +++ b/sys/src/cmd/mothra/rdhtml.c @@ -982,6 +982,7 @@ void plrdhtml(char *name, int fd, Www *dst, int killimgs){ g.state->size=NORMAL; break; case Tag_code: + case Tag_samp: g.state->font=CWIDTH; g.state->size=NORMAL; break; @@ -1113,7 +1114,6 @@ void plrdhtml(char *name, int fd, Www *dst, int killimgs){ case Tag_xmp: htmlerror(g.name, g.lineno, "<%s> deprecated", tag[g.tag].name); case Tag_pre: - case Tag_samp: g.state->indent=0; g.state->pre=1; g.state->font=CWIDTH; @@ -1203,7 +1203,6 @@ void plrdhtml(char *name, int fd, Www *dst, int killimgs){ case Tag_listing: case Tag_menu: case Tag_ol: - case Tag_samp: case Tag_title: case Tag_ul: case Tag_xmp: |