Rosetta Code:Village Pump/Line breaks in templates: Difference between revisions

m
Add template
(Summarize my recent batch of edits)
m (Add template)
 
(2 intermediate revisions by 2 users not shown)
Line 1:
{{Vptopic
|topic=Line breaks in templates
|summary=Discussion of how to handle multiple templates next to each other.
}}
I've seen people go back and forth in [[Template:Works with]], [[Template:Libheader]], [[Template:Trans]], and other example-level templates on whether they want the line break in the template or on the page. We should just make a decision and go with it. I vote for one line break in the template (not a <nowiki><br/></nowiki>) so that people can type something like this:
<pre>{{works with|libraryx|2.1}}
Line 34 ⟶ 38:
:::::: It's now done (e.g., <nowiki>{{tcllib|math}}</nowiki> indicates that the math package of the tcllib library is used) though perhaps it's an area where other languages might want to do something similar. I've also taken steps to mark up the information in that template so it is reflected in the SMW tagging. This makes it possible to find all the examples where a particular tcllib package was used (a new capability; it couldn't be done before).
:::::: I know about the need to keep things synchronized. For now, I'll do it as a manual action. –[[User:Dkf|Donal Fellows]] 14:15, 9 November 2010 (UTC)
::::::: ... I really need to buy you a drink or something; that's a lot of nice cleanup work you've put in over the last few days. I wonder if {{tmpl|libheader}} could be adjusted for similar functionality. Say, to have it read "Uses '''component''' from '''library''', tacking on semantic properties in the process. Hm. I suppose that could probably just be put in a new template, {{tmpl|uses from}} --[[User:Short Circuit|Michael Mol]] 15:13, 9 November 2010 (UTC)
::::::: Oh, that's really cool! Now that RC has rebuilt all the semantic properties, I can do queries like [http://rosettacode.org/wiki/Special:SearchByProperty/Uses-20tcllib-20package/struct::list this] to list all the uses of a particular package. I like this semantic stuff; now that we've got some data, you can actually use it to find out interesting things… (BTW, what's the best way of writing queries as links? Maybe that's something for a different Village Pump page though.) –[[User:Dkf|Donal Fellows]] 22:44, 9 November 2010 (UTC)
 
You guys are awesome. Thanks for getting this fixed so quickly. --[[User:Mwn3d|Mwn3d]] 18:24, 3 November 2010 (UTC)
Anonymous user