Re: The demise of ly:multi-measure-rest::percent

2024-05-03 Thread Richard Shann
On Fri, 2024-05-03 at 18:01 +0200, Hans Aikema wrote:
> 
> 
> > On 3 May 2024, at 15:34, Richard Shann 
> > wrote:
> > 
> > On Fri, 2024-05-03 at 09:25 -0400, Kieren MacMillan wrote:
> > > Hi Richard,
> > > 
> > > > > is there a reason you don't use \repeat percent in the first
> > > > > place ?
> > > > It's easier for users of Denemo to have a single piece of
> > > > LilyPond
> > > > syntax at the place they want to see the "%"
> > > 
> > > How is this
> > > 
> > >   \repeat percent 2 { c c c c }
> > > 
> > > not “a single piece of Lilypond syntax at the place they want to
> > > tsee
> > > the "%"?
> > 
> > The user sees "\repeat percent 2" then the notes c c c c and then a
> > "}"
> > - something before the notes and something after, "after" being
> > where
> > they get the "%" appearing in the typeset.
> > You can insert such syntax with Denemo, but most users would get
> > tripped up, they want to put in the notes then the "%" and then
> > carry
> > on with more stuff. 
> > 
> > Richard
> 
> If I were to see such a source,

you wouldn't do it if you were going to look at the "source", you would
use the nice LilyPond syntax that is for the purpose. There is nothing
to stop you doing that in Denemo. But you would have to be aware of the
"source" which most users are not.

>  with rests where notes are supposed to be I think I’d start
> screaming and shouting what kind of an idiot put a rest where there
> is music.
> 
> Apparently humans differ in there preferences

No, I think all humans would share that preference to look at clean
LilyPond if looking at LilyPond code is what they wanted to do. The
reason I got involved with Denemo is that I wanted to generate the
syntax for figured bass by playing the relevant notes, rather than
entering a string of <6 4> <5 3> codes that had to match up with the
durations of the notes written elsewhere in the file - i.e. I wanted a
quick and musical way of getting a lovely typeset. It worked - I have
about a thousand sonatas typeset to prove it.

best wishes,

Richard





Re: The demise of ly:multi-measure-rest::percent

2024-05-03 Thread Richard Shann
On Fri, 2024-05-03 at 09:25 -0400, Kieren MacMillan wrote:
> Hi Richard,
> 
> > > is there a reason you don't use \repeat percent in the first
> > > place ?
> > It's easier for users of Denemo to have a single piece of LilyPond
> > syntax at the place they want to see the "%"
> 
> How is this
> 
>   \repeat percent 2 { c c c c }
> 
> not “a single piece of Lilypond syntax at the place they want to tsee
> the "%"?

The user sees "\repeat percent 2" then the notes c c c c and then a "}"
- something before the notes and something after, "after" being where
they get the "%" appearing in the typeset.
You can insert such syntax with Denemo, but most users would get
tripped up, they want to put in the notes then the "%" and then carry
on with more stuff. 

Richard


> 
> Just curious!
> Kieren.
> __
> 
> My work day may look different than your work day. Please do not feel
> obligated to read or respond to this email outside of your normal
> working hours.
> 




Re: The demise of ly:multi-measure-rest::percent

