* lily/system.cc (get_line): plug leak.
* lily/paper-book.cc (pages): plug memory leaks: delete page array
and contents.
(stencil2line): plug leak.
* Documentation/user/changing-defaults.itely (Determining a grob
property): new node.
(Layout interfaces): new node.
(Navigating the program reference): new node.
2004-03-23 Han-Wen Nienhuys <hanwen@xs4all.nl>
+ * lily/main.cc (main_with_guile): switch debugging.
+
+ * lily/system.cc (get_line): plug leak.
+
+ * lily/paper-book.cc (pages): plug memory leaks: delete page array
+ and contents.
+ (stencil2line): plug leak.
+
* Documentation/user/changing-defaults.itely (Determining a grob
property): new node.
(Layout interfaces): new node.
* Fonts::
* Text markup::
* Global layout::
-* Font Size::
* Output details::
@end menu
* Navigating the program reference::
* Layout interfaces::
* Determining the grob property::
-* Determining a grob property::
@end menu
them are not user-serviceable (``Internal properties''), but others
are.
-@node Determining the grob property
-@subsection Determining the grob property
-
We have been talking of `the' @code{Fingering} object, but actually it
does not amount to much. The initialization file
@file{scm/define-grobs.scm} shows the soul of the `object',
variable settings, and the webpage is directly generated from this
definition.
-@node Determining a grob property
-@subsection Determining a grob property
+@node Determining the grob property
+@subsection Determining the grob property
+
Recall that we wanted to change the position of the @b{2} in
@internalsref{Fingering_engraver} plug-in says
@quotation
- Fingering_engraver is part of contexts: @dots{} @internalsref{Voice}
+ Fingering_engraver is part of contexts: @dots{} @b{@internalsref{Voice}}
@end quotation
* Font selection::
@end menu
+
+
@node Selecting font sizes
@subsection Selecting font sizes
@menu
+* Setting global staff size::
* Vertical spacing::
* Horizontal spacing::
+* Line breaking::
+* Page layout::
@end menu
+@node Setting global staff size
+@subsection Setting global staff size
+
+@cindex font size, setting
+@cindex staff size, setting
+@cindex @code{paper} file
+
+The Feta font provides musical symbols at eight different
+sizes. Each font is tuned for a different staff size: at smaller sizes
+the font gets heavier, to match the relatively heavier staff lines.
+The recommended font sizes are listed in the following table:
+
+@multitable @columnfractions .25 .25 .25 .25
+
+@item @b{font name}
+@tab @b{staff height (pt)}
+@tab @b{staff height (mm)}
+@tab @b{use}
+
+@item feta11
+@tab 11.22
+@tab 3.9
+@tab pocket scores
+
+@item feta13
+@tab 12.60
+@tab 4.4
+@tab
+
+@item feta14
+@tab 14.14
+@tab 5.0
+@tab
+
+@item feta16
+@tab 15.87
+@tab 5.6
+@tab
+
+@item feta18
+@tab 17.82
+@tab 6.3
+@tab song books
+
+@item feta20
+@tab 17.82
+@tab 7.0
+@tab standard parts
+
+@item feta23
+@tab 22.45
+@tab 7.9
+@tab
+
+@item feta20
+@tab 25.2
+@tab 8.9
+@tab
+@c modern rental material ?
+
+@end multitable
+
+These fonts are available in any sizes. The context property
+@code{fontSize} and the layout property @code{staff-space} (in
+@internalsref{StaffSymbol}) can be used to tune size for individual
+staves. The size of individual staves are relative to the global size,
+which can be set in the following manner:
+
+@example
+ #(set-global-staff-size 14)
+@end example
+
+This sets the global default size to 14pt staff height, and scales all
+fonts accordingly.
+
+@seealso
+
+This manual: @ref{Selecting font sizes}.
+
+
+
+@menu
+* Vertical spacing::
+* Horizontal spacing::
+* Line breaking::
+* Page layout::
+@end menu
+
@node Vertical spacing
@subsection Vertical spacing
-@node Font Size
-@section Font size
-
-@cindex font size, setting
-@cindex staff size, setting
-@cindex @code{paper} file
-
-The Feta font provides musical symbols at eight different
-sizes. Each font is tuned for a different staff size: at smaller sizes
-the font gets heavier, to match the relatively heavier staff lines.
-The recommended font sizes are listed in the following table:
-
-@multitable @columnfractions .25 .25 .25 .25
-
-@item @b{font name}
-@tab @b{staff height (pt)}
-@tab @b{staff height (mm)}
-@tab @b{use}
-
-@item feta11
-@tab 11.22
-@tab 3.9
-@tab pocket scores
-
-@item feta13
-@tab 12.60
-@tab 4.4
-@tab
-
-@item feta14
-@tab 14.14
-@tab 5.0
-@tab
-
-@item feta16
-@tab 15.87
-@tab 5.6
-@tab
-
-@item feta18
-@tab 17.82
-@tab 6.3
-@tab song books
-
-@item feta20
-@tab 17.82
-@tab 7.0
-@tab standard parts
-
-@item feta23
-@tab 22.45
-@tab 7.9
-@tab
-
-@item feta20
-@tab 25.2
-@tab 8.9
-@tab
-@c modern rental material ?
-
-@end multitable
-
-These fonts are available in any sizes. The context property
-@code{fontSize} and the layout property @code{staff-space} (in
-@internalsref{StaffSymbol}) can be used to tune size for individual
-staves. The size of individual staves are relative to the global size,
-which can be set in the following manner:
-
-@example
- #(set-global-staff-size 14)
-@end example
-
-This sets the global default size to 14pt staff height, and scales all
-fonts accordingly.
-
-@seealso
-
-This manual: @ref{Selecting font sizes}.
-
-
@menu
* Line breaking::
* Page layout::
version, the format
@code{texi-html} must be used.
-@ignore
-@c broken
@item @option{-F @var{filter}}, @option{--filter=@var{filter}}
Pipe snippets through @var{filter}.
@example
lilypond-book --filter='convert-ly --from=2.0.0' my-book.tely
@end example
-@end ignore
@item @option{--help}
Print a short help message.
The command @code{\setEasyHeads} overrides settings for the
@internalsref{NoteHead} object. To make the letters readable, it has
to be printed in a large font size. To print with a larger font, see
-@ref{Font Size}.
+@ref{Setting global staff size}.
@cindex Xdvi
@cindex ghostscript
PACKAGE_NAME=LilyPond
MAJOR_VERSION=2
MINOR_VERSION=1
-PATCH_LEVEL=33
-MY_PATCH_LEVEL=hwn1
+PATCH_LEVEL=34
+MY_PATCH_LEVEL=
virtual SCM process (String);
private:
- Protected_scm score_;
+ Protected_scm systems_;
void preprocess ();
void calc_idealspacing ();
class Staff_symbol_referencer
{
public:
-
static bool has_interface (Grob*);
static bool ugly_hack (Grob*);
static void set_position (Grob*,Real);
Leading are the lead strips between the sticks (lines) of
typeface. ie. leading is vertical space.
*/
-
static Real line_thickness (Grob*);
static Real staff_space (Grob*);
- static Grob * get_staff_symbol (Grob*);
+ static Grob *get_staff_symbol (Grob*);
static bool on_staffline (Grob*);
static bool on_staffline (Grob*,int);
static int line_count (Grob*);
bool first = true;
while (char const *arg = option_parser->get_next_arg ())
{
-
#if 0
/* Code to debug memory leaks. Cannot call from within .ly
since then we get the protects from the parser state too. */
scm_gc ();
scm_call_0 (ly_scheme_function ("dump-gc-protects"));
#endif
-
do_one_file (arg);
first = false;
}
stil->extent (Y_AXIS).length ());
Paper_line *pl = new Paper_line (dim, scm_cons (stil->smobbed_copy (),
SCM_EOL), is_title);
- return pl->self_scm ();
+
+ return scm_gc_unprotect_object (pl->self_scm ());
}
/* Simplistic page interface */
(*pages)[i]->output (out, i + 1 == page_count);
out->output_scheme (scm_list_1 (ly_symbol2scm ("end-output")));
+
+ /*
+ Ugh
+ */
+ for (int i =pages->size (); i--;)
+ delete pages->elem(i);
+ delete pages;
+
+
progress_indication ("\n");
}
SCM all = lines ();
SCM proc = paper->get_scmvar ("page-breaking");
- SCM breaks = scm_apply_0 (proc, scm_list_n (all,
- gh_double2scm (height_),
- gh_double2scm (text_height),
- gh_double2scm (-copy_height),
- gh_double2scm (-tag_height),
- SCM_UNDEFINED));
+ SCM breaks = scm_apply_0 (proc, scm_list_n (all, gh_double2scm (height_),
+ gh_double2scm (text_height),
+ gh_double2scm (-copy_height),
+ gh_double2scm (-tag_height),
+ SCM_UNDEFINED));
/* Copyright on first page. */
if (unsmob_stencil (copyright_))
/* Tagline on last page. */
if (unsmob_stencil (tagline_))
page->tagline_ = tagline_;
+
return pages;
}
{
paper_ = 0;
system_ = 0;
- score_ = SCM_EOL;
}
Paper_score::Paper_score (Paper_score const &s)
if (!system_)
system_ = system;
- score_ = gh_cons (system->self_scm (), score_);
+ systems_ = gh_cons (system->self_scm (), systems_);
system->pscore_ = this;
scm_gc_unprotect_object (system->self_scm ());
progress_indication ("\n");
/* Only keep result stencils in lines_, *title_; delete all grobs. */
- score_ = SCM_EOL;
+ systems_ = SCM_EOL;
return lines;
}
/*
must copy the stencil, for we cannot change the stencil
cached in G.
- */
+ */
SCM my_stencil = stil->smobbed_copy ();
unsmob_stencil (my_stencil)->translate (o + extra);
stencils = scm_cons (my_stencil, stencils);
Interval y (extent (this, Y_AXIS));
Paper_line *pl = new Paper_line (Offset (x.length (), y.length ()),
stencils);
+
+ scm_gc_unprotect_object (pl->self_scm ());
return pl->self_scm ();
}
Syntax
-\applyoutput FUNC
+\\applyoutput FUNC
arguments to func are 1. the grob, 2. the originating context,
3. context where FUNC is called.
(eg (find-engraver-by-name name ))
)
- (cons (symbol->string name )
+ (cons (string-append "@code{" (ref-ify (symbol->string name)) "}")
(engraver-doc-string eg #f)
)
))
#:text
(string-append
desc
- "\n\n This context is also known as: \n\n"
- (human-listify aliases)
+ (if (pair? aliases)
+ (string-append "\n\n This context is also known as: \n\n"
+ (human-listify aliases))
+ "")
"\n\nThis context creates the following layout objects: \n\n"
(human-listify (uniq-list (sort grob-refs string<? )))
"."
"\n\nThis context is built from the following engravers: "
(description-list->texi
- (map document-engraver-by-name consists))
+ (map document-engraver-by-name consists))
))))
(define (engraver-grobs grav)
) "w"))
)
+ (display "DUMPING...\n")
(display
(filter
(lambda (x) (not (symbol? x)))
INSTALLATION_OUT_FILES=$(LILYPOND_WORDS)
# $(outdir)/lilypond-words $(outdir)/lilypond-words.el
+EXTRA_DIST_FILES=$(wildcard *.vim) vimrc
+
+LILYPOND_WORDS = $(outdir)/lilypond-words $(outdir)/lilypond-words.vim
+LILYPOND_WORDS_DEPENDS =\
+ $(topdir)/lily/my-lily-lexer.cc \
+ $(buildscript-dir)/lilypond-words.py \
+ $(topdir)/scm/new-markup.scm \
+ $(topdir)/ly/engraver-init.ly
+
STEPMAKE_TEMPLATES=install-out
# vimdir defined in config.make
rm $(vimdir)/syntax/lilypond.vim
rmdir -p $(vimdir)/syntax
-EXTRA_DIST_FILES=filetype.vim vimrc
-
-LILYPOND_WORDS = $(outdir)/lilypond-words $(outdir)/lilypond-words.vim
-LILYPOND_WORDS_DEPENDS =\
- $(topdir)/lily/my-lily-lexer.cc \
- $(buildscript-dir)/lilypond-words.py \
- $(topdir)/scm/new-markup.scm \
- $(topdir)/ly/engraver-init.ly
-
$(LILYPOND_WORDS):
cd $(topdir) && $(PYTHON) buildscripts/lilypond-words.py --words --vim --dir=$(builddir)/vim/$(outconfbase)