From: Han-Wen Nienhuys Date: Sun, 10 Jun 2007 04:10:06 +0000 (-0300) Subject: use simple-format for stencil.scm X-Git-Tag: release/2.11.27-1~15^2~4^2~1 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=c2fb0a612743e63154edc1bc2944f90320d082e7;p=lilypond.git use simple-format for stencil.scm --- diff --git a/buildscripts/output-distance.py b/buildscripts/output-distance.py index ea82a93de9..d52f99879c 100644 --- a/buildscripts/output-distance.py +++ b/buildscripts/output-distance.py @@ -577,8 +577,6 @@ class SignatureFileLink (FileLink): return d + orphan_distance - - def add_file_compare (self, f1, f2): system_index = [] diff --git a/scm/stencil.scm b/scm/stencil.scm index bd4e4e44c6..db35a5ecc5 100644 --- a/scm/stencil.scm +++ b/scm/stencil.scm @@ -238,7 +238,7 @@ encloses the contents. (if (not (interval-sane? extent)) (set! annotation (interpret-markup layout text-props - (make-simple-markup (format "~a: NaN/inf" name)))) + (make-simple-markup (simple-format #f "~a: NaN/inf" name)))) (let ((text-stencil (interpret-markup layout text-props (markup #:whiteout #:simple name))) @@ -249,9 +249,9 @@ encloses the contents. ((interval-empty? extent) (format "empty")) (is-length - (format "~$" (interval-length extent))) + (ly:format "~$" (interval-length extent))) (else - (format "(~$,~$)" + (ly:format "(~$,~$)" (car extent) (cdr extent))))))) (arrows (ly:stencil-translate-axis (dimension-arrows (cons 0 (interval-length extent))) @@ -282,7 +282,7 @@ encloses the contents. (factor (exact->inexact (/ size bbox-size))) (scaled-bbox (map (lambda (x) (* factor x)) bbox)) - (clip-rect-string (format + (clip-rect-string (ly:format "~a ~a ~a ~a rectclip" (list-ref bbox 0) (list-ref bbox 1) @@ -295,7 +295,7 @@ encloses the contents. (list 'embedded-ps (string-append - (format + (ly:format " gsave currentpoint translate @@ -326,7 +326,7 @@ grestore (if (pair? paper-systems) (begin (let* - ((outname (format "~a-~a.signature" basename count)) ) + ((outname (simple-format #f "~a-~a.signature" basename count)) ) (ly:message "Writing ~a" outname) (write-system-signature outname (car paper-systems)) @@ -367,10 +367,10 @@ grestore (define (raw-string expr) "escape quotes and slashes for python consumption" - (regexp-substitute/global #f "[@\n]" (format "~a" expr) 'pre " " 'post)) + (regexp-substitute/global #f "[@\n]" (simple-format #f "~a" expr) 'pre " " 'post)) (define (raw-pair expr) - (format "~a ~a" + (simple-format #f "~a ~a" (car expr) (cdr expr))) (define (found-grob expr) @@ -393,7 +393,7 @@ grestore rest) ""))) - (format output + (simple-format output "~a@~a@~a@~a@~a\n" (cdr (assq 'name (ly:grob-property grob 'meta) )) (raw-string location) @@ -425,7 +425,7 @@ grestore (if (ly:grob? system-grob) (begin - (display (format "# Output signature\n# Generated by LilyPond ~a\n" (lilypond-version)) + (display (simple-format #f "# Output signature\n# Generated by LilyPond ~a\n" (lilypond-version)) output) (interpret-for-signature found-grob (lambda (x) #f) (ly:stencil-expr