lilypond-user
[Top][All Lists]
Advanced

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

Re: GridLine appearance


From: Pierre Perol-Schneider
Subject: Re: GridLine appearance
Date: Fri, 3 Apr 2015 21:46:27 +0200

Glad to hear, nice output!
Cheers,
Pierre

2015-04-03 16:00 GMT+02:00 James Worlton <address@hidden>:
Just to follow up: Using Pierre's myArrow and myGridLinesBis code, I am able to produce the image in the result which is exactly what I was looking for. Thanks again! LilyPond rocks, as do the geniuses that come up with solutions to strange requests!

James Worlton

On Fri, Apr 3, 2015 at 7:36 AM, James Worlton <address@hidden> wrote:
Thank you, Pierre. This looks like it will work!

James W

On Fri, Apr 3, 2015 at 3:09 AM, Pierre Perol-Schneider <address@hidden> wrote:
Hi James,

I'm not sure about that advantages of using grid lines.
How about something like:

\version "2.19.17"

musicA = {
  c'4 c' c' c'
}

musicB = {
  b4 b b c'''
}

verticalLine = ^\markup {

  %% to cross staves simply add: 
  \with-dimensions #'(0 . 0) #'(0 . 0)
  \center-column {
    \arrow-head #Y #UP ##t
    \draw-dashed-line #'(0 . 10)
  }
}

myArrow = #(define-music-function (parser location arg-arrow) (number?)
     #{
       -\markup {
          %% to cross staves simply add:
          \with-dimensions #'(0 . 0) #'(0 . 0)
          \center-column {
            \arrow-head #Y #UP ##t
            \draw-dashed-line #`(0 . ,arg-arrow)
          }
        }
     #})

myGridLines = {
  s4\verticalLine s s s\verticalLine
}

myGridLinesBis = {
  s4^\myArrow 10 s s s^\myArrow 7
}

<<
  \new Staff \musicA
  \new Dynamics \myGridLines
  \new Staff { s1 }
  \new Staff \musicB
>>

<<
  \new Staff \musicA
  \new Dynamics \myGridLinesBis
  \new Staff { s1 }
  \new Staff \musicB
>>


Hope that helps,

Cheers,
Pierre

2015-04-03 4:50 GMT+02:00 James Worlton <address@hidden>:
Hello,

In my score I have a section where I need a line from one part to cross other staves and point to another part. I've been able to adapt GridLine to appear when I need it, but I'd like to change the appearance: specifically, make the line dashed and add an arrow at the top. I do not need this in the parts, it is mainly for the conductor's reference. The parts will be cued another way.

The code below combines the two possibilities I can think of and shows where I've gotten to. The problems are I can't figure out how to make the markup version NOT affect the spacing between staves, and just draw over the top of them; or alternatively, how to get GridLine to be dashed with an arrowhead on top. I'd prefer the GridLine solution, since that will stretch vertically with the system if necessary.

Is this possible with GridLine? If not, is it possible with a markup?

\version "2.19.17"

musicA = {
  c'4 c' c' c'
}

verticalLine = ^\markup {
  \center-column {
    \arrow-head #Y #UP ##t
    \draw-dashed-line #'(0 . 18)
  }
}

musicB = {
  \override Score.GridLine.extra-offset = #'(0.0 . 2.0)
  \override Score.GridLine.line = #'dashed
  \hide Score.GridLine
  b4\verticalLine b b \revert Score.GridLine.transparent b
}

\score {
  <<
    \new Staff { \musicA }
    \new Staff \with {
      \consists "Grid_point_engraver"
      gridInterval = #(ly:make-moment 1/4)
    } { s1 }
    \new Staff \with {
      \consists "Grid_point_engraver"
      gridInterval = #(ly:make-moment 1/4)
    } { \musicB }
  >>
  \layout {
    \context {
      \Score
      \consists "Grid_line_span_engraver"
      \override NoteColumn.X-offset = #-0.5
    }
  }
}

Thanks!
James Worlton

_______________________________________________
lilypond-user mailing list
address@hidden
https://lists.gnu.org/mailman/listinfo/lilypond-user





reply via email to

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