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

Insert break opportunities in URIs shown for print #563

Closed
mojavelinux opened this issue Sep 19, 2016 · 1 comment
Closed

Insert break opportunities in URIs shown for print #563

mojavelinux opened this issue Sep 19, 2016 · 1 comment
Assignees

Comments

@mojavelinux
Copy link
Member

If unbroken, URIs can disrupt text justification or and line wrapping by leaving behind large gaps. When URIs are shown for print (media=print or media=prepress), insert break opportunities in the URI so that it flows more naturally.

Add break opportunities at the following locations:

  • After each forward slash following a path segment (but not after the URI scheme)
  • After the ? that begins the query string
  • After each & in the query string
  • After the # that begins the fragment identifier

Don't insert a break opportunity before the last character.

We may even want to think about doing this for all visible URIs in the text (at least ones that match as a link in AsciiDoc).

@mojavelinux mojavelinux added this to the v1.5.0.alpha.14 milestone Sep 19, 2016
@mojavelinux mojavelinux self-assigned this Sep 19, 2016
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Oct 22, 2016
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Oct 22, 2016
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Oct 23, 2016
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Oct 23, 2016
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Oct 23, 2016
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Oct 23, 2016
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Oct 23, 2016
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Oct 23, 2016
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Oct 23, 2016
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Oct 23, 2016
mojavelinux added a commit to mojavelinux/asciidoctor-pdf that referenced this issue Oct 23, 2016
mojavelinux added a commit that referenced this issue Oct 23, 2016
resolves #563 allow printed URI to break at break opportunities
fapdash pushed a commit to vogellacompany/asciidoctor-pdf that referenced this issue Dec 13, 2016
@mojavelinux
Copy link
Member Author

To clarify, this is done for any visible URI that's specified as part of a link, regardless of media type.

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