Template talk:Listen
From Wikipedia, the free encyclopedia
Template:Listen links to an audio file. It is meant to be used for audio files set off from the text, like music clips or sound recordings. To apply it in an article use the following:
{{Listen|filename=Name of file on commons.ogg|title=Title of this file|description=The description of this file|filesize=The size of the file for downloading}}
For instance, {{Listen|filename=Accordian chords-01.ogg|title=Accordion chords|description=Chords being played on an accordion|filesize=145 KB}}
is rendered like this:
- Accordion chords (file info) — play in browser (beta)
- Chords being played on an accordion
- Problems listening to the file? See media help.
The other major template is Template:Audio (documentation), which is meant more for inline sounds like pronunciations.
See also {{Multi-listen start}}, {{Multi-listen item}}, and {{Multi-listen end}}.
For an overview of audio templates in all language Wikipedias see: commons:List of the different audio-templates for the Wikipedias
Contents |
[edit] Discussion
The image doesn't do enough to set the text off from the body of the article. It reads as if it's part of the article when you're reading through it. This is a perfectly legitimate use of italics. – flamurai (t) 06:30, Feb 20, 2005 (UTC)
- Firstly, that is the point of the template. If one wanted to completely set the text off, one would float the table right. That is not what is intended for here.
- Secondly, italics are used for emphasis and to highlight terms, not to make things more visible. Dysprosia 07:40, 20 Feb 2005 (UTC)
- If you read any decent book on typography, you would learn that italics are used just for that purpose. – flamurai (t) 07:45, Feb 20, 2005 (UTC)
- The use of larger text is much more efficient in making things more visible. However, this is a moot point; see below.
- The template is clearly meant to be self-contained. It's not designed to be part of the body of the article. – flamurai (t) 07:48, Feb 20, 2005 (UTC)
- I created the template in order to simplify the placement of an audio piece inline with the article, with the image to highlight. See pre-listen templates of Goldberg Variations to see what I had intended. It is designed to be part of the body of the article, otherwise a seperate section should be used along with Template:Multi-listen, such as in Piano Sonata in C major (Mozart) (which does not use this template as of yet). As the intent for this template is to be integrated with the body of the article, there is no need for italics or other visibility enhancing measures. Dysprosia 08:46, 20 Feb 2005 (UTC)
- It's not about enhancing visibility. It's about indicating to the reader "this text is not part of the body of the article."
- I don't think you understand what I mean by the body of the article. The body of the article is the main text. The caption of an image, for example, is not part of the body of an article. A link to a sound file in this case is much like a caption of an image. It's describing something separate from the article. It's not part of the paragraph and sentence structure that is the article. If the audio link were supposed to be part of the article, it would be used like this within the main text of the article. – flamurai (t) 08:53, Feb 20, 2005 (UTC)
- I created the template in order to simplify the placement of an audio piece inline with the article, with the image to highlight. See pre-listen templates of Goldberg Variations to see what I had intended. It is designed to be part of the body of the article, otherwise a seperate section should be used along with Template:Multi-listen, such as in Piano Sonata in C major (Mozart) (which does not use this template as of yet). As the intent for this template is to be integrated with the body of the article, there is no need for italics or other visibility enhancing measures. Dysprosia 08:46, 20 Feb 2005 (UTC)
- If you read any decent book on typography, you would learn that italics are used just for that purpose. – flamurai (t) 07:45, Feb 20, 2005 (UTC)
-
-
-
-
- I'd have to disagree with you on "a link to a sound file in this case is much like a caption of an image". What you are suggesting is what I mentioned in my first reply to you - if the link is not in the body of the article it should behave much like an image, it should be floated right, just like any other image.
- But it isn't. It's used inline with the text. The wording is deliberately done so to flow with the text of the article. It is intended to be a logical continuation of the text of the article. It is intended to contain a standard, generic wording and a highlighting image so the fact that there is indeed a sound file is not lost in the text. Dysprosia 12:41, 20 Feb 2005 (UTC)
- So if you made a paper version of Wikipedia, you'd include the "Listen to..." text? – flamurai (t) 15:18, Feb 20, 2005 (UTC)
- I don't understand what point you're trying to make with that comment. If it's that since the text should not be included in a paper edition of Wikipedia, it is thus "not part of the body of the text", then by that argument, images and image captions are part of the body of the text? Regardless, one can exclude images simply by not including the template text in print publication. Dysprosia 23:36, 20 Feb 2005 (UTC)
- You're twisting my point. How about this. If you were reading the text out loud, would you read the "listen to" sentence? – flamurai (t) 00:53, Feb 21, 2005 (UTC)
- I don't understand what point you're trying to make with that comment. If it's that since the text should not be included in a paper edition of Wikipedia, it is thus "not part of the body of the text", then by that argument, images and image captions are part of the body of the text? Regardless, one can exclude images simply by not including the template text in print publication. Dysprosia 23:36, 20 Feb 2005 (UTC)
- So if you made a paper version of Wikipedia, you'd include the "Listen to..." text? – flamurai (t) 15:18, Feb 20, 2005 (UTC)
-
-
-
In that case, I agree with Dysprosia - I don't like the italics - I think it looks ugly, I think they are unncessary, and if they really are necessary in a few cases, the user can add them manually to the description. →Raul654 05:36, Feb 23, 2005 (UTC)
- Personally, I think the entire template is ugly and I'm not the only one. This was more of a stopgap to improve readability problems caused by the fact that the template is somewhere between inline text and a standalone item.
- A better, software-side solution would be to have Media: links display a different icon instead of the same icon as external links.
- The reason I added the italics is because I felt they were necessary in History of music.
- – flamurai (t) 05:47, Feb 23, 2005 (UTC)
-
- If you think it's ugly, you should discuss why you think it's ugly.
- In any case, I would strongly disagree with Alkivar doing what he did. The point is to keep the audio in context with the text. If there is a circumstance where an article is discussing multiple works, and one section does describe a work, and one has the audio for it, it would be expected that the audio accompany the text, not to appear some time late after the article has finished. One does not add all the images to an article at the end of it, do they? Dysprosia 05:56, 23 Feb 2005 (UTC)
-
-
- The problem, as I already mentioned, is that it's halfway between a standalone entity and inline text. The way I originally used it here, almost every use was just repeating information that was in the text, so that's why I prefer it as a standalone entity. The other thing is the repeated notice about the sound format. It's really only necessary to have that once in each article. Finally, it's poorly executed and adds excess whitespace to articles. I don't know why this is, but it's really annoying. One last thing... the music notes in the icon are backwards, which probably will drive any musician who notices that nuts.
- Personally, I think the best solution is to redesign this template to work as a standlone template, and get a software enhancement for inline media links so it shows an icon that makes it obvious it's media instead of an external link icon.
- – flamurai (t) 06:33, Feb 23, 2005 (UTC)
-
-
-
-
- I disagree with you that it's "halfway". Its use is to point out audio that is relevant to the text, and to accompany the text. Do you disagree with this usage? You have not spoken to my comments about the usage that I had already mentioned.
- I don't really know what text it is repeating; it is a parametrized template, so the user of the template is responsible for the text the template takes on.
- I disagree with you that it is only necessary to have that audio help message once. Almost all operating systems support raw audio formats such as WAV, but using WAV for everything is obviously impractical. No operating system other than Linux I imagine support OGG natively, so it is important to make this distinction clear. The notice is small, so it can hardly be that annoying. Regardless, it can be repaired also, which I will attempt.
- The issue with the image is obviously repairable.
- If you are so discontented with this template, there is always the option for you to create a different template that will appear and behave more like an image link, floated right, seperate from the text. Dysprosia 07:22, 23 Feb 2005 (UTC)
-
-
-
-
-
-
- I don't want it to behave more like an image link. It's not an image link; it's an audio link. But it's not part of the text. It's separate from the text. I like the use of this template, I just don't like it's layout.
- For example, your use of the template on Johannes Brahms is not part of the text. Same with Goldberg Variations. You said it yourself: this template isn't used as part of the text, it's used to accompany the text. It is a separate layer used to enhance the text like a figure, image, or table, though it is none of those. If I pull that template out, it does nothing to integrity of the article, but if I don't have the audio file, the text in this template becomes pointless. There needs to be a clear visual distinction between the article body and the text describing the audio file, and the icon isn't enough. It either needs to be boxed, ruled, or set apart typographically. I chose the last solution because it was the easiest.
- This template also shouldn't be used in separate "Media" sections. It's really unappealing and unprofessional to have the same template four times in a row just like it's unappealing to have a whole bunch of images stacked down the right side of the page.
- Minor issue, but the music notes thing isn't as easily fixable as you think. The only easy solution is to remove them completely. If you just flip them, the highlight won't match with the lighting on the speaker.
- See this Zilla bug for my proposed solution to true inline audio linking.
- – flamurai (t) 23:10, Feb 24, 2005 (UTC)
-
-
-
[edit] The end break and text flow
I hope I haven't messed anything up too much here. I inserted an .ogg file at Aramaic language#Middle Syriac and the clear="all" attribute of the ending break tag meant that the next section began below the image to the template's right. I imagine this would happen every time this template is inserted in an article where there is an image or table aligned right: the following text is placed down the page to clear everything. To me, this just looks bad. If my attempt to fix this diplay issue isn't the best then please fix it properly. Gareth Hughes 22:32, 24 Feb 2005 (UTC)
[edit] New layout
It's a bit better. The thing is, it's not visually obvious the caption is connected to the sound file above it. Also, if you do a separate title/caption, you should remove the "Listen to" and let the user caption it however they want. For example, on Marching percussion I'd rather the caption be: "The battery percussion section – consisting of snare drums, multi-tenors, and bass drums – of the Cavaliers Drum and Bugle Corps performs a portion of their 2000 show unaccompanied."
I tested some of this out.
– flamurai (t) 20:29, Feb 25, 2005 (UTC)
[edit] Break into multiple templates
We should have two variants of this template: With and without a description. Pronunciations, for example, need no description, but the way this template is coded, there will be a blank line there. (I fixed this template to behave nicely with a blank description. – flamurai (t) 00:39, Feb 26, 2005 (UTC))
Also, I changed "listento" to "description" because it is more generic and gives us more flexibility. Even if we go back to the old "Listen to {{{description}}}", it still works.
- The reason why I named the variable "listento" because it enables the user to write to fit the sentence. If we go back to "Listen to", the variable should ideally be changed back, because it would imply "description=The Number One Song" which would appear as "Listen to The Number One Song", which doesn't quite fit. Dysprosia
Also, I think the multi-listen template should be done in the style of the phyla templates and such. That is,
{{multi-listen start}} {{multi-listen item|title=Whatever|filename=whatever.ogg|description=Whatever}} {{multi-listen item|title=Blah|filename=blah.ogg|description=Blah}} {{multi-listen end}}
That way the format stays consistent.
If we use the template as it is now, to get the right rowspan, we might have to use:
{{multi-listen start|item count = 2}} {{multi-listen item|title=Whatever|filename=whatever.ogg|description=Whatever}} {{multi-listen item|title=Blah|filename=blah.ogg|description=Blah}} {{multi-listen end}}x
– flamurai (t) 23:29, Feb 25, 2005 (UTC)
Example of my multi-listen idea here: User:Flamurai/Sandbox. – flamurai (t) 03:06, Feb 26, 2005 (UTC)
[edit] Bug report submitted about whitespace problem
I submitted a bug report about the ugly excess whitespace problem we're noticing with this template. – flamurai (t) 07:05, Feb 26, 2005 (UTC)
[edit] Audio template
Maybe we should consider joining this and the audio template. Or at least letting people know that an alternative exists. The other one is a bit more minimalistic, and much easier to integrate with text, but not quite as intuitive as this. Any suggestions? Peter Isotalo 23:43, Apr 6, 2005 (UTC)
- Would anyone mind if the info-link linked to the image file at Commons instead of the one locally? That way there would be no need to click twice or to have a double set of copyright info. Peter Isotalo 21:16, Apr 11, 2005 (UTC)
- No, don't link directly to commons, because (a) I'm not sure that all files using this template are located on commons, and (b) even if they all do now, there's no way to guarentee that they will in the future. →Raul654 22:28, Apr 11, 2005 (UTC)
[edit] |format=Ogg
what is the |format=[[Ogg]]
used for? it appears to have no function from the template source... - Omegatron 23:45, Apr 12, 2005 (UTC)
- It's an artifact. At one point we had some .MID files, and while they can no longer be uploaded, there are still a few around. Same with .WAV. There may still be some value to it in case we decide to support another format in the future. The Uninvited Co., Inc. 02:29, 13 Apr 2005 (UTC)
-
- Wouldn't it be better to remove it now and reinsert when/if we start supporting those formats? Peter Isotalo 12:22, Apr 13, 2005 (UTC)
-
-
-
- Yeah, leave it in, if there is a potential for it to be used again in the future. BUT WHAT DID IT DO? - Omegatron 17:55, Apr 13, 2005 (UTC)
-
-
-
- What did it do, though? How was it used? The filename already has the extension information. - Omegatron 17:55, Apr 13, 2005 (UTC)
[edit] box it
can we put this in a box to set it apart from the text? - Omegatron July 1, 2005 01:24 (UTC)
- The speaker icon sets it off from the text sufficiently. Adding a box would be superfluous. —Michael Z. 2005-07-1 16:12 Z
[edit] Commons only?
Will this work with audio that is part of Wikipedia but not part of Commons? --Theodore Kloba 17:42, July 21, 2005 (UTC)
- Yes. The Uninvited Co., Inc. 17:47, 21 July 2005 (UTC)
[edit] Setting template off from text
I saw in the discussion above that someone commented that this template is not for floating over to the right, but what if that's what we want to do? At the moment I am doing this:
<div style="float:right; margin-left: 10px;"> {{Listen|filename=XXXXX.ogg|title=XXXXX|description=XXXXX|format=[[Ogg]]}} </div>
but it's not working terribly well. Any advice welcome. pfctdayelise 04:39, 11 November 2005 (UTC) Oh, and the main problems are on pages that are already using right-floated templates. See for example No Aphrodisiac. pfctdayelise 04:44, 11 November 2005 (UTC)
[edit] metadata?
why are the descriptions of the sound file categorized as class="metadata"? This is supposed to be for things like site notices that don't get printed. — Omegatron 17:56, 26 February 2006 (UTC)
[edit] CSS version
I've been working on a new version of the {{listen}} template, that would use semantic HTML and CSS instead of tables. Here it is, more or less finished (Bypass your cache if you don't see the speaker icon):
<div class="medialist listenlist"> * [[Media:{{{filename}}}|{{{title}}}]] ([[:Image:{{{filename}}}|file info]]) ** {{{description}}} ** ''Problems listening to the file? See [[Wikipedia:Media help|media help]].'' </div>
- Accordion chords (file info)
- Chords being played on an accordion — 145 KB
- Problems listening to the file? See media help.
The markup is a lot simpler and it will degrade to a plain list (which is a Good Thing) to user agents that don't have CSS, like this:
- Accordion chords (file info)
- Chords being played on an accordion — 145 KB
- Problems listening to the file? See media help.
-- Blanked. See below for the new CSS --
With the CSS, it will look more or less like the original template, but the icon will just be decoration and won't be clickable. This is a good thing, too, since the audio help link should be included explicitly anyway, and the image won't go to the image description page, either.
If everyone likes it and my css is clean, I'll add this to the site-wide css and then we can replace the templates.
I've added it to the site CSS for the purpose of demonstration, but it can be tweaked before the templates are replaced.
It gets rid of the extra newlines, too, so we won't need the span hack.
See also Template_talk:Multi-listen_start#CSS_version — Omegatron 22:51, 26 February 2006 (UTC)
- It lacks the speaker (or video) icon, and basically blends into the text. This is a very bad thing. Raul654 00:04, 27 February 2006 (UTC)
- Also, what about the multi-item video and audio templates? Raul654 00:06, 27 February 2006 (UTC)
-
Read my whole post. You have to use the included CSS to get the visual styling with the icon.- Bypass your cache if you don't see the speaker icon. For user agents that don't support CSS, it will degrade to a standard list of items, which makes more sense than a table (it's not tabular data at all).
- This works for the multi-listen template, too, as I linked above, and also a note on the video templates to look here for discussion, since they're exactly the same template with a different icon. — Omegatron 01:21, 27 February 2006 (UTC)
-
-
- OK, I see everything fine now. Yes, I do like the new look. But, this isn't a CSS hack, is it? It's not gonna break for people looking at it on various browsers or at different resolutions, is it? Raul654 01:48, 27 February 2006 (UTC)
-
-
-
-
- That's the whole reason I made it. The current version relies on tables for visual layout, which is very bad and Evil, according to people who want to write accessible, interoperable code.
- So I made a version that doesn't. For people who don't have CSS, it will just look like a plain list of items, which it is. — Omegatron 02:01, 27 February 2006 (UTC)
-
-
- Using CSS instead of templates would be a good idea. How would it look for browsers which do not handle CSS?
- The eventual use of this template isn't quite what I envisaged for the template, but there appears to be a standard usage of the template now that should probably not be changed. Dysprosia 11:34, 27 February 2006 (UTC)
-
- Oh. This isn't CSS instead of templates; it's a CSS-based template. CSS instead of tables, rather.
- For browsers or user agents that don't support stylesheets, it will just look like a list. — Omegatron 14:25, 27 February 2006 (UTC)
-
-
-
-
- I was just about to amend my comment to say that. ;) Dysprosia 21:32, 27 February 2006 (UTC)
-
-
-
-
-
-
-
-
- Yes, it would be nice if you could type [[Media:something.ogg|style|description]] and give it parameters to make it look pretty, like image syntax does with framed and thumb. — Omegatron 01:13, 28 February 2006 (UTC)
-
-
-
-
- It works for me,
except for that ugly cropped drop shadow. – flamurai (t) 17:00, 27 February 2006 (UTC) - I just fixed the drop shadow, and the incorrectly oriented music notes. – flamurai (t) 17:10, 27 February 2006 (UTC)
-
- Drop shadow? Music notes? — Omegatron 21:03, 27 February 2006 (UTC)
-
-
-
- Ohhhhhhhhhh... in the icon image itself. Got it now. — Omegatron 04:20, 28 February 2006 (UTC)
-
-
Is there any reason why this should not go live? I'm willing to make hte necessary changes to the site CSS for both the audio and video links. Raul654 03:51, 28 February 2006 (UTC)
- I already made the changes to the site CSS, which is why you can see it. :-)
- Only the template needs to be changed to make this go live.
- The video template would need another set of CSS rules, with only the image url changed (which is sort of redundant. hmmm...) — Omegatron 04:20, 28 February 2006 (UTC)
- Ok, why don't you go ahead and fix that then? Raul654 04:20, 28 February 2006 (UTC)
I don't know how best to "fix that". Maybe something like this?
/* Icons for medialist templates [[Template:Listen]], [[Template:Multi-listen_start]], [[Template:Video]], [[Template:Multi-video_start]] */ div.listenlist { background: url("http://upload.wikimedia.org/wikipedia/commons/thumb/a/a6/Gnome-speakernotes.png/30px-Gnome-speakernotes.png"); padding-left: 40px; } div.videolist { background: url("http://upload.wikimedia.org/wikipedia/commons/thumb/0/0e/Video.svg/40px-Video.svg.png"); padding-left: 50px; } div.multivideolist { background: url("http://upload.wikimedia.org/wikipedia/en/thumb/7/7a/FilmRoll-small.png/40px-FilmRoll-small.png"); padding-left: 50px; } /* Style rules for media list templates */ div.medialist { min-height: 50px; margin: 1em; background-position: top left; background-repeat: no-repeat; } div.medialist ul { list-style-type: none; list-style-image: none; margin: 0; } div.medialist ul li { padding-bottom: 0.5em; } div.medialist ul li li { font-size: 91%; padding-bottom: 0; }
Gets complicated fast. — Omegatron 04:59, 28 February 2006 (UTC)
- I updated the site CSS with this version and put examples at Template talk:Video and Template talk:Multi-video start. Basically the same thing with different images. If there are any other similar templates, they would need a chunk of code, too. I changed it so this type of list has its own class medialist, and the icon to use is the only thing set by the listenlist/videolist class:
<div class="medialist videolist"> * Thing ** Thing ** Thing </div>
Then it requires less changes if more templates are added. (Are there any more besides these four?) Sorry for all this clutter on the talk page. — Omegatron 05:47, 2 March 2006 (UTC)
- Not to my knowledge. Raul654 05:51, 2 March 2006 (UTC)
[edit] Broken formatting
This template doesn't render correctly on GNU Free Documentation License#External links. Is it because of the bullets, or something else? GarrettTalk 09:08, 24 April 2006 (UTC)
- Yep. Because of the bullets. It could probably be fixed if needed, but why is that template used in the external links section? — Omegatron 14:06, 24 April 2006 (UTC)
[edit] File size
Perhaps it would be useful to add the size parameter to the template. I know all these files have their metadata accessible via the info link, however many people (like me sometimes) are: a) too lazy or impatient to wait for the description page to load, b) don't have a fast connection and are quite surprised in a negative way when they see the file has e.g. 8 MB. --Eleassar my talk 16:12, 16 June 2006 (UTC)
- I agree. It should be an optional parameter. — Omegatron 01:00, 19 June 2006 (UTC)