Only just did I see this e-mail has been rejected because the svg is
too large. So – once more with only .ly…
Am 14.09.2015 um 20:35 schrieb Simon
Albrecht:
Am 14.09.2015 um 18:28 schrieb address@hidden:
Hello,
I'd like to render my scores (only short exercises
that don't fill a page) as .svg so I can include them on a
website. For this, the images would have to be cropped without
any white margins. I've searched the web for hours without
finding a solution.
I tried lilypond -dbackend=svg test.ly,
but this only renders the first system.
IIRC there is only one system in test.ly. -dbackend=svg should
work just fine.
I also tried to include this:
\paper {
indent = 0\mm
line-width = 120\mm
oddHeaderMarkup = ""
evenHeaderMarkup = ""
oddFooterMarkup = ""
evenFooterMarkup = ""
These are not for margins, but for headers and footers, as their
names say. Try the following:
%%%%%% zero-margin.ly %%%%%%%%
\version "2.19.27"
\paper {
right-margin = 0
left-margin = 10
top-margin = 0
bottom-margin = 0
}
mus = \repeat unfold 64 \relative { c' d e f }
\score {
\new StaffGroup \with { shortInstrumentName = "test" }
<<
\mus
\mus
>>
}
%%%%%%%%%%%%%%%%
With that, I get the attached results.
If the left margin is 0 as well, the System_start_delimiter and
instrument names will be off the page.
The svg seems OK to me, except for the missing embedded font,
which we are trying to fix at the moment.
By the way: Searching the index of our Notation Reference manual
for ‘svg’ brings you directly to
<http://lilypond.org/doc/v2.18/Documentation/notation/alternative-output-formats#index-SVG-output>.
HTH, Simon
|