swiftlang / swift-markdown

A Swift package for parsing, building, editing, and analyzing Markdown documents.
https://swiftpackageindex.com/swiftlang/swift-markdown/documentation/markdown
Apache License 2.0
2.78k stars 190 forks source link

Justify Text - Feature Request #130

Open waelsaad opened 1 year ago

waelsaad commented 1 year ago

Hi,

I think this is a basic feature that is missing yet for some reason it seems to be tricky to be implemented correctly.

I have a scenario where I need to parse lots of large XML files and each file needs to be rendered as a readable document. The text needs to be justified. I've implemented text justification using UIKit multiple ways but couldn't get it right. because of performance as the document is large and UITextViews takes time to calculate each of its paragraph content height.

Thanks,

Wael

QuietMisdreavus commented 1 year ago

"Justified text" in the form of text that fills the margins of its container (by the layout engine changing the width of spaces within the text) isn't something that happens in a Markdown library. Generally that happens via CSS added to the output. Did you mean to post this issue to Swift-DocC? If so, i can transfer the issue there for broader discussion.