Re: fisisis impossible?

2018-03-12 Thread Marc Hohl
Am 12.03.2018 1:50 nachm. schrieb Torsten Hämmerle <torsten.haemme...@web.de>:Marc Hohl wrote

> This is on the issue tracker:

> 

> https://sourceforge.net/p/testlilyissues/issues/3356/



Thank you, Marc,



This 2013 issue (like this thread, too) may be related mainly to \chordmode,No. If LilyPond has no internal representation of triple signs, neither notes nor chords will work at all.

but generally, it'd be nice to have triple flats/sharps in LilyPond.

I've started working on the case.
That's cool!Regards, Marc


All the best,

Torsten







--

Sent from: http://lilypond.1069038.n5.nabble.com/User-f3.html



___

lilypond-user mailing list

lilypond-user@gnu.org

https://lists.gnu.org/mailman/listinfo/lilypond-user


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: fisisis impossible?

2018-03-11 Thread Marc Hohl

Am 10.03.2018 um 21:20 schrieb bart deruyter:

Hi all,

got in a situation, trying to describe the bis augmented chord in second 
inversion, which would contain fisisis in a slashed chord name.


Lilypond returns an error, unexpected symbol, expecting tonicname pitch, 
which makes me believe that lilypond does not know triple sharps (isisis).


Am I right? Are there solutions for this?


This is on the issue tracker:

https://sourceforge.net/p/testlilyissues/issues/3356/

Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Three simultaneous slurs

2018-02-21 Thread Marc Hohl
Oh sorry, it looks lie a tie between b-flat and b-flat, but the handwritten note heads could also be interpreted differently :)Am 21.02.2018 12:34 nachm. schrieb Andrew Bernard :Hi Marc,Actually not a tie. If it were, the next note would not have an accidental. It's a slur for vocal music. Sorry I did not explain the full context.Thanks.Andrew
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Three simultaneous slurs

2018-02-21 Thread Marc Hohl
The smallest "slur" in the picture is a tie, isn't it?The next bigger slur can be typeset directly, and the outmost slur is a PhrasingSlur IMHO.HTH, MarcAm 21.02.2018 11:56 vorm. schrieb Andrew Bernard :Referring to the attached image from the MS I am engraving, I have three simultaneous slurs going on.How can this be handled in lilypond 2.19.81 (or indeed any version)?Do I have to use a fake simultaneous voice to fudge the result?Andrew
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: endless tab?

2018-02-05 Thread Marc Hohl



Case 1: I set an arbitrary bar (the manual calls it "bar check")


Because it is a *check*, not a bar line!

You insert bars by \bar "|" or \bar "|." or whatever, no by the bar 
*check* symbol alone, that's quite a difference.


Just my 2 ct,

Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: tie polyphony

2018-01-24 Thread Marc Hohl

Am 24.01.2018 um 09:31 schrieb Gianmaria Lari:

Hello,

In the following code

\version "2.19.80"
\fixed c' {
   r4 a b d'
   << {4 4 4 4} \\ c1 >>
}

... I would like to tie the "a" with the very first chord 4. How 
I can do it?


That's not a tie then.

IIUC, you'll need a phrasing slur for this: \(  \)

HTH,

Marc


Thank you, Gianmaria


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: reloading \set TabStaff.minimumFret = #x

2018-01-24 Thread Marc Hohl

Am 23.01.2018 um 15:26 schrieb bb:
Is it possible to omit \set TabStaff.minimumFret = #x for a sequence of 
measures/bars?


One can simply override the statement by defining a string for a note.

I have a couple of bars in sequence that should be fingered below that 
minimumFret. The fingering of the tones of the following bars should 
again resdtricted above some value. I like to avoid defining the strings 
for a long sequence of notes.



\unset TabStaff.minimumFret

should do the trick

HTH,

Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: [OT] Linux Users

2017-11-19 Thread Marc Hohl

Am 18.11.2017 um 17:58 schrieb Jacques Peron:
Linux, LilyPond, LuaLaTeX (and Gregorio for gregorian chant) here. To 
integrate LilyPond into LaTeX, I developped lyluatex 
.


Which is a great tool and IMHO easier to use than lilypond-book!

Linux, LilyPond, LuaLaTeX/XeLaTeX here.

Marc


​

2017-11-18 17:24 GMT+01:00 David Bellows >:


I use Linux, Lilypond, LuaLaTeX, and Csound, editing all of it in
emacs. This does seem like a pretty potent or at least popular
combination.

On Sat, Nov 18, 2017 at 8:18 AM, Sam Bivens > wrote:
 > I'm also a Linux user. For notation I use LilyPond (with Frescobaldi)
 > exclusively, and for any serious writing I use LaTeX.
 >
 > Although I use the lilyglyphs package in LaTeX, I've never gotten
around to
 > using lilypond-book; instead I just autocrop my Lily PDFs and
insert those
 > as floats.
 >
 > A quick question for others: I've used LilyPond a couple times on
Mac, and
 > the compile times were horrendous. Are the compile times on Linux
faster
 > than on other operating systems? (Unfortunately I can't remember
what Mac OS
 > I used...)
 >
 > Sam
 >
 > ___
 > lilypond-user mailing list
 > lilypond-user@gnu.org 
 > https://lists.gnu.org/mailman/listinfo/lilypond-user

 >

___
lilypond-user mailing list
lilypond-user@gnu.org 
https://lists.gnu.org/mailman/listinfo/lilypond-user





___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Invisible note lines?

2017-10-27 Thread Marc Hohl

Am 27.10.2017 um 18:25 schrieb bb:

I interpret this to have to comment out one of the two \score blocks for
printing and the other for to get the midi? or do I miss the point?


No, you just put two score blocks in your .ly file.
If one score block contains a \midi block and *no* layout block, there 
is no graphical output.


See

http://lilypond.org/doc/v2.18/Documentation/notation/creating-midi-files

for clarification.

HTH,

Marc



Regards BB

Am 27.10.2017 um 18:07 schrieb Marc Hohl:

Am 27.10.2017 um 18:04 schrieb bb:

For a backing track I want a melody line and chords printed on a lead
sheet - standard with lilypond.
But a midi should have an aditional kickdrum/bassdrum for rhythm. The
notes should not be visible on the lead sheet but to hear in the midi.
Is it possible to add notes for midi but invisible on the print?

Certainly I can assemble one lilypond file for the lead sheet and
another one for the midi. But that is not really smart. It is not
comfortable to have to change two lilypond files for corrections etc.


You only need to include two \score commands in one lilypond file:

\score {
   ... stuff to be printed ...
}

\score {
... same stuff without kick ...
    \midi { }
}

HTH,

Marc


Regards BB




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Invisible note lines?

2017-10-27 Thread Marc Hohl

Am 27.10.2017 um 18:04 schrieb bb:

For a backing track I want a melody line and chords printed on a lead
sheet - standard with lilypond.
But a midi should have an aditional kickdrum/bassdrum for rhythm. The
notes should not be visible on the lead sheet but to hear in the midi.
Is it possible to add notes for midi but invisible on the print?

Certainly I can assemble one lilypond file for the lead sheet and
another one for the midi. But that is not really smart. It is not
comfortable to have to change two lilypond files for corrections etc.


You only need to include two \score commands in one lilypond file:

\score {
  ... stuff to be printed ...
}

\score {
... same stuff without kick ...
   \midi { }
}

HTH,

Marc


Regards BB




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: \justify & break

2017-10-05 Thread Marc Hohl
I misread the mail, this is nonsense.Sorry for the noise.Am 05.10.2017 9:50 vorm. schrieb Marc Hohl <m...@hohlart.de>:Am 05.10.2017 9:32 vorm. schrieb Gianmaria Lari <gianmarialari@gmail.com>:On 5 October 2017 at 09:28, Thomas Morley <thomasmorley65@gmail.com> wrote:2017-10-05 6:56 GMT+02:00 Gianmaria Lari <gianmarialari@gmail.com>:
> On 5 October 2017 at 01:05, Thomas Morley <thomasmorley65@gmail.com> wrote:
>>
>> 2017-10-04 17:53 GMT+02:00 Gianmaria Lari <gianmarialari@gmail.com>:
>> > On 4 October 2017 at 17:15, Malte Meyn <lilypond@maltemeyn.de> wrote:
>> >> Am 04.10.2017 um 17:11 schrieb Gianmaria Lari:
>> >>>
>> >>> Is there any \break like command to avoid to use two \justify?
>> >>
>> >>
>> >> Use \justify-string instead. Empty lines make line breaks:
>> >
>> > [...]
>> >
>> > Yes, I saw \justify-string and it works but I wonder if it existed
>> > something
>> > more natural, like a \break or a command with the lilypond syntax
>> > (and
>> > not scheme syntax with #).
>> >
>> > The reason I'm so picky it's because I'm thinking to the day when I will
>> > suggest lilypond as engraving program to other persons. I will not
>> > propose
>> > it to programmers and would like to avoid (each time is possible) to use
>> > special syntax that I have to explain etc. etc.
>> >
>> > Thank you, g.
>>
>> Well, you could do:
>>
>> \markup {
>>   \column {
>>     \line  \bold \smallCaps { Note }
>>     \justify-string
>>     #"L'articolazione d'elezione per lo staccato è quella del braccio, o
>> nel
>>     caso di parti rapide, del polso. \n
>>     Nello staccato, braccio, mano e dita sono un tutt'uno ed agiscono in
>> modo
>>     compatto senza scomporsi e senza articolazioni intermedie."
>>   }
>> }
>>
>> Ofcourse \n _is_ scheme-syntax ;)
>
>
> Uhmm... in that case I prefer to use two consecutive \justify. But \n is
> good to know. I will keep it in my arsenal :)

Keep in mind: \n is valid input only as part of strings.

> By the way why \justify-string use the scheme syntax and it is not a first
> class citizen of lilypond language?
> Thank you, g.

Not sure what you mean. I don't know what a "first class citizen of
lilypond language" might be.Why \justify-string use the scheme-syntax and not the lilypond syntax?You need scheme when using \n, otherwise an empty line works fine for separating paragraphs in \justify-string, no scheme needed.Marcg.
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: \justify & break

2017-10-05 Thread Marc Hohl
Am 05.10.2017 9:32 vorm. schrieb Gianmaria Lari :On 5 October 2017 at 09:28, Thomas Morley  wrote:2017-10-05 6:56 GMT+02:00 Gianmaria Lari :
> On 5 October 2017 at 01:05, Thomas Morley  wrote:
>>
>> 2017-10-04 17:53 GMT+02:00 Gianmaria Lari :
>> > On 4 October 2017 at 17:15, Malte Meyn  wrote:
>> >> Am 04.10.2017 um 17:11 schrieb Gianmaria Lari:
>> >>>
>> >>> Is there any \break like command to avoid to use two \justify?
>> >>
>> >>
>> >> Use \justify-string instead. Empty lines make line breaks:
>> >
>> > [...]
>> >
>> > Yes, I saw \justify-string and it works but I wonder if it existed
>> > something
>> > more natural, like a \break or a command with the lilypond syntax
>> > (and
>> > not scheme syntax with #).
>> >
>> > The reason I'm so picky it's because I'm thinking to the day when I will
>> > suggest lilypond as engraving program to other persons. I will not
>> > propose
>> > it to programmers and would like to avoid (each time is possible) to use
>> > special syntax that I have to explain etc. etc.
>> >
>> > Thank you, g.
>>
>> Well, you could do:
>>
>> \markup {
>>   \column {
>>     \line  \bold \smallCaps { Note }
>>     \justify-string
>>     #"L'articolazione d'elezione per lo staccato è quella del braccio, o
>> nel
>>     caso di parti rapide, del polso. \n
>>     Nello staccato, braccio, mano e dita sono un tutt'uno ed agiscono in
>> modo
>>     compatto senza scomporsi e senza articolazioni intermedie."
>>   }
>> }
>>
>> Ofcourse \n _is_ scheme-syntax ;)
>
>
> Uhmm... in that case I prefer to use two consecutive \justify. But \n is
> good to know. I will keep it in my arsenal :)

Keep in mind: \n is valid input only as part of strings.

> By the way why \justify-string use the scheme syntax and it is not a first
> class citizen of lilypond language?
> Thank you, g.

Not sure what you mean. I don't know what a "first class citizen of
lilypond language" might be.Why \justify-string use the scheme-syntax and not the lilypond syntax?You need scheme when using \n, otherwise an empty line works fine for separating paragraphs in \justify-string, no scheme needed.Marcg.
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: How can I make a 7.9+.9- chord?

2017-09-28 Thread Marc Hohl

Am 28.09.2017 um 18:31 schrieb gumblex:
[...]And how can I display this chord correctly in a

ChordNames line?


This is untested, but IIRC

\once\override ChordName.text = \markup { ... }

should work.


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: How can I make a 7.9+.9- chord?

2017-09-28 Thread Marc Hohl

Am 28.09.2017 um 18:31 schrieb gumblex:

Dear list,

I would like to write a "dis:7.9+.9-" chord in \chordmode. However, both
in ChordNames lines and in scores, it appears to be a "dis:7.9-" chord.
If I write "dis:7.9-.9+", it appears to be a "dis:7.9+" chord.


