W3C home > Mailing lists > Public > www-style@w3.org > March 2009

Re: [Backgrounds/Borders] What to do when a border-image fails to load

From: Brad Kemper <brad.kemper@gmail.com>
Date: Thu, 26 Mar 2009 08:43:50 -0700
Cc: "www-style@w3.org list" <www-style@w3.org>
Message-Id: <24E9F156-6E14-4B47-9622-D0453FFE4EC2@gmail.com>
To: David Hyatt <hyatt@apple.com>

On Mar 25, 2009, at 12:06 PM, David Hyatt wrote:

> http://www.w3.org/TR/2008/WD-css3-background-20080910/#the-border- 
> image
>
> contains the following sentence:
>
> "If the slash is present in the property value, the one to four  
> values after it are used for the width of the border instead of the  
> ‘border-width’ properties (but only if the specified image can be  
> displayed)."
>
> [..]
>
> If the image fails to load, it's only going to be after trying for a  
> while, and therefore an implementation honoring the language above  
> would end up popping back to the original border-widths as specified  
> somewhere else, but only after the image load has failed.
>
> It's best for the border-image to just always set the border widths,  
> even if the image fails to load.  That way on a failure, the entire  
> box doesn't change size.

Is this mainly a problem with the geometry changing? That is, if the  
width of the image border were the same as the border-width, would you  
be able to go in and un-paint the border and repaint it with the image  
many seconds or minutes later (after the image loaded), without too  
much trouble? If not, because of the complexities of stacking contexts  
and such, then maybe "failed to load" should be excluded from the  
fallback feature of this property, and it should only fall back for  
"user has images turned off" and "UA doesn't support images or this  
image type".
Received on Thursday, 26 March 2009 15:44:28 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:17 GMT