Jump to content

Wikipedia talk:Extended image syntax

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by Mike Christie (talk | contribs) at 09:25, 15 July 2021 (Coordinates of the thing the image is of: Thanks). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
WikiProject iconWikipedia Help NA‑class Low‑importance
WikiProject iconThis page is within the scope of the Wikipedia Help Project, a collaborative effort to improve Wikipedia's help documentation for readers and contributors. If you would like to participate, please visit the project page, where you can join the discussion and see a list of open tasks. To browse help related resources see the Help Menu or Help Directory. Or ask for help on your talk page and a volunteer will visit you there.
NAThis page does not require a rating on the project's quality scale.
LowThis page has been rated as Low-importance on the project's importance scale.

How do we specify background color?

How do we specify a background color, so that e.g. black text is visible on a black background? I'm looking at the info box in Atlantean language. Thanks. — kwami (talk) 06:37, 16 April 2021 (UTC)[reply]

I have an idea. Give me 15 minutes... nagualdesign 07:05, 16 April 2021 (UTC)[reply]
..Took a little longer than expected. I created a new image file, File:Dig Adlantisag.png, and added it to the infobox. Ping me if you'd like any alterations. nagualdesign 07:44, 16 April 2021 (UTC)[reply]
Thanks! That looks beautiful; I was hoping for an easy fix rather than hand the work over to someone else, but there probably won't be many times we need to do something like this. — kwami (talk) 08:26, 16 April 2021 (UTC)[reply]
I don't mind in the least. It was pretty straightforward. I could do something similar for the Klingon language infobox if you like. nagualdesign 08:34, 16 April 2021 (UTC)[reply]
..Since the Klingon fonts don't show up on desktop or mobile I went ahead and replaced the altname parameter with File:tlhIngan Hol.png. nagualdesign 10:26, 16 April 2021 (UTC)[reply]

Displaying thumb of some video without that "Play the Video"-Button

Interview with Ward Cunningham, inventor of the wiki

Is there any way, any magic keyword to show just the preview image of a video without that Start-Button, like it is in Page information of Wiki? --Wurgl (talk) 09:23, 21 May 2021 (UTC)[reply]

I think your best bet would be WP:TemplateStyles to set background-image: none on .mw-tmh-player.video > .mw-tmh-play:not(:hover). The last part of that makes sure the play button is able to reappear on hover. User:GKFXtalk 11:42, 21 May 2021 (UTC)[reply]
It is for german wikipedia where that template is missing. Importing that template (causing sure a lot of discussion) is too much effort for a very few (maybe 3) videos/images. I was hoping there might be some undocumented parameter. However, thanks. --Wurgl (talk) 09:34, 23 May 2021 (UTC)[reply]

Coordinates of the thing the image is of

Is there syntax for or a way to use coordinates for the thing that the image is an image of? E.g. if you have a picture that is of a particular building in a town, the coords for the article will be for the town. The picture may have coords in its metadata of course, but that’s invisible in any article it’s included in. I ask because a friend in real life recently added a picture and wanted to specify exactly where it was, and I realized I’d never seen this use case before.

For example, I took two of the pictures in Loch Muick, and they’re far enough apart to have noticeably different coords. Is there a natural way to add that information to those images in that article? Mike Christie (talk - contribs - library) 02:02, 13 July 2021 (UTC)[reply]

The obvious place for such coordinates would be via {{coord}} in the image's caption. -- Michael Bednarek (talk) 03:22, 13 July 2021 (UTC)[reply]
I tried this with {{Coord| 56.851082| -3.741822|display=inline|name=Dail-an-eas bridge}} in the fourth image in Glen Tilt. (The documentation for {{Coord}} made me think it was only for the main article location.) It works, but it doesn't look as if anyone ever expected coord to be used this way -- the "name" parameter does nothing in the article, and in the linked GeoHack page it does use it as the (easily missed) page title, but also gives it as the article name in the link back to Wikipedia. It would be nice if the image syntax allowed something prettier to be automatic. For example the Glen Tilt page itself has "Coordinates: inline 56°49′59″N 3°46′34″W / 56.833°N 3.776°W / 56.833; -3.776" at the top right, with tooltip text for the button saying "Show location on an interactive map". Can something like that be made to happen when a coord is used in an image caption? Perhaps using the name parameter to make it "Show Dail-an-eas bridge on an interactive map" for the tooltip? Mike Christie (talk - contribs - library) 05:34, 13 July 2021 (UTC)[reply]
A facility for image coordinates already exists, although not in the form you want. See "Camera location" in the "Summary" section of the file description page for this image. We could debate the merits of making it more visible/accessible, but in my opinion it would be a bad idea for multiple reasons. It would be unwise to allow the same information in both places, with no mechanism to ensure that they are in agreement. The information in the file description is for readers as well as editors, and it would not serve readers in the long term to protect them from having to learn to use it. My suggestion is to update the file description with the coordinates, revert your change to the caption, and call it a day. 68.97.42.64 (talk) 06:21, 13 July 2021 (UTC)[reply]
The popup for WikiMiniAtlas is obscured if {{coord}} appears in the last line of an image caption. This can be avoided by using it earlier in the caption, or by adding 2 line breaks after it. -- Michael Bednarek (talk) 11:05, 13 July 2021 (UTC)[reply]
I see what you mean; I added a couple of line breaks and the WikiMiniAtlas popup is now visible. It sounds like that's the best current answer. I take the IP's point about the image file being the natural places for the coordinates to live, but that shouldn't prevent useful reader functionality -- a template that was able to extract the coords from the image file and display a WikiMiniAtlas link would be a nice gadget to place inside a caption. I'll suggest that at VPT. Mike Christie (talk - contribs - library) 12:35, 13 July 2021 (UTC)[reply]
I'm with 68.97.42.64 on this. Commons provides a number of templates specifically for this, which are used on file description pages - they include c:Template:Globe location, c:Template:Location and c:Template:Object location. --Redrose64 🌹 (talk) 15:55, 13 July 2021 (UTC)[reply]
Thanks for the links; those look like what I was looking for. Mike Christie (talk - contribs - library) 09:25, 15 July 2021 (UTC)[reply]