Template:Gallery 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 template-protected)) to notify an administrator or template editor 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 for discussing improvements to the Gallery template. |
|
Archives: 1, 2Auto-archiving period: 90 days |
This template does not require a rating on Wikipedia's content assessment scale. It is of interest to the following WikiProjects: | ||||||||
|
Hello,
Module:Gallery contains the following lines:
gargs['widths'] = tonumber(args.width) or 180
gargs['heights'] = tonumber(args.height) or 180
That sure makes it sound like the default width / height for traditional galleries is supposed to be 180x180. However, this is not actually true. Either gargs isn't being used at all, or else some other bit of parsing later on down the line throws it out, because the default gallery size end up being 120x120 if no width / height arguments are passed in. Is this a bug, or a feature? Where is the step that actually changes an unset widths / heights to 120?
(Context: I'm considering starting an RFC to change the default to something larger, but would like to know the technical constraints first. Maybe there's some deep issue with doing that or other problem to be aware of.) SnowFire (talk) 03:33, 9 September 2023 (UTC)
((gallery))
? Here is a comparison between <gallery>...</gallery>
and ((gallery))
, both in minimal form:
<gallery>...</gallery>
, these images render at 120×89 and 95×120:
<gallery> Stephen Taber and the Rockland Breakwater.jpg|''Stephen Taber'' and the Rockland Breakwater Schooner Stephen Taber, around 1900.jpg | ''Stephen Taber'' anchored off Long Island c. 1900 </gallery>
((gallery))
, these images render at 182×135 and 144×182:
((gallery |File:Stephen Taber and the Rockland Breakwater.jpg|''Stephen Taber'' and the Rockland Breakwater |File:Schooner Stephen Taber, around 1900.jpg | ''Stephen Taber'' anchored off Long Island c. 1900 ))
bordered-images
css class (Module:Gallery/styles.css line 76).frame:extensionTag{ name = 'gallery', content = '\n' .. table.concat(gallery,'\n'), args = gargs}
<gallery>...</gallery>
tag that looks like this:
<gallery class="nochecker bordered-images whitebg" heights="180" widths="180">
File:Stephen Taber and the Rockland Breakwater.jpg|Stephen Taber and the Rockland Breakwater
File:Schooner Stephen Taber, around 1900.jpg|Stephen Taber anchored off Long Island c. 1900</gallery>
<gallery>...</gallery>
tag default. If you want to change the <gallery>...</gallery>
tag default, this template/module is not the place to do it. Perhaps en.wiki has a configuration switch that can be changed increase <gallery>...</gallery>
tag default height/width. You might ask at WP:VPT.<gallery>...</gallery>
, which is an extension to the MediaWiki software. Changes to the latter are discussed at Help talk:Gallery tag. --Redrose64 🌹 (talk) 21:47, 17 September 2023 (UTC)See the discussion here: is it possible to remove the empty spaces between images in a gallery tag in "packed" mode? Jarble (talk) 16:07, 21 September 2023 (UTC)
I am trying to make 2 pie charts be right next to eachother, they are the same size. Can i use Template:Pie chart inside of the gallery template? 😎😎PaulGamerBoy360😎😎 (talk) 15:54, 14 December 2023 (UTC)
This edit request to Module:Gallery/styles.css has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Last year the <gallery> tag dropped large margin at the left side, and make use of px
unit instead to produce more compact view. So this template need to update to follow on. In this template I made changes for these three classes: mod-gallery-default
, title
, footer
. You can see the changes here, and you can also see the effects on c:Template:Gallery. -- Great Brightstar (talk) 16:37, 10 June 2024 (UTC)