Okay, that works good. I also added \override StanzaNumber #'font-family = #'sans for the stanza numbers to be in the same style.
But for consictency I´d like to have some other fonts also being Sans, e.g. the font of the volta brackets. I couldn´t find something about it in the manual. I tried to add \override VoltaText #'font-family = #'sans to the above, but it didn´t help. And is there a way to set the default font for markups to Sans? Thanks, Dominic 2007/9/14, Mats Bengtsson <[EMAIL PROTECTED]>: > If all you want to do is to get a Sans font for lyrics, it's just to > redefine the > corresponding font property. To do this for all Lyrics contexts in your > file, > you can add > \layout{ > \context{ > \Lyrics > \override LyricText #'font-family = #'sans > } > } > anywhere at the top level of the .ly file. > > On the other hand, if you want this specific file, you have to use the > (make-pango-font-tree ...) command, which unfortunately needs to know > the current staff size. One practical way to do it is to remove the line > myStaffSize = #20 > from your .ly file and in your .lytex do > \begin[staffsize=11]{lilypond} > \paper{ myStaffSize = #11 } > \include "test.ly" > \end{lilypond} > > If you also want to be able to run the same .ly file standalone, then > you could > make a separate wrapper .ly file that just contains > \paper{ myStaffSize = #20 } > \include "test.ly" > > /Mats > > Dominic Neumann wrote: > > Hi, > > > > I want to try to have all my lyrics typeset in a Sans font. Therefor > > I´ve used a snippet from LSR > > (http://lsr.dsi.unimi.it/LSR/Snippet?id=221): > > > > %%% BEGIN OF SNIPPET %%% > > \paper { > > myStaffSize = #20 > > > > #(define fonts > > (make-pango-font-tree "Bitstream Vera Sans" > > "Nimbus Sans" > > "Luxi Mono" > > (/ myStaffSize 20))) > > } > > %%% END OF SNIPPET %%% > > > > I substituted Times New Roman with Bitstream Vera Sans what isn´t a > > very good way, I think. > > When producing lilypond-output directly with lilypond this works quite > > good, but together with lilypond-book the layout is very bad: the > > barlines and stems are smaller than they should be to suit the size of > > the noteheads. > > > > I produced two simple examples to show what I did: > > > > %%%% BEGIN OF PURE LILYPOND-FILE%%%% > > \version "2.10.29" > > > > \paper { > > myStaffSize = #20 > > > > #(define fonts > > (make-pango-font-tree "Bitstream Vera Sans" > > "Nimbus Sans" > > "Luxi Mono" > > (/ myStaffSize 20))) > > } > > > > verseOne = \lyricmode { > > \set stanza = "1. " > > test bla blub -- ber > > test bla blub -- ber > > } > > > > \score { > > { > > << > > \relative c'' { > > \key d \major > > \time 2/4 > > cis4 d | e fis > > cis4 d | e fis > > \bar "|." > > } > > \addlyrics { \verseOne } > > >> > > } > > } > > > > %%%% ENDOF PURE LILYPOND-FILE%%%% > > > > %%%% BEGIN OF LYTEX-FILE %%%% > > \documentclass{article} > > > > \begin{document} > > > > \lilypondfile[staffsize=11]{test.ly} > > > > \end{document} > > %%%% END OF LYTEX-FILE %%%% > > > > > > As you see, I cannot change the Staffsize and everything belonging to > > it from within the LyTeX-file. How can I achieve this in another way? > > I hope there is a more straight-forward way ... > > > > Thanks, Dominic > > > > PS: It seems that the \sans command only works within \markup > > commands. So I cannot say "\sans" at the beginning of the document to > > make everything appear in a Sans font. > > > > > > ------------------------------------------------------------------------ > > > > > > ------------------------------------------------------------------------ > > > > ------------------------------------------------------------------------ > > > > _______________________________________________ > > lilypond-user mailing list > > lilypond-user@gnu.org > > http://lists.gnu.org/mailman/listinfo/lilypond-user > > > > -- > ============================================= > Mats Bengtsson > Signal Processing > Signals, Sensors and Systems > Royal Institute of Technology > SE-100 44 STOCKHOLM > Sweden > Phone: (+46) 8 790 8463 > Fax: (+46) 8 790 7260 > Email: [EMAIL PROTECTED] > WWW: http://www.s3.kth.se/~mabe > ============================================= > > > -- -------------------------------------------------- Verlag & IT-Dienstleistungen Dominic Neumann Lessingstraße 8 09130 Chemnitz Tel.: 03 71 / 2 83 93 74 eMail: [EMAIL PROTECTED] Web: http://verlag.dominicneumann.de/ _______________________________________________ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user