Switch to using px to set text height instead of em.

This commit is contained in:
Evan Czaplicki 2013-06-23 04:48:32 -07:00
parent da9c49338a
commit 340c2e7efa
2 changed files with 2 additions and 2 deletions

View file

@ -71,7 +71,7 @@ Elm.Native.Text = function(elm) {
}
function size(px, text) { return addStyle('font-size', px + 'px', text) }
var header = addTag('h1');
function height(h, text) { return addStyle('font-size', h+'em', text) }
function height(h, text) { return addStyle('font-size', h+'px', text) }
function italic(text) { return addStyle('font-style', 'italic', text) }
var bold = addTag('b');

View file

@ -21,7 +21,7 @@ header : Text -> Text
-- Create a link.
link : String -> Text -> Text
-- Set the height of text in \"ems\". 1em is the normal height of text. 2ems is twice that height.
-- Set the height of text in pixels.
height : Float -> Text -> Text
-- Set the color of a string.