From 26375db7cec1aec27b1a37cbe2af6d1b3291bbf4 Mon Sep 17 00:00:00 2001 From: Matthew Butterick Date: Thu, 6 Jun 2019 10:12:48 -0700 Subject: [PATCH] space-before correction --- quad/quadwriter/layout.rkt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/quad/quadwriter/layout.rkt b/quad/quadwriter/layout.rkt index 489539c1..4dfddccb 100644 --- a/quad/quadwriter/layout.rkt +++ b/quad/quadwriter/layout.rkt @@ -342,7 +342,9 @@ elems)]) 'sw))]))] [_ null])])) (define maybe-first-line (and (pair? new-lines) (car new-lines))) - (append (list (make-paragraph-spacer maybe-first-line :space-before 0)) + (append (match opening-q + [#false (list (make-paragraph-spacer maybe-first-line :space-before 0))] ; paragraph break + [_ null]) new-lines (match ending-q [(? page-break-quad? page-break) (list page-break)] ; hard page break