9front - general discussion about 9front
 help / color / mirror / Atom feed
From: ori@eigenstate.org
To: 9front@9front.org
Subject: Re: [9front] mothra: fix rendering of <samp> tag
Date: Wed, 26 Jan 2022 12:51:06 -0500	[thread overview]
Message-ID: <E2730A98E265C3AA10CDC24107A71B24@eigenstate.org> (raw)
In-Reply-To: <CAAJ3RaPsVi9GciB1ofW_dkV5y1ax6uMWi-vgU8XpH3Uyj+C=VQ@mail.gmail.com>

Do you have an example site or html snippet that
I can compare against?

Quoth Kristo <kristo.ilmari@gmail.com>:
> Hi all,
> 
> 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 fix this issue.
> 
> diff 9d43029ff984435111eff658308a44b4f3eee1cc uncommitted
> --- a/sys/src/cmd/mothra/rdhtml.c
> +++ b/sys/src/cmd/mothra/rdhtml.c
> @@ -982,6 +982,7 @@
>  			g.state->size=NORMAL;
>  			break;
>  		case Tag_code:
> +		case Tag_samp:
>  			g.state->font=CWIDTH;
>  			g.state->size=NORMAL;
>  			break;
> @@ -1113,7 +1114,6 @@
>  		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 @@
>  		case Tag_listing:
>  		case Tag_menu:
>  		case Tag_ol:
> -		case Tag_samp:
>  		case Tag_title:
>  		case Tag_ul:
>  		case Tag_xmp:
> 


  reply	other threads:[~2022-01-26 17:59 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-01-22 17:30 Kristo
2022-01-26 17:51 ` ori [this message]
2022-01-26 18:32   ` Kristo
2022-01-27 16:34     ` ori

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=E2730A98E265C3AA10CDC24107A71B24@eigenstate.org \
    --to=ori@eigenstate.org \
    --cc=9front@9front.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).