\offset Y-offset (was: Distance of a grob from its reference point)

2020-01-19 Thread Paolo Prete
Hello Aaron, sorry for the (a bit) late reply. I'm looking at your code and I don't understand what is it intended to do. You write: "% Test with bracket that is positioned by Y-offset." but from what I see, the bracket is positioned by both outside-staff-padding and y-offset inside \shiftOttavaB

Re: Distance of a grob from its reference point

2020-01-17 Thread Paolo Prete
On Fri, Jan 17, 2020 at 11:08 PM Aaron Hill wrote: > On 2020-01-17 4:34 am, Paolo Prete wrote: > > I said (and I confirm) that *\offset Y-offset is broken*. This command > > should be blacklisted, given that it leads to random results. > > That's all. > > I believe I have demonstrated not only th

Re: Distance of a grob from its reference point

2020-01-17 Thread Aaron Hill
On 2020-01-17 4:34 am, Paolo Prete wrote: I said (and I confirm) that *\offset Y-offset is broken*. This command should be blacklisted, given that it leads to random results. That's all. I believe I have demonstrated not only that \offset Y-offset is working properly but how it can be used in

Re: Distance of a grob from its reference point

2020-01-17 Thread Paolo Prete
On Fri, Jan 17, 2020 at 3:33 AM Aaron Hill wrote: > On 2020-01-16 4:01 pm, Paolo Prete wrote: > > This gives a clearer overview, thanks, but I would not use it, even if > > it > > produces the wanted result. > > Sorry if I implied otherwise, but I thought I was clear that this code > was not inte

Re: Distance of a grob from its reference point

2020-01-16 Thread Aaron Hill
On 2020-01-16 4:01 pm, Paolo Prete wrote: This gives a clearer overview, thanks, but I would not use it, even if it produces the wanted result. Sorry if I implied otherwise, but I thought I was clear that this code was not intended for practical use. This is only test code to demonstrate th

Re: Distance of a grob from its reference point

2020-01-16 Thread Paolo Prete
On Fri, Jan 17, 2020 at 12:31 AM Aaron Hill wrote: > > This time, you omitted the overrides to prevent padding and > staff-padding from influencing the test: > > \version "2.19.45" > notes = \fixed c''' { \ottava 1 f4 4 4 \ottava 0 f, } > > { >% Make sure these properties do not influen

Re: Distance of a grob from its reference point

2020-01-16 Thread Aaron Hill
On 2020-01-16 2:43 pm, Paolo Prete wrote: On Thu, Jan 16, 2020 at 11:35 PM Aaron Hill wrote: You forgot to \revert outside-staff-padding *before* applying extra-offset. Right, But even with \revert, the issue remains, because in any case the value of 0.56 for outside-staff-padding doesn'

Re: Distance of a grob from its reference point

2020-01-16 Thread Paolo Prete
On Thu, Jan 16, 2020 at 11:35 PM Aaron Hill wrote: > > > You forgot to \revert outside-staff-padding *before* applying > extra-offset. > > Right, But even with \revert, the issue remains, because in any case the value of 0.56 for outside-staff-padding doesn't produce a shift. See: %%

Re: Distance of a grob from its reference point

2020-01-16 Thread Thomas Morley
Am Do., 16. Jan. 2020 um 23:12 Uhr schrieb David Nalesnik : > > On Thu, Jan 16, 2020 at 3:42 PM David Nalesnik > wrote: > > > > Hi Robin, > > > > On Thu, Jan 16, 2020 at 1:02 PM Robin Bannister wrote: > > > > > > Paolo Prete wrote: > > > > > > > This is *precious* info. Please, can you tell/conf

Re: Distance of a grob from its reference point

2020-01-16 Thread Aaron Hill
On 2020-01-16 2:09 pm, Paolo Prete wrote: I'm sorry to say that I made additional tests and the +0.46 method doesn't seem to work. You can check here: %% \version "2.19.45" { \override Staff.OttavaBracket.outside-staff-padding = #0 \ottava #1 f''' f''' f''' \ottava #0 f'

Re: Distance of a grob from its reference point

