⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 control.h

📁 使用GPS驱动中间件,先初始化GPS,发送相关命令,等待接收地理的数据,若接收到数据,可从液晶屏中显示.
💻 H
📖 第 1 页 / 共 5 页
字号:
 *      - BM_IMAGE_BITMAP\n
 *        Bitmap of a button.
 *      - BM_IMAGE_ICON\n
 *        Icon of a button.
 *
 * \return A handle of the bitmap or icon of the button, zero when error.
 */
#define BM_GETIMAGE             0xF0F6

#define BM_IMAGE_BITMAP         1
#define BM_IMAGE_ICON           2
    
/**
 * \def BM_SETIMAGE
 * \brief Associates a new image (icon or bitmap) with the button.
 *
 * An application sends a BM_SETIMAGE message to 
 * associate a new image (icon or bitmap) with the button.
 *
 * Please use BM_IMAGE_BITMAP or BM_IMAGE_ICON as the first parameter of the message 
 * to indicate the type of button control image:
 *  - BM_IMAGE_BITMAP\n
 *          Specifies the type of image to associate with the button to be a bitmap.
 *  - BM_IMAGE_ICON\n
 *          Specifies the type of image to associate with the button to be an icon.
 */
#define BM_SETIMAGE             0xF0F7

#define BM_MSGMAX               0xF100

    /** @} end of ctrl_button_msgs */
    
    /**
     * \defgroup ctrl_button_ncs Notification codes of button control
     * @{
     */

/**
 * \def BN_CLICKED
 * \brief The BN_CLICKED notification message is sent when the user clicks a button.
 */
#define BN_CLICKED          0

#define BN_PAINT            1   /* not supported */
#define BN_HILITE           2
#define BN_UNHILITE         3
#define BN_DISABLE          4   /* not supported */
#define BN_DOUBLECLICKED    5

/**
 * \def BN_PUSHED
 * \brief The BN_PUSHED notification message is sent when the user pushes a button.
 */
#define BN_PUSHED           BN_HILITE

/**
 * \def BN_UNPUSHED
 * \brief The BN_UNPUSHED notification message is sent when the user unpushes a button.
 */
#define BN_UNPUSHED         BN_UNHILITE

/**
 * \def BN_DBLCLK
 * \brief The BN_DBLCLK notification message is sent when the user double-clicks a button.
 */
#define BN_DBLCLK           BN_DOUBLECLICKED

/**
 * \def BN_SETFOCUS
 * \brief The BN_SETFOCUS notification message is sent when a button receives the keyboard focus.
 */
#define BN_SETFOCUS         6

/**
 * \def BN_KILLFOCUS
 * \brief The BN_KILLFOCUS notification message is sent when a button loses the keyboard focus.
 */
#define BN_KILLFOCUS        7

    /** @} end of ctrl_button_ncs */

    /** @} end of ctrl_button */

#endif /* _CTRL_BUTTON */

/****** Edit and MEdit Control ***********************************************/
#if defined (_CTRL_SIMEDIT) || defined(_CTRL_SLEDIT) || defined(_CTRL_MLEDIT)

    /**
     * \defgroup ctrl_edit Edit/MEdit control
     *
     * \bug You can not pass caption argument for multi-line edit control
     *      when you create it, just use null string:
     *
     * \code
     *  CreateWindowEx (CTRL_MEDIT, ..., "", ...);
     * \endcode
     *
     * @{
     */

/**
 * \def CTRL_EDIT
 * \brief The class name of simple single-line editor box.
 *
 * This edit control uses the system default fixed logical font.
 */
#define CTRL_EDIT           ("edit")

/**
 * \def CTRL_SLEDIT
 * \brief The class name of single-line editor box.
 *
 * This edit control uses the system logical font for control,
 * which may be variable-width font..
 */
#define CTRL_SLEDIT         ("sledit")

/**
 * \def CTRL_MLEDIT
 * \brief The class name of multiple-line editor box.
 *
 * This edit control uses the system logical font for control,
 * which may be variable-width font..
 */
#define CTRL_MLEDIT         ("mledit")

/**
 * \def CTRL_MEDIT
 * \brief Another class name of multiple-line editor box.
 *
 * This edit control uses the system logical font for control,
 * which may be variable-width font..
 */
#define CTRL_MEDIT          ("medit")

#define CTRL_OLDMEDIT       ("oldmedit")

    /**
     * \defgroup ctrl_edit_styles Styles of edit control
     * @{
     */

/**
 * \def ES_LEFT
 * \brief Left-aligns text.
 */
#define ES_LEFT             0x00000000L

