[css-d] Left sidebar aligned with a centered block

2013-04-18 Thread Zaia Z
Hi all, I have a question about positioning elements on a webpage. I have a central block of content in the middle of the page: .main { border:1px solid #000; clear: both; margin:15px auto; width: 800px; } I'm also positioning a sidebar to the left of this centered block: .sidebar {

[css-d] Question regarding the use of section

2013-04-18 Thread Nancy Johnson
When I first went live with a website a few months ago, the following code validated and now it doesn't. Why? section role=main Thank you, Nancy Johnson __ css-discuss [css-d@lists.css-discuss.org]

Re: [css-d] Question regarding the use of section

2013-04-18 Thread Markus Ernst
Am 18.04.2013 16:39 schrieb Nancy Johnson: When I first went live with a website a few months ago, the following code validated and now it doesn't. Why? section role=main Strange enough: the specs at WHATWG allow main as a value of @role in the section element:

Re: [css-d] Question regarding the use of section

2013-04-18 Thread John D
I would change it to: section id=mainYou are using correct doctype right? !DOCTYPE html Hope this helps. When I first went live with a website a few months ago, the following code validated and now it doesn't. Why? section role=main

Re: [css-d] Question regarding the use of section

2013-04-18 Thread Tom Livingston
On Thu, Apr 18, 2013 at 12:12 PM, John D xfs...@hotmail.com wrote: I would change it to: section id=mainYou are using correct doctype right? !DOCTYPE html Hope this helps. When I first went live with a website a few months ago, the following code validated and now it doesn't. Why?

Re: [css-d] Left sidebar aligned with a centered block

2013-04-18 Thread Micky Hulse
Hello, I _quickly_ slapped this together: http://jsbin.com/asozay/1/ Not cross-browser tested though. The basic gist of things is to have an absolutely positioned sidebar inside the parent which is position relative. From there, you can keep the main column centered like normal, and the

Re: [css-d] Question regarding the use of section

2013-04-18 Thread Philip TAYLOR
Nancy Johnson wrote: When I first went live with a website a few months ago, the following code validated and now it doesn't. Why? section role=main Thank you, Nancy Johnson Validation takes place in a context; with no knowledge of the context in which you used this construct a

Re: [css-d] Question regarding the use of section

2013-04-18 Thread Tim Arnold
On Thu, Apr 18, 2013 at 10:39 AM, Nancy Johnson njohnso...@gmail.com wrote: When I first went live with a website a few months ago, the following code validated and now it doesn't. Why? section role=main Thank you, Nancy Johnson Nancy, I'm not sure why it validated before, but

Re: [css-d] Left sidebar aligned with a centered block

2013-04-18 Thread David Laakso
On Thu, Apr 18, 2013 at 9:21 AM, Zaia Z zigaew...@gmail.com wrote: How should I arrange the CSS for the sidebar such that it always maintains a consistent gap to the left of the centered block? I'd appreciate your advice on this; thanks! Zaia Not sue why you might want to do that?

Re: [css-d] Question regarding the use of section

2013-04-18 Thread Jay Tanna
AFAIK, Section's role is implied but if you want to make it specific then you should be using DIV. For example this code would validate: div id=section role=main This is a section of my page! /div Lots of HTML tags will not accept the role attribute. Don't know why but it could be

[css-d] font-size in body selector?

2013-04-18 Thread COM
My understanding of font-size spec is: 100% = 1 em = the size of an M and that this is 16px high. What I am not clear is: where do you tell the browser how large the M is? Is it universally understood that 1 M is 16 pixels high? thank you! John

Re: [css-d] font-size in body selector?

2013-04-18 Thread Tom Livingston
You can spec font-size of 100% on the body. This respects the users preference settings in their browser. You can then spec element font size in ems. The 16px is usually the default size set in browsers upon install.  — Sent from Mailbox for iPhone On Thu, Apr 18, 2013 at 5:54 PM, COM

Re: [css-d] font-size in body selector?

2013-04-18 Thread Micky Hulse
From what I know, that's based on the browser and the user prefs. On my Mac, using Firefox latest, there's a Fonts Colors section of in the prefs under Content. The default font size out-of-the-box is Times 16. Anecdote: I have an older friend, in his 60s, that has this set to something like

Re: [css-d] font-size in body selector?

2013-04-18 Thread Jukka K. Korpela
2013-04-19 0:54, COM wrote: My understanding of font-size spec is: 100% = 1 em = the size of an M and that this is 16px high. No, in the value of the font-size property, the em unit denotes the font size of the parent element. The font size is the height of the font. It is easy to see that

Re: [css-d] font-size in body selector?

2013-04-18 Thread Chris F.A. Johnson
On Thu, 18 Apr 2013, COM wrote: My understanding of font-size spec is: 100% = 1 em = the size of an M and that this is 16px high. 100% is the user's default font size. It could be anything from 12px to 24 px (or larger or smaller) and should be used for any body text on the page. What

Re: [css-d] font-size in body selector?

2013-04-18 Thread COM
On Apr 18, 2013, at 3:07 PM, Jukka K. Korpela jkorp...@cs.tut.fi wrote: What I am not clear is: where do you tell the browser how large the M is? You don't. The font designer decides the dimensions of letters, relative to the font size. OK…so the 1em is just a starting point and you

Re: [css-d] font-size in body selector?

2013-04-18 Thread Micky Hulse
You might find this tool interesting to play with: http://pxtoem.com/ The Learn tab has some OK info, and the math (for conversions) is good to know too. This article might also be of some interest to you: http://snook.ca/archives/html_and_css/font-size-with-rem

Re: [css-d] font-size in body selector?

2013-04-18 Thread Felix Miata
On 2013-04-18 15:12 (GMT-0700) COM composed: OK…so the 1em is just a starting point and you adjust to suit..or these are all *relative* sizes because in the child elements you might spec font-size: .85em ? ..so that if User cranks up the sizes, everything sizes up (or down) in the same