Template talk:Space
Template:Space is permanently protected from editing because it is a heavily used or highly visible template. Substantial changes should first be proposed and discussed here on this page. If the proposal is uncontroversial or has been discussed and is supported by consensus, editors may use {{edit protected}} to notify an administrator to make the requested edit. Usually, any contributor may edit the template's documentation to add usage notes or categories.
Any contributor may edit the template's sandbox. Functionality of the template can be checked using test cases. |
This is the talk page of a redirect that targets the page: • Template:Spaces Because this page is not frequently watched, present and future discussions, edit requests and requested moves should take place at: • Template talk:Spaces |
Examples
[edit]*abcdefghij *a{{space|1}}cdefghij *a{{space|2}}defghij *a{{space|3}}efghij *a{{space|4}}fghij
- abcdefghij
- a cdefghij
- a defghij
- a efghij
- a fghij
Genesis June 07, 2006
[edit]I ported this over from wikisource as {{indent}}. Seems useful for when a wikitable is contraindicated, yet one wants to line up several short columns of material. Indent can NOT be used in-line because of the leading '<br />'. This is at genesis the only difference between the two.
Displaying with nowikis:
{{ #switch: {{{1}}} | 0 = | 1 =   | 2 =    | 3 =     | 4 =      | 5 =       | 6 =        | 7 =         | 8 =          | 9 =           | 10 =            | 11 =             | 12 =              | 13 =               | 14 =                | 15 =                 | 16 =                  | 17 =                   | 18 =                    | 19 =                     | 20 =                      | 21 =                       | 22 =                        | 23 =                         | 24 =                          | 25 =                           | 26 =                            | 27 =                             | 28 =                              | 29 =                               | 30 =                                | }}<noinclude>[[Category:Uncategorised templates]]</noinclude>
I suggested over there at wikisource that the category ought to be 'Pretty print' or the like, along the lines of a pretty print program or filter in Computer Science, esp. used in the bad old days for C, C++, etc.
Best regards, FrankB 21:33, 26 May 2006 (UTC)
Demo/Test
[edit]- echoed from the commons... where something is broken.
- {{space|1}}... x y 1_ z
- {{space|2}}... x y 2_ z
- {{space|3}}... x y 3_ z
- {{space|4}}... x y 4_ z
- {{space|5}}... x y 5_ z
- {{space|6}}... x y 6_ z
- {{space|7}}... x y 7_ z
- {{space|8}}... x y 8_ z
- {{space|9}}... x y 9_ z
- {{space|10}}... x y 10_ z
- {{space|11}}... x y 11_ z
- {{space|12}}... x y 12_ z
-apparently, something's also now broken here today too above '5'! // FrankB 15:59, 17 August 2006 (UTC)
Not clear
[edit]It is not clear what this is all about. What is the meaning of n spaces in a proportional font? In a non- proportional font, why not just use spaces, like
99 100 1234
Patrick 00:13, 18 August 2006 (UTC)
More
[edit]I stumbled on this template thinking "Wouldn't it be nice to have some template which produces a thin space, an en space or an em space without having to type the whole "{{unicode|&...
" out? What should I call it ..."
Lo & behold the template already existed but with a different purpose ... though it's not as if its a vastly different purpose. Now, here's what I have in mind. Let's have this as a dual purpose template. Instead of my going and making a whole new template (and call it what?) let me add to this one. Here's what I'm thinking of adding (into the "").
|thin={{unicode| }}
|th={{unicode| }}
|t={{unicode| }}
|en={{unicode| }}
|n={{unicode|&nsp;}}
|em={{unicode| }}
|m={{unicode| }}
I don't think that this will cause confusion or detract in any other way from the template. Note: I've given alternatives (e.g. "thin
", "th
" or just "t
")—why not? It only makes things easier to use. Jɪmp 08:41, 20 June 2007 (UTC)
Six of one ≠ half a dozen of the other
[edit]What do twelve spaces look like using this template?
] [ | 12 {{space|1}} s
|
] [ | 6 {{space|2}} s
|
] [ | 4 {{space|3}} s
|
] [ | 3 {{space|4}} s
|
] [ | 2 {{space|6}} s
|
] [ | 1 {{space|12}}
|
- ] [
- ] [
The template is using a mix of ordinary spaces non-breaking spaces and em spaces thus we've got this strange disproportionality. {{space|2}}
, for example, is not twice but (about) four times the width of {{space|1}}
. Is there a purpose to this? Jɪmp 18:06, 21 June 2007 (UTC)
Protection template
[edit]{{editprotected}}
Please add the protection template to this template inside the <noinclude>...</noinclude>
tags at the end, not to its documentation page. The reason I removed it from there is because that documentation page is used for other, non-protected, templates as well and caused an error there. Thank you. Debresser (talk) 12:17, 5 May 2009 (UTC)
- Done. — Martin (MSGJ · talk) 12:45, 5 May 2009 (UTC)
- Thanks. Debresser (talk) 12:56, 5 May 2009 (UTC)
Default
[edit]{{editprotected}} Why not give a default value. {{space}} should give the same result as {{space|1}} ManishEarthTalk • Stalk 12:09, 16 April 2010 (UTC)
Discussion
[edit]See Wikipedia:Village_pump_(proposals)#Should_the_underscore_be_used_as_mark-up_for_non-breaking_spaces.3F ManishEarthTalk • Stalk 12:10, 16 April 2010 (UTC)
Overhaul
[edit]This template is hosed. See Template:Space/comparison for a thorough investigation of just how broken it is.
{{editprotected}}
Please replace the template with the properly tested version at Template:Space/sandbox (as of this writing). The new code works cross-platform, cross-browser, at any font size and regardless of font and regardless of unicode support; it does not allow linebreaks, which defeat the purpose of the template; it actually works up to |1=30
the way it was supposed to; it will not play tricks on small-screened mobile devices to prevent them from collapsing whitespace that they cannot handle; it has a default value, as was requested a long time ago. Basically, every problem reported here, and others besides, are now fixed.
Demo:
- Space me once
- Space me thrice
- Space me 15 times, bay-bay.
- <drum roll>
— SMcCandlish Talk⇒ ʕ(Õلō)ˀ Contribs. 02:23, 17 October 2011 (UTC)
- Done. Please make sure that the template does what you expected it to do. Nyttend (talk) 12:30, 17 October 2011 (UTC)
- I did notice I had to change {{space|12}} to margin-left:6em in this edit. Otherwise, everything looked like it was too far to the left. I'm sure there is a technical explanation! --Funandtrvl (talk) 15:31, 20 October 2011 (UTC)
Updated doc subpage to match overhaul
[edit]On 13 March 2012, I changed the doc subpage, Template:Space/doc to match the current operation of the overhauled version, as inserting multiple non-breaking spaces " ...". To remind users of the difference, I added new doc section "History" to note that formerly (for 6 years), the template had inserted em-spaces or a mix of   and regular spaces, etc. I also noted that the common interwiki Template:In5 can be used to insert wrappable spaces, as purposely designed to auto-reduce the spacing when used on narrow windows. -Wikid77 (talk) 16:43, 13 March 2012 (UTC)
Similar template
[edit]Template {{spaces}} has a similar (or the same) purpose as this template, but contrary to this template (which uses an ugly method) is uses a better code. Could {{space}} better serve as a redirect to that template? --Götz (talk) 19:19, 29 May 2013 (UTC)
Request db-t3
[edit]This edit request has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
As stated above last month, this template is a duplicate of {{spaces}}. Thus, it meets speedy deletion criteria under "T3. Duplication and hardcoded instances." Please add {{db-t3|~~~~~|Spaces}}. A redirection from this template to {{spaces}} will work, as both templates use the same syntaxis. --Götz (talk) 16:44, 17 June 2013 (UTC)
- Partly done: I agree with the redirection proposal, and I have implemented it. We can't delete the template, though, as it has 22,000 transclusions at the moment. Also, the template is not quite an identical copy, as it now has different behaviour if the first positional parameter is not a number. For example, previously the code
{{space|foo}}
would have produced
, but now it will produce an error. These errors are tracked in the category Category:Errors reported by Module String, though, so I didn't think this too big a risk. If you could keep an eye on the category for any new errors, it would be appreciated. Best — Mr. Stradivarius ♪ talk ♪ 14:22, 26 June 2013 (UTC)- I will, thanks! --Götz (talk) 19:36, 29 June 2013 (UTC)
Protected edit request on 17 March 2018
[edit]This edit request has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Leave a blank second line (a newline at that) and please add this on the third line:
{{Rcat shell|{{R from modification}}}}
stranger195 (talk • contribs • guestbook) 05:16, 17 March 2018 (UTC)
- Done — Martin (MSGJ · talk) 20:48, 17 March 2018 (UTC)