From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id UE/VOir+bWIZ8gAAbAwnHQ (envelope-from ) for ; Sun, 01 May 2022 05:27:39 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id EJ8HOir+bWKyLQAAG6o9tA (envelope-from ) for ; Sun, 01 May 2022 05:27:38 +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 8DA68E9E0 for ; Sun, 1 May 2022 05:27:38 +0200 (CEST) Received: from localhost ([::1]:41794 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nl0FF-00062U-OX for larch@yhetil.org; Sat, 30 Apr 2022 23:27:37 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:60106) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nl0EP-00062K-OR for emacs-orgmode@gnu.org; Sat, 30 Apr 2022 23:26:45 -0400 Received: from mail-pg1-x533.google.com ([2607:f8b0:4864:20::533]:36707) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nl0EN-00005G-J2 for emacs-orgmode@gnu.org; Sat, 30 Apr 2022 23:26:45 -0400 Received: by mail-pg1-x533.google.com with SMTP id g3so9381451pgg.3 for ; Sat, 30 Apr 2022 20:26:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:in-reply-to:references:date:message-id :mime-version; bh=7jNMKL8owNxUenBVFKjfF7ylNgvl+45yQjwuIpvK9SY=; b=Fde32Sh5TjVJOePw+GD9OiTnx+fUOYA67BDh94v1ld2rPPjZppci26MQv3k3zs5ME8 33mue62wcFKwAeCrgACnkIrOAbj4DwAPGpOjnVSwV19wH6z/deENYfHN33p8/GLP10wM RrtD4rKrBHc62mK8Cr2IFmTJdvW0I8Es2GcWxA7SYukuqf5CPZr2MXmwQVdoGncROh2P SNgm4HTrfKwotzEA9SDHOuKJ5rdN5W5T2ovN8pHhwxrgEr76jtKrLn5ybIsnMOewZAU9 G0AF3k0HLsxT2EmYqsiwCWt8x2gQI2FLhlxrMWWA2jxfqwiqBivFb3qd7GpFPhPebwpE FHUg== 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:in-reply-to:references:date :message-id:mime-version; bh=7jNMKL8owNxUenBVFKjfF7ylNgvl+45yQjwuIpvK9SY=; b=O6Ocu+XQmrTtS11MTAP2IgdD43rO5+tAgjkIcPA4V588IywX4YxhsbFm4SmJc7Ks6p z8O9uMCr3Mmbw6l22xdszXKRtcyfr0yMwmeGI0AEWlH6EEP7ZcUiXTYF3NdnKzPGTHS+ alfAFCPG9ZeXwQmZERVY5teVkcoxrw1/C1IXI6wdtShy4xAtxwHZ6QEpI5rQNwdZVORn nyPdDbQUzLWjc/mP9xqAIx1k7iNzExMgvA8Iz/A7Y1rkEh10JUbsRy1YHCWdOnPNCYA1 HItU/QUPfBeXS/VImKOYrRC0vBBCqaDCLAGN2vhF3GQk6n8WDSoPI6tWmjU1t+gqzHXT fc6A== X-Gm-Message-State: AOAM5320lQrUbdZBrDd4+P2ci/aqBScuY9IvvUyKJ5tVEz+B7P22wveA Oo5GpgsagNsYCCCu7eGFcjY= X-Google-Smtp-Source: ABdhPJwhc28jVipgx0w+Sn/9IYirqNjUlp07RBca0A4N6pAxnzTIyPAsvQGzaVWpLHwlYW94pqGguA== X-Received: by 2002:a63:8ac3:0:b0:3aa:fc39:93b with SMTP id y186-20020a638ac3000000b003aafc39093bmr4936407pgd.6.1651375601777; Sat, 30 Apr 2022 20:26:41 -0700 (PDT) Received: from localhost ([103.125.234.210]) by smtp.gmail.com with ESMTPSA id j12-20020a62e90c000000b0050dc76281e7sm2211603pfh.193.2022.04.30.20.26.40 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 30 Apr 2022 20:26:41 -0700 (PDT) From: Ihor Radchenko To: Max Nikulin Subject: Re: [BUG] Exporting italic link with bang inside to html fails to parse the link [9.5.2 (N/A @ /gnu/store/89yvbijwnvsbpa5h33mvbgh1gy9w30n2-emacs-org-9.5.2/share/emacs/site-lisp/org-9.5.2/)] In-Reply-To: References: <87v8vng70x.fsf@web.de> <87a6c29aj6.fsf@localhost> <956f9324-a8ea-4766-b0fd-e4dcd364edd7@gmail.com> <8735hu92dh.fsf@localhost> Date: Sun, 01 May 2022 11:27:30 +0800 Message-ID: <87czgy6ifx.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2607:f8b0:4864:20::533; envelope-from=yantar92@gmail.com; helo=mail-pg1-x533.google.com X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 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, T_SCC_BODY_TEXT_LINE=-0.01 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: , Cc: emacs-orgmode@gnu.org Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1651375658; 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=7jNMKL8owNxUenBVFKjfF7ylNgvl+45yQjwuIpvK9SY=; b=IwFzpdghx0TqI23oykbh6xnyyg/Ow9sZyfbl4LnGMo8PFBmRhNzD//7CHMHk1RM7O8ROES 0z1+GpS9ypTt74whZReaCtVGGVv1rLQoUAcUwdcOeUqpWVnqy1v5+NN4zdhjSDpnCrsCh4 ta0nOXbj3I6JGzRNNBv4dTTSeCHfbIMboLoheweQIkKPlNDJhettXjAxCXxq7whVAFG7fS qkkdNI3/hdYq54Yy66W/V8em+Ceni+QJZe94uuFBw63ftNlM2eDwN5qEES6fThb4+JR+zE KNhpmeo6Ak3ZAO9DyPuX0t2AKHTlkurOH2AQHV7HsyeefVj+pz2ykNrheY/TkA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1651375658; a=rsa-sha256; cv=none; b=PZ4rmNHZCASlPegWqvR4n6Fn45H2oof57Dlcg6V1s9T5i1vA3NGYsUtGDKU24A+iAyPjbI 9MBcLtL2k17NvMhshSGYMTZf3wHqD26r97M+UkQOvEk8pwoWioHCWplE0OVahbIgZkCdNC iNVzpGptIQrWGR2geRBTg6vBdKDqYLjn2K5Ma1ykrAY64P23baCOKGLa/VD/TmgOLDdMN0 7+KeTlnWkx7KXK0aFMelcugxuVYn2ZOdwyrsOTRysjfIIqxIQ75+dbtuD+hLJX7zPDUAPO /wOUEW8W5Fxh2bScZu0ZlS+kNL4pfUCU1INZXNY3sWz3T2z8BidYBZs4HMOBOQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=Fde32Sh5; 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.29 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=Fde32Sh5; 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: 8DA68E9E0 X-Spam-Score: -4.29 X-Migadu-Scanner: scn0.migadu.com X-TUID: vWEn4odr24Tv Max Nikulin writes: >>> 2021-09-03 5:17 Dr. Arne Babenhauserheide Bug: PDF Export of Link fails >>> https://list.orgmode.org/87pmtqp79s.fsf@web.de/T/#u >>> >>> Timothy suggested to fix `org-insert-link' somehow in than thread. >> >> Yeah. I recall a number of bug report related to this behaviour. >> Though I wanted to focus on org-insert-link here. > > Then the older bug may be cancelled as a duplicate. Not sure. Even a fix to org-insert-link would not solve the problem with unexpected export if the link is typed in manually. So, I'd rather keep both the reports for the time being. Or someone may go through all the related bugs and create a single giant discussion to avoid scattering things around. In my notes, I have at least 6 discussions related to edge cases of Org markup. >>> Unfortunately It requires an additional export filter to remove zero >>> width spaces. >> >> Yeah. Right. It should even be an easy patch, which would be welcome :) > > I meant a custom user filter. I consider zero width spaces as the last > resort. Nicolas considered making zero width spaces an official part of > syntax stripped during export and a way to preserve some of them. I think it is already kind of official. At least, we directly suggest using zero width spaces in https://orgmode.org/manual/Escape-Character.html#Escape-Character The other thing is that ox.el does not do anything about zero width spaces. > In the case of links I still prefer breaking emphasis at the link > borders. `org-insert-link' may check after inserting the markup if it > is parsed as a link and add more markers if necessary. > ... > /inter/[[https://orgmode.org/?oops=1][/word/]]/link/ I do not like this idea. It is fine when inserting a link into existing emphasis, but what if an emphasis is applied around link later? We would also need to update org-emphasize and still have an issue because many users simply type the emphasis markers manually. > I am afraid that zero width spaces in link targets may lead to confusion > of users since in the most cases e.g. http: URLs may be pasted to > external application as is. We already escape '\' ,'[', and ']' in links. Zero width spaces will not make things much different. Of course, org-link-escape and org-link-unescape will need to be updated. Note that even copying Urls directly can be worked around using filter-buffer-substring-function. Best, Ihor