2020-01-16 Thread Paolo Prete
On Thu, Jan 16, 2020 at 11:09 PM Paolo Prete wrote: > > % > > 0.56 s exactly the quantity corresponding to extra-offset to 0.1. But if > you produce a SVG file, and open it with a text editor, you will see three > pairs of coordinates: > > (first bracket) > > (second bracke

Re: Distance of a grob from its reference point

2020-01-16 Thread David Nalesnik
On Thu, Jan 16, 2020 at 3:42 PM David Nalesnik wrote: > > Hi Robin, > > On Thu, Jan 16, 2020 at 1:02 PM Robin Bannister wrote: > > > > Paolo Prete wrote: > > > > > This is *precious* info. Please, can you tell/confirm if > > > > > > 1) you are referring to \offset command ? > > > > No. That wou

Re: Distance of a grob from its reference point

2020-01-16 Thread Paolo Prete
Hi Robin, On Thu, Jan 16, 2020 at 10:05 PM Robin Bannister wrote: > Paolo Prete wrote: > > > And I really thank you. Offsetting brackets is a *very*, *very* important > > feature in professional music engraving. > > You're welcome. I'm sorry to say that I made additional tests and the +0.46

Re: Distance of a grob from its reference point

2020-01-16 Thread David Nalesnik
Hi Robin, On Thu, Jan 16, 2020 at 1:02 PM Robin Bannister wrote: > > Paolo Prete wrote: > > > This is *precious* info. Please, can you tell/confirm if > > > > 1) you are referring to \offset command ? > > No. That would be premature in this case. > > > > 2) is it applicable as a replacement for

Re: Distance of a grob from its reference point

2020-01-16 Thread Robin Bannister
Paolo Prete wrote: And I really thank you. Offsetting brackets is a *very*, *very* important feature in professional music engraving. You're welcome. I hope you don't run foul of the disadvantages too soon. See Kieren's last comment in https://lists.gnu.org/archive/html/lilypond-user/2020-01/

Re: Distance of a grob from its reference point

2020-01-16 Thread Paolo Prete
On Thu, Jan 16, 2020 at 8:01 PM Robin Bannister wrote: > Paolo Prete wrote: > > So this 0.46 is just for outside-staff-padding. > And I really thank you. Offsetting brackets is a *very*, *very* important feature in professional music engraving. Best, Paolo

Re: Distance of a grob from its reference point

2020-01-16 Thread Paolo Prete
On Thu, Jan 16, 2020 at 7:22 PM Carl Sorensen wrote: > My testing found that \offset didn’t work with outside-staff-padding for > OttavaBracket grobs. > That's great, because with this method the user is not forced to use a ruler. Then, the best one. I just tested it and now we can say that, in

Re: Distance of a grob from its reference point

2020-01-16 Thread Robin Bannister
Paolo Prete wrote: This is *precious* info. Please, can you tell/confirm if 1) you are referring to \offset command ? No. That would be premature in this case. 2) is it applicable as a replacement for "\offset Y-offset" for *every* grob that support Y-offset ? Well, I have trouble fol

Re: Distance of a grob from its reference point

2020-01-16 Thread Aaron Hill
On 2020-01-16 8:46 am, Carl Sorensen wrote: On 1/16/20, 9:34 AM, "Robin Bannister" wrote: 3) make outside-staff-padding 0.46 more than needed vertical shift e.g. 2.46 Could you just \offset outside-staff-padding by 2? Unfortunately, no. outside-staff-padding does not have a specific

Re: Distance of a grob from its reference point

2020-01-16 Thread Carl Sorensen
From: Paolo Prete Date: Thursday, January 16, 2020 at 10:24 AM To: Robin Bannister Cc: Michael Gerdau , Lilypond-User Mailing List , Carl Sorensen Subject: Re: Distance of a grob from its reference point On Thu, Jan 16, 2020 at 5:33 PM Robin Bannister mailto:r...@dabble.ch>> wrote

Re: Distance of a grob from its reference point

2020-01-16 Thread Paolo Prete
On Thu, Jan 16, 2020 at 5:33 PM Robin Bannister wrote: > OR > > 3) make outside-staff-padding 0.46 more than needed vertical shift > e.g. 2.46 > > Cheers, Robin > This is *precious* info. Please, can you tell/confirm if 1) you are referring to \offset command ? 2) is it applicable as a

