RT1050 GUI demo using emWin library

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers HEADER_Private.h Source File

HEADER_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        : 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