diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 59e76f5d..0c1c2a2d 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -6,6 +6,8 @@ AsciiDoc ChangeLog Version 8.5.4 (2010-08-15) -------------------------- .Additions and changes +- Relaxed anchor ID name syntax + (http://groups.google.com/group/asciidoc/browse_thread/thread/5f3e825c74ed30c). - Added document files: `doc/epub-notes.txt`, `doc/publishing-ebooks-with-asciidoc.txt`. - 'a2x': If all other resource locations are exhausted then recursively diff --git a/asciidoc.conf b/asciidoc.conf index acf940f9..f882c95a 100644 --- a/asciidoc.conf +++ b/asciidoc.conf @@ -194,11 +194,11 @@ CAUTION-style=template="admonitionparagraph",name="caution",caption="{caution-ca (?su)[\\]?(?Pfootnote|footnoteref):(?P\S*?)\[(?P.*?)\]= # Anchor: [[[id]]]. Bibliographic anchor. -(?su)[\\]?\[\[\[(?P[\w][\w-]*?)\]\]\]=anchor3 +(?su)[\\]?\[\[\[(?P[\w_:][\w_:.-]*?)\]\]\]=anchor3 # Anchor: [[id,xreflabel]] -(?su)[\\]?\[\[(?P[\w"].*?)\]\]=anchor2 +(?su)[\\]?\[\[(?P[\w"_:].*?)\]\]=anchor2 # Link: <> -(?su)[\\]?<<(?P[\w"].*?)>>=xref2 +(?su)[\\]?<<(?P[\w"_:].*?)>>=xref2 ifdef::asciidoc7compatible[] # Index term: ++primary,secondary,tertiary++ diff --git a/doc/asciidoc.txt b/doc/asciidoc.txt index 3abe2907..75262604 100644 --- a/doc/asciidoc.txt +++ b/doc/asciidoc.txt @@ -2091,10 +2091,11 @@ Used to specify hypertext link targets: [[,]] anchor:[] -The `` is a unique identifier that must begin with a letter. The -optional `` is the text to be displayed by captionless -'xref' macros that refer to this anchor. The optional `` is -only really useful when generating DocBook output. Example anchor: +The `` is a unique string that conforms to the output markup's +anchor syntax. The optional `` is the text to be displayed +by captionless 'xref' macros that refer to this anchor. The optional +`` is only really useful when generating DocBook output. +Example anchor: [[X1]] diff --git a/tests/data/testcases.txt b/tests/data/testcases.txt index bd63a86a..ae180b48 100644 --- a/tests/data/testcases.txt +++ b/tests/data/testcases.txt @@ -155,6 +155,11 @@ An [[X3, anchor reftext]] inline anchor with reftext. Link to <> anchor. +An example link to a bibliography entry <>. + +[horizontal] +[[[Test::Unit]]]:: http://ruby-doc.org/stdlib/libdoc/test/unit/rdoc/classes/Test/Unit.html + == Titles ==