Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unison notes on the same syllable should by default not allow line breaks #1504

Closed
jperon opened this issue Jan 23, 2021 · 16 comments
Closed
Assignees
Labels
Milestone

Comments

@jperon
Copy link
Contributor

jperon commented Jan 23, 2021

Here is a example illustrating the problem:

Screenshot_20210123_211723

The actual behaviour is that this code:

%%
(hff) (::)

gives following output from gregorio:

% File generated by gregorio 5.2.1
\GregorioTeXAPIVersion{5.2.1}%
\GreBeginHeaders %
\GreEndHeaders %
\GreBeginScore{fdfb0937e15f22d0431f6d53899bc3d9b4e7544f}{10}{8}{0}{0}{}{4}{\GreInitialClefPosition{3}{0}}%
\GreSetLargestClef{c}{3}{3}{c}{0}{3}%
\GreScoreOpening{%
}{%
\GreSetInitialClef{c}{3}{3}{c}{0}{3}{1}%
}{%
}{\GreSyllable}{\GreSetNoFirstSyllableText}{}{\GreUnstyled}{1}{\GreSetNextSyllable{}{}{}{}{}}{}{15}{}{%
\GreSyllableNoteCount{3}%
\GreGlyph{\GreCPFlexusLongqueueTwoNothing}{10}{\GreNextCustos{8}{}}{1}%
{%
\GreGlyphHeights{10}{8}%
}{}{}%
\GreEndOfElement{0}{0}{2}%
\GreGlyph{\GreCPPunctum}{8}{\GreNextCustos{9}{}}{0}%
{%
\GreGlyphHeights{8}{8}%
}{}{}%
}%
%
\GreFinalDivisioFinalis{%
}%
\GreEndScore %
\endinput %

IMO, the last \GreEndOfElement{0}{0}{2}% should be by default \GreEndOfElement{0}{1}{2}%, so that the two notes stay on the same line.

