NuMaker emWin HMI

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers HEADER_Private.h Source File

HEADER_Private.h

00001 /*********************************************************************
00002 *                 SEGGER Software GmbH                               *
00003 *        Solutions for real time microcontroller applications        *
00004 **********************************************************************
00005 *                                                                    *
00006 *        (c) 1996 - 2018  SEGGER Microcontroller GmbH                *
00007 *                                                                    *
00008 *        Internet: www.segger.com    Support:  support@segger.com    *
00009 *                                                                    *
00010 **********************************************************************
00011 
00012 ** emWin V5.48 - 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 by SEGGER Software GmbH to Nuvoton Technology Corporationat the address: No. 4, Creation Rd. III, Hsinchu Science Park, Taiwan
00019 for the purposes  of  creating  libraries  for its 
00020 Arm Cortex-M and  Arm9 32-bit microcontrollers, commercialized and distributed by Nuvoton Technology Corporation
00021 under  the terms and conditions  of  an  End  User  
00022 License  Agreement  supplied  with  the libraries.
00023 Full source code is available at: www.segger.com
00024 
00025 We appreciate your understanding and fairness.
00026 ----------------------------------------------------------------------
00027 Licensing information
00028 Licensor:                 SEGGER Software GmbH
00029 Licensed to:              Nuvoton Technology Corporation, No. 4, Creation Rd. III, Hsinchu Science Park, 30077 Hsinchu City, Taiwan
00030 Licensed SEGGER software: emWin
00031 License number:           GUI-00735
00032 License model:            emWin License Agreement, signed February 27, 2018
00033 Licensed platform:        Cortex-M and ARM9 32-bit series microcontroller designed and manufactured by or for Nuvoton Technology Corporation
00034 ----------------------------------------------------------------------
00035 Support and Update Agreement (SUA)
00036 SUA period:               2018-03-26 - 2019-03-27
00037 Contact to extend SUA:    sales@segger.com
00038 ----------------------------------------------------------------------
00039 File        : HEADER_Private.h
00040 Purpose     : Private HEADER include
00041 --------------------END-OF-HEADER-------------------------------------
00042 */
00043 
00044 #ifndef HEADER_PRIVATE_H
00045 #define HEADER_PRIVATE_H
00046 
00047 
00048 #include "HEADER.h"
00049 #include "WIDGET.h"
00050 #include "WM.h"
00051 #include "GUI_ARRAY.h"
00052 
00053 #if GUI_WINSUPPORT
00054 
00055 /*********************************************************************
00056 *
00057 *       Object definition
00058 *
00059 **********************************************************************
00060 */
00061 typedef struct {
00062   int     Width;
00063   I16     Align;
00064   WM_HMEM hDrawObj;
00065   char    acText[1];
00066 } HEADER_COLUMN;
00067 
00068 typedef struct {
00069   WIDGET_DRAW_ITEM_FUNC * pfDrawSkin;
00070 } HEADER_SKIN_PRIVATE;
00071 
00072 typedef struct {
00073   const GUI_FONT    * pFont;
00074   GUI_COLOR           BkColor;
00075   GUI_COLOR           TextColor;
00076   GUI_COLOR           ArrowColor;
00077   HEADER_SKIN_PRIVATE SkinPrivate;
00078 } HEADER_PROPS;
00079 
00080 typedef struct {
00081   WIDGET              Widget;
00082   HEADER_PROPS        Props;
00083   WIDGET_SKIN const * pWidgetSkin;
00084   GUI_ARRAY           Columns;
00085   int                 CapturePosX;
00086   int                 CaptureItem;
00087   int                 ScrollPos;
00088   int                 Sel;
00089   int                 DirIndicatorColumn;
00090   int                 DirIndicatorReverse;
00091   unsigned            Fixed;
00092   U8                  DragLimit;
00093 } HEADER_Obj;
00094 
00095 /*********************************************************************
00096 *
00097 *       Private (module internal) data
00098 *
00099 **********************************************************************
00100 */
00101 
00102 extern HEADER_PROPS        HEADER__DefaultProps;
00103 extern const GUI_CURSOR  * HEADER__pDefaultCursor;
00104 extern int                 HEADER__DefaultBorderH;
00105 extern int                 HEADER__DefaultBorderV;
00106 
00107 extern const WIDGET_SKIN   HEADER__SkinClassic;
00108 extern       WIDGET_SKIN   HEADER__Skin;
00109 
00110 extern WIDGET_SKIN const * HEADER__pSkinDefault;
00111 
00112 /*********************************************************************
00113 *
00114 *       Macros for internal use
00115 *
00116 **********************************************************************
00117 */
00118 #if GUI_DEBUG_LEVEL >= GUI_DEBUG_LEVEL_CHECK_ALL
00119   #define HEADER_INIT_ID(p)  (p->Widget.DebugId = HEADER_ID)
00120 #else
00121   #define HEADER_INIT_ID(p)
00122 #endif
00123 
00124 #if GUI_DEBUG_LEVEL >= GUI_DEBUG_LEVEL_CHECK_ALL
00125   HEADER_Obj * HEADER_LockH(HEADER_Handle h);
00126   #define HEADER_LOCK_H(h)   HEADER_LockH(h)
00127 #else
00128   #define HEADER_LOCK_H(h)   (HEADER_Obj *)GUI_LOCK_H(h)
00129 #endif
00130 
00131 void HEADER__SetDrawObj(HEADER_Handle hObj, unsigned Index, GUI_DRAW_HANDLE hDrawObj);
00132 
00133 
00134 #endif // GUI_WINSUPPORT
00135 #endif // Avoid multiple inclusion
00136 
00137 /*************************** End of file ****************************/