-
Notifications
You must be signed in to change notification settings - Fork 52
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
Spurious spaces in English when French is the main language #66
Comments
|
According to the manual, \textenglish should be used for short insertions of text. So why shouldn't this work? I can reproduce the problem. |
The cause is the same as for #169: Probably the only solution is to define |
Having written this, a better solution seems to me to add a hook that is inserted at the beginning of a language switch (say, This seems to be a fairly generalizable solution for similar cases. PS. I saw that there is already a hook
|
As an alternative, the following way could be chosen: |
The alternative does not fix the general issue though: temporarily disable all language specific settings when a nested language is entered. |
The fix seems easier than I thought. I'll di a PR in a minute. |
Fixed by #235. |
Hi everyone, I would like to ask few questions about the general principles when switching languages:
Kind regards, Ivan |
Am Donnerstag, den 22.08.2019, 03:40 -0700 schrieb Ivan Kokan:
Assuming that \text<lang> activates some local language-dependent
rules, how can one ensure those rules are reverted afterwards? I
guess various extras are to be used for this purpose.
All \*extras are reverted with \noextras, \*numbers with \no*numbers
Jürgen
|
The (rather sparse) documentation indicates so. But it isn't:
As to the babel commands:
The change of I think at least the behavior of |
On Thu, Aug 22, 2019 at 1:40 PM Jürgen Spitzmüller ***@***.***> wrote:
* Should `\text<lang>` and `\begin{<lang>}` be equivalent or not?
The (rather sparse) documentation indicates so. But it isn't:
- \text<lang> does not change the captions, but it does change \today
- \begin{<lang>} changes the captions and \today
As to the babel commands:
- \foreignlanguage and the starred otherlanguage environment behave
like \text<lang>, but in babel, \today is not changed!
- \selectlanguageand the unstarredotherlanguageenvironment behave like\begin{}`,
which is OK.
The change of \extras in all commands is in line with babel.
I think at least the behavior of \foreignlanguage and the starred
otherlanguage environment should be fixed, and the documentation
elaborated. But this should go to a separate ticket.
Babel documentation state it is a mess.
In think that \foreignlanguage and otherlanguage* and \textlang should
behave the same way.
For me the today stuff is a bug in polyglossia
… —
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#66?email_source=notifications&email_token=ABE5UHFXD2VETTYPJMMVCRTQFZ3MFA5CNFSM4AKPZS5KYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD44ZU3Q#issuecomment-523868782>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ABE5UHCYJV2LZPIYJGPK3TLQFZ3MFANCNFSM4AKPZS5A>
.
|
The issue discussed as of #66 (comment) is now #239. |
Switching locally to English with \textenglish doesn't stop polyglossia to add spaces in front of ':' ';' '!' and '?' as shown in the following example:
%%%%%%%%%%%%%%%%%
\documentclass[12pt]{article}
\usepackage{fontspec}
\usepackage{polyglossia}
\setmainlanguage{french}
\setotherlanguage{english}
\begin{document}
\showoutput
Texte en français: ça marche? oui! \textenglish{english: ok? no!}
\end{document}
%%%%%%%%%%%%%%%%%%%%
The text was updated successfully, but these errors were encountered: