NXP
/
rt1050_emwin_gui_demo
RT1050 GUI demo using emWin library
Embed:
(wiki syntax)
Show/hide line numbers
EDIT_Private.h
00001 /********************************************************************* 00002 * SEGGER Microcontroller GmbH & Co. KG * 00003 * Solutions for real time microcontroller applications * 00004 ********************************************************************** 00005 * * 00006 * (c) 1996 - 2016 SEGGER Microcontroller GmbH & Co. KG * 00007 * * 00008 * Internet: www.segger.com Support: support@segger.com * 00009 * * 00010 ********************************************************************** 00011 00012 ** emWin V5.38 - Graphical user interface for embedded applications ** 00013 All Intellectual Property rights in the Software belongs to SEGGER. 00014 emWin is protected by international copyright laws. Knowledge of the 00015 source code may not be used to write a similar product. This file may 00016 only be used in accordance with the following terms: 00017 00018 The software has been licensed to NXP Semiconductors USA, Inc. whose 00019 registered office is situated at 411 E. Plumeria Drive, San Jose, 00020 CA 95134, USA solely for the purposes of creating libraries for 00021 NXPs M0, M3/M4 and ARM7/9 processor-based devices, sublicensed and 00022 distributed under the terms and conditions of the NXP End User License 00023 Agreement. 00024 Full source code is available at: www.segger.com 00025 00026 We appreciate your understanding and fairness. 00027 ---------------------------------------------------------------------- 00028 Licensing information 00029 00030 Licensor: SEGGER Microcontroller Systems LLC 00031 Licensed to: NXP Semiconductors, 1109 McKay Dr, M/S 76, San Jose, CA 95131, USA 00032 Licensed SEGGER software: emWin 00033 License number: GUI-00186 00034 License model: emWin License Agreement, dated August 20th 2011 00035 Licensed product: - 00036 Licensed platform: NXP's ARM 7/9, Cortex-M0,M3,M4 00037 Licensed number of seats: - 00038 ---------------------------------------------------------------------- 00039 File : EDIT_Private.h 00040 Purpose : Internal header file 00041 ---------------------------END-OF-HEADER------------------------------ 00042 */ 00043 00044 #ifndef EDIT_PRIVATE_H 00045 #define EDIT_PRIVATE_H 00046 00047 #include "EDIT.h" 00048 00049 #if GUI_WINSUPPORT 00050 00051 #include "WIDGET.h" 00052 00053 /********************************************************************* 00054 * 00055 * Defines 00056 * 00057 ********************************************************************** 00058 */ 00059 #define EDIT_REALLOC_SIZE 16 00060 00061 #ifndef EDIT_XOFF 00062 #define EDIT_XOFF 1 00063 #endif 00064 00065 /********************************************************************* 00066 * 00067 * Types 00068 * 00069 ********************************************************************** 00070 */ 00071 typedef struct EDIT_Obj_struct EDIT_Obj; 00072 00073 typedef struct { 00074 int Align; 00075 int Border; 00076 const GUI_FONT * pFont; 00077 GUI_COLOR aTextColor[3]; 00078 GUI_COLOR aBkColor[3]; 00079 } EDIT_PROPS; 00080 00081 struct EDIT_Obj_struct { 00082 WIDGET Widget; 00083 WM_HMEM hpText; 00084 I16 MaxLen; 00085 U16 BufferSize; 00086 I32 Min, Max; // Min max values as normalized floats (integers) 00087 U8 NumDecs; // Number of decimals 00088 I32 CurrentValue; // Current value 00089 int CursorPos; // Cursor position. 0 means left most 00090 unsigned SelSize; // Number of selected characters 00091 U8 EditMode; // Insert or overwrite mode 00092 U8 XSizeCursor; // Size of cursor when working in insert mode 00093 U8 Flags; 00094 tEDIT_AddKeyEx * pfAddKeyEx; // Handle key input 00095 tEDIT_UpdateBuffer * pfUpdateBuffer; // Update textbuffer 00096 EDIT_PROPS Props; 00097 WM_HTIMER hTimer; 00098 U8 MinMaxMode; 00099 }; 00100 00101 /********************************************************************* 00102 * 00103 * Macros for internal use 00104 * 00105 ********************************************************************** 00106 */ 00107 #if GUI_DEBUG_LEVEL >= GUI_DEBUG_LEVEL_CHECK_ALL 00108 #define EDIT_INIT_ID(p) (p->Widget.DebugId = EDIT_ID) 00109 #else 00110 #define EDIT_INIT_ID(p) 00111 #endif 00112 00113 #if GUI_DEBUG_LEVEL >= GUI_DEBUG_LEVEL_CHECK_ALL 00114 EDIT_Obj * EDIT_LockH(EDIT_Handle h); 00115 #define EDIT_LOCK_H(h) EDIT_LockH(h) 00116 #else 00117 #define EDIT_LOCK_H(h) (EDIT_Obj *)GUI_LOCK_H(h) 00118 #endif 00119 00120 /********************************************************************* 00121 * 00122 * Public data (internal defaults) 00123 * 00124 ********************************************************************** 00125 */ 00126 extern EDIT_PROPS EDIT__DefaultProps; 00127 00128 /********************************************************************* 00129 * 00130 * Public functions (internal) 00131 * 00132 ********************************************************************** 00133 */ 00134 U16 EDIT__GetCurrentChar (EDIT_Obj * pObj); 00135 void EDIT__SetCursorPos (EDIT_Handle hObj, int CursorPos); 00136 void EDIT__SetValueUnsigned(EDIT_Handle hObj, I32 Value); 00137 00138 #endif // GUI_WINSUPPORT 00139 00140 #endif // EDIT_PRIVATE_H 00141 00142 /*************************** End of file ****************************/
Generated on Tue Jul 12 2022 19:43:35 by 1.7.2