Inhaltlich sinnvollere Aufteilung der include Skripte
This commit is contained in:
@ -121,11 +121,7 @@ includeSong =
|
||||
\bookOutputName #filename
|
||||
#}
|
||||
(ly:parser-parse-string (if (< (list-ref (ly:version) 1) 19) (ly:parser-clone parser) (ly:parser-clone))
|
||||
(string-concatenate
|
||||
(list
|
||||
"HEADER = {} \nMUSIC = {}\nTEXT = \\markuplist {""}\nlyricSize = #1.6\n"
|
||||
;"\\header { songfilename = \"" filename "\" }\n"
|
||||
"\\include \"" "../../lieder/" filename "/" filename ".ly" "\"")))
|
||||
(ly:format "\\include \"../../~a/~a/~a.ly\"" songPath filename filename))
|
||||
(let ((label (gensym "index")))
|
||||
(set! additional-page-switch-label-list
|
||||
(acons label additional-page-numbers additional-page-switch-label-list))
|
||||
@ -149,6 +145,13 @@ imagepage =
|
||||
(acons 'xsize xsize (acons 'filename filename '()))
|
||||
song-list)))
|
||||
|
||||
#(define-markup-command (pagecenter layout props stuff)(markup?)
|
||||
(interpret-markup layout props
|
||||
(let ((halfpaperheight (/ (ly:output-def-lookup layout 'paper-height) 2))
|
||||
(halfstuffheight (/ (interval-length (ly:stencil-extent (interpret-markup layout props stuff) Y)) 2)))
|
||||
(make-fill-line-markup (list (make-pad-to-box-markup '(0 . 0) (cons (- (- halfpaperheight halfstuffheight)) (+ halfpaperheight halfstuffheight)) stuff)))
|
||||
)))
|
||||
|
||||
songs =
|
||||
#(define-void-function (parser location) ()
|
||||
(for-each (lambda (songitems)
|
||||
@ -159,7 +162,7 @@ songs =
|
||||
#{ \bookpart { \markup { \null } } #}
|
||||
(if (eq? filename 'imagePage)
|
||||
(let ((xsize (assq-ref songvars 'xsize))
|
||||
(filename (ly:format "boernel_images/~a" (assq-ref songvars 'filename))))
|
||||
(filename (ly:format "~a/~a" imagePagePath (assq-ref songvars 'filename))))
|
||||
#{ \bookpart {
|
||||
\paper {
|
||||
%{
|
||||
@ -196,16 +199,6 @@ songs =
|
||||
(reverse song-list)
|
||||
))
|
||||
|
||||
includeOnce =
|
||||
#(define-void-function (parser location filename) (string?)
|
||||
(if
|
||||
(not (defined? (string->symbol filename)))
|
||||
(begin
|
||||
(ly:parser-include-string parser
|
||||
(string-concatenate
|
||||
(list "\\include \"" filename "\"")))
|
||||
(primitive-eval (list 'define (string->symbol filename) #t)))))
|
||||
|
||||
#(define (boernel-stats)
|
||||
(let (
|
||||
(songs (map (lambda (song) (symbol->string (car song))) (alist-delete 'emptyPage song-list)))
|
||||
@ -216,7 +209,7 @@ includeOnce =
|
||||
;(string-join songs "\n")
|
||||
"Nicht inkludiert:"
|
||||
opticalline
|
||||
(string-join (sort-list (lset-difference string=? (files-in-directory "../../lieder") songs) string<?) "\n")
|
||||
(string-join (sort-list (lset-difference string=? (files-in-directory (ly:format "../../~a" songPath)) songs) string<?) "\n")
|
||||
opticalline
|
||||
) "\n" )
|
||||
)))
|
||||
|
Reference in New Issue
Block a user