From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-0.7 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, HTML_MESSAGE,MAILING_LIST_MULTI,T_SCC_BODY_TEXT_LINE,URIBL_SBL_A autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 29135 invoked from network); 13 Jun 2023 21:12:28 -0000 Received: from zapf.ntg.nl (5.39.185.232) by inbox.vuxu.org with ESMTPUTF8; 13 Jun 2023 21:12:28 -0000 Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id 815E57232; Tue, 13 Jun 2023 23:12:02 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at zapf.ntg.nl Received: from zapf.ntg.nl ([127.0.0.1]) by localhost (zapf.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 7N6oQKb7omQL; Tue, 13 Jun 2023 23:12:00 +0200 (CEST) Received: from zapf.ntg.nl (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id 786A97242; Tue, 13 Jun 2023 23:12:00 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id 6B4107242 for ; Tue, 13 Jun 2023 23:11:59 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at zapf.ntg.nl Received: from zapf.ntg.nl ([127.0.0.1]) by localhost (zapf.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 5J2pbVT2ViU0 for ; Tue, 13 Jun 2023 23:11:55 +0200 (CEST) Received-SPF: Pass (mailfrom) identity=mailfrom; client-ip=209.85.160.179; helo=mail-qt1-f179.google.com; envelope-from=thangalin@gmail.com; receiver= Received: from mail-qt1-f179.google.com (mail-qt1-f179.google.com [209.85.160.179]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by zapf.ntg.nl (Postfix) with ESMTPS id B3CC47232 for ; Tue, 13 Jun 2023 23:11:55 +0200 (CEST) Received: by mail-qt1-f179.google.com with SMTP id d75a77b69052e-3f9de2605b2so8930421cf.1 for ; Tue, 13 Jun 2023 14:11:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1686690714; x=1689282714; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :from:to:cc:subject:date:message-id:reply-to; bh=VSrOQkmrhFZrAWZyYEYlDY4uhhIqicR6w6aqlOnYoLk=; b=J58cH6F4zgj3UuxaB4mBluYlkrrnuJ7rWk0Fw28es0rv4UDTSm3JTQEZJqudGju3PS OfvlpbAA8m7mDb9TLBXFy80etuM3FKSOpa5SBiMka3h3TfBQ5aNZPJTQSPmRzf7XWYIq trsc3OOPTEAR0wQP9kzCl2A/2TuDv0n4lahOTQft6B3+Wg1ieYGWH53WbPHsPTsLgHiI 6dGn6r+XSPRtHuXfiSgoVfFvgV9syCGIybYOrmuWooKwQSIo43bzCf8NO2rAuBEpG3OL OSRsMfkSpoZuBtZXc2o/dxVDoWOMPpXxz3O9z948FJoCbhzT7sIFUfkuzUTiKohqzJvj 0oRA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1686690714; x=1689282714; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=VSrOQkmrhFZrAWZyYEYlDY4uhhIqicR6w6aqlOnYoLk=; b=DTKAa3/VYkHFDru7FBtzGAoKE3wOfINOPcmOthluvf7PpTwtB1LOa+jTBVM7uYiiQs NYaO8q9mXvB9ZFTYq9xhpBsobwww1DTle7o4C0F1LDMKGc1fhcubEVNNBu/ul2PT5Zkm 8uhdBzKOH4Doxlbzzx3dyPkEDiG5DJljV99MXZJbtdcwfL9dmCKZ32E1NPCKCEmGNUO/ H7SDSakiF7Wx0UCxp8HKyaVNGb2f2lAIXm9KGw8EEYBkeXscQ4eywkoraNuGM1AJ6nYo aS05d66aSzk30OiinJ5EFlQomqN1hGcO5+0obc5E3HP4ftZzBK/v/Rq2azN6UFZ4b0MN +RRA== X-Gm-Message-State: AC+VfDxjFk88ghzfCoUJZrLllywgm3Yku0nYO35wb/BHhZLOlzUI0pvD qrdjFxCYa68wOdFGvRq62ciz7/307QQOG/8etBXUMwsVh8k= X-Google-Smtp-Source: ACHHUZ7nyGdqDBHv7WdbxhV8fqUNDBPN6ur50yqmhhGD0xwT5yIcHnwkoDliEd0Qsz9xgZ0mbCaNzTWBSSkukXvEq24= X-Received: by 2002:a05:622a:134a:b0:3f9:b870:ba13 with SMTP id w10-20020a05622a134a00b003f9b870ba13mr16940930qtk.24.1686690714498; Tue, 13 Jun 2023 14:11:54 -0700 (PDT) MIME-Version: 1.0 References: <2B49A49C-A649-48F5-8789-5F057EC30E15@gmail.com> In-Reply-To: Date: Tue, 13 Jun 2023 14:11:43 -0700 Message-ID: To: mailing list for ConTeXt users Subject: Re: [NTG-context] Protect the lettrine X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.38 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Thangalin via ntg-context Reply-To: mailing list for ConTeXt users Cc: Thangalin Content-Type: multipart/mixed; boundary="===============8152464067261536106==" Errors-To: ntg-context-bounces@ntg.nl Sender: "ntg-context" --===============8152464067261536106== Content-Type: multipart/alternative; boundary="000000000000e23eae05fe09484e" --000000000000e23eae05fe09484e Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Here's the output I'm looking to achieve: https://i.stack.imgur.com/XeZQS.png Note how the second line honours the lettrine's width and padding, in the same way that the second line of the first paragraph in Knuth's quote respects the width and padding. On Tue, Jun 13, 2023 at 2:01=E2=80=AFPM Thangalin wro= te: > Thanks Otared, > > Unfortunately, that's adding content between \starttext and \stoptext, > which isn't tenable in my situation. The user is writing in Markdown, whi= ch > is automatically converted to XHTML then passed to ConTeXt, and so the > setups need to account for this scenario without modifying the source > document. > > Cheers! > > On Tue, Jun 13, 2023 at 1:30=E2=80=AFAM Otared Kavian via ntg-context < > ntg-context@ntg.nl> wrote: > >> Hi, >> >> Adding \hfill\break to the short line solves the issue, but probably >> there is a better way to achieve the correct result. >> >> \setupinitial[n=3D2] >> >> \setuphead[chapter][ >> after=3D{\placeinitial}, >> page=3Dno, >> ] >> >> \starttext >> \chapter{one} >> Kermit Ruffins \hfill\break % <--- >> >> Meet me at the second line. >> >> \chapter{two} >> \input knuth >> >> Meet me at the second line. >> \stoptext >> >> >> Best regards: Otared >> >> On 13 Jun 2023, at 04:43, Thangalin via ntg-context >> wrote: >> >> I'm using KeenWrite Themes (specifically, Boschet) to typeset a chapter >> wherein the first letter is a lettrine. When the first paragraph is too >> short, the second paragraph overlaps the lettrine. >> >> % SOT >> \setupinitial[n=3D2] >> >> \setuphead[chapter][ >> after=3D{\placeinitial}, >> page=3Dno, >> ] >> >> \starttext >> \chapter{one} >> Kermit Ruffins >> >> Meet me at the second line. >> >> \chapter{two} >> \input knuth >> >> Meet me at the second line. >> \stoptext >> % EOT >> >> Produces: https://i.stack.imgur.com/kNDqw.png >> >> How would you instruct ConTeXt to "protect" the lettrine such that >> regardless of whether the first paragraph spans multiple lines, a short >> first paragraph will still prevent the second paragraph from overlapping >> the lettrine? >> >> That is, the setups should work in both cases, without any knowledge >> about the first paragraph length being added between \starttext and >> \stoptext. >> >> ConTeXt LMTX version: 2023.06.04 18:58 >> >> Thank you! >> >> ________________________________________________________________________= ___________ >> If your question is of interest to others as well, please add an entry t= o >> the Wiki! >> >> maillist : ntg-context@ntg.nl / >> https://www.ntg.nl/mailman/listinfo/ntg-context >> webpage : https://www.pragma-ade.nl / http://context.aanhet.net >> archive : https://bitbucket.org/phg/context-mirror/commits/ >> wiki : https://contextgarden.net >> >> ________________________________________________________________________= ___________ >> >> >> Otared Kavian >> e-mail: otared@gmail.com >> Phone: +33 6 88 26 70 95 >> >> >> >> >> >> ________________________________________________________________________= ___________ >> If your question is of interest to others as well, please add an entry t= o >> the Wiki! >> >> maillist : ntg-context@ntg.nl / >> https://www.ntg.nl/mailman/listinfo/ntg-context >> webpage : https://www.pragma-ade.nl / http://context.aanhet.net >> archive : https://bitbucket.org/phg/context-mirror/commits/ >> wiki : https://contextgarden.net >> >> ________________________________________________________________________= ___________ >> > --000000000000e23eae05fe09484e Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Here's the output I'm looking to achieve:


Note how the se= cond line honours the lettrine's width and padding, in the same way tha= t the second line of the first paragraph in Knuth's quote respects the = width and padding.

On Tue, Jun 13, 2023 at 2:01=E2=80=AFPM Thang= alin <thangalin@gmail.com>= wrote:
Thanks Otared,

Unfortunately, that&#= 39;s adding content between \starttext and \stoptext, which isn't tenab= le in my situation. The user is writing in Markdown, which is automatically= converted to XHTML then passed to ConTeXt, and so the setups need to accou= nt for this scenario without modifying the source document.

<= /div>
Cheers!

On Tue, Jun 13, 2023 at 1:30=E2=80=AFAM Otared K= avian via ntg-context <ntg-context@ntg.nl> wrote:
Hi,

Adding \hfill\break to= the short line solves the issue, but probably there is a better way to ach= ieve the correct result.

\setupinitial[n=3D2]=

\setuphead[chapter][
=C2=A0 after=3D{\p= laceinitial},
=C2=A0 page=3Dno,
]

<= div>\starttext
\chapter{one}
Kermit Ruffins \hfill\brea= k % <---

Meet me at the second line.
=
\chapter{two}
\input knuth

Meet me at the second line.
\stoptext

=
Best regards: Otared

On 13 Jun 2023, at 04:43, Thangalin via ntg-context <ntg-context@ntg.nl> wrote= :

I'm using KeenWrite Themes (speci= fically, Boschet) to typeset a chapter wherein the first letter is a lettri= ne. When the first paragraph is too short, the second paragraph overlaps th= e lettrine.

% SOT
\setupinitial[n=3D= 2]

\setuphead[chapter][
=C2=A0 after=3D{\placeinitial},
=C2=A0= page=3Dno,
]

\starttext
\chapter{one}
Kermit Ruffins
Meet me at the second line.

\chapter{two}
\input knuth

M= eet me at the second line.
\stoptext
% EOT


How= would you instruct ConTeXt to "protect" the lettrine such that r= egardless of whether the first paragraph spans multiple lines, a short firs= t paragraph will still prevent the second paragraph from overlapping the le= ttrine?

That is, the setups should work in both ca= ses, without any knowledge about the first paragraph length being added bet= ween \starttext and \stoptext.

ConTeXt LMTX versio= n: 2023.06.04 18:58

Thank you!
___________________________________________________________________________= ________
If your question is of interest to others as well, please add a= n entry to the Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/= listinfo/ntg-context
webpage =C2=A0: https://www.pragma-ade.nl / http://context.aanhet.net
arch= ive =C2=A0: https://bitbucket.org/phg/context-mirror/commits/
w= iki =C2=A0=C2=A0=C2=A0=C2=A0: https://contextgarden.net
______________________________= _____________________________________________________

Otared Kavian
P= hone: +33 6 88 26 70 95




___________________________________________________________= ________________________
If your question is of interest to others as well, please add an entry to t= he Wiki!

maillist : ntg-cont= ext@ntg.nl / https://www.ntg.nl/mailman/listinfo/= ntg-context
webpage=C2=A0 : https://www.pragma-ade.nl / http://context.aanhet.net
archive=C2=A0 :
https://bitbucket.org/phg/context-m= irror/commits/
wiki=C2=A0 =C2=A0 =C2=A0: https://contextgarden.net
___________________________________________________________________________= ________
--000000000000e23eae05fe09484e-- --===============8152464067261536106== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context webpage : https://www.pragma-ade.nl / http://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : https://contextgarden.net ___________________________________________________________________________________ --===============8152464067261536106==--