(LILYPOND_BOOK_FLAGS): use -f tex for lilypond-book.
* scm/framework-ps.scm (convert-to-pdf): new function. Call
ps2pdf.
(output-preview-framework): new function. Generate a preview .ps
-* Invoking lilypond:: Titling LilyPond scores.
-* Invoking the lilypond binary::
* Error messages::
* Reporting bugs::
* Editor support::
* Point and click::
* Error messages::
* Reporting bugs::
* Editor support::
* Point and click::
+* Invoking lilypond-latex::
-@node Invoking the lilypond binary
-@section Invoking the lilypond binary
+
+@node Invoking lilypond
+@section Invoking lilypond
@cindex Invoking LilyPond
@cindex command line options
@cindex options, command line
@cindex switches
@cindex Invoking LilyPond
@cindex command line options
@cindex options, command line
@cindex switches
-The formatting system consists of two parts: a binary executable
-(@file{lilypond}), which is responsible for the formatting
-functionality, and support scripts, which post-process the resulting
-output. Normally, the support scripts are called, which in turn invoke
-the @code{lilypond-bin} binary. However, @code{lilypond-bin} may be
-called directly as follows.
+The @code{lilypond} may be called as follows from the command line.
- lilypond-bin [@var{option}]@dots{} @var{file}@dots{}
+ lilypond [@var{option}]@dots{} @var{file}@dots{}
@node Invoking lilypond-latex
@section Invoking lilypond-latex
@node Invoking lilypond-latex
@section Invoking lilypond-latex
-Before LilyPond 3.0, the task of generating nicely titled output was
-relegated to a separate program. This wrapper script
-@code{lilypond-latex} uses the LilyPond program and La@TeX{} to create
-a nicely titled piece of sheet music.
+Before LilyPond 3.0, the @code{lilypond} program only generated music
+notation. Titles and page layout was done in a separate wrapper
+program. For compatibility with older files, this wrapper program has
+been retained as @code{lilypond-latex}. It uses the LilyPond program
+and La@TeX{} to create a nicely titled piece of sheet music. Use of
+this program is only necessary if the input file contains special
+La@TeX{} options or formatting codes in markup texts.
+The @code{lilypond-latex} wrapper is invoked from the command-line as
+follows
- @code{lilypond} [@var{option}]@dots{} @var{file}@dots{}
+ @code{lilypond-latex} [@var{option}]@dots{} @var{file}@dots{}
-To have @code{lilypond} read from stdin, use a dash @code{-} for
+To have @code{lilypond-latex} read from stdin, use a dash @code{-} for
@var{file}. The program supports the following options.
@cindex stdin, reading
@var{file}. The program supports the following options.
@cindex stdin, reading
@item @option{-P @var{process}}, @option{--process=@var{COMMAND}}
Process lilypond snippets using @var{command}. The default command is
@item @option{-P @var{process}}, @option{--process=@var{COMMAND}}
Process lilypond snippets using @var{command}. The default command is
@item @option{--verbose}
Be verbose.
@item @option{--verbose}
Be verbose.
@example
lilypond (GNU LilyPond) 2.2.0
@example
lilypond (GNU LilyPond) 2.2.0
Now processing `/home/fred/ly/test.ly'
Parsing...
Interpreting music...[1]
Now processing `/home/fred/ly/test.ly'
Parsing...
Interpreting music...[1]
#texi-html for www only:
LILYPOND_BOOK_FORMAT=$(if $(subst out-www,,$(notdir $(outdir))),texi,texi-html)
#texi-html for www only:
LILYPOND_BOOK_FORMAT=$(if $(subst out-www,,$(notdir $(outdir))),texi,texi-html)
-LY2DVI = $(script-dir)/lilypond.py
LYS_TO_TELY = $(buildscript-dir)/lys-to-tely.py
LYS_TO_TELY = $(buildscript-dir)/lys-to-tely.py
-$(outdir)/%.png: $(outdir)/%.ps
- gs -sDEVICE=pnggray -dTextAlphaBits=4 -dGraphicsAlphaBits=4 -sOutputFile="$(name-stem)-page%d.png" -r90 -dNOPAUSE $< -c quit
- -mv $(name-stem)-page*.png $(outdir)/
- rm -f $@
- ln -s $(name-stem)-page1.png $@
-
$(outdir)/%.ly.txt: %.ly
ln -f $< $@
$(outdir)/%.ly.txt: %.ly
ln -f $< $@
$(outdir)/%.ly: %.abc
$(PYTHON) $(ABC2LY) --strict -o $@ $<
$(outdir)/%.ly: %.abc
$(PYTHON) $(ABC2LY) --strict -o $@ $<
-$(outdir)/%.ps: $(outdir)/%.ly
- $(PYTHON) $(LY2DVI) --output=$@ $<
-
-$(outdir)/%.ps: %.ly
- $(PYTHON) $(LY2DVI) --output=$@ $<
+$(outdir)/%.png $(outdir)/%.pdf $(outdir)/%.ly $(outdir)/%.ps: $(outdir)/%.ly
+# hmm. notdir builds srcdir builds?
+ cd $(outdir); $(LILYPOND) --pdf --ps --png $(notdir $<)
-$(outdir)/%.pdf: $(outdir)/%.ps
- ps2pdf -sPAPERSIZE=a4 $< $@
+$(outdir)/%.ly: %.ly
+ cp $< $@
(define-public (convert-to-pdf book name)
(let*
((defs (ly:paper-book-book-paper book))
(define-public (convert-to-pdf book name)
(let*
((defs (ly:paper-book-book-paper book))
- (size (ly:output-def-lookup book 'papersize)))
+ (size (ly:output-def-lookup defs 'papersize)))
(postscript->pdf (if (string? size) size "a4")
name)))
(postscript->pdf (if (string? size) size "a4")
name)))