📄 group__nanox__window.html
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"><html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"><title>Nano-X window API.</title><link href="doxygen.css" rel="stylesheet" type="text/css"></head><body><!-- Generated by Doxygen 1.3 --><center><a class="qindex" href="index.html">Main Page</a> <a class="qindex" href="modules.html">Modules</a> <a class="qindex" href="classes.html">Alphabetical List</a> <a class="qindex" href="annotated.html">Data Structures</a> <a class="qindex" href="files.html">File List</a> <a class="qindex" href="functions.html">Data Fields</a> <a class="qindex" href="pages.html">Related Pages</a> </center><hr><h1>Nano-X window API.<br><small>[<a class="el" href="group__nanox.html">Nano-X public API</a>]</small></h1>Functions for handling windows on the screen. <a href="#_details">More...</a><table border=0 cellpadding=0 cellspacing=0><tr><td></td></tr><tr><td colspan=2><br><h2>Functions</h2></td></tr><tr><td nowrap align=right valign=top>GR_WINDOW_ID </td><td valign=bottom><a class="el" href="group__nanox__window.html#a0">GrNewWindow</a> (GR_WINDOW_ID parent, GR_COORD x, GR_COORD y, GR_SIZE width, GR_SIZE height, GR_SIZE bordersize, GR_COLOR background, GR_COLOR bordercolor)</td></tr><tr><td> </td><td><em class="mdesc">Create a new window.</em> <a href="#a0"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>GR_WINDOW_ID </td><td valign=bottom><a class="el" href="group__nanox__window.html#a1">GrNewPixmap</a> (GR_SIZE width, GR_SIZE height, void *pixels)</td></tr><tr><td> </td><td><em class="mdesc">Create a new server side pixmap.</em> <a href="#a1"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>GR_WINDOW_ID </td><td valign=bottom><a class="el" href="group__nanox__window.html#a2">GrNewInputWindow</a> (GR_WINDOW_ID parent, GR_COORD x, GR_COORD y, GR_SIZE width, GR_SIZE height)</td></tr><tr><td> </td><td><em class="mdesc">Create a new input-only window with the specified dimensions which is a child of the specified parent window.</em> <a href="#a2"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a3">GrDestroyWindow</a> (GR_WINDOW_ID wid)</td></tr><tr><td> </td><td><em class="mdesc">Destroys a window and all of it's children.</em> <a href="#a3"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a4">GrGetWindowInfo</a> (GR_WINDOW_ID wid, <a class="el" href="structGR__WINDOW__INFO.html">GR_WINDOW_INFO</a> *infoptr)</td></tr><tr><td> </td><td><em class="mdesc">Fills in a <a class="el" href="structGR__WINDOW__INFO.html">GR_WINDOW_INFO</a> structure with information regarding a window.</em> <a href="#a4"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a5">GrMapWindow</a> (GR_WINDOW_ID wid)</td></tr><tr><td> </td><td><em class="mdesc">Recursively maps (makes visible) the specified window and all of the child windows which have a sufficient map count.</em> <a href="#a5"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a6">GrUnmapWindow</a> (GR_WINDOW_ID wid)</td></tr><tr><td> </td><td><em class="mdesc">Recursively unmaps (makes invisible) the specified window and all of the child windows.</em> <a href="#a6"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a7">GrRaiseWindow</a> (GR_WINDOW_ID wid)</td></tr><tr><td> </td><td><em class="mdesc">Places the specified window at the top of its parents drawing stack, above all of its sibling windows.</em> <a href="#a7"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a8">GrLowerWindow</a> (GR_WINDOW_ID wid)</td></tr><tr><td> </td><td><em class="mdesc">Places the specified window at the bottom of its parents drawing stack, below all of its sibling windows.</em> <a href="#a8"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a9">GrMoveWindow</a> (GR_WINDOW_ID wid, GR_COORD x, GR_COORD y)</td></tr><tr><td> </td><td><em class="mdesc">Moves the specified window to the specified position relative to its parent window.</em> <a href="#a9"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a10">GrResizeWindow</a> (GR_WINDOW_ID wid, GR_SIZE width, GR_SIZE height)</td></tr><tr><td> </td><td><em class="mdesc">Resizes the specified window to be the specified width and height.</em> <a href="#a10"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a11">GrReparentWindow</a> (GR_WINDOW_ID wid, GR_WINDOW_ID pwid, GR_COORD x, GR_COORD y)</td></tr><tr><td> </td><td><em class="mdesc">Changes the parent window of the specified window to the specified parent window and places it at the specified coordinates relative to the new parent.</em> <a href="#a11"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>GR_WINDOW_ID </td><td valign=bottom><a class="el" href="group__nanox__window.html#a12">GrGetFocus</a> (void)</td></tr><tr><td> </td><td><em class="mdesc">Returns the ID of the window which currently has the keyboard focus.</em> <a href="#a12"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a13">GrSetFocus</a> (GR_WINDOW_ID wid)</td></tr><tr><td> </td><td><em class="mdesc">Sets the keyboard focus to the specified window.</em> <a href="#a13"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a14">GrSetWMProperties</a> (GR_WINDOW_ID wid, <a class="el" href="structGR__WM__PROPERTIES.html">GR_WM_PROPERTIES</a> *props)</td></tr><tr><td> </td><td><em class="mdesc">Copies the provided <a class="el" href="structGR__WM__PROPERTIES.html">GR_WM_PROPERTIES</a> structure into the the <a class="el" href="structGR__WM__PROPERTIES.html">GR_WM_PROPERTIES</a> structure of the specified window id.</em> <a href="#a14"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a15">GrGetWMProperties</a> (GR_WINDOW_ID wid, <a class="el" href="structGR__WM__PROPERTIES.html">GR_WM_PROPERTIES</a> *props)</td></tr><tr><td> </td><td><em class="mdesc">Reads the <a class="el" href="structGR__WM__PROPERTIES.html">GR_WM_PROPERTIES</a> structure for the window with the specified id and fills in the provided structure with the information.</em> <a href="#a15"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a16">GrCloseWindow</a> (GR_WINDOW_ID wid)</td></tr><tr><td> </td><td><em class="mdesc">Sends a CLOSE_REQ event to the specified window if the client has selected to receive CLOSE_REQ events on this window.</em> <a href="#a16"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a17">GrKillWindow</a> (GR_WINDOW_ID wid)</td></tr><tr><td> </td><td><em class="mdesc">Forcibly disconnects the client which owns this window with the specified ID number.</em> <a href="#a17"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a18">GrSetBackgroundPixmap</a> (GR_WINDOW_ID wid, GR_WINDOW_ID pixmap, int flags)</td></tr><tr><td> </td><td><em class="mdesc">Sets the background of the specified window to the specified pixmap.</em> <a href="#a18"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a19">GrQueryTree</a> (GR_WINDOW_ID wid, GR_WINDOW_ID *parentid, GR_WINDOW_ID **children, GR_COUNT *nchildren)</td></tr><tr><td> </td><td><em class="mdesc">Return window parent and list of children.</em> <a href="#a19"></a><em></em><br><br></td></tr><tr><td nowrap align=right valign=top>void </td><td valign=bottom><a class="el" href="group__nanox__window.html#a20">GrSetWindowRegion</a> (GR_WINDOW_ID wid, GR_REGION_ID rid, int type)</td></tr><tr><td> </td><td><em class="mdesc">Sets the bounding region of the specified window, not to be confused with a GC clip region.</em> <a href="#a20"></a><em></em><br><br></td></tr></table><hr><a name="_details"></a><h2>Detailed Description</h2>Functions for handling windows on the screen.<p><hr><h2>Function Documentation</h2><a name="a16" doxytag="nano-X.h::GrCloseWindow"></a><p><table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> void GrCloseWindow </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">GR_WINDOW_ID </td> <td class="mdname1" valign="top" nowrap> <em>wid</em> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr></table><table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td><p>Sends a CLOSE_REQ event to the specified window if the client has selected to receive CLOSE_REQ events on this window.<p>Used to request an application to shut down but not force it to do so immediately, so the application can ask whether to save changed files before shutting down cleanly.<p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign=top><em>wid</em> </td><td>the ID of the window to send the CLOSE_REQ event to </td></tr> </table></dl> </td> </tr></table><a name="a3" doxytag="nano-X.h::GrDestroyWindow"></a><p><table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> void GrDestroyWindow </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">GR_WINDOW_ID </td> <td class="mdname1" valign="top" nowrap> <em>wid</em> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr></table><table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td><p>Destroys a window and all of it's children.<p>Recursively unmaps and frees the data structures associated with the specified window and all of its children.<p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign=top><em>wid</em> </td><td>The ID of the window to destroy. </td></tr> </table></dl> </td> </tr></table><a name="a12" doxytag="nano-X.h::GrGetFocus"></a><p><table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> GR_WINDOW_ID GrGetFocus </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">void </td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr></table><table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td><p>Returns the ID of the window which currently has the keyboard focus.<p><dl compact><dt><b>Returns:</b></dt><dd>the ID of the window which currently has the keyboard focus </dd></dl> </td> </tr></table><a name="a4" doxytag="nano-X.h::GrGetWindowInfo"></a><p><table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> void GrGetWindowInfo </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">GR_WINDOW_ID </td> <td class="mdname" nowrap> <em>wid</em>, </td> </tr> <tr> <td></td> <td></td> <td class="md" nowrap><a class="el" href="structGR__WINDOW__INFO.html">GR_WINDOW_INFO</a> * </td> <td class="mdname" nowrap> <em>infoptr</em></td> </tr> <tr> <td></td> <td class="md">) </td> <td class="md" colspan="2"></td> </tr> </table> </td> </tr></table><table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td><p>Fills in a <a class="el" href="structGR__WINDOW__INFO.html">GR_WINDOW_INFO</a> structure with information regarding a window.<p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign=top><em>wid</em> </td><td>The ID of the window to retrieve information about. </td></tr> <tr><td valign=top><em>infoptr</em> </td><td>Pointer to a <a class="el" href="structGR__WINDOW__INFO.html">GR_WINDOW_INFO</a> structure to return the information in. </td></tr> </table></dl> </td> </tr></table><a name="a15" doxytag="nano-X.h::GrGetWMProperties"></a><p><table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> void GrGetWMProperties </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">GR_WINDOW_ID </td> <td class="mdname" nowrap> <em>wid</em>, </td> </tr> <tr> <td></td> <td></td> <td class="md" nowrap><a class="el" href="structGR__WM__PROPERTIES.html">GR_WM_PROPERTIES</a> * </td> <td class="mdname" nowrap> <em>props</em></td> </tr> <tr> <td></td> <td class="md">) </td> <td class="md" colspan="2"></td> </tr> </table> </td> </tr></table><table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td><p>Reads the <a class="el" href="structGR__WM__PROPERTIES.html">GR_WM_PROPERTIES</a> structure for the window with the specified id and fills in the provided structure with the information.<p>It is the callers responsibility to free the title member as it is allocated dynamically. The title field will be set to NULL if the window has no title.<p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign=top><em>wid</em> </td><td>the ID of the window to retreive the WM properties of </td></tr> <tr><td valign=top><em>props</em> </td><td>pointer to a <a class="el" href="structGR__WM__PROPERTIES.html">GR_WM_PROPERTIES</a> structure to fill in </td></tr> </table></dl> </td> </tr></table><a name="a17" doxytag="nano-X.h::GrKillWindow"></a><p><table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> void GrKillWindow </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">GR_WINDOW_ID </td> <td class="mdname1" valign="top" nowrap> <em>wid</em> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr></table><table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td><p>Forcibly disconnects the client which owns this window with the specified ID number.<p>Used to kill an application which has locked up and is not responding to CLOSE_REQ events.<p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign=top><em>wid</em> </td><td>the ID of the window to kill </td></tr> </table></dl> </td> </tr></table><a name="a8" doxytag="nano-X.h::GrLowerWindow"></a><p><table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> void GrLowerWindow </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">GR_WINDOW_ID </td> <td class="mdname1" valign="top" nowrap> <em>wid</em> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr></table><table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td><p>Places the specified window at the bottom of its parents drawing stack, below all of its sibling windows.<p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign=top><em>wid</em> </td><td>the ID of the window to lower </td></tr> </table></dl> </td> </tr></table><a name="a5" doxytag="nano-X.h::GrMapWindow"></a><p><table width="100%" cellpadding="2" cellspacing="0" border="0"> <tr> <td class="md"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"> void GrMapWindow </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">GR_WINDOW_ID </td> <td class="mdname1" valign="top" nowrap> <em>wid</em> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap></td> </tr> </table> </td> </tr></table><table cellspacing=5 cellpadding=0 border=0> <tr> <td> </td> <td><p>Recursively maps (makes visible) the specified window and all of the child windows which have a sufficient map count.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -