Re: relative mode occasionally gets forgotten?
Patrick McCarty wrote: On Thu, May 14, 2009 at 8:05 PM, Chip c...@wiegand.org wrote: Chip wrote: I've come across this a couple times - when I am inputting a song it all works fine in \relative mode. I do some editing, some copy/paste from one part to another, view the resulting pdf and see the octaves are all messed up. The only way to fix them is to use absolute octave marks in small sections, usually only a few measures, to get the song to print correctly. Then for whatever reason, after those few measures the rest of the song is just fine. This seems to be completely random, has happened in a couple different songs, in different versions of lilypond. Has anyone seen this kind of behavior? Just seems rather odd. -- Chip I found the problem - I had the \relative c and the \transpose ef f bits seperated like this - bari = \transpose f ef { e4-- e8-- e8-- e4-. r ... stuff } barisax = \relative c' { \global \set Staff.instrumentName = #Bari Sax \set Staff.shortInstrumentName = #Bari \clef treble \bari%I've been told I don't need the here in this usage but without them I get errors } After I moved the \relative c' up to the same line as the \transpose the octave problems were fixed. It appears that the two have to be together, not seperated like I had them. I think this is the issue mentioned in the Known Issues for Chapter 1.1.2 Transpose in the Notation Reference. However, the two sentences included there are very confusing and should be rewritten to make the issue more clear. -Patrick Yes, I see what you mean. Not sure I understand it myself. -- Chip ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Need help with this trill
Thank you all for your helpful replies. @Eluze: Yes, that snippet does exactly what I want. Thanks!! @Kieren: It does indeed, thanks for pointing it out. It's very convenient too, when there are several of these trills. Best regards, Holger On Fri, May 15, 2009 at 1:29 AM, Kieren MacMillan kieren_macmil...@sympatico.ca wrote: Hi, http://lists.gnu.org/archive/html/lilypond-user/2009-04/msg00606.html Does this not exactly answer the (second) question? Regards, Kieren. Date: Thu, 14 May 2009 16:14:58 -0700 From: elu...@gmail.com To: lilypond-user@gnu.org Subject: Re: Need help with this trill Carl D. Sorensen wrote: On 5/14/09 3:24 PM, Holger Hellebro hol...@gmail.com wrote: I think \graceAfter is what you're looking for. 2. How to put the natural symbol above the trill symbol. I've tried ^\markup{\tiny \natural} both before and after the \trill, but the trill sign ends up above the natural sign in either case. i tried the following code which seems to work (there is plenty of examples in NR Grace notes): \version 2.12 { \clef G_8 \transpose c c' { R 1 \override TextScript #'outside-staff-priority = #600 \override Script #'outside-staff-priority = #500 \slurDown \afterGrace c 1 ( \trill ^\markup {\teeny \translate #'( .55 . 0 ) \musicglyph #accidentals.natural } { c 16[ d] ) } c 1 } } -- View this message in context: http://www.nabble.com/Need-help-with-this-trill-tp23549304p23550774.html Sent from the Gnu - Lilypond - User mailing list archive at Nabble.com. ___ 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 ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Fit on one page?
Would someone be able to help me get this on one page? 2009/5/14 d...@haygoods.org: I would like to reduce the vertical space between staves (aka 1-stave systems) within one \score on a page that has two other \scores. Once the rest of the content is added, I want to force the first \score's staves much closer together and leave all the default automatic spacing in place for the second two scores. This will allow all three scores to fit on one page. Have you tried this? \context { \Staff \override VerticalAxisGroup #'minimum-Y-extent = #'(0 . 0) } Default is #'(-4 . 4) If you have lyrics, remember to do the same for the \Lyrics context. -- Francisco Vila. Badajoz (Spain) www.paconet.org I wasn't able to get this to work, even setting the Y-extent explicitly, and working with 'line-break-system-details also: \override NonMusicalPaperColumn #'line-break-system-details = #'((next-space . 0)) In most cases, the stretcher seems to kick in, in between \scores and score \headers, and it eiths mangles the score title spacing, or decides to re-stretch the staves over two pages. So, even though I would like fit this all on one page by vertically compressing only \score 1, I can accept something that affects all three scores, like \paper space-between-systems. But if I use this, can you show me how to isolate this first page in a \bookpart, so that I can use the defaults for the rest of the book? Thanks, - Dan ___ \version 2.12.0 % necessary for upgrading to future LilyPond versions. \paper { indent = 0\cm #(set-paper-size letter) } \header{ title = Warm Up } \layout { \context { \Score \remove Bar_number_engraver } } \score { \transpose bes c { \relative c' { \key bes \major \set fingeringOrientations = #'(down) #(set-accidental-style 'modern) \override Staff.TimeSignature #'break-visibility = #'#(#f #t #t) \slurUp bes'1-\markup { \combine \finger 0 \postscript #1 0 translate 1.5 1.5 scale newpath 0.2 0.3 moveto 12 0.3 lineto closepath stroke } ( f' ) ( bes ) ( f ) ( bes, ) \bar || \break \time 4/4 a-\markup \finger 2 ( e' ) ( a ) ( e ) ( a, ) \bar || \break \time 4/4 aes-\markup \finger 1 ( ees' ) ( aes ) ( ees ) ( aes, ) \bar || \break \time 4/4 g-\markup \finger 12 ( d' ) ( g ) ( d ) ( g, ) \bar || \break \time 4/4 ges-\markup \finger 23 ( des' ) ( ges ) ( des ) ( ges, ) \bar || \break \time 4/4 f-\markup \finger 13 ( c' ) ( f ) ( c ) ( f, ) \bar || \break \time 4/4 e-\markup \finger 123 ( b' ) ( e ) ( b ) ( e, ) \bar |. } } \header { piece = Warm Up #1 } } \score { \transpose bes c { \relative c' { \key bes \major \set fingeringOrientations = #'(down) #(set-accidental-style 'modern) \slurUp bes'2-\markup \finger 0( f' ) a,-\markup \finger 2 ( e' ) aes,-\markup \finger 1 ( ees' ) g,-\markup \finger 12 ( d' ) \break ges,-\markup \finger 23( des' ) f,-\markup \finger 13 ( c' ) e,-\markup \finger 123 ( b' ) bes-\markup \finger 0 ( f' ) \bar |. } } \header { piece = Warm Up #2 } } \score { \transpose bes c { \relative c' { \key bes \major \set fingeringOrientations = #'(down) #(set-accidental-style 'modern) \slurUp bes'4-\markup \finger 0( f' bes2 ) a,4-\markup \finger 2 ( e' a2 ) aes,4-\markup \finger 1( ees' aes2 ) g,4-\markup \finger 12 ( d' g2 ) \break ges,4-\markup \finger 23 ( des' ges2 ) f,4-\markup \finger 13 ( c' f2 ) e,4-\markup \finger 123( b' e2 ) bes4-\markup \finger 0 ( f' bes2 ) \bar |. } } \header { piece = Warm Up #3 } } ___ lilypond-user mailing list
Re: Fit on one page?
2009/5/15 d...@haygoods.org: Would someone be able to help me get this on one page? By brute force I'do: \paper { between-system-padding=0 ... -- Francisco Vila. Badajoz (Spain) www.paconet.org ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Need help with this trill
Francisco Vila-5 wrote: The problem with \afterGrace is that you cannot put a slur: By the way, what's wrong with this code? Not having \new Staff (because I assume it's not needed) it creates three staves! i think this could be related to the issues found about graces in the beginning of a score; a workaraound for both is: { \relative c'''{ s 1*0 \afterGrace a2 _( { g 16[ a] ) } a2 } } please also note the elegant way to temporarily override the direction of the slur! -- View this message in context: http://www.nabble.com/Need-help-with-this-trill-tp23549304p23555641.html Sent from the Gnu - Lilypond - User mailing list archive at Nabble.com. ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Fit on one page?
2009/5/15 Francisco Vila paconet@gmail.com: 2009/5/15 d...@haygoods.org: Would someone be able to help me get this on one page? By brute force I'do: \paper { between-system-padding=0 ... % % me too; and, occasionally: ragged-last-bottom = ##f } -- Francisco Vila. Badajoz (Spain) www.paconet.org -- Dmytro O. Redchuk ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Need help with this trill
Francisco Vila wrote: The problem with \afterGrace is that you cannot put a slur: \new Staff \relative c'''{ \afterGrace a2 {g16[ a]} a2 } \new Staff \relative c'''{ a2 \acciaccatura {g16[ a]} a2 } Of course you can: \new Voice \relative c'''{ \afterGrace a2 ( {g16[ a])} a2 } By the way, what's wrong with this code? Not having \new Staff (because I assume it's not needed) it creates three staves! \relative c'''{ \afterGrace a2 {g16[ a]} a2 } Well, you just showed to yourself that your assumption was wrong. Actually, as illustrated in my example above, you rather need \new Voice, not \new Staff, since otherwise the \afterGrace will end up in a separate Voice. In practice this isn't a problem unless you happen to have an \afterGrace on the first note of the piece. As soon as there are some other notes before, the Voice context has already been created by LilyPond. /Mats -- = Mats Bengtsson Signal Processing School of Electrical Engineering Royal Institute of Technology (KTH) SE-100 44 STOCKHOLM Sweden Phone: (+46) 8 790 8463 Fax: (+46) 8 790 7260 Email: mats.bengts...@ee.kth.se WWW: http://www.s3.kth.se/~mabe = ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Fit on one page?
Dmytro O. Redchuk wrote: 2009/5/15 Francisco Vila paconet@gmail.com: 2009/5/15 d...@haygoods.org: Would someone be able to help me get this on one page? By brute force I'do: \paper { between-system-padding=0 ... % % me too; and, occasionally: ragged-last-bottom = ##f } another brute-force method: \paper { page-count = 1 } Jon -- Jonathan Kulp http://www.jonathankulp.com ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: relative mode occasionally gets forgotten?
Chip wrote: Patrick McCarty wrote: On Thu, May 14, 2009 at 8:05 PM, Chip c...@wiegand.org wrote: Chip wrote: I've come across this a couple times - when I am inputting a song it all works fine in \relative mode. I do some editing, some copy/paste from one part to another, view the resulting pdf and see the octaves are all messed up. The only way to fix them is to use absolute octave marks in small sections, usually only a few measures, to get the song to print correctly. Then for whatever reason, after those few measures the rest of the song is just fine. This seems to be completely random, has happened in a couple different songs, in different versions of lilypond. Has anyone seen this kind of behavior? Just seems rather odd. -- Chip I found the problem - I had the \relative c and the \transpose ef f bits seperated like this - bari = \transpose f ef { e4-- e8-- e8-- e4-. r ... stuff } barisax = \relative c' { \global \set Staff.instrumentName = #Bari Sax \set Staff.shortInstrumentName = #Bari \clef treble \bari%I've been told I don't need the here in this usage but without them I get errors } After I moved the \relative c' up to the same line as the \transpose the octave problems were fixed. It appears that the two have to be together, not seperated like I had them. I think this is the issue mentioned in the Known Issues for Chapter 1.1.2 Transpose in the Notation Reference. However, the two sentences included there are very confusing and should be rewritten to make the issue more clear. -Patrick Yes, I see what you mean. Not sure I understand it myself. -- Chip If someone who understands the issue can send me new wording for this passage that makes it clearer, I will make a patch for the docs. Jon -- Jonathan Kulp http://www.jonathankulp.com ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Bass in Chord Name
Marc Hohl wrote: descried his analysis about chords representation Thanks Marc very very much. Actually your code does not work for me but you pointed me to right direction. I analyzed ly/property-init.ly and scm/chord-name.scm files and functions in them to understand how chord logic works. After several tunings and tries I found very simple solution for my need. I do not even need to change property-init.ly and chord-name.scm. I shouldn't use internal \germanChords directive, but define in my lilypond file the following: \set chordRootNamer = #(chord-name-german-markup #t) After this both chords and basses in chords are represented using H and B (not B and Bb). Surprisingly how simple solution became at the end. -- View this message in context: http://www.nabble.com/Bass-in-Chord-Name-tp23429277p23557867.html Sent from the Gnu - Lilypond - User mailing list archive at Nabble.com. ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Complex chords
How to achieve these complex chords: C+5 (instead of C+) Cdim (instead of Co) Cmaj8 (instead of triangle) and chord transition from G7/4-3 as show on image attached http://www.nabble.com/file/p23558140/slika.jpeg -- View this message in context: http://www.nabble.com/Complex-chords-tp23558140p23558140.html Sent from the Gnu - Lilypond - User mailing list archive at Nabble.com. ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Replacing \set stanza with custom verseNumber
Tom Dickson-3 wrote: It doesn't work correctly - it appears Scheme doesn't like the second use of the variable? verseNumber = #(define-music-function (parser location markp) (string?) #{ \set vocalName = $markp \set shortVocalName = $markp \override InstrumentName #'X-offset = #2 \override InstrumentName #'font-series = #'bold #}) is what I'm trying - for me it works when i call it like { \context Staff { \clef G_8 \context Voice=mel { c d e f g a b c } \context Lyrics \lyricsto mel { \verseNumber #xy do re mi fa so la ti do } } } -- View this message in context: http://www.nabble.com/Replacing-%5Cset-stanza-with-custom-verseNumber-tp23553190p23558767.html Sent from the Gnu - Lilypond - User mailing list archive at Nabble.com. ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: relative mode occasionally gets forgotten?
Hi Jon, Jonathan Kulp wrote: Chip wrote: snip I think this is the issue mentioned in the Known Issues for Chapter 1.1.2 Transpose in the Notation Reference. However, the two sentences included there are very confusing and should be rewritten make the issue more clear. -Patrick Yes, I see what you mean. Not sure I understand it myself. -- Chip If someone who understands the issue can send me new wording for this passage that makes it clearer, I will make a patch for the docs. There are two issues 1. The information is in the wrong place 2. It's written in confusing developer-speak. 1. The text should be in section 1.1.2 Transposing after the first example. Put it just before the bit reading If a part written in C (normal /concert pitch/) 2. The text should be changed from The relative conversion will not affect \transpose, \chordmode or \relative sections in its argument. To use relative mode within transposed music, an additional \relative must be placed inside \transpose. to Note that in the previous example the music supplied as /musicexpr/ uses a \relative command. This is because \transpose does not pick up any \relative settings you may have set up in the outer block containing your \transpose statement. If you use \relative pitches, always code /musicexpr/ as a \relative block when using \transpose Jon Cheers, Ian ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: relative mode occasionally gets forgotten?
On 5/15/09 5:05 AM, Jonathan Kulp jonlancek...@gmail.com wrote: Chip wrote: Patrick McCarty wrote: On Thu, May 14, 2009 at 8:05 PM, Chip c...@wiegand.org wrote: I think this is the issue mentioned in the Known Issues for Chapter 1.1.2 Transpose in the Notation Reference. However, the two sentences included there are very confusing and should be rewritten to make the issue more clear. -Patrick Yes, I see what you mean. Not sure I understand it myself. -- Chip If someone who understands the issue can send me new wording for this passage that makes it clearer, I will make a patch for the docs. How about: Music inside a \transpose or \chordmode block is absolute, unless a \relative is included inside the the \transpose or \chordmode block. When \relative blocks are nested, the innermost relative block applies. I think that this information should be put in several places in the NR. First, I think that the information above should be put into 1.1.1 Writing Pitches as examples under Relative octave entry. There should be three separate items/examples: When relative blocks are nested, the innermost relative block applies. \relative c' { d e f \relative c'' { d e f}} Music inside a \chordmode block is absolute unless a \relative is included in the block. \relative c' { \chordmode { c \relative c'' { c }} Music inside a \transpose block is absolute unless a \relative is included. \relative c' { d e \transpose f g { d e \relative c' { d e }}} Second, I think a warning (inside a box, not just a known issue) under t1.1.2 Changing multiple pitches Transpose should say Music inside a \transpose block is absolute unless a \relative is included in the block. with a see-also to \relative. Similarly, a warning in 2.7.1. Chord mode should say Music inside a \chordmode block is absolute unless a \relative is included in the block. with a see-also to \relative. Note: I haven't tested any of these examples. HTH, Carl ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: relative mode occasionally gets forgotten?
I'm not sure that the relative mode gets forgotten but that LilyPond follows its own internal rules. I find that LilyPond behaves the way that the manual says it does: it picks the closest pitch. If I write { c2 a2 } it picks the A below that C rather than the A above that C. If I want the A above the C, I write { c2 a'2 } and all is well. Sometimes when I first compile the song there are pitches wildly out of their intended octave; then it's a matter of finding the proper places to change the pitch octaves with ' or , and the problem is usually solved with two or three of these. Pretty quick and simple without needing to resort to sticking \relative commands into the middle of the music information- something I hate doing because it makes it hard to debug the song. I use LilyPond to write out jazz lead sheets using the template below (with some modifications, e.g., \include and \repeat etc., as needed) which shows how I use the \relative command. When I transpose the music, I use two \transpose commands, one before each of the \relative commands. This seems to minimize the problems reported by the OP. Someone on the list sent me this template but I can't remember who it was. It works very well for my purposes and probably would not work well for many other purposes and perhaps not the OP's. \version 2.12.2 \paper { indent = 0.0 } \header { title = composer = meter = copyright = } harmonies = \chordmode { } melody = \relative c' { \override Staff.TimeSignature #'style = #'() \time 4/4 \clef treble \key \bar |: \bar :| } \addlyrics { } \score { \new ChordNames { \set chordChanges = ##t \harmonies } \new Staff \melody } ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Complex chords
On May 15, 2009, at 6:45 AM, Stjepan Brbot wrote: How to achieve these complex chords: C+5 (instead of C+) Cdim (instead of Co) Cmaj8 (instead of triangle) and chord transition from G7/4-3 as show on image attached http://www.nabble.com/file/p23558140/slika.jpeg You need to define exceptions to the way that LilyPond writes chords. One way is to use one of the alternative chord rendering methods that you can find in the snippet repository. You can put this into a .ly file and use the \include command to call it when the music file is rendered into a PDF. Another list member sent me this set of exceptions which you can modify as you need: % Pop chords as used in English/American popular music % by James L. Hammons % Written against \version 2.11.52 chordFlat = \markup { \hspace #0.2 \tiny \raise #1.0 \flat } chordSharp = \markup { \hspace #0.1 \teeny \raise #1.0 \sharp } popChordsMusic = { % Triads c g-\markup { 5 } c d g-\markup { 2 } % c d g-\markup { sus2 } c f g-\markup { sus } % c f g-\markup { sus4 } % c ees ges-\markup { \small \raise #1.0 o } c ees ges-\markup { \raise #0.8 o } % c ees ges-\markup { dim } % c e gis-\markup { aug } % or + % Sixths c e g a-\markup { 6 } c ees g a-\markup { m6 } % Sevenths (including altered) c e g bes-\markup { 7 } c ees g bes-\markup { m7 } c e g b-\markup { maj7 } c f g bes-\markup { 7sus4 } c d g bes-\markup { 7sus2 } c e ges bes-\markup { 7 \chordFlat 5 } c e gis bes-\markup { 7 \chordSharp 5 } % c e gis bes-\markup { aug7 } % or +7 c ees g b-\markup { m(maj7) } % c ees ges beses-\markup { \small \raise #1.0 { o } 7 } c ees ges beses-\markup { \raise #0.8 { o } 7 } % c ees ges beses-\markup { dim7 } % c ees ges bes-\markup { \small \raise #1.0 { #(ly:export (ly:wide- char-utf-8 #x00f8)) } 7 } % c ees ges bes-\markup { \raise #0.8 { #(ly:export (ly:wide-char- utf-8 #x00f8)) } 7 } c ees ges bes-\markup { m7 \chordFlat 5 } c e ges b-\markup { maj7 \chordFlat 5 } c e gis b-\markup { maj7 \chordSharp 5 } % Ninths (including altered--incomplete) c e g bes d'-\markup { 9 } c ees g bes d'-\markup { m9 } c e g b d'-\markup { maj9 } c e g d'-\markup { add9 } c e g a d'-\markup { 6/9 } c ees g a d'-\markup { m6/9 } c ees g b d'-\markup { m(maj9) } c e g bes des'-\markup { 7 \chordFlat 9 } c e g bes dis'-\markup { 7 \chordSharp 9 } %dim7add9, dim7b9, dim7#9, 9#5, 9b5, maj9#5, maj9b5, 9sus4, 9sus2 % Elevenths (incomplete) c e g bes d' f'-\markup { 11 } c ees g bes d' f'-\markup { m11 } c e g b d' f'-\markup { maj11 } c e g f'-\markup { add11 } c ees g f'-\markup { m add11 } c ees g bes f'-\markup { m7add11 } % Thirteenths (incomplete) c e g bes d' a'-\markup { 13 } c ees g bes d' a'-\markup { m13 } c e g b d' a'-\markup { maj13 } c e g a'-\markup { add13 } % Misc add chords c e g bes des' aes'-\markup { 7 \chordFlat 9 \chordFlat 13 } c e gis bes des'-\markup { 7 \chordSharp 5 \chordFlat 9 } c e g b d' fis'-\markup { maj9 \chordSharp 11 } c e g bes d' fis'-\markup { 9 \chordSharp 11 } } % Add to existing exceptions popChordsAdd = #(append (sequential-music-to-chord-exceptions popChordsMusic #t) ignatzekExceptions) % Bah, can't we set this globally? YES! See below... % \set chordNameExceptions = #popChords % Bah, this doesn't work either... % #(set chordNameExceptions popChords) % Let's try fixing the accidentals with some Scheme... #(define (chord-name-pop-markup pitch) (let* ((alt (ly:pitch-alteration pitch))) (make-line-markup (list (make-simple-markup (vector-ref #(C D E F G A B) (ly:pitch-notename pitch))) ;; If it's natural, do nothing (if (= alt 0) (make-line-markup (list empty-markup)) (if (= alt FLAT) ;; Otherwise, handle adding the flat symbol (make-line-markup (list (make-hspace-markup 0.3) ;; WAS: 0.4 (make-tiny-markup (make-raise-markup 1.0 (make-musicglyph-markup accidentals.flat))) ) ) ;; or handle adding the sharp symbol (make-line-markup (list (make-hspace-markup 0.1) ;; WAS: 0.2 (make-teeny-markup (make-raise-markup 1.0 (make-musicglyph-markup accidentals.sharp))) ) ) ) ) ) ) ) ) %{ popChords = { \set chordNameExceptions = #popChordsAdd \set chordRootNamer =
Re: relative mode occasionally gets forgotten?
Carl D. Sorensen wrote: Music inside a \transpose or \chordmode block is absolute, unless a \relative is included inside the the \transpose or \chordmode block. When \relative blocks are nested, the innermost relative block applies. I don't understand why \chordmode (and \chords) changes back to absolute mode, when \notemode doesn't. Is it just since it's less common that the roots of the chords span several octaves, or is there any other good reason why LilyPond is implemented in this way? /Mats ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: relative mode occasionally gets forgotten?
On Fri, May 15, 2009 at 06:46:39AM -0600, Carl D. Sorensen wrote: First, I think that the information above should be put into 1.1.1 Writing Pitches as examples under Relative octave entry. There should be three separate items/examples: When relative blocks are nested, the innermost relative block applies. \relative c' { d e f \relative c'' { d e f}} Woah, that's froody! I would have never expected that! Note: I haven't tested any of these examples. I tested the above, because I just couldn't believe it. Anyway, I agree with these proposals. Cheers, - Graham ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: relative mode occasionally gets forgotten?
Tim McNamara wrote: I'm not sure that the relative mode gets forgotten but that LilyPond follows its own internal rules. I find that LilyPond behaves the way that the manual says it does: it picks the closest pitch. If I write { c2 a2 } it picks the A below that C rather than the A above that C. If I want the A above the C, I write { c2 a'2 } and all is well. Sometimes when I first compile the song there are pitches wildly out of their intended octave; then it's a matter of finding the proper places to change the pitch octaves with ' or , and the problem is usually solved with two or three of these. Pretty quick and simple without needing to resort to sticking \relative commands into the middle of the music information- something I hate doing because it makes it hard to debug the song. Here is an example of the issue I came across - r4 r8 ef~ ef d c bf a4. g8~ g2~ g2-- r In any mode the tied notes are the same octave, of course. But for whatever reason, with the \transpose and the \relative split as originally described, they were in different octaves, which obviously, broke the ties. Putting the \transpose ef f \relative c' together fixed the problem. With the \transpose and \relative split there were quite a few random instances of such odd octave issues, some would be just a single note or two, others 3 or 4 measures of music where almost every other note jumped octaves up and down. It's really a weird thing to see. In my template I typically use \transpose x x \relative x but for whatever reason I don't even recall now I moved the \transpose up to the notes section of the code. I think what I did was entered the notes of the tenor sax part in their actual tenor sax key (and all other instruments in concert key), then \transposed them, the tenor sax notes, down to concert key for the purpose viewing the score entirely in concert key. Thus the tenor sax part had the really wicked octave issue. Regards -- Chip I used the following template for all my transcriptions of texmex and tejano music (for a 7 piece horn section)- % LilyPond \include english.ly \version 2.12.2 \header{ title = composer = As Recorded By: arranger = Transcribed by: Chip Wiegand } global = { \time 4/4 \key bf \major #(override-auto-beam-setting '(end 1 8 * *) 1 4 'Staff) #(override-auto-beam-setting '(end 1 8 * *) 2 4 'Staff) #(override-auto-beam-setting '(end 1 8 * *) 3 4 'Staff) \override Glissando #'thickness = #3 \override Glissando #'style = #'zigzag \override Glissando #'minimum-length = #6 \override Glissando #'springs-and-rods = #ly:spanner::set-spacing-rods \override MultiMeasureRest #'expand-limit = 1 \set Score.skipBars = ##t \numericTimeSignature } \paper { top-margin = 0.1\cm page-top-space = 0.1\cm ragged-bottom = ##t left-margin = 20\mm line-width = 175\mm } tagline = \markup { \simple #(strftime %b %d, %Y (localtime (current-time))) \with-url #http://lilypond.org/web/; { LilyPond \simple #(lilypond-version) (http://lilypond.org/) } } % -- Trumpet 1-- trpta = {} trumpeta = \transpose bf c \relative c'' { \global \set Staff.instrumentName = #Trumpet 1 \set Staff.shortInstrumentName = #Trpt 1 \clef treble \trpta } % -- Trumpet 2-- trptb = {} trumpetb = \transpose bf c \relative c'' { \global \set Staff.instrumentName = #Trumpet 2 \set Staff.shortInstrumentName = #Trpt 2 \clef treble \trptb } % -- Alto Sax 1 -- altoa = {} altosaxa = \transpose bf g \relative c'' { \global \set Staff.instrumentName = #Alto Sax \set Staff.shortInstrumentName = #Alto \clef treble \altoa } % -- Tenor-- tenor = {} tenorsax = \transpose bf c \relative c'' { \global \set Staff.instrumentName = #Tenor Sax \set Staff.shortInstrumentName = #Tenor \clef treble \tenor } % -- Bari-- bari = {} barisax = \transpose bf g \relative c''{ \global \set Staff.instrumentName = #Bari Sax \set Staff.shortInstrumentName = #Bari \clef treble \bari } % -- Trombone 1-- tbonea = {} trombonea = \relative c { \global \set Staff.instrumentName = #Trombone 1 \set Staff.shortInstrumentName = #Tbn 1 \clef bass \tbonea } % -- Trombone 2-- tboneb= {} tromboneb = \relative c { \global \set Staff.instrumentName = #Trombone 2 \set Staff.shortInstrumentName = #Tbn 2 \clef bass \tboneb } \book { \score { \new StaffGroup = trumpets \new Staff = trpta \trumpeta \new Staff = trptb \trumpetb \new StaffGroup = saxes \new Staff = altoa \altosaxa \new Staff = tenor \tenorsax \new Staff = bari \barisax \new StaffGroup = trombones \new Staff = tbonea \trombonea \new Staff = tboneb \tromboneb } } \book { \score { \new Staff = trumpeta \with { \remove Instrument_name_engraver } \trumpeta \header {piece=Trumpet 1} \layout { indent = 0\mm} } } \book { \score { \new Staff = trumpetb \with { \remove
Re: Replacing \set stanza with custom verseNumber
Tom Dickson-3 wrote: It doesn't work correctly - it appears Scheme doesn't like the second use of the variable? verseNumber = #(define-music-function (parser location markp) (string?) #{ \set vocalName = $markp \set shortVocalName = $markp \override InstrumentName #'X-offset = #2 \override InstrumentName #'font-series = #'bold #}) is what I'm trying - for me it works when i call it like When I call it I get the verse number on subsequent lines, but the first line has no number. I'll try it again (I'm calling it as such: \verseName 1. ) ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: relative mode occasionally gets forgotten?
On 5/15/09 8:43 AM, Mats Bengtsson mats.bengts...@ee.kth.se wrote: Carl D. Sorensen wrote: Music inside a \transpose or \chordmode block is absolute, unless a \relative is included inside the the \transpose or \chordmode block. When \relative blocks are nested, the innermost relative block applies. I don't understand why \chordmode (and \chords) changes back to absolute mode, when \notemode doesn't. Is it just since it's less common that the roots of the chords span several octaves, or is there any other good reason why LilyPond is implemented in this way? I have no idea why LilyPond is implemented in this way. \chords behaves the same as \chordmode because \chords is just equivalent to \new ChordNames \chordmode, which I am sure you already knew. Thanks, Carl ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: relative mode occasionally gets forgotten?
In message 20090515145035.ga3...@nagi, Graham Percival gra...@percival-music.ca writes On Fri, May 15, 2009 at 06:46:39AM -0600, Carl D. Sorensen wrote: First, I think that the information above should be put into 1.1.1 Writing Pitches as examples under Relative octave entry. There should be three separate items/examples: When relative blocks are nested, the innermost relative block applies. \relative c' { d e f \relative c'' { d e f}} Woah, that's froody! I would have never expected that! Note: I haven't tested any of these examples. I tested the above, because I just couldn't believe it. Anyway, I agree with these proposals. When I first saw Chip's example, my reaction was why on earth would you want to do that? As I understand it, \relative converts from note names to absolute pitches. Pretty much everything else in lily works on pitches. In a .ly file you don't know, on seeing a c, which c it is - middle, top, low, whatever. If it's wrapped in a \relative{}, that assigns a pitch to it. Anything else on seeing it assumes it's c in the bass clef as that's the pitch assigned to the note c. So, I don't know how to word it, but when you're talking about \relative in the manual it should say that you should only use \relative immediately around your note names because it converts note names to absolute pitches. If there's another operator inside your \relative (ie in Chip's case, a \transpose, in the example above an inner \relative) that forces absolute pitches, then the \relative will do nothing because it doesn't know what to do with a pitch. Cheers, Wol -- Anthony W. Youngman - anth...@thewolery.demon.co.uk ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Bass in Chord Name
Stjepan Brbot schrieb: Marc Hohl wrote: descried his analysis about chords representation Thanks Marc very very much. Actually your code does not work for me but you pointed me to right direction. I analyzed ly/property-init.ly and scm/chord-name.scm files and functions in them to understand how chord logic works. After several tunings and tries I found very simple solution for my need. I do not even need to change property-init.ly and chord-name.scm. I shouldn't use internal \germanChords directive, but define in my lilypond file the following: \set chordRootNamer = #(chord-name-german-markup #t) Ok, then I have misunderstood this function, I thought that it will use German names for the bass notes , i.e. Fis instead of F#. After this both chords and basses in chords are represented using H and B (not B and Bb). Surprisingly how simple solution became at the end Great! (I know, somethimes I think way too complicated and am astonished to see that there is always a simpler solution...) Greetings Marc ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: relative mode occasionally gets forgotten?
--- Original Message --- From: Anthony W. Youngman lilyp...@thewolery.demon.co.uk To: lilypond-user@gnu.org Sent: 15.5.09, 18:03:43 Subject: Re: relative mode occasionally gets forgotten? In message 20090515145035.ga3...@nagi, Graham Percival gra...@percival-music.ca writes On Fri, May 15, 2009 at 06:46:39AM -0600, Carl D. Sorensen wrote: First, I think that the information above should be put into 1.1.1 Writing Pitches as examples under Relative octave entry. There should be three separate items/examples: When relative blocks are nested, the innermost relative block applies. \relative c' { d e f \relative c'' { d e f}} Woah, that's froody! I would have never expected that! Note: I haven't tested any of these examples. I tested the above, because I just couldn't believe it. Anyway, I agree with these proposals. When I first saw Chip's example, my reaction was why on earth would you want to do that? As I understand it, \relative converts from note names to absolute pitches. Pretty much everything else in lily works on pitches. In a .ly file you don't know, on seeing a c, which c it is - middle, top, low, whatever. If it's wrapped in a \relative{}, that assigns a pitch to it. Anything else on seeing it assumes it's c in the bass clef as that's the pitch assigned to the note c. So, I don't know how to word it, but when you're talking about \relative in the manual it should say that you should only use \relative immediately around your note names because it converts note names to absolute pitches. If there's another operator inside your \relative (ie in Chip's case, a \transpose, in the example above an inner \relative) that forces absolute pitches, then the \relative will do nothing because it doesn't know what to do with a pitch. Cheers, Wol -- Anthony W. Youngman - anth...@thewolery.demon.co.uk I don't know if it's worth mentioning, but you can also run into problems using \repeat inside a \relative block if an \unfoldRepeats is used outside the block. For example in Tune = \relative c' { \partial 4 d4 | \repeat volta 2 { c4 d e g | } } the first c will be relative to the last g on the second play through using \unfoldRepeats. Rewriting as Tune = { \partial 4 d'4 | \repeat volta 2 \relative c' { c4 d e g | } } resolves the problem. I try to make sure I keep \relatives at the innermost block for this reason. Is this a case of programming style, and should the docs cover it? ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: relative mode occasionally gets forgotten?
On May 15, 2009, at 9:54 AM, Chip wrote: Tim McNamara wrote: I'm not sure that the relative mode gets forgotten but that LilyPond follows its own internal rules. I find that LilyPond behaves the way that the manual says it does: it picks the closest pitch. If I write { c2 a2 } it picks the A below that C rather than the A above that C. If I want the A above the C, I write { c2 a'2 } and all is well. Sometimes when I first compile the song there are pitches wildly out of their intended octave; then it's a matter of finding the proper places to change the pitch octaves with ' or , and the problem is usually solved with two or three of these. Pretty quick and simple without needing to resort to sticking \relative commands into the middle of the music information- something I hate doing because it makes it hard to debug the song. Here is an example of the issue I came across - r4 r8 ef~ ef d c bf a4. g8~ g2~ g2-- r In any mode the tied notes are the same octave, of course. But for whatever reason, with the \transpose and the \relative split as originally described, they were in different octaves, which obviously, broke the ties. Putting the \transpose ef f \relative c' together fixed the problem. With the \transpose and \relative split there were quite a few random instances of such odd octave issues, some would be just a single note or two, others 3 or 4 measures of music where almost every other note jumped octaves up and down. It's really a weird thing to see. In my template I typically use \transpose x x \relative x but for whatever reason I don't even recall now I moved the \transpose up to the notes section of the code. I think what I did was entered the notes of the tenor sax part in their actual tenor sax key (and all other instruments in concert key), then \transposed them, the tenor sax notes, down to concert key for the purpose viewing the score entirely in concert key. Thus the tenor sax part had the really wicked octave issue. I recall reading in the documentation for the \transpose command that transposition should be done to or from concert to the target key using C as one of the arguments for \transpose. So, if I write a song that's nominally in Bb for the concert instruments, then for transposing for the Bb horns/Eb horns, etc. is done this way, respectively: \transpose c d (putting the tenor sax chart in C) \transpose c a (putting the also sax chart in G) So my source code in the .ly file is all in concert, modified by the \transpose command. There is a separate .ly file for each transposition, the way I do it, and I print a separate lead sheet for each transposition. There is probably an elegant way to do this from only one .ly file and automagically print separate lead sheets for each instrument in the right key, but I don't know what it is. Now, for orchestral music and such where you have a conductor who needs to see all the parts at once, my approach might not work very well, but for jazz it gets the job done because I don't need all the parts on one sheet. I would think that the It may be that \tranpose ef f is what's creating your problem by confusing LilyPond? ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
jEdit changes file unexpectedly
Hello, I have found a problem with jEdit (probably LilypondTool). I just write a .ly source that contains the word Pincé. I saved the file yesterday. Today I wanted to continue and see that this word has been changed to Pincé. That's a bit annoying. The Pincé is a playing instruction and should be a markup. Do you know a way to save the spelling of it? Since it appears at several places, it's not easy to fix it every time I re-open the file. Regards, Helge ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: missing glissando features (bugs?)
2009/5/15 Marc Hohl m...@hohlart.de: I still don't get it - when I use extra-dy = 0, I get glissando lines parallel to the staff lines, so a value of zero can't be right. I have attached the pdf output, the upmost tab lie is the standard behaviour, the middle line is extra-dy = 0, and the lowest line is the one with my calculated value for extra-dy. Hmm, I don't seem to be doing a very good job of explaining it. :) As I can see, a value of 0 is definitely wrong here, so it seems that a normal score and a tab score handle extra-dy differently. Exactly: as I mentioned earlier in the thread, in engraver-init.ly there's a setting for 'extra-dy in the context definition for TabVoice, whereas there's no setting for normal glissandos. If you have a look at line-spanner.cc you'll find the code which reads 'extra-dy: it uses robust_scm2double () to ensure a sane value is returned (0 in this case) if the property isn't set. To recap, the current behaviour for glissandos is as follows: 1. If a glissando is in a Voice context other than TabVoice, 'extra-dy = #0 unless overridden by the user. 2. In a TabVoice, 'extra-dy = #0.75 for all glissandos, even if they're between notes at different staff-positions. For a TabVoice glissando, we want 'extra-dy to be 0.75/-0.75 for notes at the same staff-position, depending on the change in pitch; otherwise 'extra-dy should be 0, since we don't need to add any extra slope to glissandos between notes at different staff-positions (or do we... see below ;) (if (and (= left-staff-position right-staff-position) ( (ly:pitch-semitones right-pitch) (ly:pitch-semitones left-pitch))) -0.75 0.75 ))) This code can't distinguish between (equal staff-positions right-pitch left-pitch) and (different staff-positions), so will return 0.75 for both situations. Here's a version of the callback which will only apply 'extra-dy if the staff-positions are equal: #(define (glissando::calc-tab-extra-dy grob) (let* ((original (ly:grob-original grob)) (left-bound (ly:spanner-bound original LEFT)) (right-bound (ly:spanner-bound original RIGHT)) (left-pitch (ly:event-property (event-cause left-bound) 'pitch)) (right-pitch (ly:event-property (event-cause right-bound) 'pitch)) (left-staff-position (ly:grob-property left-bound 'staff-position)) (right-staff-position (ly:grob-property right-bound 'staff-position)) (extra-dy (if (= left-staff-position right-staff-position) (if ( (ly:pitch-semitones right-pitch) (ly:pitch-semitones left-pitch)) -0.75 0.75) ;; not on same staff-position - no extra-dy 0))) extra-dy)) Of course, you might prefer to apply 'extra-dy in all cases, since the above places the glissando start and end points on staff-lines (see attached image). :) Regards, Neil \version 2.12.2 \paper { indent = 0 ragged-right = ##f } #(define (glissando::calc-tab-extra-dy grob) (let* ((original (ly:grob-original grob)) (left-bound (ly:spanner-bound original LEFT)) (right-bound (ly:spanner-bound original RIGHT)) (left-pitch (ly:event-property (event-cause left-bound) 'pitch)) (right-pitch (ly:event-property (event-cause right-bound) 'pitch)) (left-staff-position (ly:grob-property left-bound 'staff-position)) (right-staff-position (ly:grob-property right-bound 'staff-position))) (if (and (= left-staff-position right-staff-position) ( (ly:pitch-semitones right-pitch) (ly:pitch-semitones left-pitch))) -0.75 0.75))) #(define (extra-dy-test-a grob) (let* ((original (ly:grob-original grob)) (left-bound (ly:spanner-bound original LEFT)) (right-bound (ly:spanner-bound original RIGHT)) (left-pitch (ly:event-property (event-cause left-bound) 'pitch)) (right-pitch (ly:event-property (event-cause right-bound) 'pitch)) (left-staff-position (ly:grob-property left-bound 'staff-position)) (right-staff-position (ly:grob-property right-bound 'staff-position))) (if (= left-staff-position right-staff-position) (if ( (ly:pitch-semitones right-pitch) (ly:pitch-semitones left-pitch)) -0.75 0.75) ;; not on same staff-position - no extra-dy 0))) #(define (extra-dy-test-b grob) (let* ((original (ly:grob-original grob)) (left-bound (ly:spanner-bound original LEFT)) (right-bound (ly:spanner-bound original RIGHT)) (left-pitch (ly:event-property (event-cause left-bound) 'pitch)) (right-pitch (ly:event-property (event-cause right-bound) 'pitch)) (left-staff-position (ly:grob-property left-bound 'staff-position)) (right-staff-position (ly:grob-property right-bound
Re: jEdit changes file unexpectedly
Am 15.05.2009, 22:05 Uhr, schrieb Helge Kruse helge.kruse-nos...@gmx.net: I have found a problem with jEdit (probably LilypondTool). I just write a .ly source that contains the word Pincé. I saved the file yesterday. Today I wanted to continue and see that this word has been changed to Pincé. That's a bit annoying. The Pincé is a playing instruction Do you know a way to save the spelling of it? Since it appears at several places, it's not easy to fix it every time I re-open the file. Look at 3.3.3 Text encoding in the Notation Reference. Especially: ...The easiest way to enter such text is by using a Unicode-aware editor and saving the file with UTF-8 encoding... in jEdit you can set the default charakter encoding under Utilities-Global Options / jEdit / Encodings or just for the buffer under Utilities-Buffer Options: Chakter encoding Henning ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: relative mode occasionally gets forgotten?
In message 200905151909580...@1654122929, David Pounder pound...@lineone.net writes --- Original Message --- From: Anthony W. Youngman lilyp...@thewolery.demon.co.uk To: lilypond-user@gnu.org Sent: 15.5.09, 18:03:43 Subject: Re: relative mode occasionally gets forgotten? In message 20090515145035.ga3...@nagi, Graham Percival gra...@percival-music.ca writes On Fri, May 15, 2009 at 06:46:39AM -0600, Carl D. Sorensen wrote: First, I think that the information above should be put into 1.1.1 Writing Pitches as examples under Relative octave entry. There should be three separate items/examples: When relative blocks are nested, the innermost relative block applies. \relative c' { d e f \relative c'' { d e f}} Woah, that's froody! I would have never expected that! Note: I haven't tested any of these examples. I tested the above, because I just couldn't believe it. Anyway, I agree with these proposals. When I first saw Chip's example, my reaction was why on earth would you want to do that? As I understand it, \relative converts from note names to absolute pitches. Pretty much everything else in lily works on pitches. In a .ly file you don't know, on seeing a c, which c it is - middle, top, low, whatever. If it's wrapped in a \relative{}, that assigns a pitch to it. Anything else on seeing it assumes it's c in the bass clef as that's the pitch assigned to the note c. So, I don't know how to word it, but when you're talking about \relative in the manual it should say that you should only use \relative immediately around your note names because it converts note names to absolute pitches. If there's another operator inside your \relative (ie in Chip's case, a \transpose, in the example above an inner \relative) that forces absolute pitches, then the \relative will do nothing because it doesn't know what to do with a pitch. Cheers, Wol -- Anthony W. Youngman - anth...@thewolery.demon.co.uk I don't know if it's worth mentioning, but you can also run into problems using \repeat inside a \relative block if an \unfoldRepeats is used outside the block. For example in Tune = \relative c' { \partial 4 d4 | \repeat volta 2 { c4 d e g | } } the first c will be relative to the last g on the second play through using \unfoldRepeats. Rewriting as Tune = { \partial 4 d'4 | \repeat volta 2 \relative c' { c4 d e g | } } resolves the problem. I try to make sure I keep \relatives at the innermost block for this reason. Is this a case of programming style, and should the docs cover it? Han-Wen gave me a resetOctave function that deals with this. I don't know if it's made its way into the docs, though. Cheers, Wol -- Anthony W. Youngman - anth...@thewolery.demon.co.uk ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Quoting everything from another voice
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 The notation reference states in section 1.6.3 that \quoteDuring is typically used for two instruments that play the same notes during a passage of music. Unfortunately, quoteDuring quotes only notes, rests and ties, but not dynamics, slurs, other markup etc. Thus in its plain vanilla form it is not suitable for passages where one instrument playes colla parte with another, since all markings will be missing in the instrumental score... One snippet in that section shows how one can prevent rests from being quoted (using the quotedEventTypes list), but it does not mention how can can exactly duplicate from another instrument. What is the correct value for quotedEventTypes to really quote everything, including dynamics, markups, tempo changes, key/clef/time changes, etc.? Is there any pre-defined list of all available event types that can be used? As an example I'm attaching a file, where \bb quotes everything from \aa, but in the output only the notes appear, but no key/clef/time, tempo change, markup, dynamic markings, articulartions, etc. Cheers, Reinhold - -- - -- Reinhold Kainhofer, reinh...@kainhofer.com, http://reinhold.kainhofer.com/ * Financial Actuarial Math., Vienna Univ. of Technology, Austria * http://www.fam.tuwien.ac.at/, DVR: 0005886 * LilyPond, Music typesetting, http://www.lilypond.org -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.9 (GNU/Linux) iD8DBQFKDej0TqjEwhXvPN0RAqecAJ9hKTKKvuE7qYDb8W2ukQTvlunYsACgpg3f onjx9FL/oPfGUpIoOFP7NTM= =LwJm -END PGP SIGNATURE- \version 2.13.1 \pointAndClickOff aa = \relative c'' { \time 3/4 \key c \minor \clef bass \tempo Adagio c,4(\ff\ g8)_test g8-.-| a4 | \time 4/4 \key as \minor \clef tenor \tempo Andante 4=35 c4(\ff\ g8)_test g8-.-| a2 | } \addQuote #a \aa bb = \relative c'' { \time 3/4 \key c \minor \mark Quoted part: \quoteDuring #a { s2. | s1 } \mark Manually written: c4(\ff\ g8)_test g8-.-| a2 | } \new Score \new Staff {\aa} \new Staff {\bb} % The following score should contain everything, as if \time, \key, \clef, \tempo, -., -|, \ff, etc were written directly in \bb \new Score \new Staff {\bb} test.pdf Description: Adobe PDF document ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: relative mode occasionally gets forgotten?
On 5/15/09 3:06 PM, Anthony W. Youngman lilyp...@thewolery.demon.co.uk wrote: In message 200905151909580...@1654122929, David Pounder pound...@lineone.net writes I don't know if it's worth mentioning, but you can also run into problems using \repeat inside a \relative block if an \unfoldRepeats is used outside the block. For example in Tune = \relative c' { \partial 4 d4 | \repeat volta 2 { c4 d e g | } } the first c will be relative to the last g on the second play through using \unfoldRepeats. Rewriting as Tune = { \partial 4 d'4 | \repeat volta 2 \relative c' { c4 d e g | } } resolves the problem. I try to make sure I keep \relatives at the innermost block for this reason. Is this a case of programming style, and should the docs cover it? Han-Wen gave me a resetOctave function that deals with this. I don't know if it's made its way into the docs, though. I just use the octave check construct and ignore the warning. Carl ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Quoting everything from another voice
On 5/15/09 4:13 PM, Reinhold Kainhofer reinh...@kainhofer.com wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 The notation reference states in section 1.6.3 that \quoteDuring is typically used for two instruments that play the same notes during a passage of music. Unfortunately, quoteDuring quotes only notes, rests and ties, but not dynamics, slurs, other markup etc. Thus in its plain vanilla form it is not suitable for passages where one instrument playes colla parte with another, since all markings will be missing in the instrumental score... One snippet in that section shows how one can prevent rests from being quoted (using the quotedEventTypes list), but it does not mention how can can exactly duplicate from another instrument. What is the correct value for quotedEventTypes to really quote everything, including dynamics, markups, tempo changes, key/clef/time changes, etc.? Is there any pre-defined list of all available event types that can be used? As an example I'm attaching a file, where \bb quotes everything from \aa, but in the output only the notes appear, but no key/clef/time, tempo change, markup, dynamic markings, articulartions, etc. Given your expertise in LilyPond, I hesitate to chime in here, but Why do you need to quote instead of just putting everything in a variable and including it in both voices? Carl ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Quoting everything from another voice
On Fri, May 15, 2009 at 3:13 PM, Reinhold Kainhofer reinh...@kainhofer.com wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 The notation reference states in section 1.6.3 that \quoteDuring is typically used for two instruments that play the same notes during a passage of music. Unfortunately, quoteDuring quotes only notes, rests and ties, but not dynamics, slurs, other markup etc. Thus in its plain vanilla form it is not suitable for passages where one instrument playes colla parte with another, since all markings will be missing in the instrumental score... One snippet in that section shows how one can prevent rests from being quoted (using the quotedEventTypes list), but it does not mention how can can exactly duplicate from another instrument. What is the correct value for quotedEventTypes to really quote everything, including dynamics, markups, tempo changes, key/clef/time changes, etc.? Is there any pre-defined list of all available event types that can be used? Yes, the tree of all event types is listed in scm/define-event-types.scm. I just tried adding this override, and it seemed to work: \set Staff.quotedEventTypes = #'(StreamEvent) -Patrick ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Quoting everything from another voice
On Fri, May 15, 2009 at 3:50 PM, Patrick McCarty pnor...@gmail.com wrote: On Fri, May 15, 2009 at 3:13 PM, Reinhold Kainhofer Is there any pre-defined list of all available event types that can be used? Yes, the tree of all event types is listed in scm/define-event-types.scm. Sorry, I meant scm/define-event-classes.scm. -Patrick ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Creating harmonized lines
Is LilyPond capable of generating harmonized lines of notes? For example, say I have: \key g \major \melody { c8 d8 e8 fis8 g1 } for one instrument and I want a second instrument to play a harmonized line a third up from that (e.g., { e8 fis8 g8 a8 b1 } ), is there a command for LilyPond to do this? Using \transpose c e would apply a major third interval to all the notes, resulting in the harmony line not being within the key of G. I can of course just do this by hand, but I was looking for the automagical way if it exists. I have not been able to find anything in the documentation, the mailing list archives (other than a discussion about how \transpose does not do diatonic transposition) or the snippet repository that would point to this capability. Maybe I should just stop being lazy... Tim ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Quoting everything from another voice
2009/5/15 Patrick McCarty pnor...@gmail.com: On Fri, May 15, 2009 at 3:50 PM, Patrick McCarty pnor...@gmail.com wrote: On Fri, May 15, 2009 at 3:13 PM, Reinhold Kainhofer Is there any pre-defined list of all available event types that can be used? Yes, the tree of all event types is listed in scm/define-event-types.scm. Sorry, I meant scm/define-event-classes.scm. IR 1.2 also lists them. You could use #'(music-event) instead of #'(StreamEvent). When I last looked at this, I came to the conclusion that it's not currently possible to quote everything since some items don't have events. For example, time signatures and tempo marks rely on property settings, which can't be quoted. I tried hacking the code in part-combiner.scm (recording-group-emulate), but couldn't even get a simple \override to be quoted. Regards, Neil ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: relative mode occasionally gets forgotten?
--- Original Message --- From: Carl D. Sorensen c_soren...@byu.edu To: Anthony W. Youngman lilyp...@thewolery.demon.co.uk, lilypond-user@gnu.org lilypond-user@gnu.org Sent: 15.5.09, 23:43:07 Subject: Re: relative mode occasionally gets forgotten? On 5/15/09 3:06 PM, Anthony W. Youngman lilyp...@thewolery.demon.co.uk wrote: In message 200905151909580...@1654122929, David Pounder pound...@lineone.net writes I don't know if it's worth mentioning, but you can also run into problems using \repeat inside a \relative block if an \unfoldRepeats is used outside the block. For example in Tune = \relative c' { \partial 4 d4 | \repeat volta 2 { c4 d e g | } } the first c will be relative to the last g on the second play through using \unfoldRepeats. Rewriting as Tune = { \partial 4 d'4 | \repeat volta 2 \relative c' { c4 d e g | } } resolves the problem. I try to make sure I keep \relatives at the innermost block for this reason. Is this a case of programming style, and should the docs cover it? Han-Wen gave me a resetOctave function that deals with this. I don't know if it's made its way into the docs, though. I just use the octave check construct and ignore the warning. Carl That works, but makes it harder to see useful warnings as they fly up the screen. I suppose it just comes down to personal preference - it took me a couple of years to realise I could get rid of the warnings by changing where I put the \relatives - so to speak. Dave. ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: changing grob properties?
2009/5/15 Marc Hohl m...@hohlart.de: Upto now, I have achieved to make tablature fret numbers invisible which are tied to another note. But I don't know how to add parentheses to the numbers that are tied but show up after a line break (for example the first note in measure 5, see attachment). I tried something like (set! (ly:music-property note 'elements) (cons (make-music 'NoteEvent 'parenthesize #t) (ly:music-property note 'elements))) but I realized that a grob is not a music expression as the variable called note in the code fragment above. Indeed, once the grob's been created it's too late to be setting music properties. Then I came up with the vague idea to combine the TabNoteHead-Stencil with the stencil for the parentheses, but this was beyond my knowledge, it didn't work. It won't work, since the stencil callback for parentheses has some rather specific requirements which are set in the Parenthesis_engraver. You could use markup to place the parentheses around the TabNoteHead, but unless I'm mistaken, that's not possible inside a callback for 'after-line-breaking, since it's called after stencils have been generated. \version 2.12.2 #(define (tie::handle-tab-tie grob) (let* ((original (ly:grob-original grob)) (tied-tabnotehead (ly:spanner-bound original RIGHT)) Should be (ly:spanner-bound grob RIGHT). The unbroken grob is only used to obtain the list of broken spanners, if there are any (remember that this callback will be called for every tie, including those which aren't split). (siblings (if (ly:grob? original) (ly:spanner-broken-into original) '() ))) (if (and (= (length siblings) 2) (eq? (car (last-pair siblings)) grob)) ;; tie is split ;; just a dummy function here, parentheses should be inserted (begin (ly:grob-set-property! tied-tabnotehead 'transparent #f) It would be easier to see whether this is actually working on the correct grob if you changed the override to 'color. (newline) (display Tie is split.) (newline)) ;; tie is not split - make fret number invisible (ly:grob-set-property! tied-tabnotehead 'transparent #t) );; end if )) test = \relative c { f2 ~ f4 \parenthesize e g8 g ~ g g ~ g g~ g g ~ g1 c1 ~ \break c2 ~ c c\3 e\2 g\1 4 c\3 e\2 g\1 ~ c\3 e\2 g\1 c\3 e\2 g\1 \bar |. } \score { \new Staff { \clef G_8 \test } \new TabStaff { \clef tab \override Tie #'stencil = #tie::handle-tab-tie Should be \override Tie #'after-line-breaking = #tie::handle-tab-tie There's no stencil returned by the function, which is why you're getting loads of programming errors and invisible ties. Regards, Neil ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Re: Pedal problem
gnomino wrote: However, the pedal bracket appears disjointed and uneven. Is there any way I can fix this? Here's one way of doing it. Off hand, I don't know if there's a more elegant solution, but there might be. Anyway, the idea for this comes from this snippet: http://lilypond.org/doc/v2.13/input/lsr/lilypond-snippets/Expressive-marks#Piano-template-with-centered-dynamics Basically I just replaced Dynamics with Pedals and removed unnecessary lines. HTH. - Mark \version 2.13.0 \layout { % define Pedals context \context { \type Engraver_group \name Pedals \consists Output_property_engraver \consists Piano_pedal_engraver \consists Script_engraver \consists Skip_event_swallow_translator \consists Axis_group_engraver pedalSustainStrings = #'(Ped. *Ped. *) pedalUnaCordaStrings = #'(una corda tre corde) \override VerticalAxisGroup #'minimum-Y-extent = #'(-1 . 1) pedalSustainStyle = #'bracket } % modify PianoStaff context to accept Pedals context \context { \PianoStaff \accepts Pedals } } susOn = \sustainOn susOff = \sustainOff \new PianoStaff \new Staff { c'4 c' c' c' } \new Staff { \times 4/6 { c'4 c' c' c' c' c' } } \new Pedals { s4\susOn s\susOff\susOn s\susOff\susOn s\susOff\susOn } attachment: pedal-bracket.png___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user
Pedal problem
not top-posting Hello, I'm trying to typeset two staves with different rhythms and pedalling that starts/stops on the notes in the top staff, but appears below the second staff. I tried the following: \new PianoStaff \new Staff { c'4 c'4 c'4 c'4 } \new Staff \set Staff.pedalSustainStyle = #'bracket \times 4/6 { c'4 c'4 c'4 c'4 c'4 c'4 } { s4\sustainOn s4\sustainOff\sustainOn s4\sustainOff\sustainOn s4\sustainOff\sustainOn } However, the pedal bracket appears disjointed and uneven. Is there any way I can fix this? (I'm using 2.13.0) Thanks in advance. ___ lilypond-user mailing list lilypond-user@gnu.org http://lists.gnu.org/mailman/listinfo/lilypond-user