#define ES_CENTER           0x00000001L
#define ES_RIGHT            0x00000002L
#define ES_MULTILINE        0x00000004L

/**
 * \def ES_UPPERCASE
 * \brief Converts all characters to uppercase as they are typed into the edit control.
 */
#define ES_UPPERCASE        0x00000008L

/**
 * \def ES_LOWERCASE
 * \brief Converts all characters to lowercase as they are typed into the edit control.
 */
#define ES_LOWERCASE        0x00000010L

/**
 * \def ES_PASSWORD
 * \brief Displays an asterisk (*) for each character typed into the edit control.
 */
#define ES_PASSWORD         0x00000020L

#define ES_AUTOVSCROLL      0x00000040L
#define ES_AUTOHSCROLL      0x00000080L

/**
 * \def ES_NOHIDESEL
 * \brief Edit control with this style will remain selected when focus is lost
 */
#define ES_NOHIDESEL        0x00000100L

/**
 * \def ES_AUTOSELECT
 * \brief Selects all text when getting focus
 */
#define ES_AUTOSELECT       0x00000400L
//#define ES_OEMCONVERT       0x00000400L

/**
 * \def ES_READONLY
 * \brief Prevents the user from typing or editing text in the edit control.
 */
#define ES_READONLY         0x00000800L

/**
 * \def ES_BASELINE
 * \brief Draws base line under input area instead of frame border.
 */
#define ES_BASELINE         0x00001000L

/**
 * \def ES_AUTOWRAP
 * \brief Automatically wraps against border when inputting.
 */
#define ES_AUTOWRAP         0x00002000L

/**
 * \def ES_TITLE
 * \brief Shows specified title texts.
 */
#define ES_TITLE            0x00004000L

/**
 * \def ES_TIP
 * \brief Shows specified tip texts.
 */
#define ES_TIP              0x00008000L

    /** @} end of ctrl_edit_styles */

    /**
     * \defgroup ctrl_edit_msgs Messages of edit control
     * @{
     */

/**
 * \def EM_GETSEL
 * \brief Gets the selected string in the edit control.
 *
 * \code
 * EM_GETSEL
 *
 * char *buffer;
 * int len;
 *
 * wParam = len;
 * lParam = (LPARAM)buffer;
 * \endcode
 *
 * \param len Length of buffer.
 * \param buffer Pointer to the string buffer
 *
 * \return length of the selected string
 */
#define EM_GETSEL               0xF0B0

/**
 * \def EM_SETSEL
 * \brief Sets the selected point in the edit control and makes
 *        the text between insertion point and selection point selected.
 *
 *        Generally, you should send EM_SETCARETPOS first to set insertion
 *        point before you use EM_SETSEL to select text.
 *
 * \code
 * EM_SETSEL
 *
 * int line_pos;
 * int char_pos;
 *
 * wParam = (WPARAM)line_pos;
 * lParam = (LPARAM)char_pos;
 * \endcode
 *
 * \param line_pos line position of the selection point.
 *                 For single line editor, it is always zero.
 *                 Note : For multi-line editor, "line" means a text string ended with a line
 *                 seperator, not a single text line in wrap mode. So, char_pos
 *                 means the character position in a text string.
 * \param char_pos character(wide character) position of the selection point.
 *
 * \return length of the selected string
 */
#define EM_SETSEL               0xF0B1
#define EM_SETSELECTION         EM_SETSEL

/**
 * \def EM_SELECTALL
 * \brief Selects all the texts, the same meaning as ctrl+a
 *        
 * \code
 * EM_SELECTALL
 *
 * wParam = 0;
 * lParam = 0;
 * \endcode
 */
#define EM_SELECTALL              0xF0B2

/**
 * \def EM_GETSELPOS
 * \brief Gets the position of the selection point.
 *
 * \code
 * EM_GETSELPOS
 * int* line_pos;
 * int* char_pos;
 *
 * wParam = (WPARAM)line_pos;
 * lParam = (LPARAM)char_pos;
 * \endcode
 *
 * \param line_pos Pointer to a integer buffer to save the selection line position.
 *                 For single line editor, it is always zero.
 *                 Note : Here "line" means a text string ended with a line
 *                 seperator, not a single text line in wrap mode. So, char_pos
 *                 means the character position in a text string.
 * \param char_pos Pointer to a integer buffer to save the selection character position.
 *
 * \return The string length of the text from the beginning to the selection point.
 */
#define EM_GETSELPOS              0xF0B3

