diff options
author | Chris Young <chris@unsatisfactorysoftware.co.uk> | 2011-04-22 14:53:56 +0000 |
---|---|---|
committer | Chris Young <chris@unsatisfactorysoftware.co.uk> | 2011-04-22 14:53:56 +0000 |
commit | ed5d8d0dbadfeee9a420874c8b286a56eff971b5 (patch) | |
tree | 570ee7b2322d17b3ae8dc68de0febf07d1c734cc /amiga | |
parent | b5f94b26dc7a3fc54d2a4dbb00b1b4644b7cffba (diff) | |
download | netsurf-ed5d8d0dbadfeee9a420874c8b286a56eff971b5.tar.gz netsurf-ed5d8d0dbadfeee9a420874c8b286a56eff971b5.tar.bz2 |
Use bold softstyle when no designed bold font is defined
svn path=/trunk/netsurf/; revision=12225
Diffstat (limited to 'amiga')
-rw-r--r-- | amiga/font.c | 31 |
1 files changed, 23 insertions, 8 deletions
diff --git a/amiga/font.c b/amiga/font.c index c816ce04a..b78245496 100644 --- a/amiga/font.c +++ b/amiga/font.c @@ -296,6 +296,7 @@ struct OutlineFont *ami_open_outline_font(const plot_font_style_t *fstyle, BOOL ULONG ysize; int tstyle = 0; plot_font_generic_family_t fontfamily; + ULONG embolden = 0; if(fallback) fontfamily = NSA_UNICODE_FONT; else fontfamily = fstyle->family; @@ -314,13 +315,27 @@ struct OutlineFont *ami_open_outline_font(const plot_font_style_t *fstyle, BOOL break; case NSA_BOLD: - if(ofb[fontfamily]) ofont = ofb[fontfamily]; - else ofont = of[fontfamily]; + if(ofb[fontfamily]) + { + ofont = ofb[fontfamily]; + } + else + { + ofont = of[fontfamily]; + embolden = (1 << 12); + } break; case NSA_BOLDITALIC: - if(ofbi[fontfamily]) ofont = ofbi[fontfamily]; - else ofont = of[fontfamily]; + if(ofbi[fontfamily]) + { + ofont = ofbi[fontfamily]; + } + else + { + ofont = of[fontfamily]; + embolden = (1 << 12); + } break; default: @@ -332,12 +347,12 @@ struct OutlineFont *ami_open_outline_font(const plot_font_style_t *fstyle, BOOL ysize = fstyle->size * ((1 << 16) / FONT_SIZE_SCALE); if(ESetInfo(&ofont->olf_EEngine, - OT_DeviceDPI,(72<<16) | 72, - OT_PointHeight,ysize, + OT_DeviceDPI, (72<<16) | 72, + OT_PointHeight, ysize, + OT_EmboldenX, embolden, + OT_EmboldenY, embolden, TAG_END) == OTERR_Success) - { return ofont; - } return NULL; } |