]> git.donarmstrong.com Git - lilypond.git/blob - scm/music-documentation-lib.scm
release: 1.3.148
[lilypond.git] / scm / music-documentation-lib.scm
1
2
3 (define (music-property->texi sym)
4   (let* ((name (symbol->string sym))
5         (type (object-property sym 'music-type?))
6         (typename (type-name type))
7         (desc (object-property sym 'music-doc)))
8
9     (cons (string-append "@code{" name "} "
10                        "(" typename ")"
11                        ": "
12                        )
13           desc)))
14
15 (define (document-music name)
16   (let* (
17        (ps (sort (map symbol->string all-music-properties) string<?))
18        (descs (map (lambda (prop)
19                      (music-property->texi (string->symbol prop)))
20                    ps))
21        (texi (description-list->texi descs))
22        )
23     
24     (string-append
25      (node name)
26      (texi-section 1 name #f)
27      texi)
28   ))
29   
30