lilypond-user
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Create one png image per pageBreak?


From: Stan Mulder
Subject: Re: Create one png image per pageBreak?
Date: Mon, 22 Dec 2014 21:23:48 +0000 (UTC)
User-agent: Loom/3.14 (http://gmane.org/)

> How about compiling your code with
> lilypond -dpreview -dresolution=200 your-file.ly
> ?
> (or whatever resolution is apropiate)


Oh wow! That -dpreview trims the file nicely. I was prepared to use
ImageMagik's convert program to trim the whitespace thusly, "convert -trim
filename.png outfile.png" -- but now I don't have to do that.

I guess the question is, since I've got to construct a lot of repetitive
lines of code for each chord, am I doing this in the most efficient manner?
This would be great for a for-loop kind of thing. Do you see any way to
simplify or automate my code? Maybe with macros, or something else?


\version "2.19.15"
%#(set-global-staff-size 30)

\include "lilypond-book-preamble.ly"
\paper { oddFooterMarkup = ##f }
\include "english.ly"
%\include "predefined-plectrum-banjo-fretboards.ly"
\include "predefined-guitar-fretboards.ly"

plec = { 
  %\set Staff.stringTunings = #plectrumTuning 
  \override FretBoard.fret-diagram-details.number-type = #'arabic
  \override FretBoard.fret-diagram-details.finger-code = #'in-dot
}

chord_C    = \chordmode { c   } #(define output-suffix "chord_C")   \book {
<< \new ChordNames { \chord_C  } \new FretBoards { \plec \chord_C  } >> }
chord_Cm   = \chordmode { c:m } #(define output-suffix "chord_Cm")  \book {
<< \new ChordNames { \chord_Cm } \new FretBoards { \plec \chord_Cm } >> }







reply via email to

[Prev in Thread] Current Thread [Next in Thread]