Re: Distance of a grob from its reference point

2020-01-16 Thread Carl Sorensen
On 1/16/20, 9:34 AM, "Robin Bannister" wrote: Paolo Prete wrote: > I simply wanted to understand how to offset a bracket. > And the conclusion is: avoid \offset + X/Y-offset and use > > 1) extra-offset (if you don't need automatic collision-avoidance) > > OR

Re: Distance of a grob from its reference point

2020-01-16 Thread Robin Bannister
Paolo Prete wrote: I simply wanted to understand how to offset a bracket. And the conclusion is: avoid \offset + X/Y-offset and use 1) extra-offset (if you don't need automatic collision-avoidance) OR 2) \override X/Y-offset with a ruler (if you need automatic collision-avoidance) OR 3) m

Re: Distance of a grob from its reference point

2020-01-16 Thread Paolo Prete
On Thu, Jan 16, 2020 at 11:45 AM Michael Gerdau wrote: > > > FWIW: Prior to reading this thread I wasn't even aware, that \offset > might not do what I want in all situations. I use it occasionally and > like it - works for me. > > Claiming it is completely broken seems way over the top to me. >

Re: Distance of a grob from its reference point

2020-01-16 Thread Michael Gerdau
Dear Paolo, > Yes, but, it's necessary too to add a *warning* on the Lilypond output. > This is much more clear for the user than the documentation. while you correctly point out that \offset sometimes leads to random/unpredicted values it quite often gives the expected result. At least for me.

Re: Distance of a grob from its reference point

2020-01-15 Thread Paolo Prete
On Thu, Jan 16, 2020 at 1:16 AM Aaron Hill wrote: > On 2020-01-15 3:59 pm, Paolo Prete wrote > > If you are pushing things by small amounts akin to font kerning, then > collisions are unlikely and extra-offset is often the right tool for the > job. > "If you are pushing things by small amounts a

Re: Distance of a grob from its reference point

2020-01-15 Thread Paolo Prete
On Thu, Jan 16, 2020 at 1:31 AM Carl Sorensen wrote: > > > It may be desirable, but it’s not **necessary** to add a warning. At > this point, I don’t think we have the infrastructure to add the warning. > I did not know that. I thought that such a modification was a one-line change.

Re: Distance of a grob from its reference point

2020-01-15 Thread Carl Sorensen
Paolo, Please don’t top-post on this list. Users are expected to interleave their responses. Please see how other users do it. From: Paolo Prete Date: Wednesday, January 15, 2020 at 5:15 PM To: Carl Sorensen Cc: Lilypond-User Mailing List Subject: Re: Distance of a grob from its reference

Re: Distance of a grob from its reference point

2020-01-15 Thread Aaron Hill
On 2020-01-15 3:59 pm, Paolo Prete wrote: Hi Aaron. It's not Y-offset that has not to be used. It's the combination \offset + Y-offset. \override SomeGrob.Y-offset can be used (with a ruler, in an uncomfortably way) \offset Y-offset is nonsense. See my reply to Carl, and his reply to me.

Re: Distance of a grob from its reference point

2020-01-15 Thread Paolo Prete
*To: *Carl Sorensen > *Cc: *Lilypond-User Mailing List > *Subject: *Re: Distance of a grob from its reference point > > > > Thanks to you Carl. > > > > Now, given that it's nonsense to offset an unknown value, I would remove > this property from the offset co

Re: Distance of a grob from its reference point

2020-01-15 Thread Carl Sorensen
From: Paolo Prete Date: Wednesday, January 15, 2020 at 4:45 PM To: Carl Sorensen Cc: Lilypond-User Mailing List Subject: Re: Distance of a grob from its reference point Thanks to you Carl. Now, given that it's nonsense to offset an unknown value, I would remove this property fro

Re: Distance of a grob from its reference point

2020-01-15 Thread Paolo Prete
Hi Aaron. It's not Y-offset that has not to be used. It's the combination \offset + Y-offset. \override SomeGrob.Y-offset can be used (with a ruler, in an uncomfortably way) \offset Y-offset is nonsense. See my reply to Carl, and his reply to me. HTH Paolo On Thu, Jan 16, 2020 at 12:46 AM Aa

Re: Distance of a grob from its reference point

2020-01-15 Thread Aaron Hill
On 2020-01-15 1:57 pm, Paolo Prete wrote: I quote Carl's words: "So offset applies to the *estimated* position, and then the spacing engine works on the offset+estimated postion and ends up putting things where it thinks they belong" I checked that with the examples made before and it seems

Re: Distance of a grob from its reference point

2020-01-15 Thread Paolo Prete
pond-User Mailing List > *Subject: *Re: Distance of a grob from its reference point > > > > I don't mean that with *broken*. I mean that it's unusable, given that the > values you put inside this function don't correspond to anything that you > can measure. Th

Re: Distance of a grob from its reference point

2020-01-15 Thread Carl Sorensen
From: Paolo Prete Date: Wednesday, January 15, 2020 at 4:16 PM To: Carl Sorensen Cc: Lilypond-User Mailing List Subject: Re: Distance of a grob from its reference point I don't mean that with *broken*. I mean that it's unusable, given that the values you put inside this func

Re: Distance of a grob from its reference point

2020-01-15 Thread Paolo Prete
day, January 15, 2020 at 2:30 PM > *To: *Carl Sorensen > *Cc: *Lilypond-User Mailing List > *Subject: *Re: Distance of a grob from its reference point > > > > Then, do you agree that this causes that the \offset command is broken at > least for the X/Y-offset properties of

Re: Distance of a grob from its reference point

2020-01-15 Thread Carl Sorensen
From: Paolo Prete Date: Wednesday, January 15, 2020 at 2:30 PM To: Carl Sorensen Cc: Lilypond-User Mailing List Subject: Re: Distance of a grob from its reference point Then, do you agree that this causes that the \offset command is broken at least for the X/Y-offset properties of any grob

Re: Distance of a grob from its reference point

2020-01-15 Thread Paolo Prete
In other words, this means: "if you are lucky enough that the position estimated by Lilypond is the same that you have in mind, offset will offset to the quantity that you want. Otherwise it will led to improper placement (because it will mix the value that it has in mind, with the value that you h

Re: Distance of a grob from its reference point

2020-01-15 Thread Paolo Prete
I quote Carl's words: "So offset applies to the *estimated* position, and then the spacing engine works on the offset+estimated postion and ends up putting things where it thinks they belong" I checked that with the examples made before and it seems absolutely true. Then: you have to offset an e

Re: Distance of a grob from its reference point

2020-01-15 Thread Aaron Hill
On 2020-01-15 1:21 pm, Paolo Prete wrote: Without a proper behavior of the "\offset" command you cannot do nor the automatic 2) placement, nor a fine tuning. What is "proper behavior" for \offset to you? It is my understanding \offset works precisely as documented, but that is a worthless me

