[Top][All Lists]

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

Total number of pages & Logo

From: Frederik Van der Veken
Subject: Total number of pages & Logo
Date: Fri, 10 Feb 2012 11:56:49 +0100

Hi everybody,

First I want to say thanks to the makers of Lilypond, it really is a superb 
Fantastic layout and easy to use, it is my main music layout program now 
(coming from Sibelius, which I also like, but which is getting expensive and 
big ~  550€ and 60Gb)!

So, I've been trying for several days by now to get the layout how I want it. I 
succeeded almost, but got stuck at two problems:

1) I'd like to add the logo of my choir in the top left corner of the first 
page. I tried using \epsfile but a) it doesn't work (maybe because it is an eps 
generated from a tiff?) and b) it seems I have to attach it to a music element, 
however, I want it to be positioned always at the (exact) same spot (top left 
corner thus) while having it only at the first page (thus not in the header). 
Any ideas how to achieve this?

2) In the top right corner, I added the score numbering I'm using in my choir. 
However, I'd like to also add the current page number with respect to the total 
number of pages, and only if there is more than one page. Until now, I got:

\version "2.15.28"
\paper {
  print-page-number = ##t
  print-first-page-number = ##t
  oddFooterMarkup = \markup \null
  evenFooterMarkup = \markup \null
  oddHeaderMarkup = \markup { \bold \fill-line { "                              
          \right-column { \concat { \fontsize #4 "SzM " \general-align #X #LEFT 
 \fontsize #5 \scoreIndex }
                \concat { \on-the-fly #print-page-number-check-first 
\fromproperty #'page:page-number-string "/"  \numberOfPages }
  evenHeaderMarkup = \oddHeaderMarkup

So this gives something like "SzM 411 1/2" , but I have to set \numberOfPages 
manually. This is not so convenient, as I generate different scores from the 
same code, which do not necessarily have the same number of pages (like a 
version for choir, and a version for piano+choir). Is there a way to 
auto-detect the total number of pages of a score?
And how would I incorporate "if… then" to only show the page numbering if there 
is more than one page (i.e. "SzM 411" instead of "SzM 411 1/1"?
I tried several things, but it never compiled (unfortunately I am not yet that 
strong with Scheme).

Thanks a lot for any replies, and sorry for the long mail (I have been freaking 
out the last few days trying to get it right).


reply via email to

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