From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/32843 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Mats Holmberg Newsgroups: gmane.text.pandoc Subject: Re: Selecting CSS style for paragraph Date: Sat, 17 Jun 2023 16:16:13 -0700 (PDT) Message-ID: <08ff7f6f-6f3c-48da-b52e-ce0a219841d6n@googlegroups.com> References: <0102580d-3f9a-407d-b089-54a8b51ab6f3n@googlegroups.com> Reply-To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_Part_6064_1560366590.1687043773050" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="9582"; mail-complaints-to="usenet@ciao.gmane.io" To: pandoc-discuss Original-X-From: pandoc-discuss+bncBCPMBIUJ4EBBBPX5XCSAMGQENVIVZHA-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Sun Jun 18 01:16:18 2023 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane-mx.org Original-Received: from mail-ot1-f55.google.com ([209.85.210.55]) by ciao.gmane.io with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1qAf9W-0002Jh-7Y for gtp-pandoc-discuss@m.gmane-mx.org; Sun, 18 Jun 2023 01:16:18 +0200 Original-Received: by mail-ot1-f55.google.com with SMTP id 46e09a7af769-6b2adf6b550sf1518821a34.1 for ; Sat, 17 Jun 2023 16:16:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20221208; t=1687043777; x=1689635777; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:x-original-sender :mime-version:subject:references:in-reply-to:message-id:to:from:date :sender:from:to:cc:subject:date:message-id:reply-to; bh=g92woXdQDBkntciEn30qKELAAkVNoGG4p6OYeknJwFw=; b=EdLju+6tmVM7i9PFBPhU9OumrqFyBfcSHPxFcK2PTtoYxe680sxyPVn7MdW7Qk/7qU aqYjeHANArtcU6tzWq3MybLLCu20xwg0mvnLpyLCIiINhcizQqpRoaaZl6CGAUl1Mjnc DhKZ9yZjCOJiqfgtdQ+3PkadUIgvOftpMXoix6CipDfc+hUjGHHmkHBEVehjplZRLduo G5ZMrzOTMYnWnkGpMu0Z/PhxbEByYne8dfbJe1AfHiGsr5EZWc8pK4C/5FkK4KyWrTOw FH9mnN813CA9jw/uWXJtlBu1VKD2mCZQJMZrK1J4/wTHgpaB5kO+cu4gwI3pgXRXcrb3 UmFg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1687043777; x=1689635777; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:x-original-sender :mime-version:subject:references:in-reply-to:message-id:to:from:date :from:to:cc:subject:date:message-id:reply-to; bh=g92woXdQDBkntciEn30qKELAAkVNoGG4p6OYeknJwFw=; b=nQRybwY6uLC8ELqsIg9od/EJ9lYfLh8mHaaPz4OEkymVRTAkZ+8kZBTjEz5kQrANhR WTajYpIrgx2UmtxAdGFj3Wol5tDCUBjdIhU/67miu7PkpVgEihmuM0YcYbQNgBO0R289 tO0zE32bM/SVtcB4bXi5POlLIVRFj4tBcQfSnoYQnmBlmu3Lam+z9BIhpzcssgyldwBT y6NSFKMqREX4fbhED0iDa9fEDT2Qs58J//8NJ5oTwTdh2ShcIuE9XFlp35tldU47DAUf Iox6RaYONIr2TCivuEua447Cf2GUHIA1mkTtRIYgqmRWu+YfYRuO3FlpDJ09bXKMEdMr Zn/Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687043777; x=1689635777; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence:reply-to :x-original-sender:mime-version:subject:references:in-reply-to :message-id:to:from:date:x-beenthere:x-gm-message-state:sender:from :to:cc:subject:date:message-id:reply-to; bh=g92woXdQDBkntciEn30qKELAAkVNoGG4p6OYeknJwFw=; b=g9WrZK4laqEAB3m2swleqQWRfzJj7C/3w0PxsHuuekNKhUCnAc5+XkyHKdZX2J0LVm Fb/tiN8r8svGjSfjgpATnAW1Hxj63CcU/1ZxXgyJFuZzepLRTl5DPWJH1SJw+fA94Xbz 5YjRJQqr9lGR55z2nSj/wZEDhl2WBzfTsjgBi2ePbVK1qsmqp9qZkSqx9x2qHrzFjhzD v3s4wykJXibYb7amcyCZI0PzsC8yqTez9X1snRbZNF2jSV7GoZxP7J0J4BMsJV6WSNih MgR1dXHCPyZh2plQYb0smzh58HShhRZ2TiAEQD9+VqvAywHXmq Original-Sender: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org X-Gm-Message-State: AC+VfDw7bjVDacKHJcfQ0lemKxu+tGCxV7D8O4u00pWdhLL3FGC5VFxT zSQeTikNMnc6EzW/H6yKUqQ= X-Google-Smtp-Source: ACHHUZ5qVGsjT0JP+ExcJkwCcSdUmOLLfiapRNUSHTiBqotX+qKzo4ARertMi+tynhs+g7GYd5XNKQ== X-Received: by 2002:a05:6870:4c2:b0:19f:5626:a98e with SMTP id u2-20020a05687004c200b0019f5626a98emr1989594oam.6.1687043776996; Sat, 17 Jun 2023 16:16:16 -0700 (PDT) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 2002:a05:6870:4b45:b0:19f:3c91:db38 with SMTP id ls5-20020a0568704b4500b0019f3c91db38ls1418428oab.0.-pod-prod-08-us; Sat, 17 Jun 2023 16:16:13 -0700 (PDT) X-Received: by 2002:a05:6870:5aab:b0:1a3:213f:5b9 with SMTP id dt43-20020a0568705aab00b001a3213f05b9mr845996oab.10.1687043773798; Sat, 17 Jun 2023 16:16:13 -0700 (PDT) In-Reply-To: X-Original-Sender: elmatzo-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:32843 Archived-At: ------=_Part_6064_1560366590.1687043773050 Content-Type: multipart/alternative; boundary="----=_Part_6065_406045076.1687043773050" ------=_Part_6065_406045076.1687043773050 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Oh, I see. Well, in that case I guess I'll just have to stick with html=20 blocks for the parts of the text that that has to be separately styled,=20 it's not all that often. Or look for another tool. But I really like=20 pandoc, so I think I'll stick around. Would be interesting to know why the= =20 design choice was made to not allow attributes for all elements, though.=20 Seems to me that it would be a very useful feature. Thanks a lot for the information, now I can finally stop trying to figure= =20 this out. Kind regards, Mats On Sunday, June 18, 2023 at 12:04:49=E2=80=AFAM UTC+2 Bastien DUMONT wrote: > Pandoc doesn't have classes and attributes for all elements. To set=20 > attributes and classes on a paragraph, you must wrap it in a div as you= =20 > discovered. Then, either you change your CSS file to apply the required= =20 > formatting to all paragraphs inside a div of a given class, or you can=20 > post-process the HTML file to pass the classes and the attributes on the= =20 > children paragraphs. > > Le Saturday 17 June 2023 =C3=A0 01:47:12PM, Mats Holmberg a =C3=A9crit : > > Hi all, > >=20 > > I am trying to learn how to use pandoc and markdown for book writing=20 > (creating > > epubs and html books). Overall it works splendidly, but I have a proble= m=20 > that I > > don't know how > > to solve: hinting to pandoc which CSS style to use for my paragraph. > > . > > I know that i can simply wrap my text in a html block e.g.

