emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* [patch] Link abbreviations : left-trim the tag
@ 2009-06-19 21:56 Nicolas Girard
  2009-06-20 19:22 ` Carsten Dominik
  0 siblings, 1 reply; 2+ messages in thread
From: Nicolas Girard @ 2009-06-19 21:56 UTC (permalink / raw)
  To: emacs-orgmode

Hi,
the following patch left-trims the tag in a link abbreviation ; this
allows to write
[[google: org-mode]]
for better readability.

--
Nicolas


diff --git a/lisp/org.el b/lisp/org.el
index 07d790f..8aef3c7 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -6830,7 +6830,7 @@ call CMD."

 (defun org-link-expand-abbrev (link)
   "Apply replacements as defined in `org-link-abbrev-alist."
-  (if (string-match "^\\([a-zA-Z][-_a-zA-Z0-9]*\\)\\(::?\\(.*\\)\\)?$" link)
+  (if (string-match "^\\([a-zA-Z][-_a-zA-Z0-9]*\\)\\(::?[
\t]*\\(.*\\)\\)?$" link)
       (let* ((key (match-string 1 link))
             (as (or (assoc key org-link-abbrev-alist-local)
                     (assoc key org-link-abbrev-alist)))

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-06-20 19:22 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-06-19 21:56 [patch] Link abbreviations : left-trim the tag Nicolas Girard
2009-06-20 19:22 ` Carsten Dominik

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

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).