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

controlling hyphen glyph for lyrics #542

Open
lemzwerg opened this issue Aug 16, 2024 · 3 comments
Open

controlling hyphen glyph for lyrics #542

lemzwerg opened this issue Aug 16, 2024 · 3 comments

Comments

@lemzwerg
Copy link
Contributor

AFAICS, MusicXML provides no possibility to control the hyphen between syllables of a word. There are two possibilities.

  • the hyphen is a glyph (with the usual text attributes plus a space-length attribute)
  • the hyphen is a dashed line (as an alternative to a line consisting of hyphen glyphs, with the usual attributes for dashed lines)

I suggest to add one or more elements to <defaults> for controlling the hyphen globally, and perhaps some attributes like color to <syllabic> – if the type is begin or middle the attributes could control the hyphen(s) after the syllable.

@lemzwerg
Copy link
Contributor Author

I missed the <distance> element for hyphens, thus a space-length attribute is not necessary.

@mscuthbert
Copy link
Contributor

Hi @lemzwerg -- would you mind rewriting the proposal to take into account <distance> and say what the proposal is here, or close the issue? Thanks!

@lemzwerg
Copy link
Contributor Author

OK, here it is.

A lyric hyphen can either be a series of (identical) glyphs or a dashed line. If it is the former, there should be a means to select the used glyph and control its appearance. If it is the latter, there should also be a means to control its appearance.

Currently, MusicXML only provides the <distance type="hyphen"> child within an <appearance> element to specify the distance between hyphens. I thus suggest the following.

  1. Extend the <appearance> element by adding a new child, say, <hyphen>, that allows the user to select a default glyph for the hyphen. It should come with the usual attributes for glyphs like font-size (but probably not color).
  2. Extend the <line-width> element by adding a new type hyphen to the line-width-type type to set the line width (i.e., the thickness) of a hyphen in case it is a dashed line.
  3. Extend the <distance> element by adding a new type hyphen-length to set the length of a hyphen in case it is a dashed line.
  4. Extend the <syllabic> element by adding attributes that control the appearance of the hyphen locally after the current syllable if its value either begin or middle. Possible attributes that come to my mind are
    a. color (to override the color of <lyric>)
    b. appearance, with possible values enforce (to make a hyphen always appear between two syllables even in tight typesetting situations) or suppress (to hide the hyphen at a specific place)

If case 1 is present, use a glyph for a hyphen. If cases 2 and/or 3 are present, use a dashed line. If there is a mix up between cases 1 to 3, let the application decide what to use.

An alternative to cases 2 and 3 is to extend my suggested case 1 by adding a type attribute so that the global hyphen setup – either as a glyph or as a dashed line – can be done within a single element (it would also have the benefit that defining a hyphen as both a glyph and a dashed line at the same time could be avoided). Handling the hyphen in <distance> would then be deprecated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants