Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

CSS

I don't see the extra space created by the browser due to inline-blocks?

.

4 Answers

Steven Parker
Steven Parker
231,271 Points

This is explained about 1 minute into the video. It's the same trick he did in the earlier video on Removing Gaps Between Inline and Inline-Block Elements where negative margins are used to pull the element into what would otherwise be a gap.

.

Steven Parker
Steven Parker
231,271 Points

I accidentally posted the wrong answer but deleted it .. you must have been quick to see it!

I was right about "white space" actually being "background-colored space", but that's a different issue than what you are asking here. The background behind the columns actually is white in this case, it's the columns that have the colored background.

.

Steven Parker
Steven Parker
231,271 Points

That's the whole point of the negative margin trick .. to eliminate the gap between the columns.

.

Steven Parker
Steven Parker
231,271 Points

There would have been a gap if not compensated for with the margins. Try removing those settings and see!