Last modified: 2007-03-25 00:39:15 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 9409 - Image frame width in units other than pixels
Image frame width in units other than pixels
Status: RESOLVED DUPLICATE of bug 7048
Product: MediaWiki
Classification: Unclassified
File management (Other open bugs)
unspecified
All All
: Normal enhancement (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2007-03-24 07:14 UTC by Eugene Pivovarov
Modified: 2007-03-25 00:39 UTC (History)
0 users

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Eugene Pivovarov 2007-03-24 07:14:50 UTC
Most of Wikipedia articles explicitly set the sizes of the thumb images (instead of relying on 
user preferences). Since presently the image size can only be given in pixels, the articles are 
optimized for a particular screen resolution (typically 1024x768) and look very different at 
other resolutions. Therefore, it is highly desired to have the possibility to specify the width 
of the image frame in non-pixel CSS length units: in, cm, mm, pc, pt, em or ex. For example:

<nowiki>[[Image:Picture.jpg|thumb|2in|Caption text]]</nowiki>

Here is how the non-pixel width could be processed by the engine. First, it generates the 
image with the number of pixels corresponding to the provided width at the resolution 
specified in user preferences or by default -- say, 90 dpi. Thus, in the example above it 
would render an image 180px wide by default. Second, the server returns an XHTML with the 
img tag that contains no width or height attributes and instead contains only a style 
attribute that specifies the required width of the image:

<nowiki><img src="Picture.jpg" style="width: 2in;"/></nowiki>

Thus, at higher screen resolutions the browser will scale up the image so that it will always 
have 90 dpi.
Comment 1 Eugene Pivovarov 2007-03-24 07:17:18 UTC
Please ignore nowiki tags above; I just was not sure how the bug reports are displayed.
Comment 2 Aryeh Gregor (not reading bugmail, please e-mail directly) 2007-03-25 00:39:15 UTC

*** This bug has been marked as a duplicate of 7048 ***

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links