libs-gui/Documentation/gsdoc/NSEvent.gsdoc

506 lines
17 KiB
Text
Raw Normal View History

<?xml version="1.0"?>
<!DOCTYPE gsdoc PUBLIC "-//GNUstep//DTD gsdoc 0.6.7//EN" "http://www.gnustep.org/gsdoc-0_6_7.xml">
<gsdoc base="NSEvent" up="Gui">
<head>
<title>NSEvent</title>
<author name="Scott Christley">
<email address="scottc@net-community.com">
scottc@net-community.com
</email>
</author>
<author name="Ovidiu Predescu">
<email address="ovidiu@net-community.com">
ovidiu@net-community.com
</email>
</author>
<author name="Felipe A. Rodriguez">
<email address="far@ix.netcom.com">
far@ix.netcom.com
</email>
</author>
<abstract>The event class</abstract>
<copy>1996 Free Software Foundation, Inc.</copy>
</head>
<body>
<front><contents /></front>
<chapter>
<heading>
Software documentation for the NSEvent class
</heading>
<class name="NSEvent" super="NSObject">
<declared>AppKit/NSEvent.h</declared>
<conform>NSCoding</conform>
<conform>NSCopying</conform>
<desc>
<em>Description forthcoming.</em>
</desc>
<method type="NSEvent*" factory="yes">
<sel>enterExitEventWithType:</sel>
<arg type="NSEventType">type</arg>
<sel>location:</sel>
<arg type="NSPoint">location</arg>
<sel>modifierFlags:</sel>
<arg type="unsigned int">flags</arg>
<sel>timestamp:</sel>
<arg type="NSTimeInterval">time</arg>
<sel>windowNumber:</sel>
<arg type="int">windowNum</arg>
<sel>context:</sel>
<arg type="NSGraphicsContext*">context</arg>
<sel>eventNumber:</sel>
<arg type="int">eventNum</arg>
<sel>trackingNumber:</sel>
<arg type="int">trackingNum</arg>
<sel>userData:</sel>
<arg type="void*">userData</arg>
<desc>
<em>Description forthcoming.</em>
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="NSEvent*" factory="yes">
<sel>keyEventWithType:</sel>
<arg type="NSEventType">type</arg>
<sel>location:</sel>
<arg type="NSPoint">location</arg>
<sel>modifierFlags:</sel>
<arg type="unsigned int">flags</arg>
<sel>timestamp:</sel>
<arg type="NSTimeInterval">time</arg>
<sel>windowNumber:</sel>
<arg type="int">windowNum</arg>
<sel>context:</sel>
<arg type="NSGraphicsContext*">context</arg>
<sel>characters:</sel>
<arg type="NSString*">keys</arg>
<sel>charactersIgnoringModifiers:</sel>
<arg type="NSString*">ukeys</arg>
<sel>isARepeat:</sel>
<arg type="BOOL">repeatKey</arg>
<sel>keyCode:</sel>
<arg type="unsigned short">code</arg>
<desc>
<em>Description forthcoming.</em>
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="NSEvent*" factory="yes">
<sel>mouseEventWithType:</sel>
<arg type="NSEventType">type</arg>
<sel>location:</sel>
<arg type="NSPoint">location</arg>
<sel>modifierFlags:</sel>
<arg type="unsigned int">flags</arg>
<sel>timestamp:</sel>
<arg type="NSTimeInterval">time</arg>
<sel>windowNumber:</sel>
<arg type="int">windowNum</arg>
<sel>context:</sel>
<arg type="NSGraphicsContext*">context</arg>
<sel>eventNumber:</sel>
<arg type="int">eventNum</arg>
<sel>clickCount:</sel>
<arg type="int">clickNum</arg>
<sel>pressure:</sel>
<arg type="float">pressureValue</arg>
<desc>
<em>Description forthcoming.</em>
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="NSEvent*" factory="yes">
<sel>mouseEventWithType:</sel>
<arg type="NSEventType">type</arg>
<sel>location:</sel>
<arg type="NSPoint">location</arg>
<sel>modifierFlags:</sel>
<arg type="unsigned int">flags</arg>
<sel>timestamp:</sel>
<arg type="NSTimeInterval">time</arg>
<sel>windowNumber:</sel>
<arg type="int">windowNum</arg>
<sel>context:</sel>
<arg type="NSGraphicsContext*">context</arg>
<sel>eventNumber:</sel>
<arg type="int">eventNum</arg>
<sel>clickCount:</sel>
<arg type="int">clickNum</arg>
<sel>pressure:</sel>
<arg type="float">pressureValue</arg>
<sel>buttonNumber:</sel>
<arg type="int">buttonNum</arg>
<sel>deltaX:</sel>
<arg type="float">deltaX</arg>
<sel>deltaY:</sel>
<arg type="float">deltaY</arg>
<sel>deltaZ:</sel>
<arg type="float">deltaZ</arg>
<desc>
<em>Description forthcoming.</em>
</desc>
<standards>
<NotOpenStep /> <NotMacOS-X /> <GNUstep />
</standards>
</method>
<method type="NSPoint" factory="yes">
<sel>mouseLocation</sel>
<desc>
Returns the current mouse location.
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="NSEvent*" factory="yes">
<sel>otherEventWithType:</sel>
<arg type="NSEventType">type</arg>
<sel>location:</sel>
<arg type="NSPoint">location</arg>
<sel>modifierFlags:</sel>
<arg type="unsigned int">flags</arg>
<sel>timestamp:</sel>
<arg type="NSTimeInterval">time</arg>
<sel>windowNumber:</sel>
<arg type="int">windowNum</arg>
<sel>context:</sel>
<arg type="NSGraphicsContext*">context</arg>
<sel>subtype:</sel>
<arg type="short">subType</arg>
<sel>data1:</sel>
<arg type="int">data1</arg>
<sel>data2:</sel>
<arg type="int">data2</arg>
<desc>
<em>Description forthcoming.</em>
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="void" factory="yes">
<sel>startPeriodicEventsAfterDelay:</sel>
<arg type="NSTimeInterval">delaySeconds</arg>
<sel>withPeriod:</sel>
<arg type="NSTimeInterval">periodSeconds</arg>
<desc>
<em>Description forthcoming.</em>
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="void" factory="yes">
<sel>stopPeriodicEvents</sel>
<desc>
<em>Description forthcoming.</em>
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="int">
<sel>buttonNumber</sel>
<desc>
Returns the button number for the mouse button
pressed in a mouse event. Intended primarily for
the case where a mouse has three or more buttons, and
you want to know which button an 'other' mouse event
refers to.
</desc>
<standards>
<NotOpenStep /> <GNUstep /> <MacOS-X />
</standards>
</method>
<method type="NSString*">
<sel>characters</sel>
<desc>
Returns the string of characters for a keyboard
event. <br /> Raises an
NSInternalInconsistencyException
if applied to any other type of event.
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="NSString*">
<sel>charactersIgnoringModifiers</sel>
<desc>
Returns the string of characters for a keyboard
event, as if no modifier keys had been pressed when
the keyboard event occirred. <br /> Raises an
NSInternalInconsistencyException
if applied to any other type of event.
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="int">
<sel>clickCount</sel>
<desc>
Return the number of clicks associated with the
mouse down or up event. This method is not applicable
for any event type other than a mouse down or mouse up.
<br /> Raises an NSInternalInconsistencyException if
applied to any other type of event.
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="NSGraphicsContext*">
<sel>context</sel>
<desc>
Returns the graphics context for which this event
was generated.
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="int">
<sel>data1</sel>
<desc>
Returns the 'data1' item associated with the event.
<br /> Raises NSInternalInconsistencyException if
the event is not of type NSAppKitDefined,
NSSystemDefined, NSApplicationDefined, or
NSPeriodic
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="int">
<sel>data2</sel>
<desc>
Returns the 'data2' item associated with the event.
<br /> Raises NSInternalInconsistencyException if
the event is not of type NSAppKitDefined,
NSSystemDefined, NSApplicationDefined, or
NSPeriodic
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="float">
<sel>deltaX</sel>
<desc>
<p>Returns the movement of the mouse on the X axis.</p>
<p>
This method is only valid for NSMouseMoved,
NS*MouseDragged and NSScrollWheel events,
otherwise it will raise an
NSInternalInconsistencyException.
</p>
</desc>
<standards>
<NotOpenStep /> <GNUstep /> <MacOS-X />
</standards>
</method>
<method type="float">
<sel>deltaY</sel>
<desc>
<p>Returns the movement of the mouse on the Y axis.</p>
<p>
This method is only valid for NSMouseMoved,
NS*MouseDragged and NSScrollWheel events,
otherwise it will raise an
NSInternalInconsistencyException.
</p>
</desc>
<standards>
<NotOpenStep /> <GNUstep /> <MacOS-X />
</standards>
</method>
<method type="float">
<sel>deltaZ</sel>
<desc>
<p>Returns the movement of the mouse on the Z axis.</p>
<p>
This method is only valid for NSMouseMoved,
NS*MouseDragged and NSScrollWheel events,
otherwise it will raise an
NSInternalInconsistencyException.
</p>
<p>The value returned is 0.0 in most cases.</p>
</desc>
<standards>
<NotOpenStep /> <GNUstep /> <MacOS-X />
</standards>
</method>
<method type="int">
<sel>eventNumber</sel>
<desc>
Returns the event number associated with any mouse
event or tracking event. Event numbers are allocated
sequentially when the system creates these
events. <br /> Raises an
NSInternalInconsistencyException
if applied to any other type of event.
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="BOOL">
<sel>isARepeat</sel>
<desc>
Returns a flag to say if this is a keyboard repeat
event. <br /> Raises an
NSInternalInconsistencyException
if applied to any other type of event than an NSKeyUp or
NSKeyDown.
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="unsigned short">
<sel>keyCode</sel>
<desc>
Returns the numeric key code of a keyboard event.
<br /> Raises an NSInternalInconsistencyException if
applied to any other type of event than an NSKeyUp
or NSKeyDown.
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="NSPoint">
<sel>locationInWindow</sel>
<desc>
Returns the window location for which this event
was generated (in the base coordinate system of the
window).
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="unsigned int">
<sel>modifierFlags</sel>
<desc>
Returns the modifier flag bits associated with the
event.
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="float">
<sel>pressure</sel>
<desc>
Returns the pressure associated with a mouse event.
This is a value in the range 0.0 to 1.0 and for mormal
mouse events should be set to one of those extremes.
This is used by pressure sensitive input devices.
<br /> Raises an NSInternalInconsistencyException if
applied to any other type of event than a mouse
event.
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="short">
<sel>subtype</sel>
<desc>
Returns the 'subtype' item associated with the
event. <br /> Raises
NSInternalInconsistencyException
if the event is not of type NSAppKitDefined,
NSSystemDefined, NSApplicationDefined, or
NSPeriodic
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="NSTimeInterval">
<sel>timestamp</sel>
<desc>
Returns the time interval since system startup at
which this event was generated.
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="int">
<sel>trackingNumber</sel>
<desc>
Returns a number identifying the tracking rectangle
entered or exited. <br /> Raises an
NSInternalInconsistencyException
if applied to any other type of event than a mouse
entered or exited event.
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="NSEventType">
<sel>type</sel>
<desc>
returns the type of this event.
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="void*">
<sel>userData</sel>
<desc>
Returns usder data associated with a tracking
event... the data assigned to the tracking
rectangle concerned when it was created.. <br />
Raises an NSInternalInconsistencyException if
applied to any other type of event than a mouse
entered or exited event.
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="NSWindow*">
<sel>window</sel>
<desc>
Returns the window for which this event was
generated. <br /> Periodic events have no
associated window, and you should not call this
method for those events.
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<method type="int">
<sel>windowNumber</sel>
<desc>
Returns the window number of the window for which
this event was generated. <br /> Periodic events have
no associated window, and you should not call this
method for those events.
</desc>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</method>
<standards>
<GNUstep /> <MacOS-X /> <OpenStep />
</standards>
</class>
</chapter>
</body>
</gsdoc>