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

Add forced line breaks feature #2063

Merged
merged 6 commits into from
Oct 24, 2024
Merged

Add forced line breaks feature #2063

merged 6 commits into from
Oct 24, 2024

Conversation

vkbo
Copy link
Owner

@vkbo vkbo commented Oct 24, 2024

Summary:

This PR:

  • Adds a new shortcode [br] that can be used to insert forced line breaks in text paragraphs. They only work in plain text paragraphs that already support line breaks. If they are put anywhere else, they are stripped out when building the document or manuscript. There are other ways to add breaks in headings.
  • Move the handling of line breaks in heading to the Tokenizer class so that the format classes can ignore these.
  • Fixes a bug in the raw output format that was stripping the alignment and indentation tags.

Related Issue(s):

Closes #1991

Reviewer's Checklist:

  • The header of all files contain a reference to the repository license
  • The overall test coverage is increased or remains the same as before
  • All tests are passing
  • All flake8 checks are passing and the style guide is followed
  • Documentation (as docstrings) is complete and understandable
  • Only files that have been actively changed are committed

vkbo added 5 commits October 24, 2024 00:02

Verified

This commit was signed with the committer’s verified signature.
alexsapran Alexandros Sapranidis

Verified

This commit was signed with the committer’s verified signature.
alexsapran Alexandros Sapranidis

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
@vkbo vkbo added this to the Release 2.6 Beta 1 milestone Oct 24, 2024
@vkbo vkbo merged commit 41e5152 into main Oct 24, 2024
9 checks passed
@vkbo vkbo deleted the line_breaks branch October 24, 2024 15:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add a hard line break shortcode
1 participant