and another

pull/178/head
Matthew Butterick 6 years ago
parent 03aa25f4e5
commit e65c165e7b

@ -197,12 +197,14 @@
#:linebreak-proc (txexpr-elements? . -> . txexpr-elements?) #:linebreak-proc (txexpr-elements? . -> . txexpr-elements?)
#:force? boolean?) #:force? boolean?)
. ->* . txexpr-elements?) . ->* . txexpr-elements?)
(define paragraph-separator (setup:paragraph-separator))
(unless (string? paragraph-separator)
(raise-argument-error 'decode-paragraphs "string" paragraph-separator))
(define (prep-paragraph-flow elems) (define (prep-paragraph-flow elems)
(linebreak-proc (merge-newlines (trimf elems whitespace?)))) (linebreak-proc (merge-newlines (trimf elems whitespace?))))
(define (paragraph-break? x) (define (paragraph-break? x)
(define paragraph-separator (setup:paragraph-separator))
(define paragraph-pattern (pregexp (format "^~a+$" paragraph-separator))) (define paragraph-pattern (pregexp (format "^~a+$" paragraph-separator)))
(and (string? x) (regexp-match paragraph-pattern x))) (and (string? x) (regexp-match paragraph-pattern x)))

@ -1 +1 @@
1531950418 1531950963

Loading…
Cancel
Save