Am 28.08.2010 um 12:28 schrieb Werner:

Hello.

I would like to get instead of just a page number something like:

1/3
1 of 3
1 von 3
on first page if the whole piece contains 3 pages

Maybe also (small)
„title“, S. 2 von 3
„title“, p. 2 of 3
„title“, 2/3

on page two of three...
(but also just 2/3, 2 von 3 or 2 of 3 would b good.)
(And of course 3/3, 3 von 3 oder 3 of 3 on last page.)

Does someone have a hint?
The following solution might not be the most elegant one but it works at least:

\version "2.13.30"

\paper {
  print-first-page-number = ##t
  oddHeaderMarkup = \markup {
    \column {
      \fill-line {
        \line { }
        \line {
          Page
          \on-the-fly #print-page-number-check-first
          \fromproperty #'page:page-number-string
          of \concat { \page-ref #'lastPage "0" "?" }
        }
      }
    }
  }
  evenHeaderMarkup = \markup {
    \column {
      \fill-line {
        \line { }
        \line {
          Page
          \on-the-fly #print-page-number-check-first
          \fromproperty #'page:page-number-string
          of \concat {\page-ref #'lastPage "0" "?"}
        }
      }
    }
  }
  oddFooterMarkup = \markup {
    \column {
      \fill-line {
        \line { }
        \line {
          Page
          \on-the-fly #print-page-number-check-first
          \fromproperty #'page:page-number-string
          of \concat {\page-ref #'lastPage "0" "?"}
        }
      }
    }
  }
  evenFooterMarkup = \markup {
    \column {
      \fill-line {
        \line { }
        \line {
          Page
          \on-the-fly #print-page-number-check-first
          \fromproperty #'page:page-number-string
          of \concat {\page-ref #'lastPage "0" "?"}
        }
      }
    }
  }
}

music = {
  \repeat unfold 250 { c''1 }
  \label #'lastPage
}

\score {
 \music
}

I included both footer and header markups. Feel free to comment out whatever you don't need. You might want to change »Page« and »of« to »Seite« and »von«.

HTH
patrick



Greetings

Werner


_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user


_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
http://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to