A little Problem translating a header file.
Kagamin
spam at here.lot
Mon Nov 14 10:40:51 PST 2011
Jude Young Wrote:
> /* VT100 symbols begin here */
> #define ACS_ULCORNER NCURSES_ACS('l') /* upper left corner */
> #define ACS_LLCORNER NCURSES_ACS('m') /* lower left corner */
> #define ACS_URCORNER NCURSES_ACS('k') /* upper right corner */
> #define ACS_LRCORNER NCURSES_ACS('j') /* lower right corner */
>
> immutable enum ACS
> {
> /* VT100 symbols begin here */
> ULCORNER = 'l',
> LLCORNER = 'm',
> URCORNER = 'k',
>
> to use it you have to type: addch(acs_map[ACS.ULCORNER]);
addch_map(ubyte c)
{ addch(acs_map[c]); }
or
immutable enum ACS
{
/* VT100 symbols begin here */
ULCORNER = NCURSES_ACS('l'),
LLCORNER = NCURSES_ACS('m'),
URCORNER = NCURSES_ACS('k'),
should be CTFE'able if acs_map is immutable and known at compile time.
More information about the Digitalmars-d
mailing list