📄 group__mywins__helpers.htm
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"><title>MiniGUI V1.6.10 API Reference: Useful helpers</title><link href="doxygen.css" rel="stylesheet" type="text/css"></head><body><!-- Generated by Doxygen 1.4.2 --><div class="qindex"><a class="qindex" href="index.htm">Main Page</a> | <a class="qindex" href="modules.htm">Modules</a> | <a class="qindex" href="classes.htm">Alphabetical List</a> | <a class="qindex" href="annotated.htm">Data Structures</a> | <a class="qindex" href="dirs.htm">Directories</a> | <a class="qindex" href="files.htm">File List</a> | <a class="qindex" href="functions.htm">Data Fields</a> | <a class="qindex" href="globals.htm">Globals</a> | <a class="qindex" href="pages.htm">Related Pages</a></div><h1>Useful helpers<br><small>[<a class="el" href="group__mywins__fns.htm">Interfaces of MyWins module of MiniGUIExt library</a>]</small></h1><h2>Data Structures</h2><ul><li>struct <a class="el" href="struct__myWinButton.htm">_myWinButton</a><li>struct <a class="el" href="struct__myWinEntry.htm">_myWinEntry</a></ul><h2>Typedefs</h2><ul><li>typedef <a class="el" href="struct__myWinButton.htm">_myWinButton</a> <a class="el" href="group__mywins__helpers.htm#ga0">myWINBUTTON</a><li>typedef <a class="el" href="struct__myWinEntry.htm">_myWinEntry</a> <a class="el" href="group__mywins__helpers.htm#ga2">myWINENTRY</a></ul><h2>Functions</h2><ul><li>MGEXT_EXPORT int <a class="el" href="group__mywins__helpers.htm#ga4">myMessageBox</a> (<a class="el" href="group__handles.htm#ga1">HWND</a> hwnd, <a class="el" href="group__win32__types.htm#ga4">DWORD</a> dwStyle, const char *title, const char *text,...)<dl class="el"><dd class="mdescRight">Creates a message box. <a href="#ga4"></a><br></dl><li>MGEXT_EXPORT int <a class="el" href="group__mywins__helpers.htm#ga5">myWinMessage</a> (<a class="el" href="group__handles.htm#ga1">HWND</a> hwnd, const char *title, const char *button1, const char *text,...)<dl class="el"><dd class="mdescRight">Creates a message box within only one button. <a href="#ga5"></a><br></dl><li>MGEXT_EXPORT int <a class="el" href="group__mywins__helpers.htm#ga6">myWinChoice</a> (<a class="el" href="group__handles.htm#ga1">HWND</a> hwnd, const char *title, const char *button1, const char *button2, const char *text,...)<dl class="el"><dd class="mdescRight">Creates a message box within two buttons. <a href="#ga6"></a><br></dl><li>MGEXT_EXPORT int <a class="el" href="group__mywins__helpers.htm#ga7">myWinTernary</a> (<a class="el" href="group__handles.htm#ga1">HWND</a> hwnd, const char *title, const char *button1, const char *button2, const char *button3, const char *text,...)<dl class="el"><dd class="mdescRight">Creates a message box within three buttons. <a href="#ga7"></a><br></dl><li>MGEXT_EXPORT void <a class="el" href="group__mywins__helpers.htm#ga8">errorWindow</a> (<a class="el" href="group__handles.htm#ga1">HWND</a> hwnd, const char *str, const char *title)<dl class="el"><dd class="mdescRight">A MiniGUI edition of <em>perror</em>. <a href="#ga8"></a><br></dl><li>MGEXT_EXPORT <a class="el" href="group__handles.htm#ga1">HWND</a> <a class="el" href="group__mywins__helpers.htm#ga9">createStatusWin</a> (<a class="el" href="group__handles.htm#ga1">HWND</a> hParentWnd, int width, int height, const char *title, const char *text,...)<dl class="el"><dd class="mdescRight">Creates a status main window. <a href="#ga9"></a><br></dl><li>MGEXT_EXPORT void <a class="el" href="group__mywins__helpers.htm#ga10">destroyStatusWin</a> (<a class="el" href="group__handles.htm#ga1">HWND</a> hwnd)<dl class="el"><dd class="mdescRight">Destroies a status window. <a href="#ga10"></a><br></dl><li>MGEXT_EXPORT <a class="el" href="group__handles.htm#ga1">HWND</a> <a class="el" href="group__mywins__helpers.htm#ga11">createToolTipWin</a> (<a class="el" href="group__handles.htm#ga1">HWND</a> hParentWnd, int x, int y, int timeout_ms, const char *text,...)<dl class="el"><dd class="mdescRight">Creates a tool tip window. <a href="#ga11"></a><br></dl><li>MGEXT_EXPORT void <a class="el" href="group__mywins__helpers.htm#ga12">resetToolTipWin</a> (<a class="el" href="group__handles.htm#ga1">HWND</a> hwnd, int x, int y, const char *text,...)<dl class="el"><dd class="mdescRight">Resets a tool tip window. <a href="#ga12"></a><br></dl><li>MGEXT_EXPORT void <a class="el" href="group__mywins__helpers.htm#ga13">destroyToolTipWin</a> (<a class="el" href="group__handles.htm#ga1">HWND</a> hwnd)<dl class="el"><dd class="mdescRight">Destroies a tool tip window. <a href="#ga13"></a><br></dl><li>MGEXT_EXPORT <a class="el" href="group__handles.htm#ga1">HWND</a> <a class="el" href="group__mywins__helpers.htm#ga14">createProgressWin</a> (<a class="el" href="group__handles.htm#ga1">HWND</a> hParentWnd, const char *title, const char *label, int id, int range)<dl class="el"><dd class="mdescRight">Creates a main window within a progress bar. <a href="#ga14"></a><br></dl><li>MGEXT_EXPORT void <a class="el" href="group__mywins__helpers.htm#ga15">destroyProgressWin</a> (<a class="el" href="group__handles.htm#ga1">HWND</a> hwnd)<dl class="el"><dd class="mdescRight">Destroies progress window. <a href="#ga15"></a><br></dl><li>MGEXT_EXPORT int <a class="el" href="group__mywins__helpers.htm#ga16">myWinMenu</a> (<a class="el" href="group__handles.htm#ga1">HWND</a> hParentWnd, const char *title, const char *label, int width, int listboxheight, char **items, int *listItem, <a class="el" href="struct__myWinButton.htm">myWINBUTTON</a> *buttons)<dl class="el"><dd class="mdescRight">Creates a menu main window for the user to select an item. <a href="#ga16"></a><br></dl><li>MGEXT_EXPORT int <a class="el" href="group__mywins__helpers.htm#ga17">myWinEntries</a> (<a class="el" href="group__handles.htm#ga1">HWND</a> hParentWnd, const char *title, const char *label, int width, int editboxwidth, <a class="el" href="group__simple__types.htm#ga0">BOOL</a> fIME, <a class="el" href="struct__myWinEntry.htm">myWINENTRY</a> *items, <a class="el" href="struct__myWinButton.htm">myWINBUTTON</a> *buttons)<dl class="el"><dd class="mdescRight">Creates a entry main window for the user to enter something. <a href="#ga17"></a><br></dl><li>MGEXT_EXPORT int <a class="el" href="group__mywins__helpers.htm#ga18">myWinHelpMessage</a> (<a class="el" href="group__handles.htm#ga1">HWND</a> hwnd, int width, int height, const char *help_title, const char *help_msg)<dl class="el"><dd class="mdescRight">Creates a help message window. <a href="#ga18"></a><br></dl></ul><hr><a name="_details"></a><h2>Detailed Description</h2>This module defines some useful helpers, such as tool-tip window, progress window, and so on. <hr><h2>Typedef Documentation</h2><a class="anchor" name="ga0" doxytag="mywindows.h::myWINBUTTON"></a><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top">typedef struct <a class="el" href="struct__myWinButton.htm">_myWinButton</a> <a class="el" href="struct__myWinButton.htm">myWINBUTTON</a> </td> </tr> </table> </td> </tr></table><table cellspacing="5" cellpadding="0" border="0"> <tr> <td> </td> <td><p>Button info structure used by <em>myWinMenu</em> and <em>myWinEntries</em> function. <dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__mywins__helpers.htm#ga16">myWinMenu</a>, <a class="el" href="group__mywins__helpers.htm#ga17">myWinEntries</a> </dd></dl> </td> </tr></table><a class="anchor" name="ga2" doxytag="mywindows.h::myWINENTRY"></a><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top">typedef struct <a class="el" href="struct__myWinEntry.htm">_myWinEntry</a> <a class="el" href="struct__myWinEntry.htm">myWINENTRY</a> </td> </tr> </table> </td> </tr></table><table cellspacing="5" cellpadding="0" border="0"> <tr> <td> </td> <td><p>Entry info structure used by <em>myWinEntries</em> function. <dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__mywins__helpers.htm#ga17">myWinEntries</a> </dd></dl> </td> </tr></table><hr><h2>Function Documentation</h2><a class="anchor" name="ga14" doxytag="mywindows.h::createProgressWin"></a><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"><a class="el" href="group__handles.htm#ga1">HWND</a> createProgressWin </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top"><a class="el" href="group__handles.htm#ga1">HWND</a> </td> <td class="mdname" nowrap> <em>hParentWnd</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>const char * </td> <td class="mdname" nowrap> <em>title</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>const char * </td> <td class="mdname" nowrap> <em>label</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>int </td> <td class="mdname" nowrap> <em>id</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>int </td> <td class="mdname" nowrap> <em>range</em></td> </tr> <tr> <td class="md"></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>Creates a main window within a progress bar. <p>This function creates a main window within a progress bar and returns the handle. You can call <em>destroyProgressWin</em> to destroy it.<p>Note that you can use <em>SendDlgItemMessage</em> to send a message to the progress bar in the main window in order to update the progress bar.<p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>hParentWnd</em> </td><td>The hosting main window. </td></tr> <tr><td valign="top"></td><td valign="top"><em>title</em> </td><td>The title of the progress window. </td></tr> <tr><td valign="top"></td><td valign="top"><em>label</em> </td><td>The text in the label of the progress bar. </td></tr> <tr><td valign="top"></td><td valign="top"><em>id</em> </td><td>The identifier of the progress bar. </td></tr> <tr><td valign="top"></td><td valign="top"><em>range</em> </td><td>The maximal value of the progress bar (minimal value is 0).</td></tr> </table></dl><dl compact><dt><b>Returns:</b></dt><dd>The handle to the progress window on success, HWND_INVALID on error.</dd></dl><dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__mywins__helpers.htm#ga15">destroyProgressWin</a> </dd></dl> </td> </tr></table><a class="anchor" name="ga9" doxytag="mywindows.h::createStatusWin"></a><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"><a class="el" href="group__handles.htm#ga1">HWND</a> createStatusWin </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top"><a class="el" href="group__handles.htm#ga1">HWND</a> </td> <td class="mdname" nowrap> <em>hParentWnd</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>int </td> <td class="mdname" nowrap> <em>width</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>int </td> <td class="mdname" nowrap> <em>height</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>const char * </td> <td class="mdname" nowrap> <em>title</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>const char * </td> <td class="mdname" nowrap> <em>text</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap> </td> <td class="mdname" nowrap> <em>...</em></td> </tr> <tr> <td class="md"></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>Creates a status main window. <p>This function creates a status main window and returns the handle to it. You can call <em>destroyStatusWin</em> to destroy it. This function also receives <em>printf-like</em> arguments to format a string.<p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>hParentWnd</em> </td><td>The hosting main window. </td></tr> <tr><td valign="top"></td><td valign="top"><em>width</em> </td><td>The width of the status window. </td></tr> <tr><td valign="top"></td><td valign="top"><em>height</em> </td><td>The height of the status window. </td></tr> <tr><td valign="top"></td><td valign="top"><em>title</em> </td><td>The title of the status window. </td></tr> <tr><td valign="top"></td><td valign="top"><em>text</em> </td><td>The format string.</td></tr> </table></dl><dl compact><dt><b>Returns:</b></dt><dd>The handle to the status window on success, HWND_INVALID on error.</dd></dl><dl compact><dt><b>See also:</b></dt><dd><a class="el" href="group__mywins__helpers.htm#ga10">destroyStatusWin</a> </dd></dl> </td> </tr></table><a class="anchor" name="ga11" doxytag="mywindows.h::createToolTipWin"></a><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top"><a class="el" href="group__handles.htm#ga1">HWND</a> createToolTipWin </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top"><a class="el" href="group__handles.htm#ga1">HWND</a> </td> <td class="mdname" nowrap> <em>hParentWnd</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>int </td> <td class="mdname" nowrap> <em>x</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>int </td> <td class="mdname" nowrap> <em>y</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>int </td> <td class="mdname" nowrap> <em>timeout_ms</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>const char * </td> <td class="mdname" nowrap> <em>text</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap> </td> <td class="mdname" nowrap> <em>...</em></td>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -