<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>
<channel>
	<title>Comments on: CSS Repeats Itself</title>
	<atom:link href="http://cafe.elharo.com/web/css-repeats-itself/feed/" rel="self" type="application/rss+xml" />
	<link>http://cafe.elharo.com/web/css-repeats-itself/</link>
	<description>Longer than a blog; shorter than a book</description>
	<pubDate>Tue, 06 Jan 2009 12:03:45 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.6.3</generator>
		<item>
		<title>By: UsabilitÃ  &#171; Usability, accessibility and the Web World</title>
		<link>http://cafe.elharo.com/web/css-repeats-itself/#comment-79086</link>
		<dc:creator>UsabilitÃ  &#171; Usability, accessibility and the Web World</dc:creator>
		<pubDate>Thu, 19 Apr 2007 09:37:33 +0000</pubDate>
		<guid isPermaLink="false">http://cafe.elharo.com/web/css-repeats-itself/#comment-79086</guid>
		<description>[...] Ecco qui il link al post: CSS repeats itself. [...]</description>
		<content:encoded><![CDATA[<p>[...] Ecco qui il link al post: CSS repeats itself. [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Andy Stewart</title>
		<link>http://cafe.elharo.com/web/css-repeats-itself/#comment-37999</link>
		<dc:creator>Andy Stewart</dc:creator>
		<pubDate>Fri, 15 Dec 2006 11:17:19 +0000</pubDate>
		<guid isPermaLink="false">http://cafe.elharo.com/web/css-repeats-itself/#comment-37999</guid>
		<description>If you're using Ruby on Rails, you may be interested in &lt;a href="http://blog.airbladesoftware.com/2006/12/11/cssdryer-dry-up-your-css" rel="nofollow"&gt;css_dryer&lt;/a&gt;, a plugin I recently wrote to avoid duplication in selectors and introduce variables.</description>
		<content:encoded><![CDATA[<p>If you&#8217;re using Ruby on Rails, you may be interested in <a href="http://blog.airbladesoftware.com/2006/12/11/cssdryer-dry-up-your-css" onclick="javascript:pageTracker._trackPageview('/outbound/comment/blog.airbladesoftware.com');" rel="nofollow">css_dryer</a>, a plugin I recently wrote to avoid duplication in selectors and introduce variables.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: johnk</title>
		<link>http://cafe.elharo.com/web/css-repeats-itself/#comment-23459</link>
		<dc:creator>johnk</dc:creator>
		<pubDate>Thu, 19 Oct 2006 23:55:50 +0000</pubDate>
		<guid isPermaLink="false">http://cafe.elharo.com/web/css-repeats-itself/#comment-23459</guid>
		<description>A complete solution for liquid layouts, that doesn't involve programming, probably doesn't exist.  Look at how complex TeX is... and that's specially tuned to produce text flows for a pretty narrow range of documents (basically, textbooks and math papers).  Web pages can be books, blogs, hypertexts, newspapers, and brochures.</description>
		<content:encoded><![CDATA[<p>A complete solution for liquid layouts, that doesn&#8217;t involve programming, probably doesn&#8217;t exist.  Look at how complex TeX is&#8230; and that&#8217;s specially tuned to produce text flows for a pretty narrow range of documents (basically, textbooks and math papers).  Web pages can be books, blogs, hypertexts, newspapers, and brochures.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: David Singleton</title>
		<link>http://cafe.elharo.com/web/css-repeats-itself/#comment-23396</link>
		<dc:creator>David Singleton</dc:creator>
		<pubDate>Thu, 19 Oct 2006 16:34:43 +0000</pubDate>
		<guid isPermaLink="false">http://cafe.elharo.com/web/css-repeats-itself/#comment-23396</guid>
		<description>I completely agree with the gist of your post.

CSS is far from perfect. Ignoring browser bugs there are still many things that make my life difficult on a day to day basis at work. Personally I would find a  CSS variable system far more useful for colours than for px widths. 

Some kind of CSS variable system would be a huge step forward, and many people have been using the 'CSS+V' solution for years, in itself this shows there really is call for it to be discussed and included in the CSS spec in the distant future.

However I disagree with the example you've chosen, and most of the comments that people have been left. 

There seems to be quite a divide between traditional programmers and those who work with CSS/HTML. I work with both client side and server side web coding on a daily basis, so I'd like to think I have a slightly balanced opinion (I'm sure many might disagree)

The example you chose is a particular method of doing a traditional 3 col layout that happens to rely on a fair amount of negative margins and position juggling. It's a quite extreme example to take. There are other methods that require far less repitition to achieve the same goal.

While I'll willingly admit that CSS has its flaws and needs much improvement, I'm really quite baffled as to how people still prefer tables. The only real advantage they offer is the ease of an equal height multi-column layout, something which is achievable with CSS, in some cases using a combination of a single table to layout columns and then CSS for everything else is by far the simplist solution.

It seems that a lot of the comments here advocate tables rather than CSS entirely, not just for layout. Once you get beyond simple columns, tables become incredibly complex compared to CSS. I've spent a lot of time working with both table and semantic/CSS sites, and by far semantic HTML/CSS is _much_ easier to build and maintain. I'd love to hear someone who has to work with the resulting HTML for any length of time argue the pluses of tables.

Phew, bit of a rant.</description>
		<content:encoded><![CDATA[<p>I completely agree with the gist of your post.</p>
<p>CSS is far from perfect. Ignoring browser bugs there are still many things that make my life difficult on a day to day basis at work. Personally I would find a  CSS variable system far more useful for colours than for px widths. </p>
<p>Some kind of CSS variable system would be a huge step forward, and many people have been using the &#8216;CSS+V&#8217; solution for years, in itself this shows there really is call for it to be discussed and included in the CSS spec in the distant future.</p>
<p>However I disagree with the example you&#8217;ve chosen, and most of the comments that people have been left. </p>
<p>There seems to be quite a divide between traditional programmers and those who work with CSS/HTML. I work with both client side and server side web coding on a daily basis, so I&#8217;d like to think I have a slightly balanced opinion (I&#8217;m sure many might disagree)</p>
<p>The example you chose is a particular method of doing a traditional 3 col layout that happens to rely on a fair amount of negative margins and position juggling. It&#8217;s a quite extreme example to take. There are other methods that require far less repitition to achieve the same goal.</p>
<p>While I&#8217;ll willingly admit that CSS has its flaws and needs much improvement, I&#8217;m really quite baffled as to how people still prefer tables. The only real advantage they offer is the ease of an equal height multi-column layout, something which is achievable with CSS, in some cases using a combination of a single table to layout columns and then CSS for everything else is by far the simplist solution.</p>
<p>It seems that a lot of the comments here advocate tables rather than CSS entirely, not just for layout. Once you get beyond simple columns, tables become incredibly complex compared to CSS. I&#8217;ve spent a lot of time working with both table and semantic/CSS sites, and by far semantic HTML/CSS is _much_ easier to build and maintain. I&#8217;d love to hear someone who has to work with the resulting HTML for any length of time argue the pluses of tables.</p>
<p>Phew, bit of a rant.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: johnk</title>
		<link>http://cafe.elharo.com/web/css-repeats-itself/#comment-23219</link>
		<dc:creator>johnk</dc:creator>
		<pubDate>Wed, 18 Oct 2006 22:30:10 +0000</pubDate>
		<guid isPermaLink="false">http://cafe.elharo.com/web/css-repeats-itself/#comment-23219</guid>
		<description>I do this all the time:

.selector { property:  }

It's a little ugly, but it works, and is pretty clear to me.

If you want to be more snazzy, you could do something like those server side constants, but, maybe a little less intrusively.  You could write a preprocessor that will magically replace values in the CSS that's formatted with the macro names after the values, like this:

#right {
  width: 150px;          /* rightWidth */
  margin-right: -150px;  /* rightMargin */
}

The preprocessor would just look for comments after values, and replace the value.  If you wanted to be really clever (and who doesn't) set the value of the macro by the first usage of it.  That is, the first occurence of "150px; /* rightWidth */" would define rightWidth as "150px".  Maybe a text editor hack could be used to "process the macros" and allow you to do it all client-side.</description>
		<content:encoded><![CDATA[<p>I do this all the time:</p>
<p>.selector { property:  }</p>
<p>It&#8217;s a little ugly, but it works, and is pretty clear to me.</p>
<p>If you want to be more snazzy, you could do something like those server side constants, but, maybe a little less intrusively.  You could write a preprocessor that will magically replace values in the CSS that&#8217;s formatted with the macro names after the values, like this:</p>
<p>#right {<br />
  width: 150px;          /* rightWidth */<br />
  margin-right: -150px;  /* rightMargin */<br />
}</p>
<p>The preprocessor would just look for comments after values, and replace the value.  If you wanted to be really clever (and who doesn&#8217;t) set the value of the macro by the first usage of it.  That is, the first occurence of &#8220;150px; /* rightWidth */&#8221; would define rightWidth as &#8220;150px&#8221;.  Maybe a text editor hack could be used to &#8220;process the macros&#8221; and allow you to do it all client-side.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: gman</title>
		<link>http://cafe.elharo.com/web/css-repeats-itself/#comment-23164</link>
		<dc:creator>gman</dc:creator>
		<pubDate>Wed, 18 Oct 2006 15:36:33 +0000</pubDate>
		<guid isPermaLink="false">http://cafe.elharo.com/web/css-repeats-itself/#comment-23164</guid>
		<description>It's funny to me that people complain about tables because the content is not separated from the layout and yet CSS comes no where close to separating content from layout. If content was truly separate from layout I should be able to specify the content in any order. I should also not have to nest images in 2-3 layers of divs just to get a dropshadow. I should not be resigned to displaying articles in the order they appear in the html.

And, as far as Taylor's example table above, CSS still can't handle with the content is larger than the defined space. Tables will adjust themselves to fit the content. CSS still can't :-(

http://greggman.com/edit/editheadlines/2004-06-15.htm</description>
		<content:encoded><![CDATA[<p>It&#8217;s funny to me that people complain about tables because the content is not separated from the layout and yet CSS comes no where close to separating content from layout. If content was truly separate from layout I should be able to specify the content in any order. I should also not have to nest images in 2-3 layers of divs just to get a dropshadow. I should not be resigned to displaying articles in the order they appear in the html.</p>
<p>And, as far as Taylor&#8217;s example table above, CSS still can&#8217;t handle with the content is larger than the defined space. Tables will adjust themselves to fit the content. CSS still can&#8217;t <img src='http://cafe.elharo.com/wp-includes/images/smilies/icon_sad.gif' alt=':-(' class='wp-smiley' /> </p>
<p><a href="http://greggman.com/edit/editheadlines/2004-06-15.htm" onclick="javascript:pageTracker._trackPageview('/outbound/comment/greggman.com');" rel="nofollow">http://greggman.com/edit/editheadlines/2004-06-15.htm</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: zappini</title>
		<link>http://cafe.elharo.com/web/css-repeats-itself/#comment-20728</link>
		<dc:creator>zappini</dc:creator>
		<pubDate>Thu, 05 Oct 2006 18:49:35 +0000</pubDate>
		<guid isPermaLink="false">http://cafe.elharo.com/web/css-repeats-itself/#comment-20728</guid>
		<description>I tried to study and use constraint systems, including various layout managers, for a while. I gave up. 

I now support using special purpose layout managers. My &lt;a href="https://designgridlayout.dev.java.net/" rel="nofollow"&gt;DesignGridLayout&lt;/a&gt;, inspired by the work of Mullet and Sano, is my first attempt using this strategy.  I envision additional layout managers derived from use cases and platform look and feels. Stuff like login boxes, property sheet editors, etc.

If I cared more about the web, I'd probably completely bypass CSS layouts and implement a layout manager in JavaScript.</description>
		<content:encoded><![CDATA[<p>I tried to study and use constraint systems, including various layout managers, for a while. I gave up. </p>
<p>I now support using special purpose layout managers. My <a href="https://designgridlayout.dev.java.net/" onclick="javascript:pageTracker._trackPageview('/outbound/comment/designgridlayout.dev.java.net');" rel="nofollow">DesignGridLayout</a>, inspired by the work of Mullet and Sano, is my first attempt using this strategy.  I envision additional layout managers derived from use cases and platform look and feels. Stuff like login boxes, property sheet editors, etc.</p>
<p>If I cared more about the web, I&#8217;d probably completely bypass CSS layouts and implement a layout manager in JavaScript.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Streamlining CSS &#124; Phil Wallach</title>
		<link>http://cafe.elharo.com/web/css-repeats-itself/#comment-20691</link>
		<dc:creator>Streamlining CSS &#124; Phil Wallach</dc:creator>
		<pubDate>Thu, 05 Oct 2006 15:10:32 +0000</pubDate>
		<guid isPermaLink="false">http://cafe.elharo.com/web/css-repeats-itself/#comment-20691</guid>
		<description>[...] I had been thinking about this for a while, and was considering coming up with some sort of CSS generation language.Â  Then, as these things happen, I read CSS Repeats ItselfÂ and everything became clear. [...]</description>
		<content:encoded><![CDATA[<p>[...] I had been thinking about this for a while, and was considering coming up with some sort of CSS generation language.Â  Then, as these things happen, I read CSS Repeats ItselfÂ and everything became clear. [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dan Kubb</title>
		<link>http://cafe.elharo.com/web/css-repeats-itself/#comment-20507</link>
		<dc:creator>Dan Kubb</dc:creator>
		<pubDate>Wed, 04 Oct 2006 16:39:23 +0000</pubDate>
		<guid isPermaLink="false">http://cafe.elharo.com/web/css-repeats-itself/#comment-20507</guid>
		<description>There's one other thing I always wished that CSS allowed: nested scoping. Here's an example that better illustrates the idea (this was intended to be indented, not sure how it'll display):

&lt;pre&gt;form {
  fieldset {
    input {
      [type=text] {
        /* only applies to elements matching the CSS rule "form fieldset input[type=text]" */
      }
      [type=button {
        /* only applies to elements matching the CSS rule "form fieldset input[type=button]" */
      }
    }
  }
  div {
    input[type=submit] {
      /* only applies to elements matching the CSS rule "form div input[type=submit]" */
    }
  }
}&lt;/pre&gt;

With most of my stylesheets I arrange all the form related rules separately from the table related rules.  If I could nest them like the example above, I could cut out a lot of duplication as well as keep related rules together more easily.</description>
		<content:encoded><![CDATA[<p>There&#8217;s one other thing I always wished that CSS allowed: nested scoping. Here&#8217;s an example that better illustrates the idea (this was intended to be indented, not sure how it&#8217;ll display):</p>
<pre>form {
  fieldset {
    input {
      [type=text] {
        /* only applies to elements matching the CSS rule "form fieldset input[type=text]" */
      }
      [type=button {
        /* only applies to elements matching the CSS rule "form fieldset input[type=button]" */
      }
    }
  }
  div {
    input[type=submit] {
      /* only applies to elements matching the CSS rule "form div input[type=submit]" */
    }
  }
}</pre>
<p>With most of my stylesheets I arrange all the form related rules separately from the table related rules.  If I could nest them like the example above, I could cut out a lot of duplication as well as keep related rules together more easily.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Andrew Assarattanakul</title>
		<link>http://cafe.elharo.com/web/css-repeats-itself/#comment-20487</link>
		<dc:creator>Andrew Assarattanakul</dc:creator>
		<pubDate>Wed, 04 Oct 2006 14:16:26 +0000</pubDate>
		<guid isPermaLink="false">http://cafe.elharo.com/web/css-repeats-itself/#comment-20487</guid>
		<description>Well if people are picky about pixels being specified, this will work if you don't want to have any borders or margins for the containers.

&lt;pre&gt;#container{
	width:90%;
	margin:0 auto;
}
#left{
	width:25%;
	float:left;
}
#right{
	width:25%;
	float:right;
}
#center{
	width:50%;
	float:left;
}&lt;/pre&gt;</description>
		<content:encoded><![CDATA[<p>Well if people are picky about pixels being specified, this will work if you don&#8217;t want to have any borders or margins for the containers.</p>
<pre>#container{
	width:90%;
	margin:0 auto;
}
#left{
	width:25%;
	float:left;
}
#right{
	width:25%;
	float:right;
}
#center{
	width:50%;
	float:left;
}</pre>
]]></content:encoded>
	</item>
</channel>
</rss>
