logo-dw

Go Back   Dreamweaver Club Forums > Hand Coders Forum > HTML and CSS
Register FAQ Members List Search Today's Posts Mark Forums Read

Reply
 
Thread Tools Display Modes
Old 04-19-2012, 07:27 PM   #1
Gnarly
 
Join Date: Apr 2012
Location: Virginia, USA
Posts: 12
Default Precise font sizing

Wondering if someone can give me some insight.

I'm trying to get my font to be about 0.90em. The problem is Safari seems to be telling me that I can use either 1em or 0.75em (guesstimate). Nothing in-between will work. The same issue happens when I use px.

Am I doing it wrong??
Gnarly is offline   Reply With Quote
Old 04-23-2012, 09:27 PM   #2
Gnarly
 
Join Date: Apr 2012
Location: Virginia, USA
Posts: 12
Default

Ok then, does anyone know where the nearest army recruitment center is?
Gnarly is offline   Reply With Quote
Old 04-24-2012, 04:20 AM   #3
d a v e
 
Join Date: Feb 2006
Location: finland
Posts: 1,684
Default

link to your site would be useful
d a v e is offline   Reply With Quote
Old 04-24-2012, 05:35 AM   #4
edbr
edbr's Avatar
 
Join Date: Aug 2005
Location: Bali
Posts: 11,164
Default

not sure how relevant it is but did you use a css reset, it might help level the playing field. if not the Infantry are always on the look out i heard.
welcome to the forum BTW
__________________
If you're happy and you know it shake your meds!
different style links examples

Flight / Hotel search
Free script download
Bali Villas
edbr is offline   Reply With Quote
Old 04-24-2012, 05:37 AM   #5
edbr
edbr's Avatar
 
Join Date: Aug 2005
Location: Bali
Posts: 11,164
Default

ah just found this afeter a quick yahoogle
I did another test by increasing Safari's font size to 18px, and the
>> layout expanded. This makes the EM not stable to use for layout. I wonder
>> if it has always like this for Safari or is a new bug.

try % perhaps
__________________
If you're happy and you know it shake your meds!
different style links examples

Flight / Hotel search
Free script download
Bali Villas
edbr is offline   Reply With Quote
Old 04-24-2012, 06:27 PM   #6
Gnarly
 
Join Date: Apr 2012
Location: Virginia, USA
Posts: 12
Default

Quote:
Originally Posted by edbr View Post
not sure how relevant it is but did you use a css reset, it might help level the playing field. if not the Infantry are always on the look out i heard.
welcome to the forum BTW
Lol, thanks.

From what I gather, 1em is equal to the default browser font size. Just another way of saying 100%? I was just hoping to go a bit deeper into the fractions than I apparently can.
Gnarly is offline   Reply With Quote
Old 04-24-2012, 07:10 PM   #7
d a v e
 
Join Date: Feb 2006
Location: finland
Posts: 1,684
Default

i usually set 62.5% on the body then everything else in ems
e.g. 24px heading is 2.4 em

again, as always, a link would be easier to see how you have things set up
d a v e is offline   Reply With Quote
Old 04-24-2012, 10:29 PM   #8
gentleone
gentleone's Avatar
 
Join Date: Nov 2009
Location: Rhodes, Greece
Posts: 2,837
Default

Don't forget that em's take the size of the parent. The size can get really unexpected small if you use different font-sizes in nested elements.
__________________
www.gentlemedia.nl
gentleone is offline   Reply With Quote
Old 04-25-2012, 01:00 AM   #9
edbr
edbr's Avatar
 
Join Date: Aug 2005
Location: Bali
Posts: 11,164
Default

Quote:
From what I gather, 1em is equal to the default browser font size. Just another way of saying 100%? I was just hoping to go a bit deeper into the fractions than I apparently can.
the article i saw was quoting a bug that safari has handling em's, the recommendation was to use %'c and offered a reset for it, i didnt save it im afraid but found it quickly searching safari and em issue
__________________
If you're happy and you know it shake your meds!
different style links examples

Flight / Hotel search
Free script download
Bali Villas
edbr is offline   Reply With Quote
Old 04-25-2012, 12:56 PM   #10
domedia
Administrator
domedia's Avatar
 
Join Date: Dec 2003
Posts: 9,730
Default

Quote:
Originally Posted by d a v e View Post
i usually set 62.5% on the body then everything else in ems
e.g. 24px heading is 2.4 em

again, as always, a link would be easier to see how you have things set up
I do exactly the same, but use 'rem' instead. It does not inherit the size of the parent elements.

Code:
html	{
	font-size: 62.5%;
	}
body {
	font-size: 14px;
	font-size: 1.4rem;
	}
For more information about this technique from Jonathan Snook:
http://snook.ca/archives/html_and_cs...-size-with-rem

.
domedia is offline   Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 08:03 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2017, vBulletin Solutions, Inc.
Copyright 2006 DreamweaverClub.com