/* CONTAINEREX.H - LEAD Container header file Copyright (c) 1991-2005 LEAD Technologies, Inc. All Rights Reserved. */ #if !defined(INC_LTCNTR_H) #define INC_LTCNTR_H #include "ltkrn.h" #include "ltdis.h" #include "ltefx.h" #include "ltimg.h" #define _HEADER_ENTRY_ #include "ltpck.h" /* The window class for the container control */ #define LTCONTAINERCLASS TEXT("LEADCONTAINER32") /* The container handle */ typedef HANDLE HDISPCONTAINER; typedef struct tagDISPCONTAINERPROPERTIES { L_UINT uStructSize; L_UINT uMask; L_UINT uMask1; L_UINT uNumRows; L_UINT uNumCols; COLORREF crEmptyCellBackGroundColor; COLORREF crBackground; COLORREF crText; COLORREF crShadow; COLORREF crRulerIn; COLORREF crRulerout; COLORREF crActiveBorderColor; COLORREF crNonActiveBorderColor; COLORREF crActiveSubCellBorderColor; HCURSOR hDefaultCursor; HCURSOR hRszVertCursor; HCURSOR hRszHorzCursor; HCURSOR hRszBothCursor; L_BOOL bAutoScroll; L_UINT uCellsMaintenance; L_BOOL bShowFreezeText; L_UINT uBorderStyle; L_UINT uTextQuality; L_UINT uRulerStyle; } DISPCONTAINERPROPERTIES, L_FAR * pDISPCONTAINERPROPERTIES; typedef struct tagDISPCELLPROPERTIES { L_UINT uStructSize; L_UINT uMask; L_UINT uShowRuler; L_UINT uShowTags; L_UINT uNumRows; L_UINT uNumCols; L_BOOL bOnMove; L_BOOL bIndividual; L_BOOL bIsFit; } DISPCELLPROPERTIES, * pDISPCELLPROPERTIES; typedef struct tagDISPCONTAINERACTIONPROPS { L_UINT uStructSize; HCURSOR hCursor; L_INT nChange; L_BOOL bCircularMouseMove; } DISPCONTAINERACTIONPROPS, L_FAR * pDISPCONTAINERACTIONPROPS; typedef struct tagDISPWLEVELACTIONPROPS { DISPCONTAINERACTIONPROPS DispContainerActionProps; COLORREF rgbColorStart; COLORREF rgbColorEnd; L_INT nWidth; L_INT nCenter; L_UINT uFillType; } DISPWLEVELACTIONPROPS, L_FAR * pDISPWLEVELACTIONPROPS; typedef struct tagDISPALPHAACTIONPROPS { DISPCONTAINERACTIONPROPS DispContainerActionProps; L_INT nFactor; } DISPALPHAACTIONPROPS, L_FAR * pDISPALPHAACTIONPROPS; typedef struct tagDISPMAGACTIONPROPS { DISPCONTAINERACTIONPROPS DispContainerActionProps; L_INT nWidth; L_INT nHeight; L_INT nZoom; COLORREF clrPen; L_BOOL bEllipse; L_INT nBorderSize; L_BOOL b3D; L_INT nCrosshair; } DISPMAGACTIONPROPS, L_FAR * pDISPMAGACTIONPROPS; typedef struct tagDISPOFFSETACTIONPROPS { DISPCONTAINERACTIONPROPS DispContainerActionProps; L_INT nXOffset; L_INT nYOffset; } DISPOFFSETACTIONPROPS, L_FAR * pDISPOFFSETACTIONPROPS; typedef struct tagDISPSCALEACTIONPROPS { DISPCONTAINERACTIONPROPS DispContainerActionProps; L_UINT uScale; } DISPSCALEACTIONPROPS, L_FAR * pDISPSCALEACTIONPROPS; typedef struct tagDISPSTACKACTIONPROPS { DISPCONTAINERACTIONPROPS DispContainerActionProps; L_INT nScrollValue; L_INT nActiveSubCell; } DISPSTACKACTIONPROPS, L_FAR * pDISPSTACKACTIONPROPS; typedef struct tagDISPOWNERACTIONPROPS { DISPCONTAINERACTIONPROPS DispContainerActionProps; } DISPOWNERACTIONPROPS, L_FAR * pDISPOWNERACTIONPROPS; #define MAX_BUTTON_NUM 7 #define CONTAINER_ACTION_WINDOWLEVEL 1 #define CONTAINER_ACTION_SCALE 2 #define CONTAINER_ACTION_OFFSET 3 #define CONTAINER_ACTION_STACK 4 #define CONTAINER_ACTION_MAG 5 #define CONTAINER_ACTION_ALPHA 6 #define DISPWIN_ALIGN_TOPLEFT 0 #define DISPWIN_ALIGN_LEFTCENTER 1 #define DISPWIN_ALIGN_BOTTOMLEFT 2 #define DISPWIN_ALIGN_TOPCENTER 3 #define DISPWIN_ALIGN_BOTTOMCENTER 4 #define DISPWIN_ALIGN_TOPRIGHT 5 #define DISPWIN_ALIGN_RIGHTCENTER 6 #define DISPWIN_ALIGN_BOTTOMRIGHT 7 #define DISPWIN_TYPE_USERDATA 0 #define DISPWIN_TYPE_SCALE 1 #define DISPWIN_TYPE_WLCENTERWIDTH 2 #define DISPWIN_TYPE_FIELDOFVIEW 3 #define DISPWIN_TYPE_OWNERDRAW 4 #define DISPWIN_TYPE_FRAME 5 #define DCPF_ALL 0x001FFFFF #define DCPF_NUMROWS 0x00000001 #define DCPF_NUMCOLS 0x00000002 #define DCPF_EMPTYCELLBACKGROUNDCOLOR 0x00000004 #define DCPF_BACKGROUNDCOLOR 0x00000008 #define DCPF_TEXTCOLOR 0x00000010 #define DCPF_SHADOWCOLOR 0x00000020 #define DCPF_RULERINCOLOR 0x00000040 #define DCPF_RULEROUTCOLOR 0x00000080 #define DCPF_ACTIVEBORDERCOLOR 0x00000100 #define DCPF_NONACTIVEBORDERCOLOR 0x00000200 #define DCPF_ACTIVESUBCELLBORDERCOLOR 0x00000400 #define DCPF_DEFAULTCURSOR 0x00000800 #define DCPF_VERTCURSOR 0x00001000 #define DCPF_HORZCURSOR 0x00002000 #define DCPF_BOTHCURSOR 0x00004000 #define DCPF_AUTOSCROLL 0x00008000 #define DCPF_CELLSMAINTENANCE 0x00010000 #define DCPF_SHOWFREEZETEXT 0x00020000 #define DCPF_BORDERSTYLE 0x00040000 #define DCPF_TEXTQUALITY 0x00080000 #define DCPF_RULERSTYLE 0x00100000 #define DCPF_RULERSTYLE_INVERT 0x00000000 #define DCPF_RULERSTYLE_BORDERED 0x00000001 #define DCPF_CELLSMAINTENANCE_SIZE 0x00000000 #define DCPF_CELLSMAINTENANCE_POS 0x00000001 #define DCACTION_ACTIVEONLY 0x00000000 #define DCACTION_SELECTED 0x00000001 #define DCACTION_ALLCELLS 0x00000002 #define DCACTION_REALTIME 0x00000000 #define DCACTION_ONRELEASE 0x00000010 enum DISPCONTAINER_MOUSEBUTTONS { CONTAINER_MOUSE_BUTTON_NONE, CONTAINER_MOUSE_BUTTON_LEFT, CONTAINER_MOUSE_BUTTON_RIGHT, CONTAINER_MOUSE_BUTTON_MIDDLE, CONTAINER_MOUSE_WHEEL, CONTAINER_MOUSE_BUTTON_XBUTTON1, //the first XButton CONTAINER_MOUSE_BUTTON_XBUTTON2, //the second XButton }; #define DCCELLPF_ALL 0x0000007F #define DCCELLPF_SHOWRULER 0x00000001 #define DCCELLPF_SHOWTAGS 0x00000002 #define DCCELLPF_ROWS 0x00000004 #define DCCELLPF_COLS 0x00000008 #define DCCELLPF_APPLYONMOVE 0x00000010 #define DCCELLPF_ALLOWINDIVIDUALWINDOWLEVEL 0x00000020 #define DCCELLPF_IMAGE_FIT 0x00000040 #define DCCELLPF_SHOWRULER_NONE 0x00000000 #define DCCELLPF_SHOWRULER_BOTH 0x00000001 #define DCCELLPF_SHOWRULER_VERT 0x00000002 #define DCCELLPF_SHOWRULER_HORZ 0x00000003 #define DCCELLPF_SHOWTAGS_SHOW 0x00000000 #define DCCELLPF_SHOWTAGS_HIDE 0x00000001 #define CONTAINER_MOUSEMOVE_UP 0x00000000 #define CONTAINER_MOUSEMOVE_DOWN 0x00000001 #define CONTAINER_MOUSEMOVE_LEFT 0x00000002 #define CONTAINER_MOUSEMOVE_RIGHT 0x00000003 #define CONTAINER_ACTION_CONTAINERLEVEL 0x00000000 #define CONTAINER_ACTION_CELLLEVEL 0x00000001 #define CONTAINER_KEY_SHIFT 0x00000001 #define CONTAINER_KEY_CTRL 0x00000002 #define CONTAINER_KEY_ALT 0x00000004 typedef L_INT (pEXT_CALLBACK DISPCONTAINERACTIONCALLBACK) (HBITMAPLIST L_FAR * phBitmapList, L_UINT uCount, L_INT nAction, L_UINT uMessage, L_UINT wParam, POINT L_FAR * ptMousePos, L_VOID L_FAR * pUserData); typedef L_INT (pEXT_CALLBACK DISPCONTAINERTAGCALLBACK) (L_INT nCellIndex, HDC hDC, RECT L_FAR * lpRect, L_VOID L_FAR * pUserData); /* External prototypes */ HDISPCONTAINER EXT_FUNCTION L_DispContainerCreate (HWND hWndParent, LPRECT lpRect, L_UINT uFlags); HDISPCONTAINER EXT_FUNCTION L_DispContainerGetHandle(HWND hConWnd); HWND EXT_FUNCTION L_DispContainerGetWindowHandle (HDISPCONTAINER hCon, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerDestroy (HDISPCONTAINER hCon, L_BOOL bCleanImages, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerSetProperties (HDISPCONTAINER hCon, pDISPCONTAINERPROPERTIES pDispContainerProp, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerGetProperties (HDISPCONTAINER hCon, pDISPCONTAINERPROPERTIES pDispContainerProp, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerInsertCell (HDISPCONTAINER hCon, L_INT nCellIndex, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerRemoveCell (HDISPCONTAINER hCon, L_INT nCellIndex, L_BOOL bCleanImage, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerGetCellCount (HDISPCONTAINER hCon, L_UINT uFlags); HWND EXT_FUNCTION L_DispContainerGetCellWindowHandle(HDISPCONTAINER hCon, L_INT nCellIndex, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerSetCellBitmapList(HDISPCONTAINER hCon, L_INT nCellIndex, HBITMAPLIST hBitmapList, L_BOOL bCleanImage, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerAddAction (HDISPCONTAINER hCon, L_INT nAction, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerSetAction (HDISPCONTAINER hCon, L_INT nAction, L_INT nMouseButton, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerSetCellTag (HDISPCONTAINER hCon, L_INT nCellIndex, L_UINT uRow, L_UINT uAlign, L_UINT uType, LPTSTR pString, L_UINT uFlags); L_VOID EXT_FUNCTION L_UseContainerControl (L_VOID); L_INT EXT_FUNCTION L_DispContainerSetCellProperties(HDISPCONTAINER hCon, L_INT nCellIndex, pDISPCELLPROPERTIES pCellProperties, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerGetCellProperties(HDISPCONTAINER hCon, L_INT nCellIndex, pDISPCELLPROPERTIES pCellProperties, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerGetCellPosition (HDISPCONTAINER hCon, L_INT nCellIndex, L_UINT L_FAR * puRow, L_UINT L_FAR * puCol, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerRepositionCell (HDISPCONTAINER hCon, L_INT nCellIndex, L_INT nTargetCellIndex, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerGetCellBitmapList(HDISPCONTAINER hCon, L_INT nCellIndex, pHBITMAPLIST phBitmapList, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerGetCellBounds (HDISPCONTAINER hCon, L_INT nCellIndex, LPRECT lpRect, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerFreezeCell (HDISPCONTAINER hCon, L_INT nCellIndex, L_BOOL bFreeze, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerSetFirstVisibleRow(HDISPCONTAINER hCon, L_UINT uRow, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerGetFirstVisibleRow(HDISPCONTAINER hCon, L_UINT L_FAR * uRow, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerSetActionProperties(HDISPCONTAINER hCon, L_INT nAction, L_INT nCellIndex, L_INT nSubCellIndex, LONG pActionProperties, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerGetActionProperties(HDISPCONTAINER hCon, L_INT nAction, L_INT nCellIndex, L_INT nSubCellIndex, LONG pActionProperties, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerRemoveAction (HDISPCONTAINER hCon, L_INT nAction, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerGetActionCount (HDISPCONTAINER hCon, L_INT L_FAR * nCount, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerSetKeyboardAction (HDISPCONTAINER hCon, L_INT nAction, L_INT nButton, L_UINT uKey, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerSetBounds (HDISPCONTAINER hCon, RECT L_FAR * lpRect, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerGetBounds (HDISPCONTAINER hCon, LPRECT lpRect, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerSelectCell (HDISPCONTAINER hCon, L_INT nCellIndex, L_BOOL bSelect, L_UINT uFlags); L_BOOL EXT_FUNCTION L_DispContainerIsCellSelected (HDISPCONTAINER hCon, L_INT nCellIndex, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerSetTagCallBack (HDISPCONTAINER hCon, DISPCONTAINERTAGCALLBACK pfnCallBack, L_VOID L_FAR * pUserData); L_INT EXT_FUNCTION L_DispContainerSetActionCallBack (HDISPCONTAINER hCon, DISPCONTAINERACTIONCALLBACK pfnCallBack, L_VOID L_FAR * pUserData); L_INT EXT_FUNCTION L_DispContainerGetTagCallBack (HDISPCONTAINER hCon, DISPCONTAINERTAGCALLBACK L_FAR * ppfnCallBack, LPVOID L_FAR * ppUserData); L_INT EXT_FUNCTION L_DispContainerGetActionCallBack (HDISPCONTAINER hCon, DISPCONTAINERACTIONCALLBACK L_FAR * ppfnCallBack, LPVOID L_FAR * ppUserData); L_BOOL EXT_FUNCTION L_DispContainerIsActionActive (HDISPCONTAINER hCon, L_INT nAction, L_UINT uFlags); L_INT EXT_FUNCTION L_DispContainerGetKeyboardAction (HDISPCONTAINER hCon, L_INT nAction, L_INT nMouseDirection, L_UINT L_FAR * puVk, L_UINT L_FAR * puModifiers, L_UINT uFlags); L_BOOL EXT_FUNCTION L_DispContainerIsCellFrozen (HDISPCONTAINER hCon, L_INT nCellIndex, L_UINT uFlags); #undef _HEADER_ENTRY_ #include "ltpck.h" #endif