]> git.donarmstrong.com Git - lilypond.git/blob - scm/safe-lily.scm
Doc: CG: add warning about non-sequential reading.
[lilypond.git] / scm / safe-lily.scm
1 ;;;; This file is part of LilyPond, the GNU music typesetter.
2 ;;;;
3 ;;;; Copyright (C) 2004--2009 Han-Wen Nienhuys <hanwen@xs4all.nl>
4 ;;;;
5 ;;;; LilyPond is free software: you can redistribute it and/or modify
6 ;;;; it under the terms of the GNU General Public License as published by
7 ;;;; the Free Software Foundation, either version 3 of the License, or
8 ;;;; (at your option) any later version.
9 ;;;;
10 ;;;; LilyPond is distributed in the hope that it will be useful,
11 ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
12 ;;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
13 ;;;; GNU General Public License for more details.
14 ;;;;
15 ;;;; You should have received a copy of the GNU General Public License
16 ;;;; along with LilyPond.  If not, see <http://www.gnu.org/licenses/>.
17
18 (map
19  (lambda (sym)
20    (set! safe-objects (cons (cons sym (primitive-eval sym))
21                             safe-objects)))
22  '(ly:add-interface
23    ly:moment-add
24    ly:all-grob-interfaces
25    ly:all-output-backend-commands
26    ly:all-stencil-expressions
27    ly:bracket
28    ly:context-find
29    ly:context-id
30    ly:context-name
31    ly:context-parent
32    ly:context-property
33    ly:context-property-where-defined
34    ly:context-pushpop-property
35    ly:context-set-property!
36    ly:context-unset-property
37    ly:context?
38    ly:dimension?
39    ly:dir?
40    ly:moment-div
41    ly:duration-dot-count
42    ly:duration-factor
43    ly:duration-log
44    ly:duration<?
45    ly:duration?
46    ly:error
47    ly:export
48    ly:font-get-glyph
49    ly:font-design-size
50    ly:font-file-name
51    ly:font-magnification
52    ly:font-metric?
53    ly:font-name
54    ly:format-output
55    ly:get-all-function-documentation
56    ly:get-all-translators
57    ly:get-glyph
58    ly:get-option
59    ly:grob-alist-chain
60    ly:grob-default-font
61    ly:grob-extent
62    ly:grob-original
63    ly:grob-layout
64    ly:grob-parent
65    ly:grob-property
66    ly:grob-script-priority-less
67    ly:grob-set-property!
68    ly:grob-staff-position
69    ly:grob-suicide!
70    ly:grob-system
71    ly:grob-translate-axis!
72    ly:grob?
73    ly:input-file-line-char-column
74    ly:input-location?
75    ly:input-message
76    ly:intlog2
77    ly:item-break-dir
78    ly:item?
79    ly:iterator?
80    ly:make-music
81    ly:make-duration
82    ly:make-moment
83    ly:make-music-function
84    ly:make-pitch
85    ly:make-stencil
86    ly:moment<?
87    ly:moment?
88    ly:moment-mul
89    ly:music-compress
90    ly:music-deep-copy
91    ly:music-duration-compress
92    ly:music-duration-length
93    ly:music-length
94    ly:music-list?
95    ly:music-mutable-properties
96    ly:music-property
97    ly:make-score
98    ly:music-set-property!
99    ly:music-transpose
100    ly:music?
101    ly:lily-parser?
102    ly:message
103    ly:number->string
104    ly:option-usage
105    ly:output-def-clone
106    ly:output-def-lookup
107    ly:output-def-scope
108    ly:output-description
109    ly:paper-book?
110    ly:prob-property
111    ly:output-def?
112    ly:paper-get-font
113    ly:paper-get-number
114    ly:paper-system?
115    ly:parser-parse-string
116    ly:pitch-alteration
117    ly:pitch-diff
118    ly:pitch-notename
119    ly:pitch-octave
120    ly:pitch-quartertones
121    ly:pitch-semitones
122    ly:pitch-steps
123    ly:pitch-transpose
124    ly:pitch<?
125    ly:pitch?
126    ly:position-on-line?
127    ly:round-filled-box
128    ly:run-translator
129    ly:set-option
130    ly:spanner-broken-into
131    ly:spanner-bound
132    ly:spanner?
133    ly:staff-symbol-line-thickness
134    ly:stencil-add
135    ly:stencil-aligned-to
136    ly:stencil-combine-at-edge
137    ly:stencil-expr
138    ly:stencil-extent
139    ly:stencil-translate
140    ly:stencil-translate-axis
141    ly:stencil?
142    ly:text-dimension
143    ly:translator-description
144    ly:translator-name
145    ly:translator?
146    ly:transpose-key-alist
147    ly:unit
148    ly:usage
149    ly:version
150    ly:warning
151
152    ;; FIXME: cannot change staff size in --safe-mode
153    ;;$defaultpaper
154    ;;$defaultmidi
155    ;;$defaultlayout
156
157    ly:accidental-interface::print
158    ly:arpeggio::print
159    ly:arpeggio::brew-chord-bracket
160    ly:bar-line::print
161    ly:breathing-sign::offset-callback
162    ly:clef::print
163    ly:cluster::print
164    ly:cluster-beacon::height
165    ly:custos::print
166    ly:dots::print
167    ly:hairpin::print
168    ly:hara-kiri-group-spanner::force-hara-kiri-callback
169    ly:hara-kiri-group-spanner::y-extent
170    ly:horizontal-bracket::print
171    ly:lyric-hyphen::print
172    ly:lyric-hyphen::set-spacing-rods
173    ly:key-signature-interface::print
174    ly:line-spanner::print
175    ly:lyric-extender::print
176    ly:measure-grouping::print
177    ly:mensural-ligature::brew-ligature-primitive
178    ly:mensural-ligature::print
179    ly:multi-measure-rest::percent
180    ly:multi-measure-rest::print
181    ly:multi-measure-rest::set-spacing-rods
182    ly:note-head::print
183    ly:ottava-bracket::print
184    ly:paper-column::print
185    ly:percent-repeat-item-interface::beat-slash
186    ly:percent-repeat-item-interface::double-percent
187    ly:piano-pedal-bracket::print
188    ly:rest::print
189    ly:script-interface::print
190    ly:slur::height
191    ly:slur::print
192    ly:spacing-spanner::set-springs
193    ly:span-bar::print
194    ly:spanner::set-spacing-rods
195    ly:staff-symbol::print
196    ly:staff-symbol-referencer::callback
197    ly:stem::height
198    ly:stem::offset-callback
199    ly:stem::print
200    ly:stem-tremolo::height
201    ly:stem-tremolo::print
202    ly:sustain-pedal::print
203    ly:system-start-delimiter::print
204    ly:text-interface::print
205    ly:tie::print
206    ly:time-signature::print
207    ly:tuplet-bracket::print
208    ly:vaticana-ligature::brew-ligature-primitive
209    ly:vaticana-ligature::print
210    ly:volta-bracket-interface::print
211    ))
212
213 (define-public (make-safe-lilypond-module)
214   (let* ((m (make-safe-module)))
215     (for-each (lambda (p) (module-define! m (car p) (cdr p))) safe-objects)
216     m))