]> git.donarmstrong.com Git - lilypond.git/blob - scm/documentation-generate.scm
*** empty log message ***
[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--2005 Han-Wen Nienhuys <hanwen@cs.uu.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-backend.scm"
24                "document-markup.scm"))
25
26 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
27
28 (display
29  (slot-ref (all-scheme-functions-doc) 'text)
30  (open-output-file "scheme-functions.tely"))
31
32 (display 
33  (markup-doc-string)
34  (open-output-file "markup-commands.tely"))
35
36
37 (display
38  (backend-properties-doc-string all-user-grob-properties)
39  (open-output-file "layout-properties.tely"))
40
41 (display
42  (translation-properties-doc-string all-user-translation-properties)
43  (open-output-file "context-properties.tely"))
44
45 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
46
47 (define file-name "lilypond-internals")
48 (define outname (string-append file-name ".texi"))
49
50 (define out-port (open-output-file outname))
51
52 (writing-wip outname)
53
54 (display
55  (string-append
56   (texi-file-head "LilyPond program-reference" file-name
57                   "(lilypond-internals.info)")
58   "
59
60 @ifhtml
61 @macro usermanref{NAME}
62 @uref{../lilypond/\\NAME\\.html,\\NAME\\}
63 @cindex \\NAME\\
64 @end macro
65 @end ifhtml
66
67 @ifinfo
68 @macro usermanref{NAME}
69 @ref{\\NAME\\,,,lilypond/lilypond}
70 @cindex \\NAME\\
71 @end macro
72 @end ifinfo
73
74 @iftex
75 @macro usermanref{NAME}
76 @ref{\\NAME\\}@c
77 @end macro
78 @end iftex
79
80 @ifhtml
81 @macro glossaryref{NAME}
82 @uref{../music-glossary/\\NAME\\.html,\\NAME\\}
83 @cindex \\NAME\\
84 @end macro
85 @end ifhtml
86
87 @ifinfo
88 @macro glossaryref{NAME}
89 @inforef{\\NAME\\,,lilypond/music-glossary}
90 @cindex \\NAME\\
91 @end macro
92 @end ifinfo
93
94
95 @macro internalsref{NAME}
96 @ref{\\NAME\\}
97 @end macro
98
99 @ifhtml
100
101 @macro inputfileref{DIR,NAME}
102 @uref{../../../../\\DIR\\/out-www/collated-files.html#\\NAME\\,@file{\\DIR\\/\\NAME\\}}@c
103 @end macro
104
105 @end ifhtml
106
107 @ifinfo
108
109 @macro inputfileref{DIR,NAME}
110 @file{\\DIR\\/\\NAME\\}
111 @end macro
112
113 @end ifinfo
114
115 @iftex
116 @macro inputfileref{DIR,NAME}@c
117 @file{\\DIR\\/\\NAME\\}@c
118 @end macro
119 @end iftex
120
121
122
123 @ignore
124 @omftitle LilyPond internals
125 @omfcreator Han-Wen Nienhuys and Jan Nieuwenhuizen
126 @omfdescription Programmer's reference of the LilyPond music engraving system
127 @omftype user's guide
128 @omflanguage English
129 @omfcategory Applications|Publishing
130 @end ignore
131
132
133 ")
134  out-port)
135
136 (define top-node
137   (make <texi-node>
138     #:name "Top"
139     #:text 
140     (string-append  "This is the program reference for LilyPond version " (lilypond-version))
141
142     #:children
143     (list
144      (music-doc-node)
145      (translation-doc-node)
146      (backend-doc-node)
147      (all-scheme-functions-doc)
148      (make <texi-node>
149        #:name "Indexes"
150        #:text "
151 @unnumbered Concept index
152
153 @printindex cp
154
155 @unnumbered Variable index
156
157 @printindex vr
158
159 @unnumbered Function index
160
161 @printindex fn
162
163 \n@bye"))))
164
165 (dump-node top-node out-port 0)
166 (newline (current-error-port))
167
168
169
170