--- On Thu, 10/11/11, Jay Tanna <[email protected]> wrote:
> From: Jay Tanna <[email protected]> > Subject: Re: [css-d] css measures - em grid system makes sense ? > To: "mem" <[email protected]> > Date: Thursday, 10 November, 2011, 2:09 > You can convert a px size into em > size by using this simple calculations: > > 1) Most browsers have default font size of 16px; > > 2) You should set body fonts to 62.50% to make default size > of 10px; > > 3) You can now use em for everything else to match your px > size. For example, if your width is 960px then set it > to 96em. If you want a font size to be 20px then set > it to 2em. > > 4) em is nothing but percentage in broad terms so 1.3em is > actually 130%. So 130% of 10px is 13px or 1.3em > > Hope you get the idea but the calculations get much > difficult if you have deep-rooted divs or div into div into > div and that is where you need to use your excel spreadheet > to do the necessary calculations. > > > > > > Hello all, > > > > On my css layouts, I tend to use *em* for font size > and > > *px* for all the rest. > > However, I wish not to follow this path any longer, > since I > > wish to embrace the *em* for [almost] all the > development. > > > > Problem: we use a *960px grid* for styling most of > our > > pages, so the margin or paddings and widths are given > on px, > > and if we convert those, sometimes, we will get weird > stuff > > like: 0.345 em. > > > > Question: Will it make sense to create a grid based on > *em* > > ? > > > > The point is to allow us to start drawing more user > > friendly measures like .5em or .4em and avoid .453 em > > stuff. > > > > What do you think ? > > > > Note: This is just a question, if it does make sense > to > > you, just tell me and explain me why so that I could > > understand and I can leave with that. > > > > > > ______________________________________________________________________ css-discuss [[email protected]] http://www.css-discuss.org/mailman/listinfo/css-d List wiki/FAQ -- http://css-discuss.incutio.com/ List policies -- http://css-discuss.org/policies.html Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
