Better default description for link to Org-mode heading

Requested by Stefan Vollmar.
This commit is contained in:
Carsten Dominik 2009-06-20 21:10:55 +02:00
parent daa2800ff3
commit 51ad548037
2 changed files with 4 additions and 1 deletions

View File

@ -1,5 +1,8 @@
2009-06-20 Carsten Dominik <carsten.dominik@gmail.com>
* org.el (org-store-link): Better default description for link to
Org-mode headline.
* org-exp.el (org-export-generic): Autoload the generic exporter
function.
(org-export): Implement the `g' key for the generic exporter.

View File

@ -7037,7 +7037,7 @@ For file links, arg negates `org-context-in-file-links'."
(condition-case nil
(org-make-org-heading-search-string txt)
(error "")))
desc "NONE")))
desc (or (nth 4 (org-heading-components)) "NONE"))))
(if (string-match "::\\'" cpltxt)
(setq cpltxt (substring cpltxt 0 -2)))
(setq link (org-make-link cpltxt)))))