Sujet sur Discussion utilisateur:Trizek (WMF)/Structured Discussions Archive 1

Whatamidoing (WMF) (discutercontributions)

Due to French spacing of punctuation, are non-breaking spaces added regularly on this wiki? How (e.g., template, HTML code, directly typing the character)?

Trizek (discutercontributions)

(Replying with my volunteer account, since I'm around using it.)

We have some templates that will add a given string to an article, with the appropriate non-breaking spaces. {{nobr}} is the generic one.

Otherwise, I think/beleive/hope that VE does the job for me...? Especially for : ; ? !.

Whatamidoing (WMF) (discutercontributions)

The visual editor originally auto-converted non-breaking spaces to plain spaces. Then I heard that it accepted them, but enwiki was unhappy (because they have an old rule against using non-breaking spaces directly, on the grounds that the difference isn't visible in the wikitext editors). Currently, I'm not sure what it actually does.

Whatamidoing (WMF) (discutercontributions)

I'm curious what you (all) think it should do.

Trizek (WMF) (discutercontributions)

I think we should have a per-wiki rule, through a configuration file. For instance, when I type a ? here, it should be preceded by the appropriate non-breaking space. Not at en.wp.

Non-breaking spaces should be visible (highlighted in grey I think they were) in either editors.

Whatamidoing (WMF) (discutercontributions)

That idea sounds like something for SSastry (WMF) to think about. Just space+question mark would be auto-converted to use the non-breaking space (i.e., not a question mark without a space), right?

Trizek (WMF) (discutercontributions)

You're right.

Cscott (discutercontributions)

There's already support for converting spaces to non-breaking spaces around quotation marks automatically on output, the so-called "french-spacing" options. https://phabricator.wikimedia.org/T197902

That already applies to question marks, I believe. So I think maybe the issue is how Visual Editor displays this while editing, since the output after editing should be correct? (You should only extremely rarely need to manually insert a non-breaking space.)

Trizek (WMF) (discutercontributions)

Good to know, thank you Cscott. I wasn't aware of this rule.

Whatamidoing (WMF) (discutercontributions)

I've filed phab:T299478 to see whether VisualEditor can support it. The Editing team isn't doing active feature development there, so it may take some months/years.

Répondre à « Non-breaking spaces »