This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
HTML5 should make it clear that when the image from the <img> element is not rendered the height/width DOM attributes return the intrinsic image height/width and not zero. (A May version of the draft had this backwards and the current version is not clear; probably because the rendering section is not done yet.)
Yeah, it should return 0 when there's no image, and the intrinsic width if the image isn't rendered.
Ian : what do you call 'no image' : an empty source, or an 404 HTTP request ? And is 'intrinsic image height/width' overriden by @width and @height img attributes ?
Does the text in the spec now answer those questions?
Ian, if you mean http://dev.w3.org/cvsweb/~checkout~/html5/spec/Overview.html?rev=1.1128#dimension0, the last sentence miss the img tag ("The width and height DOM attributes on the embed, object, and video elements must reflect the content attributes of the same name."). And if the img is missing, yes, it answers my question, thanks.
Well I don't only mean that section, I also mean the bits that define HTMLImageElement.height and .width, the height/width content attributes, fetching, and so forth.
You mean "The DOM attributes width and height must return the rendered width and height of the image, in CSS pixels, if the image is being rendered, and is being rendered to a visual medium; or else the intrinsic with and height of the image, in CSS pixels, if the image is available but not being rendered to a visual medium; or else 0, if the image is not available or its dimensions are not known." ? (I think that the last 'or', "if the image is not available or its dimensions are not known.", should be an 'and'.)
So what should it return if the image is available but it's dimensions are not known? (e.g. it has no intrinsic dimensions, like a dynamically sized gradient or infinite pattern)
Ok, would never have though to so strange 'images'... Thank you very much.
This bug predates the HTML Working Group Decision Policy. If you are satisfied with the resolution of this bug, please change the state of this bug to CLOSED. If you have additional information and would like the editor to reconsider, please reopen this bug. If you would like to escalate the issue to the full HTML Working Group, please add the TrackerRequest keyword to this bug, and suggest title and text for the tracker issue; or you may create a tracker issue yourself, if you are able to do so. For more details, see this document: http://dev.w3.org/html5/decision-policy/decision-policy.html This bug is now being moved to VERIFIED. Please respond within two weeks. If this bug is not closed, reopened or escalated within two weeks, it may be marked as NoReply and will no longer be considered a pending comment.