Closed
Bug 509757
Opened 16 years ago
Closed 16 years ago
A shorthand for height and width in CSS
Categories
(Core :: CSS Parsing and Computation, enhancement)
Core
CSS Parsing and Computation
Tracking
()
RESOLVED
WONTFIX
People
(Reporter: deprecationmail, Unassigned)
Details
User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; sv-SE; rv:1.9.1.2) Gecko/20090729 Firefox/3.5.2
Build Identifier:
This idea came from https://developer.mozilla.org/en/Mozilla_CSS_support_chart, when I saw there was a property called "size". Apparently, this was removed in CSS 2.1. I couldn't find what this was supposed to do, but it was related to paged media which makes me think that it wasn't related to what my suggestion.
It needs a name, and as size seems to have returned in CSS3, we'll have to figure out something else, but I'll use it in my examples below.
What I suggests looks something like this:
#image{
background: url(image.png);
size: 50px 200px;
}
Where the first value represents height, and the second width, or reversed.
This can also be useful for setting the same height and width for an image.
#image{
background: url(image.png);
size: 200px;
}
Now the image has the size 200px on both height and width.
What do you think?
Reproducible: Always
I don't think we want to do this; height and width are clear and well known; if we add aliases for them it will make style sheets harder to read for people who already know CSS, and it doesn't add anything useful.
Status: UNCONFIRMED → RESOLVED
Closed: 16 years ago
Resolution: --- → WONTFIX
I see. The benefit I could see with this was shorter code, and therefore less to download and easier to write, but yes, it's probably not worth it.
You need to log in
before you can comment on or make changes to this bug.
Description
•