* [PATCH] Fix broken internal links on export
@ 2010-10-12 16:00 Jambunathan K
2010-10-24 18:37 ` David Maus
0 siblings, 1 reply; 2+ messages in thread
From: Jambunathan K @ 2010-10-12 16:00 UTC (permalink / raw
To: emacs-orgmode
[-- Attachment #1: Type: text/plain, Size: 561 bytes --]
Summary: Fix broken internal links on export
Test case.
(setq org-link-search-must-match-exact-headline t)
# file temp.org
* Heading 1
Some content.
* Heading 2
There is a link to [[Heading 1]] here.
Export this to html and note that [[Heading 1]] is wrongly
translated. Apply the patch. See that the internal link is correctly
exported.
<p>
-There is a link to <a href="#Heading==1">Heading 1</a> here.
+There is a link to <a href="#sec-1">Heading 1</a> here.
</p></div>
</div>
Note:
Is 'dedicated the right value to return?
Jambunathan K.
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: patch --]
[-- Type: text/x-patch, Size: 874 bytes --]
From 82fcc473277c2a1c5647820c19eff0f0e11582c9 Mon Sep 17 00:00:00 2001
From: Jambunathan K <kjambunathan@gmail.com>
Date: Tue, 12 Oct 2010 21:17:09 +0530
Subject: [PATCH] Fix broken internal links on export
* org.el (org-link-search): Return 'dedicated on successful match when
org-link-search-must-match-exact-headline is set to t.
---
lisp/org.el | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/lisp/org.el b/lisp/org.el
index a80286f..f0ad595 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -9389,6 +9389,7 @@ in all files. If AVOID-POS is given, ignore matches near that position."
(regexp-quote s))
nil t))
;; OK, found a match
+ (setq type 'dedicated)
(goto-char (match-beginning 0)))
((and (not org-link-search-inhibit-query)
(eq org-link-search-must-match-exact-headline 'query-to-create)
--
1.7.2.3
[-- Attachment #3: Type: text/plain, Size: 201 bytes --]
_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] Fix broken internal links on export
2010-10-12 16:00 [PATCH] Fix broken internal links on export Jambunathan K
@ 2010-10-24 18:37 ` David Maus
0 siblings, 0 replies; 2+ messages in thread
From: David Maus @ 2010-10-24 18:37 UTC (permalink / raw
To: Jambunathan K; +Cc: emacs-orgmode
[-- Attachment #1.1: Type: text/plain, Size: 334 bytes --]
At Tue, 12 Oct 2010 21:30:12 +0530,
Jambunathan K wrote:
>
> Note:
> Is 'dedicated the right value to return?
>
From my understanding of the code: Yes. The patch fixes the problem
and has been accepted.
Best,
-- David
--
OpenPGP... 0x99ADB83B5A4478E6
Jabber.... dmjena@jabber.org
Email..... dmaus@ictsoc.de
[-- Attachment #1.2: Type: application/pgp-signature, Size: 230 bytes --]
[-- Attachment #2: Type: text/plain, Size: 201 bytes --]
_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2010-10-24 18:38 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-10-12 16:00 [PATCH] Fix broken internal links on export Jambunathan K
2010-10-24 18:37 ` David Maus
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.