diff options
author | Kristaps Dzonsons <kristaps@bsd.lv> | 2010-06-25 19:50:23 +0000 |
---|---|---|
committer | Kristaps Dzonsons <kristaps@bsd.lv> | 2010-06-25 19:50:23 +0000 |
commit | 3234ace1ba2fef84ad009e6822dd76699a34e344 (patch) | |
tree | a48423d1f37e790774a27d5ede04465fcf8d8b87 /html.c | |
parent | a0a09dc999ed5bd2a42918fc6f4143ef92b81ba4 (diff) | |
download | mandoc-3234ace1ba2fef84ad009e6822dd76699a34e344.tar.gz mandoc-3234ace1ba2fef84ad009e6822dd76699a34e344.tar.zst mandoc-3234ace1ba2fef84ad009e6822dd76699a34e344.zip |
Remove "pt" from struct roffsu, as CSS (the only reason it was there) is
unclear about which units accept floats/integers, which leads me to
assume that it handles either and rounds as appropriate.
Diffstat (limited to 'html.c')
-rw-r--r-- | html.c | 12 |
1 files changed, 6 insertions, 6 deletions
@@ -1,4 +1,4 @@ -/* $Id: html.c,v 1.102 2010/06/19 20:46:27 kristaps Exp $ */ +/* $Id: html.c,v 1.103 2010/06/25 19:50:23 kristaps Exp $ */ /* * Copyright (c) 2008, 2009 Kristaps Dzonsons <kristaps@bsd.lv> * @@ -718,11 +718,11 @@ bufcat_su(struct html *h, const char *p, const struct roffsu *su) break; } - if (su->pt) - buffmt(h, "%s: %f%s;", p, v, u); - else - /* LINTED */ - buffmt(h, "%s: %d%s;", p, (int)v, u); + /* + * XXX: the CSS spec isn't clear as to which types accept + * integer or real numbers, so we just make them all decimals. + */ + buffmt(h, "%s: %.2f%s;", p, v, u); } |