]> git.donarmstrong.com Git - lilypond.git/blob - scm/documentation-generate.scm
Merge master into nested-bookparts
[lilypond.git] / scm / documentation-generate.scm
1 ;;;; generate-documentation.scm -- Generate documentation
2 ;;;;
3 ;;;; source file of the GNU LilyPond music typesetter
4 ;;;; 
5 ;;;; (c) 2000--2007 Han-Wen Nienhuys <hanwen@xs4all.nl>
6 ;;;; Jan Nieuwenhuizen <janneke@gnu.org>
7
8 ;;; File entry point for generated documentation
9 ;;; Running LilyPond on this file generates the documentation
10
11 ;;(set-debug-cell-accesses! 5000)
12
13 ;;;;;;;;;;;;;;;;
14 ;;;;;;;;;;;;;;;; TODO : make modules of these!
15 ;;;;;;;;;;;;;;;;
16
17 ;; todo: naming: grob vs. layout property
18
19 (map ly:load '("documentation-lib.scm"
20                "document-functions.scm"
21                "document-translation.scm"
22                "document-music.scm"
23                "document-identifiers.scm"
24                "document-backend.scm"
25                "document-markup.scm"))
26
27 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
28
29 (display
30  (slot-ref (all-scheme-functions-doc) 'text)
31  (open-output-file "scheme-functions.tely"))
32
33 ;;(display 
34 ;; (markup-doc-string)
35 ;; (open-output-file "markup-commands.tely"))
36
37 (call-with-output-file "markup-commands.tely"
38   (lambda (port)
39     (dump-node (markup-doc-node) port 2)))
40
41 (call-with-output-file "markup-list-commands.tely"
42   (lambda (port)
43     (dump-node (markup-list-doc-node) port 2)))
44
45 (display 
46  (identifiers-doc-string)
47  (open-output-file "identifiers.tely"))
48
49
50 (display
51  (backend-properties-doc-string all-user-grob-properties)
52  (open-output-file "layout-properties.tely"))
53
54 (display
55  (translation-properties-doc-string all-user-translation-properties)
56  (open-output-file "context-properties.tely"))
57
58 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
59
60 (define file-name "lilypond-internals")
61 (define outname (string-append file-name ".texi"))
62
63 (define out-port (open-output-file outname))
64
65 (writing-wip outname)
66
67 (display
68  (string-append
69   (texi-file-head "LilyPond program-reference" file-name
70                   "(lilypond/lilypond-internals.info)")
71   "
72
73 @include macros.texi
74
75 @ignore
76 @omftitle LilyPond internals
77 @omfcreator Han-Wen Nienhuys and Jan Nieuwenhuizen
78 @omfdescription Programmer's reference of the LilyPond music engraving system
79 @omftype user's guide
80 @omflanguage English
81 @omfcategory Applications|Publishing
82 @end ignore
83
84 @iftex
85 @afourpaper
86 @c don't replace quotes with directed quotes
87 @tex
88 \\gdef\\SETtxicodequoteundirected{Foo}
89 \\gdef\\SETtxicodequotebacktick{Bla}
90 @end tex
91 @end iftex
92
93 @finalout
94
95 @titlepage
96 @title LilyPond
97 @subtitle The music typesetter
98 @titlefont{Internals Reference}
99 @author The LilyPond development team
100
101 Copyright @copyright{} 1999--2008 by the authors
102
103 @vskip 20pt
104
105 For LilyPond version @version{}
106 @end titlepage
107
108 @contents
109
110 @ifnottex")
111  out-port)
112
113 (define top-node
114   (make <texi-node>
115     #:name "GNU LilyPond -- Internals Reference"
116     #:text
117     (string-append  "@end ifnottex
118
119 @ifhtml
120 This document is also available as a
121 @uref{source/Documentation/user/lilypond-internals.pdf,PDF} and as
122 @uref{source/Documentation/user/lilypond-internals-big-page.html,one big page}.
123 @end ifhtml
124
125 This is the Internals Reference (IR) for version "
126                     (lilypond-version)
127                     " of LilyPond, the GNU music typesetter.")
128
129     #:children
130     (list
131      (music-doc-node)
132      (translation-doc-node)
133      (backend-doc-node)
134      (all-scheme-functions-doc)
135      (make <texi-node>
136        #:appendix #t
137        #:name "Indices"
138        #:text "
139 @appendixsec Concept index
140
141 @printindex cp
142
143 @appendixsec Function index
144
145 @printindex fn
146
147 \n@bye"))))
148
149 (dump-node top-node out-port 0)
150 (newline (current-error-port))