Re: Distance of a grob from its reference point

2020-01-15 Thread Paolo Prete
ensen wrote: > > > > > *From: *Paolo Prete > *Date: *Tuesday, January 14, 2020 at 8:10 PM > *To: *Aaron Hill > *Cc: *Lilypond-User Mailing List > *Subject: *Re: Distance of a grob from its reference point > > > > > > > > > > I really can&#x

Re: Distance of a grob from its reference point

2020-01-15 Thread Paolo Prete
Hi Aaron, I apologize too if I'm going to use words that can appear a bit rude. This is only for making the goal clearer, and I state again that without your great help I could not do my editor. Now: there's a misunderstanding in your reply too. I'm not focusing on the *manual* tweaking. The oppos

Re: Distance of a grob from its reference point

2020-01-14 Thread Kieren MacMillan
Hi all, On Jan 14, 2020, at 10:50 PM, Aaron Hill wrote: > I very much need LilyPond to be able to make the smart decisions on my behalf. Me, too. > That is why I am trying to defend getting the automatic parts working better I think that’s an important goal. > I would disagree with the notion

Re: Distance of a grob from its reference point

2020-01-14 Thread Carl Sorensen
From: Paolo Prete Date: Tuesday, January 14, 2020 at 8:10 PM To: Aaron Hill Cc: Lilypond-User Mailing List Subject: Re: Distance of a grob from its reference point I really can't count how many times I had to to that in so many scores. And there's no way to do that automagical

