From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id 8Fa7B5x26WZ5AgEAe85BDQ:P1 (envelope-from ) for ; Tue, 17 Sep 2024 12:31:24 +0000 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id 8Fa7B5x26WZ5AgEAe85BDQ (envelope-from ) for ; Tue, 17 Sep 2024 14:31:24 +0200 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=gmail.com header.s=20230601 header.b=hAGwTSVF; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1726576284; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=QjSqn5QhL/Gy9wOO/HGuxyWMDCICXyUINIX/895hSO4=; b=BzKYmL7gp6Dk6OCY8J4H7Pq85iJZDrs2CBJ71Amf7iSlWc6n/OodTLQxSyAU7XvCPysoGi kGxY4jMy89aDktfquPqIlRM7lmcTjr7EYc+ToJHRfdXdDYaKUISLbiEjs8F7LUw8fXjb2q cErCjFCI8+6h7kinBSL/K6VIRGrDawax5KO8VthO/Vu34uj0v+nKdowTqr6QcPPpKJqJ0z icfMsdStbT2EnuJpZkKj5R3llT1uTNPrXin8jg5TSFBEP0IbM4N+bAf27uJoWFyyvn5wD0 3a6CHgw+AqieDEhmNlQUBV9enfHIi9qqjSqUpLHebO/qCcqD71ohCU02mgE+Dw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=gmail.com header.s=20230601 header.b=hAGwTSVF; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org"; dmarc=fail reason="SPF not aligned (relaxed)" header.from=gmail.com (policy=none) ARC-Seal: i=1; s=key1; d=yhetil.org; t=1726576284; a=rsa-sha256; cv=none; b=gShOMuDuCdsxW+uqjrESVNXU13pdihmcQhROZx/VhpGcziZGiNQU98GKOeVERebYecTeb1 ZAELxoOHGqnx10/ssPqFQHghWWwit25JRkVW+NZJD3VlTbcfAtEh7SjCDGli4ZQn57ZDqb 5nRu5GGxJRwuzNZrkEDZDtY8RWlV8kKaVBZREZFWGgjatB4RZhy67y9EE6q5hN76fWKkQB JTL27dXeT8wkwikArUUmT41E+ZpIPmniPpMxqcplt8OcmikLQuE6grV7zqB35TIila2/CL 2Nd5cYL4C2Auq0gNyz44MxYa7KKCphL+fP5SEvb0jZsbtBJ7P9EdyjTN3jejJg== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 9A1614386 for ; Tue, 17 Sep 2024 14:31:23 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sqXLk-0004ij-2Y; Tue, 17 Sep 2024 08:30:32 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sqXLh-0004cw-6e for emacs-orgmode@gnu.org; Tue, 17 Sep 2024 08:30:29 -0400 Received: from mail-yb1-xb2e.google.com ([2607:f8b0:4864:20::b2e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sqXLd-00018P-SD for emacs-orgmode@gnu.org; Tue, 17 Sep 2024 08:30:28 -0400 Received: by mail-yb1-xb2e.google.com with SMTP id 3f1490d57ef6-dff1ccdc17bso5414932276.0 for ; Tue, 17 Sep 2024 05:30:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1726576224; x=1727181024; darn=gnu.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=tirwx2MJU2NiJi3703NkWhMXcz+VCTa81cAm26LEMBo=; b=hAGwTSVFWrzr7gwrk3anCc5FCnabrY6TsCDDT2rv21cnYF0vWuKFbA45ibF5RxLqHk q7LiVNknueJE6Xy1njWmUd7mTNNjRQB5iVkjf3P/+mSmfhsMR0U7/Eo4xQivB2im1RMq FlsXjl6urIlI7ap8sLIfNSHMzkio754hRBfp6z8rZNRECxkLBaqjgfzZzFa+QdkkMTZP LNOukxz3nthKgTAxrPXgucSwgYSWy6l4+P2hsx6UI4bBY8CxC3h3Pijo7TNoHL8o1tJj xMy8xLShayu9R79XgcpwUvRP3S0UhHgFq6kAYOlKoUSkqH4v9cggZavJKm0ye29nMOhT 0Wxw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1726576224; x=1727181024; h=cc: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=tirwx2MJU2NiJi3703NkWhMXcz+VCTa81cAm26LEMBo=; b=LFoHjllOo9R2O/mDjkmQyr1VRiCxSsPPujwFDKlAaE0OtbdrfPlm41FduvqyDoqYyr BsPQC1snoIEoVA1nqGEZKY6uHDMuSLhOmqtOq0/LRyW7qE4aCBdlOXLc7zQlKAlJ2jSc tkEmK0XpdLwDcBqfYfRQb2z/LN1BtF9UhEEKLdZTtH05KCmiI7K73pv+ThuM8nwDoS4f o8RLTCO4siz0K6JKP4nGikYOffMHlfIsAit/lV2td5ubR2EXztm6QghasCcDxvrU3bRX jng38x5kLIOHZcHv/xIkvfV8sEYvr55CwUPg2nRObHi6FvfaK1tDK2LifPIrGgkyAjHQ laMQ== X-Gm-Message-State: AOJu0Yw2lJqPf2Y1Znj7y9kf0re8a2MQ0AaKTWIeFI4K9va3oY53g9hE CSZL0Siv+5eP+yUbH8GScMVkvnrSmB0xs4GMW6JFFtrcbeECUrLGfoHCTraMI5DtU5BkQgHQFyH nfEx0VrAhSCp63COKZig/Yu7vAZmYLWMt X-Google-Smtp-Source: AGHT+IEaCkf9LzsDdfd7RIGsCz++imLj3cRicFaTKvIT6DVuneqC+9V+qsNoh0uZ1GIMLfQDrSochElg6+1uWaanfbI= X-Received: by 2002:a05:6902:2782:b0:e1d:1d19:edf2 with SMTP id 3f1490d57ef6-e1d9dc4178amr16538171276.46.1726576224348; Tue, 17 Sep 2024 05:30:24 -0700 (PDT) MIME-Version: 1.0 References: <87ikv3o33d.fsf@localhost> In-Reply-To: From: Benjamin McMillan Date: Tue, 17 Sep 2024 21:29:58 +0900 Message-ID: Subject: Re: [BUG] export blocks no longer fontifying [9.7.10 (release_9.7.10 @ /Users/ben/Scripts/emacs/lisp/org/)] To: Ihor Radchenko Cc: emacs-orgmode@gnu.org Content-Type: multipart/mixed; boundary="00000000000087dff106224fdaa3" Received-SPF: pass client-ip=2607:f8b0:4864:20::b2e; envelope-from=mcmillanbb@gmail.com; helo=mail-yb1-xb2e.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Queue-Id: 9A1614386 X-Migadu-Scanner: mx11.migadu.com X-Spam-Score: -5.40 X-Migadu-Spam-Score: -5.40 X-TUID: VAaF3NpmEVxP --00000000000087dff106224fdaa3 Content-Type: multipart/alternative; boundary="00000000000087dff006224fdaa1" --00000000000087dff006224fdaa1 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable I attach the patch here. However, I have two questions. First, I am not certain that I set up the repository correctly, because when I run "make test" it generates 55 unexpected failures. This without making any changes. (The patch submitted here does not generate any new failures.) Second, the existing comment at the patch becomes slightly out of date with the change. In fact, I propose that it might be good to update the docstring for `org-src-fontify-natively' to explicitly state that it enable fontification for src, example, and export blocks. If that is agreed on, I am happy to submit a further patch. Thanks, Ben On Mon, Sep 16, 2024 at 11:27=E2=80=AFPM Benjamin McMillan wrote: > Ok, I am happy to submit a patch. It would be my first, so I will have to > find time to make the commit properly. > > On Wed, Sep 11, 2024 at 1:59=E2=80=AFAM Ihor Radchenko > wrote: > >> Benjamin McMillan writes: >> >> > At some point in the last few months, org mode stopped fontifying my >> > latex export blocks. However, an older version of emacs on my computer >> > still does fontify. >> > (The difference is seen even opening emacs with the -q flag) >> > It seems that there was a change to the function >> > org-fontify-meta-lines-and-blocks-1 in org.el, specifically at the >> > conditional that checks org-src-fontify-natively. >> > As the comment there explains, the intention is to only fontify src >> > blocks, but I don't see any option exposed to enable fontififcation of >> > export blocks, which is a fairly crucial feature to my workflow. >> > >> > I think fontification of export blocks should follow that of src block= s, >> > or a separate option should be made. (Or, I may be missing some alread= y >> > existing solution!) >> > >> > For what it is worth, I can get the desired behavior by modifying the >> > code mentioned above to include "export", as in the following: >> > (and org-src-fontify-natively >> > ;; Technically, according to >> > ;; `org-src-fontify-natively' docstring, we should >> > ;; only fontify src blocks. However, it is common >> > ;; to use undocumented fontification of example >> > ;; blocks with undocumented language specifier. >> > ;; Keep this undocumented feature for user >> > ;; convenience. >> > (member block-type '("src" "example" "export"))) >> >> Since we already do it for example blocks, I see not why we should not >> for export blocks. >> >> Would you be interested to submit a patch with your modification? >> See https://orgmode.org/worg/org-contribute.html#first-patch >> >> -- >> Ihor Radchenko // yantar92, >> Org mode contributor, >> Learn more about Org mode at . >> Support Org development at , >> or support my work at >> > --00000000000087dff006224fdaa1 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
I attach the patch here.

