]> git.donarmstrong.com Git - lilypond.git/blob - scm/documentation-generate.scm
Merge branch 'master' of ssh://kainhofer@git.sv.gnu.org/srv/git/lilypond into dev...
[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 (display 
38  (markup-list-doc-string)
39  (open-output-file "markup-list-commands.tely"))
40
41 (display 
42  (identifiers-doc-string)
43  (open-output-file "identifiers.tely"))
44
45
46 (display
47  (backend-properties-doc-string all-user-grob-properties)
48  (open-output-file "layout-properties.tely"))
49
50 (display
51  (translation-properties-doc-string all-user-translation-properties)
52  (open-output-file "context-properties.tely"))
53
54 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
55
56 (define file-name "lilypond-internals")
57 (define outname (string-append file-name ".texi"))
58
59 (define out-port (open-output-file outname))
60
61 (writing-wip outname)
62
63 (display
64  (string-append
65   (texi-file-head "LilyPond program-reference" file-name
66                   "(lilypond/lilypond-internals.info)")
67   "
68
69 @c NOTE: This is documentation-generate.scm, not macros.itexi
70
71
72 @ifhtml
73 @c ***** HTML *****
74
75 @ifset bigpage
76
77 @macro ruser{TEXT}
78 @ref{\\TEXT\\,,,lilypond-big-page,Notation Reference}
79 @cindex \\TEXT\\
80 @end macro
81
82 @macro glossaryref{TEXT}
83 @vindex \\TEXT\\
84 @ref{\\TEXT\\,,,music-glossary-big-page,Music Glossary}
85 @end macro
86
87 @end ifset
88
89 @ifclear bigpage
90
91 @macro ruser{NAME}
92 @ref{\\NAME\\,,,lilypond,Notation Reference}
93 @cindex \\NAME\\
94 @end macro
95
96 @macro glossaryref{NAME}
97 @ref{\\NAME\\,,,music-glossary,Music Glossary}
98 @cindex \\NAME\\
99 @end macro
100
101 @end ifclear
102
103 @macro inputfileref{DIR,NAME}
104 @uref{source/\\DIR\\/out-www/collated-files.html#\\NAME\\,@file{\\DIR\\/\\NAME\\}}@c
105 @end macro
106
107 @macro q{TEXT}
108 @html
109 &lsquo;\\TEXT\\&rsquo;
110 @end html
111 @end macro
112 @end ifhtml
113
114
115 @ifinfo
116 @c ***** info *****
117
118 @macro ruser{NAME}
119 @inforef{\\NAME\\,,,lilypond}
120 @cindex \\NAME\\
121 @end macro
122
123 @macro glossaryref{NAME}
124 @inforef{\\NAME\\,,lilypond/music-glossary}
125 @cindex \\NAME\\
126 @end macro
127
128 @macro inputfileref{DIR,NAME}
129 @file{\\DIR\\/\\NAME\\}
130 @end macro
131
132 @macro q{TEXT}
133 `\\TEXT\\'
134 @end macro
135 @end ifinfo
136
137
138 @iftex
139 @c ***** TeX *****
140
141 @macro ruser{NAME}
142 @ref{\\NAME\\}@c
143 @end macro
144
145 @macro inputfileref{DIR,NAME}@c
146 @file{\\DIR\\/\\NAME\\}@c
147 @end macro
148
149 @macro q{TEXT}
150 `\\TEXT\\'
151 @end macro
152 @end iftex
153
154
155 @macro internalsref{NAME}
156 @ref{\\NAME\\}
157 @end macro
158
159
160 @ignore
161 @omftitle LilyPond internals
162 @omfcreator Han-Wen Nienhuys and Jan Nieuwenhuizen
163 @omfdescription Programmer's reference of the LilyPond music engraving system
164 @omftype user's guide
165 @omflanguage English
166 @omfcategory Applications|Publishing
167 @end ignore
168
169 @contents
170 ")
171  out-port)
172
173 (define top-node
174   (make <texi-node>
175     #:name "Top"
176     #:text 
177     (string-append  "This is the program reference for version "
178                     (lilypond-version)
179                     " of LilyPond, the GNU music typesetter.")
180
181     #:children
182     (list
183      (music-doc-node)
184      (translation-doc-node)
185      (backend-doc-node)
186      (all-scheme-functions-doc)
187      (make <texi-node>
188        #:name "Indexes"
189        #:text "
190 @unnumbered Concept index
191
192 @printindex cp
193
194 @unnumbered Function index
195
196 @printindex fn
197
198 \n@bye"))))
199
200 (dump-node top-node out-port 0)
201 (newline (current-error-port))