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

French space for guillemets #141

Open
maieul opened this Issue Apr 13, 2016 · 23 comments

Comments

Projects
None yet
5 participants
@maieul
Contributor

maieul commented Apr 13, 2016

The @hugoroy commit 6bcba5a breaks the csquotes french guillemets

Cf this MWE

_\documentclass{article}
\usepackage{polyglossia}
\setmainlanguage{french}
\setotherlanguage{english}
\usepackage[french=guillemets]{csquotes} \MakeOuterQuote{"}
\begin{document}
\enquote{s}

"s"

\enquote{x}

«x»_
\end{document}
Before the commit
before.pdf

After the commit

after.pdf

cf @aurelberra

@reutenauer

This comment has been minimized.

Owner

reutenauer commented Apr 13, 2016

Hum, that’s bad, thanks for the report. I’ll have a look.

@maieul

This comment has been minimized.

Contributor

maieul commented Apr 13, 2016

I think the problem is that \MakeOuterQuote{"} already insert a space,

cf

\documentclass{article}
\usepackage{polyglossia}
\setmainlanguage{french}
\setotherlanguage{english}
\usepackage[french=guillemets]{csquotes} \MakeOuterQuote{"}
\makeatletter
\apptocmd{\french@punctuation}{%
     \XeTeXinterchartoks \french@punctguillstart 255 = {\nobreakspace\xpg@nospace}% "«  " -> "«~"
     \XeTeXinterchartoks 255 \french@punctguillend = {\xpg@unskip\nobreakspace}% "  »" -> "~»"  
}{}{}
\makeatother
\begin{document}
\enquote{s}

"s"

\enquote{x}

« x »

" s "

«x»
\end{document}
@reutenauer

This comment has been minimized.

Owner

reutenauer commented Apr 13, 2016

Yes, clearly there’s a conflict between the two requirements. It’s really not clear to me what’s the best choice is.

@aurelberra

This comment has been minimized.

aurelberra commented Apr 13, 2016

Indeed. Uncommenting the lines which deal with 255 + quotes in
gloss-french.ldf solves the problem, I think.

A.
On mer. 13 avr. 2016 at 16:10, Maïeul Rouquette notifications@github.com
wrote:

I think the problem is that \MakeOuterQuote{"} already insert a space,

cf

\documentclass{article}
\usepackage{polyglossia}
\setmainlanguage{french}
\setotherlanguage{english}
\usepackage[french=guillemets]

{csquotes} \MakeOuterQuote{"}
\makeatletter
\apptocmd{\french@punctuation}{%
\XeTeXinterchartoks \french@punctguillstart 255 = {\nobreakspace\xpg@nospace}% "« " -> "«"
\XeTeXinterchartoks 255 \french@punctguillend = {\xpg@unskip\nobreakspace}% " »" -> "
»"
}{}{}
\makeatother
\begin{document}
\enquote{s}

"s"

\enquote{x}

« x »

" s "

«x»
\end{document}


You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub
#141 (comment)

@maieul

This comment has been minimized.

Contributor

maieul commented Apr 13, 2016

@aurelberra it solves our problem, but reinstalls @hugoroy problem :-)

@aurelberra

This comment has been minimized.

aurelberra commented Apr 13, 2016

Yes, sorry: I had missed the motivation for the commit. But isn't it a
clear logical principle to simplify input (" or «) or make it semantic
(\enquote) rather than mix it with presentation of the content («\space) ?

On mer. 13 avr. 2016 at 16:13, Maïeul Rouquette notifications@github.com
wrote:

@aurelberra https://github.com/aurelberra it solve us problem, but
reinstall @hugoroy https://github.com/hugoroy problem :-)


You are receiving this because you were mentioned.
Reply to this email directly or view it on GitHub
#141 (comment)

@maieul

This comment has been minimized.

Contributor

maieul commented Apr 13, 2016

Yes, sorry: I had missed the motivation for the commit. But isn't it a
clear logical principle to simplify input (" or �) or make it semantic
(\enquote) rather than mix it with content (�\space) ?

yes indeed, but it should be to automatically clean the �\space, and I think Arthur will find the way ;-)

@maieul

This comment has been minimized.

Contributor

maieul commented Apr 19, 2016

hi @reutenauer some news about this issue ?

@maieul

This comment has been minimized.

Contributor

maieul commented May 1, 2016

\XeTeXinterchartoks \french@punctguillstart 255 = {\nobreakspace\xpg@nospace\ignorespaces}% "« " -> "«~"
seems to be the good one. Allow both « s » and «s»

@maieul

This comment has been minimized.

Contributor

maieul commented May 1, 2016

ah thats does not work for " s "

@maieul

This comment has been minimized.

Contributor

maieul commented May 1, 2016

but for " s " concerned csquotes, and so it is a bug in this one. So I suggest to integrate my solution, and I will open an issue for csquotes.

@hugoroy

This comment has been minimized.

Contributor

hugoroy commented May 1, 2016

\XeTeXinterchartoks \french@punctguillstart 255 = {\nobreakspace\xpg@nospace\ignorespaces}% "« " -> "«~"
seems to be the good one. Allow both « s » and «s»

No because it does not work for «s» or « s » (with non breakable space character)

@maieul

This comment has been minimized.

Contributor

maieul commented May 2, 2016

hum, in this case I afraid the only solution will be to add an option.
But the default one should be the historical behavior: automatically inserting space.

@hugoroy

This comment has been minimized.

Contributor

hugoroy commented May 2, 2016

Wouln't be better fixed in csquotes? If I understand correctly, everything works fine except in combination with csquotes.

@maieul

This comment has been minimized.

Contributor

maieul commented May 3, 2016

hum… maybe we should test for «s» in csquotes.

@hugoroy

This comment has been minimized.

Contributor

hugoroy commented May 3, 2016

Yes I think so, especially because this facilitates compatibility with document written with babel/latex in mind and probably other contexts as well.

Envoyé de mon appareil mobile.
Sent from my mobile device.

@aurelberra

This comment has been minimized.

aurelberra commented May 3, 2016

I also think that this is to be dealt with in the csquotes issue opened by @maieul.

@maieul

This comment has been minimized.

Contributor

maieul commented Jan 28, 2017

The csquotes mainteners close the issue.

I suggest to revert the commit @hugoroy and to come back to the previous behavior. No one should add space around guillemet in the code.

Maybe we could get the code of @hugoroy as an option, but not the default behavior.

@aurelberra

This comment has been minimized.

aurelberra commented Jan 29, 2017

I fully agree with @maieul's proposal. Such spaces should be an option.

@aurelberra

This comment has been minimized.

aurelberra commented Apr 5, 2017

I would like to know if there has been any progress on this problem. Cf. #145.

maieul added a commit to maieul/polyglossia that referenced this issue Apr 5, 2017

issue reutenauer#141, coming back to older behavior with french guill…
…emets (problem introduced by 6bcba5a)

With this, the example in this MWE are working
\documentclass{article}
\usepackage{polyglossia}
\setmainlanguage{french}
\setotherlanguage{english}
\usepackage[]{csquotes}
 \MakeOuterQuote{"}
 \begin{document}

 \enquote{x}

 «a»

 « a »

 " a "
 \end{document}
@ArchangeGabriel

This comment has been minimized.

ArchangeGabriel commented Apr 5, 2017

I’m not sure what this issue is about, but I personally type thing as « s » or « s » when unbreakable spaces are not supported by the other people working with me on a doc. Because I want my source code to already be the most typographically right as possible.

Anyway, I’ve been using Babel for a long time now since it now seems to be superior to polyglossia, at least for my use.

@maieul

This comment has been minimized.

Contributor

maieul commented Apr 6, 2017

@ArchangeGabriel

This comment has been minimized.

ArchangeGabriel commented Apr 15, 2017

I’m concerned about being able to extract my “code” and use it in something else than a LaTeX document without having to run a script on it or modify things by hand. But anyway, I’m not an user of polyglossia, so if you’re all fine with that then it’s your right. ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment