Re: [gcpm] border-parts

Also sprach Brad Kemper:

 > > This is identical to 'border-parts: repeat(20px 10px 0 1fr)' in the
 > > previous proposal, it seems.
 > 
 > Correct. Except that, if I understand correctly, one of the things  
 > that made it complicated was when you stung it together with other  
 > parts, like this:
 > 
 > border-parts: 1fr 5px repeat(20px 10px 0 1fr);
 > 
 > So my change to help simplify is to say that "repeat" would be for the  
 > whole string of lengths, and not for substrings of lengths.

It's not much simpler and it doesn't address the fundamental
competition between the two: you would still have repeating patterns
and fr units in the same border.

 > > The problem is the competition that appears between repeat and
 > > fractions. We think of fractions as eating up the leftover space.
 > > However, 'repeat' is also very good at eating leftovers and this makes
 > > fractions go towards 0.
 > 
 > True, but with repeated patterns I would really like to be able to  
 > have dash patterns that line up on the corners nicely, preferably in a  
 > way that was symmetrical on both ends.

In the old prosal, you could to this with:

  border-top: 20px 10px 0 1fr repeat(10px 10px 0 1fr) 0 10px 0 1fr 20px;

This would have given you 20px end parts, 10px middle parts, and 10px
+ equal flex between the visible parts.

The trick is to use "10px 0 1fr" to express "a flex with a minimum
length of 10px".

This is possibly useful.

However, it's a bit cryptic and I think it falls short of all the
other things people would like to do if they could design their own
"dashed" or "dotted" styles. Don't you want 3d effects, shadows,
colors and gradiants on those border parts?

I don't think border-parts lends itself to these kinds of extenstions
and I therefore think a separate proposal for CSS4 Borders and
Backgrounds is better.

-h&kon
              Håkon Wium Lie                          CTO °þe®ª
howcome@opera.com                  http://people.opera.com/howcome

Received on Thursday, 6 November 2008 14:28:58 UTC