From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/28232 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Tim Newsgroups: gmane.text.pandoc Subject: Re: changing format of --numbered-sections Date: Mon, 26 Apr 2021 23:33:30 -0700 (PDT) Message-ID: References: <676ca0f1-1c1f-49c8-afec-c6453c4d298en@googlegroups.com> <87y2d48cox.fsf@zeitkraut.de> Reply-To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_Part_1460_897180588.1619505210229" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="17721"; mail-complaints-to="usenet@ciao.gmane.io" To: pandoc-discuss Original-X-From: pandoc-discuss+bncBCI5FX76RINBBO7AT2CAMGQE3YNNDUA-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Tue Apr 27 08:33:34 2021 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane-mx.org Original-Received: from mail-ot1-f59.google.com ([209.85.210.59]) by ciao.gmane.io with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1lbHHp-0004Od-NJ for gtp-pandoc-discuss@m.gmane-mx.org; Tue, 27 Apr 2021 08:33:33 +0200 Original-Received: by mail-ot1-f59.google.com with SMTP id w6-20020a0568300786b0290297fb946e1asf17593756ots.4 for ; Mon, 26 Apr 2021 23:33:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20161025; h=sender:date:from:to:message-id:in-reply-to:references:subject :mime-version:x-original-sender:reply-to:precedence:mailing-list :list-id:list-post:list-help:list-archive:list-subscribe :list-unsubscribe; bh=ns/BqSNkIXO0+sFCuoqIBZ2IqbrHsRYpGZWrT+iGWrY=; b=W2CmBRgybkmueVmqNcRFefBXRlvBgWpOoCV+eqS9lbAHhpFNZ5qAVUV/btViiPNCs4 uxclRYmGF08mLDvwgBlhHvZrTm74LYdP7UBFyeY0+T/shyoBzhM9mBXY12UvdQU9vfXO oQNGHMl96TwYbcsx5CpN0K7ROJu0gkDXhXJx2J5sXS9ywdVH7HE/iCBAhsKBuMnN4sHr 3Qk9xbulJZCEoRyD7N7gm0x9oosnXTlz/zK8jrOl0A2zI6Fx0/Y59v9CEJcjvMnONHOO a/bunAF1bEujRlvwku/R6M3tPUGOhd5hqBEKDfgv+2ITMDGJzIG/bycIvjHwRfEZ8O/j tkdA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:message-id:in-reply-to:references:subject:mime-version :x-original-sender:reply-to:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-subscribe:list-unsubscribe; bh=ns/BqSNkIXO0+sFCuoqIBZ2IqbrHsRYpGZWrT+iGWrY=; b=Haii+7m2w9OpvV9UXzXpLSdgUMGu+S9HhnzVe9TWzCKujey3Q56F/jgTuL5kFgPVNg QA6oq3SmvSs+CXOu5veWFPps5877UHvMaY17tAeY5GY3hbQj3ZsXpJpGgS0KH9gSXoqK xfUXKkx23wUD17W5X08iVJIM9EfD19vQP5ByroXDXMB3Un21NOyG1ztomv2q9R02BC21 bIphjDHrFF+3Auh61UqYOwtmekVIOKwkz/fDPXD4oinQQeVeTqqGNTOtVjjXkLTdcUzB w/2/rtfZUInAxC9x8cEOmNVYJ5jaYsxW3l08X0X9nam6GvvcsdjZHSIuOzGvOfv0jyxK c42g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=sender:x-gm-message-state:date:from:to:message-id:in-reply-to :references:subject:mime-version:x-original-sender:reply-to :precedence:mailing-list:list-id:x-spam-checked-in-group:list-post :list-help:list-archive:list-subscribe:list-unsubscribe; bh=ns/BqSNkIXO0+sFCuoqIBZ2IqbrHsRYpGZWrT+iGWrY=; b=gQXd1Bhdba9j9jtYogGmrBEPwe9XsGwFELyuqV6c48wlDiQ902TwBeuR7Nzpn8kZwB AWlw83AqAV3MTHmty4GxmGG1nHgJHnv4aFtZSPe5KqFasZr8rixujwRzOJQZL3T7sPke wU4Onf0hn0EOnxipshbppKVNectzQQZud/qwXWIcTPmmIkGaunZFIJ4vWTti1Lnw9Pla KfGVGBviBf8dYqXp134G1Xd0nMoiTxHK6q9wke41rhe8I8O/q8EkNMY0aMfr5CDJCbPh G3jkWf/5yxGiVdJkKFRpLsn5/nf4vOL9rW3BeJTkAY6kzFg5qsXJkcXUNyTuPtMSmsrO kmdw== Original-Sender: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org X-Gm-Message-State: AOAM5338TRyQrL54/6/oJx4t/Sji/e8YCwuQnlXL9xZrlAD1IRn4V8tC UIBg2VoLfJquK5g00Q5pVQU= X-Google-Smtp-Source: ABdhPJwwZQtlJq3mfmsN3zaOVZGhhbrgj/JTE409V7cPqMhCNkIDxZ8Ej/q0Ry5kzeTsWBVLI2ZAmQ== X-Received: by 2002:a54:4696:: with SMTP id k22mr2156972oic.168.1619505212715; Mon, 26 Apr 2021 23:33:32 -0700 (PDT) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 2002:a05:6830:3488:: with SMTP id c8ls1564868otu.10.gmail; Mon, 26 Apr 2021 23:33:31 -0700 (PDT) X-Received: by 2002:a05:6830:1e17:: with SMTP id s23mr4052511otr.126.1619505211105; Mon, 26 Apr 2021 23:33:31 -0700 (PDT) In-Reply-To: <87y2d48cox.fsf-9EawChwDxG8hFhg+JK9F0w@public.gmane.org> X-Original-Sender: tim.at.ast-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org Precedence: list Mailing-list: list pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org; contact pandoc-discuss+owners-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org List-ID: X-Google-Group-Id: 1007024079513 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , Xref: news.gmane.io gmane.text.pandoc:28232 Archived-At: ------=_Part_1460_897180588.1619505210229 Content-Type: multipart/alternative; boundary="----=_Part_1461_1706079858.1619505210229" ------=_Part_1461_1706079858.1619505210229 Content-Type: text/plain; charset="UTF-8" I think this almost does the trick, but the colon is appearing at the end of the heading: 1 FirstHeading. whereas I wanted it just after the number 1. Is there a way to change it ? On Tuesday, 27 April 2021 at 16:27:18 UTC+10 Albert Krewinkel wrote: > > Tim writes: > > > I am converting markdown to html using pandoc with an associated simple > CSS. > > > > Currently, the numbered headings appear as: > > > > 1 FirstHeading > > 1.1.. > > > > 2 SecondHeading > > > > My aim: I would like to modify the format of the headings very slightly > so > > that there is a period after even the H1 headings: > > 1. FirstHeading. > > > > I am *guessing* from looking at the html output that pandoc hardcodes the > > html output for the numbered sections. Am I right therefore in thinking > > that I cannot modify my CSS to achieve my aim. > > > > What then is the easiest way to achieve my aim? > > If this is just for HTML, then you could use CSS to add the period. > > Putting the following anywhere in your input Markdown should do the > trick: > > ```{=html} > > ``` > > If you also need to target different output, then I'd suggest using a > pandoc Lua filter. Put the following in a file `heading-periods.lua` > and run with `pandoc --lua-filter heading-periods.lua` > > ``` lua > function Header (h) > h.content = h.content:insert(pandoc.Str '.') > return h > end > ``` > > HTH, > Albert > > > -- > Albert Krewinkel > GPG: 8eed e3e2 e8c5 6f18 81fe e836 388d c0b2 1f63 1124 > -- You received this message because you are subscribed to the Google Groups "pandoc-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/aaadb65c-3cca-497f-94b7-059013c62811n%40googlegroups.com. ------=_Part_1461_1706079858.1619505210229 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable I think this almost does the trick, but the colon is appearing at the end o= f the heading:

1 FirstHeading.

whereas I wanted it just after= the number 1.

Is there a way to change it ?

--
You received this message because you are subscribed to the Google Groups &= quot;pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an e= mail to
pand= oc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To view this discussion on the web visit https://groups.google.com/d= /msgid/pandoc-discuss/aaadb65c-3cca-497f-94b7-059013c62811n%40googlegroups.= com.
------=_Part_1461_1706079858.1619505210229-- ------=_Part_1460_897180588.1619505210229--