2006-10-04 Han-Wen Nienhuys <hanwen@lilypond.org>
+ * scm/backend-library.scm: update email address.
+
* Documentation/topdocs/NEWS.tely (Top): add duration-log override
example.
;;;; source file of the GNU LilyPond music typesetter
;;;;
;;;; (c) 2005--2006 Jan Nieuwenhuizen <janneke@gnu.org>
-;;;; Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; backend helpers.
;;;; source file of the GNU LilyPond music typesetter
;;;;
;;;; (c) 1998--2006 Jan Nieuwenhuizen <janneke@gnu.org>
-;;;; Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; Han-Wen Nienhuys <hanwen@xs4all.nl>
;;; Note: this file can't be used without LilyPond executable
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2000--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2000--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; source file of the GNU LilyPond music typesetter
;;;;
;;;; (c) 2000--2006 Jan Nieuwenhuizen <janneke@gnu.org>
-;;;; Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; Han-Wen Nienhuys <hanwen@xs4all.nl>
(define (natural-chord-alteration p)
"Return the natural alteration for step P."
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Jan Nieuwenhuizen <janneke@gnu.org>
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Jan Nieuwenhuizen <janneke@gnu.org>
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Jan Nieuwenhuizen <janneke@gnu.org>
(define (define-grob-property symbol type? description)
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Jan Nieuwenhuizen <janneke@gnu.org>
;;;; distances are given in line-thickness (thicknesses) and
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2000--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2000--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Jan Nieuwenhuizen <janneke@gnu.org>
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Jan Nieuwenhuizen <janneke@gnu.org>
(define (music-property-description symbol type? description)
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Jan Nieuwenhuizen <janneke@gnu.org>
;; TODO: should link back into user manual.
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2000--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2000--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Jan Nieuwenhuizen <janneke@gnu.org>
(define (interface-doc-string interface grob-description)
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Jan Nieuwenhuizen <janneke@gnu.org>
(use-modules
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Jan Nieuwenhuizen <janneke@gnu.org>
(define (doc-markup-function func)
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Jan Nieuwenhuizen <janneke@gnu.org>
(define (music-props-doc)
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2000--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2000--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Jan Nieuwenhuizen <janneke@gnu.org>
(define (engraver-makes-grob? name-symbol grav)
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2000--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2000--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Jan Nieuwenhuizen <janneke@gnu.org>
;;; File entry point for generated documentation
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2000--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2000--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Jan Nieuwenhuizen <janneke@gnu.org>
(use-modules (oop goops)
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2005--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2005--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
(define cache-hash-tab (make-hash-table 11))
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
(define-module (scm framework-eps))
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
(define-module (scm framework-ps))
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
(define-module (scm framework-tex)
#:export (output-framework-tex
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
(define-module (scm framework-texstr)
#:export (output-framework-tex
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; 2006 Nicolas Sceaux <nicolas.sceaux@free.fr>
(define-module (scm layout-page-dump)
;;;; source file of the GNU LilyPond music typesetter
;;;;
;;;; (c) 2004--2006 Jan Nieuwenhuizen <janneke@gnu.org>
-;;;; Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; Han-Wen Nienhuys <hanwen@xs4all.nl>
(define-module (scm layout-page-layout)
#:use-module (srfi srfi-1)
;;;; source file of the GNU LilyPond music typesetter
;;;;
;;;; (c) 1998--2006 Jan Nieuwenhuizen <janneke@gnu.org>
-;;;; Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; Han-Wen Nienhuys <hanwen@xs4all.nl>
(define-public X 0)
;;
+(define-public (string-encode-integer i)
+ (cond
+ ((= i 0) "o")
+ ((< i 0) (string-append "n" (string-encode-integer (- i))))
+ (else (string-append
+ (make-string 1 (integer->char (+ 65 (modulo i 26))))
+ (string-encode-integer (quotient i 26))))))
(define-public (ly:numbers->string lst)
(string-join (map ly:number->string lst) " "))
;;;; source file of the GNU LilyPond music typesetter
;;;;
;;;; (c) 1998--2006 Jan Nieuwenhuizen <janneke@gnu.org>
-;;;; Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; Han-Wen Nienhuys <hanwen@xs4all.nl>
(define (define-scheme-options)
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2003--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2003--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
"
Internally markup is stored as lists, whose head is a function.
;;;; source file of the GNU LilyPond music typesetter
;;;;
;;;; (c) 1998--2006 Jan Nieuwenhuizen <janneke@gnu.org>
-;;;; Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; Han-Wen Nienhuys <hanwen@xs4all.nl>
;; (use-modules (ice-9 optargs))
;;;; source file of the GNU LilyPond music typesetter
;;;;
;;;; (c) 1998--2006 Jan Nieuwenhuizen <janneke@gnu.org>
-;;;; Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; Han-Wen Nienhuys <hanwen@xs4all.nl>
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; general
+
+(define-public (make-stencil-boxer thickness padding callback)
+
+ "Return function that adds a box around the grob passed as argument."
+ (lambda (grob)
+
+ (box-stencil (callback grob) thickness padding)))
+
+(define-public (make-stencil-circler thickness padding callback)
+ "Return function that adds a circle around the grob passed as argument."
+
+ (lambda (grob) (circle-stencil (callback grob) thickness padding)))
+
+(define-public (print-circled-text-callback grob)
+ (let* ((text (ly:grob-property grob 'text))
+
+ (layout (ly:grob-layout grob))
+ (defs (ly:output-def-lookup layout 'text-font-defaults))
+ (props (ly:grob-alist-chain grob defs))
+ (circle (ly:text-interface::interpret-markup
+ layout props (make-circle-markup text))))
+ circle))
+
+
(define-public (event-cause grob)
(let*
((cause (ly:grob-property grob 'cause)))
(else #f))))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-;; note heads
-
-(define-public (note-head::calc-duration-log grob)
- (ly:duration-log
- (ly:event-property (event-cause grob) 'duration)))
-
-(define-public (dots::calc-dot-count grob)
- (ly:duration-dot-count
- (ly:event-property (event-cause grob) 'duration)))
-
-;; The TabNoteHead stem attachment function.
-(define (note-head::calc-tablature-stem-attachment grob)
- (cons 0.0 1.35))
+;; tablature
;; The TabNoteHead tablatureFormat callback.
;; Compute the text grob-property
(define-public (four-string-banjo tuning)
(reverse (cdr (reverse tuning))))
-;;; end of tablature functions
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; note heads
-(define-public (make-stencil-boxer thickness padding callback)
+(define-public (note-head::calc-duration-log grob)
+ (ly:duration-log
+ (ly:event-property (event-cause grob) 'duration)))
- "Return function that adds a box around the grob passed as argument."
- (lambda (grob)
-
- (box-stencil (callback grob) thickness padding)))
+(define-public (dots::calc-dot-count grob)
+ (ly:duration-dot-count
+ (ly:event-property (event-cause grob) 'duration)))
-(define-public (make-stencil-circler thickness padding callback)
- "Return function that adds a circle around the grob passed as argument."
- (lambda (grob) (circle-stencil (callback grob) thickness padding)))
+(define (note-head::calc-tablature-stem-attachment grob)
+ (cons 0.0 1.35))
-(define-public (arg->string arg)
- (cond ((number? arg) (ly:inexact->string arg 10))
- ((string? arg) (string-append "\"" arg "\""))
- ((symbol? arg) (string-append "\"" (symbol->string arg) "\""))))
-(define-public (print-circled-text-callback grob)
- (let* ((text (ly:grob-property grob 'text))
-
- (layout (ly:grob-layout grob))
- (defs (ly:output-def-lookup layout 'text-font-defaults))
- (props (ly:grob-alist-chain grob defs))
- (circle (ly:text-interface::interpret-markup
- layout props (make-circle-markup text))))
- circle))
;; silly, use alist?
(define-public (note-head::calc-glyph-name grob)
'(1.0 . 0.0))
-(define-public (string-encode-integer i)
- (cond
- ((= i 0) "o")
- ((< i 0) (string-append "n" (string-encode-integer (- i))))
- (else (string-append
- (make-string 1 (integer->char (+ 65 (modulo i 26))))
- (string-encode-integer (quotient i 26))))))
+
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; bar numbers
(define-public ((every-nth-bar-number-visible n) barnum) (= 0 (modulo barnum n)))
(define-public (first-bar-number-invisible barnum) (> barnum 1))
-;; See documentation of ly:item::visibility-lambda-
+;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
+;; break visibility
+
(define-public begin-of-line-visible
#(#f #f #t))
(define-public end-of-line-visible
;;;; source file of the GNU LilyPond music typesetter
;;;;
;;;; (c) 1998--2006 Jan Nieuwenhuizen <janneke@gnu.org>
-;;;; Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Note: currently misused as testbed for titles with markup, see
;;;; input/test/title-markup.ly
;;;; source file of the GNU LilyPond music typesetter
;;;;
;;;; (c) 1998--2006 Jan Nieuwenhuizen <janneke@gnu.org>
-;;;; Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; Han-Wen Nienhuys <hanwen@xs4all.nl>
;; The public interface is tight.
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
(define-module (scm output-texstr))
(define this-module (current-module))
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
(define-public (set-paper-dimension-variables mod)
(module-define! mod 'dimension-variables
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;; (name . (glyph clef-position octavation))
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;; todo: figure out how to make module,
;; without breaking nested ly scopes
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2004--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
(map
(lambda (sym)
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2000--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2000--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
(set! default-script-alist
(append
;;;; source file of the GNU LilyPond music typesetter
;;;;
;;;; (c) 1998--2006 Jan Nieuwenhuizen <janneke@gnu.org>
-;;;; Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; Han-Wen Nienhuys <hanwen@xs4all.nl>
(define standalone (not (defined? 'ly:gulp-file)))
;;(write standalone (current-error-port))
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2003--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2003--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
(define-public (stack-stencils axis dir padding stils)
"Stack stencils STILS in direction AXIS, DIR, using PADDING."
;;;; source file of the GNU LilyPond music typesetter
;;;;
;;;; (c) 2004--2006 Jan Nieuwenhuizen <janneke@gnu.org>
-;;;; Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; Han-Wen Nienhuys <hanwen@xs4all.nl>
(define-public (layout-extract-page-properties layout)
(list (append `((line-width . ,(ly:paper-get-number
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 2003--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 2003--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Jan Nieuwenhuizen <janneke@gnu.org>
(use-modules (ice-9 regex)
;;;;
;;;; source file of the GNU LilyPond music typesetter
;;;;
-;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+;;;; (c) 1998--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
;;;; Jan Nieuwenhuizen <janneke@gnu.org>
;; metronome marks