-
Notifications
You must be signed in to change notification settings - Fork 43
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
better error handling on \n\n inside a syllable in gabc #1111
Comments
Should it not replace multiple whitespace (\t| |\n|\r)+ with a single blank space? |
With the exception of two line breaks in a row (which is treated as equivalent to |
Got it, thanks. |
Is it a problem to ignore any "special" character (under "space") in gabc ? |
I don't think it's a good idea to be over-zealous with this change. There's too much chance of breaking something outside gabc (present or future) that uses a control character for its operation. |
1-Most problems come from (\t| |\n|\r) as you state it. My problem was created the following way : I wanted to create a new version of Pange Lingua. I did start from a classical version, and used https://bbloomf.github.io/jgabc/transcriber.html to get the accentuated text and change the music, and got the problem with this result. It was difficult to find it. Sed ego non sum Lumen... |
What do you mean by "special character"? This is pretty unclear to me... What other special characters do you see? |
Good old special characters : U+0000 à U+001F On 05/19/2016 09:38 AM, Elie Roux wrote:
|
@rpspringuel It seems like {newline}{blank}{newline} is also treated as \par, so I think the pattern for replacement should be (\n|\r)(\t| |\n|\r)*. |
But can't somebody have in between and arbitrary TeX stuff, including \par, \n\n etc.? Changing that in any way would be IMNSHO undesirable? |
Maybe a good option would be to handle that on the TeX side, by just ignoring new lines... users who do not want this behavior could change it easily |
The |
Good idea yes |
While I didn't think about it, given that TeX automatically ignores blanks spaces at the beginning of a line, that does make sense. |
* commit '22e725b90f107583dfe9d51f7ec93a6e1852b8e5': Collapsed strings of whitespace that start with a newline to a single space. Fixes gregorio-project#1111.
* release-4.2: Fixing old bar spacing algorithm Collapsed strings of whitespace that start with a newline to a single space. Fixes gregorio-project#1111.
* release-4.2: Accepting corrected results Added a test for whitespace collapsing. Tests gregorio-project/gregorio#1111. New test to show interaction between mora shift and old bar spacing algorithm
gregorio could replace (\n|\r)+ with \n inside syllables when outputing GregorioTeX, see this thread
The text was updated successfully, but these errors were encountered: