Template talk:R
Extra newline
Can anyone explain to me why there is an extra newline after this template's contents? Can anyone remove it, please?? --Larry Sanger 13:24, 6 May 2008 (CDT)
To answer my own question, it's caused by the fact that we place newlines between each use of the template, like this:
{{r|Biology}} {{r|Microbiology}} {{r|Cell Biology}}
That outputs:
- Biology [r]: The science of life — of complex, self-organizing, information-processing systems living in the past, present or future. [e]
- Microbiology [r]: The study of microorganisms (overlapping with areas of virology, bacteriology, mycology, and parasitology). [e]
- Cell Biology [r]: The study of the components of cells and their interactions. [e]
But the r template itself adds an asterisk, which adds its own newline (before the asterisk). That's two newlines. To eliminate extra newlines, you could do this:
{{r|Biology}}{{r|Microbiology}}{{r|Cell Biology}}
which outputs:
- Biology [r]: The science of life — of complex, self-organizing, information-processing systems living in the past, present or future. [e]
- Microbiology [r]: The study of microorganisms (overlapping with areas of virology, bacteriology, mycology, and parasitology). [e]
- Cell Biology [r]: The study of the components of cells and their interactions. [e]
--Larry Sanger 13:55, 6 May 2008 (CDT)
- Just want to point out that the real reason for the problem above was an extra font tag that got removed in the following edit. Also this template has changed a lot since the above was written so those examples may not look the same as when it was written on May 6th. Chris Day 11:52, 20 May 2008 (CDT)
Formatting limits
Note that even though both:
{{r|Biology}} {{r|Cell (biology)||**}}
- Biology [r]: The science of life — of complex, self-organizing, information-processing systems living in the past, present or future. [e]
- Cell (biology) [r]: The basic unit of life, consisting of biochemical networks enclosed by a membrane. [e]
and:
{{r|Biology}} **{{r|Cell (biology)||}}
- Biology [r]: The science of life — of complex, self-organizing, information-processing systems living in the past, present or future. [e]
- Cell (biology) [r]: The basic unit of life, consisting of biochemical networks enclosed by a membrane. [e]
work, however:
{{r|Biology}} *{{r|Cell (biology)||*}}
- Biology [r]: The science of life — of complex, self-organizing, information-processing systems living in the past, present or future. [e]
- Cell (biology) [r]: The basic unit of life, consisting of biochemical networks enclosed by a membrane. [e]
doesn't. The best theory about why is that it must be that thing with an extra newline being emitted - it must be coming out after the leading '*' and before the second '*' (in the no-working cases), i.e. right at the start of the template invocation. That's why the ones with the '**' (at either end) work, that new line is not splitting the two '*'s apart. In those middle ones, the reason the naked bullet is coming out right up on the left margin is that it sees:
* *[[link]]
not:
**[[link]]
and of course then we get two separate bullets, fully left-justified. Dont ask me why the **{{r|link||}} case works, because it should be seeing:
** [[link]]
if my theory about when the 'rogue' new line is appearing is correct, but clearly it's not appearing then! J. Noel Chiappa 11:47, 20 May 2008 (CDT)
- This makes sense %*? Chris Day 11:55, 20 May 2008 (CDT)
ROTFLMAOIf it's any consolation,it doesn't make any sense to me either! :-) Bugs - they can be so wierd.- There was one at MIT once which quite literally depended on the phase of the moon - thereby stunning all the hackers, for whom phrases like 'the new memory bank usually works, depending on the phase of the moon' (i.e. totally randomly and disconnected from any external causality that could be identified, as far as anyone could tell) were stock. We were all suitably impressed when a bug appeared which really did depend on the phase of the moon! J. Noel Chiappa 12:06, 20 May 2008 (CDT)
Helpful for Core Articles
Hi Chris and Noel, just wanted to tell you that I think this third option for hierarchical arrangements makes the template especially useful for article lists like those on the CZ:Core Article pages. Thanks! -- Daniel Mietchen 12:00, 20 May 2008 (CDT)