summaryrefslogtreecommitdiff
path: root/amiga/font.c
diff options
context:
space:
mode:
authorJohn Mark Bell <jmb@netsurf-browser.org>2009-07-23 23:05:34 +0000
committerJohn Mark Bell <jmb@netsurf-browser.org>2009-07-23 23:05:34 +0000
commitddeadd1c02880367ad786b113d352a519f45ec73 (patch)
tree00b8b46ee1a3fc84e5492c2183dfaa8192d261f9 /amiga/font.c
parentb20949a35025b23da1bf0ac6003f4575eb94281d (diff)
downloadnetsurf-ddeadd1c02880367ad786b113d352a519f45ec73.tar.gz
netsurf-ddeadd1c02880367ad786b113d352a519f45ec73.tar.bz2
Merge LibCSS port to trunk.
svn path=/trunk/netsurf/; revision=8752
Diffstat (limited to 'amiga/font.c')
-rw-r--r--amiga/font.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/amiga/font.c b/amiga/font.c
index cd7d834e2..5c694c199 100644
--- a/amiga/font.c
+++ b/amiga/font.c
@@ -237,7 +237,7 @@ struct OutlineFont *ami_open_outline_font(const plot_font_style_t *fstyle)
{
struct OutlineFont *ofont;
char *fontname;
- WORD ysize;
+ ULONG ysize;
int tstyle = 0;
if ((fstyle->flags & FONTF_ITALIC) || (fstyle->flags & FONTF_OBLIQUE))
@@ -268,14 +268,12 @@ struct OutlineFont *ami_open_outline_font(const plot_font_style_t *fstyle)
break;
}
- ysize = fstyle->size;
-
- if(ysize < (option_font_min_size / 10) * FONT_SIZE_SCALE)
- ysize = (option_font_min_size / 10) * FONT_SIZE_SCALE;
+ /* Scale to 16.16 fixed point */
+ ysize = fstyle->size * ((1 << 16) / FONT_SIZE_SCALE);
if(ESetInfo(&ofont->olf_EEngine,
OT_DeviceDPI,(72<<16) | 72,
- OT_PointHeight,(ysize<<16)/FONT_SIZE_SCALE,
+ OT_PointHeight,ysize,
TAG_END) == OTERR_Success)
{
return ofont;