2024-05-03 Thread Richard Shann
On Fri, 2024-05-03 at 13:04 +0200, Xavier Scheuer wrote:
> On Fri, 3 May 2024 at 12:43, Richard Shann 
> wrote:
> > 
> > In earlier versions of LilyPond I avoided the use of \repeat
> > percent 2
> > {} syntax by overwriting the stencil for a whole bar rest:
> > 
> > \version "2.20.0"
> > { c c c c
> > \once \override MultiMeasureRest.stencil  = #ly:multi-measure-
> > rest::percent
> > \once \override MultiMeasureRest #'thickness = #0.48
> > R1*4/4
> > }
> > 
> > The stencil ly:multi-measure-rest::percent has gone in versin 2.24
> > and
> > I see that the symbol ly:percent-repeat-interface::percent at the
> > same
> > place in the source code. However this results in the "%" glyph not
> > being centered as was the old one:
> > 
> > \version "2.24.0"
> > { c c c c
> > \once \override MultiMeasureRest.stencil  = #ly:percent-repeat-
> > interface::percent
> > \once \override MultiMeasureRest #'thickness = #0.48
> > R1*4/4
> > }
> > 
> > Is there an easy fix - the extra-offset needed varies according to
> > the
> > width of the bar...
> 
> Hello,
> 
> Not replying to your question but is there a reason you don't use
> \repeat percent in the first place ?
It's easier for users of Denemo to have a single piece of LilyPond
syntax at the place they want to see the "%"
> And what about using "makePercent" as described in NR 1.4.2?
> 
> makePercent =
> #(define-music-function (note) (ly:music?)
>    "Make a percent repeat the same length as NOTE."
>    (make-music 'PercentEvent
>                'length (ly:music-length note)))
> 
> \relative c'' {
>   \makePercent s1
> }

That's perfect - a great improvement over the original :)
Thank you very much.
Richard

> 
> Kind regards,
> Xavier




The demise of ly:multi-measure-rest::percent

2024-05-03 Thread Richard Shann
In earlier versions of LilyPond I avoided the use of \repeat percent 2
{} syntax by overwriting the stencil for a whole bar rest:

\version "2.20.0"
{ c c c c
\once \override MultiMeasureRest.stencil  = #ly:multi-measure-rest::percent 
\once \override MultiMeasureRest #'thickness = #0.48
R1*4/4
}

The stencil ly:multi-measure-rest::percent has gone in versin 2.24 and
I see that the symbol ly:percent-repeat-interface::percent at the same
place in the source code. However this results in the "%" glyph not
being centered as was the old one:

\version "2.24.0"
{ c c c c
\once \override MultiMeasureRest.stencil  = 
#ly:percent-repeat-interface::percent
\once \override MultiMeasureRest #'thickness = #0.48
R1*4/4
}

Is there an easy fix - the extra-offset needed varies according to the
width of the bar...

Richard Shann






Re: Figured bass

2024-04-25 Thread Richard Shann
On Thu, 2024-04-25 at 01:15 +0300, Dimitri Sykias wrote:
> Hi Jacob
> Thanks for the reply.
> When I use for ex. (Version "2.24.1”)
> \figures {
>     \override FiguredBass.BassFigure.font-size = #2
>     <6- 4> <6> <6- 4-> <_-> <5-> <5+ _+> < 5- _-> <6 _+> <_+> <5- _-
> >}
> accidentals are placed at the left side of the number. 
> 
> > On 25 Apr 2024, at 1:10 AM, Jakob Pedersen 
> > wrote:
> > 
> >  
> >  Hi Dimitri
> >  
> >  Isn't that the standard as shown in the example?
> > http://lilypond.org/doc/v2.24/Documentation/notation/figured-bass

This example is the "standard" - not the default - if you click on it
you see it uses:

 \set figuredBassAlterationDirection = #RIGHT
  \set figuredBassPlusDirection = #RIGHT
  \override BassFigureAlignment.stacking-dir = #DOWN

and the first of these is what you need. 
HTH
Richard





Re: Help need with the "implicitBassFigures" command

2024-01-12 Thread Richard Shann
On Thu, 2024-01-11 at 12:40 +, Eef Weenink wrote:
> Thank you Richard
> 
> You say: “ 
> You don't have to use 5 as the implicit figure:”
> 
> Try:
> -
> 
>     \new FiguredBass \with { implicitBassFigures = #'(0) }   
> \figuremode {
>   \set figuredBassAlterationDirection = #RIGHT
>   \set figuredBassPlusDirection = #RIGHT
>   \override BassFigureAlignment.stacking-dir = #DOWN
>   <6 5->8 <0 4->8
> --
> 
> So my choosing the number as “0” (or any other). I can use that
> number instead of the original to have it surpressed.
> Good to know. For pratical reasons (not getting lost in my scores ☺ )
> I will set this everytime to “5” or what number needed (in figured
> bass, I know about the 5 not being needed to mention, because if
> nothing written it is always 5.

If you think about it, that's not true! There are many notes which
remain unfigured where it is left to the performer to judge that a
change of harmony is not required. Indeed, usually the majority of
notes.
And conversely, you do see the 5 even when it is not the resolution of
a suspension.

>  Maybe also some other numbers to surpress? )

Well, just to keep track of what the figure being suppressed is, you
could use 55 in your implicitBassFigures list - it would mean you only
have to declare the list once. Then you would write the figure 55 for
those 5's which are being suppressed.

I have to say that if I came across your example in performance I would
imagine it was the 6 on the note earlier that was being extended. But
then, as the figures are appearing below the staff, the figures are
perhaps intended for academic use only?

Richard Shann



> Anyway most clear is to implicitBassFigures=”5” and write 5
> 
> To ease my life: 
> declare in the beginning: 
> -
> extendOn = \bassFigureExtendersOn
> extendOnImpFive = { \bassFigureExtendersOn 
> \set implicitBassFigures = #'(5)}
> extendOff = {\bassFigureExtendersOff 
> \set implicitBassFigures = #'()}
> ---
> use as needed
> 
> 
> Regards, Eef




Re: Help need with the "implicitBassFigures" command

2024-01-11 Thread Richard Shann
On Thu, 2024-01-11 at 10:43 +, Eef Weenink wrote:
> Good day to all of you.
> 
> I am working on a figured bass, and now it is needed to get an
> extended line under two notes, not showing the number:
> Afbeelding met lijn, Lettertype, ontvangst, tekst
> 
> Automatisch gegenereerde beschrijving
> The line under the d and e have the meaning: Read as 5 and extend to
> next note.
> I made this using this command: 
>   \new FiguredBass \with { implicitBassFigures = #'(5) }
>  
> But this surpresses ALL the “fives” in the fragment. It I set it to
> “0” or leave it out, I see this:
> Afbeelding met Lettertype, lijn, muziek
> 
> Automatisch gegenereerde beschrijving
> Only the 5 at d and e should be surpressed. So I input these lines: 
> <5 4->8
>   \extendOn
>   \set Staff.implicitBassFigures = #'(5)
>   %{if I set the implicitBass to 5, or other number, it DOES NOT
> do anything%}
>   <5 3>4
>   \set Staff.implicitBassFigures = #'(0)
> 
> Big puzzle now is how to get this to work. I read somewhere this
> would be caused by combination of implicitBassfigures and
> \bassFigureExtendersOn.
> However it is no option to leave \bassFigureExtendersOn out (I would
> not get the line I need).
> 
> For testing, here is the example I used: 
> %%---
> \version "2.24.3"
>  
> extendOn = \bassFigureExtendersOn
> extendOff = \bassFigureExtendersOff
>  
> \score {
>   \new StaffGroup <<
>     \new Staff = "violone" \with {
>   instrumentName = \markup {
>     \center-column { Violone, \line { e Cembalo. } }
>   }
>     }
>     {
>   \time 4/4
>   \clef bass
>   fis8 d8 e8 fis8 g8 g,4 g16 f
>     }
>  
>     \new FiguredBass \with { implicitBassFigures = #'(0) }
>     %{if I set the implicitBass to 5, or other number, it works for
> the whole passage%}
>     \figuremode {
>   \set figuredBassAlterationDirection = #RIGHT
>   \set figuredBassPlusDirection = #RIGHT
>   \override BassFigureAlignment.stacking-dir = #DOWN
>   <6 5->8 <5 4->8
>   \extendOn
>   \set Staff.implicitBassFigures = #'(5)
>   %{if I set the implicitBass to 5, or other number, it DOES NOT
> do anything%}
>   <5 3>4 
>   \set Staff.implicitBassFigures = #'(0)
>   \extendOff <5 _+>8
>   <7>8 <6>8 <5>4
> }
>   >>
> }
> %%
You don't have to use 5 as the implicit figure:

Try:
\version "2.24.3"
 
extendOn = \bassFigureExtendersOn
extendOff = \bassFigureExtendersOff
 
\score {
  \new StaffGroup <<
\new Staff = "violone" \with {
  instrumentName = \markup {
\center-column { Violone, \line { e Cembalo. } }
  }
}
{
  \time 4/4
  \clef bass
  fis8 d8 e8 fis8 g8 g,4 g16 f
}
 
\new FiguredBass \with { implicitBassFigures = #'(0) }
%{if I set the implicitBass to 5, or other number, it works for the
whole passage%}
\figuremode {
  \set figuredBassAlterationDirection = #RIGHT
  \set figuredBassPlusDirection = #RIGHT
  \override BassFigureAlignment.stacking-dir = #DOWN
  <6 5->8 <0 4->8
  \extendOn
 % \set Staff.implicitBassFigures = #'(5)
  %{if I set the implicitBass to 5, or other number, it DOES NOT do
anything%}
  <0 3>4
  \set Staff.implicitBassFigures = #'(0)
  \extendOff <5 _+>8
  <7>8 <6>8 <5>4
}
  >>
}
%%

Richard




Re: WARNING: SPAM / MALWARE being sent to list members

2023-10-23 Thread Richard Shann
specifically, if you get an email with a name you recognize check the
email address is the one that person usually uses (mine purported to
come from Jean-Abou but the email address was spurious).
Richard
On Mon, 2023-10-23 at 12:01 -0400, Rik Kabel wrote:
> The following turd was sent to me this morning. I have removed the
> link so that it is not accidentally activated.
> The email source is full of faked headers.
> Be careful about what you open and click on.
> -- 
>  Rik
> 
>  
>   Forwarded Message  
> >  
> > Subject:Re: Where did the \header number go?
> > Date:   Mon, 23 Oct 2023 08:15:20 -0600
> > From:   Panix 
> > To: r...@panix.com
> > 
> >  
> >  
> > Check document: SPAM LINK REMOVED
> > 
> > On 8/20/2023 11:35 AM, Jean Abou Samra wrote:
> >   
> > Le dimanche 20 août 2023 à 10:54 -0400, Rik Kabel a écrit :
> > Hello list,
> > I have a few pieces that have been engraved for my choir with
> > 2.18.10 that include catalog numbers entered as
> >  
> > \header {
> >    ...
> >    number = \markup { \fontsize #4 \sans \ellipse 11B }
> >    ...
> >  }
> > The number variable seems to be gone with current versions, and I
> > can find no mention of the change.
> > Has another feature taken its place?
> > 
> > 
> > I could not see any effect of adding number = "foo" to a \header
> > block in 2.18.0, and I did not find any trace of this in the source
> > code of that version either?
> > 
> > Maybe you redefined a title using one of the xxxTitleMarkup
> > variables, and you used \fromproperty #'header:number there?
> > 
> > Or maybe you're just confusing this with the 'opus' variable?
> > 
> > Sorry for the noise.
> > The number was set in a bookTitleMarkup block in the paper
> > definition.




Re: Fingering orientations

2023-09-17 Thread Richard Shann
On Sun, 2023-09-17 at 14:58 +0200, Jean Abou Samra wrote:
> Le dimanche 17 septembre 2023 à 12:56 +0100, Richard Shann a écrit :
> > I can't figure out why this:
> > 
> > \version "2.24.0"
> > {
> >     \set fingeringOrientations = #'( left right up down)  > ''-1
> > e ''-2 g''-3 >
> > }
> > 
> > outputs the 0 and 3 fingerings down and up respectively and the
> > other
> > two right with nothing on left.
> > 
> > Is there a limitation to two note chords? Or what?
> > I'm consulting
> > https://lilypond.org/doc/v2.24/Documentation/notation/direction-and-placement
> 
> 
> fingeringOrientations isn't a list with one entry per fingering. It's
> a list of orientations that LilyPond is *allowed* to choose for
> fingerings. It will always prefer putting fingerings on the right
> rather than on the left, if allowed to.

Oh, I see, thank you. I've realised I gave the wrong link to the page I
read that mentioned fingeringOrientations, it was in "Selected
Snippets" I can't in fact find where this variable is described...

Richard

> 
> 
> Best,
> Jean
> 




Fingering orientations

2023-09-17 Thread Richard Shann
I can't figure out why this:

\version "2.24.0"
{
\set fingeringOrientations = #'( left right up down) 
}

outputs the 0 and 3 fingerings down and up respectively and the other
two right with nothing on left.

Is there a limitation to two note chords? Or what?
I'm consulting
https://lilypond.org/doc/v2.24/Documentation/notation/direction-and-placement

Richard Shann




Re: Bar numbers on Dynamics staff above music

2023-08-28 Thread Richard Shann
On Mon, 2023-08-28 at 11:27 +0200, Xavier Scheuer wrote:
> On Mon, 28 Aug 2023 at 10:17, Richard Shann 
> wrote:
> > 
> > There are more problems than I thought with your solution-
> > here is your example with some higher notes in it - the bar numbers
> > leave the staff again:
> 
> Hello,
> 
> Removing "Bar_number_engraver" from the Score context and adding it
> to the Staff context (or the first staff with \with if you have more
> than one staff) will get the bar numbers onto the staff.
> It should give you the same bar number positioning as if the Dynamics
> context was not above your staff.
> If you have some overrides, change them from the Score context to the
> Staff context as well.
> 
> \layout {
>   \context {
>     \Score
>     \remove "Bar_number_engraver"
>   }
>   \context {
>     \Staff  % if more than one Staff, use \with for the first Staff
> in your \score block
>     \consists "Bar_number_engraver"
>     \override BarNumber.break-visibility = #end-of-line-invisible
>     barNumberVisibility = #(every-nth-bar-number-visible 1)
>   }
> }
> 
Perfect! Thank you so much.

Richard

> Kind regards,
> Xavier
> 




Re: Bar numbers on Dynamics staff above music

2023-08-28 Thread Richard Shann
testing further...
On Sun, 2023-08-27 at 07:50 -0700, Knute Snortum wrote:
> On Sun, Aug 27, 2023 at 7:31 AM Richard Shann
>  wrote:
> > If I create a Dynamics staff above the music, the bar numbers are
> > printed on it rather than on the staff with the music. At least
> > this is
> > why setting the outside-staff-priority doesn't have any effect.
> > Is there a way to get bar numbers onto the staff with the music?
> > 
> 
> 
> Here's my MWE, there may be better ways to do this:
> 
> %
> \version "2.24"
> 
> dyn = {
>   s4 s2.\f |
>   s4 s2.\f |
>   s4 s2.\f |
> }
> 
> mus = {
>   \override Score.BarNumber.outside-staff-priority = #-500
>   \override Score.BarNumber.break-visibility = #end-of-line-invisible
>   \set Score.barNumberVisibility = #(every-nth-bar-number-visible 1)
>   \repeat unfold 8 c''8
>   \override Score.BarNumber.Y-offset = -1 % <--- here's what's
> different
>   \repeat unfold 16 c''8
> }
> 
> \score {
>   <<
>     \new Dynamics \dyn
>     \new Staff \mus
>   >>
> }
> %

There are more problems than I thought with your solution-
here is your example with some higher notes in it - the bar numbers
leave the staff again:

44
\version "2.24"

dyn = {
  s4 s2.\f |
  s4 s2.\f |
  s4 s2.\f |
}

mus = {
  \override Score.BarNumber.outside-staff-priority = #-500
  \override Score.BarNumber.break-visibility = #end-of-line-invisible
  \set Score.barNumberVisibility = #(every-nth-bar-number-visible 1)
   \override Score.BarNumber.Y-offset = -1 % <--- here's what's different
  \repeat unfold 8 c''8
  \repeat unfold 8 c'''8  \repeat unfold 8 c'8
}

\score {
  <<
\new Dynamics \dyn
\new Staff \mus
  >>
}

%%

perhaps this is intractable - thank you all the same.

Richard




Re: Bar numbers on Dynamics staff above music

2023-08-27 Thread Richard Shann
On Sun, 2023-08-27 at 07:50 -0700, Knute Snortum wrote:
> On Sun, Aug 27, 2023 at 7:31 AM Richard Shann
>  wrote:
> > If I create a Dynamics staff above the music, the bar numbers are
> > printed on it rather than on the staff with the music. At least
> > this is
> > why setting the outside-staff-priority doesn't have any effect.
> > Is there a way to get bar numbers onto the staff with the music?
> > 
> 
> 
> Here's my MWE, there may be better ways to do this:
> 
> %
> \version "2.24"
> 
> dyn = {
>   s4 s2.\f |
>   s4 s2.\f |
>   s4 s2.\f |
> }
> 
> mus = {
>   \override Score.BarNumber.outside-staff-priority = #-500
>   \override Score.BarNumber.break-visibility = #end-of-line-invisible
>   \set Score.barNumberVisibility = #(every-nth-bar-number-visible 1)
>   \repeat unfold 8 c''8
>   \override Score.BarNumber.Y-offset = -1 % <--- here's what's
> different
>   \repeat unfold 16 c''8
> }
> 
> \score {
>   <<
>     \new Dynamics \dyn
>     \new Staff \mus
>   >>
> }
> %

Thank you very much, it seems I simplified too much however:

%%
\version "2.24"
dyn = {
   c'4 c'\f c' c'
 c' c' <> \tweak DynamicText.self-alignment-X #LEFT #(make-
dynamic-script #{ \markup \normal-text \column {\line{1x \dynamic mp
}\line{2x \dynamic mf}
 }#}) c' c'
 c' c'\f c' c' 
}
mus = { \repeat unfold 24 c''8

}
\score {
  <<  
\override Score.BarNumber.outside-staff-priority = #-500
\override Score.BarNumber.break-visibility = #end-of-line-
invisible
\set Score.barNumberVisibility = #(every-nth-bar-number-
visible 1) 
\override Score.BarNumber.Y-offset = -1
<<   
 \new Dynamics \dyn
 \new Staff \mus 
>>
  >>
   }
%%

Here there is a custom dynamic on two lines (for first and second
times) and the bar numbers leave the staff again.

Richard.

> 
> --
> Knute Snortum
> 
> 
>  




Bar numbers on Dynamics staff above music

2023-08-27 Thread Richard Shann
If I create a Dynamics staff above the music, the bar numbers are
printed on it rather than on the staff with the music. At least this is
why setting the outside-staff-priority doesn't have any effect.
Is there a way to get bar numbers onto the staff with the music?

This is my MWE:

\version "2.24"
dyn = {

   c'4 c'\f c' c'
 c' c'\f c' c'
 c' c'\f c' c' 
}
mus = { \repeat unfold 24 c''8

}
\score {
  <<  
\override Score.BarNumber.outside-staff-priority = #-500
\override Score.BarNumber.break-visibility = #end-of-line-invisible
\set Score.barNumberVisibility = #(every-nth-bar-number-visible 1) 
<<   
 \new Dynamics \dyn
 \new Staff \mus 
>>
  >>
   }
%%%%%%%%
Richard Shann



Re: Changing the size of the TabStaff clef

2023-08-18 Thread Richard Shann
On Fri, 2023-08-18 at 17:40 +0200, Jean Abou Samra wrote:
> Le vendredi 18 août 2023 à 16:34 +0100, Richard Shann a écrit :
> > Is it possible to reduce the size of the TabStaff clef?
> > this doesn't work:
> > \version "2.24.1"
> > <<
> >   \new TabStaff \with {
> >    \override TabStaff.Clef.font-size = #-1
>    ^
> 
> You should remove this, you're already in a \with { ... } for
> TabStaff.

Perfect! Thank you.
Richard


> 
> (There is an issue for this quirk:
> https://gitlab.com/lilypond/lilypond/-/issues/1254#note_594663257 )




Changing the size of the TabStaff clef

2023-08-18 Thread Richard Shann
Is it possible to reduce the size of the TabStaff clef?
this doesn't work:
\version "2.24.1"
<<
  \new TabStaff \with {
   \override TabStaff.Clef.font-size = #-1
  }{c c c c | }

>>

Richard Shann




Re: footnote in any markup

2023-08-09 Thread Richard Shann
Reading over the docs again, I see that this is what is meant by
"footnotes outside of music expressions".
Sorry for the noise.
Richard Shann
On Wed, 2023-08-09 at 15:36 +0100, Richard Shann wrote:
> I've noticed that the following does not work:
> 
> 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> \version "2.24.1"
> \score  {
>     { a'4 f' ^\markup {
>     "A simple"  \auto-footnote "tune" \italic " By me"
>   } g'4 }
> }
> 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> 
> I'm guessing this is something that simply can't be done but if so I
> didn't guess it from the documentation. Should it be mentioned under
> "Known Issues and Warnings"?
> 
> Richard Shann
> 
> 




footnote in any markup

2023-08-09 Thread Richard Shann
I've noticed that the following does not work:

8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
\version "2.24.1"
\score  {
{ a'4 f' ^\markup {
"A simple"  \auto-footnote "tune" \italic " By me"
  } g'4 }
}
8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><

I'm guessing this is something that simply can't be done but if so I
didn't guess it from the documentation. Should it be mentioned under
"Known Issues and Warnings"?

Richard Shann




Re: detecting parallel fifths and octaves in figured bass

2023-07-15 Thread Richard Shann
On Fri, 2023-07-14 at 21:08 +, Eef Weenink wrote:
> Maybe somebody already made a script for this: 
> 
> In figured bass there are two fundamental rules: Avoid parallell
> octaves and or fifhts. 
> So it would be nice to have some scipts what checks for this.

FWIW
There is a script in Denemo which marks consecutives in a movement,
but unless you were using Denemo to generate your LilyPond I'm doubtful
if that will help.

Richard
(Incidentally, there is vastly more support for figured bass in Denemo
than can be found anywhere else - including the ability to enter the
figures by playing the appropriate pitches on a Midi keyboard).

>  So if two voices have a distance of a fifth or octave, the next
> chord is checked if the same two voices have a fifth or octave too.
> If so, they are parallel. 
> 
> Any ideas, suggestions? 
> 
> regards, Eef




Re: Library to embed LilyPond in other programs

2023-05-31 Thread Richard Shann
On Wed, 2023-05-31 at 11:46 +0200, Jean Abou Samra wrote:
> Le mercredi 31 mai 2023 à 13:31 +1000, Andrew Bernard a écrit :
> > I'd still be interested to know in rough outline how Denemo lets
> > you add single notes in a GUI and have the feedback from lilypond
> > so quickly.
> 
> As far as I know, it does not use LilyPond for the GUI preview that
> you edit on the fly, only for the final rendering.
> 
Sorry I missed this thread so far (denemo-de...@gnu.org is better for
this topic).

Denemo does a crude typesetting and audio playback so you can see the
music and hear it as you enter. It optionally also runs LilyPond in the
background so you can see the final typeset. This typesetting can be
restricted to just a few bars either side of the current note (and/or a
few staffs) which is usually good for larger scores.

HTH

Richard.




Re: Sign for Flattement (Finger vibrato)

2023-05-08 Thread Richard Shann
On Mon, 2023-05-08 at 12:42 +0200, Franz-Rudolf Kuhnen wrote:
> Hi,
> 
> I'm in the process of re-setting suites from Pierre Danican-Philidors
> op.1. Philidor is one of the few composers who mark exactly where a
> flattement, i.e. a finger vibrato, should be played. He does this
> with a wavy line over the corresponding notes.

You can use the 

\vibrato amplitude wavelength thickness

command which is defined by this include file

http://git.savannah.gnu.org/gitweb/?p=denemo.git;a=blob;f=actions/lilypond/vibrato.ily;h=dadedd6859563a0bac0629b19ac729111ced29bd;hb=HEAD

(that's the 2.22 version, the 2.24 version is in a subdirectory).
It lets you create wavy lines of the desired wriggliness (it's included
in Denemo).

HTH

Richard Shann


> 
> This sign differs from "\prallprall". In addition, as can be seen in
> the example, it should be between the two notes.
> 
> Can someone help me?
> Thanks in advance.
> 
> Regards
> 
> Franz-Rudolf Kuhnen
> https://www.kuhnen-musik.de
> https://noten.kuhnen-musik.de
> 
> 





Re: -dgui option dropped in 2.24 - how to stop the black box on Windows now?

2023-05-07 Thread Richard Shann
On Tue, 2023-04-04 at 12:03 +0200, Jean Abou Samra wrote:
> Le mardi 04 avril 2023 à 11:34 +0200, Jean Abou Samra a écrit :
> Le lundi 03 avril 2023 à 20:50 +0200, Jonas Hahnfeld via LilyPond
> user discussion a écrit :
> > This shouldn't be needed: g_spawn_sync internally uses a helper
> > executable that should take care exactly of this aspect. LilyPond
> > uses
> > it internally to call Ghostscript.
> Hmm, but Denemo is already using g_spawn_sync and still experiencing
> this issue, or am I missing something?
> You are right that the GLib sources contain a gspawn-win32-helper.c
> program with the comment
> /* We build gspawn-win32-helper.exe as a Windows GUI application
>  * to avoid any temporarily flashing console windows in case
>  * the gspawn function is invoked by a GUI program. Thus, no main()
>  * but a WinMain().
>  */
> Later, there is
> #ifndef HELPER_CONSOLE
> int _stdcall
> WinMain (struct HINSTANCE__ *hInstance,
>struct HINSTANCE__ *hPrevInstance,
>char   *lpszCmdLine,
>int nCmdShow)
> #else
> int
> main (int ignored_argc, char **ignored_argv)
> #endif
> Apparently, there are two such executables, gspawn-win32-helper.exe
> and gspawn-win32-helper-console.exe, the latter compiled with -
> DHELP_CONSOLE.
> In gspawn-win32.c, I see
>   if (might_be_console_process ())
> helper_process = HELPER_PROCESS "-console.exe";
>   else
> helper_process = HELPER_PROCESS ".exe";
> which calls
> static gboolean
> might_be_console_process (void)
> {
>   // we should always fail to attach ourself to a console (because
> we're
>   // either already attached, or we do not have a console)
>   gboolean attached_to_self = AttachConsole (GetCurrentProcessId ());
>   g_return_val_if_fail (!attached_to_self, TRUE);
> 
>   switch (GetLastError ())
> {
> // current process is already attached to a console
> case ERROR_ACCESS_DENIED:
>   return TRUE;
> // current process does not have a console
> case ERROR_INVALID_HANDLE:
>   return FALSE;
> // we should not get ERROR_INVALID_PARAMETER
> }
> 
>   g_return_val_if_reached (FALSE);
> }
> Richard, maybe might_be_console_process is returning true inside
> Denemo for some reason?

I couldn't follow up this suggestion because I don't have a way of
building Denemo for Windows to experiment with. But it occurred to me
that I *could* test this idea just by swapping the executables
gspawn-win32-helper.exe and gspawn-win32-helper-console.exe around -
that is, running the opposite one that the 
might_be_console_process (void) 
call suggests.
I did this and it turns out that this doesn't prevent a terminal from
popping up, however there is a clue: the title of the program being run
in the title bar of the terminal changes from lilypond.exe to gspawn-
win32-helper.exe when that program is replaced by gspawn-win32-helper-
console.exe.
So it would seem that a terminal would pop up regardless of which of
those gspawn-win32 helper programs ran, but the title bar would name
the helper program rather than the lilypond.exe program.

Richard










Re: Centering columns on the page

2023-04-18 Thread Richard Shann
On Mon, 2023-04-17 at 20:26 +0200, Jean Abou Samra wrote:
> Le lundi 17 avril 2023 à 18:51 +0100, Richard Shann a écrit :
> Someone asked me how to set some verses in columns across the page
> after the title in their piece. I found a snippet in the LSR which
> defines a markup command \columns to place columns evenly spaced
> across
> the page. So with three verses you get one aligned at the left, one
> 1/3
> and one 2/3 of the way across the page. With two columns the second
> column starts at the page center.
> What is nice about this definition is that it scales nicely when you
> alter the global staff size.
> I have tried to modify the definition to move the whole set of
> columns
> to the left,

eeek! sorry, I meant to the right of course, to center the columns on
the page.

>  so that e.g. the second of three columns straddles the
> center of the page or the space between two columns is centered.
> My efforts have been in vain, so I was wondering if someone could
> suggest how to do this.
> Like this?
> \markup \override #'(line-width . 100) \columns ...
> The line-width property is read by \line / make-line-markup.

Oh, I'm sorry for writing "left" for "right", that completely muddled
my question. Setting the line width narrower moves the center of the
block of columns to the left - even further from the center of the
page.
If it existed \override #'(left-margin . 100) might be the answer.
For complete flexibility I suppose one could wish to set to space to
left of each column separately...

Richard






Centering columns on the page

2023-04-17 Thread Richard Shann
Someone asked me how to set some verses in columns across the page
after the title in their piece. I found a snippet in the LSR which
defines a markup command \columns to place columns evenly spaced across
the page. So with three verses you get one aligned at the left, one 1/3
and one 2/3 of the way across the page. With two columns the second
column starts at the page center.
What is nice about this definition is that it scales nicely when you
alter the global staff size.

I have tried to modify the definition to move the whole set of columns
to the left, so that e.g. the second of three columns straddles the
center of the page or the space between two columns is centered.
My efforts have been in vain, so I was wondering if someone could
suggest how to do this.

The code is as follows:

8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><

\version "2.24.0"
#(set-global-staff-size 12) 
%#(set-global-staff-size 32) 

#(define-markup-command (columns layout props args) (markup-list?)
   (ly:message "~s" make-line-markup)
   (let ((line-width (/ (chain-assoc-get 'line-width props
 (ly:output-def-lookup layout 
'line-width))
 (max (length args) 1
 (interpret-markup layout props
   (make-line-markup  (map (lambda (line)
(markup #:pad-to-box `(0 . 
,line-width) '(0 . 0)
#:override `(line-width 
. ,line-width)
line))
  args)
\markup \columns  {

  \column {
\line {Verse One }
\line {Second Line }

  }
  \column {
   \line {Verse Two }
   \line {Second Line }
  }
  
  \column {
   \line {Verse Three }
   \line {Second Line }
  
  }
}

8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><

Where a change of global staff size is commented out for ease of testing.

Best wishes,

Richard Shann






Re: -dgui option dropped in 2.24 - vanishing log file.

2023-04-04 Thread Richard Shann


On Tue, 2023-04-04 at 11:03 +0100, Richard Shann wrote:
> On Tue, 2023-04-04 at 11:32 +0200, Jean Abou Samra wrote:
> > Le mardi 04 avril 2023 à 10:29 +0100, Richard Shann a écrit :
> > > The situation on Windows without lilypond-windows.exe is even
> > > worse
> > > than I thought - the option -dlog-file no longer generates the
> > > log
> > > file
> > > into the prescribed place - instead the log is splashed onto the
> > > terminal box (which then vanishes when the typesetting is
> > > finished).

Sorry - this seems to have been noise on my part - I've just been re-
running LilyPond 2.22 and 2.24 under Denemo and the log files are being
generated as usual, and only the loglevel message in the terminal.
I can't reproduce the problem.
Richard Shann



> > > It means no error reporting to the unlucky Windows users of
> > > Denemo.
> > For me, -dlog-file still works. Do you have a reproducer?
> 
> I've just run lilypond.exe from a "Windows Power Shell" in the
> lilypond
> bin directory targetting a file on the user's Desktop. It *did*
> indeed
> generate a log file with the -dlog-file option, the file appearing in
> the bin directory where the executable was launched. No stderr
> appeared
> in the terminal.
> 
> The documentation on -dlog-file doesn't specify where the file will
> appear in the case that a full path is not given, but previously run
> from g_spawn_sync it appeared in the same directory as the lilypond
> source. It doesn't appear there now, nor in the bin directory (this
> is
> under the user's home directory), nor (given my limited abilities
> searching on Windows) anywhere else.
> 
> I should mention that the -dgui was a complete red herring here - I
> mistakenly thought Denemo was depending on it to capture the log
> output
> but in actual fact "-dlog-file filename" is always passed, the only
> thing Denemo has to do is append the ".log" and then open it to find
> the error locations.
> 
> It is, of course still working under Unix - the log file appears
> under
> the /tmp/Denemo directory where the LilyPond source is written by
> Denemo.
> 
> Thank you for looking into this!
> 
> Richard
> 
> 
> 
> 





Re: -dgui option dropped in 2.24 - how to stop the black box on Windows now?

2023-04-04 Thread Richard Shann
On Tue, 2023-04-04 at 12:03 +0200, Jean Abou Samra wrote:
> Le mardi 04 avril 2023 à 11:34 +0200, Jean Abou Samra a écrit :
> Le lundi 03 avril 2023 à 20:50 +0200, Jonas Hahnfeld via LilyPond
> user discussion a écrit :
> > This shouldn't be needed: g_spawn_sync internally uses a helper
> > executable that should take care exactly of this aspect. LilyPond
> > uses
> > it internally to call Ghostscript.
> Hmm, but Denemo is already using g_spawn_sync and still experiencing
> this issue, or am I missing something?
> You are right that the GLib sources contain a gspawn-win32-helper.c
> program with the comment
> /* We build gspawn-win32-helper.exe as a Windows GUI application
>  * to avoid any temporarily flashing console windows in case
>  * the gspawn function is invoked by a GUI program. Thus, no main()
>  * but a WinMain().
>  */
> Later, there is
> #ifndef HELPER_CONSOLE
> int _stdcall
> WinMain (struct HINSTANCE__ *hInstance,
>struct HINSTANCE__ *hPrevInstance,
>char   *lpszCmdLine,
>int nCmdShow)
> #else
> int
> main (int ignored_argc, char **ignored_argv)
> #endif
> Apparently, there are two such executables, gspawn-win32-helper.exe
> and gspawn-win32-helper-console.exe, the latter compiled with -
> DHELP_CONSOLE.
> In gspawn-win32.c, I see
>   if (might_be_console_process ())
> helper_process = HELPER_PROCESS "-console.exe";
>   else
> helper_process = HELPER_PROCESS ".exe";
> which calls
> static gboolean
> might_be_console_process (void)
> {
>   // we should always fail to attach ourself to a console (because
> we're
>   // either already attached, or we do not have a console)
>   gboolean attached_to_self = AttachConsole (GetCurrentProcessId ());
>   g_return_val_if_fail (!attached_to_self, TRUE);
> 
>   switch (GetLastError ())
> {
> // current process is already attached to a console
> case ERROR_ACCESS_DENIED:
>   return TRUE;
> // current process does not have a console
> case ERROR_INVALID_HANDLE:
>   return FALSE;
> // we should not get ERROR_INVALID_PARAMETER
> }
> 
>   g_return_val_if_reached (FALSE);
> }
> Richard, maybe might_be_console_process is returning true inside
> Denemo for some reason? 

I don't understand, I'm afraid. Denemo only makes calls to the g_spawn*
functions as documented. The function might_be_console_process() is
static - internal to glib - or rather to some executable that it calls,
apparently.

The name and path of the lilypond executable is typed into Denemo and
the g_spawn call is made - so the only difference is that it is calling
lilypond.exe below the 2.24.0 folder rather than the lilypond-
windows.exe below the 2.22.0 folder. I've just tested this out by
downloading 2.22.0 to the home directory and telling the same Denemo
executable to execute lilypond.exe and lilypond-windows.exe
alternately. With the former I get the terminal popping up and not with
the latter.

Richard Shann





Re: -dgui option dropped in 2.24 - how to stop the black box on Windows now?

2023-04-04 Thread Richard Shann
On Tue, 2023-04-04 at 11:32 +0200, Jean Abou Samra wrote:
> Le mardi 04 avril 2023 à 10:29 +0100, Richard Shann a écrit :
> > The situation on Windows without lilypond-windows.exe is even worse
> > than I thought - the option -dlog-file no longer generates the log
> > file
> > into the prescribed place - instead the log is splashed onto the
> > terminal box (which then vanishes when the typesetting is
> > finished).
> > It means no error reporting to the unlucky Windows users of Denemo.
> For me, -dlog-file still works. Do you have a reproducer?

I've just run lilypond.exe from a "Windows Power Shell" in the lilypond
bin directory targetting a file on the user's Desktop. It *did* indeed
generate a log file with the -dlog-file option, the file appearing in
the bin directory where the executable was launched. No stderr appeared
in the terminal.

The documentation on -dlog-file doesn't specify where the file will
appear in the case that a full path is not given, but previously run
from g_spawn_sync it appeared in the same directory as the lilypond
source. It doesn't appear there now, nor in the bin directory (this is
under the user's home directory), nor (given my limited abilities
searching on Windows) anywhere else.

I should mention that the -dgui was a complete red herring here - I
mistakenly thought Denemo was depending on it to capture the log output
but in actual fact "-dlog-file filename" is always passed, the only
thing Denemo has to do is append the ".log" and then open it to find
the error locations.

It is, of course still working under Unix - the log file appears under
the /tmp/Denemo directory where the LilyPond source is written by
Denemo.

Thank you for looking into this!

Richard






Re: -dgui option dropped in 2.24 - how to stop the black box on Windows now?

2023-04-04 Thread Richard Shann
The situation on Windows without lilypond-windows.exe is even worse
than I thought - the option -dlog-file no longer generates the log file
into the prescribed place - instead the log is splashed onto the
terminal box (which then vanishes when the typesetting is finished).
It means no error reporting to the unlucky Windows users of Denemo.

Please can we have lilypond-windows.exe back? It is indeed as far as I
know just an extra target in the makefile with -mconsole in it, and
given the size of a LilyPond installation not a enormous burden on the
windows users disk space.

Richard Shann



On Mon, 2023-04-03 at 10:54 -0700, Aaron Hill wrote:
> On 2023-04-03 10:31 am, Jean Abou Samra wrote:
> > > Le 3 avr. 2023 à 12:21, Richard Shann  a
> > > écrit :
> > > 
> > > Is there any chance the developers might re-instate the
> > > lilypond-windows.exe?
> > 
> > Maybe. Is it as easy as compiling with -mconsole ? Does that have
> > other 
> > effects to take care of? Is there a use case where the current mode
> > is 
> > important or could we just switch to the other mode?
> 
> LilyPond would still need to be able to be run purely from the
> terminal, 
> so the main target should continue to use the console subsystem. 
> This 
> importantly covers the scenarios of scripting and automation where
> you 
> need standard I/O to be mapped properly.
> 
> The use case for a third-party GUI application running LilyPond 
> behind-the-scenes is where the "windows" subsystem could be useful, 
> providing the application is unable to spawn the child process in a 
> hidden manner.
> 
> This goes to my question of which application has the real problem.  
> Denemo relied on LilyPond providing two entrypoints, so it was not 
> really at fault.  But Denemo probably should have been spawning the 
> worker process hidden to begin with, thus never relying on 
> lilypond-windows.exe in the first place.  However, that would require
> working around glib to use the Win32 API directly (and adding 
> platform-specific development overhead), or by getting the glib 
> developers to expose the underlying process creation flag.  But for
> all 
> I know, it might be out-of-scope for glib to support this scenario,
> thus 
> pushing the work back to Denemo.
> 
> It should be noted that this dual subsystem approach is very common
> on 
> Windows.  Take the Windows scripting host itself.  It comes in two 
> flavors: wscript.exe and cscript.exe.  The first is for use without
> an 
> attached terminal, and the second is meant to be run from the 
> command-line.  Java likewise has always shipped with two frontends: 
> java.exe and javaw.exe.  So, LilyPond would not be doing anything 
> unusual by shipping two executables.
> 
> 
> -- Aaron Hill





Re: -dgui option dropped in 2.24 - how to stop the black box on Windows now?

2023-04-03 Thread Richard Shann
On Sun, 2023-04-02 at 11:54 -0700, Aaron Hill wrote:
> On 2023-04-02 8:38 am, Richard Shann wrote:
> > there used to be an executable lilypond-windows.exe in addition to
> > the
> > lilypond.exe which has also vanished. I suspect it was compiled
> > using
> > the option
> > 
> > -mconsole
> > 
> > passed to gcc as this is how Denemo is compiled to avoid leaving a
> > terminal around that would tempt the user to kill everything by
> > dismissing it (Windows users are generally not familiar with
> > terminals).
> 
> Yup.  On Windows, the executable takes two forms based on whether it
> is 
> CLI-based or GUI-based.  lilypond-windows.exe was in all practical
> ways 
> identical to lilypond.exe except that it had WinMain as its
> entrypoint 
> instead of main.  This meant Windows did not automatically allocate a
> console window.  Do note that even GUI-based applications are
> afforded a 
> text console but they must explicitly call the AllocConsole API.
> 
> 
> > If I understand this correctly, it looks like I will have to spawn
> > a
> > process that runs a windows batch file that processes the command
> > line
> > parameters and synthesizes the names of the log file that LilyPond
> > used
> > to create and then calls LilyPond with re-direction of the output.
> > I'm
> > not sure that this can be done without a terminal popping up to
> > annoy
> > the user.
> 
> I have never looked at Denemo or its source code, so what I am going
> to 
> say might not be so trivially applicable. 

You were quite right to be doubtful - Denemo tries to off-load the
target machine dependent stuff onto libraries, in this case glib which
provides the routine to spawn a process, and sadly does not expose the
CREATE_NO_WINDOW part of the Win32 API.
For now I'll disable the autocompilation option for Windows with
LilyPond 2.24. Is there any chance the developers might re-instate the
lilypond-windows.exe?

Richard Shann

> 

>  But in the Win32 API, you can 
> call CreateProcess [1] and use the process flag CREATE_NO_WINDOW
> [2].  
> This should prevent the console window appearing if the child process
> is 
> CLI-based.
> 
> [1]: 
>   
> https://learn.microsoft.com/en-us/windows/win32/api/processthreadsapi/nf-processthreadsapi-createprocessa
> [2]: 
>   
> https://learn.microsoft.com/en-us/windows/win32/procthread/process-creation-flags
> 
> 
> > Is there anyway of spawning a LilyPond 2.24 process on Windows now
> > without plaguing the user with terminals?
> 
> You might be able to shim with a VBS wrapper.  I do this a lot for 
> custom scheduled tasks that would normally run in the terminal but
> that 
> I do not want to interrupt what I am doing by spawning a window at
> odd 
> times.  Something like this should work, passing arguments to the
> script 
> along to LilyPond:
> 
> 
> ' Turn WScript.Arguments into a proper array.
> Dim args()
> ReDim args(WScript.Arguments.Count - 1)
> For i = 0 To WScript.Arguments.Count - 1
>    args(i) = Chr(34) & WScript.Arguments(i) & Chr(34)
> Next
> 
> Dim shell
> Set shell = WScript.CreateObject("WScript.Shell")
> shell.Run "lilypond.exe " & Join(args), 0, True
> 
> 
> NOTE: The important parameter here is the zero (0) to shell.Run. 
> This 
> hides the spawned process.  The True waits for the child process to 
> finish, which probably is what you need for this use case.  But if
> you 
> just want to fire off a child process and not have the scripting host
> stick around, change that to False.
> 
> 
> -- Aaron Hill





Re: -dgui option dropped in 2.24 - how to stop the black box on Windows now?

2023-04-02 Thread Richard Shann
On Sun, 2023-04-02 at 13:57 +0200, Robin Bannister wrote:
> Richard Shann wrote:
> > There was an option -dgui which allowed Denemo to run LilyPond in
> > the
> > background on Windows, but this has vanished without, as far as I
> > can
> > see, any entry in the Changes to account for it
> > 
> 
> See 
> https://gitlab.com/lilypond/lilypond/-/commit/0a7d54646be5566de53e2f7dd0c19a2c1df92156?merge_request_iid=1373
> 
Thank you for your quick reply. 
If I understand this correctly, it looks like I will have to spawn a
process that runs a windows batch file that processes the command line
parameters and synthesizes the names of the log file that LilyPond used
to create and then calls LilyPond with re-direction of the output. I'm
not sure that this can be done without a terminal popping up to annoy
the user.

However I think what this says is that the current problem of a
terminal popping up and blocking progress is due something else that
has changed:
there used to be an executable lilypond-windows.exe in addition to the
lilypond.exe which has also vanished. I suspect it was compiled using
the option

-mconsole

passed to gcc as this is how Denemo is compiled to avoid leaving a
terminal around that would tempt the user to kill everything by
dismissing it (Windows users are generally not familiar with
terminals).

Is there anyway of spawning a LilyPond 2.24 process on Windows now
without plaguing the user with terminals?

Richard




> 
> Cheers,
> Robin





-dgui option dropped in 2.24 - how to stop the black box on Windows now?

2023-04-02 Thread Richard Shann
There was an option -dgui which allowed Denemo to run LilyPond in the
background on Windows, but this has vanished without, as far as I can
see, any entry in the Changes to account for it

https://lilypond.org/doc/v2.24/Documentation/changes-big-page

Is it possible for LilyPond 2.24 to be run in the background? 
As it is an ugly console pops up blotting out the user's view of his
work and preventing him continuing to enter text/music until it is
done.

Richard





Rehearsal Mark and textMark side by side?

2023-03-30 Thread Richard Shann
Is there a way to combine a rehearsal mark with some text following it
other than the rather crude

\version "2.24.0"
 {
  c'' \mark \default c'' c'' c''  \textEndMark \markup {a tempo}
}

where the durations of the notes are chosen to make text follow the
rehearsal mark?

Richard





Re: Height of markup entered on a Dynamics Staff

2023-03-30 Thread Richard Shann
On Wed, 2023-03-29 at 10:03 -0700, Knute Snortum wrote:
> On Wed, Mar 29, 2023 at 5:08 AM Richard Shann <
> rich...@rshann.plus.com> wrote:
> > In the following snippet the text is displaced vertically upwards
> > if
> > the commenting out is removed, i.e. a note appears with more than
> > one
> > leger line later on the staff.
> > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> > \version "2.24"
> > MI = {
> >         <> ^\markup \bold \italic {"text" } 
> >         R1*4/4
> >         R1*4/4
> > }
> > MII = {
> >          R1*4/4
> >          R1*4/4
> >          c''1 
> >          %c'''1
> > 
> > }
> > \score {
> >           <<
> >               \new Dynamics \MI
> >               \new Staff  \MII
> >           >>
> >        }
> > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> > 
> > Is this a bug?
> > 
> 
> 
> Hmm... I'm not seeing anything I would call a bug when I run your
> example.  Here's what it looks like (attached).
the thing that was troubling me was that when uncommenting the higher
note the position of the text moved without it seemed any need to. I
understand why now, so that's ok.
Richard

> 
> --
> Knute Snortum





Re: Height of markup entered on a Dynamics Staff

2023-03-30 Thread Richard Shann
On Wed, 2023-03-29 at 20:05 +0200, Jean Abou Samra wrote:
> Le mercredi 29 mars 2023 à 13:07 +0100, Richard Shann a écrit :
> > In the following snippet the text is displaced vertically upwards
> > if
> > the commenting out is removed, i.e. a note appears with more than
> > one
> > leger line later on the staff.
> > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8>< \version "2.24"
> > MI = {
> >     <> ^\markup \bold \italic {"text" }
> >     R14/4
> >     R14/4
> > }
> > MII = {
> >  R14/4
> >  R14/4
> >  c''1
> >  %c'''1
> > 
> > }
> > \score {
> >   <<
> >   \new Dynamics \MI
> >   \new Staff  \MII
> >   >>
> >    }
> > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> > Is this a bug?
> I don't think so. The point of the Dynamics context is to align the
> dynamics put into it on a common baseline. If there were another
> ^\markup ... at the point of that note with a ledger line, the
> alignment would force the first markup to much higher (just add s1
> s1^"text" in MI to see it). There is a tradeoff between making the
> line of dynamics look like it's consistently above the staff and not
> pushing it farther than necessary from the staff. I think LilyPond's
> behavior here is legitimate, though perhaps the text script should go
> higher than it does (with the ledgered note).

Ah, I understand, it comes down to me abusing the purpose of
DynamicsStaff .. thinking cap on.

Richard






Height of markup entered on a Dynamics Staff

2023-03-29 Thread Richard Shann
In the following snippet the text is displaced vertically upwards if
the commenting out is removed, i.e. a note appears with more than one
leger line later on the staff.
8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
\version "2.24"
MI = {
<> ^\markup \bold \italic {"text" } 
R1*4/4
R1*4/4
}
MII = {
 R1*4/4
 R1*4/4
 c''1 
 %c'''1
 
}
\score {
  <<
  \new Dynamics \MI
  \new Staff  \MII
  >>
   }
8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><

Is this a bug?

Richard





Re: rehearsalMarkFormatter => markFormatter in 2.24.0

2023-03-12 Thread Richard Shann
On Sat, 2023-03-11 at 19:03 +0100, Jean Abou Samra wrote:
> Le vendredi 10 mars 2023 à 14:35 +0000, Richard Shann a écrit :
> > sorry, yes, I just assumed it had been shortened not lengthened.
> It was renamed because LilyPond gained other “mark formatters”, such
> as segnoMarkFormatter and codaMarkFormatter.
> > for anyone listening in that needs an extra ")" i.e.
> > xxx = #(if (ly:version? >= '(2 23 6))
> > 'rehearsalMarkFormatter'markFormatter)
> Yes, sorry.
> > This ly:version is new to me I'm ashamed to say. Does it raise the
> > possibility of writing chunks of LilyPond that are conditional on
> > the version I wonder? I would perhaps need to phrase that as a
> > specific question about some particular construct ...
> Yup, you can use it to make decision in Scheme based on the LilyPond
> version, and since a lot of LilyPond's constructs can be controlled
> from Scheme, it can be applied in many cases.
I've been digging into your very helpful LilyPond/Scheme guide, but it
will take me a while to be able to ask a sensible question ...
Thanks again,
Richard




Re: rehearsalMarkFormatter => markFormatter in 2.24.0

2023-03-10 Thread Richard Shann
On Fri, 2023-03-10 at 14:12 +0100, Jean Abou Samra wrote:
> 
> 
> > Le 10 mars 2023 à 13:47, Richard Shann  a
> > écrit :
> > 
> > I've noticed a name change in 2.24 where
> > rehearsalMarkFormatter has become markFormatter.
> 
> 
> (You mean the other way around.)
sorry, yes, I just assumed it had been shortened not lengthened.
> 
> 
> > I want to make scores that can be compiled under either 2.22 or
> > 2.24 so
> > I tried this:
> > 
> > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8
> > ><
> > \version "2.24.0"
> > xxx = rehearsalMarkFormatter
> > 
> > %\version "2.22.0"
> > %xxx = markFormatter
> > 
> > \relative c'' {
> >  \set Score.\xxx = #format-mark-box-alphabet
> >  c1 \mark \default
> >  c1 \mark \default
> >  c1 \mark #8
> >  c1 \mark \default
> >  c1 \mark \default
> > }
> > 
> > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8
> > ><
> > If the commenting out is switched round this continues to work.
> > (The definition of xxx would be in an include file in a versioned
> > directory).
> 
> You can also do
> 
> xxx = #(if (ly:version? >= '(2 23 6) 'rehearsalMarkFormatter
> 'markFormatter)

for anyone listening in that needs an extra ")" i.e.

xxx = #(if (ly:version? >= '(2 23 6)) 'rehearsalMarkFormatter'markFormatter)

This ly:version is new to me I'm ashamed to say. Does it raise the
possibility of writing chunks of LilyPond that are conditional on the
version I wonder? I would perhaps need to phrase that as a specific
question about some particular construct ...

> 
> to have it picked automatically based on the current LilyPond
> version.
> 
> > 
> > My question is, is this a reasonable approach? 
> > Specifically is it reliable to use variables in this way, as
> > components
> > of a property?
> 
> Yes.

That's good to hear.
Thank you so much for the speedy help.

Richard





rehearsalMarkFormatter => markFormatter in 2.24.0

2023-03-10 Thread Richard Shann
I've noticed a name change in 2.24 where
rehearsalMarkFormatter has become markFormatter.
I want to make scores that can be compiled under either 2.22 or 2.24 so
I tried this:

8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
\version "2.24.0"
xxx = rehearsalMarkFormatter

%\version "2.22.0"
%xxx = markFormatter

\relative c'' {
  \set Score.\xxx = #format-mark-box-alphabet
  c1 \mark \default
  c1 \mark \default
  c1 \mark #8
  c1 \mark \default
  c1 \mark \default
}

8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
If the commenting out is switched round this continues to work.
(The definition of xxx would be in an include file in a versioned
directory).

My question is, is this a reasonable approach? 
Specifically is it reliable to use variables in this way, as components
of a property?

Richard Shann










Re: DynamicsStaff spacing itself too far from the music

2023-03-01 Thread Richard Shann
On Tue, 2023-02-28 at 20:16 +, Timothy Lanfear wrote:
> On 28/02/2023 17:53, Richard Shann wrote:
> In a complex score with a DynamicsStaff placed above the music for
> markups and another below for the dynamics an unusually large space
> opened up below the music and above the dynamics.
> I pared the complex score down to this MWE:
> 
> A Dynamics context  by default is centred between the staves above
> and below. Adjusting this behaviour might be what you need.
> \version "2.24"
>  
>  marks = {
>  %This line is needed.
>  \repeat unfold 40 {s1 }
>  }
>  music = {
>   \repeat unfold 80 {c''1 }
>    }
>  dyns = {
>   \repeat unfold 80 { <>  \f c''1 }
>    }
>  \paper {
>  %this line is needed.
>  system-system-spacing.minimum-distance = 15
>     }
>  
>  \score {
>    <<   \new Dynamics \with { \override
> VerticalAxisGroup.staff-affinity = #DOWN } <<\marks >>
>     \new Staff <<   \music  >>
>     \new Dynamics \with { \override
> VerticalAxisGroup.staff-affinity = #UP } << \dyns >>
>     >>
>     }
> 

Thank you very much  - it's all clear now.
Richard Shann







DynamicsStaff spacing itself too far from the music

2023-02-28 Thread Richard Shann
In a complex score with a DynamicsStaff placed above the music for
markups and another below for the dynamics an unusually large space
opened up below the music and above the dynamics.
I pared the complex score down to this MWE:

8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><

\version "2.24"
marks = {
%This line is needed.
\repeat unfold 40 {s1 } 
}
music = {
 \repeat unfold 80 {c''1 }
  }
dyns = {
 \repeat unfold 80 { <>  \f c''1 }  
  }
\paper {
%this line is needed.
system-system-spacing.minimum-distance = 15
   }

\score {
  <<   \new Dynamics <<\marks >> 
   \new Staff <<   \music  >> 
   \new Dynamics << \dyns >>
   >>
   } 

8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><

In this example the extra spacing disappears after the third system.
Strangely, the problem goes away if the system-system-spacing.minimum-
distance is not set, however this does not happen on the complex score,
and, as there is plenty of room on the page it is difficult to see how
this setting could be called into play.

Any insights into this behavior would be most welcome, as well as any
setting that might directly address this spacing.

Richard Shann






Braces over systems where \stopStaff is active go missing

2023-02-06 Thread Richard Shann


If I use \stopStaff then systems where it is active don't display
braces, even though they do display the initial clef.
For example:

\version "2.24"
\score {
 \new StaffGroup <<
\new Staff  {\stopStaff c'1 }
\new Staff {c'1 }
 >>
   }

Is there a way to get the braces to show?

Richard





Re: \stopStaff shows/doesn't show ledger lines?

2023-02-01 Thread Richard Shann
Thank you for the quick response Valentin

On Wed, 2023-02-01 at 13:52 +0100, Valentin Petzel wrote:
> Hello Richard,
> 
> the problem here is that the LedgerLineSpanner tries to reference
> it’s staff 
> symbol, which is set when the Spanner is created. So the
> LedgerLineSpanner 
> does not know the StaffSymbol ended.
> 
> The LedgerLineSpanner will be broken on encountering a new
> StaffSymbol. To 
> solve this issue one could change the engraver to listen to stop
> staff events 
> and in this case also break the LedgerLineSpanner.

I guess that's a bug in \stopStaff then, I've done some digging and it
seems I can add
\override NoteHead.no-ledgers = ##t
to it as a workaround.

Richard

> 
> Cheers,
> Valentin
> 
> Am Mittwoch, 1. Februar 2023, 13:17:45 CET schrieb Richard Shann:
> > On Wed, 2023-02-01 at 10:35 +, Richard Shann wrote:
> > > In this piece
> > 
> > I've discovered this can be made still more minimal:
> > 
> > \version "2.24"
> > music = {
> >     e'''1 \stopStaff e'''1 \break e'''1  }
> > \score { \music }
> > 
> > The \break is needed.
> > 
> > Richard
> > 
> > >  the note on the first system has ledger lines typeset
> > > 
> > > while those on the second does not.
> > > 
> > > \version "2.24"
> > > music = {
> > >  s1*4/4  \stopStaff e'''1
> > >  s1*4/4  \break e'''1 s1*4/4 }
> > > \score { \music }
> > > 
> > > The entry in the documentation for \stopStaff leads to a page
> > > that
> > > doesn't seem to say much about it...
> > > 
> > > Richard
> 





Re: \stopStaff shows/doesn't show ledger lines?

2023-02-01 Thread Richard Shann
On Wed, 2023-02-01 at 10:35 +, Richard Shann wrote:
> In this piece
I've discovered this can be made still more minimal:

\version "2.24"
music = {
e'''1 \stopStaff e'''1 \break e'''1  }
\score { \music } 

The \break is needed.

Richard


>  the note on the first system has ledger lines typeset
> while those on the second does not.
> 
> \version "2.24"
> music = {
>  s1*4/4  \stopStaff e'''1 
>  s1*4/4  \break e'''1 s1*4/4 }
> \score { \music } 
> 
> The entry in the documentation for \stopStaff leads to a page that
> doesn't seem to say much about it...
> 
> Richard
> 
> 
> 





\stopStaff shows/doesn't show ledger lines?

2023-02-01 Thread Richard Shann
In this piece the note on the first system has ledger lines typeset
while those on the second does not.

\version "2.24"
music = {
 s1*4/4  \stopStaff e'''1 
 s1*4/4  \break e'''1 s1*4/4 }
\score { \music } 

The entry in the documentation for \stopStaff leads to a page that doesn't seem 
to say much about it...

Richard





Re: Font change in 2.24.0 Figured bass "4"

2023-01-14 Thread Richard Shann
On Sat, 2023-01-14 at 18:50 +0100, Jean Abou Samra wrote:
> Le 14/01/2023 à 18:27, Richard Shann a écrit :
> > I didn't get a response to this email,
> 
> ?? You got a reponse from Werner last Monday. While there can be 
> distribution delays on this list, you were in the direct recipients
> of 
> the email so it is a mystery if it didn't reach you.

Ah, I should have checked the archives - I did think it *very* strange
- I haven't received either the direct or the mailing list versions of
that message. I did have a power cut in the recent storms that required
fixing my file system and several things were broken (I had to re-
install guile) but the emails seemed ok.

> 
> You can always read it again at 
>  
> https://lists.gnu.org/archive/html/lilypond-user/2023-01/msg00168.html
> 
> Please confirm that you received this email...

yes, everything fine now - thank you very much!

Richard






Re: Font change in 2.24.0 Figured bass "4"

2023-01-14 Thread Richard Shann


I didn't get a response to this email, but I stumbled across this the
presence of these glyphs
fattened.four
fattened.four.alt
at
https://lilypond.org/doc/v2.24/Documentation/notation/the-emmentaler-font#figured-bass-symbol-glyphs

and it would seem that the change to figured bass going to version 2.24
is to switch to using the alt versions of the glyphs.
Is anyone able to help me get control of the choice of glyph armed with
this information?
Richard

On Mon, 2023-01-09 at 16:52 +, Richard Shann wrote:
> The figure "4" in figured bass is coming out with a stunted upright
> in
> the new release
> 
> 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> %\version "2.20.0"
> \version "2.24.0"
> \score {
>     \new Staff  << 
>     \context Staff \figuremode { <4> }
>  \new Voice {  \clef bass   c  } 
>  >>
>    } 
> 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> gives a strange-looking 4 which resembles an upside-down 7 with a
> smudge on it, quite difficult to decipher (see attached examples).
> 
> Is this a bug and how can I access the previously used font?
> 
> Richard Shann
> 





Font change in 2.24.0 Figured bass "4"

2023-01-09 Thread Richard Shann
The figure "4" in figured bass is coming out with a stunted upright in
the new release

8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
%\version "2.20.0"
\version "2.24.0"
\score {
\new Staff  << 
\context Staff \figuremode { <4> }
 \new Voice {  \clef bass   c  } 
 >>
   } 
8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
gives a strange-looking 4 which resembles an upside-down 7 with a
smudge on it, quite difficult to decipher (see attached examples).

Is this a bug and how can I access the previously used font?

Richard Shann



Re: Tab staff - forcing a note onto a lower string

2022-12-10 Thread Richard Shann
On Sat, 2022-12-10 at 17:42 +0100, Jean Abou Samra wrote:
> Le 10/12/2022 à 17:37, Richard Shann a écrit :
> > Is it possible to specify the string to be used for a note when
> > using a
> > TAB staff? So that a lower string gets marked with a number higher
> > than
> > it usually goes up to (because the next higher string is ordinarily
> > used).
> 
> 
> There is an example here (the fourth code example in the section):
> 
> https://lilypond.org/doc/v2.22/Documentation/notation/common-notation-for-fretted-strings.html#default
> -
> tablatures

Perfect! Not sure how I missed that.

Richard





Tab staff - forcing a note onto a lower string

2022-12-10 Thread Richard Shann
Is it possible to specify the string to be used for a note when using a
TAB staff? So that a lower string gets marked with a number higher than
it usually goes up to (because the next higher string is ordinarily
used).

Richard





Re: issues with installing Lilypond

2022-09-20 Thread Richard Shann
On Tue, 2022-09-20 at 09:26 -0400, t...@risingdove.com wrote:
> On 19 Sep 2022 at 17:55, Cluanie Fraser wrote:
> 
> > 
> >  Hi Tim,
> >  Thanks for responding. I´m really struggling as I´m quite out
> > of depth with this tech stuff.
> >  This is what shows up when I download the Lilypond file from
> > the website and double 
> >  click to open it.
> 
> You've opened it in Notepad, which is for text files. What you have
> opened is definitely NOT a 
> text file. 
>  
> >  I tried downloading Denemo and that kind of worked but doesn´t
> > let me edit the music in 
> >  the lilypond text file, I can only do it graphically which
> > isn´t ideal.
> 
> I know next to nothing about Denomo, but I think it's a graphical
> music editor, which would 
> work with files in its own format, and would know nothing about
> Lilypond (*.ly) files.

just to set things straight - Denemo certainly does know about LilyPond
files, it can write them and it can import them sometimes and can read
chunks of music from LilyPond files via the clipboard. And you can
insert LilyPond syntax at places in a Denemo score...

Richard Shann






Re: Ambitus + Cue gives spurious note column warning

2022-07-23 Thread Richard Shann
On Sat, 2022-07-23 at 16:38 +0200, Jean Abou Samra wrote:
> 
> 
> Le 23/07/2022 à 15:58, Richard Shann a écrit :
> > The combination of Ambitus and a cue seems to provoke a strange
> > warning:
> > 
> > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> > \version "2.22"
> > MvmntIVoiceI = { c'1 c'}
> > MvmntIVoiceII = {
> >   \cueDuringWithClef #"1 Treble on Staff 1 Mvmnt
> > 1"#1 #"treble" { R1*4/4 }
> >   c1
> >  }
> > 
> > \layout { \context {  \Voice   \consists "Ambitus_engraver" }}
> > 
> > \addQuote "1 Treble on Staff 1 Mvmnt 1" \MvmntIVoiceI
> > 
> > \score {
> >    <<
> >  \new Staff  <<
> >    
> >    \new Voice  { \MvmntIVoiceI } %End of
> > voice
> >  >> %End of Staff
> > 
> >  \new Staff   <<
> >  \new Voice = "MvmntIVoiceII"  { \clef
> > alto \MvmntIVoiceII }
> >  >>
> >    >>
> >     }
> > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> > 
> > which gives:
> > 
> > Starting lilypond 2.22.0 [Ambitus-cue-notecolumnclash.ly]...
> > Processing `/home/rshann/Skype/Ambitus-cue-notecolumnclash.ly'
> > Parsing...
> > Interpreting music...
> > Interpreting music...
> > Preprocessing graphical objects...
> > programming error: Note_column without heads and stem
> > continuing, cross fingers
> > /home/rshann/Skype/Ambitus-cue-notecolumnclash.ly:6:18: programming
> > error: note-column has no direction
> >   
> >   c1
> > /home/rshann/Skype/Ambitus-cue-notecolumnclash.ly:6:18: continuing,
> > cross fingers
> > 
> > I cut this down from a much bigger score to make a MWE but in so
> > doing
> > I see I have inadvertently triggered an extra warning, the first
> > one
> > above about Note_column without heads and stem. The original only
> > has
> > the warning about "note-column has no direction". I hope this won't
> > muddy the issue.
> > 
> > Any thoughts?
> 
> 
> 
> That sounds like https://gitlab.com/lilypond/lilypond/-/issues/1113.
> 
> The fix appears to be very simple, currently writing the regression
> tests to post a patch ...
> 
> You can work around it for now using
> 
> \layout {
>    \context {
>  \Score
>  \override AmbitusNoteHead.meta.interfaces =
>    #'(ambitus-interface
>   font-interface
>   ledgered-interface
>   note-head-interface
>   staff-symbol-referencer-interface)
>    }
> }
> 

Thank you! That works in the original context.

Richard


> Best,
> Jean
> 





Ambitus + Cue gives spurious note column warning

2022-07-23 Thread Richard Shann
The combination of Ambitus and a cue seems to provoke a strange
warning:

8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
\version "2.22"
MvmntIVoiceI = { c'1 c'}
MvmntIVoiceII = {
 \cueDuringWithClef #"1 Treble on Staff 1 Mvmnt 1"#1 #"treble" 
{ R1*4/4 }
 c1 
}

\layout { \context {  \Voice   \consists "Ambitus_engraver" }}

\addQuote "1 Treble on Staff 1 Mvmnt 1" \MvmntIVoiceI

\score { 
  <<
\new Staff  << 
  
  \new Voice  { \MvmntIVoiceI } %End of voice
>> %End of Staff

\new Staff   << 
\new Voice = "MvmntIVoiceII"  { \clef alto 
\MvmntIVoiceII }
>> 
  >>
   }
8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><

which gives:

Starting lilypond 2.22.0 [Ambitus-cue-notecolumnclash.ly]...
Processing `/home/rshann/Skype/Ambitus-cue-notecolumnclash.ly'
Parsing...
Interpreting music...
Interpreting music...
Preprocessing graphical objects...
programming error: Note_column without heads and stem
continuing, cross fingers
/home/rshann/Skype/Ambitus-cue-notecolumnclash.ly:6:18: programming
error: note-column has no direction
 
 c1 
/home/rshann/Skype/Ambitus-cue-notecolumnclash.ly:6:18: continuing,
cross fingers

I cut this down from a much bigger score to make a MWE but in so doing
I see I have inadvertently triggered an extra warning, the first one
above about Note_column without heads and stem. The original only has
the warning about "note-column has no direction". I hope this won't
muddy the issue.

Any thoughts?

Richard Shann










Re: Expressive marks

2022-05-13 Thread Richard Shann
On Fri, 2022-05-13 at 14:06 +0200, Stephan Schöll wrote:
> I'm wondering if we need 340 lines of Scheme code or if we could /
> why we can't use the TrillSpanner and just eliminate the "tr" prefix
> and leave the wiggy line,

yes, that's good if you want exactly that wiggley line - the 340 lines
of scheme code let you control the amplitude and frequency of the
wiggles (and even modulate these as the line progresses IIRC), which
can be important when matching early printed scores.

Richard


>  something based on (but not working since I don't understand Scheme
> lists thoroughly):
> \relative c'' {
>    \once \override TrillSpanner.bound-details = '((left (text
> #
>    "scripts.trill")
>  (stencil-offset -0.5 . -1)
>  (padding . 0.5)
>  (attach-dir . 0))
>  (left-broken (end-on-note . #t))
>  (right))
>    
>    e8\startTrillSpan e c c s\stopTrillSpan
>  }
> ... and simply replacing "scripts.trill" with an empty string or
> void/null ...
> 
> Am 13.05.2022 um 09:37 schrieb Richard Shann:
> On Fri, 2022-05-13 at 09:12 +0200, Mario Bolognani wrote:
>  
> > Any idea on how to obtain this kind of expressive marks?
> There is a thread about this which I was involved in, the code that
> resulted is here in Denemo's source LilyPond files:
> 
> http://git.savannah.gnu.org/gitweb/?p=denemo.git;a=blob;f=actions/lilypond/vibrato.ily;h=dadedd6859563a0bac0629b19ac729111ced29bd;hb=HEAD
>  
> 
> from where you can pick it up and use it in raw LilyPond scores.
> 
> Richard Shann
> 
> 
> 
>   





Re: Expressive marks

2022-05-13 Thread Richard Shann
On Fri, 2022-05-13 at 09:12 +0200, Mario Bolognani wrote:
> Any idea on how to obtain this kind of expressive marks?

There is a thread about this which I was involved in, the code that
resulted is here in Denemo's source LilyPond files:

http://git.savannah.gnu.org/gitweb/?p=denemo.git;a=blob;f=actions/lilypond/vibrato.ily;h=dadedd6859563a0bac0629b19ac729111ced29bd;hb=HEAD
> 
from where you can pick it up and use it in raw LilyPond scores.

Richard Shann





Re: Reducing length of stems of beamed notes after \stopStaff

2022-04-19 Thread Richard Shann
On Mon, 2022-04-18 at 11:34 +0200, Thomas Morley wrote:
> Am Sa., 16. Apr. 2022 um 13:49 Uhr schrieb Nate Whetsell
> :
> > 
> > I’m trying to put some beamed notes (no staff lines, time
> > signature, or anything else) in a \markup block. To do this, I’m
> > using a Staff with several engravers \remove’d, using \stopStaff to
> > eliminate staff lines, and then setting Stem.details.beamed-lengths
> > to reduce the length of stems. However, setting
> > Stem.details.beamed-lengths seems to have no effect after
> > \stopStaff, so the stems are too tall. Is there some other way to
> > get short beamed notes in a \markup block?
> > 
> > Here is an example showing what I’ve tried:
> > 
> > \markup { \justify {
> >   Lorem ipsum pqpqpq dolor sit amet, consectetur adipiscing elit,
> > sed do eiusmod
> >   tempor incididunt ut labore et dolore.
> >   \score {
> >     % Normal Staff with \stopStaff (stems too tall)
> >     \new Staff \with {
> >   \remove "Bar_engraver"
> >   \remove "Clef_engraver"
> >   \remove "Time_signature_engraver"
> >   \magnifyStaff #(magstep -3)
> >     } {
> >   \stopStaff
> >   \override Stem.details.beamed-lengths = #'(3)
> >   \relative { \time 6/8 \stemUp b'8 8 8 }
> >     }
> >     \layout { ragged-right=##t indent=0 }
> >   }
> >   \score {
> >     % RhythmicStaff with \stopStaff (stems too tall)
> >     \new RhythmicStaff \with {
> >   \remove "Bar_engraver"
> >   \remove "Clef_engraver"
> >   \remove "Time_signature_engraver"
> >   \magnifyStaff #(magstep -3)
> >     } {
> >   \stopStaff
> >   \override Stem.details.beamed-lengths = #'(3)
> >   \relative { \time 6/8 \stemUp b'8 8 8 }
> >     }
> >     \layout { ragged-right=##t indent=0 }
> >   }
> >   \score {
> >     % Normal Staff *without* \stopStaff (stems shorter, but staff
> > lines shown)
> >     \new Staff \with {
> >   \remove "Bar_engraver"
> >   \remove "Clef_engraver"
> >   \remove "Time_signature_engraver"
> >   \magnifyStaff #(magstep -3)
> >     } {
> >   \override Stem.details.beamed-lengths = #'(3)
> >   \relative { \time 6/8 \stemUp b'8 8 8 }
> >     }
> >     \layout { ragged-right=##t indent=0 }
> >   }
> > } }
> 
> \stopStaff is not the right tool for your purpose.
> Why not adding
> \override StaffSymbol.line-count = 0
> to the Staff's \with
> ?

This seems to work well - here is a somewhat tidied up example:

\version "2.22.0"
\markup { \justify {
   Here are three quavers 
   \raise #0.4\score {
   \new Staff \with {
 \remove "Bar_engraver"
 \remove "Clef_engraver"
 \remove "Time_signature_engraver"
 \magnifyStaff #(magstep -3)
 \override StaffSymbol.line-count = 0
 \override 
Stem.details.beamed-lengths = #'(3)
} 
  { \stemUp b'8[ 8 8] }

   \layout { ragged-right=##t indent=0 }
 }
 , nicely spaced and beamed! 
}
   }

I used the \raise to place note bottoms of the note heads on the text
line, but I haven't looked at how it behaves as you change the overall
score size; it would be good to turn off the autobeamer as well to give
complete control over the beaming...

Richard






Re: Displaying typesetting information at compile time

2022-03-22 Thread Richard Shann
On Mon, 2022-03-21 at 17:28 +0100, Jean Abou Samra wrote:
> 
> 
> Le 21/03/2022 à 17:24, Richard Shann a écrit :
> > On Sun, 2022-03-20 at 20:09 +0100, Jean Abou Samra wrote:
> > > 
> > [...] perhaps there is something altogether
> > simpler?
> 
> 
> 
> In that case, just output the info at the end of page-post-process
> instead
> of storing it and retrieving it later.
> 
> \version "2.22.2"
> 
> \paper {
>     page-post-process =
>   #(lambda (paper pages)
>  (let ((n-systems 0)
>    (page-min #f)
>    (page-max #f))
>    (for-each
>     (lambda (page)
>   (for-each
>    (lambda (line)
>  (let ((sys (ly:prob-property line 'system-grob)))
>    (if (ly:grob? sys)
>    (let ((sys-page (ly:grob-property sys 'page-
> number)))
>     (set! n-systems (1+ n-systems))
>     (set! page-min (if page-min
>    (min page-min sys-page)
>    sys-page))
>     (set! page-max (if page-max
>    (max page-max sys-page)
>    sys-page))
>    (ly:prob-property page 'lines)))
>     pages)
>    (ly:message "~a systems on ~a pages"
>    n-systems
>    (1+ (- page-max page-min)
> }
> 
> \repeat unfold 10 { 1 1 \break }
> \repeat unfold 13 { 1 1 \break }
> 
Perfect! Thanks, I should have thought to track down documentation for
page-post-process ...
Richard





Re: Displaying typesetting information at compile time

2022-03-21 Thread Richard Shann
On Sun, 2022-03-20 at 20:09 +0100, Jean Abou Samra wrote:
> 
> 
> Le 20/03/2022 à 19:09, Richard Shann a écrit :
> > On Sun, 2022-03-20 at 18:43 +0100, Jean Abou Samra wrote:
> > > \version "2.22.2"
> > > 
> > > markWithPageInfo =
> > >     %% Must not get called before line breaking
> > >     \tweak X-extent #'(0 . 0)
> > >     \tweak Y-extent #'(0 . 0)
> > >     \tweak horizontal-skylines
> > >   #(ly:make-unpure-pure-container ly:grob::simple-horizontal-
> > > skylines-from-extents)
> > >     \tweak vertical-skylines
> > >   #(ly:make-unpure-pure-container ly:grob::simple-vertical-
> > > skylines-from-extents)
> > >     \tweak stencil
> > >   #(lambda (grob)
> > >  (let* ((sys (ly:grob-system grob))
> > >     ;; No broken pieces for systems ...
> > >     (alignment (ly:grob-object sys 'vertical-
> > > alignment))
> > >     (all-alignments (ly:spanner-broken-into (ly:grob-
> > > original alignment)))
> > >     (all-systems (map ly:grob-system all-alignments))
> > >     (n-systems (length all-systems))
> > >     (all-pages (map (lambda (s) (ly:grob-property s
> > > 'page-
> > > number))
> > >     all-systems))
> > >     (n-pages (1+ (- (apply max all-pages)
> > >     (apply min all-pages
> > >     (layout (ly:grob-layout grob))
> > >     (defs (append `((n-systems . ,(number->string n-
> > > systems))
> > >     (n-pages . ,(number->string n-
> > > pages)))
> > >   (ly:output-def-lookup layout 'text-
> > > font-
> > > defaults)))
> > >     (props (ly:grob-alist-chain grob defs))
> > >     (text (ly:grob-property grob 'text)))
> > >    (interpret-markup layout props text)))
> > >     \mark \etc
> > > 
> > > {
> > >     \markWithPageInfo \markup { Have \fromproperty #'n-systems
> > > systems
> > > on \fromproperty #'n-pages pages }
> > >     \repeat unfold 20 { 1 1 \break }
> > > }
> > Wow! That goes beyond what I had in mind - it actually outputs the
> > information within the typeset (I guess the stuff with skylining
> > might
> > be to avoid the typesetting of this information affecting the
> > number of
> > pages/systems??).
> 
> 
> 
> Sort of, yes. Normally, the RehearsalMark is drawn before line
> breaking 
> is done, and its width and height are accounted for during page
> breaking 
> and page spacing. At that time, there is obviously no number of pages
> or 
> systems available. So I'm giving it predetermined extents and
> skylines, 
> which are used for page breaking and page spacing purposes, only
> after 
> which the RehearsalMark's stencil is computed. The drawback is that
> it 
> could collide with something on top of it.
> 
> However, there was a flaw in that code. When you have several scores
> in 
> a bookpart, page-count and system-count override the total numbers
> for 
> the whole bookpart, but I was counting them per score. Here is a
> fixed 
> version:
> 
> \version "2.22.2"
> 
> \paper {
>    page-post-process =
>  #(lambda (paper pages)
>     (let ((n-systems 0)
>   (page-min #f)
>   (page-max #f))
>   (for-each
>    (lambda (page)
>  (for-each
>   (lambda (line)
>     (let ((sys (ly:prob-property line 'system-grob)))
>   (if (ly:grob? sys)
>   (let ((sys-page (ly:grob-property sys 'page-
> number)))
>    (set! n-systems (1+ n-systems))
>    (set! page-min (if page-min
>   (min page-min sys-page)
>   sys-page))
>    (set! page-max (if page-max
>   (max page-max sys-page)
>   sys-page))
>   (ly:prob-property page 'lines)))
>    pages)
>   (ly:output-def-set-variable! paper 'n-systems n-systems)
>   (ly:output-def-set-variable! paper 'n-pages (1+ (- page-max
> page-min)
> }
> 
> #(define-markup-command (page-info layout props arg) (markup?)
>     (ly:make-stencil
>

Re: Displaying typesetting information at compile time

2022-03-20 Thread Richard Shann
On Sun, 2022-03-20 at 18:43 +0100, Jean Abou Samra wrote:
> 
> \version "2.22.2"
> 
> markWithPageInfo =
>    %% Must not get called before line breaking
>    \tweak X-extent #'(0 . 0)
>    \tweak Y-extent #'(0 . 0)
>    \tweak horizontal-skylines
>  #(ly:make-unpure-pure-container ly:grob::simple-horizontal-
> skylines-from-extents)
>    \tweak vertical-skylines
>  #(ly:make-unpure-pure-container ly:grob::simple-vertical-
> skylines-from-extents)
>    \tweak stencil
>  #(lambda (grob)
>     (let* ((sys (ly:grob-system grob))
>    ;; No broken pieces for systems ...
>    (alignment (ly:grob-object sys 'vertical-alignment))
>    (all-alignments (ly:spanner-broken-into (ly:grob-
> original alignment)))
>    (all-systems (map ly:grob-system all-alignments))
>    (n-systems (length all-systems))
>    (all-pages (map (lambda (s) (ly:grob-property s 'page-
> number))
>    all-systems))
>    (n-pages (1+ (- (apply max all-pages)
>    (apply min all-pages
>    (layout (ly:grob-layout grob))
>    (defs (append `((n-systems . ,(number->string n-
> systems))
>    (n-pages . ,(number->string n-pages)))
>  (ly:output-def-lookup layout 'text-font-
> defaults)))
>    (props (ly:grob-alist-chain grob defs))
>    (text (ly:grob-property grob 'text)))
>   (interpret-markup layout props text)))
>    \mark \etc
> 
> {
>    \markWithPageInfo \markup { Have \fromproperty #'n-systems systems
> on \fromproperty #'n-pages pages }
>    \repeat unfold 20 { 1 1 \break }
> }

Wow! That goes beyond what I had in mind - it actually outputs the
information within the typeset (I guess the stuff with skylining might
be to avoid the typesetting of this information affecting the number of
pages/systems??). What I had in mind was just some Scheme (display ...)
inserted in the way Valentin (*) did with this:

\override Score.SpacingSpanner.common-shortest-duration =
#(grob-transformer 'common-shortest-duration
   (lambda (grob orig) (display orig) (newline) orig))

So that the information can be used to guide selection of tweaks.

Richard

(*) in the "Re: Wildly different horizontal spacing in two similar
scores." thread







Displaying typesetting information at compile time

2022-03-20 Thread Richard Shann
I wonder if someone could suggest how to get LilyPond to emit various
bits of information about the score it is typesetting. Specifically can
it be persuaded to display the number of pages in the output PDF and
the total number of systems?
The idea would be to guide the user as to suitable values for

\paper {
  system-count = xx
  page-count = yy
}

without having to count up the number of systems (pages is not really a
problem of course).

Richard Shann






Re: Wildly different horizontal spacing in two similar scores.

2022-03-19 Thread Richard Shann
On Sat, 2022-03-19 at 12:49 +, Paul Hodges wrote:
> I don't use that - I specify the exact number of systems I want, and
> on how many pages, using:
> \paper {
>   system-count = xx
>   page-count = yy
> }
> 
> This forces the length to be stretched to the extent I require; then
> detailed adjustments can be made with \break and \pageBreak.

Thanks for this, it works well, the only thing to watch is when you
specify too few systems the last one runs off the right hand side.

Richard


> 
> Paul
> 
> 
> From: Richard Shann 
> > 
> > I've tried adding
> >  \paper {
> >     systems-per-page = 20
> >    }
> > 
> > 
> > 





Re: Wildly different horizontal spacing in two similar scores.

2022-03-18 Thread Richard Shann
On Fri, 2022-03-18 at 17:30 +, Paul Hodges wrote:
> From: Richard Shann 
> > 
> > I wonder what "There is no convenient mechanism to manually
> > override
> > spacing. " means ...
> 
> 
> I take it to mean that adjusting spacing on a smaller scale, like
> within a bar, is not so easy.

ah, I see, thank you. However:
> 
> [...]

> In the specific case of the example that this thread is about, I
> would
> probably have simply specified the number of systems without another
> thought.

I've tried adding
 \paper {
systems-per-page = 20
   }
(to take an extreme case) but it doesn't change the horizontal spacing
at all it just forces more systems onto the page causing them to
collide as you request more. The problem I am facing is that one part
is spaced horizontally much more loosely than another seemingly similar
part.

Richard
 







Re: Wildly different horizontal spacing in two similar scores.

2022-03-18 Thread Richard Shann
On Fri, 2022-03-18 at 12:27 +, Richard Shann wrote:
> On Fri, 2022-03-18 at 12:11 +0100, Valentin Petzel wrote:
> > Let’s take a look at what’s happening here:
> > 
> > if we add
> > \override Score.SpacingSpanner.common-shortest-duration =
> > #(grob-transformer 'common-shortest-duration
> >    (lambda (grob orig) (display orig) (newline)
> > orig))
> 
> Many thanks - it sounds like it will worth experimenting with setting
> common-shortest-duration manually to common-up the appearamce of the
> parts. Would some syntax along the lines 
> 
> \override Score.SpacingSpanner.common-shortest-duration = #(make-
> moement '(1 . 8))
> 
> do this? (I'm doubtful because I didn't see an example in the manual
> -
> rather the statement
> "There is no convenient mechanism to manually override spacing. "
> at 
> https://lilypond.org/doc/v2.22/Documentation/notation/horizontal-spacing-overview
> )

To answer my own question (I looked further down in the docs quoted)

\override Score.SpacingSpanner.common-shortest-duration = #(ly:make-
moment 1/8)

does the needed tweak.

I wonder what "There is no convenient mechanism to manually override
spacing. " means ...

Richard


> 
> Richard
> > 
> > at the beginning we will have the value of common-shortest duration
> > ouput. For 
> > 1-1 this is 1/32, for 1-4 this is 1/8. To understand why this is
> > happening you 
> > need to understand how Lilypond calculates the common-shortest
> > duration. 
> > Basically Lilypond takes the smallest duration for each measure,
> > and
> > then 
> > counts for each one how many measures have it as smallest duration.
> > Then 
> > Lilypond simply finds the duration with the highest count and
> > returns
> > the 
> > minimum of that one and base-shortest duration.
> > 
> > Now this algorithm is kind of unstable. In your case you have many
> > measures 
> > with 1/8th notes as shortest duration and many measures with 1/32nd
> > notes as 
> > shortest duration. So if you have slightly more measures of the
> > first
> > type you 
> > will get the dense result, if you have slightly more of the second
> > type you 
> > get the wide result.
> > 
> > So in some sense this is "working as intended", it is just that the
> > algorithm 
> > for common-shortest-duration is probably not optimal. It might be
> > better to 
> > take some sort of weighted average, which would be much more stable
> > in such 
> > situations. I’ll do some experimenting for this.
> > 
> > Cheers,
> > Valentin
> > 
> > Am Freitag, 18. März 2022, 10:39:10 CET schrieb Richard Shann:
> > > Attached are two scores which have quite similar music in them
> > > but
> > > LilyPond typesets one them with about twice as much horizontal
> > > space as
> > > the other.
> > > The documentation gives an overview of the algorithm for
> > > horizontal
> > > spacing but eyeballing this music I can't see any shortest-note
> > > differences that could trigger this.
> > > Any idea what might be going on?
> > > 
> > > Richard Shann
> > 
> 
> 
> 





Re: Wildly different horizontal spacing in two similar scores.

2022-03-18 Thread Richard Shann
On Fri, 2022-03-18 at 12:11 +0100, Valentin Petzel wrote:
> Let’s take a look at what’s happening here:
> 
> if we add
> \override Score.SpacingSpanner.common-shortest-duration =
> #(grob-transformer 'common-shortest-duration
>    (lambda (grob orig) (display orig) (newline)
> orig))

Many thanks - it sounds like it will worth experimenting with setting
common-shortest-duration manually to common-up the appearamce of the
parts. Would some syntax along the lines 

\override Score.SpacingSpanner.common-shortest-duration = #(make-
moement '(1 . 8))

do this? (I'm doubtful because I didn't see an example in the manual -
rather the statement
"There is no convenient mechanism to manually override spacing. "
at 
https://lilypond.org/doc/v2.22/Documentation/notation/horizontal-spacing-overview
)

Richard
> 
> at the beginning we will have the value of common-shortest duration
> ouput. For 
> 1-1 this is 1/32, for 1-4 this is 1/8. To understand why this is
> happening you 
> need to understand how Lilypond calculates the common-shortest
> duration. 
> Basically Lilypond takes the smallest duration for each measure, and
> then 
> counts for each one how many measures have it as smallest duration.
> Then 
> Lilypond simply finds the duration with the highest count and returns
> the 
> minimum of that one and base-shortest duration.
> 
> Now this algorithm is kind of unstable. In your case you have many
> measures 
> with 1/8th notes as shortest duration and many measures with 1/32nd
> notes as 
> shortest duration. So if you have slightly more measures of the first
> type you 
> will get the dense result, if you have slightly more of the second
> type you 
> get the wide result.
> 
> So in some sense this is "working as intended", it is just that the
> algorithm 
> for common-shortest-duration is probably not optimal. It might be
> better to 
> take some sort of weighted average, which would be much more stable
> in such 
> situations. I’ll do some experimenting for this.
> 
> Cheers,
> Valentin
> 
> Am Freitag, 18. März 2022, 10:39:10 CET schrieb Richard Shann:
> > Attached are two scores which have quite similar music in them but
> > LilyPond typesets one them with about twice as much horizontal
> > space as
> > the other.
> > The documentation gives an overview of the algorithm for horizontal
> > spacing but eyeballing this music I can't see any shortest-note
> > differences that could trigger this.
> > Any idea what might be going on?
> > 
> > Richard Shann
> 





Re: Creating a book of pieces?

2022-02-26 Thread Richard Shann
On Sat, 2022-02-26 at 00:45 +, Alasdair McAndrew wrote:
> Thank you very much.  I already use multiple score blocks for
> different movements; each movement has its own heading, time
> signature etc.  So I get a single file from multiple score blocks. 
> But these multiple blocks form suites, and I want the book to refer
> to the suites, rather than their individual movements.
> 
> That is, the contents page might have
> 
> Suite 1 ...    3
> Suite 2 ...    14
> 
> and so on for the pages for each suite.  But Suite 1 itself (and all
> the others) is built from the score blocks: Overture, Allemande,
> Bourree, Menuet, Gavotte, Gigue  (for example).  Maybe LaTeX will in
> fact be my best bet?

There was a recent discussion of this in the thread starting here:

https://lists.gnu.org/archive/html/lilypond-user/2022-02/msg00187.html

The upshot is that there is currently no way to create a book directly
from LilyPond with your Suite 1 having its own font-size, indent etc
differing from Suite 2 and so on.
The solution I've created - in Denemo(*), but it should be possible to
do it otherwise - uses Ghostscript to concatenate PDFs and report on
their page count (and multiple runs of LilyPond on the separate Suites
to install the correct page numbering). With this you can create an
arbitrary collection of LilyPond books and put them together into a
single PDF. Generating a title page and table of contents is an obvious
extension.

HTH

Richard Shann

(*)
http://git.savannah.gnu.org/gitweb/?p=denemo.git;a=blob;f=actions/menus/MainMenu/FileMenu/Export/ExportBook.scm;h=663a5e8e8c40ea73d398cbf97e59ea5b48acaeba;hb=de8e0176e500ed969579c574be7e7d842f7f4160

> 
> cheers,
> Alasdair
> 
> On Saturday 26 February 2022 11:37:12 (+11:00), Valentin Petzel
> wrote:
> 
> > Hello Alasdair,
> > 
> > Yes, there is. Placing multiple \score{...} blocks in one file will
> > produce one pdf. Using \book{..} we can split this into multiple
> > pdfs produced from one file.
> > 
> > Title pages can be designed using \markup{...}, but it is also
> > viable to create the title page in some other application and join
> > the pdfs (this might be nescessary if you want to design very
> > intricate pdfs).
> > 
> > Doing a ToC is possible as well, see here:
> > https://lilypond.org/doc/v2.23/Documentation/notation/table-of-contents
> > 
> > Cheers,
> > Valentin
> > 
> > 
> > Am Freitag, 25. Februar 2022, 22:49:22 CET schrieb Alasdair
> > McAndrew:
> > > Hello,
> > > Over the past few weeks I have been transcribing a set of 18th
> > > century
> > > suites into Lilypond (they look very nice, too), and now I'd like
> > > to
> > > collect them into one "book"; that is, a single PDF file with
> > > title page,
> > > table of contents etc.
> > > 
> > > Can Lilypond do this, or do I need to invoke some other
> > > software?  I can
> > > use LaTeX happily enough - I've been using it professionally for
> > > decades.
> > > (However, getting page numbers correct in LaTeX from included PDF
> > > files has
> > > a few pitfalls.)  Is there a "standard" way of collecting a whole
> > > lot of
> > > Lilypond pieces into one nice product?
> > > 
> > > Thanks very much,
> > > Alasdair
> > 
> > 
> 
> -- 
> 0432 854 858
> https://numbersandshapes.net





Re: Concatenating LilyPond scores with different staff sizes.

2022-02-09 Thread Richard Shann
On Wed, 2022-02-09 at 09:42 -0700, Abraham Lee wrote:
> Hey, Richard!
> 
> On Wed, Feb 9, 2022 at 9:13 AM Richard Shann
>  wrote:
> > On Wed, 2022-02-09 at 13:00 +, Valentin Petzel wrote:
> > > Hello Richard,
> > > 
> > > I do not like to say such things, but read the docs:
> > > 
> > http://lilypond.org/doc/v2.23/Documentation/notation/setting-the-staff-size
> > > 
> > > set-global-staff-size is by definition used to set the staffsize
> > > globally. For affecting one specific score you want to use
> > layout-
> > > set-staff-size.
> > 
> > I perhaps should have given details of my experimentations with
> > this.
> > It seems that the terminology here is confusing - the set-global-
> > staff-
> > size is *not* equivalent to layout-set-staff-size on each score
> > block
> > as the following shows:
> > 
> > \version "2.22.0"
> > %#(set-global-staff-size 44)
> > \score {
> >   \layout {
> >       #(layout-set-staff-size 44)
> >     } 
> >   {e f g a}}
> > 
> > Commenting and un-commenting the set-global-staff-size shows that
> > they
> > are different, and indeed I'm not quite sure what the use-case is
> > for
> > the layout-set-staff-size, it distorts the placement of clefs/time
> > signatures.
> > I was hoping there might be a set of settings which could be used
> > to do
> > what set-global-staff-size does on each score block...
> > 
> > Richard
> > 
> > > 
> > > Cheers,
> > > Valentin
> > > 
> > > 09.02.2022 13:04:16 Richard Shann :
> > > 
> > > > To create a single PDF of a full score and parts it is
> > convenient
> > > > in
> > > > Denemo to simply concatenate the LilyPond; something like this:
> > > > 
> > > > \version "2.22.0"
> > > > #(set-global-staff-size 20)
> > > > \markup "First"
> > > > { c d e}
> > > > #(set-global-staff-size 10)
> > > > \markup "Second"
> > > > {e f g}
> > > > 
> > > > This runs into the problem that the full score is often needed
> > at a
> > > > smaller font size and in the above code the last set-global-
> > staff-
> > > > size
> > > > is, naturally, the one used for both \score{}s.
> > > > 
> > > > I realize it may be a long shot, and a bit esoteric, but is
> > there
> > > > any
> > > > way something like that could be achieved? (I'm not seeking
> > > > radically
> > > > different approaches here as this won't be hand-written).
> > > > 
> > > > Richard Shann
> > 
> 
> 
>  In my own experimentation, there's no convenient way to get what you
> want in the same output file. The last call to set-global-staff-size
> affects the current \book. You can then re-call the command if you
> explicitly callout another \book after that, but that generates a
> separate output file for each \book block.

yes, it's quite possible then to concatenate the PDFs with ghostscript
but the pagination is wrong. 
I can't help thinking that there might be a set of individual sizes
that set-global-staff-size is affecting which could be separately
tweaked at score level. The very fact that the variable set-global-
staff-size alters the size of the markup for titles etc indicates that
the scope of the variable has drifted away from what was originally
intended. And the fact that layout-set-staff-size fails to keep clefs
and time signatures behaving properly seems strange too, perhaps there
is some further variables that will make them behave... it seems this
is a case for a LilyPond guru.

Richard









Re: Concatenating LilyPond scores with different staff sizes.

2022-02-09 Thread Richard Shann
On Wed, 2022-02-09 at 13:00 +, Valentin Petzel wrote:
> Hello Richard,
> 
> I do not like to say such things, but read the docs:
> http://lilypond.org/doc/v2.23/Documentation/notation/setting-the-staff-size
> 
> set-global-staff-size is by definition used to set the staffsize
> globally. For affecting one specific score you want to use layout-
> set-staff-size.

I perhaps should have given details of my experimentations with this.
It seems that the terminology here is confusing - the set-global-staff-
size is *not* equivalent to layout-set-staff-size on each score block
as the following shows:

\version "2.22.0"
%#(set-global-staff-size 44)
\score {
  \layout {
  #(layout-set-staff-size 44)
} 
  {e f g a}}

Commenting and un-commenting the set-global-staff-size shows that they
are different, and indeed I'm not quite sure what the use-case is for
the layout-set-staff-size, it distorts the placement of clefs/time
signatures.
I was hoping there might be a set of settings which could be used to do
what set-global-staff-size does on each score block...

Richard

> 
> Cheers,
> Valentin
> 
> 09.02.2022 13:04:16 Richard Shann :
> 
> > To create a single PDF of a full score and parts it is convenient
> > in
> > Denemo to simply concatenate the LilyPond; something like this:
> > 
> > \version "2.22.0"
> > #(set-global-staff-size 20)
> > \markup "First"
> > { c d e}
> > #(set-global-staff-size 10)
> > \markup "Second"
> > {e f g}
> > 
> > This runs into the problem that the full score is often needed at a
> > smaller font size and in the above code the last set-global-staff-
> > size
> > is, naturally, the one used for both \score{}s.
> > 
> > I realize it may be a long shot, and a bit esoteric, but is there
> > any
> > way something like that could be achieved? (I'm not seeking
> > radically
> > different approaches here as this won't be hand-written).
> > 
> > Richard Shann





Concatenating LilyPond scores with different staff sizes.

2022-02-09 Thread Richard Shann
To create a single PDF of a full score and parts it is convenient in
Denemo to simply concatenate the LilyPond; something like this:

\version "2.22.0"
#(set-global-staff-size 20) 
\markup "First"
{ c d e}
#(set-global-staff-size 10) 
\markup "Second"
{e f g}

This runs into the problem that the full score is often needed at a
smaller font size and in the above code the last set-global-staff-size
is, naturally, the one used for both \score{}s.

I realize it may be a long shot, and a bit esoteric, but is there any
way something like that could be achieved? (I'm not seeking radically
different approaches here as this won't be hand-written).

Richard Shann





Re: (Solved)Re: To get rid of the horizontal line before the footnotes?

2022-02-07 Thread Richard Shann
On Mon, 2022-02-07 at 15:59 +, Carl Sorensen wrote:
> 
> 
> On 2/7/22, 8:57 AM, "lilypond-user on behalf of Richard Shann"
>  rich...@rshann.plus.com> wrote:
> 
>     On Mon, 2022-02-07 at 13:41 +0100, Jean Abou Samra wrote:
>     > Le 05/02/2022 à 12:50, Richard Shann a écrit :
>     > > On Sat, 2022-02-05 at 11:30 +, Richard Shann wrote:
>     > > > Is there a way to drop the line that is drawn below the
> systems
>     > > > above
>     > > > the footnotes?
>     > > Sorry for asking before searching the mailing-list archives,
>     > > 
>     > > \paper { footnote-separator-markup = ##f }
>     > > 
>     > > is the answer I see. The docs often still defeat me, just too
> much
>     > > stuff :(
>     > 
>     > 
>     > 
>     > How about using the indices? Looking at
>     > 
>     >
> https://lilypond.org/doc/v2.22/Documentation/notation/lilypond-index.html#lilypond-index_cp_letter-F
>     > 
>     > around 'footnote' directs you to 'footnote-separator-markup'
>     > immediately.
>     
>     Thanks-
> It's good that it's there - I often look in those indices to
>     try and track things down; what that entry leads to is an entry
> in a
>     section called "Miscellaneous paper variables", I must have
> missed it.
>     I wonder if that entry in that section would be better placed in
> the
>     section on footnotes 
>     
>    
> https://lilypond.org/doc/v2.22/Documentation/notation/creating-footnotes
>     
>     I gave this section a good read. I noticed it did document
> annotation-
>     line which I picked up on when I was implementing footnotes in
> Denemo
>     some years ago, but no mention of the footnote-separator ...
> 
> The footnote-separator markup is listed in the first paragraph of the
> page on the link you sent.

ha, I see I linked to 2.22 but I had been reading 2.20 :( 
nice to know that the docs are improving as always.

Richard





Re: (Solved)Re: To get rid of the horizontal line before the footnotes?

2022-02-07 Thread Richard Shann
On Mon, 2022-02-07 at 13:41 +0100, Jean Abou Samra wrote:
> Le 05/02/2022 à 12:50, Richard Shann a écrit :
> > On Sat, 2022-02-05 at 11:30 +, Richard Shann wrote:
> > > Is there a way to drop the line that is drawn below the systems
> > > above
> > > the footnotes?
> > Sorry for asking before searching the mailing-list archives,
> > 
> > \paper { footnote-separator-markup = ##f }
> > 
> > is the answer I see. The docs often still defeat me, just too much
> > stuff :(
> 
> 
> 
> How about using the indices? Looking at
> 
> https://lilypond.org/doc/v2.22/Documentation/notation/lilypond-index.html#lilypond-index_cp_letter-F
> 
> around 'footnote' directs you to 'footnote-separator-markup'
> immediately.

Thanks-
It's good that it's there - I often look in those indices to
try and track things down; what that entry leads to is an entry in a
section called "Miscellaneous paper variables", I must have missed it.
I wonder if that entry in that section would be better placed in the
section on footnotes 

https://lilypond.org/doc/v2.22/Documentation/notation/creating-footnotes

I gave this section a good read. I noticed it did document annotation-
line which I picked up on when I was implementing footnotes in Denemo
some years ago, but no mention of the footnote-separator ...

Richard








Re: Slurs with "afterGrace"

2022-02-06 Thread Richard Shann



\afterGrace g4(-+ {a16 g16)}   }

Richard

On Sun, 2022-02-06 at 09:13 +, Alasdair McAndrew wrote:
> Thank you very much!  (But in Australia, where I am, it is early
> evening).   I did try that, but the difficulty is that I already have
> a symbol attached to the note (which I should have included in my
> example):
> 
> \afterGrace g4-+( {a16 g16} )
> 
> I've tried moving the beginning of the slur to directly after the
> note:
> 
> \afterGrace g4(-+ {a16 g16} )
> 
> but this is no good either.  I'm sorry not to have included this
> clearly important detail in my first post.
> 
> Alasdair
> 
> 
> 
> On Sunday 06 February 2022 19:31:32 (+11:00), Rip _Mus wrote:
> 
> > Good morning,
> > try:
> > 
> > \afterGrace g4( { a16 g16) }
> > 
> > The slur event must be attached directly after the note.
> > 
> > Rip_mus
> > 
> > Il dom 6 feb 2022, 08:59 Alasdair McAndrew  ha
> > scritto:
> > > This works:
> > > g4( \grace {a16 g16})
> > > 
> > > making a slur which includes the grace notes.  But in order to
> > > get the 
> > > right spacing and barring (I need grace notes to occur before the
> > > bar line, 
> > > rather than after), I need to use "afterGrace":
> > > 
> > > \afterGrace g4 {a16 g16}
> > > 
> > > However, if I attempt to include a slur:
> > > 
> > > \afterGrace g4( {a16 g16} )
> > > 
> > > I get a warning about an "Unattached SlurEvent".  Lilypond makes
> > > a good 
> > > guess at what I want and bungs a slur in anyway - but what does
> > > this 
> > > warning mean, and how can I avoid it?  Thank you!
> > > 
> > > Alasdair





Re: Slurs with "afterGrace"

2022-02-06 Thread Richard Shann
On Sun, 2022-02-06 at 10:00 +, Alasdair McAndrew wrote:
> Thank you!  I would never have thought of putting the ending slur
> inside 
> the grace note braces - but it works perfectly. 

well I got there because it said the error was in column 30, i.e. the
closing ) and I suspected that those are supposed to postfixed to the
note where the slur ends, not a sequence { } of notes.

Richard

>  
> Again, thanks.
> 
> Alasdair
> 
> On Sunday 06 February 2022 20:53:12 (+11:00), Richard Shann wrote:
> 
>  >
>  >
>  > \afterGrace g4(-+ {a16 g16)} }
>  >
>  > Richard
>  >
>  > On Sun, 2022-02-06 at 09:13 +, Alasdair McAndrew wrote:
>  > > Thank you very much!  (But in Australia, where I am, it is early
>  > > evening).   I did try that, but the difficulty is that I already
> have
>  > > a symbol attached to the note (which I should have included in
> my
>  > > example):
>  > >
>  > > \afterGrace g4-+( {a16 g16} )
>  > >
>  > > I've tried moving the beginning of the slur to directly after
> the
>  > > note:
>  > >
>  > > \afterGrace g4(-+ {a16 g16} )
>  > >
>  > > but this is no good either.  I'm sorry not to have included this
>  > > clearly important detail in my first post.
>  > >
>  > > Alasdair
>  > >
>  > >
>  > >
>  > > On Sunday 06 February 2022 19:31:32 (+11:00), Rip _Mus wrote:
>  > >
>  > > > Good morning,
>  > > > try:
>  > > >
>  > > > \afterGrace g4( { a16 g16) }
>  > > >
>  > > > The slur event must be attached directly after the note.
>  > > >
>  > > > Rip_mus
>  > > >
>  > > > Il dom 6 feb 2022, 08:59 Alasdair McAndrew 
> ha
>  > > > scritto:
>  > > > > This works:
>  > > > > g4( \grace {a16 g16})
>  > > > >
>  > > > > making a slur which includes the grace notes.  But in order
> to
>  > > > > get the
>  > > > > right spacing and barring (I need grace notes to occur
> before the
>  > > > > bar line,
>  > > > > rather than after), I need to use "afterGrace":
>  > > > >
>  > > > > \afterGrace g4 {a16 g16}
>  > > > >
>  > > > > However, if I attempt to include a slur:
>  > > > >
>  > > > > \afterGrace g4( {a16 g16} )
>  > > > >
>  > > > > I get a warning about an "Unattached SlurEvent".  Lilypond
> makes
>  > > > > a good
>  > > > > guess at what I want and bungs a slur in anyway - but what
> does
>  > > > > this
>  > > > > warning mean, and how can I avoid it?  Thank you!
>  > > > >
>  > > > > Alasdair
>  >
>  >
>  >





Re: Key Signature Change beyond the end of a movement.

2022-02-05 Thread Richard Shann
On Sun, 2022-02-06 at 00:15 +0900, Masaki, Akikazu wrote:
> Hi Richard,
> 
> The last spacer is not necessary, but staff lines don't reach
> trailing
> key or time signatures by default.  (I guess you tried that.)

yes, that's the purpose of the spacer.

> Set StaffSymbol.break-align-symbols property;
> 
> \version "2.22.0"
> \layout {
>    \context {
>  \Staff
>  \override StaffSymbol.break-align-symbols = #'()
>  % \override StaffSymbol.break-align-symbols = #'(key-signature)
> %% a bit different result
>    }
> }
> \markup { Movement I }
> {
>    c'' c'' c'' c''
>    c''  c''
>    \bar "|." \key bes \major }
> 

Thank you for this insight. I worry what else altering this value might
change, but can find no reference to break-align-symbols, a search on
lilypond.org gives just one hit for
break-align-symbol (not symbols) - namely

http://lilypond.org/doc/v2.20/Documentation/internals/doublepercentrepeat

which lead me to

http://lilypond.org/doc/v2.20/Documentation/internals/break_002dalignment_002dinterface


which still doesn't mention a property break-align-symbols ...

I'm guessing setting this must impact something else, as otherwise the
present default just leads to the rather unusual typesetting for the
trailing key change.

Richard

> 
> Akikazu
> 
> 
> On 2022/02/05 21:58, Richard Shann wrote:
> > When the following movement in a score is going to be in a
> > different
> > key the player is sometimes warned by printing a key signature
> > change
> > after the closing barline.
> > The attached file accomplishes this, but I wonder if there is
> > something
> > less hacky that does this. In particular the spacer rest duration
> > matters but what it is doing exactly seems a mystery.
> > 
> > Richard Shann
> > 
> > 
> 





Key Signature Change beyond the end of a movement.

2022-02-05 Thread Richard Shann
When the following movement in a score is going to be in a different
key the player is sometimes warned by printing a key signature change
after the closing barline.
The attached file accomplishes this, but I wonder if there is something
less hacky that does this. In particular the spacer rest duration
matters but what it is doing exactly seems a mystery.

Richard Shann



\version "2.22.0"
\markup {Movement I}
{
  c'' c'' c'' c'' 
  c''  c'' 
 \bar "|." \key bes \major s16  }
\markup {Movement II }
{ \key bes \major
  c''4 c'' c'' c'' 
  c''  c'' \bar "|." }

(Solved)Re: To get rid of the horizontal line before the footnotes?

2022-02-05 Thread Richard Shann
On Sat, 2022-02-05 at 11:30 +, Richard Shann wrote:
> Is there a way to drop the line that is drawn below the systems above
> the footnotes?

Sorry for asking before searching the mailing-list archives,

\paper { footnote-separator-markup = ##f }

is the answer I see. The docs often still defeat me, just too much
stuff :(

Richard





To get rid of the horizontal line before the footnotes?

2022-02-05 Thread Richard Shann
Is there a way to drop the line that is drawn below the systems above
the footnotes?

Richard Shann





Re: Vibrato (wavy lines) notation

2022-01-14 Thread Richard Shann
On Fri, 2022-01-14 at 20:41 +0100, Valentin Petzel wrote:
> Hello Richard,
> 
> The file you’ve given us has a lot of nonsensical quoting in lines
> 149-153.
> 
> Basically `(path ...) is already quasi-quoted, so there is no reason
> to quote 
> the symbol round (as it is already quoted). Also you will get an
> error for 
> line 150 where we have
> 
> `(,@',(concatenate path-final))
> 
> So we first quasi-quote something that is already quasi-quoted, then
> we create 
> a list, use an unquote splice operator (,@), which basically
> evaluates the 
> expression to a list and then gives the entries of the list instead
> of the 
> list (note we are CREATING a list first just to splice something into
> it – 
> instead of this we can simply do ,(concatenate path-final)), then we
> are 
> quoting the whole thing we just unquoted again to add another
> unquote, which 
> does not work as the last quote was not a quasi-quote.
> 
> So to get it to work closest to what’s in the file we’d need to do
> 
> (,@`,(concatenate path-final))
> 
> Or alternatively
> 
> ,`(,@`,(concatenate path-final))
> 
> But much more intelligent would be simply doing this:
> 
> ,(concatenate path-final)
> 
> I have appended a fixed version of your file.
> 
> Cheers,
> Valentin

Thank you and Jean Abou for your quick and insightful replies - my
score is once more typesetting beautifully.

Richard





Re: Vibrato (wavy lines) notation

2022-01-14 Thread Richard Shann
On Mon, 2018-03-26 at 21:06 +0100, Richard Shann wrote:
> On Mon, 2018-03-26 at 11:53 +0200, Thomas Morley wrote:
> > 2018-03-25 21:13 GMT+02:00 Richard Shann :
> > > I have been using a bit of code written by Mark Witmer to achieve
> > > wavy
> > > 
> [...] someone can suggest a
> > > correct way to handle line breaks with these vibrato markings.
> > Hi,
> > 
> > you may be interested in
> >   
> > http://lilypond.1069038.n5.nabble.com/How-to-make-this-postscript-spa
> > nner-to-work-with-L-amp-R-bound-details-td204375.html#a204622
> 
> That's great. I notice it uses make-path-stencil which is not in
> 2.18,
> in fact I couldn't trace the documentation for it in 2.19 either, it
> seems to be just mentioned in the Changes document
> http://lilypond.org/doc/v2.19/Documentation/changes/index.html
> 
> In case it may be useful to anyone I've attached a 2.18 version which
> also takes a thickness parameter.
> 
> Richard

I've been trying to typeset a file using these wavy lines with LilyPond
22.2 and it throws an obscure error (this is after running convert.ly).

/usr/share/lilypond/2.22.0/scm/output-ps.scm:272:49: In procedure
symbol->string in expression (symbol->string join):
/usr/share/lilypond/2.22.0/scm/output-ps.scm:272:49: Wrong type
argument in position 1 (expecting symbol): (quote round)
Exited with return code 1.

Attached is the vibrato.ily from before with an test example at the
end. I notice that a variable name "round" is used whose name clashes
with a Scheme procedure, but that doesn't seem to be the cause of the
problem. Any ideas?

Richard Shann


\version "2.22.0"

%% 
https://raw.githubusercontent.com/mwitmer/LyUtil/master/ly/expressive_markings/vibrato.ly
%% Original author: Mark Witmer
%% Rewritten version by Harm

#(define (line-part-min-max x1 x2)
  (list (min x1 x2) (max x1 x2)))

#(define (bezier-part-min-max x1 x2 x3 x4)
  ((lambda (x) (list (reduce min 1 x) (reduce max -1 x)))
   (map
(lambda (x)
  (+ (* x1 (expt (- 1 x) 3))
 (+ (* 3 (* x2 (* (expt (- 1 x) 2) x)))
(+ (* 3 (* x3 (* (- 1 x) (expt x 2
   (* x4 (expt x 3))
(if (< (+ (expt x2 2) (+ (expt x3 2) (* x1 x4)))
   (+ (* x1 x3) (+ (* x2 x4) (* x2 x3
(list 0.0 1.0)
(filter
 (lambda (x) (and (>= x 0) (<= x 1)))
 (append
  (list 0.0 1.0)
  (map (lambda (op)
 (if (not (eqv? 0.0
(exact->inexact (- (+ x1 (* 3 x3)) (+ x4 (* 3 
x2))
 ;; Zeros of the bezier curve
 (/ (+ (- x1 (* 2 x2))
   (op x3
   (sqrt (- (+ (expt x2 2)
   (+ (expt x3 2) (* x1 x4)))
(+ (* x1 x3)
   (+ (* x2 x4) (* x2 x3)))
(- (+ x1 (* 3 x3)) (+ x4 (* 3 x2
 ;; Apply L'hopital's rule to get the zeros if 0/0
 (* (op 0 1)
(/ (/ (- x4 x3) 2)
   (sqrt (- (+ (* x2 x2)
   (+ (* x3 x3) (* x1 x4)))
(+ (* x1 x3)
   (+ (* x2 x4) (* x2 x3)
   (list + -
   
#(define (bezier-min-max x1 y1 x2 y2 x3 y3 x4 y4)
  (map (lambda (x)
 (apply bezier-part-min-max x))
   `((,x1 ,x2 ,x3 ,x4) (,y1 ,y2 ,y3 ,y4

#(define (line-min-max x1 y1 x2 y2)
  (map (lambda (x)
 (apply line-part-min-max x))
   `((,x1 ,x2) (,y1 ,y2

#(define (path-min-max origin pointlist)

  ((lambda (x)
 (list
  (reduce min +inf.0 (map caar x))
  (reduce max -inf.0 (map cadar x))
  (reduce min +inf.0 (map caadr x))
  (reduce max -inf.0 (map cadadr x
   (map (lambda (x)
  (if (= (length x) 8)
  (apply bezier-min-max x)
  (apply line-min-max x)))
(map (lambda (x y)
   (append (list (cadr (reverse x)) (car (reverse x))) y))
 (append (list origin)
 (reverse (cdr (reverse pointlist pointlist
 
#(define (make-path-stencil path thickness x-scale y-scale fill)
  "Make a stencil based on the path described by the list @var{path},
with thickness @var{thickness}, and scaled by @var{x-scale} in the X
direction and @var{y-scale} in the Y direction.  @var{fill} is a boolean
argument that specifies if the path should be filled.  Valid path
commands are: moveto rmoveto lineto rlineto curveto rcurveto closepath,
and their standard SVG single letter equivalents: M m L l C c Z z."

  (define (convert-path path origin previous-point)
"Recursive function to standa

Re: Ties on series of tied notes on center line flipping direction (randomly?)

2022-01-09 Thread Richard Shann
On Sun, 2022-01-09 at 12:48 -0500, Kieren MacMillan wrote:
> Hi Richard,
> 
> > I guess this means it is not a well-known feature.
> 
> Not well-known, likely… but sure seems like a bug and not a feature
> to me.  =)
> 
> > Does anyone have an idea if there are guidelines which suggest
> > what choice should be made?
> 
> It is traditional to place ties on whole notes as if they had stems:
> above if the stems would go down, below if the stems would go up. So
> the question here reduces to the question of which side the stems
> would be on [if there were stems]?
> 
> For middle-line notes, there is no strict rule… but there is a
> general consensus that stems shouldn't flip unnecessarily. That means
> in this case, the stems would/should go down, and thus the ties would
> [all] be above.

That makes sense - it would even be possible for Denemo to work around
the, erm, feature but it will be much better to leave it to LilyPond...

Richard


> 
> Hope that helps!
> Kieren.





Re: Ties on series of tied notes on center line flipping direction (randomly?)

2022-01-09 Thread Richard Shann
On Sun, 2022-01-09 at 17:43 +0100, Thomas Morley wrote:
> Am So., 9. Jan. 2022 um 17:16 Uhr schrieb Valentin Petzel <
> valen...@petzel.at>:
> > 
> > Hi Richard,
> > 
> > It is hard to try to understand the problem with just some
> > pictures. Do you
> > have some code you can send us?
> > 
> > Cheers,
> > Valentin
> > 
> > Am Sonntag, 9. Jänner 2022, 13:34:48 CET schrieb Richard Shann:
> > > Hi,
> > > 
> > > Has anyone experienced the direction of ties on a series of tied
> > > notes
> > > on the center line of the staff flipping direction, seemingly at
> > > random?
> > > 
> > > I attach an example, but I haven't been able to cut the file
> > > concerned
> > > down while keeping the effect - if I delete the lyrics for
> > > example the
> > > problem at that point goes away and if I delete bars likewise
> > > (*).
> > > 
> > > I guess this might be related to the question of how LilyPond
> > > decides
> > > the direction for ties on notes on the center line in any case? I
> > > am on
> > > version 2.22 of LilyPond.
> > > 
> > > Richard Shann
> > > 
> > > (*) I should add that as my lyrics are written separately from
> > > the
> > > notes, deleting bars without deleting the corresponding lyrics as
> > > I did
> > > does alter the underlay of the lyrics, so perhaps it is all
> > > lyrics
> > > related...
> 
> Below triggers it:
> 
> \relative b' { b2~ b1*3/8~ b1*1/8 }
> 
> Obviously it depends on spacing/tie-length, see also:
> 
> \relative b' {
>  \cadenzaOn
>   b1~
>   b1~
>   \override NoteColumn.X-offset = #-2
>   b
> }
> 
> No time to investigate further, though.

Thank you for the replies - I guess this means it is not a well-known
feature. Does anyone have an idea if there are guidelines which suggest
what choice should be made?

Richard
 






Ties on series of tied notes on center line flipping direction (randomly?)

2022-01-09 Thread Richard Shann
Hi,

Has anyone experienced the direction of ties on a series of tied notes
on the center line of the staff flipping direction, seemingly at
random?

I attach an example, but I haven't been able to cut the file concerned
down while keeping the effect - if I delete the lyrics for example the
problem at that point goes away and if I delete bars likewise (*).

I guess this might be related to the question of how LilyPond decides
the direction for ties on notes on the center line in any case? I am on
version 2.22 of LilyPond.

Richard Shann

(*) I should add that as my lyrics are written separately from the
notes, deleting bars without deleting the corresponding lyrics as I did
does alter the underlay of the lyrics, so perhaps it is all lyrics
related...


Re: Changing fingers while holding key down

2021-10-21 Thread Richard Shann
On Thu, 2021-10-21 at 08:59 -0700, Knute Snortum wrote:
> Hi everyone,
> 
> In piano music, there's a technique for holding down a key with one
> finger, then switching to another. 

I see that Denemo emits

c \finger \markup \tied-lyric #" 1~2  "

for this...

Richard

>  I know how this looks in music
> notation (see attached) but I don't know how to engrave it with
> LilyPond.  I've searched the docs, the LSR, and the internet for the
> answer, but I don't know any technical term for this (is there one?)
> so the results were less than helpful.
> 
> How is this done in LilyPond?  I'm assuming one uses markup with
> \finger, but I can't find a way to make the "slur" on top of the
> numbers.  (I've seen this notated with the slur under the numbers
> too.)
> 
> --
> Knute Snortum



Re: Using Scheme inside Lilypond

2021-09-05 Thread Richard Shann
On Sat, 2021-09-04 at 22:21 +0200, Jean Abou Samra wrote:
> Le 04/09/2021 à 20:39, Richard Shann a écrit :
> > (I'm trying to write code that will draw a box round A4 or letter
> > paper
> > with just a change of some scaling factors - I can work around it
> > but
> > it's distressing not to understand what is going on).
> 
> Is this the kind of thing you're looking for?
> 
> \version "2.22.1"
> 
> #(define-markup-command (page-box layout props left-padding top-
> padding 
> right-padding bottom-padding)
>     (number? number? number? number?)
>     #:properties ((thickness 0.1))
>     (let* ((paper-width (ly:output-def-lookup layout 'paper-width))
>    (paper-height (ly:output-def-lookup layout 'paper-height))
>    (left-margin (ly:output-def-lookup layout 'left-margin))
>    (top-margin (ly:output-def-lookup layout 'top-margin))
>    (start-x (- left-padding left-margin))
>    (start-y (- (- top-padding top-margin)))
>    (end-x (- paper-width right-padding left-margin))
>    (end-y (- (- paper-height bottom-padding top-margin
>   (ly:stencil-outline
>     (interpret-markup layout props
>   (make-path-markup
>     thickness
>     `((moveto ,start-x ,start-y)
>   (lineto ,start-x ,end-y)
>   (lineto ,end-x ,end-y)
>   (lineto ,end-x ,start-y)
>   (closepath
>     empty-stencil)))
> 
> \paper {
>    #(set-paper-size "a5landscape")
> }
> 
> \markup \combine
>    \override #'(thickness . 0.3) \page-box #2 #2 #3 #1
>    \page-box #3 #3 #4 #2

That's very kind of you - I would have slogged away for a day or two to
generate something not even half as general and elegant. I'll slot that
in...

Richard




Re: Using Scheme inside Lilypond

2021-09-04 Thread Richard Shann
On Sat, 2021-09-04 at 20:44 +0200, David Kastrup wrote:
> Richard Shann  writes:
> 
> > Can someone educate me as to why this works:
> > 
> > \markup \path #0.4 #'((moveto 0 0) (lineto -30 50) (lineto -20 80)
> > (closepath))
> > 
> > but this does not:
> > 
> > \markup \path #0.4 #'((moveto 0 0) (lineto -30 (* 2 25)) (lineto
> > -20 80) (closepath))
> > 
> > The difference being I replace 50 with (* 2 25)
> > 
> > (I'm trying to write code that will draw a box round A4 or letter
> > paper
> > with just a change of some scaling factors - I can work around it
> > but
> > it's distressing not to understand what is going on).
> 
> (* 2 25) is a list with 3 elements, the symbol * and the numbers 2
> and
> 25.  In a list quoted with ' Scheme has no incentive to evaluate an
> expression.  You could use a quasiquote (a backtick instead of a
> tick)
> to gain the capability of using a comma for temporary evaluation of
> one
> expression, namely
> 
> \markup \path #0.4 #`((moveto 0 0) (lineto -30 ,(* 2 25)) (lineto -20
> 80) (closepath))
> 
> Numeric constants like 0 and -30 are self-quoting, so putting ,
> before
> them does not make a difference.

Thank you - and to Aaron too, I knew it must be something like that,
but only tried the , operator forgetting (if I ever knew) about `
Now I'm cooking with gas...
Richard








Using Scheme inside Lilypond

2021-09-04 Thread Richard Shann
Can someone educate me as to why this works:

\markup \path #0.4 #'((moveto 0 0) (lineto -30 50) (lineto -20 80) (closepath))

but this does not:

\markup \path #0.4 #'((moveto 0 0) (lineto -30 (* 2 25)) (lineto -20 80) 
(closepath))

The difference being I replace 50 with (* 2 25)

(I'm trying to write code that will draw a box round A4 or letter paper
with just a change of some scaling factors - I can work around it but
it's distressing not to understand what is going on).

Richard Shann






Re: Workaround for (not-allowed) numbers in variable names?

2021-03-06 Thread Richard Shann
On Fri, 2021-03-05 at 10:15 -0800, Mogens Lemvig Hansen wrote:
> I believe it was David K who made this magic work:
>  
> \version "2.20.0"
>  
> mus.1 = { c d e }
>  
> \score {
>   \new Staff { \mus.1 }
> }
>  

This can be extended to cover the case where a variable has two numbers
associated with it:

8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
\version "2.20.0"
 
Movement.1.Staff.1 = { c d e }
Movement.1.Staff.2 = { c' d' e' }
Movement.2.Staff.1 = { f g a } 
Movement.2.Staff.2 = { f' g' a' } 
\score {
  <<
\new Staff { \Movement.1.Staff.1 }
\new Staff { \Movement.1.Staff.2 }
  >>

}
\score {
  <<
  \new Staff { \Movement.2.Staff.1 }
\new Staff { \Movement.2.Staff.2 }
  >>

}

8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><

(cautionary note: I haven't examined the code or docs on this, but it
seems a dot before and after will do the trick mid-word and a single
dot at end of word)

A decade or so ago I resorted to converting all the numbers to Roman
numerals using a C routine that's knocking around on the interweb...
time I upgraded that.

Richard Shann



> Regards,
> Mogens
>  
> From: Silvain Dupertuis
> Sent: March 5, 2021 10:12
> To: lilypond-user@gnu.org
> Subject: Re: Workaround for (not-allowed) numbers in variable names?
>  
> I also wondered why numbers are not allowed in variables.
> As for me, I used things like A, B, C instead... but it is less
> practical.
>  
> My guess is that it may be linked to the way numbers are used in
> notes and chords to indicate duration, otherwise it would be real
> nice to be able to use digits in variable names...!
>  
> Le 05.03.21 à 17:37, stefano franchi a écrit :
> Here is a question for anyone who may have been using lilypond for
> projects involving text and many, many, short and similar musical
> snippets.
>  
> I am putting together a book that will contain many (very brief) 
> exercises, grouped thematically. I had thought a convenient and
> flexible way to organize the material and keep future maintenance
> under control would be to create top level variables names for the
> main musical categories and sub-categories and then assign each score
> snippet to progressively numbered variable. So I would have, CategA-1 
> = {"code for one exercise"} , CategB-2 = "code for another
> exercise"}, and so on. Clean structure, easy to maintain and
> rearrange, etc.
>  
> Then I discovered that lilypond does not allow numbers in variable
> names :-(
>  
> I'd be willing to bet my use case is not particularly weird---there
> must have been other people encountering the same problem.
>  
> How have you guys managed it?
>  
> Cheers,
>  
> S.
>  
> 
> --
> __
> Stefano Franchi
> 
> stefano.fran...@gmail.com
> https://www.researchgate.net/profile/Stefano_Franchi
>  
> -- 
> Silvain Dupertuis
> Route de Lausanne 335
> 1293 Bellevue (Switzerland)
> tél. +41-(0)22-774.20.67
> portable +41-(0)79-604.87.52
> web: silvain-dupertuis.org
>  



Re: Braces with TabStaff

2021-02-12 Thread Richard Shann
On Fri, 2021-02-12 at 15:37 +0100, David Kastrup wrote:
> Richard Shann  writes:
> 
> > When I try to create a ChoirStaff brace around two staves one of
> > which
> > is a TabStaff I get two braces:
> > 
> > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> > \version "2.20.0"
> > music = { c''1 }
> > 
> > \score { 
> >   <<
> >  \new ChoirStaff <<
> > \new TabStaff = "Part 1"  << 
> >  \music
> > >> 
> > \new Staff
> > << 
> >    \new Voice { 
> > \music
> >   } 
> > >> 
> >  >>
> >   >>
> >    }
> > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> > 
> > If I replace TabStaff with Staff in the above, all is well.
> > Can anyone shed light on this?
> 
> You'll find that this only happens for guitar tablature, not bass
> guitar
> tablature.  Whether a brace is placed or not depends on the height of
> the system/group.
> 
> Try
> 
> \version "2.20.0"
> music = { c''1 }
> 
> \score { 
>   <<
>  \new ChoirStaff \with { \override SystemStartBracket.collapse-height 
> = 8 } <<
> \new TabStaff = "Part 1"  << 
>  \music
> >> 
> \new Staff
> << 
>    \new Voice { 
> \music
>   } 
> >> 
>  >>
>   >>
>    }
> 
> instead.  Yes, this is somewhat insane.

Thank you. I'll try and get the time to see if I can safely emit this
override every time Denemo is creating a ChoirStaff.

Richard Shann







Braces with TabStaff

2021-02-12 Thread Richard Shann
When I try to create a ChoirStaff brace around two staves one of which
is a TabStaff I get two braces:

8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
\version "2.20.0"
music = { c''1 }

\score { 
  <<
 \new ChoirStaff <<
\new TabStaff = "Part 1"  << 
 \music
>> 
\new Staff
<< 
   \new Voice { 
\music
  } 
>> 
 >>
  >>
   }
8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><

If I replace TabStaff with Staff in the above, all is well.
Can anyone shed light on this?

Richard Shann




Re: page-limit-inter-system-space

2021-02-11 Thread Richard Shann
On Tue, 2021-02-09 at 16:47 +, Carl Sorensen wrote:
> 
> On 2/9/21, 8:57 AM, "lilypond-user on behalf of Richard Shann"  pond-user-bounces+carl.d.sorensen=gmail@gnu.org on behalf of rich
> a...@rshann.plus.com> wrote:
> 
> Looking in the second link you gave, where the feature was
> removed, I
> don't see an explanation as to why it was removed: so I wonder if
> there
> is some other way of limiting the system to system spacing so
> that it
> spreads out to fill the page only to a limited extent. I can
> always
> manually insert blank space after the movement, but it would be
> nicer
> not to have to design the amount of space every time it happens -
> indeed nicer not to have to intervene at all.
> 
> The feature was removed because the page-spacing algorithm was
> completely redone.  The new spacing algorithm is more configurable,
> but it is not clear that the default settings are optimal.  It is
> also not clear that users can effectively use the spacing values
> based on the listings in the Notation Reference.  This probably cries
> out for an entry in the Learning Manual about how to use the vertical
> spacing variables.
> 
> Here's a thread that shows some suggestions for changes to the
> default values.  I have not tried them to see how well they work.
> 
> https://lilypond-user.gnu.narkive.com/xebxLJaX/request-for-engraving-
> suggestions

Thanks - I've now tested out setting system-system-
spacing.stretchability and I'm pretty sure most people would find the
default value 

system-system-spacing = #'((basic-distance . 12) (minimum-distance . 8) 
(padding . 1) (stretchability . 60))

which is in paper-defaults-init.ly to be *much* too high (60 => 2 ??).
And I see that the markup to score stretchability also needs to be much
reduced to prevent the titles appearing at the top of the page and the
music much lower.

Thanks again to all who helped.

Richard






Re: page-limit-inter-system-space

2021-02-09 Thread Richard Shann
On Mon, 2021-02-08 at 20:53 +0100, Xavier Scheuer wrote:
> On Mon, 8 Feb 2021 at 19:28, Richard Shann 
> wrote:
> >
> > In a multi-movement piece with each movement starting on a new page
> it
> > happens by default that if one movement is very short it will be
> spread
> > out to fill the page. This can be difficult to read as the systems
> are
> > so far apart. I would like to tell LilyPond to limit the space
> between
> > systems to avoid this (leaving blank space below the movement).
> > I've come across page-limit-inter-system-space but can't find the
> > documentation for it.
> > I've been testing various values in the following code without
> success.
> >
> >
> 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> >
> > \version "2.20.0"
> > music = {\repeat unfold 30 c'' }
> > \paper {
> >          page-limit-inter-system-space = ##t
> >          page-limit-inter-system-space-factor = #0.2
> >        }
> > \score {
> >         \music
> > }
> > \pageBreak
> > \score {
> >         \music     
> > }
> >
> >
> 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> >
> > Can someone suggest how to make these two movements look the same
> on
> > the page?
> 
> Hello,
> 
> I do not find any mention of "page-limit-inter-system-space" in the
> documentation (in fact a search of this term on the whole website
> lilypond.org does not give any results!).
> Where have you heard about it?

It was sitting around as one of the options to set in Denemo, no one
noticed it had stopped working over a decade ago...
> 
> AFAICS in lilypond's code on gitlab this variable was introduced in a
> commit 13 years ago but removed 11 years ago...
> https://gitlab.com/lilypond/lilypond/-/commit/2d817f0288ab1e90fe6258a
> eae34d9466043cdbf
> https://gitlab.com/lilypond/lilypond/-/commit/d062d6527a8a10e32d5a092
> 0a28a3ac029ba14ef
> 
> In your case I would use different \bookpart with different \paper
> containing, or not, ragged(-last)-bottom.

Thank you - and to all the others who pointed to \bookpart, this
answers perfectly the specific question I asked viz. how to make a
short movement not spread out to fill the page.
It does still leave the problem that lead to the introduction of page-
limit-inter-system-space as described in your first link:

"When only a couple of flat systems are placed on a page, the resulting
vertical spacing may be non-eleguant: one system at the top of the page,
and the other at the bottom, with a huge gap between them. To avoid this
situation, the space added between the systems can be limited. This
feature is activated by setting to @code{#t} the
@code{page-limit-inter-system-space} variable in the @code{\paper}
block. The paper variable @code{page-limit-inter-system-space-factor}
determines how much the space can be increased: for instance, the value
@code{1.3} means that the space can be 30% larger than what it would be
on a ragged-bottom page."

This problem remains because it is nicer if the music expands as much
as is reasonable and then leaves blank space, rather than suddenly
retreating up the page when the spacing is becoming unpleasant
resulting in a large blank space at the bottom.

Looking in the second link you gave, where the feature was removed, I
don't see an explanation as to why it was removed: so I wonder if there
is some other way of limiting the system to system spacing so that it
spreads out to fill the page only to a limited extent. I can always
manually insert blank space after the movement, but it would be nicer
not to have to design the amount of space every time it happens -
indeed nicer not to have to intervene at all.

Many thanks for the responses,

Richard




Re: Keeping original system distances

2021-02-08 Thread Richard Shann
On Mon, 2021-02-08 at 01:50 -0800, Calvin Ransom wrote:
> I am attempting to conserve the spacing when combining two scores
> together. I want score one on one page and score two on the next page
> but when I use \pageBreak it changes the spacing of the systems in an
> unwanted way, is there a way for me to prevent this from happening?
> I am using the \include command to combine multiple scores into one
> document,
> Any help would be greatly appreciated.
> 
> Calvin Ransom
> British Columbia

Curiously, I tried to ask what I think is the same question today, but
my email hasn't got to the list.
Here was my question (I'm calling the "two scores" two movements, in
LilyPond each movement in a piece is one \score{} block):

In a multi-movement piece with each movement starting on a new page it
happens by default that if one movement is very short it will be spread
out to fill the page. This can be difficult to read as the systems are
so far apart. I would like to tell LilyPond to limit the space between
systems to avoid this (leaving blank space below the movement).
I've come across page-limit-inter-system-space but can't find the
documentation for it.
I've been testing various values in the following code without success.

8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><

\version "2.20.0"
music = {\repeat unfold 30 c'' }
\paper {
 page-limit-inter-system-space = ##t
 page-limit-inter-system-space-factor = #0.2
   }
\score {
\music 
}
\pageBreak
\score {
\music 
}

8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><

Can someone suggest how to make these two movements look the same on
the page?

Richard Shann



page-limit-inter-system-space

2021-02-08 Thread Richard Shann
In a multi-movement piece with each movement starting on a new page it
happens by default that if one movement is very short it will be spread
out to fill the page. This can be difficult to read as the systems are
so far apart. I would like to tell LilyPond to limit the space between
systems to avoid this (leaving blank space below the movement).
I've come across page-limit-inter-system-space but can't find the
documentation for it.
I've been testing various values in the following code without success.

8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><

\version "2.20.0"
music = {\repeat unfold 30 c'' }
\paper {
 page-limit-inter-system-space = ##t
 page-limit-inter-system-space-factor = #0.2
   }
\score {
\music 
}
\pageBreak
\score {
\music 
}

8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><

Can someone suggest how to make these two movements look the same on
the page?

Richard Shann




Re: \beamExeceptions problem

2021-01-04 Thread Richard Shann
On Sun, 2021-01-03 at 22:34 +0100, Xavier Scheuer wrote:
> On Sun, 3 Jan 2021 at 18:04, Richard Shann 
> wrote:
> >
> > My understanding of the \beamExceptions function in 2.20 was that
> you
> > should be able to pass it a complete bar beamed as you would wish
> and
> > expect other bars with the same beat structure to be beamed to
> match.
> > In this example barOne and barTwo have the same rhythm but only
> barOne
> > is beamed as desired.
> > What have I got wrong?
> 
> Hello Richard,
> 
> I learned this \beamExceptions function thanks to you, thank you.

:)

> If you replace  \beamExceptions \barOne by
> \beamExceptions { 16[ 16] 16[ 32 32] 16[ 16] 16[ 32 32] }
> you get the desired output.
> 
> Not sure what's going on, but when putting only rhythm in the pattern
> (like the example in the documentation) it seems to work.

what's going on is that you added the beam end ] which I had failed to
put there because, as David pointed out, the autobeaming did it for me.
The inclusion of the note names is ok (and very useful if you are
creating your template by copying a bar of music from your score).

Richard Shann






Re: \beamExeceptions problem

2021-01-04 Thread Richard Shann
On Mon, 2021-01-04 at 00:45 +0100, David Kastrup wrote:
> Richard Shann  writes:
> 
> > My understanding of the \beamExceptions function in 2.20 was that
> > you
> > should be able to pass it a complete bar beamed as you would wish
> > and
> > expect other bars with the same beat structure to be beamed to
> > match.
> 
> But you did not pass \beamExceptions a bar beamed as you would wish.
> You passed it a bar with beaming depending on a combination of
> automatic
> beaming and beaming exceptions.

ah, I see, thanks.

> 
> That doesn't work since at the current point of time, beaming
> exceptions
> _only_ affect beam ends.
> 
> > In this example barOne and barTwo have the same rhythm but only
> > barOne
> > is beamed as desired.
> > What have I got wrong?
> > 
> > Richard Shann
> > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> > \version "2.20"
> > 
> > barOne = {g'16 b' b'[( a'32 g']) d'16[ c''16] c''16[( b'32 a'])}
> 
> Beaming for 1/16 notes ends here after c''16] and nowhere
> else.  Beaming
> for 32nd notes ends after g'32]) and a'32]) and nowhere else.  Those
> are
> the beaming exceptions being generated by
> 
> \beamExceptions \barOne
> 
> as you can verify with
> 
> \void \displayScheme \beamExceptions \barOne
> 

I think I'll need to write a script to place manual beams throughout a
movement to match a sample bar, as thinking about it, it would be too
much to expect LilyPond to do this sort of thing.

Richard Shann







\beamExeceptions problem

2021-01-03 Thread Richard Shann
My understanding of the \beamExceptions function in 2.20 was that you
should be able to pass it a complete bar beamed as you would wish and
expect other bars with the same beat structure to be beamed to match.
In this example barOne and barTwo have the same rhythm but only barOne
is beamed as desired.
What have I got wrong?

Richard Shann
8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><
\version "2.20"

barOne = {g'16 b' b'[( a'32 g']) d'16[ c''16] c''16[( b'32 a'])}

barTwo = {g'16 b' b'( a'32 g') d'16 c''16 c''16( b'32 a')}


Music = {
  \barOne
  \barTwo   
}

\score { %Start of Movement
  <<
\new Staff { 
   \time 2/4 \Music
}
  >>

  \layout {
  \overrideTimeSignatureSettings 2/4 1/4 #'(1 1) 
  \beamExceptions \barOne
  }
   }
8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><8><



Re: horizontal position of augmentation dots

2020-12-07 Thread Richard Shann
On Mon, 2020-12-07 at 07:56 -0800, Knute Snortum wrote:
> When you read the documentation for an interface, check the bottom of
> the page for "This object supports the following interface(s):".  In
> this case it's the grob-interface that has the extra-offset property.

Ah, yes, thank you. It's a sort of multiple inheritance thing I
guess...

Richard


> --
> Knute Snortum
> 
> 
> 
> On Sun, Dec 6, 2020 at 8:10 AM Richard Shann  > wrote:
> > On Sun, 2020-12-06 at 16:52 +0100, Pierre Perol-Schneider wrote:
> > > Hi Richard,
> > > How about:
> > > 
> > > \version "2.20.0"
> > > A = {f2~  f8. s16 s4 }
> > > B = {bes,2~  
> > >      \tweak Dots.extra-offset #'(-.8 . 0)
> > >      bes,8. bes,32 a, bes,16 c d e }
> > > 
> > > \score {
> > > \new Staff  << 
> > >  \new Voice   {\voiceOne \clef bass \A }
> > >  \new Voice   {\voiceTwo \B }
> > >             >> 
> > >        }
> > 
> > Thank you! I'm disconcerted that I didn't find this for myself. I
> > got
> > to this page
> > https://lilypond.org/doc/v2.18/Documentation/internals/dots
> > but it didn't seem to lead to extra-offset as a property... I
> > suppose I
> > need to tweak LilyPond so rarely that I get out of practice at
> > finding
> > things in the documentation (this was my first bit of polyphony for
> > ten
> > years!).
> > 
> > Richard
> > 
> > 
> > > 
> > > Cheers,
> > > Pierre
> > > 
> > > Le dim. 6 déc. 2020 à 15:32, Richard Shann  > om>
> > > a écrit :
> > > > I struck me that this score:
> > > > 
> > > > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> > > > \version "2.20.0"
> > > > A = {f2~  f8. s16 s4 }
> > > > B = {bes,2~  bes,8. bes,32 a, bes,16 c d e }
> > > > 
> > > > \score {
> > > > \new Staff  << 
> > > >  \new Voice   {\voiceOne \clef bass \A }
> > > >  \new Voice  {\voiceTwo \B }
> > > > >> 
> > > >    }
> > > > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> > > > 
> > > > has the lower dotted note vertically aligned with the upper one
> > > > (see
> > > > attached pdf). I thought it might be nicer to move the lower
> > dot
> > > > closer
> > > > to its notehead, but I couldn't find out how to do that. With a
> > lot
> > > > of
> > > > things there are properties to tweak but this didn't seem to
> > the
> > > > the
> > > > case for augmentation dots.
> > > > Perhaps someone could steer me in the right direction?
> > > > 
> > > > Richard Shann
> > > > 
> > 
> > 



Re: horizontal position of augmentation dots

2020-12-06 Thread Richard Shann
On Sun, 2020-12-06 at 16:52 +0100, Pierre Perol-Schneider wrote:
> Hi Richard,
> How about:
> 
> \version "2.20.0"
> A = {f2~  f8. s16 s4 }
> B = {bes,2~  
>      \tweak Dots.extra-offset #'(-.8 . 0)
>      bes,8. bes,32 a, bes,16 c d e }
> 
> \score {
> \new Staff  << 
>  \new Voice   {\voiceOne \clef bass \A }
>  \new Voice   {\voiceTwo \B }
>             >> 
>        }

Thank you! I'm disconcerted that I didn't find this for myself. I got
to this page
https://lilypond.org/doc/v2.18/Documentation/internals/dots
but it didn't seem to lead to extra-offset as a property... I suppose I
need to tweak LilyPond so rarely that I get out of practice at finding
things in the documentation (this was my first bit of polyphony for ten
years!).

Richard


> 
> Cheers,
> Pierre
> 
> Le dim. 6 déc. 2020 à 15:32, Richard Shann 
> a écrit :
> > I struck me that this score:
> > 
> > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> > \version "2.20.0"
> > A = {f2~  f8. s16 s4 }
> > B = {bes,2~  bes,8. bes,32 a, bes,16 c d e }
> > 
> > \score {
> > \new Staff  << 
> >  \new Voice   {\voiceOne \clef bass \A }
> >  \new Voice  {\voiceTwo \B }
> > >> 
> >    }
> > 8><8><8><8><8><8><8><8><8><8><8><8><8><8><
> > 
> > has the lower dotted note vertically aligned with the upper one
> > (see
> > attached pdf). I thought it might be nicer to move the lower dot
> > closer
> > to its notehead, but I couldn't find out how to do that. With a lot
> > of
> > things there are properties to tweak but this didn't seem to the
> > the
> > case for augmentation dots.
> > Perhaps someone could steer me in the right direction?
> > 
> > Richard Shann
> > 



horizontal position of augmentation dots

2020-12-06 Thread Richard Shann
I struck me that this score:

8><8><8><8><8><8><8><8><8><8><8><8><8><8><
\version "2.20.0"
A = {f2~  f8. s16 s4 }
B = {bes,2~  bes,8. bes,32 a, bes,16 c d e }

\score {
\new Staff  << 
 \new Voice   {\voiceOne \clef bass \A }
 \new Voice  {\voiceTwo \B }
>> 
   }
8><8><8><8><8><8><8><8><8><8><8><8><8><8><

has the lower dotted note vertically aligned with the upper one (see
attached pdf). I thought it might be nicer to move the lower dot closer
to its notehead, but I couldn't find out how to do that. With a lot of
things there are properties to tweak but this didn't seem to the the
case for augmentation dots.
Perhaps someone could steer me in the right direction?

Richard Shann


Untitled.pdf
Description: Adobe PDF document


Re: LilyPond learning curve (was: feasibilty question: simple GUI for web-based Lilypond instance)

2020-10-25 Thread Richard Shann
On Sun, 2020-10-25 at 18:21 +0100, Martín Rincón Botero wrote:
> I wonder if you realise that you do not have to look at "Denemo's
> GUI"
> - that is, you can set all of the menus, palettes etc hidden and just
> use the pc keyboard and a MIDI keyboard to enter notes, rests etc and
> then press a key to export the LilyPond syntax for the part you just
> entered.
> 
> I didn’t know that. I guess I’ll try that later, although without
> palettes I fail to imagine what the “GUI experience” would be.

I don't know if you would call it a "GUI experience", what you are left
with is an instant display of the notes you have entered (and indeed a
sounding of their pitch) which helps avoid wrong notes, wrong octaves
etc. Well, you get a bit more - you get to see if you've left a bar un-
filled or overstuffed or if your slur isn't terminated, and so on. But
the menus are really only there for you to choose which things you want
to set keyboard shortcuts for. 
Oh, and you can re-shape slurs with the mouse in the PDF that LilyPond
creates...

Richard

> The third factor is that there’s a large class of mistakes that you
> simply could not make in Finale or Sibelius: mismatched braces, beams
> or slurs that you forget to close, notes entered in the wrong octave,
> etc.
> 
> Oh, yes. That’s a huge factor as well. GUIs really do a great job at
> preventing you from making so many mistakes. 
> 
> www.martinrinconbotero.com
> On 25. Oct 2020, 18:02 +0100, Richard Shann 
> , wrote:
> > I wonder if you realise that you do not have to look at "Denemo's
> > GUI"
> > - that is, you can set all of the menus, palettes etc hidden and
> > just
> > use the pc keyboard and a MIDI keyboard to enter notes, rests etc
> > and
> > then press a key to export the LilyPond syntax for the part you
> > just
> > entered.



Re: LilyPond learning curve (was: feasibilty question: simple GUI for web-based Lilypond instance)

2020-10-25 Thread Richard Shann
On Sun, 2020-10-25 at 12:39 -0400, Kieren MacMillan wrote:
> Hi Richard,
> 
> > I've never been sure why someone hasn't shown an interest in doing
> > that...
> 
> How is that better than using the Frescobaldi MIDI input?

Well, I may need educating here, but it seems to be limited to entering
the LilyPond syntax for notes played on a MIDI keyboard, and limited to
all sharps or all flats at that. The note entry system for Denemo
allows you to enter rhythms at the pc keyboard which show up as
pitchless notes in the display and then play notes on the MIDI keyboard
which are assigned to the previously entered rhythms. It's like the
"Step Entry" systems of the GUI programs but you aren't limited to one
rhythmic value at a time, you can enter a whole bar or system or
movement of rhythms and just start playing in the notes on your
keyboard. Generally, entering rhythms can be done rhythmically (e.g.
two key presses for a dotted rhythm, three for a triplet) which helps
keep your place when transcribing.

That's the basic idea, but there are some frills - you can enter slurs
along with the notes without breaking rhythm and you can just play the
MIDI notes if the note values are the same for long stretches. And you
can take advantage of bars with the same rhythmic pattern etc. And for
tonal music you get to choose a range of accidentals that makes sense
and get warned if you play a diminished interval which is usually the
first sign that you have entered e.g. D-sharp for E-flat.

Richard





Re: LilyPond learning curve (was: feasibilty question: simple GUI for web-based Lilypond instance)

2020-10-25 Thread Richard Shann
On Sun, 2020-10-25 at 17:10 +0100, Martín Rincón Botero wrote:
> > I've never been sure why someone hasn't shown an interest in doing
> > that...
> > 
> 
> I myself have to respectfully say that I can't stand looking at
> Denemo's GUI. I haven't been able to keep it installed for more than
> 30 seconds for this reason.

I wonder if you realise that you do not have to look at "Denemo's GUI"
- that is, you can set all of the menus, palettes etc hidden and just
use the pc keyboard and a MIDI keyboard to enter notes, rests etc and
then press a key to export the LilyPond syntax for the part you just
entered. All you see is a (crude) typesetting of the notes as you enter
them, which enables you to keep track of the music you have entered.
In recompense you get a method of entering music in the time it takes
to play it twice (and, of course, if it is slow music, you can play it
in faster than you would perform it).

Richard Shann



  1   2   3   4   5   6   7   >