]> git.donarmstrong.com Git - lilypond.git/blob - scm/document-markup.scm
release commit
[lilypond.git] / scm / document-markup.scm
1
2 (define (doc-markup-function func)
3   (let*
4       (
5        (doc-str  (procedure-documentation func) )
6        (f-name (symbol->string (procedure-name  func)))
7        (sig (object-property func 'markup-signature))
8        (sig-str (string-join (map type-name sig) " "))
9        )
10     
11     
12        
13   (string-append
14    "\n\n@b{"
15    f-name
16    "}\n\n@findex " f-name "\n"
17    "\n\n@i{Argument types}: " sig-str
18    (if (string? doc-str)
19        (string-append
20         "\n\n@i{Description}: \n\n"
21         doc-str)
22        "")
23    
24    
25   )))
26
27 (define (markup-function<? a b)
28   (string<? (symbol->string (procedure-name a)) (symbol->string (procedure-name b))))
29
30 (define (markup-doc-node)
31   (make <texi-node>
32     #:name "Markup functions"
33     #:desc "Definitions of the markup functions."
34
35
36     #:text (apply string-append
37                   
38                   "A @code{\\markup} mode command, eg. @code{bold}, is
39 coupled with a Scheme function (@code{bold-markup}) implementing the
40 formatting.  For use in Scheme, a function @code{make-bold-markup} is
41 also defined, which constructs a Markup expression.
42
43 This chapter describes all of the @code{...-markup} functions.
44
45 "
46
47                   (map doc-markup-function
48                        (sort markup-function-list markup-function<?) ))
49     ))
50
51