summaryrefslogtreecommitdiff
path: root/frontends/amiga
diff options
context:
space:
mode:
authorChris Young <chris@unsatisfactorysoftware.co.uk>2024-01-15 11:02:44 +0000
committerChris Young <chris@unsatisfactorysoftware.co.uk>2024-01-15 11:02:44 +0000
commitda33103357c8202ab72d2de8586b73b0ef0d6eeb (patch)
tree86347718d27d8a3551ffe9452dab9737a187f870 /frontends/amiga
parent9c5b07633f40759e0de25988b3716a2f63b939c2 (diff)
downloadnetsurf-da33103357c8202ab72d2de8586b73b0ef0d6eeb.tar.gz
netsurf-da33103357c8202ab72d2de8586b73b0ef0d6eeb.tar.bz2
Amiga: Ensure font kerning matches for width and plotting
Diffstat (limited to 'frontends/amiga')
-rw-r--r--frontends/amiga/font_bullet.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/frontends/amiga/font_bullet.c b/frontends/amiga/font_bullet.c
index dec39a1f7..43f7b9488 100644
--- a/frontends/amiga/font_bullet.c
+++ b/frontends/amiga/font_bullet.c
@@ -554,6 +554,7 @@ static inline int32 ami_font_plot_glyph(struct OutlineFont *ofont, struct RastPo
FIXED kern = 0;
ULONG glyphmaptag;
ULONG template_type;
+ bool skip_c2 = false;
uint32 long_char_1 = 0, long_char_2 = 0;
#ifndef __amigaos4__
struct BulletBase *BulletBase = ofont->BulletBase;
@@ -571,6 +572,8 @@ static inline int32 ami_font_plot_glyph(struct OutlineFont *ofont, struct RastPo
}
#endif
+ if (*char2 < 0x0020) skip_c2 = true;
+
#ifdef __amigaos4__
if(__builtin_expect(aa == true, 1)) {
glyphmaptag = OT_GlyphMap8Bit;
@@ -633,7 +636,7 @@ static inline int32 ami_font_plot_glyph(struct OutlineFont *ofont, struct RastPo
kern = 0;
- if(*char2) EObtainInfo(AMI_OFONT_ENGINE,
+ if((*char2) && (!skip_c2)) EObtainInfo(AMI_OFONT_ENGINE,
OT_TextKernPair, &kern,
TAG_END);
@@ -643,7 +646,7 @@ static inline int32 ami_font_plot_glyph(struct OutlineFont *ofont, struct RastPo
glyphmaptag, glyph,
TAG_END);
- if(*char2) EReleaseInfo(AMI_OFONT_ENGINE,
+ if((*char2) && (!skip_c2)) EReleaseInfo(AMI_OFONT_ENGINE,
OT_TextKernPair, kern,
TAG_END);
}