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

code block break / export is confused (use br, or use pre - do not use both!) #5

Open
cmsmcq opened this issue Oct 25, 2013 · 1 comment

Comments

@cmsmcq
Copy link

cmsmcq commented Oct 25, 2013

The styling widget for "code" appears to be intended for marking blocks of code.

In the HTML exported by dhwriter, the code block as a whole is tagged as pre, which is pretty much what one would expect. But instead of writing the code block out with a newline at the end of each line of the input, it's written out with a br element (and no newline) at the end of each input line. This would be OK (though it produces HTML that's hard to read), but the export procedure also appears to insert newlines to prevent lines getting too long. The result is that input given as

<pb n="[iii]"/>
<p>Quaestiones, quae ad mathematicae
fundamenta pertinent,
etsi hisce temporibus
a multis tractatae,
satisfacienti solutione
et adhuc carent.

is being displayed and exported as if it were

<pb n="[iii]"/>
<p>Quaestiones, quae ad mathematicae
fundamenta pertinent,
etsi hisce temporibus
  a multis tractatae,

  satisfacienti solutione
et adhuc
  carent.

(The extraneous blanks at the beginnings of lines are also an issue. I do not know where they are coming from.)

@cmsmcq
Copy link
Author

cmsmcq commented Oct 28, 2013

For the record: the version of dhwriter on the site today (28 October) does has different behavior. The example given above now appears in my TEI export in the form

        <eg>&lt;pb n="[iii]"/&gt; &lt;p&gt;Quaestiones, quae ad mathematicae fundamenta pertinent, etsi hisce temporibus a multis tractatae, satisfacienti solutione et adhuc carent.</eg>

That is, the line breaks in the code block are currently being lost in the TEI export. (They are still present in the interactive display and in the review PDF; I haven't yet checked the other export forms.)

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

No branches or pull requests

1 participant