Now does character remapping depending on font encoding.

This commit is contained in:
marcus 2001-02-02 06:01:01 +00:00
parent 005368f745
commit 51c778440d
1 changed files with 12 additions and 2 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: rasops.c,v 1.34 2001/01/21 13:50:59 takemura Exp $ */
/* $NetBSD: rasops.c,v 1.35 2001/02/02 06:01:01 marcus Exp $ */
/*-
* Copyright (c) 1999 The NetBSD Foundation, Inc.
@ -37,7 +37,7 @@
*/
#include <sys/cdefs.h>
__KERNEL_RCSID(0, "$NetBSD: rasops.c,v 1.34 2001/01/21 13:50:59 takemura Exp $");
__KERNEL_RCSID(0, "$NetBSD: rasops.c,v 1.35 2001/02/02 06:01:01 marcus Exp $");
#include "opt_rasops.h"
#include "rasops_glue.h"
@ -331,6 +331,16 @@ rasops_mapchar(cookie, c, cp)
if (ri->ri_font == NULL)
panic("rasops_mapchar: no font selected\n");
#endif
if (ri->ri_font->encoding != WSDISPLAY_FONTENC_ISO) {
if ( (c = wsfont_map_unichar(ri->ri_font, c)) < 0) {
*cp = ' ';
return (0);
}
}
if (c < ri->ri_font->firstchar) {
*cp = ' ';