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

hyphens in margins #845

Closed
eroux opened this issue Jan 28, 2016 · 5 comments
Closed

hyphens in margins #845

eroux opened this issue Jan 28, 2016 · 5 comments
Assignees
Milestone

Comments

@eroux
Copy link
Contributor

eroux commented Jan 28, 2016

Hyphens should not be allowed to go far from the right limit of the staff lines. Example of undesired behavior:

hyphen

In a first step, the behavior should be the same as when there is no hyphen, in a second step we would differenciate the case where the syllable ends by an hyphen (automatic or not), and allow it to come closer to the lines (a kind of character protrusion).

I'm affraid this is no easy fix, as the hyphen that poses problems is added in lua after the paragraph breaking algorithm, so even in a two-pass system, this wouldn't be easy: the first pass would tell the second to add an hyphen, and in some cases, the second would pass the syllable on the line after (because it would have become too big to stay on the line it was on), and thus we would have an instable system... Maybe the best way to deal with this is with a discretionary?

@rpspringuel
Copy link
Contributor

It looks to me like that hyphen is protruding exactly as it should according to the page you linked.

Also, do you have the gabc file that you used to produce the score from which that image was cut?

@eroux
Copy link
Contributor Author

eroux commented Feb 5, 2016

The thing is the protrusion here is a bug, not a feature that was intended, and protrusion should be optional anyway (not all people like the mechanism). You can reproduce it with

\documentclass[11pt]{article}
\usepackage{fontspec}
\usepackage{geometry}
\geometry{a5paper}
\usepackage{gregoriotex}
\usepackage{libertine}
\begin{document}
\gabcsnippet{igggg(g)igggg(g) igggg(g)igggg(g) igggg(g)igggg(g) igggg(g)igggg(g) igggg(g)igggg(g)}
\end{document}

although here this is a limit case that might be hard to fix...

@eroux
Copy link
Contributor Author

eroux commented Feb 14, 2016

I think it's possible to trick this by adding some kind of space (the size of an hyphen) after the text, this space being removed if not at end of line... might not be easy but that should be the best solution

@eroux eroux mentioned this issue Feb 17, 2016
@eroux
Copy link
Contributor Author

eroux commented Feb 21, 2016

See the example of this message for a realistic case.

@eroux eroux added this to the 4.1 milestone Feb 21, 2016
@eroux eroux self-assigned this Feb 21, 2016
eroux added a commit that referenced this issue Feb 21, 2016
@eroux
Copy link
Contributor Author

eroux commented Feb 21, 2016

See #945

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

2 participants