Control of lyrics parameters?

• Nov 18, 2015 - 00:41

I am wondering if there is a way to control the spacing of the hyphens that MuseScore places between syllables in melismatic text.

I am editing a set of motets written in 4/2, with Latin texts. When a melismatic section is sung on the final syllable of a word, we use a baseline extender (which is continuous), but for intermediate syllables a series of hyphens is used instead. I find that in MuseScore these 'extender' hyphens between syllables are spaced quite far apart; too far, in fact, for the singer's eyes to track easily.
hyphen spacing.png
I would like to adjust the parameters so that the program will place more and more-closely-spaced hyphens between syllables, to make a better visual connection between the two parts of the word. Right now, the only way I have found to increase the number of hyphens printed is to increase the stretch of the music itself, and that often spreads the syllables so far apart that I'm no better off than I was beforehand.
hyphen spacing 2.png
Is there a user control built into the program that would allow me to modify the spacing of these hyphens, or is that a hard-coded parameter with which I would be best advised not to mess around?



My impression is that there is currently no user control - the maximum hyphen distance is hard coded into the programs as 16sp. However, it was done in such a way that it should be relatively straightforward to eventually add style options to control this. Similarly for other settings relating to extenders and hyphens, including the thickness of the lines, heigh of the hyphens, etc.

In reply to by Marc Sabatella

Thanks for the reply, Marc.

So, for the time being, I'm stuck with the default spacing, unless I want to start placing 'hard' hyphens manually under each note at each incidence? Hmmm....

Any chance one of you really smart guys could create that style option sometime in the recent future, maybe as a nightly? I'd really like to be able to improve the presentation of the lyrics in these motets, which I hope to have in publishable form by the end of the year.

In reply to by Shoichi

Thanks; what you're describing is entering 'hard' hyphens instead of relying on the program to set extender hyphens automatically. I can do that if I have to, but considering the number of times this occurs, and the fact that the 'stretch' of the music controlling the overall layout changes as the score and the parts are formatted during page make-up, doing it manually like that is not an attractive prospect....

Hi Recorder485,

Recently (hmm... well... more or less recently...), I took over dealing with lyric dash/melisma coding and added a few improvements, namely:

  1. Since 2.0.something, dashes and melismata are carried over to next system(s) if they cross a system end (in previous versions, the next system(s) lack any trace of either).
  2. Since 2.0.somethingelse, a minimum and a maximum dash lengths have been introduced, allowing the dash to shrink if little room is available between syllables, without altering the 'normal' syllable and/or note spacing. If there is no room for even the minimum length, the dash is skipped altogether. At the same time, I added the repetition of the dash when syllables are very far apart.

    All these parameters (min/max dash length and max distance between multiple dashes) are hard coded and have been determined empirically.

  3. In the nightly version, I have recently added the configurability of min/max dash length and the option of either forcing it (forcing at least the min distance between the syllables) or skipping it (and reclaiming any remaining room between the syllables), if there is no room to fit even the min dash length. You may find details of this change at this issue and/or at this github pull request .

    These changes will only show up in version 2.1 (not any earlier, due to a change in the file structure, which we try to keep constant across all releases of the same major version).

There has been some improvement in dash management, but of course there is room for improvement.

Changing the hard-coded max. distance between dash repetitions into a user-controllable parameter would be not a big change. However, it is important to understand that:

A) it will be a score-wide parameter, applying to all the 'dashed' syllables of a score, not a parameter of each individual syllable.

B) It will not force a fixed distance between the repetitions, but only a range of variation. An example using the currently hard-coded 16 sp value:

B1) If two syllables are 31.9sp apart, one dash in the middle will be enough to make two gaps of 15.95sp, below the max distance.
B2) If two syllables are 32.1sp apart, one dash will make two gaps of 16.05sp, above the max distance; two dashes are required, which would create three gaps of 10.7sp each.

Changing the max distance would change the range of variability, but would not make all distances between dashes equal, as the distance between consecutive syllables can be any value and only an integer number of dashes can be inserted between them.

If this is OK, the additional parameter can be implemented (to appear in nightly and to be released in ver. 2.1) with no great fuss.



In reply to by Miwarre

So sorry about my delay in replying; my ISP suffered a major break in the fibre-optic cable and I was off-line until early this morning.

In any event, it's great that you're doing this, and what you've described is precisely the sort of control I am looking for. I would not want to set dashes at hard intervals, since that would inevitably cause problems as the score and parts are reformatted multiple times during page make-up. I also would definitely want the control parameter to be score-wide (and, I presume that it would also link to the parts).

Can you let me know when your implementation would be available as a nightly, and remind me how to find and download that?


PS--I just remembered you asking me in the traverso thread about my user name, and realised I had not replied. No, the '485' has nothing to do with pitch; I play standard 440 instruments most of the time, and have only a single 415 (an alto) which I use rarely. The '485' is simply the house number of my home/office; my way to set up the user-name 'Recorder' with a number I can easily remember. ;o)

In reply to by Recorder485

@ Recorder485: don't feel sorry! There is plenty to work on while a topic is being sorted out! Luckily you are connected again.