> "no-indent">Text

. > > But then I can't use markdown in the html block. Some other markdown=20 > parsers I > > have > > tested (MarkDiv, for example) have a syntax that goes something like th= is > > instead: > > {.no-indent}Text, which seems to work perfectly. I have tried the synta= x=20 > :::: > > {.no-indent} in pandoc, but that generates a
around the whole=20 > thing which > > is not what i want. > >=20 > > I have tried to go through all the extensions that are available in=20 > pandoc, but > > so far haven't found anything that works. > >=20 > > I guess this might be kind of a noob question, but I have really tried= =20 > to find > > a solution > > and failed. Is this a real problem, or am I overlooking something=20 > simple? Some=20 > > combination of pandoc extensions or something like that? Any help will = be > > immensely=20 > > appreciated! > >=20 > > Kind regards, > > Mats > >=20 > > -- > > You received this message because you are subscribed to the Google Grou= ps > > "pandoc-discuss" group. > > To unsubscribe from this group and stop receiving emails from it, send= =20 > an email > > to [1]pandoc-discus...-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > > To view this discussion on the web visit [2] > https://groups.google.com/d/msgid/ > > pandoc-discuss/0102580d-3f9a-407d-b089-54a8b51ab6f3n%40googlegroups.com= . > >=20 > > References: > >=20 > > [1] mailto:pandoc-discus...-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org > > [2]=20 > https://groups.google.com/d/msgid/pandoc-discuss/0102580d-3f9a-407d-b089-= 54a8b51ab6f3n%40googlegroups.com?utm_medium=3Demail&utm_source=3Dfooter > > --=20 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 e= mail 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/08ff7f6f-6f3c-48da-b52e-ce0a219841d6n%40googlegroups.com. ------=_Part_6065_406045076.1687043773050 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Oh, I see. Well, in that case I guess I'll just have to stick with html blo= cks for the parts of the text that that has to be separately styled, it's n= ot all that often. Or look for another tool. But I really like pandoc, so I= think I'll stick around. Would be interesting to know why the design choic= e was made to not allow attributes for all elements, though. Seems to me th= at it would be a very useful feature.

