Add additional line drawing and characters.
Pointed out by pooka@.
This commit is contained in:
parent
4d57c0fb0d
commit
65f3606f46
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: acs.c,v 1.13 2007/05/28 15:01:53 blymn Exp $ */
|
||||
/* $NetBSD: acs.c,v 1.14 2007/07/11 18:44:46 jdc Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2000 The NetBSD Foundation, Inc.
|
||||
@ -38,7 +38,7 @@
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
#ifndef lint
|
||||
__RCSID("$NetBSD: acs.c,v 1.13 2007/05/28 15:01:53 blymn Exp $");
|
||||
__RCSID("$NetBSD: acs.c,v 1.14 2007/07/11 18:44:46 jdc Exp $");
|
||||
#endif /* not lint */
|
||||
|
||||
#include "curses.h"
|
||||
@ -94,6 +94,14 @@ __init_acs(SCREEN *screen)
|
||||
/* ACS_TTEE = '+'; */
|
||||
ACS_VLINE = '|';
|
||||
ACS_BULLET = 'o';
|
||||
/* Add the extensions defaults */
|
||||
ACS_S3 = '-';
|
||||
ACS_S7 = '-';
|
||||
ACS_LEQUAL = '<';
|
||||
ACS_GEQUAL = '>';
|
||||
ACS_PI = '*';
|
||||
ACS_NEQUAL = '!';
|
||||
ACS_STERLING = 'f';
|
||||
|
||||
if (screen->tc_ac == NULL)
|
||||
goto out;
|
||||
@ -176,6 +184,13 @@ __init_wacs(SCREEN *screen)
|
||||
WACS_S9 = ( wchar_t )btowc( '_' );
|
||||
WACS_VLINE = ( wchar_t )btowc( '|' );
|
||||
WACS_BULLET = ( wchar_t )btowc( 'o' );
|
||||
WACS_S3 = ( wchar_t )btowc( 'p' );
|
||||
WACS_S7 = ( wchar_t )btowc( 'r' );
|
||||
WACS_LEQUAL = ( wchar_t )btowc( 'y' );
|
||||
WACS_GEQUAL = ( wchar_t )btowc( 'z' );
|
||||
WACS_PI = ( wchar_t )btowc( '{' );
|
||||
WACS_NEQUAL = ( wchar_t )btowc( '|' );
|
||||
WACS_STERLING = ( wchar_t )btowc( '}' );
|
||||
} else {
|
||||
/* Unicode defaults */
|
||||
#ifdef DEBUG
|
||||
@ -207,6 +222,13 @@ __init_wacs(SCREEN *screen)
|
||||
WACS_TTEE = 0x252c;
|
||||
WACS_VLINE = 0x2502;
|
||||
WACS_BULLET = 0x00b7;
|
||||
WACS_S3 = 0x23bb;
|
||||
WACS_S7 = 0x23bc;
|
||||
WACS_LEQUAL = 0x2264;
|
||||
WACS_GEQUAL = 0x2265;
|
||||
WACS_PI = 0x03C0;
|
||||
WACS_NEQUAL = 0x2260;
|
||||
WACS_STERLING = 0x00A3;
|
||||
}
|
||||
|
||||
if (screen->tc_ac == NULL) {
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: curses.h,v 1.89 2007/07/01 10:53:59 xtraeme Exp $ */
|
||||
/* $NetBSD: curses.h,v 1.90 2007/07/11 18:44:46 jdc Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1981, 1993, 1994
|
||||
@ -280,6 +280,8 @@ extern chtype _acs_char[NUM_ACS];
|
||||
#else
|
||||
#define __UC_CAST(a) (unsigned char)(a)
|
||||
#endif
|
||||
|
||||
/* Standard definitions */
|
||||
#define ACS_RARROW _acs_char[__UC_CAST('+')]
|
||||
#define ACS_LARROW _acs_char[__UC_CAST(',')]
|
||||
#define ACS_UARROW _acs_char[__UC_CAST('-')]
|
||||
@ -306,6 +308,15 @@ extern chtype _acs_char[NUM_ACS];
|
||||
#define ACS_VLINE _acs_char[__UC_CAST('x')]
|
||||
#define ACS_BULLET _acs_char[__UC_CAST('~')]
|
||||
|
||||
/* Extensions */
|
||||
#define ACS_S3 _acs_char[__UC_CAST('p')]
|
||||
#define ACS_S7 _acs_char[__UC_CAST('r')]
|
||||
#define ACS_LEQUAL _acs_char[__UC_CAST('y')]
|
||||
#define ACS_GEQUAL _acs_char[__UC_CAST('z')]
|
||||
#define ACS_PI _acs_char[__UC_CAST('{')]
|
||||
#define ACS_NEQUAL _acs_char[__UC_CAST('|')]
|
||||
#define ACS_STERLING _acs_char[__UC_CAST('}')]
|
||||
|
||||
#ifdef HAVE_WCHAR
|
||||
extern cchar_t _wacs_char[NUM_ACS];
|
||||
|
||||
@ -334,6 +345,13 @@ extern cchar_t _wacs_char[NUM_ACS];
|
||||
#define WACS_TTEE _wacs_char[(unsigned char)'w'].vals[0]
|
||||
#define WACS_VLINE _wacs_char[(unsigned char)'x'].vals[0]
|
||||
#define WACS_BULLET _wacs_char[(unsigned char)'~'].vals[0]
|
||||
#define WACS_S3 _wacs_char[(unsigned char)'p'].vals[0]
|
||||
#define WACS_S7 _wacs_char[(unsigned char)'r'].vals[0]
|
||||
#define WACS_LEQUAL _wacs_char[(unsigned char)'y'].vals[0]
|
||||
#define WACS_GEQUAL _wacs_char[(unsigned char)'z'].vals[0]
|
||||
#define WACS_PI _wacs_char[(unsigned char)'{'].vals[0]
|
||||
#define WACS_NEQUAL _wacs_char[(unsigned char)'|'].vals[0]
|
||||
#define WACS_STERLING _wacs_char[(unsigned char)'}'].vals[0]
|
||||
#endif /* HAVE_WCHAR */
|
||||
|
||||
/* System V compatibility */
|
||||
|
Loading…
Reference in New Issue
Block a user