We have a deal, then. For better tracking, I have created a "pro-forma" feature request in the issue tracker: #88171: Add dash max distance to lyrics parameters.

I'll post here and there when the fix will be pushed to github. This will not mean that the fix will be immediately integrated in the nightly, but you will be able to track the progress.

Cheers, M.

P.S.: before switching to viola da gamba, I used to play recorder too and I also had mostly 440 instruments, with the exception of an alto at 415 (well, I also had a "flauto di voce", a tenor in D, at 415, bit I never had a real occasion to use it!). Patterns tend to repeat, apparently.

In reply to by Miwarre

I will certainly welcome the ability to reduce the maximum distance between dashes in a hyphenated lyric.

For me, the current MuseScore default always sets the dashes too far apart. As an example, here are two images from a piece which I am transcribing:
a) Oxford University Press 1936 edition (using 5 dashes)
b) MuseScore 2.0.2 (using 2 dashes)


Thanks for all the improvements!

In reply to by Miwarre

MuseScore 2.1

I have hunted around for a way to configure the spacing between lyric dashes, but I can't find it in 2.1. Did this feature actually get incorporated before the 2.1 release?

The place I expected to see it is with other Lyrics parameters, as "Lyrics dash spacing":

Thanks for any clarification.

In reply to by DanielR

I see that the changes required for this seem (mostly) to be in the 2.1 code - even if the dialog boxes aren't. Is it possible to change these parameters in 2.1 in some manual fashion (such as with an editor a the mscx file)?

In reply to by Marc Sabatella

Perhaps the default value could be reduced a bit? I had a look in "Behind Bars" (p.448 - Hyphen spacing), and although Gould doesn't mention a particular separation distance, she does say to "place hyphens at regular intervals between widely spaced syllables", and the examples she gives appear to support a much shorter distance than MuseScore uses.

In reply to by Marc Sabatella

I cannot compile it even with a fresh clone and fresh Qt download of 5.8 on ubuntu 16.04. It is very frustrating. Stops here BTW:

[ 75%] Building CXX object mscore/CMakeFiles/mscore.dir/navigator.cpp.o
cc1plus: warning: /home/djk/mscore-2/build.release/all.h.gch: not used because `__STRICT_ANSI__' not defined [-Winvalid-pch]
In file included from /home/djk/mscore-2/mscore/musescore.cpp:109:0:
/home/djk/mscore-2/mscore/startcenter.h:20:20: fatal error: QWebView: No such file or directory

But for what it is worth (and especially for some of the early stuff that I transcribe using 'tick' bar lines), the parameter should be nearer 4 or even 2.

In reply to by DanielR

I, too, agree that the dashes in the latest example are too close, which is yet another argument in favour of creating a user-configurable parameter for this element. However, until that happens, the optimum dash spacing should be set at no more than 12 and no less than 8 (the default spacing in 2.0.1--the build we use for 'stability' reasons--was set at 16).

Since I started this thread three-ish years ago, MuseScore contributor schepers compiled a custom build for me with the spacing hard-coded at 8, and we have been using it ever since. For those interested, please see and following.

In reply to by Recorder485

So that I’ll find this post again when I search for it in a couple of days:

8sp distance doesn’t look too shabby. And it should not be too difficult to move the hyphens half of the (fixed) 8/16sp or (in 3.0) configured distance to the left and add another one, so that the first and last hyphen will have only half the distance from the syllable text (as in the OUP edition above), could be a bit tricky for the cases with only one hyphen currently rendered, but doable.

@Jojo-Schmitz: do you think something like that could land in 3.0? Just, as a general rule, Sil{½x}-{x}-{x}-{x}-{½x}be distance, where x is the one configured.

In reply to by mirabilos

It looks good, pretty much like the custom build of 2.0.1 we've been using for a few years now. Question: does your PR provide a 'hard-coded' tweak, or does it provide a way to control the dash spacing parameter directly in the UI? For 2.0.1, it turned out to be simple enough to change the basic parameter from 16sp to 8sp in the code; making it a compatible user-configurable parameter was the part that never got solved. I've been a bit out of the development loop for a while (too much to do; not enough time to do it all), so please excuse me if the answer to that is obvious to everyone except me.

In reply to by Recorder485

I made two patches.

The one was just for my 2.x builds that halves the distance between two hyphens from 16sp to 8sp just like in your build.

The other was for 2.x and 3.x both and takes the distance between hyphens (either the fixed one in 2.x or the configurable one in 3.x) and halves it for the distance between syllable and hyphen. That’s the new one, the one I submitted.

I believe it does an impressive amount of increasing legibility even with 16sp distance (8sp is still better).

I’ll upload a 2.x build with the patches to Debian experimental (not unstable, which contains a much less patched one) in a few minutes.

In reply to by mirabilos

Okay, so if I understand you correctly, we're still not at the point where the lyrics-dash parameter can be modified by the users from the UI. It's all well and good to reduce the hard-coded spacing from 16sp t0 8sp, but the ultimate goal should be to offer control of this parameter to the users. Visual elements are always somewhat subjective, and what I as an editor find acceptable might offend other editors with different priorities.

Do you still have an unanswered question? Please log in first to post your question.