This is in preparation for deleting layout-page-layout.scm.
}
else if (scm_is_pair (scores_))
{
- SCM proc = paper_->c_variable ("page-breaking-wrapper");
- pages_ = scm_apply_0 (proc, scm_list_1 (self_scm ()));
+ SCM page_breaking = paper_->c_variable ("page-breaking");
+ pages_ = scm_apply_0 (page_breaking, scm_list_1 (self_scm ()));
+ SCM post_process = paper_->c_variable ("page-post-process");
+ if (ly_is_procedure (post_process))
+ scm_apply_2 (post_process, paper_->self_scm (), pages_, SCM_EOL);
/* set systems_ from the pages */
if (systems_ == SCM_BOOL_F)
(word-space . 0.6)))
#(define page-breaking ly:optimal-breaking)
- #(define page-breaking-wrapper page-breaking-wrapper)
#(define page-post-process post-process-pages)
#(define write-page-layout (ly:get-option 'dump-tweaks))
(cdr spacing)))))
page)))
-(define (page-breaking-wrapper paper-book)
- "Compute line and page breaks by calling the page-breaking paper variable,
- then performs the post process function using the page-post-process paper
- variable. Finally, return the pages."
- (let* ((paper (ly:paper-book-paper paper-book))
- (pages ((ly:output-def-lookup paper 'page-breaking) paper-book)))
- ((ly:output-def-lookup paper 'page-post-process) paper pages)
- pages))
-
(define (post-process-pages layout pages)
"If the write-page-layout paper variable is true, dumps page breaks
and tweaks."