From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id gH8OKXWdPmOLbgAAbAwnHQ (envelope-from ) for ; Thu, 06 Oct 2022 11:18:45 +0200 Received: from aspmx1.migadu.com ([2001:41d0:8:6d80::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id +JM3KHWdPmOwbgEAG6o9tA (envelope-from ) for ; Thu, 06 Oct 2022 11:18:45 +0200 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 21CBA259AE for ; Thu, 6 Oct 2022 11:18:45 +0200 (CEST) Received: from localhost ([::1]:54664 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ogN1f-0001tv-DG for larch@yhetil.org; Thu, 06 Oct 2022 05:18:43 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:49354) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ogMe0-000802-9D for emacs-orgmode@gnu.org; Thu, 06 Oct 2022 04:54:16 -0400 Received: from mail-pj1-x1034.google.com ([2607:f8b0:4864:20::1034]:44657) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ogMdy-0000GH-EB for emacs-orgmode@gnu.org; Thu, 06 Oct 2022 04:54:15 -0400 Received: by mail-pj1-x1034.google.com with SMTP id t10-20020a17090a4e4a00b0020af4bcae10so1083464pjl.3 for ; Thu, 06 Oct 2022 01:54:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:message-id:date:references:in-reply-to:subject:cc:to :from:from:to:cc:subject:date; bh=QBnbz2qJmX6I/3Yna/XBX/QoxzM/maCiU5UxJ9KrqeA=; b=XleXkcOi9w8AmxyYxlg84qBz7NdjqSn2lvHupRalmtvozcpsfmk39hKKHKcBg4QWUB g1mhAUZ/gq4UtgTrJGuz3UWgBQr33o+4WG1PTkOiiaA5ZoB9AJZ7GbwNXL6zGvtmreJW 1MFbPVzMpkcgFrnvwas28tEYzyexA1uis2/F2+HTSl6aBrmN0D0vWfRrCuQNETifk4Bq KZK3nrpEwkiAoMTVyVu5srSlm469SDoUU5JMJ5j85u2OUKLhQSSu43fnwHPsQUlRZUbL +2eKIBBkURiEDdYsI5zLVP3B2Aqw9XDf25Wg95B9/eY0Fe5LpnxrQJNWABpv+1cm4aH/ d8BQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=mime-version:message-id:date:references:in-reply-to:subject:cc:to :from:x-gm-message-state:from:to:cc:subject:date; bh=QBnbz2qJmX6I/3Yna/XBX/QoxzM/maCiU5UxJ9KrqeA=; b=HPKIEhtu4QpD4NiPxL2AJYQ1Q8V8xtn9lUBT24tv7GwSjB3jhpKpisGSX71GqIssk2 z+eRxTdsMxfniOcffYQ1+7owVlRmCaTCdnWppP7zVdnGHutMMIaizdf4QtTweHyswYxb suRfuiCYcYXYOgPkv+eA7Pq1tqAiyrjad5s7LGIgtImdpwQ4ot+J3ANco8WX1D3W6Y9I ryEVh7ezMJxbqWE1VhoWrvqqVWurY6YZSPBCK1/h53he+cfztmbU8RaH7rnJ44DoYcWt JOAC1+bUH/MlJVkCDajQumdUIqjZBi0TJUubqBQ/LNHmP+DgteSfejAJbluEZsWFMAn2 9urA== X-Gm-Message-State: ACrzQf1ddiGG4XZZak4hF85/00rmAD/8anndQ90azx+nM5BNeoRVBxJG LuV48qhk8d95q52viHjzkMI= X-Google-Smtp-Source: AMsMyM6Iu9hz7W5hpgQTJMbsXKcXJPRl30cqr8/Wd9dhWLdDTDvylPuHoRser4d4EQy6A/ZavCH6YQ== X-Received: by 2002:a17:90b:38cb:b0:203:100:bb53 with SMTP id nn11-20020a17090b38cb00b002030100bb53mr4176949pjb.107.1665046452774; Thu, 06 Oct 2022 01:54:12 -0700 (PDT) Received: from localhost ([1.83.154.214]) by smtp.gmail.com with ESMTPSA id y184-20020a6264c1000000b00561a8a12796sm1934953pfb.1.2022.10.06.01.54.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 06 Oct 2022 01:54:11 -0700 (PDT) From: Ihor Radchenko To: Tor Kringeland Cc: emacs-orgmode@gnu.org Subject: Re: [BUG] `org-fill-paragraph' doesn't respect formatting In-Reply-To: References: Date: Thu, 06 Oct 2022 16:55:03 +0800 Message-ID: <87pmf549i0.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2607:f8b0:4864:20::1034; envelope-from=yantar92@gmail.com; helo=mail-pj1-x1034.google.com X-Spam_score_int: -17 X-Spam_score: -1.8 X-Spam_bar: - X-Spam_report: (-1.8 / 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, 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" 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=1665047925; 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=QBnbz2qJmX6I/3Yna/XBX/QoxzM/maCiU5UxJ9KrqeA=; b=I3MhIDBTCjshwLAKVJaAPVcMk+O4B9/03qM0aUH5A8CJGunrJZo/dCqkLhCA994nOUAuMR 2195rw7GKEQaCyND0VDhWIxsqxwrMGpe0lJ1dzcB/dcuaPn1n+oBnL5CnrEdUMkdCay/a+ 5hpDTjYBNZjkvL8j/vUhwFIuMXDEXj/7ZHLeaXMzQo8AGNKIuJHW0b/5yhFFA9F5WCHqpv kQzGoB3S1hD+gIi1qUL2nIn/HxWZJKbUn3eu3zvLwD3quDQc8J9CKkHmIiXk5eXQ5D7isK tFvm5+U9tEvfvdvIDN7zzvBWUzahb4jpdofONDp8tR3HSRz7qx+D2tS8SWKbkg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1665047925; a=rsa-sha256; cv=none; b=BklNOjNsiumjCL20tWNo7ylHzKn2gMjfrCLm9SrJrS36Re1QKdOMc1o21T7IhmyKYebK/Y OQO+K3desMlxlee7lfUnTWzjKmYguJg897H6Hk5CWbaZej7cN+4Xq2FVgcsbUCTeiVxwMw RknVV2yW2NMfOyTyQ6qFB0qvmXK3b6i/NgiZlRh16vBXBeLNmt6cSFc6i3ZHMFphazBZ8H HK2FTM5AyXe35W1aDkT1rBAkrQzvL+VZ/qKdCoG1ILV/AXgQB+5MJ29IHyCXdqbxEAHTTn 6iTsRtqP9W9Gc8FCGRSyr92kyUHph6MfEUqyPsCk3Jw44btbISFpiXeqvhH3tw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=XleXkcOi; 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: -3.37 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=XleXkcOi; 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: 21CBA259AE X-Spam-Score: -3.37 X-Migadu-Scanner: scn1.migadu.com X-TUID: FtWCWPfTxYQZ Tor Kringeland writes: > Applying `org-fill-paragraph' to /e.g./ > > /Some text./ Some more text. > > when `sentence-end-double-space' is t removes the double space to a > single space. The same happens with other formatting like *bold* and > _underline_. In other instances it is more context aware. /E.g./ > applying it to > > (Some text.) Some more text. > > does nothing, which is correct. This is because Org does not set sentence-end-base to include the markup markers. The easiest way to fix this bug will be setting sentence-end-base. However, in addition to fixing the particular case in this bug report, such change may have unforeseen consequences in other scenarios. We may be more selective and only allow the actual parsed emphasis end markers to be recognized as sentence end. Or I may be overthinking things because `org-mode-transpose-word-syntax-table' is already using indiscriminate approach wrt treating the emphasis barely shielding emphasis additions to specific commands (like in `org-fill-element'). WDYT? -- Ihor Radchenko // yantar92, Org mode contributor, Learn more about Org mode at . Support Org development at , or support my work at