[comp.sys.amiga] DeadKeyConvert

dillon@CORY.BERKELEY.EDU (Matt Dillon) (10/06/87)

>Because to do so would break programs unprepared to parse escape sequences
>generated by the non-VANILLA keys, and because it is considered sufficiently
>easy for a program to use RAWKEY events and DeadKeyConvert().
>
>At least that was the logic for v1.2.

	I took a look at the DeadKeyConvert() routine in the Enhancer
Docs.... and I confess confusion as to how it is handled.  Since the dead
key is a separate RAWKEY event before the key-to-be-modified, how is this
handled by DeadKeyConvert() which takes a single packet?  There is no
explanation as to the contents of the IAddress field and why indirecting
through it causes the dead-key conversion routine to work.


				-Matt

jimm@mitsumi.UUCP (Jim Mackraz) (10/07/87)

In article <8710060606.AA06049@cory.Berkeley.EDU> dillon@CORY.BERKELEY.EDU (Matt Dillon) writes:
>	I took a look at the DeadKeyConvert() routine in the Enhancer
>Docs.... and I confess confusion as to how it is handled.  Since the dead
>key is a separate RAWKEY event before the key-to-be-modified, how is this
>handled by DeadKeyConvert() which takes a single packet?  There is no
>explanation as to the contents of the IAddress field and why indirecting
>through it causes the dead-key conversion routine to work.
>				-Matt

That's because it is vudu.  The dead key prefix is stored indirect off of
the IAddress field in the Intuimessages, copied there by Intuition from
the original IECLASS_RAWKEY input event.  The struct InputEvent contains
a union, and a few multiple use fields, and I don't remember which one
contains the dead key prefix.  But it is put there by the input.device,
based on previous key presses.

In the source for Commodities Exchange, direct use at the InputEvent is
made, which you can use for education.  It is in the "invert key map"
section (ikm.c) which maps from converted keycode back to an input event
structure.

I think that at the IntuiMessage level, this information should be thought
of as a magic number in a black box.  I'm not trying to be glib, but the
intention certainly was that it would be used only as shown in the example.

It is true, though, that at the input.device level, better documentation
on dead keys would be welcome (Bob?).

	jimm

-- 
	Jim Mackraz
	Mitsumi Technology, Inc.		408/980-5422
	{amiga,pyramid}!mitsumi!jimm