From 2504eec834a01b134c7e215fb61cb3bd3d8aed91 Mon Sep 17 00:00:00 2001 From: Matthew Flatt Date: Sat, 25 Aug 2012 07:38:17 -0600 Subject: [PATCH] fix condense-mode slide counting in `with-steps' --- collects/slideshow/step.rkt | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/collects/slideshow/step.rkt b/collects/slideshow/step.rkt index 2f2ca6d2cd..401fd93e91 100644 --- a/collects/slideshow/step.rkt +++ b/collects/slideshow/step.rkt @@ -105,9 +105,13 @@ (and (after?/p p1) (not (after?/p p2)))) (let () expr0 expr ...)) (if (and condensing condense?) - (last-pair steps) + (begin + (skip-slides (sub1 (length steps))) + (last-pair steps)) (if condense? - (filter (lambda (id) - (not (regexp-match #rx"~$" (symbol->string id)))) - steps) + (let ([l (filter (lambda (id) + (not (regexp-match #rx"~$" (symbol->string id)))) + steps)]) + (skip-slides (- (length steps) (length l))) + l) steps))))))])))