Open bel28kent opened 5 months ago
g
means groups
, and represents a group of line and page breaks for a particular page layout. The name of the group is arbitrary as long as it does not contain spaces (preferrably only letters, numbers, dash, underscore, period).
I have not fully implemented it yet, but the idea is that you can specify which group of LB/PB you want to use when rendering to graphical notation. original
is the group name for encoding the LB/PB of the source edition, but if you have multiple sources, each could be given a different group name.
When generating LB/PB directly for a digital score, it would depend on the physical dimensions for the layout, such as letter
or A4
, for example:
!!!LO:LB:g=letter
If two layout schemes are present for the same line break, it would look like this:
!!!LO:LB:g=letter, a4
The LB/PB positions could also be affected by the size of the music, so to set the breaks for a specific size, might be something like for 80% scaling for letter size (8.5"×11"):
!!LO:LB:g=letter-80
Currently all LB/PB groups are translated into MEI data, but the idea is to add a line such as:
!!!system-breaks: letter
And this would ignore all LB/PB that do not have the letter
group. And if the original line breaks should be used instead:
!!!system-breaks: original
So the name for system breaks is fairly flexible, and there are no standard names other than "original" for an unspecified single source edition. Probably for added system breaks, using the target page size and music size would be useful.
The names could be used in the future in collaboration with embedded verovio options, such as:
!!!verovio-letter: [a verovio option related to printing on letter-sized paper, such as setting the page height and width]
!!!verovio-a4: [a verovio option related to printing on A4 paper]
!!!verovio-original: [a verovio option related to printing in the source edition layout]
Okay. I have encoded as !!LO:LB:g=encoder
to make it clear that the line break has been added by the encoder and is not in the original edition. (OK to close this issue from my end.)
That sounds good. You only added one linebreak?
I added one linebreak at line 1774 in scriabin-op04.krn and at line 369 in scriabin-op09_no02.krn. The underlying reason in both cases is that the measures have long fioritura passages that in the original edition are broken across two systems. But I don't seem to be able to have a linebreak in the middle of a measure. So I will just put the fioritura on their own system and move the others down.
It would be useful to add a new feature to verovio to have "suggested" system breaks or "required" system breaks. Currently if you put one system break in a file, verovio will treat that as the only line break in the score (causing two systems for the score even if it is a very long score, when breaks encoded
option is used.
Maybe adding options such as breaks suggested
which would be a variant of breaks auto
would be useful in verovio: This would give a preference to line breaks encoded in the file, but ignore them if the music that is automatically typeset would be too crowded or empty if the suggested break were to be used.
Then adding an option such as breaks required
would be a hybrid variant between breaks auto
and breaks encoded
. The enocded breaks would always be done, but then automatic breaks would also be added to keep any line from getting too crowded. This feature would currently work, but a refinement in the current system would make it better: verovio currently does a one pass layout of automatic system breaks. The hybrid system would work better if there were a recursive auto breaking algorithm: you do a first pass of generating line breaks, and then go back to the most crowded/empty lines, and steal a measure from another line for lines that are too empty, or give a measure to another line if the current line is too crowded (but in both cases, this would require iterative application, where extra measures would migrate (potentially from the end of the first measure the the beginning of the last measure as is needed in J.S. Bach WTCI prelude).
I will think about adding an issue about this on the verovio repository, but perhaps when @lpugin wants to work on adding a more advanced line breaking algorithm.
Another way to deal with the cadenza using the breaks auto
option in verovio (it does not work with breaks encoded
, would be to add invislble barlines in the cadenza. In that way verovio can choose the best point in the cadenza to break the system and not have an overfilled line of music. This will not work currently if there are any line breaks present in the file at the moment (they are an implicit form of my idea of breaks suggested
option above.
Example using Scriabin op. 4:
**kern **kern **dynam
*M22/4yy *M22/4yy *
=163 =163 =163
*8ba * *
*cue *cue *
12BBBB- 12BBB- 12r .
*X8ba * *
12DnL 12A- 12B- 12dn\ 12fnL 12b- 12ffn\ .
12D-XJ 12A- 12B- 12d-X 12f-XJ 12b- 12ff-X .
12DnL 12A- 12B- 12dn\ 12fnL 12b- 12ffn\ .
12E- 12A- 12B- 12e- 12g- 12b- 12gg- .
12G-J 12B- 12g- 12b-J 12ddn 12bb- .
12FL 12B- 12f\ 12a-L 12dd 12aa-\ .
12F 12B- 12f 12a- 12dd 12aa- .
12F-XJ 12B- 12f-X 12gnJ 12dd 12ggn .
12FnL 12B- 12fn\ 12a-L 12dd 12aa-\ .
12G-J 12B- 12g- 12b- 12dd 12bb- .
*clefG2 * *
12B- 12dn 12b- 12dd-XJ 12ff 12ddd-X .
=- =- =-
12A-L 12d 12a- 12cc-L 12ff 12ccc-\ .
12A- 12d 12a- 12cc- 12ff 12ccc- .
12GnJ 12d 12gn 12b-J 12ff 12bb- .
12A-L 12d 12a- 12cc-L 12ff 12ccc-\ .
12B- 12dn 12b- 12dd-X 12ff 12ddd-X .
12d-XJ 12f 12dd-X 12ffJ 12aa- 12fff .
12c-L 12f 12cc- 12ee-L 12aa- 12eee-\ .
12B- 12f 12b- 12ddn 12aa- 12dddn .
* *8va *
12e-J 12a- 12ee- 12ggJ 12ccc- 12gggn .
=- =- =-
12e-L 12a- 12ee- 12ggL 12ccc- 12ggg\ .
12dn 12a- 12ddn 12ff 12ccc- 12fff .
12gJ 12b- 12ggn 12bb-J 12dddn 12bbb- .
12gL 12b- 12gg\ 12bb-L 12ddd 12bbb-\ .
12f 12b- 12ff 12aa- 12ddd 12aaa- .
12b-J 12ddn 12bb- 12ddd-XJ 12fff 12dddd-X .
12b-L 12ddn 12bb-\ 12ddd-XL 12fff 12dddd-X\ .
12a- 12dd 12aa- 12ccc- 12fff 12cccc- .
12ee-J 12eee- 12fffJ 12aaa- 12cccc- 12ffff .
=- =- =-
12ddL 12dddn\ 12fffL 12aaa- 12cccc- 12ffff\ .
12dd-X 12ddd-X 12dddn 12fff 12aaa- 12ddddn .
12cc-J 12ccc- 12dddJ 12fff 12aaa- 12dddd .
12b-L 12bb-\ 12ccc-L 12ddd 12fff 12cccc-\ .
12a- 12aa- 12ccc- 12ddd 12fff 12cccc- .
12g-XJ 12gg-X 12aa-J 12ccc- 12ddd 12aaa- .
12fL 12ff 12aa-L 12ccc- 12ddd 12aaa-\ .
12e- 12ee- 12ff 12aa- 12ccc- 12fff .
12dnJ 12ddn 12ffJ 12aa- 12ccc- 12fff .
12d-XL 12dd-X 12ddnL 12ff 12aa- 12ddd .
12c- 12cc- 12dd 12ff 12aa- 12ddd .
12B-J 12b- 12cc-J 12dd 12ff 12ccc- .
12A-L 12a- 12cc- 12ddn 12ff 12ccc- .
* *X8va *
12G-X 12g- 12a-L 12cc- 12ddn 12aa-\ .
*clefF4 * *
12FJ 12f 12a-J 12cc- 12dd 12aa- .
=- =- =-
12E-L 12e-\ 12fL 12a- 12cc- 12ff .
12Dn 12dn 12f 12a- 12cc- 12ff .
12D-XJ 12d-X 12dnJ 12f 12a- 12ddn .
12C-L 12c-\ 12dL 12f 12a- 12dd .
12BB- 12B- 12c- 12d 12f 12cc- .
12AA-J 12A- 12c-J 12d 12f 12cc- .
12GG-L 12G- 12A-L 12c- 12dn 12a- .
12FF 12F 12A- 12c- 12d 12a- .
12EE-J 12E- 12FJ 12A- 12c- 12f .
* *clefF4 *
=- =- =-
12DDnL 12Dn 12FL 12A- 12c- 12f\ .
12DD-X 12D-X 12Dn 12F 12A- 12dn .
12CC-J 12C- 12DJ 12F 12A- 12d .
12BBB-L 12BB- 12DL 12F 12A- 12d\ .
12CC- 12C- 12D 12F 12A- 12d .
12BBB-J 12BB- 12DJ 12F 12A- 12d .
12CC-L 12C- 12DL 12F 12A- 12d\ .
12BBB- 12BB- 12D 12F 12A- 12d .
12CC-J 12C- 12DJ 12F 12A- 12d .
12BBB-L 12BB- 12DL 12F 12A- 12d\ .
12CC- 12C- 12D 12F 12A- 12d .
12BBB-J 12BB- 12DJ 12F 12A- 12d .
*Xcue *Xcue *
* *clefG2 *
=164 =164 =164
*- *- *-
*M22/4yy
means it is an interpreted time signature (and is hidden in the notation). It would be good to come up with a "unmetered" tandem interpretation or time signature, since this is not a real 22/4 time signature (i.e., it is an unmetered measure). Then when doing some sort of metric analysis, this measure would be ignored. As a tandem interpretation may be *Xmeter
and *meter
at the end of the cadenza.
I added various invisible barlines in measure 163 which allows nicer dynamic layout (but you cannot have original linebreaks encoded if using this method):
After posting the response a couple of days ago I realized that I could use invisible bar lines. I then marked these as original since they do match the score.
Here are examples for Op 4 and Op 9, No 2.
For Op 9, No 2, the line breaks are correct though this is now creating a problem with the beaming and note placement. I will post an issue about it in Mysterium repo at some point.
What should take the place of
g=original
when the line break is one that I have added and not in the original edition?