Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-15 Thread Paolo Prete
Good idea Kieren, if they approve it, I'll suggest the nomenclature you proposed. Best, P On Mon, Dec 16, 2019 at 2:03 AM Kieren MacMillan < kieren_macmil...@sympatico.ca> wrote: > Hi Paolo, > > > After that, can we add this on the snippets repository? > > Might I suggest a nomenclature improve

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-15 Thread Paolo Prete
Ok, let's move the discussion on the dev ml, then. Cheers, P On Mon, Dec 16, 2019 at 2:07 AM Thomas Morley wrote: > Am Mo., 16. Dez. 2019 um 01:50 Uhr schrieb Paolo Prete < > paolopr...@gmail.com>: > > > > Hello Thomas, > > > > this is a bit discouraging for me, TBH. > > Hope someone could wri

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-15 Thread Thomas Morley
Am Mo., 16. Dez. 2019 um 01:50 Uhr schrieb Paolo Prete : > > Hello Thomas, > > this is a bit discouraging for me, TBH. > Hope someone could write a proper Scheme procedure, then, and port the > snippet on 2.18.2. Makes no sense to "downgrade" your code, imho. That would mean to replace nice code

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-15 Thread Kieren MacMillan
Hi Paolo, > After that, can we add this on the snippets repository? Might I suggest a nomenclature improvement? Since the code tunes slurs, phrasing slurs, and ties, perhaps it makes sense to change all "JSSVGSlurTuner*" names (code and file) to something like “JSSVGCurveTuner*” or similar. Ju

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-15 Thread Paolo Prete
Hello Thomas, this is a bit discouraging for me, TBH. Hope someone could write a proper Scheme procedure, then, and port the snippet on 2.18.2. Best, P On Mon, Dec 16, 2019 at 12:24 AM Thomas Morley wrote: > Am Mo., 16. Dez. 2019 um 00:06 Uhr schrieb Paolo Prete < > paolopr...@gmail.com>: >

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-15 Thread Thomas Morley
Am Mo., 16. Dez. 2019 um 00:06 Uhr schrieb Paolo Prete : > After that, can we add this on the snippets repository? No. The LSR runs 2.18.2 and apart from other things grob-transformer is a 2.19.-feature. There's some older code of mine around printing control-points and the like, but Aaron's code

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-15 Thread Paolo Prete
Attached to this post there's the improved version (fixed indentation and lines' max length). Note too that this version includes a function that prevents opening the default menu with the right mouse button. Can someone fix the scheme code indentation? After that, can we add this on the snippets

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-15 Thread Stefano Troncaro
Hi Paolo, I tried it out and it seems to be working great! This should save a lot of time. Thank you! El dom., 15 dic. 2019 a las 4:05, Werner LEMBERG () escribió: > > > At this point, here's the complete all-in-one .ly template. [...] > > It would be nice if you could format this to avoid line

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-15 Thread Kieren MacMillan
Hi Paolo (and everyone else who contributed to this snippet/feature), This is *so* fabulous! Thank you for the wonderful and useful tool. Best, Kieren. Kieren MacMillan, composer (he/him/his) ‣ website: www.kierenmacmillan.info ‣ email: i...@kierenmacmillan.info

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-14 Thread Werner LEMBERG
> At this point, here's the complete all-in-one .ly template. [...] It would be nice if you could format this to avoid line lengths longer than 80 characters. As the non-HTML part of your e-mail shows, the code becomes very hard to read otherwise. Werner

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-14 Thread Étienne Beaulé
I wouldn't worry so much about overriding that define, as svg-end can only be used at that one spot or the output file would be corrupted. A patch that included a proper override was provided 9 years but ignored. I'll get the relevant parts of the patch up-to-date as it is proving potential. Than

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-14 Thread Paolo Prete
At this point, here's the complete all-in-one .ly template. Much cleaner and without risks to mess the code, for the user. In addition, it has not to be patched: just open and use the generated .svg file. Hope it could be included in the snippets repo. Thanks all for your collaboration! %

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-14 Thread Paolo Prete
To Stefano and Elaine: really, it's better to avoid scripting on scripting on scripting, IMHO. SVG is designed to be lovely coupled with JS, and the output file should be all-inclusive. Nor HTML is required. Only Lilypond and any SVG viewer (including browsers). The override of internal stuff pro

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-14 Thread Paolo Prete
Hello Aaron, I understand that it is potentially dangerous because this is not API but we are accessing it like API. However, looking at the code, svg-end is referenced only inside its def file (framework-svg.scm), as a dummy append to the output file: http://git.savannah.gnu.org/gitweb/?p=lilypo

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-14 Thread Aaron Hill
On 2019-12-14 6:16 am, Paolo Prete wrote: However, how can I make it work for multiple pages output? Another approach would be to modify how LilyPond generates SVG output, so that the script in question is inserted just before the closing element: \version "2.19.83" svg-script = #(de

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-14 Thread Stefano Troncaro
Hi Paolo, I was also having that concern. Elaine replied in a new thread with a solution for that, in which instead of adding the script to the svg files with lilypond you just use an external script. I haven't tested it yet but it seems to me like that'll be a cleaner approach, you just include t

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-14 Thread Paolo Prete
Hi Stefano, your suggestion produces the script for every page, but it requires to manually add a property in the \paper scope. Instead, I would like to automatically set this property, and leave the user to set all the score properties (including the paper's one) without messing up the code addin

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-14 Thread Paolo Prete
Hi Stefano, your suggestion produces the script for every page, but it requires to manually add a property in the \paper scope. Instead, I would like to automatically set this property, and leave the user to set all the score properties (including the paper's one) without messing up the code addin

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-14 Thread Flaming Hakama by Elaine
> From: Stefano Troncaro > To: Paolo Prete > Cc: Aaron Hill , lilypond-user < > lilypond-user@gnu.org> > Date: Sat, 14 Dec 2019 19:13:43 -0300 > Subject: Re: A Javascript test code for modifying ties and slurs with mouse > Hi Paolo, > > Since Aaron's svg-sc

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-14 Thread Flaming Hakama by Elaine
> From: Paolo Pr > To: Urs Liska > Cc: lilypond-user > Date: Sat, 14 Dec 2019 02:59:58 +0100 > Subject: Re: A Javascript test code for modifying ties and slurs with mouse > Thanks Urs and Elaine for your appreciation. > > Note that the same algo I wrote with (relat

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-14 Thread Stefano Troncaro
Hi Paolo, Since Aaron's svg-script function creates an empty \markup, you can use the properties oddFooterMarkup and evenFooterMarkup of the \paper block to have your script embedded at the end of every page. Look: %%% \version "2.19.83" svg-script = #(define-sche

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-14 Thread Paolo Prete
Thanks Aaron, it did the trick. However, how can I make it work for multiple pages output? On Sat, Dec 14, 2019 at 4:26 AM Aaron Hill wrote: > On 2019-12-13 5:59 pm, Paolo Pr wrote: > > First of all, I need to add with Lilypond a tag to the svg > > file > > just before the ending tag

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-13 Thread Urs Liska
From: Paolo Pr >Date: Friday, December 13, 2019 at 8:38 PM >To: Carl Sorensen >Cc: Urs Liska , "lilypond-user@gnu.org" > >Subject: Re: A Javascript test code for modifying ties and slurs with >mouse > >Hello Carl, > >my script is not intended for replac

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-13 Thread Carl Sorensen
From: Paolo Pr Date: Friday, December 13, 2019 at 8:38 PM To: Carl Sorensen Cc: Urs Liska , "lilypond-user@gnu.org" Subject: Re: A Javascript test code for modifying ties and slurs with mouse Hello Carl, my script is not intended for replacing the automatic handling of slurs. I

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-13 Thread Paolo Pr
t; Thanks, > > > > Carl > > > > > > *From: *Urs Liska > *Date: *Friday, December 13, 2019 at 4:40 PM > *To: * > *Subject: *Re: A Javascript test code for modifying ties and slurs with > mouse > > > > I have to second Elaine's comment. > D

Re: A Javascript test code for modifying ties and slurs with mouse

2019-12-13 Thread Aaron Hill
On 2019-12-13 5:59 pm, Paolo Pr wrote: First of all, I need to add with Lilypond a tag to the svg file
just before the ending  tag  in the following way:

1)