In fact, I think that, within a melism, any breakable space should be explicit (which was the behaviour "once upon a time", but I don't remember when this changed): for example, in hGFgv, the gv should stay with the hGF, unless a cut is added: hGF/gv. Perhaps it's more debattable when notes aren't unison ones, but (IMO again) it's really expected for unison ones.

jperon added a commit to jperon/gregorio that referenced this issue Jan 26, 2021
This is a proposal to fix gregorio-project#1504 if there is no objection. It restores the old behavior: line breaks are allowed between neumatic elements only if a `/` is typed.
@rpspringuel
Copy link
Contributor

Have you tried changing \gresetunbreakablesyllablenotes to a number higher than 4 (the default)? This was changed in response to #1044 which gave the user control over just how many notes stayed together.

@jperon
Copy link
Contributor Author

jperon commented Jan 26, 2021

I wasn’t aware of this macro. That said, the case I’m highlighting isn’t IMO a matter of number, but rather a matter of elements that should have an unity: whatever be the number of notes in a melisma:

  • the two notes of a distropha and the three ones of a tristropha (be this distinction meaningful or not isn’t the point : it’s a fact it exists in practice) should stay together without explicit !/ (that moreover make the gabc code quite dirty), event when typed as a sequence of punctums (as in 1960 books) ;
  • a climacus resupinus (hGFgv mentionned before) shouldn’t be divided by default.

The proposal in #1505 would make an explicit / necessary between neumatic elements, but:

  • it’s already necessary in many cases anyway;
  • even when it’s not necessary with the current behavior, it would be cleaner than, for example, having to type h!/hh!/h!/h to ensure "a distropha, then a breakable cut (implicit), then a tristropha" (which may occur in the middle of a melisma, thus not covered by \gresetunbreakablesyllablenotes).

This proposal wouldn’t even make \gresetunbreakablesyllablenotes useless: it would (as it’s the case now) ensure not too few notes before and after a line break.

@rpspringuel
Copy link
Contributor

I'm still not entirely sure I understand the issue. Can you throw together some test cases (preferably in the test repository) which show the problem when your fix is not applied and are correct when it is?

@henryso
Copy link
Contributor

henryso commented Feb 3, 2021

I think this is a matter of style. The old way was inconsistent, so the decision was made that breaks would be allowed between elements regularly unless they are "glued" together by non-breaking spaces. This would allow the scores to be placed in any width containers with predictable line breaks (like putting a paragraph into a document). Then the engraver would tweak the score as necessary to deal with spacing, etc. You can argue the opposite probably as vehemently and correctly, so this is probably something where the default behavior is configurable.

(This is, of course, just my opinion)

@rpspringuel
Copy link
Contributor

Is it just me, or is #1473 making a complaint about almost the exact opposite problem?

@eschwab
Copy link
Contributor

eschwab commented Feb 9, 2021

It would seem so. I'm in agreement with @henryso's comment above. Glue and breaks can be added as the engraver sees fit.

@fiat96
Copy link

fiat96 commented Feb 10, 2021

Apologies in advance for the long post. As one who has come across this line breaking issue all too often myself, I thought I'd put my two cents out there.

Any time two neums (or a neum and a single note) meet at the same note on the same syllable, there should not be a line break. Several instances have slipped into my scores in the past, and they're always pointed out to me as errors.

This is because, according to the Solesmes method, the two notes meeting at the same pitch form a pressus (or oriscus) and are blended together. If these notes are split by a line break, the singers may fail to recognize the pressus in time, and familiar tunes and patterns will look weird. Writing in !/ at every possible bad line break is cumbersome. Thus, I would say that neums like ghhg should be unbreakable, as should jvIHhg or ghh.

Some examples from Gregobase's precompiled images:

The very first Tract I clicked on has this problem on the very first line break:
image

The last note of the first line and the first note of the second line form a pressus here, and should be blended. Breaking a pressus across lines is never done, to my knowledge, in Solesmes printings.

Here's another:
image

This is a very common type of ending for tracts, and, for one who sings liturgical chant daily, the line break at the pressus just doesn't work.

Other notes:

An exception could be made for a distropha or tristropha, which cannot form a pressus with another neum. A line break could be allowed in ggggh or fggg. While a marked ictus on the second note also breaks a pressus, I think a line break there would still be undesirable. (hgg'f)

The issue in #1473, on the other hand, is that the following long neum was rendered unbreakable:
(gfHHhvFEfHHh)
I think this is the result of a desirable implementation, as I have commented there.

@fiat96
Copy link

fiat96 commented Feb 21, 2021

In summary, then, I would like to propose that Gregorio forbid a line break between two consecutive notes that are:

  • on the same pitch,
  • within the same one syllable, and
  • not separated by a bar.

I do not see any such line breaks in my liturgical books.

@henryso
Copy link
Contributor

henryso commented Mar 2, 2021

If we can get agreement on this set of rules, I can try to implement it, but this will be a major version update, and will happen after TeXLive 2021.

@jperon
Copy link
Contributor Author

jperon commented Mar 2, 2021

Sorry for my silence: I’m quite busy for now, and didn’t find time to reply to @rpspringuel.
I’d agree with @fiat96’s proposal.

@henryso
Copy link
Contributor

henryso commented Mar 13, 2021

Ok, any objections to @fiat96's proposal? I'll start working on this for 7.0 if not.

@henryso henryso self-assigned this Mar 13, 2021
@henryso henryso added this to the 7.0.0 milestone Mar 13, 2021
@fiat96
Copy link

fiat96 commented Mar 14, 2021

Parenthetically...

I mentioned earlier that I didn't see any line breaks like those condemned by my proposal in the liturgical books. I spotted one yesterday in the Liber Usualis for Palm Sunday's Gradual, so I felt conscience-bound to mention it:
image

It's actually a rather unique neum anyway, since the two notes in question, being immediately preceded by a note with an ictus, don't form a pressus. I still hold to my proposal, since rare cases like these could be marked with a break if the typesetter desires.

@henryso
Copy link
Contributor

henryso commented Mar 14, 2021

I think if the vast majority (or even just the majority) of cases is to keep them together, then I don't disagree with you.

@henryso
Copy link
Contributor

henryso commented May 24, 2021

I tried implementing this three ways and nixed two of them because I didn't like how they ended up (the first try injected new elements and the second try injected non-breaking spaces between the glyphs). This final implementation seems satisfactory as it only alters the interpretation of the data structures and is configurable from TeX. It will default to breakable unison notes to maintain backwards compatibility, but can be set to unbreakable with \setunisonbreakbehavior{unbreakable}

@henryso
Copy link
Contributor

henryso commented Jul 10, 2021

@fiat96 @jperon I've merged the changes into the develop branch. The behavior is controlled by \gresetunisonbreakbehavior{breakable} or \gresetunisonbreakbehavior{unbreakable}, with the former being the default for better backwards compatibility. Please try it out if you can and let me know.

@henryso henryso added C TeX and removed needinfo labels Jul 13, 2021
@henryso
Copy link
Contributor

henryso commented Jul 13, 2021

Closing this since it's been merged. Please re-open if you find bugs (or report a new bug, whatever works).

@henryso henryso closed this as completed Jul 13, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants