Re: Getting Lilyjazz fonts back in business

2023-12-04 Thread Jan
Hi Mark,
Indeed, I missed the supplementary files when I manually installed the style. 
This did the trick.
Thanks a lot for your clear and prompt reply.
Jan

> On 4 Dec 2023, at 22:27, Mark Probert  wrote:
> 
> Hi, Jan.
> 
> There are four elements to making lilyjazz work. These are, in script form,
> 
>  sh "cp lilyjazz/otf/* #{lilypond}/#{REV}/fonts/otf"
>  sh "cp lilyjazz/svg/* #{lilypond}/#{REV}/fonts/svg"
>  sh "cp lilyjazz/stylesheet/* #{lilypond}/#{REV}/ly"
>  sh "cp lilyjazz/supplementary-files/**/*.otf #{lilypond}/#{REV}/fonts/otf”
> 
> I would guess you need to copy the supplimentary file otfs. This are for the 
> chords and text
> 
> HTH
> 
> ..mark.
> 
> 
> 
>> On 5 Dec 2023, at 06:29, Jan  wrote:
>> 
>> Dear Lilypond users,
>> I’m trying to use lilyjazz for a jazz lead-sheet, in order to reproduce the 
>> hand-written style. However, the fonts do not show up as they should, cf. 
>> the examples for the lilyjazz style. For example, this is a snipped of the 
>> AllOfMe.pdf example provided at GitHub :
>> 
>> 
>> Compiling the AllOfMe.ly code with lilypond 2.24.3 (after some tweaking to 
>> get rid of a deprecated syntax) leads to the following:
>> 
>> 
>> The notes are correctly reproduced, but the chords and text are using the 
>> default font, at least it seems. I believe that Lilyjazz is properly 
>> installed, the required “ily” styles are found and the fonts are installed 
>> where they should. 
>> Any help would be greatly appreciated.
>> Jan
> 
> 




Re: Video generation from multiple pages

2023-12-04 Thread Stefano Antonelli
On Mon, 2023-12-04 at 14:48 -0600, Karlin High wrote:
> On 12/1/2023 2:21 PM, Stefano Antonelli wrote:
> > trying to modify ly2video to produce a different kind of video
> 
> Have you seen Knut Petersen's MKVIDEO project?

I have, but thanks for the suggestion.  MKVIDEO is not nicely
distributed (no git repo) so I didn't have a good look.

The problem with every lilypond video generation solution I've come
across:

ly2video
lilypond-html-live-score
LilypondToBandVideoConverter [1]
MKVIDEO

and even this unreleased one:

https://www.youtube.com/watch?v=JqwrqhPQIWQ

Is that page transitions are abrupt.  It's hard to follow the music
when the page transitions and you can't read ahead.  For my intended
use, it's not good enough.

I know that ly2video can scroll the music and leave the cursor
stationary, but that's not a good solution to this problem either.

Seeing two lines of music at a time is the right solution for me: the
current line and the next line.  At least on my phone's screen.

Really lilypond-html-live-score is quite impressive.  I like how they
use svg elements instead of png.  If the page would scroll
automatically while the music was playing it would very useful to me.
 At the same time, I would prefer a video to an html page.  It's easy
to slow a video down to learn more difficult parts.

However, ly2video seems to be the only solution that will take a
beatmap file to sync up audio with the notation.  It's called midi-
rubato and this is crucial for the kind of scrolling video scores that
I'm interested in making.

lilypond-html-live-score uses an engraver with /consists like event-
listener.ly. ly2video uses the after-line-breaking callback.

The problem is that the line breaks and page breaks don't have such a
callback.

Having a closer look at mkvideo, it's using after-line-breaking as
well.  But I noticed something interesting:

\paper {
#(define (page-post-process layout pages)
 (after-pb-processing layout pages))
}

earlier, after-pb-processing is defined.  So I copied that definition
with my own alteration:

