Custom dynamic function

2019-12-17 Thread foxfanfare
Hi all, I am trying to make a shortcut which could easily create dynamic texts without having the necessity to create a specific variable each time. Here is my attempt : --- \version "2.19.82" dynI = #(make-dynamic-script (markup #:line (#:left-align #:normal-text "this is a long

Re: Custom dynamic function

2019-12-17 Thread Kieren MacMillan
Hi, > I am trying to make a shortcut which could easily create dynamic texts > without having the necessity to create a specific variable each time. This wheel has been invented, e.g. https://lists.gnu.org/archive/html/lilypond-user/2019-09/msg00159.html Likely, Harm’s work either solves your pr

RE: problems with cues

2019-12-17 Thread Peter Gentry
You did help David your response forces me think more clearly - when you make a definite statement I take it on board. I know full well how difficult it is when someone is thrashing about in another's area of expertise and not expressing themselves clearly. I really don't mind what might be seen a

Re: Custom dynamic function

2019-12-17 Thread foxfanfare
I didn't see that post back in time. Thank you, I'll look into that! -- Sent from: http://lilypond.1069038.n5.nabble.com/User-f3.html

Swing/Shuffle rhythmMark

2019-12-17 Thread mu...@gmx.ch
Hi folks Back again after quite a while. I'm starting to typeset a songbook (or song sheets) for a singer-songwriter friend of mine who is about to launch another swiss-german children songs cd. First hurdle: I'd like to typeset a shuffled/swinged melody with 8th only instead of - a8. a16 a8. a

Need help with Scheme code

2019-12-17 Thread Paolo Prete
Hello all, In order to automate the reverse process of the lilypond+javascript snippets (write the GUI modifications of the grobs to the .ly file) I need to make the following code work: % token = \tweak output-attributes #'((id . "foobar")) \score { { a8 \token

Re: Need help with Scheme code

2019-12-17 Thread Stefano Troncaro
Hi Paolo, Look at this: \version "2.19.83" token = -\tweak output-attributes #'((id . "foobar")) \etc \relative { c'4 d8 -\token [ e ] f2 } That achieves half of what you want. Now, how to make "foobar" automatically increment I don't know, perhaps someone else can help with that. Hope that h

Re: Need help with Scheme code

2019-12-17 Thread Paolo Prete
Thanks Stefano! On Tue, Dec 17, 2019 at 11:18 PM Stefano Troncaro wrote: > Hi Paolo, > > Look at this: > > \version "2.19.83" > > token = -\tweak output-attributes #'((id . "foobar")) \etc > > \relative { c'4 d8 -\token [ e ] f2 } > > That achieves half of what you want. Now, how to make "foobar

Re: Need help with Scheme code

2019-12-17 Thread Paolo Prete
In addition, Stefano, If you have time, please try the snippet for tuning the beams (second attachment). Any test of these things are very helpful for me. On Tue, Dec 17, 2019 at 11:18 PM Stefano Troncaro wrote: > Hi Paolo, > > Look at this: > > \version "2.19.83" > > token = -\tweak output-attr

Re: Need help with Scheme code

2019-12-17 Thread Stefano Troncaro
Hi Paolo, After some googling and tweaking I managed to make the counter you wished: \version "2.19.83" #(define* (make-counter #:optional (cnt 0) (inc 1)) (lambda () (set! cnt (+ cnt inc)) cnt)) #(define serial (make-counter)) token = -\tweak output-attributes #`((id . ,(string-a

Re: Need help with Scheme code

2019-12-17 Thread Paolo Prete
Hi Stefano, unfortunately, it doesn't increment the counter globally, and the two ids in the SVG file are identical On Wed, Dec 18, 2019 at 12:12 AM Stefano Troncaro wrote: > Hi Paolo, > > After some googling and tweaking I managed to make the counter you wished: > > \version "2.19.83" > > #(de

Re: Need help with Scheme code

2019-12-17 Thread Kieren MacMillan
Hi Paolo, > The ids must be: foobar_1, foobar_2 etc. Can they be foobar.1, foobar.2, etc. instead? Lilypond has a nice built-in mechanism for that naming/pointer convention. Hope that helps! Kieren. Kieren MacMillan, composer (he/him/his) ‣ website: www.kierenm

Re: Need help with Scheme code

2019-12-17 Thread Paolo Prete
Hi Kieren, yes, of course! please let me know how to use it On Wed, Dec 18, 2019 at 1:32 AM Kieren MacMillan < kieren_macmil...@sympatico.ca> wrote: > Hi Paolo, > > > The ids must be: foobar_1, foobar_2 etc. > > Can they be foobar.1, foobar.2, etc. instead? > Lilypond has a nice built-in mechan

Re: Need help with Scheme code

2019-12-17 Thread Aaron Hill
On 2019-12-17 4:21 pm, Paolo Prete wrote: Hi Stefano, unfortunately, it doesn't increment the counter globally, and the two ids in the SVG file are identical You will need to define a music function so that the (serial) procedure is called on each occurrence. Here's an option that rolls in

Re: Need help with Scheme code

2019-12-17 Thread Paolo Prete
And thanks again to the Scheme-master Aaron. One last thing: how can I arrange that function so to obtain output-attributes = output-attributes + id ? For example: if output-attributes is (('a' . 'aa') ('i' . 'ii')) it must become:(('a' . 'aa') ('i' . 'ii') ('id' . 'foobar_1')) On Wed,

Re: Need help with Scheme code

2019-12-17 Thread Aaron Hill
On 2019-12-17 6:01 pm, Paolo Prete wrote: And thanks again to the Scheme-master Aaron. I appreciate the kind words, though I doubt my experience rises to the level of "master". One last thing: how can I arrange that function so to obtain output-attributes = output-attributes + id ? For ex

Re: Swing/Shuffle rhythmMark

2019-12-17 Thread Mats Bengtsson
Did you remember to convert the file to the latest version: convert-ly --from=2.18.2 -e yourfile.ly After such a conversion, the example looks fine when I try it with 2.19.83.    /Mats On 2019-12-17 22:27, mu...@gmx.ch wrote: Hi folks Back again after quite a while. I'm starting to typeset