This one has had me thinking for a while as well and I haven't been able to come up with a full answer but I think I'm 90% of the way, hopefully someone can do the last 10%.
The theory should be to wrap your floated divs in another div. This way they are all contained in one div. Now because floated elements are removed from the normal flow of it's parent element it means you have to float the wrapper div in order for it to full contain the group of floated divs ie:
<div class="float">variable width content ipsum</div>
This leaves you with one div called wrapper which contains all you floated divs nicely. Now, and this is the bit that gets me, you have to center that wrapper div in the middle of your .setwidth div. Because the wrapper div is floated you can't center it because it is removed from the normal flow of it's parent element (.setwidth). So another non-floated div is wrapped around the floated wrapper div id:
Now because this new nonfloat div is not floated it doesn't fully contain the wrapper div. So this doesn't allow you to center it with margin:0 auto; because the width of nonfloat is 0. What we need now is get the nonfloat div to fully enclose the wrapper div without floating the nonfloat div. This is where I'm hopeing someone else will step in to finish up.
Well at least I hope it helped to clear up how floated elements behave in relations to there containing elements.