emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Maxim Nikulin <manikulin@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Re: Bug: PDF Export of Link fails (emphasis ends inside link target)
Date: Fri, 3 Sep 2021 21:18:33 +0700	[thread overview]
Message-ID: <sgtarr$156d$1@ciao.gmane.io> (raw)
In-Reply-To: <87pmtqp79s.fsf@web.de>

On 03/09/2021 12:17, Dr. Arne Babenhauserheide wrote:
> Using the following text I get failing pdf export: The link is not
> recognized correctly but ends after the comma and the markup persists in
> the PDF.
> /Diesen Text habe ich leicht abgewandelt schon am Montag per E-Mail
> ans [[https://km-bw.de/,Lde/startseite/service/kontakt][Kultusministerium BW]] geschickt. Da hatten wir noch 2 Wochen./

It was discussed earlier.

On Tue, 20 Apr 2021 22:37:31 +0200, Nicolas Goaziou wrote
Re: [Patch] to correctly sort the items with emphasis marks in a list
https://orgmode.org/list/874kg0ae0k.fsf@nicolasgoaziou.fr/ :
> Maxim Nikulin writes:
>> Surprisingly there are still cases when the old approach works better:
>> (let ((s (org-sort-remove-invisible
>> "A /wrapping [[https://orgmode.org/?a=b&c=d#e][link]] emphasis/")))
>>   (set-text-properties 0 (length s) nil s)
>>   s)
>> "A wrapping [[https://orgmode.org?a=b&c=d#e][link]] emphasis/"
>> I expect "A wrapping link emphasis".
> Yet, your expectations are wrong. There is no link in the text above.
> Emphasized text starts at "/wrapping" and ends before "/?".
> Granted, this is a situation where the Org syntax is not very intuitive.
> Anyway, the new function is more accurate.
> Maybe we should require a space after punctuation following emphasized
> text. I don't know. This is orthogonal to the current discussion.

In your particular case it is possible to use "%2C" instead of comma:

[[https://km-bw.de/%2CLde/startseite/service/kontakt][kontakt]] link/

As a more general approach, additional emphasis marks can be added 
around link borders

     /Test/ [[https://orgmode.org/?q=query][/query/]] /test/

While I believe that during parsing of link target lookup for end of 
emphasis should be suppressed, I am not sure that it is feasible with 
current implementation. That is why I consider such behavior as a price 
for lightweight markup and its current parser.

  parent reply	other threads:[~2021-09-03 14:19 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-03  5:17 Bug: PDF Export of Link fails [9.4.6 (9.4.6-gab9f2a @ /gnu/store/2pny4z6mbi2aybgzzxz0yrzkds7hbpmq-emacs-org-9.4.6/share/emacs/site-lisp/org-9.4.6/)] Dr. Arne Babenhauserheide
2021-09-03  8:24 ` Timothy
2021-09-03  9:18   ` Ihor Radchenko
2021-09-03  8:30 ` Timothy
2021-09-03 14:18 ` Maxim Nikulin [this message]
2021-09-03 14:33   ` Bug: PDF Export of Link fails (emphasis ends inside link target) Timothy
2021-09-03 14:57     ` Maxim Nikulin
2021-09-19 12:11       ` Max Nikulin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='sgtarr$156d$1@ciao.gmane.io' \
    --to=manikulin@gmail.com \
    --cc=emacs-orgmode@gnu.org \


* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).