News for hackers. Stuff that matters.
Re:Less.js will obsolete CSS by baddox on Sunday June 20, 2010 @04:14AM (#1446106)
Literally the only problem with CSS itself is that it doesn't have defines. Every other problem is just browser implementations.
Re:Less.js will obsolete CSS by KevinMS on Sunday June 20, 2010 @04:33AM (#1446145)
I also have issues with the "box model." Judging by the popularity of grid layout systems like blueprint and 960 I think others also do.

The box model is fine when you just need to "flow" things around things, like text around images, and typical blog designs, but when you develop complicated interfaces it really shows its limitations and costs many hours of frustrating effort.

Re:Less.js will obsolete CSS by noibl on Sunday June 20, 2010 @06:28AM (#1446256)
Not sure if this is what you're referring to, but you can have a box model that includes padding and border in the width using CSS3:

  box-sizing: border-box
with -ms- (IE8), -moz- and -webkit- prefixes.

http://www.quirksmode.org/css/box.html

Re:Less.js will obsolete CSS by KevinMS on Sunday June 20, 2010 @11:16AM (#1446572)
Re:Less.js will obsolete CSS by stan_rogers on Monday June 21, 2010 @10:08AM (#1448812)
Right CSS version, wrong module: http://www.w3.org/TR/css3-ui/#box-sizing

The CSS3 UI module is a candidate recommendation. Setting:

box-sizing: border-box;

essentially puts the CSS box model render mode to where it was in IE5 (which is, frankly, the only sensible way to do it). Right now, it is available with Mozilla, Webkit and Microsoft prefixes (as are most of the UI module properties).

Re:Less.js will obsolete CSS by baddox on Sunday June 20, 2010 @01:34PM (#1446823)
Isn't CSS3 supposed to fix that or at least give us another option? I should have specified that I was referring to CSS3.
Re:Less.js will obsolete CSS by Chris_Newton on Sunday June 20, 2010 @08:29AM (#1446376)
Literally? I don't think so.

CSS has very weak layout capabilities.

CSS has weak typography.

CSS has weak colour system support.

In each case, this is partly due to limitations in the underlying model, but also partly due to having limited syntax.

In each case CSS3 modules may improve things somewhat if and when they are widely supported, but even the best proposals there aren't even close to the power of a good DTP tool or the control of a native application. When the web is trying to take over from both, CSS isn't a good tool, it's just the best we've got right now.

Re:Less.js will obsolete CSS by rabidgnat on Sunday June 20, 2010 @10:38AM (#1446498)
There are plenty of problems with CSS. You can't specify the width of an inline element, for one. That alone prevents a lot of reasonable layouts, like tables. Also problematic is a standards body that ignores this use case! In this case, they protect the writer from over-filling some boxes with more boxes. But that would at least be visible - in this case, the workarounds end up far worse.
Re:Less.js will obsolete CSS by what on Sunday June 20, 2010 @11:47AM (#1446632)
If you want a table layout, why not just use a table? Or you can use display: inline-block if you want to give a width to an inline element.
Re:Less.js will obsolete CSS by rabidgnat on Sunday June 20, 2010 @05:54PM (#1447255)
I run into plenty of situations where I have multiple lines, and I'd like the respective elements to align. It's not limited to tabular data, but it's the easiest example
Re:Less.js will obsolete CSS by Daniel_Newby on Sunday June 20, 2010 @04:15PM (#1447103)
Tables FTW. It's the HTML element for controlling horizontal and vertical relationships at the same time.
Re:Less.js will obsolete CSS by huhtenberg on Monday June 21, 2010 @01:19AM (#1448048)
> You can't specify the width of an inline element, for one.

  display: inline-block;
  width: ...

?
Re:Less.js will obsolete CSS by rabidgnat on Monday June 21, 2010 @08:17AM (#1448552)
Unfortunately, bad browser support :/

http://www.quirksmode.org/css/display.html

Re:Less.js will obsolete CSS by huhtenberg on Monday June 21, 2010 @12:54PM (#1449326)
That was primarily in the context of "Also problematic is a standards body that ignores this use case!" part of your comment.

Besides if you don't care about antiquated browsers (eg IE6), the inline-block is a viable option. In IE it will require some massaging, but it can be made to work quite easily.

Re:Less.js will obsolete CSS by isleyaardvark on Sunday June 20, 2010 @09:37AM (#1446439)
The lack of a proper layout system causes a huge number of problems, and is the reason the "tables vs. css" argument can still occasionally pop up. The nuts box model has already been mentioned.
Re:Less.js will obsolete CSS by schammy on Sunday June 20, 2010 @08:14PM (#1447491)
I agree for the most part, but as the "only" problem, it's a seriously gigantic one. CSS is cool but this limitation is so frustrating, especially once your style sheets start getting really big.