How= ever, I have two questions.
First, I am not certain that I set up= the repository correctly, because when I run "make test" it gene= rates 55 unexpected failures. This without making any changes.
(T= he patch submitted here does not generate any new failures.)

=
Second, the existing comment at the patch becomes slightly out o= f date with the change.
In fact, I propose that it might be good = to update the docstring for `org-src-fontify-natively' to explicitly st= ate that it enable fontification for src, example, and export blocks.
=
If that is agreed on, I am happy to submit a further patch.
= Thanks,
Ben

On Mon, Sep 16, 2024 at 11:27=E2=80=AFPM Ben= jamin McMillan <mcmillanbb@gmail= .com> wrote:
Ok, I am happy to submit a patch. It would be my first= , so I will have to find time to make the commit properly.

On Wed, Sep 1= 1, 2024 at 1:59=E2=80=AFAM Ihor Radchenko <yantar92@posteo.net> wrote:
Benjamin McMillan <mcmillanbb@gmail.com> writes:

> At some point in the last few months, org mode stopped fontifying my > latex export blocks. However, an older version of emacs on my computer=
> still does fontify.
> (The difference is seen even opening emacs with the -q flag)
> It seems that there was a change to the function
> org-fontify-meta-lines-and-blocks-1 in org.el, specifically at the
> conditional that checks org-src-fontify-natively.
> As the comment there explains, the intention is to only fontify src > blocks, but I don't see any option exposed to enable fontififcatio= n of
> export blocks, which is a fairly crucial feature to my workflow.
>
> I think fontification of export blocks should follow that of src block= s,
> or a separate option should be made. (Or, I may be missing some alread= y
> existing solution!)
>
> For what it is worth, I can get the desired behavior by modifying the<= br> > code mentioned above to include "export", as in the followin= g:
> (and org-src-fontify-natively
>=C2=A0 =C2=A0 =C2=A0;; Technically, according to
>=C2=A0 =C2=A0 =C2=A0;; `org-src-fontify-natively' docstring, we sho= uld
>=C2=A0 =C2=A0 =C2=A0;; only fontify src blocks.=C2=A0 However, it is co= mmon
>=C2=A0 =C2=A0 =C2=A0;; to use undocumented fontification of example
>=C2=A0 =C2=A0 =C2=A0;; blocks with undocumented language specifier.
>=C2=A0 =C2=A0 =C2=A0;; Keep this undocumented feature for user
>=C2=A0 =C2=A0 =C2=A0;; convenience.
>=C2=A0 =C2=A0 =C2=A0(member block-type '("src" "exam= ple" "export")))

Since we already do it for example blocks, I see not why we should not
for export blocks.

Would you be interested to submit a patch with your modification?
See
https://orgmode.org/worg/org-contribute.= html#first-patch

--
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,=
or support my work at <https://liberapay.com/yantar92>
--00000000000087dff006224fdaa1-- --00000000000087dff106224fdaa3 Content-Type: application/octet-stream; name="0001-lisp-org.el-Change-native-fontification-to-include-e.patch" Content-Disposition: attachment; filename="0001-lisp-org.el-Change-native-fontification-to-include-e.patch" Content-Transfer-Encoding: base64 Content-ID: X-Attachment-Id: f_m16ekzme0 RnJvbSAyZTU0M2ViNDM5M2IwMWE2NDBjMmIxZDY2ZGU1NWE3NDRiZTc1YmNhIE1vbiBTZXAgMTcg MDA6MDA6MDAgMjAwMQpGcm9tOiBCZW5qYW1pbiBNY01pbGxhbiA8bWNtaWxsYW5iYkBnbWFpbC5j b20+CkRhdGU6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gICAgIChvcmctc3JjLWZvbnQtbG9jay1m b250aWZ5LWJsb2NrIChvciBsYW5nICIiKSBibG9jay1zdGFydCBibG9jay1lbmQpKQogCSAgICAg IChhZGQtdGV4dC1wcm9wZXJ0aWVzIGJvbC1hZnRlci1iZWdpbmxpbmUgYmxvY2stZW5kICcoc3Jj LWJsb2NrIHQpKSkKLS0gCjIuNDYuMAoK --00000000000087dff106224fdaa3--