/**
 * \def EM_INSERTCBTEXT
 * \brief Inserts the text in the clipboard to the current caret position
 *
 * \code
 * EM_INSERTCBTEXT
 * int len;
 * const char *string;
 *
 * wParam = len;
 * lParam = (LPARAM)string;
 * \endcode
 *
 * \param len Length of string
 * \param string Pointer to the text string
 */
#define EM_INSERTCBTEXT           0xF0B4

/**
 * \def EM_COPYTOCB
 * \brief Copies the currently selected text to the clipboard
 *
 * \code
 * EM_COPYTOCB
 *
 * wParam = 0;
 * lParam = 0
 * \endcode
 *
 * \return Length of the text which is really copied to clipboard.
 */
#define EM_COPYTOCB               0xF0B5

/**
 * \def EM_CUTTOCB
 * \brief Cuts the currently selected text to the clipboard
 *
 * \code
 * EM_CUTTOCB
 *
 * wParam = 0;
 * lParam = 0
 * \endcode
 *
 * \return Length of the text which is really copied to clipboard.
 */
#define EM_CUTTOCB               0xF0B6

/**
 * \def EM_SETLFDISPCHAR
 * \brief Sets the char used to represent the line seperator.
 *        
 * In default case, the line sperator will not be shown.
 * If the char used to represent the line seperator is not zero,
 *    this char will be shown in place of line seperator.
 *
 * \code
 * EM_SETLFDISPCHAR
 * unsigned char ch;
 *
 * wParam = 0;
 * lParam = ch;
 * \endcode
 *
 * \param ch the char used to represent the line seperator
 */
#define EM_SETLFDISPCHAR          0xF0B7

/**
 * \def EM_SETLINESEP
 * \brief Sets the line seperator.
 *        
 * In default case, the line sperator is '\n'.
 *
 * \code
 * EM_SETLINESEP
 * unsigned char ch;
 *
 * wParam = 0;
 * lParam = ch;
 * \endcode
 *
 * \param ch the new line seperator
 */
#define EM_SETLINESEP             0xF0B8

//#define EM_GETRECT              0xF0B2
//#define EM_SETRECT              0xF0B3
//#define EM_SETRECTNP            0xF0B4
//#define EM_SCROLL               0xF0B5

/**
 * \def EM_GETCARETPOS
 * \brief Gets the position of the caret.
 *
 * \code
 * EM_GETCARETPOS
 * int* line_pos;
 * int* char_pos;
 *
 * wParam = (WPARAM)line_pos;
 * lParam = (LPARAM)char_pos;
 * \endcode
 *
 * \param line_pos Pointer to a integer buffer to save the caret line position.
 *                 For single line editor, it is always zero.
 *                 Note : Here "line" means a text string ended with a line
 *                 seperator, not a single text line in wrap mode. So, char_pos
 *                 means the character position in a text string.
 * \param char_pos Pointer to a integer buffer to save the caret character position.
 *
 * \return The string length of the text from the beginning to the caret pos.
 */
#define EM_GETCARETPOS          0xF0B9

/**
 * \def EM_SETCARETPOS
 * \brief Sets the position of the caret.
 *
 * \code
 * EM_SETCARETPOS
 * int line_pos;
 * int char_pos;
 *
 * wParam = (WPARAM)line_pos;
 * lParam = (LPARAM)char_pos;
 * \endcode
 *
 * \param line_pos The new caret line position. For single line editor, it will be ignored.
 *                 Note : Here "line" means a text string ended with a line
 *                 seperator, not a single text line in wrap mode. So, char_pos
 *                 means the character position in a text string.
 * \param char_pos The new caret character position.
 *
 * \return length of the string from the beginning to the caret position 
 *         on success, otherwise -1.
 */
#define EM_SETCARETPOS          0xF0BA
#define EM_SETINSERTION         EM_SETCARETPOS

//#define EM_SCROLLCARET          0xF0B9
//#define EM_GETMODIFY            0xF0BA
//#define EM_SETMODIFY            0xF0BB

/**
 * \def EM_GETLINECOUNT
 * \brief Gets the line number.
 *
 * \code
 * EM_GETLINECOUNT
 *
 * wParam = 0;
 * lParam = 0;
 * \endcode
 *
 * \return Line number on success, otherwise -1.
 * \note Implemented for TextEdit control.
 */
#define EM_GETLINECOUNT         0xF0BC

/**
 * \def EM_GETLINEHEIGHT
 * \brief Gets the height of a line.
 *
 * \code
 * EM_GETLINEHEIGHT
 *
 * wParam = 0;
 * lParam = 0;
 * \endcode
 *
 * \return Height value.

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -