]> git.donarmstrong.com Git - lilypond.git/blob - scm/documentation-generate.scm
Docs: reorganize documentation directory structure
[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--2009 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                "lily-sort.scm"
21                "document-functions.scm"
22                "document-translation.scm"
23                "document-music.scm"
24                "document-identifiers.scm"
25                "document-backend.scm"
26                "document-markup.scm"))
27
28 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
29
30 (display
31  (slot-ref (all-scheme-functions-doc) 'text)
32  (open-output-file "scheme-functions.tely"))
33
34 ;;(display 
35 ;; (markup-doc-string)
36 ;; (open-output-file "markup-commands.tely"))
37
38 (call-with-output-file "markup-commands.tely"
39   (lambda (port)
40     (dump-node (markup-doc-node) port 2)))
41
42 (call-with-output-file "markup-list-commands.tely"
43   (lambda (port)
44     (dump-node (markup-list-doc-node) port 2)))
45
46 (display 
47  (identifiers-doc-string)
48  (open-output-file "identifiers.tely"))
49
50
51 (display
52  (backend-properties-doc-string all-user-grob-properties)
53  (open-output-file "layout-properties.tely"))
54
55 (display
56  (translation-properties-doc-string all-user-translation-properties)
57  (open-output-file "context-properties.tely"))
58
59 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
60
61 (define file-name "internals")
62 (define outname (string-append file-name ".texi"))
63
64 (define out-port (open-output-file outname))
65
66 (writing-wip outname)
67
68 (display
69  (string-append
70   (texi-file-head "LilyPond Internals Reference" file-name
71                   "(lilypond-internals.info)")
72   "
73
74 @include macros.itexi
75
76 @ignore
77 @omftitle LilyPond internals
78 @omfcreator Han-Wen Nienhuys and Jan Nieuwenhuizen
79 @omfdescription Programmer's reference of the LilyPond music engraving system
80 @omftype user's guide
81 @omflanguage English
82 @omfcategory Applications|Publishing
83 @end ignore
84
85 @iftex
86 @afourpaper
87 @end iftex
88
89 @finalout
90
91 @titlepage
92 @title LilyPond
93 @subtitle The music typesetter
94 @titlefont{Internals Reference}
95 @author The LilyPond development team
96
97 Copyright @copyright{} 1999--2009 by the authors
98
99 @vskip 20pt
100
101 For LilyPond version @version{}
102 @end titlepage
103
104 @contents
105
106 @ifnottex")
107  out-port)
108
109 (define top-node
110   (make <texi-node>
111     #:name "GNU LilyPond -- Internals Reference"
112     #:text
113     (string-append  "@end ifnottex
114
115 @ifhtml
116 @ifclear bigpage
117 This document is also available as a
118 @uref{source/Documentation/internals.pdf,PDF} and as
119 @uref{source/Documentation/internals-big-page.html,one big page}.
120 @end ifclear
121 @ifset bigpage
122 This document is also available as a
123 @uref{source/Documentation/internals.pdf,PDF} and as a
124 @uref{source/Documentation/internals/index.html,HTML indexed multiple pages}.
125 @end ifset
126 @end ifhtml
127
128 This is the Internals Reference (IR) for version "
129                     (lilypond-version)
130                     " of LilyPond, the GNU music typesetter.")
131
132     #:children
133     (list
134      (music-doc-node)
135      (translation-doc-node)
136      (backend-doc-node)
137      (all-scheme-functions-doc)
138      (make <texi-node>
139        #:appendix #t
140        #:name "Indices"
141        #:text "
142 @appendixsec Concept index
143
144 @printindex cp
145
146 @appendixsec Function index
147
148 @printindex fn
149
150 \n@bye"))))
151
152 (dump-node top-node out-port 0)
153 (newline (current-error-port))