43 #if defined(__cplusplus) 54 #define TREEVIEW_CF_HIDELINES (1 << 0) 55 #define TREEVIEW_CF_ROWSELECT (1 << 1) 56 #define TREEVIEW_CF_AUTOSCROLLBAR_H (1 << 2) 57 #define TREEVIEW_CF_AUTOSCROLLBAR_V (1 << 3) 58 #define TREEVIEW_SF_HIDELINES TREEVIEW_CF_HIDELINES 59 #define TREEVIEW_SF_ROWSELECT TREEVIEW_CF_ROWSELECT 60 #define TREEVIEW_SF_AUTOSCROLLBAR_H TREEVIEW_CF_AUTOSCROLLBAR_H 61 #define TREEVIEW_SF_AUTOSCROLLBAR_V TREEVIEW_CF_AUTOSCROLLBAR_V 64 #define TREEVIEW_BI_CLOSED 0 65 #define TREEVIEW_BI_OPEN 1 66 #define TREEVIEW_BI_LEAF 2 67 #define TREEVIEW_BI_PLUS 3 68 #define TREEVIEW_BI_MINUS 4 69 #define TREEVIEW_BI_PM 5 72 #define TREEVIEW_CI_UNSEL 0 73 #define TREEVIEW_CI_SEL 1 74 #define TREEVIEW_CI_DISABLED 2 77 #define TREEVIEW_INSERT_ABOVE 0 78 #define TREEVIEW_INSERT_BELOW 1 79 #define TREEVIEW_INSERT_FIRST_CHILD 2 82 #define TREEVIEW_GET_FIRST 0 83 #define TREEVIEW_GET_LAST 1 84 #define TREEVIEW_GET_NEXT_SIBLING 2 85 #define TREEVIEW_GET_PREV_SIBLING 3 86 #define TREEVIEW_GET_FIRST_CHILD 4 87 #define TREEVIEW_GET_PARENT 5 90 #define TREEVIEW_ITEM_TYPE_LEAF (0 << 0) 91 #define TREEVIEW_ITEM_TYPE_NODE (1 << 0) 94 #define TREEVIEW_SELMODE_ROW 1 95 #define TREEVIEW_SELMODE_TEXT 0 103 typedef WM_HMEM TREEVIEW_Handle;
104 typedef WM_HMEM TREEVIEW_ITEM_Handle;
112 } TREEVIEW_ITEM_INFO;
120 TREEVIEW_ITEM_Handle hItem;
135 } TREEVIEW_ITEM_DRAW_INFO;
143 TREEVIEW_Handle TREEVIEW_CreateEx (
int x0,
int y0,
int xSize,
int ySize, WM_HWIN hParent,
int WinFlags,
int ExFlags,
int Id);
144 TREEVIEW_Handle TREEVIEW_CreateUser (
int x0,
int y0,
int xSize,
int ySize, WM_HWIN hParent,
int WinFlags,
int ExFlags,
int Id,
int NumExtraBytes);
145 TREEVIEW_Handle TREEVIEW_CreateIndirect(
const GUI_WIDGET_CREATE_INFO * pCreateInfo, WM_HWIN hWinParent,
int x0,
int y0, WM_CALLBACK * cb);
154 void TREEVIEW_Callback(WM_MESSAGE * pMsg);
162 int TREEVIEW_AttachItem (TREEVIEW_Handle hObj, TREEVIEW_ITEM_Handle hItem, TREEVIEW_ITEM_Handle hItemAt,
int Position);
163 void TREEVIEW_DecSel (TREEVIEW_Handle hObj);
164 TREEVIEW_ITEM_Handle TREEVIEW_GetItem (TREEVIEW_Handle hObj, TREEVIEW_ITEM_Handle hItem,
int Flags);
165 TREEVIEW_ITEM_Handle TREEVIEW_GetSel (TREEVIEW_Handle hObj);
166 int TREEVIEW_GetUserData (TREEVIEW_Handle hObj,
void * pDest,
int NumBytes);
167 void TREEVIEW_IncSel (TREEVIEW_Handle hObj);
168 TREEVIEW_ITEM_Handle TREEVIEW_InsertItem (TREEVIEW_Handle hObj,
int IsNode, TREEVIEW_ITEM_Handle hItemPrev,
int Position,
const char * s);
169 int TREEVIEW_OwnerDraw (
const WIDGET_ITEM_DRAW_INFO * pDrawItemInfo);
170 void TREEVIEW_ScrollToSel (TREEVIEW_Handle hObj);
171 void TREEVIEW_SetAutoScrollH (TREEVIEW_Handle hObj,
int State);
172 void TREEVIEW_SetAutoScrollV (TREEVIEW_Handle hObj,
int State);
173 void TREEVIEW_SetBitmapOffset(TREEVIEW_Handle hObj,
int Index,
int xOff,
int yOff);
174 void TREEVIEW_SetBkColor (TREEVIEW_Handle hObj,
int Index,
GUI_COLOR Color);
175 void TREEVIEW_SetFont (TREEVIEW_Handle hObj,
const GUI_FONT * pFont);
176 void TREEVIEW_SetHasLines (TREEVIEW_Handle hObj,
int State);
177 void TREEVIEW_SetImage (TREEVIEW_Handle hObj,
int Index,
const GUI_BITMAP * pBitmap);
178 int TREEVIEW_SetIndent (TREEVIEW_Handle hObj,
int Indent);
179 void TREEVIEW_SetLineColor (TREEVIEW_Handle hObj,
int Index,
GUI_COLOR Color);
180 void TREEVIEW_SetOwnerDraw (TREEVIEW_Handle hObj, WIDGET_DRAW_ITEM_FUNC * pfDrawItem);
181 void TREEVIEW_SetSel (TREEVIEW_Handle hObj, TREEVIEW_ITEM_Handle hItem);
182 void TREEVIEW_SetSelMode (TREEVIEW_Handle hObj,
int Mode);
183 void TREEVIEW_SetTextColor (TREEVIEW_Handle hObj,
int Index,
GUI_COLOR Color);
184 int TREEVIEW_SetTextIndent (TREEVIEW_Handle hObj,
int TextIndent);
185 int TREEVIEW_SetUserData (TREEVIEW_Handle hObj,
const void * pSrc,
int NumBytes);
194 void TREEVIEW_ITEM_Collapse (TREEVIEW_ITEM_Handle hItem);
195 void TREEVIEW_ITEM_CollapseAll(TREEVIEW_ITEM_Handle hItem);
196 TREEVIEW_ITEM_Handle TREEVIEW_ITEM_Create (
int IsNode,
const char * s,
U32 UserData);
197 void TREEVIEW_ITEM_Delete (TREEVIEW_ITEM_Handle hItem);
198 void TREEVIEW_ITEM_Detach (TREEVIEW_ITEM_Handle hItem);
199 void TREEVIEW_ITEM_Expand (TREEVIEW_ITEM_Handle hItem);
200 void TREEVIEW_ITEM_ExpandAll (TREEVIEW_ITEM_Handle hItem);
201 void TREEVIEW_ITEM_GetInfo (TREEVIEW_ITEM_Handle hItem, TREEVIEW_ITEM_INFO * pInfo);
202 void TREEVIEW_ITEM_GetText (TREEVIEW_ITEM_Handle hItem,
U8 * pBuffer,
int MaxNumBytes);
203 U32 TREEVIEW_ITEM_GetUserData(TREEVIEW_ITEM_Handle hItem);
204 void TREEVIEW_ITEM_SetImage (TREEVIEW_ITEM_Handle hItem,
int Index,
const GUI_BITMAP * pBitmap);
205 TREEVIEW_ITEM_Handle TREEVIEW_ITEM_SetText (TREEVIEW_ITEM_Handle hItem,
const char * s);
206 void TREEVIEW_ITEM_SetUserData(TREEVIEW_ITEM_Handle hItem,
U32 UserData);
214 GUI_COLOR TREEVIEW_GetDefaultBkColor (
int Index);
215 const GUI_FONT * TREEVIEW_GetDefaultFont (
void);
216 GUI_COLOR TREEVIEW_GetDefaultLineColor(
int Index);
217 GUI_COLOR TREEVIEW_GetDefaultTextColor(
int Index);
218 void TREEVIEW_SetDefaultBkColor (
int Index,
GUI_COLOR Color);
219 void TREEVIEW_SetDefaultFont (
const GUI_FONT * pFont);
220 void TREEVIEW_SetDefaultLineColor(
int Index,
GUI_COLOR Color);
221 void TREEVIEW_SetDefaultTextColor(
int Index,
GUI_COLOR Color);
223 #if defined(__cplusplus) 227 #endif // GUI_WINSUPPORT