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

too much space between "Figure" and reference #12

Closed
JonathanReeve opened this issue May 3, 2015 · 4 comments
Closed

too much space between "Figure" and reference #12

JonathanReeve opened this issue May 3, 2015 · 4 comments

Comments

@JonathanReeve
Copy link

This filter seems to put an additional space between Figure and the number, so instead of Figure~\ref it writes: Figure~ \ref, which makes LaTeX output Figure 5 with two spaces between Figure and 5. Screenshot:

screenshot from 2015-05-03 12-56-07

@lierdakil
Copy link
Owner

Right. This is due to fix for #11 (since multiple spaces would be typeset as one by LaTeX, but ~ is not). There is a corner case which I'm unsure about though. If there are multiple references, and cleveref is not used, then it would be expanded to

Figure~ \ref{a}, \ref{b}, \ref{c}

There are two options to fix this. First is to just strip leading spaces, which would give

Figure~\ref{a}, \ref{b}, \ref{c}

Second is to use non-breaking spaces all the way, e.g.

Figure~\ref{a},~\ref{b},~\ref{c}

Which one would suit you best?

@JonathanReeve
Copy link
Author

Cool. The first of those two options sounds the best to me. I myself rarely have more than one reference at a time, but I imagine that multiple references could probably be wrapped after the first one.

@lierdakil
Copy link
Owner

Ok, I've pushed 0.1.0.2 to hackage.

@JonathanReeve
Copy link
Author

Awesome.

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

No branches or pull requests

2 participants