      interface UIEvent : Event {
 /* IID: { 0xa6cf90c3, 0x15b3, 0x11d2, \
  { 0x93, 0x2e, 0x00, 0x80, 0x5f, 0x8a, 0xdd, 0x32 } } */

	      const int VK_CANCEL         = 0x03;
	      const int VK_BACK           = 0x08;
	      const int VK_TAB            = 0x09;
	      const int VK_CLEAR          = 0x0C;
	      const int VK_RETURN         = 0x0D;
	      const int VK_ENTER          = 0x0E;
	      const int VK_SHIFT          = 0x10;
	      const int VK_CONTROL        = 0x11;
	      const int VK_ALT            = 0x12;
	      const int VK_PAUSE          = 0x13;
	      const int VK_CAPS_LOCK      = 0x14;
	      const int VK_ESCAPE         = 0x1B;
	      const int VK_SPACE          = 0x20;
	      const int VK_PAGE_UP        = 0x21;
	      const int VK_PAGE_DOWN      = 0x22;
	      const int VK_END            = 0x23;
	      const int VK_HOME           = 0x24;
	      const int VK_LEFT           = 0x25;
	      const int VK_UP             = 0x26;
	      const int VK_RIGHT          = 0x27;
	      const int VK_DOWN           = 0x28;
	      const int VK_PRINTSCREEN    = 0x2C;
	      const int VK_INSERT         = 0x2D;
	      const int VK_DELETE         = 0x2E;

	      // VK_0 - VK_9 match their ascii values
	      const int VK_0              = 0x30;
	      const int VK_1              = 0x31;
	      const int VK_2              = 0x32;
	      const int VK_3              = 0x33;
	      const int VK_4              = 0x34;
	      const int VK_5              = 0x35;
	      const int VK_6              = 0x36;
	      const int VK_7              = 0x37;
	      const int VK_8              = 0x38;
	      const int VK_9              = 0x39;

	      const int VK_SEMICOLON      = 0x3B;
	      const int VK_EQUALS         = 0x3D;

	      // VK_A - VK_Z match their ascii values
	      const int VK_A              = 0x41;
	      const int VK_B              = 0x42;
	      const int VK_C              = 0x43;
	      const int VK_D              = 0x44;
	      const int VK_E              = 0x45;
	      const int VK_F              = 0x46;
	      const int VK_G              = 0x47;
	      const int VK_H              = 0x48;
	      const int VK_I              = 0x49;
	      const int VK_J              = 0x4A;
	      const int VK_K              = 0x4B;
	      const int VK_L              = 0x4C;
	      const int VK_M              = 0x4D;
	      const int VK_N              = 0x4E;
	      const int VK_O              = 0x4F;
	      const int VK_P              = 0x50;
	      const int VK_Q              = 0x51;
	      const int VK_R              = 0x52;
	      const int VK_S              = 0x53;
	      const int VK_T              = 0x54;
	      const int VK_U              = 0x55;
	      const int VK_V              = 0x56;
	      const int VK_W              = 0x57;
	      const int VK_X              = 0x58;
	      const int VK_Y              = 0x59;
	      const int VK_Z              = 0x5A;

	      const int VK_NUMPAD0        = 0x60;
	      const int VK_NUMPAD1        = 0x61;
	      const int VK_NUMPAD2        = 0x62;
	      const int VK_NUMPAD3        = 0x63;
	      const int VK_NUMPAD4        = 0x64;
	      const int VK_NUMPAD5        = 0x65;
	      const int VK_NUMPAD6        = 0x66;
	      const int VK_NUMPAD7        = 0x67;
	      const int VK_NUMPAD8        = 0x68;
	      const int VK_NUMPAD9        = 0x69;
	      const int VK_MULTIPLY       = 0x6A;
	      const int VK_ADD            = 0x6B;
	      const int VK_SEPARATOR      = 0x6C;
	      const int VK_SUBTRACT       = 0x6D;
	      const int VK_DECIMAL        = 0x6E;
	      const int VK_DIVIDE         = 0x6F;
	      const int VK_F1             = 0x70;
	      const int VK_F2             = 0x71;
	      const int VK_F3             = 0x72;
	      const int VK_F4             = 0x73;
	      const int VK_F5             = 0x74;
	      const int VK_F6             = 0x75;
	      const int VK_F7             = 0x76;
	      const int VK_F8             = 0x77;
	      const int VK_F9             = 0x78;
	      const int VK_F10            = 0x79;
	      const int VK_F11            = 0x7A;
	      const int VK_F12            = 0x7B;
	      const int VK_F13            = 0x7C;
	      const int VK_F14            = 0x7D;
	      const int VK_F15            = 0x7E;
	      const int VK_F16            = 0x7F;
	      const int VK_F17            = 0x80;
	      const int VK_F18            = 0x81;
	      const int VK_F19            = 0x82;
	      const int VK_F20            = 0x83;
	      const int VK_F21            = 0x84;
	      const int VK_F22            = 0x85;
	      const int VK_F23            = 0x86;
	      const int VK_F24            = 0x87;

	      const int VK_NUM_LOCK       = 0x90;
	      const int VK_SCROLL_LOCK    = 0x91;

	      const int VK_COMMA	    = 0xBC;
	      const int VK_PERIOD         = 0xBE;
	      const int VK_SLASH          = 0xBF;
	      const int VK_BACK_QUOTE     = 0xC0;
	      const int VK_OPEN_BRACKET   = 0xDB;
	      const int VK_BACK_SLASH     = 0xDC;
	      const int VK_CLOSE_BRACKET  = 0xDD;
	      const int VK_QUOTE          = 0xDE;

		  readonly    attribute	  wstring		text;
					  attribute	  TextRangeList inputRange;

		  readonly	  attribute   int		    screenX;
		  readonly    attribute   int		    screenY;

		  readonly    attribute   int		    clientX;
		  readonly    attribute   int		    clientY;
							  
		  readonly    attribute   boolean	    altKey;
		  readonly    attribute   boolean	    ctrlKey;
		  readonly    attribute   boolean	    shiftKey;
		  readonly    attribute   boolean	    metaKey;


		  readonly	  attribute   unsigned long   charCode;
		  readonly	  attribute   unsigned long   keyCode;
		  readonly	  attribute   unsigned long   button;
      };

      interface NSUIEvent {
 /* IID: { 0xa6cf90c4, 0x15b3, 0x11d2, \
  { 0x93, 0x2e, 0x00, 0x80, 0x5f, 0x8a, 0xdd, 0x32 } } */

	      const int EVENT_MOUSEDOWN	= 0x00000001;
	      const int EVENT_MOUSEUP		= 0x00000002;
	      const int EVENT_MOUSEOVER	= 0x00000004;
	      const int EVENT_MOUSEOUT	= 0x00000008;
	      const int EVENT_MOUSEMOVE	= 0x00000010;  
	      const int EVENT_MOUSEDRAG	= 0x00000020;
	      const int EVENT_CLICK		= 0x00000040;
	      const int EVENT_DBLCLICK	= 0x00000080;
	      const int EVENT_KEYDOWN		= 0x00000100;
	      const int EVENT_KEYUP		= 0x00000200;
	      const int EVENT_KEYPRESS	= 0x00000400;
	      const int EVENT_DRAGDROP	= 0x00000800;
	      const int EVENT_FOCUS		= 0x00001000;
	      const int EVENT_BLUR		= 0x00002000;
	      const int EVENT_SELECT		= 0x00004000;
	      const int EVENT_CHANGE		= 0x00008000;
	      const int EVENT_RESET		= 0x00010000;
	      const int EVENT_SUBMIT		= 0x00020000;
	      const int EVENT_SCROLL		= 0x00040000;
	      const int EVENT_LOAD		= 0x00080000;
	      const int EVENT_UNLOAD		= 0x00100000;
	      const int EVENT_XFER_DONE	= 0x00200000;
	      const int EVENT_ABORT		= 0x00400000;
	      const int EVENT_ERROR		= 0x00800000;
	      const int EVENT_LOCATE	        = 0x01000000;
	      const int EVENT_MOVE		= 0x02000000;
	      const int EVENT_RESIZE		= 0x04000000;
	      const int EVENT_FORWARD		= 0x08000000;
	      const int EVENT_HELP	        = 0x10000000;
	      const int EVENT_BACK		= 0x20000000;
		    const int EVENT_TEXT		= 0x40000000;

	      const int EVENT_ALT_MASK	= 0x00000001;
	      const int EVENT_CONTROL_MASK	= 0x00000002;
	      const int EVENT_SHIFT_MASK	= 0x00000004;
	      const int EVENT_META_MASK	= 0x00000008;

	      readonly    attribute   int			      layerX;
	      readonly    attribute   int			      layerY;
	      readonly    attribute   int			      pageX;
	      readonly    attribute   int			      pageY;
	      readonly    attribute   unsigned long which;
		    readonly	  attribute   Node		  	  rangeParent;
		    readonly	  attribute   int           rangeOffset;

	      readonly    attribute RenderingContext rc;
      };