This is a current restriction of LilyPond's chord handling abilities.
You cannot use two alterations of the same interval.

Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Header

2017-09-26 Thread Marc Hohl

Am 25.09.2017 um 20:37 schrieb Mario Moles:

Hi lilyponders!

How to make like in tha jpg?


Please provide us some more informations. The jpg looks like a LaTeX 
document, so the commands used there do not apply for LilyPond.


Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Draw line between fingerings, but how does this go?

2017-09-26 Thread Marc Hohl

Hello Pieter,

I used the code in this thread:

http://lilypond.1069038.n5.nabble.com/glissando-in-fingering-notation-td159875.html

This works out of the box for almost all occurrences in my scores.

HTH,

Marc


Am 25.09.2017 um 22:49 schrieb Pieter Terpstra:

Dear readers,
Trying to draw a line between the numbers, copied some code but don't know 
exactly what the commands do.
Trying to raise the line so that it fits nicely between the ones but don't know 
how, have tried the \raise command
here without success.

Anyone?

Thank you so much in advantage!

\score {
   \relative c' { \time 2/4 \key d \minor
   168168
   }
}




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: restrain string numbers

2017-09-22 Thread Marc Hohl
Am 22.09.2017 4:51 nachm. schrieb bb :I want to restrain/omit string numbers in the score. But I need them to

define because of the guitar tabs. How can I do that?
\new Staff \with { \omit StringNumber } { ... your music }HTHMarc___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Fwd: coloring notes according harmonic function

2017-09-08 Thread Marc Hohl

Am 07.09.2017 um 21:20 schrieb Rita Composer:

Dear David and other Experts,

Unfortunately I couldn't really follow you.


You have to use


<<
  \new Voice { \voiceOne ... }
  \new Voice { \voiceTwo ... }
  \new Voice { \voiceThree ... }
>>

The curly brackets { ... } are important, otherwise the first \new Voice 
ends directly after \voiceOne, and ... is treated as if \voiceOne was 
never set.


HTH a bit,

Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Remove all occurrencies of "0" fingerings

2017-08-15 Thread Marc Hohl

Am 15.08.2017 um 10:15 schrieb David Kastrup:

Marc Hohl <m...@hohlart.de> writes:
[...]

For the record: First, I used the solution with grob-transformer, but
then I found out that removing the grob completely yields to problems
with glissando lines between fingerings, so I switched to the solution
given above.


Your description did not imply that you actually wanted to use that
point for positioning purposes.  However, I think glissandi are between
noteheads rather than fingerings.  It's conceivable that they try taking
fingerings into account in some manner: in that case, it would make
sense if they ignored empty stencils.


Yes, of course. I wasn't aware of the implications either – putting
glissando lines between fingerings is quite straightforward, but I had
to use glissandoMap and some trickery to create a satisfactory result.

My current project includes a book with a violin and a guitar staff, and
an additional handout for guitar-only purposes with tablature added. My
focus was primarily on the first part, which has to be finished in terms
of the layout as soon as possible for the illustrator to start to draw
the pictures to be added later. Therefore I missed the glissando line
suddenly pointing to nowhere in the tablature part.

Interestingly, I didn't see the spurious line on screen, but in a 
printoutthat I am currently using for practicing the guitar part that 
will be

recorded in a couple of days. I don't know whether others have made
similar experiences, but on screen nearly everything seems to look
correct.


At any rate, it is sort of amusing that your choice between two complex
solutions hinges on whether they use point-stencil or empty-stencil
internally: interchanging those two is not all that hard.  At least
Thomas documented his solution better.


Well, IIRC you were the first who mentioned the recursion error (which I
should have found myself – silly me).  But I have to admit that Harm's
solution works with scheme functions I understood at first glance,
whereas the grob-transformer stuff was not that easy for me to cope
with.

Conclusion: the list is great, and the fact that there are multiple
solutions to a problem makes it easier to find the most suitable
workaround ;-)

Regards,

Marc





___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Remove all occurrencies of "0" fingerings

2017-08-15 Thread Marc Hohl

Am 08.08.2017 um 12:35 schrieb Thomas Morley:

2017-08-08 11:46 GMT+02:00 Marc Hohl <m...@hohlart.de>:

[...]

Hi Marc,

your initial code had two problems, comments inline:

