From b3aa313e8421a26489719ecb4626cc6837e0079c Mon Sep 17 00:00:00 2001 From: Chris Young Date: Sun, 17 Jan 2016 23:40:50 +0000 Subject: misc amiga fixes re font plotting --- amiga/plotters.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'amiga/plotters.c') diff --git a/amiga/plotters.c b/amiga/plotters.c index b459dcc7e..d241dd408 100644 --- a/amiga/plotters.c +++ b/amiga/plotters.c @@ -94,7 +94,7 @@ void ami_init_layers(struct gui_globals *gg, ULONG width, ULONG height) * Height is set to screen width to give enough space for thumbnails * * Also applies to the further gfx/layers functions and memory below */ - ULONG depth = 32; + int depth = 32; struct BitMap *friend = NULL; depth = GetBitMapAttr(scrn->RastPort.BitMap, BMA_DEPTH); @@ -112,6 +112,8 @@ void ami_init_layers(struct gui_globals *gg, ULONG width, ULONG height) if(depth > 8) depth = 8; #endif + if(palette_mapped == true) nsoption_set_bool(font_antialiasing, false); + if(!width) width = nsoption_int(redraw_tile_size_x); if(!height) height = nsoption_int(redraw_tile_size_y); gg->width = width; @@ -429,13 +431,10 @@ static bool ami_text(int x, int y, const char *text, size_t length, LOG("[ami_plotter] Entered ami_text()"); #endif - bool aa = true; - - if((nsoption_bool(font_antialiasing) == false) || (palette_mapped == true)) - aa = false; + if(__builtin_expect(ami_nsfont == NULL, 0)) return false; ami_plot_setapen(glob->rp, fstyle->foreground); - ami_nsfont->text(glob->rp, text, length, fstyle, x, y, aa); + ami_nsfont->text(glob->rp, text, length, fstyle, x, y, nsoption_bool(font_antialiasing)); return true; } -- cgit v1.2.3