Re: [css4-values] border-image-repeat 'extend' keyword?

On Dec 19, 2011, at 10:26 AM, fantasai <fantasai.lists@inkedblade.net> wrote:

> On 04/12/2010 01:44 PM, Joe Marty wrote:
>> lease correct me if I'm out of order ;)
>> 
>> I have searched the archive and not found any discussion of an additional keyword for the border-image-repeat property that would extend the size of the content box to fit the next whole number of border tiles.  That seems like it would be a popular and more acceptable solution in many instances, compared to stretching the border image (i.e. when the box doesn't even have a specific size to begin with).  Admittedly, it changes the size of the content box, which is unusual, but perhaps a specific width/height given to the box would over-ride this option (as would a max-height/max-width, whereas a min-height or min-width would not).
>> 
>> Perhaps I've come too late to suggest this, but I think this would be a very useful alternative to stretching your border image, and I think the keyword 'extend' would be appropriate for this function.
> 
> Probably a round() function for 'width' and 'height' would make more sense
> here than an 'extend' keyword for background-repeat. :) 

He said 'border-image-repeat', but I guess 'background-repeat' has the same issue. 

Hmm. I actually think it would be more natural to have it as a keyword alternative to 'round', when the width or height (as appropriate for the dimension specified) is 'auto'. So you either round the tile or you round the width or height, which seems a more natural way of think of it. The width and height, if 'auto', is still automatic, it just has one more thing to think about when automatically determining the width or height.

It seems very specific to border-image and background. I don't know what else a 'round()' function on width and height would consider. So if it is just for border-image and background, and doesn't make sense when 'border-image-repeat' and 'background-repeat' values other than 'repeat' are used, then that is where it should be authored. It would be more like adjusting the margin than like adjusting actual 'width' and 'height' values. 

I don't think the keyword should be 'extend' though. I'd rather see the border-image-area contract if 'border-image-offset' is zero and 'border-image-repeat' is the new keyword, and the background-positioning-area box contract if 'background-repeat' is the new keyword. This, it doesn't cause overflow on its container. The container still contains, unless 'border-image-offset' would already cause the border to expand outwards. Maybe the keyword should be 'fit' or 'compact' or something. 

Do we have a CSS4 backgrounds and borders wiki?

Received on Monday, 19 December 2011 20:37:39 UTC