#(define (after-pb-processing layout pages)
(format #t "\nafter-pb-processing"))

I ran lilypond.  There were no complaints and after-pb-processing did
print at the very end.  Once.  There are two pages though so I expected
to see it twice.

I don't know how I missed page-post-process before.  The documentation
says:

page-post-process (procedure)

If this function is defined (within the \paper block), LilyPond uses it
to post-process pages, for example, to extract the table of contents
and writing the information to an auxiliary file.  The call happens
after page breaking has been performed.

The syntax is
#(define (page-post-process layout pages) ... )

It would seem that page-post-process is called after all the page
breaking is performed.  I need something called when each page break is
performed.

I had a look at where page-post-process was used, in paper-book.cc, but
I didn't see anything else.  By the time it's at 'book' it's probably
too late.  I found page-breaking.cc which looked promising, but there's
no callback defined in there.  And the comments indicate that the page
chunking code is done before any drawing.

I also took a look at LilypondToBandVideoConverter, but it's pretty
complicated.  Ultimately he's using /consists with engravers too.
 Nothing about page breaks.

Unfortunately another dead end, but I appreciate the reply nonetheless
Karlin.

Thanks,
Stef

[1] I haven't seen LilypondToBandVideoConverter mentioned on this list
so I'm not sure many know about it.

Code:


Write up by author:
<
https://www.tensi.eu/thomas/music/produce_like_a_nerd/produce-like-a-nerd_1.html
>

demo from the above write up:
<
https://www.tensi.eu/thomas/music/produce_like_a_nerd/media/plan-wonderful_song.mp4
>


Re: clefs, time signatures, and key signatures

2023-12-04 Thread Werner LEMBERG


> please have a look at Merge Request 2188 and comment there on how to
> proceed with the new distances between clefs and time signatures,
> together with the new distances between clefs and key signatures.
> 
>   https://gitlab.com/lilypond/lilypond/-/merge_requests/2188
> 
> The question is whether the new distances should be based on the
> widest standard clef glyph (which is the alto clef, and which is
> done currently in the MR), or whether they should be based on the
> most common one, the treble clef.

For better comparison, I've updated/added the screenshots in the MR so
that you can do a blink-comparison of the images.


Werner



Re: Getting Lilyjazz fonts back in business

2023-12-04 Thread Mark Probert
Hi, Jan.

There are four elements to making lilyjazz work. These are, in script form,

  sh "cp lilyjazz/otf/* #{lilypond}/#{REV}/fonts/otf"
  sh "cp lilyjazz/svg/* #{lilypond}/#{REV}/fonts/svg"
  sh "cp lilyjazz/stylesheet/* #{lilypond}/#{REV}/ly"
  sh "cp lilyjazz/supplementary-files/**/*.otf #{lilypond}/#{REV}/fonts/otf”

I would guess you need to copy the supplimentary file otfs. This are for the 
chords and text

HTH

 ..mark.



> On 5 Dec 2023, at 06:29, Jan  wrote:
> 
> Dear Lilypond users,
> I’m trying to use lilyjazz for a jazz lead-sheet, in order to reproduce the 
> hand-written style. However, the fonts do not show up as they should, cf. the 
> examples for the lilyjazz style. For example, this is a snipped of the 
> AllOfMe.pdf example provided at GitHub :
> 
> 
> Compiling the AllOfMe.ly code with lilypond 2.24.3 (after some tweaking to 
> get rid of a deprecated syntax) leads to the following:
> 
> 
> The notes are correctly reproduced, but the chords and text are using the 
> default font, at least it seems. I believe that Lilyjazz is properly 
> installed, the required “ily” styles are found and the fonts are installed 
> where they should. 
> Any help would be greatly appreciated.
> Jan





Re: Video generation from multiple pages

2023-12-04 Thread Karlin High

On 12/1/2023 2:21 PM, Stefano Antonelli wrote:

trying to modify ly2video to produce a different kind of video


Have you seen Knut Petersen's MKVIDEO project?







Possibly it would offer some additional inspiration.
--
Karlin High
Missouri, USA




clefs, time signatures, and key signatures

2023-12-04 Thread Werner LEMBERG


Folks,


please have a look at Merge Request 2188 and comment there on how to
proceed with the new distances between clefs and time signatures,
together with the new distances between clefs and key signatures.

  https://gitlab.com/lilypond/lilypond/-/merge_requests/2188

The question is whether the new distances should be based on the
widest standard clef glyph (which is the alto clef, and which is done
currently in the MR), or whether they should be based on the most
common one, the treble clef.


Werner



Re: Video generation from multiple pages

2023-12-04 Thread Stefano Antonelli
On Sat, 2023-12-02 at 22:56 -0800, Stefano Antonelli wrote:

I wanted to mention that for some reason none of this stuff works
unless it appears before the score block.  Both dump-spacetime-info.ly
and event-listener.ly must be included at the top of the file.  If they
are located at the bottom of the file, after the score block, there are
no prints.  In case anyone happens to read this and is bitten by the
same thing.

I looked into the code and there is an after-line-breaking in system.cc

  (void) g->get_property ("after-line-breaking");

This is used in a similar way to other places I see after-line-breaking 
 used, such as haripin.cc.  So I presume this get_property() call has a
side effect of running scheme code (ie. a callback).

That means:

\layout {
  \context {
\Staff
\override System.after-line-breaking = #printPage
  }
}

should work.  And it doesn't.  I tried \Score context, no context, and
even \Voice context.  None of them printed anything.  If I'm missing
something about how this works, I can't see it.



Getting Lilyjazz fonts back in business

2023-12-04 Thread Jan
Dear Lilypond users,
I’m trying to use lilyjazz for a jazz lead-sheet, in order to reproduce the 
hand-written style. However, the fonts do not show up as they should, cf. the 
examples for the lilyjazz style. For example, this is a snipped of the 
AllOfMe.pdf 

 example provided at GitHub :



Compiling the AllOfMe.ly 
 
code with lilypond 2.24.3 (after some tweaking to get rid of a deprecated 
syntax) leads to the following:



The notes are correctly reproduced, but the chords and text are using the 
default font, at least it seems. I believe that Lilyjazz is properly installed, 
the required “ily” styles are found and the fonts are installed where they 
should. 
Any help would be greatly appreciated.
Jan

Re: spacing puzzle

2023-12-04 Thread Kieren MacMillan
Hi David,

Have you looked at all the spacing parameters?
https://lilypond.org/doc/v2.23/Documentation/notation/flexible-vertical-spacing-paper-variables#list-of-flexible-vertical-spacing-paper-variables

In particular:
top-system-spacing
the distance from the top of the printable area (i.e., the bottom of the top 
margin) to the first system on a page, when there is no (title or top-level) 
markup between the two.

Hope that helps!
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.




spacing puzzle

2023-12-04 Thread bobr...@centrum.is
I have a situation where I have too much music for one page and not enough to 
fill two pages.  My desired solution is to split the material roughly 50/50 
between two facing pages.  Each page would be filled approximately 1/3 but I 
want that 1/3 centered top to bottom.  I can achieve that by tweaking the 
margin sizes but that pushes the page number down the page as well.  I want the 
page numbers up near the corners.  Isn't there a way to "push" a score down the 
page like this?  I need it to happen on the other page as well.

Thanks,

David



Re: Centering a word before a gap in the lyrics

2023-12-04 Thread Michael Werner
Hi Paul,

On Mon, Dec 4, 2023 at 6:56 AM Paul Hodges  wrote:

> I don't know where in the documentation the difference in behaviour
> between \skip1 and "" as opposed to _ is explained.
>

It isn't much of an explanation, but in
http://lilypond.org/doc/v2.25/Documentation/notation/lyrics-and-repeats#index-_005cskip-1
is the line Note: do not use an underscore, _, to skip notes – an
underscore indicates a melisma, causing the preceding syllable to be
left-aligned.
A bit terse, to be sure. But mentioning an alignment issue I've always
stayed with using \skip to skip over a note, and only used _ when it really
was a melisma not explicitly notated in the music (such as a tie or a slur).

But the opportunity is missed on these pages, the first of which actually
> conflates the "" and _ notation:
>
>
> https://lilypond.org/doc/v2.25/Documentation/snippets/rhythms_003a-skips-in-lyric-mode-_00282_0029
>
> https://lilypond.org/doc/v2.25/Documentation/snippets/rhythms_003a-skips-in-lyric-mode
>

This was the first time I'd seen the use of "" for something like this.
I'll have to keep it in mind. And looking at those two snippet pages you
linked they make it seem like all three options are equivalent. Yet in the
NR page I linked it says they are different.

Well, I guess the important bit is you found something that does what you
need, and does it in a way that you're okay with.
-- 
Michael


Re: Centering a word before a gap in the lyrics

2023-12-04 Thread Paul Hodges
I don't know where in the documentation the difference in behaviour between 
\skip1 and "" as opposed to _ is explained.  But the opportunity is missed on 
these pages, the first of which actually conflates the "" and _ notation:


https://lilypond.org/doc/v2.25/Documentation/snippets/rhythms_003a-skips-in-lyric-mode-_00282_0029
https://lilypond.org/doc/v2.25/Documentation/snippets/rhythms_003a-skips-in-lyric-mode


Paul

Re: Centering a word before a gap in the lyrics

2023-12-04 Thread Paul Hodges




Sure. Just use a skip. Like so:

And now I discover that "" will do the same - which makes it doubly curious 
that " " does not.  "" is a lot more elegant than \skip1 as well!



 


Paul

Re: Centering a word before a gap in the lyrics

2023-12-04 Thread Paul Hodges
I should have tried that again; but I've tried it in the past and it hasn't 
seemed to work.  There must be some other subtlety involved; scores converted 
from Music XML use \skip1 for melismas...  I guess I haven't fully internalised 
the various options for lyric placement.


Thanks,
Paul




 From:   Michael Werner  
 To:   Paul Hodges  
 Cc:
 Sent:   04/12/2023 9:10 
 Subject:   Re: Centering a word before a gap in the lyrics 



Hi Paul, 


On Mon, Dec 4, 2023 at 3:52 AM Paul Hodges  wrote:


In the middle lyric, the first word is justified because the following skip (_ 
in this case) defines a melisma.  But I actually simply want there to be no 
immediately following word - this arises with multiple verses and alternatives 
in the repeat structure, for example.  I thought a quoted space would count as 
a word, but no...



In the end I have done it above by a rather unnatural circumlocution, but is 
there a more natural solution which I've missed?


Sure. Just use a skip. Like so:



 

Re: Centering a word before a gap in the lyrics

2023-12-04 Thread Michael Werner
Hi Paul,

On Mon, Dec 4, 2023 at 3:52 AM Paul Hodges  wrote:

> In the middle lyric, the first word is justified because the following
> skip (_ in this case) defines a melisma.  But I actually simply want there
> to be no immediately following word - this arises with multiple verses and
> alternatives in the repeat structure, for example.  I thought a quoted
> space would count as a word, but no...
>

> In the end I have done it above by a rather unnatural circumlocution, but
> is there a more natural solution which I've missed?
>

Sure. Just use a skip. Like so:

\version "2.25.10"

wordsA = \lyricmode { centred centred centred }
wordsB = \lyricmode { centered \skip 1 centred }

\score {
  \new Staff <<
\new Voice = "vvv" { r2 c'2 g'2 c''2 }
\new Lyrics \lyricsto "vvv" \wordsA
\new Lyrics \lyricsto "vvv" \wordsB
  >>
}


[image: image.png]

One thing to keep in mind - \skip when used in lyrics goes by notes, not
beats. So \skip 1 will skip one note, not an entire 4 beats. If you want to
skip multiple notes in one go (such as dealing with alternate endings with
multiple verses) something like:
\repeat unfold 15 { \skip 1}
comes in handy. A bit more on using \skip can be seen here:
http://lilypond.org/doc/v2.25/Documentation/notation/lyrics-and-repeats#index-_005cskip-1
and here:
http://lilypond.org/doc/v2.25/Documentation/notation/invisible-rests#index-_005cskip
-- 
Michael


Centering a word before a gap in the lyrics

2023-12-04 Thread Paul Hodges

Consider the following:


%%%
\version "2.25.10"
wordsA = \lyricmode { centred centred centred }
wordsB = \lyricmode { justified _ centred } 
wordsC = \lyricmode { justified " " centred } 
wordsC = \lyricmode { centred \once \override Lyrics.LyricText.color = #white 
"." centred } 
\score {
  \new Staff <<
    \new Voice = "vvv" { r2 c'2 g'2 c''2 }
    \new Lyrics \lyricsto "vvv" \wordsA
    \new Lyrics \lyricsto "vvv" \wordsB
    \new Lyrics \lyricsto "vvv" \wordsC
    \new Lyrics \lyricsto "vvv" \wordsD
  >>
%%%


In the middle lyric, the first word is justified because the following skip (_ 
in this case) defines a melisma.  But I actually simply want there to be no 
immediately following word - this arises with multiple verses and alternatives 
in the repeat structure, for example.  I thought a quoted space would count as 
a word, but no...


In the end I have done it above by a rather unnatural circumlocution, but is 
there a more natural solution which I've missed?


Paul