home *** CD-ROM | disk | FTP | other *** search
- <!-- manual page source format generated by PolyglotMan v3.0.8+X.Org, -->
- <!-- available at http://polyglotman.sourceforge.net/ -->
-
- <html>
- <head>
- <title>"SDL_MouseMotionEvent"("3") manual page</title>
- </head>
- <body bgcolor='#efefef' text='black' link='blue' vlink='#551A8B' alink='red'>
- <a href='#toc'>Table of Contents</a><p>
-
- <h2><a name='sect0' href='#toc0'>Name</a></h2>
- SDL_MouseMotionEvent- Mouse motion event structure
- <h2><a name='sect1' href='#toc1'>Structure Definition</a></h2>
- <p>
- <br>
- <pre>CWtypedef struct{
- Uint8 type;
- Uint8 state;
- Uint16 x, y;
- Sint16 xrel, yrel;
- } SDL_MouseMotionEvent;
- </pre><p>
-
- <h2><a name='sect2' href='#toc2'>Structure Data</a></h2>
-
- <dl>
-
- <dt><b>type</b> </dt>
- <dd><b>SDL_MOUSEMOTION</b> </dd>
-
- <dt><b>state</b> </dt>
- <dd>The current button state </dd>
-
- <dt><b>x</b>, <b>y</b>
- </dt>
- <dd>The X/Y coordinates of the mouse </dd>
-
- <dt><b>xrel</b>, <b>yrel</b> </dt>
- <dd>Relative motion in the X/Y
- direction </dd>
- </dl>
-
- <h2><a name='sect3' href='#toc3'>Description</a></h2>
- <p>
- <b>SDL_MouseMotionEvent</b> is a member of the <i><b>SDL_Event</b></i>
- union and is used when an event of type <b>SDL_MOUSEMOTION</b> is reported. <p>
- Simply
- put, a <b>SDL_MOUSEMOTION</b> type event occurs when a user moves the mouse within
- the application window or when <i><b>SDL_WarpMouse</b></i> is called. Both the absolute
- (<b>x</b> and <b>y</b>) and relative (<b>xrel</b> and <b>yrel</b>) coordinates are reported along with
- the current button states (<b>state</b>). The button state can be interpreted using
- the <b>SDL_BUTTON</b> macro (see <i><b>SDL_GetMouseState</b></i>). <p>
- If the cursor is hidden (<i><b>SDL_ShowCursor</b></i>(0))
- and the input is grabbed (<i><b>SDL_WM_GrabInput</b></i>(SDL_GRAB_ON)), then the mouse
- will give relative motion events even when the cursor reaches the edge
- fo the screen. This is currently only implemented on Windows and Linux/Unix-a-likes.
-
- <h2><a name='sect4' href='#toc4'>See Also</a></h2>
- <p>
- <i><b>SDL_Event</b></i>, <i><b>SDL_MouseButtonEvent</b></i>
- <!--
-
- <p>
-
- <hr><p>
- <a name='toc'><b>Table of Contents</b></a><p>
- <ul>
- <li><a name='toc0' href='#sect0'>Name</a></li>
- <li><a name='toc1' href='#sect1'>Structure Definition</a></li>
- <li><a name='toc2' href='#sect2'>Structure Data</a></li>
- <li><a name='toc3' href='#sect3'>Description</a></li>
- <li><a name='toc4' href='#sect4'>See Also</a></li>
- </ul>
- </body>
- </html>
-