Re: Distance of a grob from its reference point

2020-01-14 Thread Aaron Hill
On 2020-01-14 7:10 pm, Paolo Prete wrote: On Tue, Jan 14, 2020 at 9:08 PM Aaron Hill wrote: I am not connected to the world of modern notation, but I cannot envision any musical meaning for the exact vertical position of an OttavaBracket. This is not true. There are many and many cases in wh

Re: Distance of a grob from its reference point

2020-01-14 Thread Paolo Prete
On Tue, Jan 14, 2020 at 9:08 PM Aaron Hill wrote: > I am not connected to the world of modern notation, but I > cannot envision any musical meaning for the exact vertical position of > an OttavaBracket. This is not true. There are many and many cases in which you need to tune the position of

Re: Distance of a grob from its reference point

2020-01-14 Thread Paolo Prete
On Tue, Jan 14, 2020 at 10:10 PM kieren_macmillan kieren_macmillan < kieren_macmil...@sympatico.ca> wrote: > Hi Paolo (et al.), > > > Why do I need to move a grob? > > For the simple fact that any score, in order to have a * professional * > > appearance, needs HUNDREDS of these adjustments. > > E

Re: Distance of a grob from its reference point

2020-01-14 Thread kieren_macmillan kieren_macmillan
Hi Paolo (et al.), > Why do I need to move a grob? > For the simple fact that any score, in order to have a * professional * > appearance, needs HUNDREDS of these adjustments. > Even the simplest ones. I think we all agree on that. Now… At one end of a philosophical spectrum lies the point where

Re: Distance of a grob from its reference point

2020-01-14 Thread Paolo Prete
Sorry, broken link Here's the correct one: https://filebin.net/sy6z7b39fcounb5j > > I am a convinced open source developer and already 10 years ago I used > Lilypond to create my scores, because I wanted to avoid Finale, Sibelius > and other proprietary software (which I used before). In the e

Re: Distance of a grob from its reference point

2020-01-14 Thread Paolo Prete
Hi Aaron, thanks for the detailed reply. Why do I need to move a grob? For the simple fact that any score, in order to have a * professional * appearance, needs HUNDREDS of these adjustments. Even the simplest ones. I am a convinced open source developer and already 10 years ago I used Lilypond t

Re: Distance of a grob from its reference point

2020-01-14 Thread kieren_macmillan kieren_macmillan
Hi Aaron, > > My mind was a little blown by the result of changing that to > You and me both. Well, that at least makes me feel a little better. #miserylovescompany > > Hence the ability to offset (e.g.) an OttavaBracket precisely X staff > > spaces while still [re-]engaging the spacing engine i

Re: Distance of a grob from its reference point

2020-01-14 Thread Aaron Hill
On 2020-01-14 7:16 am, Kieren MacMillan wrote: My mind was a little blown by the result of changing that to \override $grob-path .before-line-breaking = #proc Doing so made it *deeply* and *immediately* clear that, despite being a serious power-user of Lilypond for almost twenty years, I kn

Re: Distance of a grob from its reference point

2020-01-14 Thread Kieren MacMillan
Hi Aaron, > If we borrow some of the underlying logic, we get the following: Wow… You are my patronus of late. =) > #{ \override $grob-path .after-line-breaking = #proc #}) My mind was a little blown by the result of changing that to \override $grob-path .before-line-breaking = #proc Do

Re: Distance of a grob from its reference point

2020-01-14 Thread Aaron Hill
On 2020-01-13 7:05 pm, Paolo Prete wrote: 1) its *calculated* distance from its reference point? (from what I see, the reference Y of an OttavaBracket is the middle line of the associated staff...) I tried ly:grob-staff-position (see the snippet below), but it doesn't seem to give this info (

Distance of a grob from its reference point

2020-01-13 Thread Paolo Prete
Hello. Is there a way to obtain, for a given grob 1) its *calculated* distance from its reference point? (from what I see, the reference Y of an OttavaBracket is the middle line of the associated staff...) I tried ly:grob-staff-position (see the snippet below), but it doesn't seem to give this inf