Arnavion / libjass

Renders ASS subs in the browser.
Apache License 2.0
174 stars 29 forks source link

Fix missing softnewline #104

Closed nickfujita closed 7 years ago

nickfujita commented 7 years ago

Resolves issue #103 Soft newline characters (\n) were being rendered as plain text. This PR adds support for soft newline styling.

Arnavion commented 7 years ago

You also need to make the renderer understand it. As it is right now, the renderer will not emit it at all, whereas you want it to be emitted either as a space or a hard newline based on the wrapping mode.

https://github.com/Arnavion/libjass/blob/e0c630038b9738fde8077d4cef38f2f547d08006/src/renderers/web/renderer.ts#L943-L945

nickfujita commented 7 years ago

Added logic to render SoftNewLine same as NewLine when WrapStyle is NoLineWrapping, and as a space for any other WrapStyle.

nickfujita commented 7 years ago

@Arnavion Wanted to followup with you to see if there is any additional feedback on this change request.

nickfujita commented 7 years ago

@Arnavion Sorry to ping again, but wanted to followup with you to see if there is any additional feedback on this change request before it can be merged?