From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id kN2RI0Is9WEPCAAAgWs5BA (envelope-from ) for ; Sat, 29 Jan 2022 13:00:02 +0100 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id SEgsIEIs9WEuMAEAauVa8A (envelope-from ) for ; Sat, 29 Jan 2022 13:00:02 +0100 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 E99E22961C for ; Sat, 29 Jan 2022 13:00:01 +0100 (CET) Received: from localhost ([::1]:55358 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nDmOe-0001u9-UA for larch@yhetil.org; Sat, 29 Jan 2022 07:00:00 -0500 Received: from eggs.gnu.org ([209.51.188.92]:59366) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nDm38-0004fI-GI for emacs-orgmode@gnu.org; Sat, 29 Jan 2022 06:37:49 -0500 Received: from [2607:f8b0:4864:20::1031] (port=46969 helo=mail-pj1-x1031.google.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nDm31-0000uZ-UX; Sat, 29 Jan 2022 06:37:41 -0500 Received: by mail-pj1-x1031.google.com with SMTP id oa14-20020a17090b1bce00b001b61aed4a03so7566208pjb.5; Sat, 29 Jan 2022 03:37:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=3jb5QnwRCsFuh/aGN3bQJkwatxo421dMQxkXbWKXVRs=; b=hepyY5zEBoH5MNFD1+1AiK7lDnGs21lHmOKknzRLb4IHfnS3XWZhVBGHF2XPtw6Sad djsb3EWGnTTKjIwPZ3h07g/wncFnxZxIGxzFsd3L330mPrhMHpnsTgl6K5KfKtSyV2pp O9GKtbRcxphlNf43B4FmexZYqS7E1c6wi5RDBGYBIidc55e92IZDKHAv/Q+M+90OTovR NdaEbSRBZAeySxTFXhmvGKxLfk/IPBzuy4Md3nHFGxPq5S6U9C+uyFR3vMHt6tIAZDkR 3V2IF31QVzXeW2S/m3w1rjOSIrrcL1+AWw9DuYGA8tTDwv96peiTlmZWxAG7ev5AfTh0 Ypyw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=3jb5QnwRCsFuh/aGN3bQJkwatxo421dMQxkXbWKXVRs=; b=fhtcWfg+Qgq4iYnrDAbH1gr3GPSQEFSpnvSI/nEgcfcwaLoFCeZjobhRcumCWJIzqh k1BCXhY93wYRWzLnop1gZjigO9NwDJNlhChcFSFe8GRTGy70CXIFh6KlU95QLXUVX9qa gw6x0omwco73y1/yMydjIGosol1DAK1VFVWAx8VaB31rXsAmzQiLCeMrAVvALz6ugdd+ TxnQXVN619LcEBpvutDHEprLufH4pP5FSRLRSpIkylX9SQ00kP/9YaiQ3ZopkDWLfYf7 Y3dd33L5GTgme/eafjME425qWsbH1SfqKGqbZ4JK8xjJKJGPhxR+TDS138dqQOQfLoM6 5tWw== X-Gm-Message-State: AOAM531loq8DM8YbB/algY4B/EpQZOP8snTta1p0EkvEpP8K12jIWqmi S7MUBcCBOOeIwcVGzLA8qb/J+ck6DGUID+A3 X-Google-Smtp-Source: ABdhPJybawBPtpp70WEQTJY1pmkfuXFmEargLJyH19nbNOJvj3jVqVn9xjYqTYOFdj3yEanw3SwDCQ== X-Received: by 2002:a17:902:714a:: with SMTP id u10mr12517012plm.21.1643456257531; Sat, 29 Jan 2022 03:37:37 -0800 (PST) Received: from localhost ([209.95.60.92]) by smtp.gmail.com with ESMTPSA id 198sm20197802pgg.4.2022.01.29.03.37.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 29 Jan 2022 03:37:36 -0800 (PST) From: Ihor Radchenko To: Bastien , Kyle Meyer , Nicolas Goaziou , Karl Voit , Christian Heinrich , emacs-orgmode@gnu.org Subject: [PATCH 25/35] Fix bug in org-get-heading Date: Sat, 29 Jan 2022 19:38:17 +0800 Message-Id: <432c038878dcd2696e41cfa9559bf82a4c4c2994.1643454546.git.yantar92@gmail.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: References: <87y2cvloay.fsf@gnu.org> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="------------2.34.1" Content-Transfer-Encoding: 8bit X-Host-Lookup-Failed: Reverse DNS lookup failed for 2607:f8b0:4864:20::1031 (failed) Received-SPF: pass client-ip=2607:f8b0:4864:20::1031; envelope-from=yantar92@gmail.com; helo=mail-pj1-x1031.google.com X-Spam_score_int: -10 X-Spam_score: -1.1 X-Spam_bar: - X-Spam_report: (-1.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_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, PDS_HP_HELO_NORDNS=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RDNS_NONE=0.793, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=no 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: , Cc: Anders Johansson Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1643457602; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=3jb5QnwRCsFuh/aGN3bQJkwatxo421dMQxkXbWKXVRs=; b=clyoOC90WJkP5BtQrHNYJGBr/y+R4bDryyVWwxYwKJO7ucZJhXhBbogQJvK1Np/7vicwmH GH8S/rmB5+A/nKhsgrzaNQ9pDOT0oQ2la/y3FuVD/J7//0f/kfSI2aVd0ONCoPxOQtH83g 9QOebQZIj9qdkKRmJ6+Gq+f/mWWNhf8/hqDd6AoiZ2dbJ4qqE71kEtqM98U76+JbTGa23Q HnXg1sg9FNPJ1A98L2ccA5WliDHwOFTVOK80G8uaI84/lY5W6+JiDfMINRIX6Ax7Fa7hLl xZYM8qIIq+amMvD4l7DDWoWGpAJv/d6C57w76pTIQ5oqLMQOsG0faRPJlTl0Jw== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1643457602; a=rsa-sha256; cv=none; b=M46Ugoe58iloNpzvOvTrFmkKqzsFCvXT9wthwNHekQlOxkQ1TiW4MkHz85onvsmBoAgvKO ex/4X6FYvTDVD8nAZj+vVAc2y8jm6g/AOgebMu3ViReG4nAyXRDx68t+7cAK8mvyjA4cMT eJDFzVw6FhYa3kMhK6jBfx2jMCPRqVKuD9krgRhYJg4hX1Y+Ivwz6tgwy/VIIe/qczS+/3 xmzb5SnKFuBsx68cEkrdzPXUQ+Q2BJ6atJ3lN9Ipuj4VZE1f36Haeu1uIRQmRkMtNMF5gr o1PBAtH7F2nld3yVMVvwTDAvjf3FVsSsFHjgbOhUxq+1JtHhb90IE3NvSQZGFg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=hepyY5zE; dmarc=pass (policy=none) header.from=gmail.com; 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" X-Migadu-Spam-Score: -4.83 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=hepyY5zE; dmarc=pass (policy=none) header.from=gmail.com; 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" X-Migadu-Queue-Id: E99E22961C X-Spam-Score: -4.83 X-Migadu-Scanner: scn0.migadu.com X-TUID: LKGcksTz45RO From: Anders Johansson This is a multi-part message in MIME format. --------------2.34.1 Content-Type: text/plain; charset=UTF-8; format=fixed Content-Transfer-Encoding: 8bit Fixes #26, where fontification could make the matching and extraction of heading components fail. --- lisp/org.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) --------------2.34.1 Content-Type: text/x-patch; name="0025-Fix-bug-in-org-get-heading.patch" Content-Transfer-Encoding: 8bit Content-Disposition: attachment; filename="0025-Fix-bug-in-org-get-heading.patch" diff --git a/lisp/org.el b/lisp/org.el index 1c01ecf88..dd6298104 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -6166,8 +6166,9 @@ (defun org-get-heading (&optional no-tags no-todo no-priority no-comment) (let ((case-fold-search nil)) (looking-at org-complex-heading-regexp) ;; When using `org-fold-core--optimise-for-huge-buffers', - ;; returned text may be invisible. Clear it up. - (org-fold-core-remove-optimisation (match-beginning 0) (match-end 0)) + ;; returned text will be invisible. Clear it up. + (save-match-data + (org-fold-core-remove-optimisation (match-beginning 0) (match-end 0))) (let ((todo (and (not no-todo) (match-string 2))) (priority (and (not no-priority) (match-string 3))) (headline (pcase (match-string 4) --------------2.34.1--