-
Notifications
You must be signed in to change notification settings - Fork 18
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
Clarify and document specification regarding whitespace and new lines #5
Comments
The statement "All paragraph markers should be preceded by a single newline" would benefit greatly with the contrapositive also explicitly stated "Markers that are not paragraph markers should not be placed immediately following a newline." That is, paragraph tags are distinguishable from note and character styles because they begin with a new line. To this end, the example of \rq ... \rq shows the character style appearing on it's own line in the USFM code. I haven't fully perused the document for other character styles appearing in collumn 1 of a row of text, but this should NOT be put forward as a best method, whether or not it is prohibited. |
From the release notes: USFM 2.1 – April 2007 |
Jeff's issue does prompt a question about the right aligned poetry tag \qr which is mostly used just before \qs Selah \qs* In this context, the right alignment ought to style as follows:
Could forcing \qr to a new line in the USFM file prevent the first possibility? |
Updates have been made to the documentation for managing whitespace and performing whitespace normalization. |
@cmahte I think the following example in the USFM 3.0 spec https://ubsicap.github.io/usfm/about/syntax.html#newlines implies that your first suggestion above was rejected:
However, because the newline before the \f is counted as whitespace, the spec also had to add later under Handling Special Contexts:
(Seems that "could be removed" above should be "should be removed"?) Isn't this save-all section saying that the USFM 3.0 standard will accept ambiguous whitespace and then try to intelligently figure out what it should really mean? (I guess what it's really doing is saying that human readability of USFM3 trumps machine clarity.) Could this issue be reopened please @klassenjm ? BTW: It seems that the 3,5,7 reference is a typo? |
@cmahte Thinking about this more in light of my comment above, this would imply that \v markers should not be on new lines. I have seen Paratext output that puts "\p \v 2 Verse text..." on the same line, but I don't recall noticing that successive verses in the same paragraph stay on the same line. (That could lead to very long lines.) Maybe the only good (but probably too radical) solution would be to declare all newlines as insignificant whitespace and to pay more attention to trailing spaces on lines instead??? (Seems that could carry through to USX as well -- I haven't studied whitespace problems in USX in recent years.) |
It should also be noted that the following is also valid USFM for those translations with some verse tagged descriptive Psalm titles.
The translations in which Psalm 18 has just over two verses in the descriptive title are interesting cases.... |
Proposal
Details
In Paratext, using “Standard” editing view, every time you save a chapter Paratext will automatically standardize the new lines. In Unformatted view Paratext never alters the newlines present. It is therefore possible to produce files like (note \mt2):
Some people also want to be able to temporarily insert blank lines, for example, and want them to stay until they remove them. It is debatable whether this 'feature' is a good thing because it leaves data in a non-standard state and has the potential for other software processing the text to break.
Application Support Requirements
The text was updated successfully, but these errors were encountered: