summaryrefslogtreecommitdiff
path: root/src/guile
diff options
context:
space:
mode:
authorLudovic Courtès2008-01-29 17:25:39 +0100
committerLudovic Courtès2008-01-29 17:25:39 +0100
commit6d6d36473616b11d977179bf3e6f30e1761f3c05 (patch)
tree83fd9d620cc477e9d9387ba5814624b672b56bdc /src/guile
parent664657a99ecb3f34a0b5dcb6c0e0fc2bcb697f10 (diff)
downloadskribilo-6d6d36473616b11d977179bf3e6f30e1761f3c05.tar.gz
skribilo-6d6d36473616b11d977179bf3e6f30e1761f3c05.tar.lz
skribilo-6d6d36473616b11d977179bf3e6f30e1761f3c05.zip
outline: Liberated the list and mode-line syntax.
* src/guile/skribilo/reader/outline.scm (%list-processors): Allow leading whitespace for list items. (outline-reader)[modeline-rx]: Allow figures, semi-colons and all.
Diffstat (limited to 'src/guile')
-rw-r--r--src/guile/skribilo/reader/outline.scm6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/guile/skribilo/reader/outline.scm b/src/guile/skribilo/reader/outline.scm
index 27ec05f..8c48293 100644
--- a/src/guile/skribilo/reader/outline.scm
+++ b/src/guile/skribilo/reader/outline.scm
@@ -335,12 +335,12 @@ to @var{node-type}."
(regexp-exec node-rx line))
(define %list-processors
- (list (make-list-processor (make-regexp "^[-~o] (.+)$" regexp/extended)
+ (list (make-list-processor (make-regexp "^[[:space:]]*[-~o] (.+)$" regexp/extended)
'itemize
(lambda (m) (match:substring m 1))
%line-processor
node-markup-line?)
- (make-list-processor (make-regexp "^([0-9]+)\\.? (.+)$"
+ (make-list-processor (make-regexp "^[[:space:]]*([0-9]+)\\.? (.+)$"
regexp/extended)
'enumerate
(lambda (m) (match:substring m 2))
@@ -410,7 +410,7 @@ to @var{node-type}."
(define* (outline-reader :optional (port (current-input-port)))
(define modeline-rx
- (make-regexp "^[[:space:]]*-\\*- [a-zA-Z-]+ -\\*-[[:space:]]*$"))
+ (make-regexp "^[[:space:]]*-\\*- ([a-zA-Z0-9;:-]|[[:space:]])+ -\\*-[[:space:]]*$"))
(define title-rx (make-regexp "^[Tt]itle: (.+)$" regexp/extended))
(define author-rx (make-regexp "^[Aa]uthors?: (.+)$" regexp/extended))
(define keywords-rx