rem: SetAPen( amiga_window->RPort, bgpen ); SetDrMd( amiga_window->RPort, JAM1 );
add: SetABPenDrMd( amiga_window->RPort, bgpen, 0, JAM1 );
context: ui_draw_text (uint8 font, uint8 flags, int mixmode, int x, int y,	      int clipx, int clipy, int clipcx, int clipcy, int boxx,	      int boxy, int boxcx, int boxcy, int bgcolour,	      int fgcolour, uint8 * text, uint8 length){  FONTGLYPH* glyph;  int i,j, xyoffset;  DATABLOB* entry;  LONG bgpen = amiga_obtain_pen( bgcolour );  x += amiga_window->BorderLeft;  y += amiga_window->BorderTop;  boxx += amiga_window->BorderLeft;  boxy += amiga_window->BorderTop;  clipx += amiga_window->BorderLeft;  clipy += amiga_window->BorderTop;  SetAPen( amiga_window->RPort, bgpen );  SetDrMd( amiga_window->RPort, JAM1 );  if (boxcx > 1)  {    RectFill( amiga_window->RPort, 	      boxx, boxy, boxx + boxcx - 1, boxy + boxcy - 1 );  }  else if (mixmode == MIX_OPAQUE)  {    RectFill( amiga_window->RPort,	      clipx, clipy, clipx + clipcx - 1, clipy + clipcy - 1 );  }  amiga_release_pen( bgpen );    /* Paint text, character by character */  for(i=0;i<length;)  {    switch (text[i])    {      case 0xff:	if (i+2<length)	  cache_put_text (text[i+1], text, text[i+2]);	else	{	  error("this shouldn't be happening\n");	  break;	}	/* this will move pointer from start to first character after FF command */	length-=i+3;	text=&(text[i+3]);	i=0;	break;      case 0xfe:	entry = cache_get_text (text[i+1]);	if (entry!=NULL)	{	  if ((((uint8 *)(entry->data))[1] == 0 ) && (!(flags & TEXT2_IMPLICIT_X)))	  {	    if (flags & TEXT2_VERTICAL)	      y += text[i+2];	    else	      x += text[i+2];	    for (j = 0; j < entry->size; j++)	      DO_GLYPH(((uint8 *) (entry->data)), j);	  }	  if (i+2<length) 	    i+=3;	  else	    i+=2;	  length-=i;	  /* this will move pointer from start to first character after FE command */	  text=&(text[i]);	  i=0;	}	break;      default:	DO_GLYPH(text,i);	i++;	break;    }  }}