Thanks a lo= t for the information, now I can finally stop trying to figure this out.

Kind regards,
Mats
On Sunday, June 18,= 2023 at 12:04:49=E2=80=AFAM UTC+2 Bastien DUMONT wrote:
Pandoc doesn't have classes= and attributes for all elements. To set attributes and classes on a paragr= aph, you must wrap it in a div as you discovered. Then, either you change y= our CSS file to apply the required formatting to all paragraphs inside a di= v of a given class, or you can post-process the HTML file to pass the class= es and the attributes on the children paragraphs.

Le Saturday 17 June 2023 =C3=A0 01:47:12PM, Mats Holmberg a =C3=A9crit = :
> Hi all,
>=20
> I am trying to learn how to use pandoc and markdown for book writi= ng (creating
> epubs and html books). Overall it works splendidly, but I have a p= roblem that I
> don't know how
> to solve: hinting to pandoc which CSS style to use for my paragrap= h.
> .
> I know that i can simply wrap my text in a html block e.g.=C2=A0 &= lt;p class=3D
> "no-indent">Text</p>.
> But then I can't use markdown in the html block. Some other ma= rkdown parsers I
> have
> tested (MarkDiv, for example) have a syntax that goes something li= ke this
> instead:
> {.no-indent}Text, which seems to work perfectly. I have tried the = syntax ::::
> {.no-indent} in pandoc, but that generates a <div> around th= e whole thing which
> is not what i want.
>=20
> I have tried to go through all the extensions that are available i= n pandoc, but
> so far haven't found anything that works.
>=20
> I guess this might be kind of a noob question, but I have really t= ried to find
> a solution
> and failed. Is this a real problem, or am I overlooking something = simple? Some=C2=A0
> combination of pandoc extensions or something like that? Any help = will be
> immensely=C2=A0
> appreciated!
>=20
> Kind regards,
> Mats
>=20
> --
> 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 [1]pandoc-discus...@= googlegroups.com.
> To view this discussion on the web visit [2]https://groups.google.com/d/msgid/
> pandoc-discuss/0102580d-3f9a-407d-b089-54a8b51ab6f3n%40googlegroups.com.
>=20
> References:
>=20
> [1] mailto:pandoc-discu= s...-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
> [2] https://groups= .google.com/d/msgid/pandoc-discuss/0102580d-3f9a-407d-b089-54a8b51ab6f3n%40= googlegroups.com?utm_medium=3Demail&utm_source=3Dfooter

--
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/08ff7f6f-6f3c-48da-b52e-ce0a219841d6n%40googlegroups.= com.
------=_Part_6065_406045076.1687043773050-- ------=_Part_6064_1560366590.1687043773050--