\override Fingering.stencil =
   #(lambda (grob)
  (let* ((text (ly:grob-property grob 'text))
 (stencil (if (equal? text "0")
  ;; to avoid the warning go for point-stencil
  ;; not empty-stencil
  point-stencil
  ;; return a stencil yourself, don't call the
  ;; property which is created by the stencil-prop
  ;; it's a cycle and I'm somewhat surprised it failed
  ;; not more spectaculary
  (ly:text-interface::print grob
stencil))



For the record: First, I used the solution with grob-transformer, but
then I found out that removing the grob completely yields to problems
with glissando lines between fingerings, so I switched to the solution
given above.

Thanks a lot!

Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Remove all occurrencies of "0" fingerings

2017-08-09 Thread Marc Hohl

Am 08.08.2017 um 18:44 schrieb David Kastrup:

Marc Hohl <m...@hohlart.de> writes:


Am 08.08.2017 um 13:00 schrieb Thomas Morley:

2017-08-08 12:47 GMT+02:00 David Kastrup <d...@gnu.org>:



You can do this by using

[...]

Nice one. I always forget about 'grob-transformer'. Missing bracket, tho'


I wasn't aware of grob-transformer at all. And I am still unsure about
what it does. I have read the doc string, though.


It gives your function both the grob and the value (callbacks and
unpure/pure containers already resolved) that _would_ get calculated
without your override in place.

That can be handy when your function just wants to modify the default,
or if the default is only used sometimes.  To use it, you don't need to
know whether the default is a constant, a function, or an unpure/pure
container.


I see. Thanks for your explanation!

Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Remove all occurrencies of "0" fingerings

2017-08-08 Thread Marc Hohl

Am 08.08.2017 um 13:00 schrieb Thomas Morley:

2017-08-08 12:47 GMT+02:00 David Kastrup :



You can do this by using

[...]

Nice one. I always forget about 'grob-transformer'. Missing bracket, tho'


I wasn't aware of grob-transformer at all. And I am still unsure about 
what it does. I have read the doc string, though.


Thanks,

Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Remove all occurrencies of "0" fingerings

2017-08-08 Thread Marc Hohl

Am 08.08.2017 um 12:47 schrieb David Kastrup:

Marc Hohl <m...@hohlart.de> writes:


I wanted to write a little callback to remove all occurrencies
of "0" fingerings. This is what I got so far:


\version "2.19.63"

music = {
   c'4-3 d'-0 e'-2 f'-3 | g'1-0
}

\score {
   \new Staff \with {
 \override Fingering.stencil =

^^^

   #(lambda (grob)

[...]

  (ly:grob-property grob 'stencil

^^


Compiling this nearly MWE, I get:

Warning: Fingering has empty extent and non-empty stencil.
Warning: Fingering has empty extent and non-empty stencil.

And *no* fingering at all is shown in the resulting score.
What am I doing wrong?


Recursion: see Recursion.


Ah, yes!

I think I intermingled the idea to use Fingering.after-line-breaking 
(where stencil is already defined) and Fingering.stencil (to remove the 
stencil before any layout decisions are completed).


Thanks for clarification!

Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Remove all occurrencies of "0" fingerings

2017-08-08 Thread Marc Hohl

Hi Malte,

Am 08.08.2017 um 10:30 schrieb Malte Meyn:



Am 08.08.2017 um 10:23 schrieb Marc Hohl:


I wanted to write a little callback to remove all occurrencies
of "0" fingerings.


This doesn’t empty the stencil but removes the Fingering grobs 
completely (by suicide):


thanks for this solution!

In my real-life example, I got

lilypond: ../flower/include/drul-array.hh:35: T& 
Drul_array::at(Direction) [with T = scm_unused_struct*]: Zusicherung 
>>d == 1 || d == -1<< nicht erf?llt.

Aborted (core dumped)

but changing before-line-breaking to after-line-breaking did the trick.

I do not fully understand why, but it works.

Thanks,

Marc


 \override Fingering.before-line-breaking =
 #(lambda (grob)
(if (equal? (ly:grob-property grob 'text) "0")
(ly:grob-suicide! grob)))

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Remove all occurrencies of "0" fingerings

2017-08-08 Thread Marc Hohl

Hello list!

I wanted to write a little callback to remove all occurrencies
of "0" fingerings. This is what I got so far:


\version "2.19.63"

music = {
  c'4-3 d'-0 e'-2 f'-3 | g'1-0
}

\score {
  \new Staff \with {
\override Fingering.stencil =
  #(lambda (grob)
 (let* ((text (ly:grob-property grob 'text))
(stencil (if (equal? text "0")
 empty-stencil
 (ly:grob-property grob 'stencil
   stencil)) }
  { \music }
}


Compiling this nearly MWE, I get:

Warning: Fingering has empty extent and non-empty stencil.
Warning: Fingering has empty extent and non-empty stencil.

And *no* fingering at all is shown in the resulting score.
What am I doing wrong?

Regards,

Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Adding an introductory note(s)

2017-08-01 Thread Marc Hohl

Am 31.07.2017 um 17:27 schrieb Stephen Nesbitt:

[...]
2)  The inability to have more than one instance of partial. Fiddle 
tunes are often notated with pickups for the A & B sections.


AFAIK, it is allowed to put a \partial in mid-piece since 2.19.11.

HTH,

Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Include file handling in lilypond-book

2017-07-12 Thread Marc Hohl

Am 12.07.2017 um 01:54 schrieb Karljurgen Feuerherm:

Hello,

Putting together an exercise book using XeLaTeX and the lilypond 
environment. Everything works relatively well until I try to use an 
include file with variable definitions.


MWE:

 % !TEX encoding = UTF-8 Unicode

 % !TEX TS-program = LilyPond-Book

 % !LILYPOND tex = xelatex

 \documentclass{memoir}

% \newcommand{\Ggrace}{\grace { g''32 }}

 \begin{document}

 \begin{lilypond}

 {

   \include "lilypond-variables.ly"


I don't know if I remember correctly, but I think I stumbled upon this 
problem before.

Have you tried to include a relative path?

\include "./lilypond-variables.ly"

  ^^

HTH,

Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: String Number collision

2017-07-06 Thread Marc Hohl

Hi Harm,

Am 05.07.2017 um 23:21 schrieb Thomas Morley:

Hi Marc,

2017-07-05 8:13 GMT+02:00 Marc Hohl <m...@hohlart.de>:

Hi list,

I have the following MWE:

[...]

It causes the string number "5" to appear twice, strangely overlapping.
I tried to move the New_fingering_engraver to Staff, but then I got

side-axis not set for grob StringNumber.


Not sure what you expected, I didn't explore the programming error, though.


Well, I hoped that lilypond discardes one of two identical string-number 
events automatically.



I assume that I have to create an engraver similar to the
Merge_rests_engraver that does this job? Or is there another way apart from

\once\hide StringNumber

all the way across the file?




You could do:

#(define (suicide-duplicate-text-grobs grob-lst)
"Walks through the sorted @var{grob-lst}, suiciding grobs with duplicate text"
   (if (null? (cdr grob-lst))
   #f
   (suicide-duplicate-text-grobs
 (if (string=? (ly:grob-property (car grob-lst) 'text)
   (ly:grob-property (cadr grob-lst) 'text))
 (begin
   (ly:grob-suicide! (car grob-lst))
   (cdr grob-lst))
 (cdr grob-lst)

#(define reduce-string-numbers
   (lambda (grob)
"Gets the PaperColumn-grob, filters for StringNumber-grobs, sorts this grobs
with @code{stringlist (ly:grob-object paper-column 'elements
(sorted-strgs
  (sort
strgs
(lambda (p q)
  (string8 ~ e''2. }

down = { <c'\5  g'\4> ~ c'2. }

\score {
   <<
   \new Staff
   <<
  \new Voice \with { \deleteDuplicateStrings } { \voiceOne \up }
  \new Voice  { \voiceTwo \down }
   >>
   \new TabStaff
   <<
  \new TabVoice { \voiceOne \up }
  \new TabVoice  { \voiceTwo \down }
   >>
   >>
}


Though, I think an engraver would probably do the job cheaper. (Not tested)


Okay, thanks a lot for your solution! I'll check how it fits in my project.

Regards,

Marc




HTH,
   Harm




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


String Number collision

2017-07-05 Thread Marc Hohl

Hi list,

I have the following MWE:

\version "2.19.60"

up = { c'8\5 e'' ~ 2. }

down = { c'4\5 ~ 2. }

%{ uncomment this to trigger error
\layout {
  \context {
\Voice
\remove "New_fingering_engraver"
  }
  \context {
\Staff
\consists "New_fingering_engraver"
  }
}
%}

\score {
  \new Staff <<
 \new Voice { \voiceOne \up }
 \new Voice { \voiceTwo \down }
  >>
}

It causes the string number "5" to appear twice, strangely overlapping.
I tried to move the New_fingering_engraver to Staff, but then I got

side-axis not set for grob StringNumber.
up = { c'8
  \5 e'' ~ 2. }

I assume that I have to create an engraver similar to the 
Merge_rests_engraver that does this job? Or is there another way apart from


\once\hide StringNumber

all the way across the file?

Note: I have to specify the sting in both voices since I use tablature 
too (ommitted in the MWE) and removing the string specification would 
yield in a erroneous tablature.


Best regards,

Marc
\version "2.19.60"

up = { c'8\5 e'' ~ 2. }

down = { c'4\5 ~ 2. }

%{ uncomment this to trigger error
\layout {
  \context {
\Voice
\remove "New_fingering_engraver"
  }
  \context {
\Staff
\consists "New_fingering_engraver"
  }
}
%}

\score {
  \new Staff <<
 \new Voice { \voiceOne \up }
 \new Voice { \voiceTwo \down }
  >>
}
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: How to make vertical arrow between staves

2017-06-14 Thread Marc Hohl

Am 14.06.2017 um 12:34 schrieb Rutger Hofman:

Good morning list,


[...]

Does

http://lsr.di.unimi.it/LSR/Item?id=962

what you want?

Marc


Rutger Hofman
Amsterdam


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: opus conflict

2017-05-01 Thread Marc Hohl

Am 01.05.2017 um 09:55 schrieb Trevor Daniels:


Thomas Morley wrote Monday, May 01, 2017 12:05 AM



2017-04-30 23:09 GMT+02:00 Mark Stephen Mrotek :

[...] I have very limited knowledge as to how to customize (write Lilypond), 
[...]


So here a little tutorial about writing custom book/scoreTitleMarkup


Nicely done, Harm!


+1

I really, really appreciate your detailed explanations and your time and 
effort that go into mails like these!


Marc



Trevor


---
This email has been checked for viruses by AVG.
http://www.avg.com
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: flip clef, key and time signature [Re: flip clef at end of line only]

2017-04-17 Thread Marc Hohl

Am 17.04.2017 um 13:47 schrieb Thomas Morley:

2017-04-17 13:35 GMT+02:00 Marc Hohl <m...@hohlart.de>:

Hi Harm,




(ly:grob-set-property! grob 'space-alist
  '((staff-bar extra-space . 1))



Ah, that's the way to go here – thanks a lot for your brilliant solution!

Can you explain why you use before-line-breaking? Does it make any
difference to after-line-breaking?


Well, I tried to affect _one_ grob with _one_ override.

The stencil-override could be done directly or before-line-breaking or
after-line-breaking.
The 'space-alist needs to be set directly (with a _separate_ override)
or 'before-line-breaking, it doesn't work sufficiently
'after-line-breaking.


I see, thanks for clarification!

Cheers,

Marc


Best,
  Harm




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: flip clef, key and time signature [Re: flip clef at end of line only]

2017-04-17 Thread Marc Hohl

Hi Harm,

Am 16.04.2017 um 21:25 schrieb Thomas Morley:

2017-04-16 17:54 GMT+02:00 Marc Hohl <m...@hohlart.de>:

[...]

I tried to go one step further and include the key signature and time
signature in my example, see the attached code.

[...]


Hi Marc,

how about below?


[...]

(ly:grob-set-property! grob 'space-alist
  '((staff-bar extra-space . 1))


Ah, that's the way to go here – thanks a lot for your brilliant solution!

Can you explain why you use before-line-breaking? Does it make any 
difference to after-line-breaking?


[...]


For the BarNumbers you'll likely need an engraver ...


I'll probably omit the BarNumbers completely, the piece I want to 
typeset is not very long – it's quite tedious and challenging to compose 
this way ;-)


Thanks,

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


flip clef, key and time signature [Re: flip clef at end of line only]

2017-04-16 Thread Marc Hohl

Am 15.04.2017 um 18:02 schrieb Malte Meyn:



Am 15.04.2017 um 17:32 schrieb Marc Hohl:

Hi list,

I am working on a little piece that's played as written; after
that, the musician has to turn the page upside down and play the
resulting notes.

I managed to get the clef displayed at the beginning and the end of
each line, and I can flip the clef ;-)

Unfortunately, overriding the Clef.stencil at the end of the line
changes the apperance for the clef in the next line, too.


You need before-line-breaking here so you can use the function
ly:item-break-dir:


\override Clef.before-line-breaking = #(lambda (grob) (if (equal?
(ly:item-break-dir grob) LEFT) (ly:grob-set-property! grob 'stencil
(lambda (grobb) (grob-interpret-markup grobb #{ \markup \translate
#'(0 . 2) \flip \musicglyph #"clefs.G" #})


I tried to go one step further and include the key signature and time
signature in my example, see the attached code.

It works and looks quite ok (the spacing between the flipped sharp and
the 3/4 is a little too wide), but I get a lot of errors:

Programmierfehler: No spacing entry from Item to `clef'
Fortsetzung, die Daumen drücken

and one line like this:

Programmierfehler: No spacing entry from TimeSignature to `key-signature'
Fortsetzung, die Daumen drücken

I searched in the sources and assume that I have to enhance the
space-alist entries in the concerning grobs, but I do not have a clue
about the first error message, so any help is highly apprechiated.

Happy Easter!

Marc

\version "2.19.0"

#(define-markup-command (flip layout props arg)
(markup?) 
   (interpret-markup layout props
 (markup #:concat (#:null #:scale (cons -1 -1) #:line (arg)

global = {
  \time 3/4
  \key g \major
  \repeat unfold 4 { 
s2. * 4 | \break
  }
  \time 3/4
}

melody = { 
  \repeat unfold 16 { c'4 4 4 }
}

\layout {
  \context {
\Score
\override BreakAlignment.break-align-orders =
##((left-edge ambitus breathing-sign time-signature
   key-cancellation key-signature clef staff-bar custos)
  
(left-edge ambitus breathing-sign clef key-cancellation
key-signature staff-bar time-signature custos)
  
(left-edge ambitus breathing-sign clef key-cancellation
key-signature staff-bar time-signature custos))
  }

  \context {
\Staff
explicitKeySignatureVisibility = ##(#t #f #t)
explicitClefVisibility = ##(#t #f #t)

\override Clef.break-visibility = ##(#t #f #t)
\override KeySignature.break-visibility = ##(#t #f #t)

\override Clef.after-line-breaking =
#(lambda (grob)
   (if (equal? (ly:item-break-dir grob) LEFT)
   (ly:grob-set-property! grob 'stencil
 (lambda (grobb)
   (grob-interpret-markup grobb
 #{ \markup \translate #'(0 . 2) \flip \musicglyph #"clefs.G" #})
 
\override KeySignature.after-line-breaking =
#(lambda (grob)
   (if (equal? (ly:item-break-dir grob) LEFT)
   (ly:grob-set-property! grob 'stencil
  (lambda (grobb)
   (ly:stencil-translate-axis
 (ly:key-signature-interface::print grobb) -4 Y)
 

\override TimeSignature.after-line-breaking =
#(lambda (grob)
   (if (equal? (ly:item-break-dir grob) LEFT)
   (ly:grob-set-property! grob 'stencil
 (lambda (grobb)
   (ly:stencil-scale
(ly:time-signature::print grobb) -1 -1)
  }
}


\score {
  \new Staff << \global \melody >>
}
  


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: flip clef at end of line only

2017-04-15 Thread Marc Hohl

Am 15.04.2017 um 18:02 schrieb Malte Meyn:



Am 15.04.2017 um 17:32 schrieb Marc Hohl:

Hi list,

I am working on a little piece that's played as written;
after that, the musician has to turn the page upside down and play the
resulting notes.

I managed to get the clef displayed at the beginning and the end of each
line, and I can flip the clef ;-)

Unfortunately, overriding the Clef.stencil at the end of the line
changes the apperance for the clef in the next line, too.


You need before-line-breaking here so you can use the function
ly:item-break-dir:


\override Clef.before-line-breaking =
#(lambda (grob)
   (if (equal? (ly:item-break-dir grob) LEFT)
   (ly:grob-set-property! grob 'stencil
 (lambda (grobb)
   (grob-interpret-markup grobb
 #{ \markup \translate #'(0 . 2) \flip \musicglyph
#"clefs.G" #})


Thanks a lot! Just for clarification: after-line-breaking seems to work 
here, too – is there a special reason to use before-line-breaking?




I added the translate in the markup to bring the clef to the correct
vertical position.


Yep – I removed it for MWE reasons :)

Cheers,

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: flip clef at end of line only

2017-04-15 Thread Marc Hohl

Am 15.04.2017 um 18:11 schrieb Son_V:



Hi list,



I am working on a little piece that's played as written;
after that, the musician has to turn the page upside down and play the
resulting notes.


I'm sorry, I'm just adding noise, but the thing you're working on seems
interesting for me.
I remember that JS Bach made some work of this kind, some palindromes too.


There is Mozarts "Der Spiegel", where two players play simultaneously, 
one reads the sheet in the right way, the other one upside down.


I can point you to a work (nothing to do with music) by Gustave Veerbek:

http://2.bp.blogspot.com/-ytAqPVXoRDM/UIXIEydfLKI/HwA/tnbOsi1iI4o/s1600/UD%2BI.bmp


Wow, that's interesting!


Have an happy Easter.


Happy Easter to you, too!

Cheers,

Marc




--
View this message in context: 
http://lilypond.1069038.n5.nabble.com/flip-clef-at-end-of-line-only-tp202312p202314.html
Sent from the User mailing list archive at Nabble.com.

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


flip clef at end of line only

2017-04-15 Thread Marc Hohl

Hi list,

I am working on a little piece that's played as written;
after that, the musician has to turn the page upside down and play the
resulting notes.

I managed to get the clef displayed at the beginning and the end of each 
line, and I can flip the clef ;-)


Unfortunately, overriding the Clef.stencil at the end of the line 
changes the apperance for the clef in the next line, too.


---

\version "2.19.0"

#(define-markup-command (flip layout props arg)
(markup?)
   (interpret-markup layout props
 (markup #:concat (#:null #:scale (cons -1 -1) #:line (arg)

global = {
  \repeat unfold 4 {
s1 * 4 |
\once\override Staff.BarLine.allow-span-bar = ##t
\once\override Staff.Clef.stencil = #(lambda (grob)
  (grob-interpret-markup grob #{ \markup\flip\musicglyph 
#"clefs.G" #}))

\break
}
}

melody = {
  \repeat unfold 16 { c'4 4 4 4 }
}

\layout {
  \context {
\Staff
explicitKeySignatureVisibility = ##(#t #f #t)
explicitClefVisibility = ##(#t #f #t)

\override Clef.break-visibility = ##(#t #f #t)
\override KeySignature.break-visibility = ##(#t #f #t)
  }
}

\score {
  \new Staff << \global \melody >>
}

---


Is there an easy way to detect whether the clef is actually at the end 
of a line, so that I can write (in pseudo-code)


if (at-end-of-line)
   rotate the clef
else
   print the clef
fi

Thanks in advance,


Marc
\version "2.19.0"

#(define-markup-command (flip layout props arg)
(markup?) 
   (interpret-markup layout props
 (markup #:concat (#:null #:scale (cons -1 -1) #:line (arg)

global = {
  \repeat unfold 4 { 
s1 * 4 |
\once\override Staff.BarLine.allow-span-bar = ##t
\once\override Staff.Clef.stencil = #(lambda (grob) 
  (grob-interpret-markup grob #{ \markup\flip\musicglyph #"clefs.G" #}))
\break
}
}

melody = { 
  \repeat unfold 16 { c'4 4 4 4 }
}

\layout {
  \context {
\Staff
explicitKeySignatureVisibility = ##(#t #f #t)
explicitClefVisibility = ##(#t #f #t)

\override Clef.break-visibility = ##(#t #f #t)
\override KeySignature.break-visibility = ##(#t #f #t)
  }
}

\score {
  \new Staff << \global \melody >>
}
  


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: How to read a error message?

2017-03-14 Thread Marc Hohl

Am 14.03.2017 um 08:49 schrieb Scoutladen - Ralph Fröhlich:

Hi,

hope to find some informations here about reading error messages

Example:

Processing `.../file.ly'
Parsing...
.../file.ly:16:30: error: unrecognized string, not in text script or
\lyricmode
  fis8 fis fis fis d d d4 g (
 h) h h8 h8
.../file.ly:16:33: error: unrecognized string, not in text script or
\lyricmode
  fis8 fis fis fis d d d4 g (h)
h h8 h8

Where can I find a short description?


I cannot answer this in general, but this looks like using german note 
names without declaring it first.


Do you have

\language "deutsch"

stated in your input file?

HTH,

Marc



Best regards
Ralph





___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Ties across voices

2016-12-13 Thread Marc Hohl

Am 13.12.2016 um 11:11 schrieb Peter Toye:

Urs, Andrew, Simon

Thank you all very much for the solutions. I now have 4 ways to create
what I need!

My next task - to get ties across enharmonics, which I gather is
impossible and I have to use slurs.


There is a regtest for this, so it looks as if lilypond accepts ties 
between enharmonic notes at least since 2.19.16.


\version "2.19.16"

\header { texidoc = "
LilyPond should accept a tie between notes which are
enharmonically identical.
" }

\score
{
  {
\time 3/4
\repeat unfold 3 {
  cis'4~ des'
}
  }
  \layout { ragged-right = ##t }
  %\midi {}
}


HTH,

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: InstrumentName on right side

2016-10-20 Thread Marc Hohl

Hi Harm,

I cannot help with the instrument name problem, but ...


Anyway, to give an imprssion a pdf is attached.


This is impressive!

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: BendSpanner-engraver

2016-10-20 Thread Marc Hohl

Am 13.09.2016 um 22:41 schrieb Thomas Morley:
[...]

2016-09-13 8:33 GMT+02:00 Marc Hohl <m...@hohlart.de>:



I hope to find the source somewhere to provide you a scan of how it should
look like.


Would be great.



I finally found some examples, but the bend arrows are not quite 
"convincing" ...



Marc
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Help required with tuplets

2016-10-19 Thread Marc Hohl

Am 19.10.2016 um 08:14 schrieb Bernhard Kleine:

Hi,

I do not see what is wrong with the following extract which is
compilable but totally wrong.


I think you misunderstood the way \tuplet works:

\tuplet 3/2 is the way to go, because you want *3* notes to last as long 
as *2* notes normally do.


HTH,

Marc



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Trouble Combining Repeats and Closing Bars in tunes

2016-10-17 Thread Marc Hohl

Am 18.10.2016 um 05:24 schrieb Ben Beeson:

Hi,

I am looking at a 4 - part tune where the first and third parts are
repeated and the second and fourth parts are not repeated. Try as I
may, I cannot get Lilypond to put  the repeats and closing bars in
the right place when engraving the tune. The following is just about
as simple as I can get it and still show the issue.


If you use \repeat volta 2 { ... }
and then put a \bar "..." command afterwards, this bar command overrides
the repeat bar line – so in fact, the line is repeated internally for
lilypond, but you can't see it.

In this case, you'll have to define your own repeat bar line at the
beginning of your document:

#(define-bar-line ":|.-.|" ":|." ".|" "|.")

and use it like this:

\repeat volta 2 { ... }

\bar ":|.-.|"   \bar "|."


The way lilypond deals internally with repeats versus explicitly given
barlines is not optimal yet :-(

HTH,

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: BendSpanner-engraver

2016-10-04 Thread Marc Hohl

Am 04.10.2016 um 10:58 schrieb David Kastrup:

Thomas Morley  writes:


warning: no notes to start a bend from found. If you want to bend
an open string, consider override/tweak like: TabNoteHead.bend-me = ##t


Hm, this text needs fixing, per current default open strings can't
serve as start _or_ end of a bend.


What about bending from behind the nut?  And of course, on a number of
electric guitars you have the infamous whammy bar...


That's true, but I think that it is a sensible default setting to 
exclude open strins *if* there are ways to enable that feature.


Marc






___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Start of the first row of a staff

2016-09-21 Thread Marc Hohl

Am 21.09.2016 um 08:19 schrieb Marco Bagolin:

Hello all,
please, I need a help because I don't find a solution in the snippet
repository.
I need that the first line of the staff is aligned as subsequent lines,
NOT as the attached example.


Does

\paper {
  indent = 0
}

Do what you mean? Or am I misunderstanding your request?

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: BendSpanner-engraver

2016-09-18 Thread Marc Hohl

Hi Harm,

Am 18.09.2016 um 12:38 schrieb Thomas Morley:

Hi Marc,

2016-09-13 22:41 GMT+02:00 Thomas Morley <thomasmorle...@gmail.com>:

2016-09-13 8:33 GMT+02:00 Marc Hohl <m...@hohlart.de>:



The dashed line would also be great in cases like those:

c'\3\startBend d'\3\stopBend~ d'\3 % bend up, no release, bent
note is tied

c'\3\startBend d'\3\stopBend~ d'\3~ d'\3\startBend c'\3\stopBend
% bend up, bent note is tied, release


Looks doable, I'll probably try the upcoming weekend.


Done.


Great!



Want the changed/extended code to play around with it?


I am a bit short of time at the moment, fiddling around with some
details of my latest theater project ... and starting teaching soon as
well ...


I'd prefer to solve that slow down first, otoh it's little effort to
do a new tarball.


If the estimated work on the slowdown is not that huge, I think it is ok
to get a grip on that first and release a new version afterwards.

Cheers,

Marc


Cheers, Harm




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: BendSpanner-engraver

2016-09-17 Thread Marc Hohl

Hi Harm,

Am 14.09.2016 um 23:00 schrieb Thomas Morley:
[...]

In general I'd vote for those shortcuts, but to fall back to the
basic commands if needed.


I had some time to re-think my basic approach ... maybe you are right
and I think way too complicated in terms of taking each string into
account. Working with different TabVoices is probably easier in most cases.





Some years ago I had long discussions on the devel list concerning
the implementation of a string-bend-engraver (that would have had
to be done in C++ at this time), especially with Carl Sorensen, and
we came to the conclusion that a bend event is something that
happens *to a certain string*, therefore it is possible to bend a
string, keep it bent, bend another one, release it and then release
the first bent string again.

This is rather complicated stuff, but some guitarists do stuff of
this kind ;-)


I partly disagree, you can bend a single string or an EventChord
(speaking lilypondish), meaning all strings are bended starting at
the same musical moment ending at another but same musical moment for
all strings. This is supported already.


Ok, this was probably a misunderstanding: I can either bend one string
or many strings at once, but you can manipulate the strings
independently ... as you proved with your concept of using distinct
TabVoices, this works already.

[...]


So I may be wrong, scans of printed TabStaffs would help me a lot.


still searching ... ;-)


Additionally, I'm not sure, whether we _should_ make every style
available, though. My limited inside lets me think every tab-editor
creates his own style ad hoc and on the fly...


Well, my concerns were not about styles, but about usability.
You convinced me that going for different TabVoices is the way to go!

[...]


The result: they never bothered to learn reading notes. :((


Yes, that's true.


Ofcourse you know, tabs _do_have disadvantages: choosing other
strings for fingerings require a _new_ tab , polyphonics are always
difficult to print. To mention the most prominent ones...


Therefore I go for a combination of normal Staves and TabStaff, and I am
responsible for the current behaviour of the TabStaff: numbers only, no
stems and stuff ;-)


Cheers,

Marc





___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: calculation of the total duration of a score

2016-09-16 Thread Marc Hohl

Hi Jan-Peter,

Am 16.09.2016 um 08:40 schrieb Jan-Peter Voigt:

Hi Marc,

nice to hear, that you have a workflow. For the record I noted two
things in the file. (And if there's some spare time, I might further
work on it.)


Thanks for the continuing work on that issue!



1. The durations are tagged by score and stored in an a-list, so you
can first collect durations in multiple scores and display them later
with a score-unique tag.


The tagging works fine, but as soon as I have a layout block in the
\score creating the exact midi file, lilypond prints it :-(

Moving the callback from \layout {} to \midi {} yields to

Programming error: Cannot find key `scoreBACH' in alist, setting to `0'.

So I still have to use my solution with the auxiliary files, which is no
problem at all.

> 2. There are acknowledgers for volta-brackets and barlines. It should
> be possible to use that information for acknowledging volta repeats
> and ajusting the duration accordingly. Those grobs are created by
> engravers, but if one creates the barlines *not* with \repeat volta,
> but with \bar ".|:", it should be acknowledged too.

This sounds promising, but IMHO it would be easier to get the engraver 
to work somehow on a \score with a \midi { } block only and transferring 
the duration to another \score.



Cheers,

Marc







Cheers Jan-Peter


Am 15.09.2016 um 08:10 schrieb Marc Hohl:

Am 14.09.2016 um 14:24 schrieb Marc Hohl: [...]

I thought of writing the duration to a external file to be read
from within the markup call in the score to be printed, but did
not follow this route any further yet.


Update: a simple test file shows that this works.

I can

- compute the total duration of a file designed for midi output
only by means of your engraver - write the duration to a file and -
read that string while processing the "print-only" file.

Merging that stuff together with some Makefile should be
straightforward, I hope ;-)

And it has the advantage that some MIDI-related changes do not
appear in the printed score, but the duration will be updated
accordingly.

Cheers,

Marc


___ lilypond-user
mailing list lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___ lilypond-user mailing
list lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: calculation of the total duration of a score

2016-09-15 Thread Marc Hohl

Am 14.09.2016 um 14:24 schrieb Marc Hohl:
[...]

I thought of writing the duration to a external file to be read from
within the markup call in the score to be printed, but did not follow
this route any further yet.


Update: a simple test file shows that this works.

I can

- compute the total duration of a file designed for
  midi output only by means of your engraver
- write the duration to a file and
- read that string while processing the "print-only" file.

Merging that stuff together with some Makefile should be 
straightforward, I hope ;-)


And it has the advantage that some MIDI-related changes do not appear in 
the printed score, but the duration will be updated accordingly.


Cheers,

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: BendSpanner-engraver

2016-09-14 Thread Marc Hohl

Hi Harm,

Am 13.09.2016 um 22:41 schrieb Thomas Morley:
[...]

Even if I wouldn't want to take one I'm forced to: my regular job
started after summer-break :((


For me, too :( And -as ever– the TODO list for doing stuff within the 
summer break is still not completely done.

[...]

The customization features are great! Also, I like the dashed line of the
pre-pend-hold use cases.

[...]


Looks doable, I'll probably try the upcoming weekend.#


Great!




[...]


Well, we can't expect a user to find his way to this coding, maybe
some predefined function, will do it!?


I hope to find the source somewhere to provide you a scan of how it should
look like.


Would be great.


Still searching ...




---

Another idea/thought/proposal: IIUC, the engraver does not take the string
numbers into account. I think this would be a good feature from a user's
point of view:

c'\startBend d'\stopBend\startBend c'\stopBend

could then probably be simplified to

c'\3\startBend d'\3 c'\3\stopBend


You may have noticed the file bend-music-functions.ly being remarkable short.
Coding shortcuts and appending them to the bend-music-functions-file
is on the TODO

Something at the lines of:

[...]

This is a very first shot, more a proof-of-concept...


This is possible, but I don't think that shortcuts are sufficient here.

Some years ago I had long discussions on the devel list concerning the 
implementation of a string-bend-engraver (that would have had to be done 
in C++ at this time), especially with Carl Sorensen, and we came to the 
conclusion that a bend event is something that happens *to a certain 
string*, therefore it is possible to bend a string, keep it bent, bend 
another one, release it and then release the first bent string again.


This is rather complicated stuff, but some guitarists do stuff of this 
kind ;-)


[...]

I considered it already.
Though, the engraver mimics the behaviour of TextSpanner.
And you can't start a TextSpanner inside EventChord.

I didn't figure how to do it different.


We discussed about that as well ;-) I tried to follow the slur engraver, 
but this is one of the more complicated engravers, so I finally gave up ;-)


Technically speaking, the mimics of the slur engraver seem ideal if you 
see it as a per-string basis: you cannot have two simultaneous bends on 
one string, but you can bend each string independently.



I have a suspicion about the slow down...
Will test as soon as I have some spare time, though it's a highly
complex and huge coding.
Sometimes I feel like touching the limits of my current coding skills.
Proceeding means to do all very carefully and thoroughly and _not_ in
any hurry ;)


Of course! As already said, I was working on the concept of a 
string-bend-engraver for about 1 1/2 years or so, and the ideas and 
concepts are still (mostly) available. I'd be glad to help you with this 
task, but some private messages in German language could be perhaps more 
effective here ... ;-)



[...]


Although, guitar-player myself I never use TabStaff
rofl


My pupils are fond of tablatures, easy available, easy to understand ...
And trying to write down a contemporary guitar solo with normal staves 
only is a bit of a nightmare ;-)


Cheers,

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: calculation of the total duration of a score

2016-09-14 Thread Marc Hohl

Hi Jan-Peter,

Am 14.09.2016 um 13:18 schrieb Jan-Peter Voigt:

Hi Marc,

I am busy today, so I will look into your example later.


No problem!


In short: Repeats are not taken into account right now.


Yes. Therefore I used the \unfoldRepeats/\midi-combination, but the
duration computed in one \score is not visible in the other one.

I thought of writing the duration to a external file to be read from
within the markup call in the score to be printed, but did not follow
this route any further yet.


I thought of a factor, that is set, when a repeat starts. But I don't
know yet, how to deal with alternatives and repeats with more than
two loops. Probably the engraver might look for barlines. Still it
needs to recognize alternatives with its possible repetitions (e.g.
1-3).


I don't know whether it is doable to implement the stuff that
\unfoldRepeats does within the engraver. Detecting the beginning and the
end of a repeated section should not be that hard, but the bookkeeping
is probably tricky in terms of alternatives, as you pointed out.


We'll crack that nut :-)


Sounds probising, thank you very much!

Marc


Jan-Peter

Am 14. September 2016 12:03:43 MESZ, schrieb Marc Hohl
<m...@hohlart.de>:

Hi Jan-Peter,

ok, so I played around with your engraver. It does exactly what it
needs to do, but somehow I am not able to get everything to work.

I'll try to explain:

Let's say that I have some music:

music = { ...stuff... \repeat volta 2 { ... more stuff ... } }

and want it displayed nicely:

\score { \new Staff { \music } }

If I include your engraver here, the calculated time is wrong,
because the repeats are not taken into account.

So I go for the midi-block

\score { \new Staff { \unfoldRepeats \music } \midi { \context {
\Score \consists ...your code here ... } } }


But it looks like the duration variable is visible within its score
only, see the attached compilable example.

How can I obtain the correct duration in combination with a compact
score?

Thanks in advance,

Marc Am 13.09.2016 um 10:24 schrieb Jan-Peter Voigt:

Hi Marc,

you already received some solutions, but I stumbled across this
thread and just want to quickly show my engraver - perhaps it also
helps.

It doesn't read repeats right now, but this may be solved with
\unfoldRepeats and the engraver placed in the midi-block. The
duration-markup-command relies on a global variable and a delayed
stencil - this will not work with multiple scores, as only the
duration of the last score will be displayed. But that is manageable,
if needed.

HTH Jan-Peter

Am 05.09.2016 um 11:01 schrieb Marc Hohl:

Hi list,

I have a couple of songs in my latest theatre project. It would be
nice to have something like "duration: 3'22''" at the end of each
song.

Doing this by hand is straightforward:I generate a midi file that
sounds accurate and let it play by timidity – but IMHO it would be
less tedious and less error-prone if lilypond were capable of doing
these calculations itself.

Tempo indications and meter changes have to be taken into account,
so this is probably doable with a special engraver only IIUC.

Has someone else already done something like this? I have no
experience in writing scheme engravers, so any hint would be highly
appreciated.

Thanks in advance,

Marc



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






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





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


-- Diese Nachricht wurde von meinem Android-Mobiltelefon mit K-9
Mail gesendet.



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: calculation of the total duration of a score

2016-09-14 Thread Marc Hohl

Hi Jan-Peter,

ok, so I played around with your engraver. It does exactly what it needs 
to do, but somehow I am not able to get everything to work.


I'll try to explain:

Let's say that I have some music:

music = {
 ...stuff...
 \repeat volta 2 { ... more stuff ... }
}

and want it displayed nicely:

\score {
  \new Staff { \music }
}

If I include your engraver here, the calculated time is wrong, because 
the repeats are not taken into account.


So I go for the midi-block

\score {
  \new Staff { \unfoldRepeats \music }
  \midi {
 \context {
\Score
\consists ...your code here ...
 }
   }
}


But it looks like the duration variable is visible within its score 
only, see the attached compilable example.


How can I obtain the correct duration in combination with a compact score?

Thanks in advance,

Marc
Am 13.09.2016 um 10:24 schrieb Jan-Peter Voigt:

Hi Marc,

you already received some solutions, but I stumbled across this thread
and just want to quickly show my engraver - perhaps it also helps.

It doesn't read repeats right now, but this may be solved with
\unfoldRepeats and the engraver placed in the midi-block.
The duration-markup-command relies on a global variable and a delayed
stencil - this will not work with multiple scores, as only the duration
of the last score will be displayed. But that is manageable, if needed.

HTH
Jan-Peter

Am 05.09.2016 um 11:01 schrieb Marc Hohl:

Hi list,

I have a couple of songs in my latest theatre project. It would be nice
to have something like "duration: 3'22''" at the end of each song.

Doing this by hand is straightforward:I generate a midi file that sounds
accurate and let it play by timidity – but IMHO it would be less tedious
and less error-prone if lilypond were capable of doing these
calculations itself.

Tempo indications and meter changes have to be taken into account, so
this is probably doable with a special engraver only IIUC.

Has someone else already done something like this? I have no experience
in writing scheme engravers, so any hint would be highly appreciated.

Thanks in advance,

Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user



\version "2.19.47"

%%% engraver definitions

% format seconds as min:sec
#(define-public (format-time dur)
   (let* ((minutes (floor (/ dur 60)))
  (seconds (round (- dur (* 60 minutes)) ) ))
 (format "~2'0d:~2'0d" (inexact->exact minutes) (inexact->exact seconds))
 ))

% complete duration of score - set after finalizing
duration = 0

% markup command to display complete time
#(define-markup-command (duration layout props)()
   (let* ((gauge-stencil (interpret-markup layout props "00:00"))
  (x-ext (ly:stencil-extent gauge-stencil X))
  (y-ext (ly:stencil-extent gauge-stencil Y)))
 (ly:make-stencil
  `(delay-stencil-evaluation
,(delay (ly:stencil-expr
 (interpret-markup layout props (format-time duration))
 )))
x-ext y-ext)
 ))
 
calc-duration-engraver = 
#(lambda (context)
   (let ((dur 0) ; duration in seconds
 (start (ly:make-moment 0)) ; last calc-time the duration was calculated
 )
 ; function to calculate duration in seconds since last calc-time
 (define (calc-dur)
   (let ((diff (ly:moment-sub (ly:context-now context) start) ) ; moment since last calc-time
 (tempo (ly:context-property context 'tempoWholesPerMinute (ly:make-moment 60/4)) )) ; current tempo
 (set! start (ly:context-now context)) ; set calc-time
 (set! dur ; add 60*(diff/tempo) to duration
   ; if tempo is 120 BPM and 120/4 elapsed,
   ; we have 60 * 120/4 * 4/120 = 60 seconds
   (+ dur
 (* 60
   (exact->inexact (ly:moment-main (ly:moment-div diff tempo)))
   )))
 dur
 ))
 (make-engraver
  (listeners
   ((tempo-change-event engraver event)
(calc-dur) ; calculate duration on every tempo-change-event (new tempo will be set after we listened to the event)
(ly:message "duration: ~A" (format-time dur))
)
   ) ; listeners
  ((finalize trans)
   (calc-dur) ; last calculation of duration
   (set! duration dur) ; set global duration (for the markup command)
   (ly:message "duration: ~A final" (format-time dur))
   )
  )))

%%% actual music example

music = {
  \tempo 4 = 60
  c'4 c' c' c'
  \repeat volta 2 { d'2 d' | e' e' }
  \tempo 4 = 90
  c'4 c' c' c'
}


Re: calculation of the total duration of a score

2016-09-13 Thread Marc Hohl

Hi Jan-Peter,

seems to do exactly what I need, so thanks for sharing ... I'll give it 
a try tomorrow, when I have some time to work on my project again.


Cheers,

Marc

Am 13.09.2016 um 10:24 schrieb Jan-Peter Voigt:

Hi Marc,

you already received some solutions, but I stumbled across this thread
and just want to quickly show my engraver - perhaps it also helps.

It doesn't read repeats right now, but this may be solved with
\unfoldRepeats and the engraver placed in the midi-block.
The duration-markup-command relies on a global variable and a delayed
stencil - this will not work with multiple scores, as only the duration
of the last score will be displayed. But that is manageable, if needed.

HTH
Jan-Peter

Am 05.09.2016 um 11:01 schrieb Marc Hohl:

Hi list,

I have a couple of songs in my latest theatre project. It would be nice
to have something like "duration: 3'22''" at the end of each song.

Doing this by hand is straightforward:I generate a midi file that sounds
accurate and let it play by timidity – but IMHO it would be less tedious
and less error-prone if lilypond were capable of doing these
calculations itself.

Tempo indications and meter changes have to be taken into account, so
this is probably doable with a special engraver only IIUC.

Has someone else already done something like this? I have no experience
in writing scheme engravers, so any hint would be highly appreciated.

Thanks in advance,

Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: BendSpanner-engraver

2016-09-13 Thread Marc Hohl

Hi Harm, hi list,

I did some simple tests and looked through the code in more detail:

---

The customization features are great! Also, I like the dashed line of 
the pre-pend-hold use cases.


The dashed line would also be great in cases like those:

c'\3\startBend d'\3\stopBend~ d'\3
% bend up, no release, bent note is tied

c'\3\startBend d'\3\stopBend~ d'\3~ d'\3\startBend c'\3\stopBend
% bend up, bent note is tied, release

---

In my archives, I found a real-world-example that does not (yet) work:

< g'\3 b'\2 >4\startBend
< a'\3 c''\2 >\stopBend\startBend
< g'\3 b'\2 >2\stopBend

It is not that easy to play on guitar, but the lower string is raised by 
two semitones, whereas the upper string is raised by one semitone.


I hope to find the source somewhere to provide you a scan of how it 
should look like.


---

Another idea/thought/proposal: IIUC, the engraver does not take the 
string numbers into account. I think this would be a good feature from a 
user's point of view:


c'\startBend d'\stopBend\startBend c'\stopBend

could then probably be simplified to

c'\3\startBend d'\3 c'\3\stopBend

if the engraver internally takes care of each string seperately.
I don't know how hard an implementation would be, but tied notes on a 
certain string can be detected automatically, so the dashed "keep this 
note bent"-line replaces a tied note.

Perhaps the slow-down in the bend::remove-certain-tab-note-heads routine
can be avoided if bend events are handled specifically for certain strings:

< g\3~ b\2~ fis'\1\startBend > < g\3 \b\2 g'\1\stopBend >

---

I do hope my feedback does not sound too negative, this is a huge amount 
of work you have done for us guitar players! Thanks a lot!


Cheers,

Marc

Am 11.09.2016 um 18:36 schrieb Marc Hohl:

Hi Harm,

I did not have much time to fully test it, but wow.
This is awesome! Kudos to you!

I'll give a more detailed report after some tests, but this may take a
while.

Cheers,

Marc

Am 11.09.2016 um 11:53 schrieb Thomas Morley:

Hi all,

as result of my private None-Google-Summer-of-Code, I'd like to
announce a BendSpanner-engraver.

It's based on our scheme-text-spanner.ly from the reg-test and the
fabulous work of Marc Hohl and his bend.ily
Thanks, to Stephen MacNeil who provided a couple of images from
printed editions.


A new grob, BendSpanner, is defined. Line-breaks, skylining, dashed
line for 'pre-bend-hold and a lot more work out of the box.
It's highly customizable. In the demo some possibilities are
demonstrated. More in the test-files.
Currently it works only for TabStaff, coding something for
default-Staff/Voice is on the TODO-list.

Though, currently it's pretty slow in compilation. The reason for this
slugginess
is the feature not to bend open strings and to ex- or include notes to
bend,
more precisley it's the definiton for
`bend::remove-certain-tab-note-heads'.

Not sure how to improve this, any hint is highly appreciated.


Ofcourse this is the first time the code is made public.
I expect several not yet noticed bugs or missing features.

Please report back.


Cheers,
  Harm



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: BendSpanner-engraver

2016-09-11 Thread Marc Hohl

Hi Harm,

I did not have much time to fully test it, but wow.
This is awesome! Kudos to you!

I'll give a more detailed report after some tests, but this may take a 
while.


Cheers,

Marc

Am 11.09.2016 um 11:53 schrieb Thomas Morley:

Hi all,

as result of my private None-Google-Summer-of-Code, I'd like to
announce a BendSpanner-engraver.

It's based on our scheme-text-spanner.ly from the reg-test and the
fabulous work of Marc Hohl and his bend.ily
Thanks, to Stephen MacNeil who provided a couple of images from
printed editions.


A new grob, BendSpanner, is defined. Line-breaks, skylining, dashed
line for 'pre-bend-hold and a lot more work out of the box.
It's highly customizable. In the demo some possibilities are
demonstrated. More in the test-files.
Currently it works only for TabStaff, coding something for
default-Staff/Voice is on the TODO-list.

Though, currently it's pretty slow in compilation. The reason for this
slugginess
is the feature not to bend open strings and to ex- or include notes to bend,
more precisley it's the definiton for `bend::remove-certain-tab-note-heads'.

Not sure how to improve this, any hint is highly appreciated.


Ofcourse this is the first time the code is made public.
I expect several not yet noticed bugs or missing features.

Please report back.


Cheers,
  Harm



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: calculation of the total duration of a score

2016-09-11 Thread Marc Hohl

Am 11.09.2016 um 12:16 schrieb David Kastrup:
[...]

Would this be somehow possible?


I probably lack the imagination for seeing your problem.


I need the total duration in terms of minutes and seconds, taking all 
possible tempo changes etc. into account.



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: calculation of the total duration of a score

2016-09-11 Thread Marc Hohl

Hi Harm, hi Paul,

thanks a lot for your code/improvements/discussion to this subject!

Definitively worth to be put in the LSR!

Some remarks from me as a real-life user:

the engraver does not expand repeats, so if there ist some \repeat volta 
... construct around, the total duration is not only wrong (which is 
clear from the way the engraver works) but somewhat strange.


So my humble question to the scheme wizards out there: is it possible to 
store the total duration in a variable/property to be read afterwards?


I think of something like

music = { ... }

\score {
   \new Staff {
  \music
  \mark \markup "Duration:
#(get-total-duration #{ \unfoldRepeats \music #})"
  \bar "|."
   }
}

(just pseudo-code, of course)

Would this be somehow possible?

Thanks,

Marc




Am 10.09.2016 um 20:48 schrieb Thomas Morley:

Hi Paul,

many thanks for looking into it and adding a diff, much easier to
compare the versions. :)

2016-09-10 20:08 GMT+02:00 Paul :

On 09/09/2016 05:27 PM, Thomas Morley wrote:


Attached you'll find a different version.



I noticed that text-only tempos (\tempo "Andante") caused problems. See
attached revision which fixes this.


Good catch, I overlooked this.
Also for the insufficient
  (if duration-marks
which was kept from an earlier version. Ofcourse your correction is
the way to go.


It also has improved code for detecting
a missing initial tempo (to then supply the default one).  See attached diff
file for changes.


You asked:
2016-09-10 16:40 GMT+02:00 Paul :


Also, I wonder, where you clear out these variables at the end of the
finalize stage:

 (set! evts '())
 (set! last-evt #f)
 (set! tempo-change-evts '())
 (set! duration-marks '())

Of course, it doesn't hurt, but is it necessary?  If so I need to do that in
my code.


Well, at first it's a matter of code-hygiene. Those variables were
filled by the engraver doing it's work, why not clear them?
Additional I fear bleeding over, if the same engraver is used while
compiling multiple scores/files. Or if he is put into multiple
contexts of the same score.
Not entirely sure about this, but better be a paranoiac ;)


Thanks for your thorough review.
I think I'll follow your suggestion and put it in the LSR.


Best,
  Harm

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: calculation of the total duration of a score

2016-09-09 Thread Marc Hohl

Hi Paul,


Am 08.09.2016 um 19:28 schrieb Paul:

Hi Marc,

Well, looks like I sent the file too soon before testing it for this use
case.  It looks like the html-live-score is using different units of
time somehow?  I haven't had a chance to look into it or figure out the
difference.


Ok, no problem, thanks for clarification!

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: calculation of the total duration of a score

2016-09-08 Thread Marc Hohl

Hi Harm,

thanks a lot for your engraver, works out of the box!

Best regards,

Marc

Am 08.09.2016 um 10:02 schrieb Thomas Morley:

2016-09-08 5:39 GMT+02:00 Paul <p...@paulwmorris.com>:

On 09/05/2016 05:01 AM, Marc Hohl wrote:


Has someone else already done something like this? I have no experience
in writing scheme engravers, so any hint would be highly appreciated.



lilypond-html-live-score does something like this by post-processing an SVG
with python to add meta data to the grobs in the SVG file:
https://gitlab.com/sigmate/lilypond-html-live-score/blob/master/make-live-score#L88

I was working on porting part of that to scheme so it could be done
directly.  I've attached my include file.  It will currently display the
total duration to the log.  It could be simplified in various ways if it was
calculating just the total duration and not adding timing info to every
grob.

It's still a work in progress and only lightly tested.

-Paul




Hi,

I've seen Paul answered already, had no time to look into his code, though.

Below my own approach.
Disadvantage: The duration-indication is bound to the last seen event.
This may result in different positions of the RehearsalMark, which I
prefered over TextScript (but this special problem would happen for
both)

\version "2.19.47"

#(define (get-seconds lst rl)
  "Takes a list of kind
'((# 1/15)
  (# 1/30)
  (# 1/15))
Calculates the time passed between each moment.
Returns the addition of it as an exact numerical value.
  "
  (if (null? (cdr lst))
  (apply + rl)
  (get-seconds
(cdr lst)
(cons
  (* (cdr (cadr lst))
 (ly:moment-main (ly:moment-sub (caar lst) (caadr lst
  rl


#(define (score-duration-engraver context)
  (let* ((evts '())
 (last-evt #f)
 (grobs '())
 (tempo-change-evts '()))
  (make-engraver
(listeners
  ((rhythmic-event engraver event)
(set! last-evt (ly:event-property event 'length))
(set! evts (cons (ly:context-current-moment context) evts))
;; TODO creating RehearsalMarks at every rhythmic-event looks like
;; a huge waste. How to do it better?
(set! grobs
  (cons
(ly:engraver-make-grob engraver 'RehearsalMark event)
grobs)))
  ((tempo-change-event engraver event)
   (let ((tempo-unit
   ;; Hmm, ugly code...
   (string->number
 (ly:duration->string (ly:event-property event 'tempo-unit
 (metronome-count (ly:event-property event 'metronome-count)))
;; Accumulate pairs of "moment when it happens" and
;; "quotient of tempo-unit and metronome-count"in `tempo-change-evts'
;; for use in `get-seconds'
(set! tempo-change-evts
  (cons
(cons
  (ly:context-current-moment context)
  (/ tempo-unit metronome-count))
tempo-change-evts)
((finalize translator)
 (let* (;; add default tempo, if not introduced at score-begin
(tempo-changes
  (if (null? tempo-change-evts)
  (list (cons (ly:make-moment 0) 1/15))
  (if (not
(equal? (ly:make-moment 0)
(car (last tempo-change-evts
  (append
tempo-change-evts (list (cons (ly:make-moment 0) 1/15)))
  tempo-change-evts)))
(duration-before-last-tempo-change
  (get-seconds tempo-changes '()))
(duration-after-last-tempo-change-without-last-dur
  (* (cdr (car tempo-changes))
 (ly:moment-main
   (ly:moment-sub (car evts) (caar tempo-changes)
(last-ev-duration
  (* (cdar tempo-changes) (ly:moment-main last-evt)))
(final-duration
  (+
 duration-before-last-tempo-change
 duration-after-last-tempo-change-without-last-dur
 last-ev-duration))
(minutes (floor final-duration))
;; Is using floor correct?
(seconds (floor (* (- final-duration minutes ) 60)))
(duration-string
  (format #f "Duration: ~a:~2,,,'0@a" minutes seconds)))
 ;; Only keep the last created RehearsalMark, suicide the others
 (for-each ly:grob-suicide! (cdr grobs))
 (ly:grob-set-property! (first grobs) 'direction DOWN)
 (ly:grob-set-property! (first grobs) 'text
;; a little custom-formatting
(markup #:rounded-box #:fontsize -3 duration-string))
 (set! evts '())
 (set! last-evt #f)
 (set! grobs '())
 (set! tempo-change-evts '()))

\layout {
  \context {
\Score
\consists \score-duration-engraver
  }
}

%%
%% EXAMPLE
%%

voiceI =
  \new Voice {
\partia

Re: calculation of the total duration of a score

2016-09-08 Thread Marc Hohl

Hi Paul,

thanks for the file. It lookes quite promising, but a quick test shows 
some strange numbers I do not understand:


test.ly ---

\version "2.19.47"

\include "grob-meta-data-engraver.ily"

\score {
  \new Staff {
 \tempo 4 = 60
 \repeat unfold 60 c'4
   }
   \layout { }
   \midi { }
 }

Processing this file yields to:

GNU LilyPond 2.19.48
»test.ly« wird verarbeitet
Analysieren...
Interpretation der Musik...[8][16][16]3.75
Vorverarbeitung der grafischen Elemente...
Interpretation der Musik...
MIDI-Ausgabe nach »test.midi«...
Ideale Seitenanzahl wird gefunden...
Musik wird auf eine Seite angepasst...
Systeme erstellen...
Layout nach »/tmp/lilypond-pgKSZe« ausgeben...
Konvertierung nach »test.pdf«...
Löschen von »/tmp/lilypond-pgKSZe«...
Kompilation erfolgreich beendet

marc@olivia ~/engraver$ timidity test.midi
Playing test.midi
MIDI file: test.midi
Format: 1  Tracks: 2  Divisions: 384
Sequence:
Text: creator:
Text: GNU LilyPond 2.19.48
Playing time: ~64 seconds
Notes cut: 0
Notes lost totally: 0

It shows a duration of 3.75 in line 4.

A timidity call plays the file in about 64 seconds
(even strange, 60 notes with tempo 4 = 60 should have a total duration 
of 60 seconds).


What does 3.75 mean?

Marc


Am 08.09.2016 um 05:39 schrieb Paul:

On 09/05/2016 05:01 AM, Marc Hohl wrote:


Has someone else already done something like this? I have no experience
in writing scheme engravers, so any hint would be highly appreciated.


lilypond-html-live-score does something like this by post-processing an
SVG with python to add meta data to the grobs in the SVG file:
https://gitlab.com/sigmate/lilypond-html-live-score/blob/master/make-live-score#L88


I was working on porting part of that to scheme so it could be done
directly.  I've attached my include file.  It will currently display the
total duration to the log.  It could be simplified in various ways if it
was calculating just the total duration and not adding timing info to
every grob.

It's still a work in progress and only lightly tested.

-Paul



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Changing MulitMeasureRest.stencil to a squiggle

2016-09-07 Thread Marc Hohl

Hi David, hi Harm,

thanks a lot for your work!

Am 06.09.2016 um 22:50 schrieb David Nalesnik:

[...]


P. S.  This all might be easier if the C++ were translated to Scheme.
Then there would be no need to try to match the old stencil's
dimensions, and no redundant calculations.  Looks like it wouldn't be
to hard to do, though I'm not up to it at the moment.


I rewrote the stencil code for bar lines from C++ to scheme once, and it 
is not at all that hard, but it turned out that some helper functions 
had to be wrapped in scheme callbacks to be available at scheme level, 
so it was quite tedious.


Unfortunately, I don't have much time to dig into development again,
at least at the moment :-(

Thanks,

Marc





___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: circle of fifths

2016-09-07 Thread Marc Hohl

Am 06.09.2016 um 19:34 schrieb David Kastrup:

Simon Albrecht  writes:

[...]

At least in mostly functional programming languages.  It might be argued
that German is perfectly appropriate for imperative languages.


;-)






___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Changing MulitMeasureRest.stencil to a squiggle

2016-09-06 Thread Marc Hohl

Am 06.09.2016 um 16:09 schrieb David Nalesnik:

Hi Marc,

On Tue, Sep 6, 2016 at 7:28 AM, Marc Hohl <m...@hohlart.de> wrote:

Hi list,

I want to change the MultiMeasureRest.stencil to a squiggle as shown in the
appendices (quite roughly pasted together in GIMP).
Searching the LSR and the web does not give any informations about this
topic (the only thing I found was using the percent stencil, which is also
hardcoded in the C++ sources).

I tried to override the stencil by

\override MultiMeasureRest.stencil = #ly:line-spanner::print

but this causes errors like

"MultiMeasureRest has empty extent and non-empty stencil."


Even if you for this to work, your mockup shows a line more complex
than a squiggle.  You'd only be able to get a simple zigzag line,
without the refinement at the ends, and without control of the
"amplitude" (as if my simple example below).


I found out that the aplitude may be controlled by

\override Staff.MultiMeasureRest.zigzag-length = #1.33
\override Staff.MultiMeasureRest.zigzag-width = #1.33

and playing around with these values.

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Changing MulitMeasureRest.stencil to a squiggle

2016-09-06 Thread Marc Hohl

Am 06.09.2016 um 16:09 schrieb David Nalesnik:

Hi Marc,

On Tue, Sep 6, 2016 at 7:28 AM, Marc Hohl <m...@hohlart.de> wrote:

Hi list,

I want to change the MultiMeasureRest.stencil to a squiggle as shown in the
appendices (quite roughly pasted together in GIMP).
Searching the LSR and the web does not give any informations about this
topic (the only thing I found was using the percent stencil, which is also
hardcoded in the C++ sources).

I tried to override the stencil by

\override MultiMeasureRest.stencil = #ly:line-spanner::print

but this causes errors like

"MultiMeasureRest has empty extent and non-empty stencil."


Even if you for this to work, your mockup shows a line more complex
than a squiggle.


Yes, of course, but that would have been a starting point ... ;-)


You'd only be able to get a simple zigzag line,
without the refinement at the ends, and without control of the
"amplitude" (as if my simple example below).



Any ideas?


The easiest way to get what you want is to create a stencil callback
which uses the default stencil for dimensions of a replacement
stencil.  The code below is a simple demonstration, which draws lines
like you would get with ly:line-spanner::print.
(Note that you need at least 2.19.27 for this to work.)


\version "2.19.46"

#(define my-stencil
   (lambda (grob)
 (let* ((default-stil (ly:multi-measure-rest::print grob))
(X-ext (ly:stencil-extent default-stil X)))
   (ly:line-interface::line grob (car X-ext) 0 (cdr X-ext) 0


Ah, that's the way to do it: getting the x-ext from the original stencil!
And I wasn't aware that ly:line-interface::line exists, so your answer 
is pretty useful for future solutions.


Thanks,

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Changing MulitMeasureRest.stencil to a squiggle

2016-09-06 Thread Marc Hohl

Hello Pierre,

thank you for your solution, this works like a charm!

Marc

Am 06.09.2016 um 16:15 schrieb Pierre Perol-Schneider:

Or even:

#(define (new-centered-mmr-stencil grob)
 (let* ((sys (ly:grob-system grob))
(X-extent (lambda (q) (ly:grob-extent q sys X)))
(left-bound (ly:spanner-bound grob LEFT))
(left-bound-X-length (interval-length (X-extent left-bound)))
(left-bound-coord (ly:grob-relative-coordinate left-bound
sys X))
(right-bound (ly:spanner-bound grob RIGHT))
(right-bound-X-length (interval-length (X-extent right-bound)))
(right-bound-coord (ly:grob-relative-coordinate right-bound
sys X))
(new-stil
   (grob-interpret-markup grob
 #{
\markup
\concat {
  \override #'(line-cap-style . square)
  \path #0.2
 #'((moveto 0 -0.9)
(lineto 0  0.9))
  \hspace #-.2
  \pattern #7 #X #-.2
\path #0.2
 #'((moveto 0 0)
(lineto 0.5 -0.9)
(lineto 1.5 0.9)
(lineto 2 0))
  \hspace #-.2
  \override #'(line-cap-style . square)
  \path #0.2
 #'((moveto 0 -0.9)
(lineto 0  0.9))
}
  #}
 ))
(new-stil-X-length (interval-length (ly:stencil-extent
new-stil X)))

(translate-value (- (+ (/ (- right-bound-coord
left-bound-coord) 2)
   (/ left-bound-X-length 2))
(/ new-stil-X-length 2)
(/ right-bound-X-length 2)))
   )

   (ly:grob-set-property! grob 'stencil
 (ly:stencil-translate-axis
   new-stil
   translate-value
   X

{
  \compressFullBarRests
  R1*32
  \override MultiMeasureRest.after-line-breaking = #new-centered-mmr-stencil
  R1*71
}

Pierre

2016-09-06 16:03 GMT+02:00 Pierre Perol-Schneider
<pierre.schneider.pa...@gmail.com
<mailto:pierre.schneider.pa...@gmail.com>>:

Hi Marc,

See:

http://lilypond.1069038.n5.nabble.com/How-to-align-a-new-MultiMeasureRest-stencil-td142767.html

<http://lilypond.1069038.n5.nabble.com/How-to-align-a-new-MultiMeasureRest-stencil-td142767.html>
How about:

\version "2.19.47"

#(define (new-centered-mmr-stencil grob)
 (let* ((sys (ly:grob-system grob))
(X-extent (lambda (q) (ly:grob-extent q sys X)))
(left-bound (ly:spanner-bound grob LEFT))
(left-bound-X-length (interval-length (X-extent
left-bound)))
(left-bound-coord (ly:grob-relative-coordinate
left-bound sys X))
(right-bound (ly:spanner-bound grob RIGHT))
(right-bound-X-length (interval-length (X-extent
right-bound)))
(right-bound-coord (ly:grob-relative-coordinate
right-bound sys X))
(new-stil
   (grob-interpret-markup grob
 #{
\markup
\concat {
  \general-align #Y #0
  \override #'(thickness . 2)
  \draw-line #'(0 . 2)
  \hspace #-.2
  \pattern #7 #X #-.2
\path #0.2
 #'((moveto 0 0)
(lineto 0.5 -1)
(lineto 1.5 1)
(lineto 2 0))
  \hspace #-.2
  \general-align #Y #0
  \override #'(thickness . 2)
  \draw-line #'(0 . 2)
}
  #}
 ))
(new-stil-X-length (interval-length (ly:stencil-extent
new-stil X)))

(translate-value (- (+ (/ (- right-bound-coord
left-bound-coord) 2)
   (/ left-bound-X-length 2))
(/ new-stil-X-length 2)
(/ right-bound-X-length 2)))
   )

   (ly:grob-set-property! grob 'stencil
 (ly:stencil-translate-axis
   new-stil
   translate-value
   X

{
  \compressFullBarRests
  R1*32
  \override MultiMeasureRest.after-line-breaking =
#new-centered-mmr-stencil
  R1*71
}


HTH,
Cheers,
Pierre

    2016-09-06 

Re: calculation of the total duration of a score

2016-09-06 Thread Marc Hohl

Am 05.09.2016 um 11:54 schrieb Federico Bruni:

Il giorno lun 5 set 2016 alle 11:01, Marc Hohl <m...@hohlart.de> ha
scritto:

[...]

I have not tried, but maybe python-ly is able to give what you want?
http://python-ly.readthedocs.io/en/latest/ly.music.html


Thanks for the link.

If I haven't overlooked an important detail, python-ly does not provide 
this function out-of-the-box.


Moreover, a scheme-ish solution allows for direct generation of a markup 
to be placed at the final bar line.


Marc





___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Changing MulitMeasureRest.stencil to a squiggle

2016-09-06 Thread Marc Hohl

Hi list,

I want to change the MultiMeasureRest.stencil to a squiggle as shown in 
the appendices (quite roughly pasted together in GIMP).
Searching the LSR and the web does not give any informations about this 
topic (the only thing I found was using the percent stencil, which is 
also hardcoded in the C++ sources).


I tried to override the stencil by

\override MultiMeasureRest.stencil = #ly:line-spanner::print

but this causes errors like

"MultiMeasureRest has empty extent and non-empty stencil."

Any ideas?

Thanks,

Marc
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


calculation of the total duration of a score

2016-09-05 Thread Marc Hohl

Hi list,

I have a couple of songs in my latest theatre project. It would be nice
to have something like "duration: 3'22''" at the end of each song.

Doing this by hand is straightforward:I generate a midi file that sounds
accurate and let it play by timidity – but IMHO it would be less tedious
and less error-prone if lilypond were capable of doing these
calculations itself.

Tempo indications and meter changes have to be taken into account, so
this is probably doable with a special engraver only IIUC.

Has someone else already done something like this? I have no experience
in writing scheme engravers, so any hint would be highly appreciated.

Thanks in advance,

Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Potential improvements to the homepage?

2016-08-21 Thread Marc Hohl

Am 21.08.2016 um 15:41 schrieb Andrew Bernard:

Hello Andrew and welcome (from another Haskell user!).

I agree with you. The website is looking tired and faded. But I think
it is somehow generated programmatically from the lilypond builds, and
not based on a content management system. I suspect this makes it
difficult to give it a fresh new look.


Isn't this mainly a CSS topic?

 This topic may better be raised

on the lilypond development list perhaps?

Lilypond does not have a REPL like Haskell. It's simply compiled. I
seem to recall there is a site where you can try out lilypond on the
web. The others on the list will know.


It's

http://www.lilybin.com

And yes, the possibility to give lilypond a try "on the fly" by means of 
a web interface would be a good idea IMHO.


Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: LilyPond logo?

2016-08-05 Thread Marc Hohl

Am 05.08.2016 um 14:01 schrieb Malte Meyn:
[...]

But maybe less is more and two flower layers are enough; so here is a
combination of logo3 and logo4 (only two flower layers -> less detail,
only one pad but with gap -> more typical).


I like it!

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: LilyPond logo?

2016-08-05 Thread Marc Hohl

Am 05.08.2016 um 11:38 schrieb Werner LEMBERG:



Here are some experiments of mine.


Very nice!


logo1.svg is the one I used in the score, logo_outline.svg is the
outline version, logo2/3/4.svg are some attempts to make it simpler.


I like logo3 most.


+1

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: getting repeat bar lines to print across an entire system

2016-07-26 Thread Marc Hohl

Am 24.07.2016 um 18:10 schrieb David Kastrup:
[...]

Well, accolades are nice and everything, but if we are talking about
frequently desired functionality, it makes sense that enough hooks are
in LilyPond itself that a custom layout can then be called upon with one
rather than 20 pages of Scheme code.

Of course, it is not always easy to figure out what is required often
enough.


Speaking for myself, I'd use the accolades more frequently if they would 
work out of the box.


Marc





___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: lilypond - Tex

2016-07-12 Thread Marc Hohl

Am 12.07.2016 um 18:24 schrieb David Wright:

On Tue 12 Jul 2016 at 17:25:35 (+0200), Marc Hohl wrote:

IIUC, the original question was about to integrate LaTeX code within
LilyPond, not the other way round ;-)


? Of course it is when you snip the rest of the OP,


Ok, sorry.



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: lilypond - Tex

2016-07-12 Thread Marc Hohl
IIUC, the original question was about to integrate LaTeX code within 
LilyPond, not the other way round ;-)


Am 12.07.2016 um 16:35 schrieb Henning Hraban Ramm:

Hi,
maybe have a look at my LilyPond/ConTeXt setup at 
http://wiki.contextgarden.net/LilyPond (Sample Include File).

If you dont like lilypond-book, you might try LyLuaTeX 
(https://github.com/jperon/lyluatex).

Greetlings, Hraban
---
fiëé visuëlle
Henning Hraban Ramm
http://www.fiee.net
http://angerweit.tikon.ch/lieder/
https://www.cacert.org (I'm an assurer)





___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: lilypond - Tex

2016-07-12 Thread Marc Hohl

Am 11.07.2016 um 21:26 schrieb bart deruyter:

Hi all,
[...]

I don't think it is possible now, but maybe it would be interesting to
work the other way round: inserting latex code in a lilypond file. Or
would it be possible? :-)


Is

https://github.com/openlilylib/snippets/tree/master/specific-solutions/xelatex-markup-list

what you're searching for?

HTH,

Marc


grtz,
Bart

http://www.bartart3d.be/
On Twitter 
On Identi.ca 
On Google+ 


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: slurs and repeats

2016-07-05 Thread Marc Hohl

Am 05.07.2016 um 11:42 schrieb Martin Tarenskeen:
[...]

I need a (partial) slur at the end of the first ending to indicate it's
slurred back to the first e' of the repeated segment. Just like the
pickup bar (\partial 4) is slurred to that same note.


Have you considered drawing the slur to the d and tweak its appearance 
so that it looks like a "half" slur?


Marc





___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: drum staves

2016-06-13 Thread Marc Hohl

Hi Riccardo,

Am 13.06.2016 um 12:27 schrieb Riccardo:

Hi, i just started to use lilypond (with frescobaldi editor).
I use it for writing drum set scores.
My problem is this: i need the small tom to be in the place of the hi hat
  (in the last upper space in the
staff… E note placement so to say…)
i try to read the manuals but couldn't figure out how to change
this…


Have you read

http://lilypond.org/doc/v2.18/Documentation/notation/common-notation-for-percussion#custom-percussion-staves

This should give you a clue about changing the defaults.

HTH a bit,

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: invisible note for expressive marks

2016-05-28 Thread Marc Hohl

Am 28.05.2016 um 19:47 schrieb Gianmaria Lari:

The expressive marks must be attached to a note. I was wondering if it
exists any void/invisible note that it is possible to use to avoid
this constraint, something like: "voidelement" \p


That's exactly what I used as an example in you other thread:

<>\p does exactly what you need ;-)

Marc


Thank you, g.

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: repeat and dynamic

2016-05-27 Thread Marc Hohl

Am 27.05.2016 um 18:50 schrieb Toine Schreurs:

Have a look to the following code. Please note that each line contain
the same notes but different dynamic information:

\version "2.19.40"
{
   a'-4 \p \< g'-3 e'-2 c''-5
   a'-4 g'-3 e'-2 c''-5
   a'-4 g'-3 e'-2 c''-5 \!
}

Is there any way to write the previous code using a repeat? Something
like this (that of course does not work):

\p \< \repeat unfold 3 {a'-4 g'-3 e'-2 c''-5} \!


I think

<>\p\<  \repeat unfold 3 {a'-4 g'-3 e'-2 c''-5} <>\!

could do the trick, but this is untested!

HTH,
Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: OT: chord naming question

2016-05-27 Thread Marc Hohl

Am 27.05.2016 um 15:29 schrieb Urs Liska:

Am 27.05.2016 um 14:20 schrieb Marc Hohl:

Write the highest note as an a# and consider it as an added 13#.

Write the upper notes as c-e-bf and interpret it as bitonal (C7 over
csharp).


Ok. If I include the g-sharp I got C7#5 over c#. Wow.


That'd be an option but I meant something different.  Of course (as
others have said) it's also depending on the context, that is on the
actual voicing/instrumentation and the general kind of harmony the music
seems to follow.

What I meant is: Consider the (left hand?) c# g# as "c#" without
specifying major/minor and the c e b# as C7. If I imagine this played on
a piano(-like instrument) this could well be an appropriate description
of what it sounds like.


Oh, now I understand – I read the c-sharp as the root/bass note, not as 
a chord (or powerchord - guitar-wise speaking).


But I see now one mistake: the topmost note is a b-natural, so it is a 
Cmaj7 over C#5.


Thzanks,

Marc


Best
Urs




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: OT: chord naming question

2016-05-27 Thread Marc Hohl

Am 27.05.2016 um 12:52 schrieb Thomas Morley:
[...]

Hi Harm,


Hi Marc,

is it an excerpt of an already printed piece (looks vaguely familiar
to me)?


No – it is a piece of mine, written some years ago for a (progressive)
rock band. I want to re-use the chords and melody for a musical project.


Without further context I've no idea how to name it, could you
provide some more?


Well, the intro and parts of the verse consist of this chord and the
same voicing lowered a whole tone (IIRC, the inspiration came from
"Nica's dream" – a jazz tune by Horace Silver, with Bbmmaj7/Abmmaj7 at
the very beginning).

The melody fits nicely into c-sharp phrygian, but I assume that this
does not help very much for the chord naming problem here.

Cheers,

Marc


Cheers, Harm




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: OT: chord naming question

2016-05-27 Thread Marc Hohl

Am 27.05.2016 um 13:11 schrieb Urs Liska:



Am 27. Mai 2016 12:58:10 MESZ, schrieb Michael Hendry 
<hendry.mich...@gmail.com>:



On 27 May 2016, at 11:36, Marc Hohl <m...@hohlart.de> wrote:

Hi list,

as there are already (partly very emotional) dicussions concerning
F# vs. Gb in another (hijacked) thread,


https://lists.gnu.org/archive/html/lilypond-user/2016-05/msg00418.html

I hope to get some information *without* starting a flame war ;-)

I have the following chord played on a guitar, see the attached

image.


< c-sharp g-sharp b-sharp e' b'>

It starts as a c minor chord with a major 7, so I'd call it cmmaj7,

but

the added b' is the minor seventh.

cm7maj7 does not look quite right, so should the b' be written as an
a'-doublesharp, to call it cmmaj7#13?

Thanks in advance!

Regards,

Marc
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user



There’s no trace of C minor here, as far as I can see (no C natural, no
E flat, no G natural) so I think I’d regarded it as a C sharp minor
seventh with an added major seventh.

It could be seen as part of a modified "Stairway to Heaven” cliché,
with the descending C sharp, C natural, B natural, A sharp sequence on
the D string.


I think the c minor was a simple typo and should read c sharp minor.


D#oh. Exactly, it was a typo – I mean c sharp minor.


I see two interpretations:

Write the highest note as an a# and consider it as an added 13#.

Write the upper notes as c-e-bf and interpret it as bitonal (C7 over csharp).


Ok. If I include the g-sharp I got C7#5 over c#. Wow.


Having major and minor 7 in the chord doesn't seem to make much sense to me.


I think I'd vote for a-doublesharp, but I'll wait some time – perhaps 
there are other ideas? ;-)


THanks,

Marc


Urs


Michael
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user





___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


OT: chord naming question

2016-05-27 Thread Marc Hohl

Hi list,

as there are already (partly very emotional) dicussions concerning
F# vs. Gb in another (hijacked) thread,
https://lists.gnu.org/archive/html/lilypond-user/2016-05/msg00418.html
I hope to get some information *without* starting a flame war ;-)

I have the following chord played on a guitar, see the attached image.

< c-sharp g-sharp b-sharp e' b'>

It starts as a c minor chord with a major 7, so I'd call it cmmaj7, but
the added b' is the minor seventh.

cm7maj7 does not look quite right, so should the b' be written as an
a'-doublesharp, to call it cmmaj7#13?

Thanks in advance!

Regards,

Marc
___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: multiple tails

2016-05-24 Thread Marc Hohl

Am 24.05.2016 um 16:54 schrieb Michael Edwards:

Hello everyone,

When I print some scores I get multiple tails on some notes. See
attached for an example. Looking at the PDF it's fine, but I've
printed on several printers from different machines and always get
extra tails. Any idea what might be causing this?


IIRC, there was a problem with multiple flags some time ago.

Which lilypond version do you use?

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Lilypond statistics

2016-04-08 Thread Marc Hohl

Am 08.04.2016 um 06:51 schrieb Dave Higgins:

Is there any way to generate statistics for a file?  Things like, let
say, a concordance or the number of a's b's or bes's, or repeated
markup's?  (I know I can do stuff like this with grep, but that's very
singular.)


I think

https://lists.gnu.org/archive/html/lilypond-user/2010-01/msg00668.html

may be a good starting point.

HTH,

Marc



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: 4 slashes in percent repeat

2016-04-04 Thread Marc Hohl

Hi Daniel,

Am 04.04.2016 um 07:07 schrieb Daniel E. Moctezuma:

Thanks for your reply.

The samples from http://lsr.di.unimi.it/LSR/Item?id=954 look nice for solo 
pieces, but my use case is for multiple instruments.
Imagine a rock band where the bass has 4 bars that will be repeated, but the 
rest of the instruments don't have repetitive bars. I've have seen this usage 
in rock songs for instance.


I see.


I understand the issue of having 2 empty bars and it seems like having a number 
above the percent repeat helps.
Example: https://musescore.org/sites/musescore.org/files/finale%20four-bar.jpg


I like the last one! With help of the thicker lines trough the otherwise 
empty bars, it is visually clear which bars belong together.


I am sure that this is doable in lilypond, but this scheme wizardry is 
way over my head ...


Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: 4 slashes in percent repeat

2016-04-03 Thread Marc Hohl

Am 03.04.2016 um 15:36 schrieb Thomas Morley:

2016-04-02 19:47 GMT+02:00 Daniel E. Moctezuma
:

Hello

I was wondering if it's possible to have a percent repeat with 4
slashes in LilyPond. Like an \override setting or similar. My use
case is when a set of 4 bars repeats n times, like: \repeat percent
4 { c1 | d | e | f | }

the most I can get is a double percent symbol .//. is there a way
to have .. ?


I remember vaguely that this issue has been discussed some years ago.

The problem I see here is that you have two completely empty bars:

|  | .//|//.|   |

So it is not easy at first glance to understand what's going on here.

I use this abbreviation for my handwritten manuscripts, but here I draw
the slashes wide and slanted enough to cover all four bars.

These comments aside, it looks as if the underlying C++ routines could
indeed handle more than 2 slashes, but there is no way to call that
routine directly IIUC.



Best regards




Apart from manually tweaking, I see no reasonable chance. But how
about: http://lsr.di.unimi.it/LSR/Item?id=954


Looks promising and easy to read.

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: custom multi-measure rests

2016-03-24 Thread Marc Hohl

Am 24.03.2016 um 10:45 schrieb Andrew Bernard:

Hi David,

It’s LSR 753 I think you are after.


D'oh – I searched the LSR for "multi measure rest" but did not find that 
one ;-)


Marc


Andrew



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Flag stencil

2016-03-24 Thread Marc Hohl

Am 24.03.2016 um 09:37 schrieb Andrew Bernard:

Hi Marc,

Thanks. But I specifically mentioned I am drawing my own stencil, not
using a font glyph.


Yep, that's exactly what I wrote. The stuff with the glyphs was just an 
explanation for Lilypond's way to *choose* flags not to *stack* them, so 
you have to do this in your function, too...


Digging deeper, the answer lies in flag-styles.scm, where can be found a
recursive function buildflag that recursively draws the supplied stencil
in the right offsets according to the supplied duration. So I nearly
have the solution I need.


... as you found out for yourself ;-)

Marc


Andrew


On 24/03/2016, 19:12, "Marc Hohl"
<lilypond-user-bounces+andrew.bernard=gmail@gnu.org
<mailto:lilypond-user-bounces+andrew.bernard=gmail@gnu.org> on
behalf of m...@hohlart.de <mailto:m...@hohlart.de>> wrote:

So you have to check duration-log and draw the suitable number of flags
according to its value.



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Flag stencil

2016-03-24 Thread Marc Hohl

Am 24.03.2016 um 03:00 schrieb Andrew Bernard:

When making a custom flag stencil, how does one go about getting all the
flags added to the stem, for the various note values, not just one?

Here’s what I have so far, which only makes one flag for any value. I
want to draw my own paths, not add glyphs from the font.


Lilypond uses separate glyphs for one, two, three flags and does not 
simply stack one flag several times onto the stem.


So you have to check duration-log and draw the suitable number of flags 
according to its value.


HTH a bit,

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: custom multi-measure rests

2016-03-24 Thread Marc Hohl

Am 24.03.2016 um 02:47 schrieb Flaming Hakama by Elaine:


I'd like to figure out how to execute something found in some Jazz
charts for drums.
It is a compact way to indicate "play time for X measures" in a single
measure.



I think this has been discussed (and solved) already, see

https://lists.gnu.org/archive/html/lilypond-user/2011-03/msg00025.html

and follow the thread for a solution.

HTH,

Marc



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Winged repeat bar line unique over multiple staves

2016-03-22 Thread Marc Hohl

Am 22.03.2016 um 14:20 schrieb Malte Meyn:



Am 22.03.2016 um 14:03 schrieb Alexis Maleval:

Hi,
I would like to know how to prevent a winged repeat bar line to be
split when it
has to cover 2 staves.


Probably this isn’t possible yet;


Yep. I rewrote the bar line stuff some years ago and stumbled across the 
fact that winged span bars are not possible.


I did not find an easy way to implement them, so I gave up :(

To be honest, the whole span bar creation routine is not really open for 
enhancements IIRC.


Marc



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Q re LSR snippet 744

2016-03-19 Thread Marc Hohl

Am 19.03.2016 um 11:02 schrieb Michael Gerdau:

Hi list,

I'm playing with LSR snippet 744 and wish to make a small amendment to
its functionality. While trying to understand what it does I think it
is not working as it should.

Here is the link: http://lsr.di.unimi.it/LSR/Item?id=744

Most importantly I think the words 'lil le' and 'fis ker' should be
displayed without a separating space after the hyphen had been removed.


That's right; IIRC it worked without adding space characters in the past.

Marc

___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: openlilylib.org programming

2016-03-19 Thread Marc Hohl

Am 18.03.2016 um 14:26 schrieb Urs Liska:
[...]

So, participation of people with knowledge and/or interest in one or
more of:

  * Bootstrap
  * Angular
  * Node.js
  * Client-Server websites
  * openLilyLib
  * documentation generation

would be highly welcome!


I am sorry to say that I won't be of much help in regard to these 
topics, but I like the logo!


Marc


I won't publicly share the URL to the stub but as a little appetizer I'm
sharing the new "logo" lettering that I - finally - put together.

Best wishes
Urs



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Adding acoustic guitar (steel) to MIDI

2016-03-16 Thread Marc Hohl

Am 15.03.2016 um 23:31 schrieb Abraham Lee:
[...]

You can turn off any context's midi instrument like this:

\new ChordNames \with { midiInstrument = ##f }


Another possibility (just for the record):

\new ChordNames \with { \remove Staff_performer }

should work as well.

Marc


that way you don't need to deal with the synthesizer to turn things on/off.

HTH,
Abraham



___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user




___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: OT: Help needed to package cross-platform python application

2016-03-10 Thread Marc Hohl

Am 11.03.2016 um 08:12 schrieb Blöchl Bernhard:

OT? Indeed! Another blog highchecking attack. Why not stay in the python
blog?


s/highchecking/hijacking/ ;-)


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: DrumStaff with melodic ossia

2016-03-10 Thread Marc Hohl

Am 10.03.2016 um 10:06 schrieb Pierre-Luc Gauthier:

Greetings

I have this drum part that needs an ossia for a Tubular bell.

But I cannot write music in it some how.
The problem can be seen and explained on line 25 and 26.

Currently I have a sn (snare) that should be a b flat.


You have to swith to \notemode:



   \new Staff = "ossia" \with {
 alignAboveContext = "drum"
 \remove "Time_signature_engraver"
 \override StaffSymbol #'staff-space = #(magstep -3)
   }
   % This bellow should be, say, a bf; i.e. not a snare.
   {\setTubularBells sn2\laissezVibrer }


change this to

{ \notemode { \setTubularBells a2 c'4 d' } }

see

http://lilybin.com/hwg9nm/3

HTH,

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: override StaffSymbol.line-count

2016-02-26 Thread Marc Hohl

Am 26.02.2016 um 10:16 schrieb Bernard:

Hi,

I am new to Lilypond.

I would like to use a 2 line staff with the code :

-

\version "2.16.2"

timb = \drummode {
  timh4 ssh
}

   <<
 \new DrumStaff \with {
   drumStyleTable = #timbales-style
   \override StaffSymbol.line-count = #2  # generate syntax error


With version 2.16.x, you have to use

\override StaffSymbol #'line-count = #2

The dot syntax came with 2.18.x, I think, and I recommend upgrading to a 
newer lilypond release.


HTH,

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: Lilypond and Jazz chords

2016-01-18 Thread Marc Hohl

Am 18.01.2016 um 09:12 schrieb Blöchl Bernhard:
[...]


Do you really believe that Sibelius was inspired by R?
The first edition of
Standardized chord symbol notation : (a uniform system for the music
profession)
von Carl Brandt; Clinton Roemer Englisch
was published 1976 by Sherman Oaks, Calif. : Roerick Music Co.

Johan Julius Christian („Jean“) Sibelius * 8. Dezember 1865 in
Hämeenlinna; † 20. September 1957 in Järvenpää near Helsinki;


IIUC, it is about the software called Sibelius, not the composer.


Are you really doing in music? May be you are only a bit bored and like
to make some noise?


Please, let's come back to a more decent style of discussion.

Chord naming rules tend to upset people, but let's not get on
with that stuff ...

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


Re: how to add header to markup after score

2016-01-09 Thread Marc Hohl

Am 09.01.2016 um 12:13 schrieb Thomas Morley:

2016-01-09 9:04 GMT+01:00 Marc Hohl <m...@hohlart.de>:

Am 09.01.2016 um 08:24 schrieb Jacques Menu:


Hello Harm,


[...]

In procedure memoization in expression (let* (block, too! # ...)

This looks as if Harms comment is taken as a scheme command due to wrong
line breaks,


I just copied the LSR-snippet.
All merits belong to its author, was Reinhold Kainhofer, I think.


Ah, ok, so s/Harms/the/ ;-)

Marc


___
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user


  1   2   3   4   5   6   7   8   9   >