STM32F769IDiscovery  1.00
uDANTE Audio Networking with STM32F7 DISCO board
PROGBAR_Private.h
Go to the documentation of this file.
1 /*********************************************************************
2 * SEGGER Microcontroller GmbH & Co. KG *
3 * Solutions for real time microcontroller applications *
4 **********************************************************************
5 * *
6 * (c) 1996 - 2015 SEGGER Microcontroller GmbH & Co. KG *
7 * *
8 * Internet: www.segger.com Support: support@segger.com *
9 * *
10 **********************************************************************
11 
12 ** emWin V5.28 - Graphical user interface for embedded applications **
13 All Intellectual Property rights in the Software belongs to SEGGER.
14 emWin is protected by international copyright laws. Knowledge of the
15 source code may not be used to write a similar product. This file may
16 only be used in accordance with the following terms:
17 
18 The software has been licensed to STMicroelectronics International
19 N.V. a Dutch company with a Swiss branch and its headquarters in Plan-
20 les-Ouates, Geneva, 39 Chemin du Champ des Filles, Switzerland for the
21 purposes of creating libraries for ARM Cortex-M-based 32-bit microcon_
22 troller products commercialized by Licensee only, sublicensed and dis_
23 tributed under the terms and conditions of the End User License Agree_
24 ment supplied by STMicroelectronics International N.V.
25 Full source code is available at: www.segger.com
26 
27 We appreciate your understanding and fairness.
28 ----------------------------------------------------------------------
29 File : PROGBAR_Private.h
30 Purpose : Internal header file
31 ---------------------------END-OF-HEADER------------------------------
32 */
33 
34 #ifndef PROGBAR_PRIVATE_H
35 #define PROGBAR_PRIVATE_H
36 
37 #include "PROGBAR.h"
38 #include "WIDGET.h"
39 
40 #if GUI_WINSUPPORT
41 
42 /*********************************************************************
43 *
44 * Defines
45 *
46 **********************************************************************
47 */
48 #define PROGBAR_SF_HORIZONTAL PROGBAR_CF_HORIZONTAL
49 #define PROGBAR_SF_VERTICAL PROGBAR_CF_VERTICAL
50 #define PROGBAR_SF_USER PROGBAR_CF_USER
51 
52 /*********************************************************************
53 *
54 * Types
55 *
56 **********************************************************************
57 */
58 typedef struct {
59  WIDGET_DRAW_ITEM_FUNC * pfDrawSkin;
60 } PROGBAR_SKIN_PRIVATE;
61 
62 typedef struct {
63  const GUI_FONT * pFont;
64  GUI_COLOR aBarColor[2];
65  GUI_COLOR aTextColor[2];
66  PROGBAR_SKIN_PRIVATE SkinPrivate;
67 } PROGBAR_PROPS;
68 
69 typedef struct {
70  WIDGET Widget;
71  int v;
72  WM_HMEM hpText;
73  I16 XOff, YOff;
74  I16 TextAlign;
75  int Min, Max;
76  PROGBAR_PROPS Props;
77  WIDGET_SKIN const * pWidgetSkin;
78  U8 Flags;
79 } PROGBAR_Obj;
80 
81 /*********************************************************************
82 *
83 * Macros for internal use
84 *
85 **********************************************************************
86 */
87 #if GUI_DEBUG_LEVEL >= GUI_DEBUG_LEVEL_CHECK_ALL
88  #define PROGBAR_INIT_ID(p) p->Widget.DebugId = PROGBAR_ID
89 #else
90  #define PROGBAR_INIT_ID(p)
91 #endif
92 
93 #if GUI_DEBUG_LEVEL >= GUI_DEBUG_LEVEL_CHECK_ALL
94  PROGBAR_Obj * PROGBAR_LockH(PROGBAR_Handle h);
95  #define PROGBAR_LOCK_H(h) PROGBAR_LockH(h)
96 #else
97  #define PROGBAR_LOCK_H(h) (PROGBAR_Obj *)GUI_LOCK_H(h)
98 #endif
99 
100 /*********************************************************************
101 *
102 * Public data (internal defaults)
103 *
104 **********************************************************************
105 */
106 extern PROGBAR_PROPS PROGBAR__DefaultProps;
107 
108 extern const WIDGET_SKIN PROGBAR__SkinClassic;
109 extern WIDGET_SKIN PROGBAR__Skin;
110 
111 extern WIDGET_SKIN const * PROGBAR__pSkinDefault;
112 
113 /*********************************************************************
114 *
115 * Public functions (internal)
116 *
117 **********************************************************************
118 */
119 char * PROGBAR__GetTextLocked(const PROGBAR_Obj * pObj);
120 void PROGBAR__GetTextRect (const PROGBAR_Obj * pObj, GUI_RECT * pRect, const char * pText);
121 int PROGBAR__Value2Pos (const PROGBAR_Obj * pObj, int v);
122 
123 #endif /* GUI_WINSUPPORT */
124 #endif /* PROGBAR_PRIVATE_H */
125 
126 /*************************** End of file ****************************/
Definition: LCD.h:102
LCD_COLOR GUI_COLOR
Definition: GUI_Type.h:50
#define I16
Definition: Global.h:56
#define U8
Definition: Global.h:44