Re: [cc65] Escape keys

Date view Thread view Subject view

From: Ullrich von Bassewitz (uz_at_musoftware.de)
Date: 2002-12-12 20:25:13


On Thu, Dec 12, 2002 at 07:49:35PM +0100, MagerValp wrote:
> Well some targets have both, but other than that... 

That's a killer argument:-)

> Maybe define both
> CH_STOP and CH_ESC to 0x03 on the C64/VIC-20, and 0x03/0x1b on the
> other platforms?

Better: Define CH_ESC on machines that have an escape key and CH_STOP on keys
with a stop key (which are all CBM machines, I think). So the existance of the
symbol means that the machine has this key, similar to the function keys. This
will allow tests like:

        switch (cgetc ()) {

#ifdef CH_ESC
            CH_ESC:
                /* Handle the escape key */
                break;
#endif

        }

So I would add CH_STOP to cbm.h and CH_ESC to the following machine specific
header files:

        cbm264.h        (base file for c16&plus/4)
        cbm510.h
        cbm610.h
        pet.h           (some PETs don't have an ESC key)
        c128.h

Did I miss anything?

Regards


        Uz


-- 
Ullrich von Bassewitz                                  uz_at_musoftware.de
----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo_at_musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.


Date view Thread view Subject view

This archive was generated by hypermail 2.1.3 : 2002-12-12 20:25:17 CET