home *** CD-ROM | disk | FTP | other *** search
Wrap
Attribute VB_Name = "modAPIGraphics" '================================= ' Date : 12/11/2001 '---------------------------------------------- ' Author : Eric O'Sullivan '---------------------------------------------- ' Contact : DiskJunky@hotmail.com '---------------------------------------------- ' Comments : 'This module was made for using api graphics functions in your 'programs. With the following api calls and function and procedures 'written by me, you have to tools to do almost anything. The only api 'function listed here that is not directly used by any piece of code 'in this module is BitBlt. You have the tools to create and manipulate 'graphics, but it is still necessary to display them manually. The 'functions themselves mostly need hDc or a handle to work. You can 'find this hDc in both a forms and pictureboxs' properties. I have 'also set up a data type called BitmapStruc. For my programs, I have 'used this structure almost exclusivly for the graphics. The structure 'holds all the information needed to reference a bitmap created using 'this module (CreateNewBitmap, DeleteBitmap). 'Please keep in mind that any object (bitmap, brush, pen etc) needs to 'be deleted after use or else it will stay in memory until the program is 'finished. Not doing so will eventually cause your program to take up 'ALL your computers recources. 'Also for anyone using optional paramters, it is probably better to use 'a default parameter values to determine whether or not a parameter 'has been passed than the function IsMissing(). ' 'Thank you, 'Eric '---------------------------------------------- '================================= Option Explicit Option Private Module '-------------------------------------------------------------------------- 'API calls '-------------------------------------------------------------------------- 'These functions are sorted alphabetically. 'This is used to copy bitmaps Public Declare Function BitBlt _ Lib "gdi32" _ (ByVal hDestDC As Long, _ ByVal X As Long, _ ByVal Y As Long, _ ByVal nWidth As Long, _ ByVal nHeight As Long, _ ByVal hSrcDC As Long, _ ByVal xSrc As Long, _ ByVal ySrc As Long, _ ByVal dwRop As Long) _ As Long 'used to change various windows settings Public Declare Function ChangeDisplaySettings _ Lib "user32" _ Alias "ChangeDisplaySettingsA" _ (ByRef wef As Any, _ ByVal i As Long) _ As Long 'creates a brush object which can be applied to a bitmap Public Declare Function CreateBrushIndirect _ Lib "gdi32" _ (lpLogBrush As LogBrush) _ As Long 'creates a colourspace object which can be applied to a bitmap Public Declare Function CreateColorSpace _ Lib "gdi32" _ Alias "CreateColorSpaceA" _ (lplogcolorspace As LogColorSpace) _ As Long 'the will create a bitmap compatable with the passed hDc Public Declare Function CreateCompatibleBitmap _ Lib "gdi32" _ (ByVal hDc As Long, _ ByVal nWidth As Long, _ ByVal nHeight As Long) _ As Long 'this create a compatable device context with the specified 'windows handle Public Declare Function CreateCompatibleDC _ Lib "gdi32" _ (ByVal hDc As Long) _ As Long 'creates an elliptical region in a hDc Public Declare Function CreateEllipticRgn _ Lib "gdi32" _ (ByVal X1 As Long, _ ByVal Y1 As Long, _ ByVal X2 As Long, _ ByVal Y2 As Long) _ As Long 'creates an elliptical region in a hDc Public Declare Function CreateEllipticRgnIndirect _ Lib "gdi32" _ (EllRect As Rect) _ As Long 'creates a font compatable with the specified device context Public Declare Function CreateFontIndirect _ Lib "gdi32" _ Alias "CreateFontIndirectA" _ (lpLogFont As LogFont) _ As Long 'creates a pen that can be applied to a hDc Public Declare Function CreatePen _ Lib "gdi32" _ (ByVal nPenStyle As Long, _ ByVal nWidth As Long, _ ByVal crColor As Long) _ As Long 'creates a pen that can be applied to a hDc Public Declare Function CreatePenIndirect _ Lib "gdi32" _ (lpLogPen As LogPen) _ As Long 'creates a rectangular region on a hDc Public Declare Function CreateRectRgn _ Lib "gdi32" _ (Left As Integer, _ Top As Integer, _ Right As Integer, _ Bottom As Integer) _ As Long 'creates a solid colour brush to be applied to 'a bitmap Public Declare Function CreateSolidBrush _ Lib "gdi32" _ (ColorRef As Long) _ As Long 'removes a device context from memory Public Declare Function DeleteDC _ Lib "gdi32" _ (ByVal hDc As Long) _ As Long 'removes an object such as a brush or bitmap from memory Public Declare Function DeleteObject _ Lib "gdi32" _ (ByVal hObject As Long) _ As Long 'this draws the animated minimize/maximize rectangeles Public Declare Function DrawAnimatedRects _ Lib "user32" _ (ByVal hWnd As Long, _ ByVal idAni As Long, _ lprcFrom As Rect, _ lprcTo As Rect) _ As Long 'this draws an icon onto a surphase (eg, a bitmap) Public Declare Function DrawIconEx _ Lib "user32" _ (ByVal hDc As Long, _ ByVal xLeft As Long, _ ByVal yTop As Long, _ ByVal hIcon As Long, _ ByVal cxWidth As Long, _ ByVal cyWidth As Long, _ ByVal istepIfAniCur As Long, _ ByVal hbrFlickerFreeDraw As Long, _ ByVal diFlags As Long) _ As Long 'this draws text onto the bitmap Public Declare Function DrawText _ Lib "user32" _ Alias "DrawTextA" _ (ByVal hDc As Long, _ ByVal lpStr As String, _ ByVal nCount As Long, _ lpRect As Rect, _ ByVal wFormat As Long) _ As Long 'this draws an ellipse onto the bitmap Public Declare Function Ellipse _ Lib "gdi32" _ (ByVal hDc As Long, _ X1 As Integer, _ Y1 As Integer, _ X2 As Integer, _ Y2 As Integer) _ As Boolean 'this will set the display settings Public Declare Function EnumDisplaySettings _ Lib "user32" _ Alias "EnumDisplaySettingsA" _ (ByVal A As Long, _ ByVal B As Long, _ wef As DEVMODE) _ As Boolean 'this provides more control than the CreatePen function Public Declare Function ExtCreatePen _ Lib "gdi32" _ (ByVal dwPenStyle As Long, _ ByVal dwWidth As Long, _ lplb As LogBrush, _ ByVal dwStyleCount As Long, _ lpStyle As Long) _ As Long 'this will fill the rectangle with the brush applied 'to the hDc Public Declare Function FillRect _ Lib "user32" _ (ByVal hWnd As Long, _ Fill As Rect, _ hBrush As Long) _ As Integer 'this will fill a region with the brush specified Public Declare Function FillRgn _ Lib "gdi32" _ (ByVal hDc As Long, _ ByVal HRgn As Long, _ hBrush As Long) _ As Boolean 'this will find a window based on its class and 'window name Public Declare Function FindWindow _ Lib "user32" _ Alias "FindWindowA" _ (ByVal lpClassName As String, _ ByVal lpWindowName As String) _ As Long 'this will return the handle of the top-most window Public Declare Function GetActiveWindow _ Lib "user32" _ () _ As Long 'this will get the state of any specified key - even 'the mouse buttons Public Declare Function GetAsyncKeyState _ Lib "user32" _ (ByVal vKey As Long) _ As Integer 'this will get the dimensions of the specified bitmap Public Declare Function GetBitmapDimensionEx _ Lib "gdi32" _ (ByVal hBitmap As Long, _ lpDimension As SizeType) _ As Long 'this will get the class name from the handle of the 'window specified Public Declare Function GetClassName _ Lib "user32" _ Alias "GetClassNameA" _ (ByVal hWnd As Long, _ ByVal lpClassName As String, _ ByVal nMaxCount As Long) _ As Long 'this will capture a screen shot of the specified 'area of the client Public Declare Function GetClientRect _ Lib "user32" _ (ByVal hWnd As Long, _ lpRect As Rect) _ As Long 'this gets the cursors icon picture Public Declare Function GetCursor _ Lib "user32" _ () _ As Long 'this gets the position of the cursor on the screen '(given in pixels) Public Declare Function GetCursorPos _ Lib "user32" _ (lpPoint As PointAPI) _ As Long 'gets a hDc of the specified window Public Declare Function GetDC _ Lib "user32" _ (ByVal hWnd As Long) _ As Long 'gets the entire screen area Public Declare Function GetDesktopWindow _ Lib "user32" _ () _ As Long 'this will get the current devices' capabilities Public Declare Function GetDeviceCaps _ Lib "gdi32" _ (ByVal hDc As Long, _ ByVal nIndex As Long) _ As Long 'get the last error to occur from within the api Public Declare Function GetLastError _ Lib "kernel32" _ () _ As Long 'get the handle of the menu bar on a window Private Declare Function GetMenu _ Lib "user32" _ (ByVal hWnd As Long) _ As Long 'Get the sub menu ID number. This is used to 'reference sub menus along with their handle Private Declare Function GetMenuItemID _ Lib "user32" _ (ByVal hMenu As Long, _ ByVal nPos As Long) _ As Long 'get information about the specified object such as 'its dimensions etc. Public Declare Function GetObjectAPI _ Lib "gdi32" _ Alias "GetObjectA" _ (ByVal hObject As Long, _ ByVal nCount As Long, _ lpObject As Any) _ As Long 'get the colour of the specified pixel Public Declare Function GetPixel _ Lib "gdi32" _ (ByVal hDc As Long, _ ByVal X As Long, _ ByVal Y As Long) _ As Long 'this will get the handle of a specified 'sub menu using the handle of the menu 'and the item ID Private Declare Function GetSubMenu _ Lib "user32" _ (ByVal hMenu As Long, _ ByVal nPos As Long) _ As Long 'get the dimensions of the applied text metrics for 'the device context Public Declare Function GetTextMetrics _ Lib "gdi32" _ Alias "GetTextMetricsA" _ (ByVal hDc As Long, _ lpMetrics As TEXTMETRIC) _ As Long 'returns the amount of time windows has been active for 'in milliseconds (sec/1000) Public Declare Function GetTickCount _ Lib "kernel32" _ () _ As Long 'very usefull timing function ;) 'retrieves the handle of a window that has the 'specified relationship to the specified window. Public Declare Function GetWindow _ Lib "user32" _ (ByVal hWnd As Long, _ ByVal wCmd As Long) _ As Long 'gets the area the specified window takes up Public Declare Function GetWindowRect _ Lib "user32" _ (ByVal hWnd As Long, _ lpRect As Rect) _ As Long 'increases the size of a rect structure Public Declare Function InflateRect _ Lib "user32" _ (lpRect As Rect, _ ByVal X As Long, _ ByVal Y As Long) _ As Long 'gets any intersection of two rectangles Public Declare Function IntersectRect _ Lib "user32" _ (lpDestRect As Rect, _ lpSrc1Rect As Rect, _ lpSrc2Rect As Rect) _ As Long 'draws a line from the current position to the 'specified co-ordinates Public Declare Function LineTo _ Lib "gdi32" _ (ByVal hDc As Long, _ XEnd As Integer, _ YEnd As Integer) _ As Boolean 'this will load a cursor into a device context Public Declare Function LoadCursor _ Lib "user32" _ Alias "LoadCursorA" _ (ByVal hInstance As Long, _ ByVal lpCursorName As Any) _ As Long 'this will load an image into a device context Public Declare Function LoadImage _ Lib "user32" _ Alias "LoadImageA" _ (ByVal hInst As Long, _ ByVal lpsz As String, _ ByVal un1 As Long, _ ByVal n1 As Long, _ ByVal n2 As Long, _ ByVal un2 As Long) _ As Long 'This stops the specified window from updating 'its display. This is mainly used to help cut out 'flicker but does not work on controls. Public Declare Function LockWindowUpdate _ Lib "user32" _ (ByVal hwndLock As Long) _ As Long 'changes some of a menu's properties Private Declare Function ModifyMenu _ Lib "user32" _ Alias "ModifyMenuA" _ (ByVal hMenu As Long, _ ByVal nPosition As Long, _ ByVal wFlags As Long, _ ByVal wIDNewItem As Long, _ ByVal lpString As Any) _ As Long 'moves the current position to the specified 'point Public Declare Function MoveToEx _ Lib "gdi32" _ (ByVal hDc As Long, _ X As Integer, _ Y As Integer, _ lpPoint As PointAPI) _ As Boolean 'multiplies two numbers and divides them by a third 'numbers Public Declare Function MulDiv _ Lib "kernel32" _ (ByVal nNumber As Long, _ ByVal nNumerator As Long, _ ByVal nDenominator As Long) _ As Long 'This will increase or decrease a rectangles 'co-ordinates by the specified amount. Usefull 'for moving graphic blocks as rect structures. Public Declare Function OffsetRect _ Lib "user32" _ (lpRect As Rect, _ ByVal X As Long, _ ByVal Y As Long) _ As Long 'Pattern Blitter. Used to draw a pattern onto 'a device context Public Declare Function PatBlt _ Lib "gdi32" _ (ByVal hDc As Long, _ ByVal X As Long, _ ByVal Y As Long, _ ByVal nWidth As Long, _ ByVal nHeight As Long, _ ByVal dwRop As Long) _ As Long 'This draws a polygon onto a device context 'useing an array. Public Declare Function Polygon _ Lib "gdi32" _ (ByVal hDc As Long, _ lpPoint As PointAPI, _ ByVal nCount As Long) _ As Long 'This will draw a set of lines to the specifed 'points Public Declare Function Polyline _ Lib "gdi32" _ (ByVal hDc As Long, _ lpPoint As PointAPI, _ ByVal nCount As Long) _ As Long 'This will draw a set of lines starting from 'the current position on the device context. Public Declare Function PolylineTo _ Lib "gdi32" _ (ByVal hDc As Long, _ lppt As PointAPI, _ ByVal cCount As Long) _ As Long 'This draws a rectangle onto the device 'context Public Declare Function Rectangle _ Lib "gdi32" _ (ByVal hWnd As Long, _ X1 As Integer, _ Y1 As Integer, _ X2 As Integer, _ Y2 As Integer) _ As Long 'This will release a device context from 'memory. Not to be confused with DeleteDC Public Declare Function ReleaseDC _ Lib "user32" _ (ByVal hWnd As Long, _ ByVal hDc As Long) _ As Long 'this will draw a round-cornered rectangle 'onto the specified device context Public Declare Function RoundRect _ Lib "gdi32" _ (ByVal hDc As Long, _ ByVal Left As Long, _ ByVal Top As Long, _ ByVal Right As Long, _ ByVal Bottom As Long, _ ByVal X3 As Long, _ ByVal Y3 As Long) _ As Long 'this will select the specified object to 'a window or device context Public Declare Function SelectObject _ Lib "gdi32" _ (ByVal hDc As Long, _ ByVal hObject As Long) _ As Long 'This sets the background colour on a bitmap Public Declare Function SetBkColor _ Lib "gdi32" _ (ByVal hDc As Long, _ ByVal crColor As Long) _ As Long 'This sets the background mode on a bitmap '(eg, transparent, solid etc) Public Declare Function SetBkMode _ Lib "gdi32" _ (ByVal hDc As Long, _ ByVal nBkMode As Long) _ As Long 'The color adjustment values are used to adjust 'the input color of the source bitmap for calls 'to the StretchBlt and StretchDIBits functions 'when HALFTONE mode is set. Public Declare Function SetColorAdjustment _ Lib "gdi32" _ (ByVal hDc As Long, _ lpca As COLORADJUSTMENT) _ As Long 'sets the colourspace to a device context Public Declare Function SetColorSpace _ Lib "gdi32" _ (ByVal hDc As Long, _ ByVal hcolorspace As Long) _ As Long 'sets the bitmap of a menu Private Declare Function SetMenuItemBitmaps _ Lib "user32" _ (ByVal hMenu As Long, _ ByVal nPosition As Long, _ ByVal wFlags As Long, _ ByVal hBitmapUnchecked As Long, _ ByVal hBitmapChecked As Long) _ As Long 'sets the current information about the selected menu Private Declare Function SetMenuItemInfo _ Lib "user32" _ Alias "SetMenuItemInfoA" _ (ByVal hMenu As Long, _ ByVal uItem As Long, _ ByVal fByPosition As Long, _ lpmii As MENUITEMINFO) _ As Long 'sets the colour of the specified pixel Public Declare Function SetPixel _ Lib "gdi32" _ (ByVal hDc As Long, _ ByVal X As Long, _ ByVal Y As Long, _ ByVal crColor As Long) _ As Long 'sets the rectangles size and position Public Declare Function SetRect _ Lib "user32" _ (lpRect As Rect, _ ByVal X1 As Long, _ ByVal Y1 As Long, _ ByVal X2 As Long, _ ByVal Y2 As Long) _ As Long 'sets the current text colour Public Declare Function SetTextColor _ Lib "gdi32" _ (ByVal hDc As Long, _ ByVal crColor As Long) _ As Long 'pauses the execution of the programs thread 'for a specified amount of milliseconds Public Declare Sub Sleep _ Lib "kernel32" _ (ByVal dwMilliseconds As Long) 'used to stretch or shrink a bitmap Public Declare Function StretchBlt _ Lib "gdi32" _ (ByVal hDc As Long, _ ByVal X As Long, _ ByVal Y As Long, _ ByVal nWidth As Long, _ ByVal nHeight As Long, _ ByVal hSrcDC As Long, _ ByVal xSrc As Long, _ ByVal ySrc As Long, _ ByVal nSrcWidth As Long, _ ByVal nSrcHeight As Long, _ ByVal dwRop As Long) _ As Long '-------------------------------------------------------------------------- 'enumerator section '-------------------------------------------------------------------------- 'the direction of the gradient Public Enum GradientTo GradHorizontal = 0 GradVertical = 1 End Enum 'in twips or pixels Public Enum Scaling InTwips = 0 InPixels = 1 End Enum 'The key values of the mouse buttons Public Enum MouseKeys MouseLeft = 1 MouseRight = 2 MouseMiddle = 4 End Enum 'text alignment constants Public Enum AlignText vbLeftAlign = 1 vbCentreAlign = 2 vbRightAlign = 3 End Enum 'bitmap flip constants Public Enum FlipType FlipHorizontally = 0 FlipVertically = 1 End Enum 'image load constants Public Enum LoadType IMAGE_BITMAP& = 0 End Enum 'rotate bitmap constants Public Enum RotateType RotateRight = 0 RotateLeft = 1 Rotate180 = 2 End Enum '-------------------------------------------------------------------------- 'Programmer defined data types '-------------------------------------------------------------------------- 'Bitmap structue for menu information Private Type MENUITEMINFO cbSize As Long fMask As Long fType As Long fState As Long wID As Long hSubMenu As Long hbmpChecked As Long hbmpUnchecked As Long dwItemData As Long dwTypeData As String cch As Long End Type 'size structure Public Type SizeType cx As Long cy As Long End Type 'Text metrics Public Type TEXTMETRIC tmHeight As Long tmAscent As Long tmDescent As Long tmInternalLeading As Long tmExternalLeading As Long tmAveCharWidth As Long tmMaxCharWidth As Long tmWeight As Long tmOverhang As Long tmDigitizedAspectX As Long tmDigitizedAspectY As Long tmFirstChar As Byte tmLastChar As Byte tmDefaultChar As Byte tmBreakChar As Byte tmItalic As Byte tmUnderlined As Byte tmStruckOut As Byte tmPitchAndFamily As Byte tmCharSet As Byte End Type Public Type COLORADJUSTMENT caSize As Integer caFlags As Integer caIlluminantIndex As Integer caRedGamma As Integer caGreenGamma As Integer caBlueGamma As Integer caReferenceBlack As Integer caReferenceWhite As Integer caContrast As Integer caBrightness As Integer caColorfulness As Integer caRedGreenTint As Integer End Type Public Type CIEXYZ ciexyzX As Long ciexyzY As Long ciexyzZ As Long End Type Public Type CIEXYZTRIPLE ciexyzRed As CIEXYZ ciexyzGreen As CIEXYZ ciexyBlue As CIEXYZ End Type Public Type LogColorSpace lcsSignature As Long lcsVersion As Long lcsSize As Long lcsCSType As Long lcsIntent As Long lcsEndPoints As CIEXYZTRIPLE lcsGammaRed As Long lcsGammaGreen As Long lcsGammaBlue As Long lcsFileName As String * 26 'MAX_PATH End Type 'display settings (800x600 etc) Public Type DEVMODE dmDeviceName As String * 32 dmSpecVersion As Integer dmDriverVersion As Integer dmSize As Integer dmDriverExtra As Integer dmFields As Long dmOrientation As Integer dmPaperSize As Integer dmPaperLength As Integer dmPaperWidth As Integer dmScale As Integer dmCopies As Integer dmDefaultSource As Integer dmPrintQuality As Integer dmColor As Integer dmDuplex As Integer dmYResolution As Integer dmTTOption As Integer dmCollate As Integer dmFormName As String * 32 dmUnusedPadding As Integer dmBitsPerPel As Long dmPelsWidth As Long dmPelsHeight As Long dmDisplayFlags As Long dmDisplayFrequency As Long End Type Public Type Rect Left As Long Top As Long Right As Long Bottom As Long End Type Public Type BitmapStruc hDcMemory As Long hDcBitmap As Long hDcPointer As Long Area As Rect End Type Public Type PointAPI X As Long Y As Long End Type Public Type LogPen lopnStyle As Long lopnWidth As PointAPI lopnColor As Long End Type Public Type LogBrush lbStyle As Long lbColor As Long lbHatch As Long End Type Public Type FontStruc Name As String Alignment As AlignText Bold As Boolean Italic As Boolean Underline As Boolean StrikeThru As Boolean PointSize As Byte Colour As Long End Type Public Type LogFont 'for the DrawText api call lfHeight As Long lfWidth As Long lfEscapement As Long lfOrientation As Long lfWeight As Long lfItalic As Byte lfUnderline As Byte lfStrikeOut As Byte lfCharSet As Byte lfOutPrecision As Byte lfClipPrecision As Byte lfQuality As Byte lfPitchAndFamily As Byte lfFaceName(1 To 32) As Byte End Type Public Type Point 'you'll need this to reference a point on the 'screen' X As Integer Y As Integer End Type 'To hold the RGB value Public Type RGBVal Red As Single Green As Single Blue As Single End Type 'bitmap structure for the GetObject api call Public Type BITMAP '14 bytes bmType As Long bmWidth As Long bmHeight As Long bmWidthBytes As Long bmPlanes As Integer bmBitsPixel As Integer bmBits As Long End Type '-------------------------------------------------------------------------- 'Constants section '-------------------------------------------------------------------------- 'general constants Public Const GW_CHILD = 5 Public Const GW_HWNDFIRST = 0 Public Const GW_HWNDLAST = 1 Public Const GW_HWNDNEXT = 2 Public Const GW_HWNDPREV = 3 Public Const GWL_WNDPROC = (-4) Public Const IDANI_OPEN = &H1 Public Const IDANI_CLOSE = &H2 Public Const IDANI_CAPTION = &H3 Public Const WM_USER = &H400 'Image load constants Public Const LR_LOADFROMFILE As Long = &H10 Public Const LR_CREATEDIBSECTION As Long = &H2000 Public Const LR_DEFAULTSIZE As Long = &H40 'PatBlt constants Public Const PATCOPY = &HF00021 ' (DWORD) dest = pattern Public Const PATINVERT = &H5A0049 ' (DWORD) dest = pattern XOR dest Public Const PATPAINT = &HFB0A09 ' (DWORD) dest = DPSnoo Public Const DSTINVERT = &H550009 ' (DWORD) dest = (NOT dest) Public Const BLACKNESS = &H42 ' (DWORD) dest = BLACK Public Const WHITENESS = &HFF0062 ' (DWORD) dest = WHITE 'Display constants Public Const CDS_FULLSCREEN = 4 Public Const DM_BITSPERPEL = &H40000 Public Const DM_PELSWIDTH = &H80000 Public Const DM_PELSHEIGHT = &H100000 Public Const DM_DISPLAYFLAGS = &H200000 Public Const DM_DISPLAYFREQUENCY = &H400000 'DrawText constants Public Const DT_CENTER = &H1 Public Const DT_BOTTOM = &H8 Public Const DT_CALCRECT = &H400 Public Const DT_EXPANDTABS = &H40 Public Const DT_EXTERNALLEADING = &H200 Public Const DT_LEFT = &H0 Public Const DT_NOCLIP = &H100 Public Const DT_NOPREFIX = &H800 Public Const DT_RIGHT = &H2 Public Const DT_SINGLELINE = &H20 Public Const DT_TABSTOP = &H80 Public Const DT_TOP = &H0 Public Const DT_VCENTER = &H4 Public Const DT_WORDBREAK = &H10 Public Const TRANSPARENT = 1 Public Const OPAQUE = 2 'CreateBrushIndirect constants Public Const BS_DIBPATTERN = 5 Public Const BS_DIBPATTERN8X8 = 8 Public Const BS_DIBPATTERNPT = 6 Public Const BS_HATCHED = 2 Public Const BS_HOLLOW = 1 Public Const BS_NULL = 1 Public Const BS_PATTERN = 3 Public Const BS_PATTERN8X8 = 7 Public Const BS_SOLID = 0 Public Const HS_BDIAGONAL = 3 ' ///// Public Const HS_CROSS = 4 ' +++++ Public Const HS_DIAGCROSS = 5 ' xxxxx Public Const HS_FDIAGONAL = 2 ' \\\\\ Public Const HS_HORIZONTAL = 0 ' ----- Public Const HS_NOSHADE = 17 Public Const HS_SOLID = 8 Public Const HS_SOLIDBKCLR = 23 Public Const HS_SOLIDCLR = 19 Public Const HS_VERTICAL = 1 ' ||||| 'BitBlt constants Public Const SRCAND = &H8800C6 ' (DWORD) dest = source AND dest Public Const SRCCOPY = &HCC0020 ' (DWORD) dest = source Public Const SRCERASE = &H440328 ' (DWORD) dest = source AND (NOT dest ) Public Const SRCINVERT = &H660046 ' (DWORD) dest = source XOR dest Public Const SRCPAINT = &HEE0086 ' (DWORD) dest = source OR dest Public Const MERGECOPY = &HC000CA ' (DWORD) dest = (source AND pattern) Public Const MERGEPAINT = &HBB0226 ' (DWORD) dest = (NOT source) OR dest Public Const NOTSRCCOPY = &H330008 ' (DWORD) dest = (NOT source) Public Const NOTSRCERASE = &H1100A6 ' (DWORD) dest = (NOT src) AND (NOT dest) 'LogFont constants Public Const LF_FACESIZE = 32 Public Const FW_BOLD = 700 Public Const FW_DONTCARE = 0 Public Const FW_EXTRABOLD = 800 Public Const FW_EXTRALIGHT = 200 Public Const FW_HEAVY = 900 Public Const FW_LIGHT = 300 Public Const FW_MEDIUM = 500 Public Const FW_NORMAL = 400 Public Const FW_SEMIBOLD = 600 Public Const FW_THIN = 100 Public Const DEFAULT_CHARSET = 1 Public Const OUT_CHARACTER_PRECIS = 2 Public Const OUT_DEFAULT_PRECIS = 0 Public Const OUT_DEVICE_PRECIS = 5 Public Const OUT_OUTLINE_PRECIS = 8 Public Const OUT_RASTER_PRECIS = 6 Public Const OUT_STRING_PRECIS = 1 Public Const OUT_STROKE_PRECIS = 3 Public Const OUT_TT_ONLY_PRECIS = 7 Public Const OUT_TT_PRECIS = 4 Public Const CLIP_CHARACTER_PRECIS = 1 Public Const CLIP_DEFAULT_PRECIS = 0 Public Const CLIP_EMBEDDED = 128 Public Const CLIP_LH_ANGLES = 16 Public Const CLIP_MASK = &HF Public Const CLIP_STROKE_PRECIS = 2 Public Const CLIP_TT_ALWAYS = 32 Public Const WM_SETFONT = &H30 Public Const LF_FULLFACESIZE = 64 Public Const DEFAULT_PITCH = 0 Public Const DEFAULT_QUALITY = 0 Public Const PROOF_QUALITY = 2 'GetDeviceCaps constants Public Const LOGPIXELSY = 90 ' Logical pixels/inch in Y 'colourspace constants Public Const MAX_PATH = 260 'pen constants Public Const PS_COSMETIC = &H0 Public Const PS_DASH = 1 ' ------- Public Const PS_DASHDOT = 3 ' _._._._ Public Const PS_DASHDOTDOT = 4 ' _.._.._ Public Const PS_DOT = 2 ' ....... Public Const PS_ENDCAP_ROUND = &H0 Public Const PS_ENDCAP_SQUARE = &H100 Public Const PS_ENDCAP_FLAT = &H200 Public Const PS_GEOMETRIC = &H10000 Public Const PS_INSIDEFRAME = 6 Public Const PS_JOIN_BEVEL = &H1000 Public Const PS_JOIN_MITER = &H2000 Public Const PS_JOIN_ROUND = &H0 Public Const PS_SOLID = 0 'mouse cursor constants Public Const IDC_APPSTARTING = 32650& Public Const IDC_ARROW = 32512& Public Const IDC_CROSS = 32515& Public Const IDC_IBEAM = 32513& Public Const IDC_ICON = 32641& Public Const IDC_NO = 32648& Public Const IDC_SIZE = 32640& Public Const IDC_SIZEALL = 32646& Public Const IDC_SIZENESW = 32643& Public Const IDC_SIZENS = 32645& Public Const IDC_SIZENWSE = 32642& Public Const IDC_SIZEWE = 32644& Public Const IDC_UPARROW = 32516& Public Const IDC_WAIT = 32514& 'menu constants Private Const MFT_RADIOCHECK = &H200& Private Const MF_BITMAP = &H4& Private Const MIIM_TYPE = &H10 Private Const MIIM_SUBMENU = &H4 'some key values for GetASyncKeyState Public Const KLeft = 37 Public Const KUp = 38 Public Const KRight = 39 Public Const KDown = 40 'some mathimatical constants Public Const Pi = 3.14159265358979 '-------------------------------------------------------------------------- 'Variable declarations section '-------------------------------------------------------------------------- 'This stores the various points of a polygon. Use DrawPoly to draw 'the polygon with the points specified in the array. 'Also see AddToPoly, ClearPoly and DelFromPoly Private PolygonPoints() As PointAPI 'some general variables used by some api calls Private rctFrom As Rect Private rctTo As Rect Private lngTrayHand As Long Private lngStartMenuHand As Long Private lngChildHand As Long Private strClass As String * 255 Private lngClassNameLen As Long Private lngRetVal As Long Private blnResChanged As Boolean '-------------------------------------------------------------------------- 'Procedures/functions section '-------------------------------------------------------------------------- Public Sub BFAlphaBlend(ByVal lngDesthDc As Long, _ ByVal lngPic1hDc As Long, _ ByVal lngPic2hDc As Long, _ ByVal intDestX As Integer, _ ByVal intDestY As Integer, _ ByVal intWidth As Integer, _ ByVal intHeight As Integer, _ ByVal lngPic1X As Integer, _ ByVal lngPic1Y As Integer, _ ByVal lngPic2X As Integer, _ ByVal lngPic2Y As Integer, _ Optional ByVal sngBlendAmount As Single = 0.5, _ Optional ByVal lngMaskhDc As Long = 0, _ Optional ByVal intMeasurement As Scaling = InPixels) 'This is a "brute force" alpha blend function. Because it's written in 'vb, this function is not as fast at it might otherwise be in another 'language like C++ or Fox. 'The purpose of the function is to mix the colours of two bitmaps to 'produce a result that looks like both pictures. Think of it as fading 'one picture into another. I get the pixel colour of a point in picture1, 'and the colour of the corresponding pixel in pixture2, find the 'middle' 'colour and put it into the destination bitmap. There are no calls to 'other procedures or functions other than api calls. This is to improve 'speed as all calculations are made internally. 'The parameter sngBlendAmount MUST be between 1 and 0. If not then 'the value is rounded to 1 or zero. 'However, sngBlendAmount is ignored if a Mask bitmap has been specified. 'Please note that if the mask used only contains black or white pixels, 'then it is recommended that you use the MergeBitmaps procedure as 'it will process the bitmaps much faster (by about 15 to 30 times). 'Keep in mind that using a mask bitmap is about 25% slower than 'specifying the blend amount. Dim TempBmp As BitmapStruc 'a temperory bitmap Dim lngResult As Long 'any result returned from an api call Dim Col1 As RGBVal 'used to store a pixel colour in RGB format Dim Col2 As RGBVal 'used to store a pixel colour in RGB format Dim BlendCol As RGBVal 'used to store a pixel colour in RGB format Dim MaskCol As RGBVal 'used to store a pixel colour in RGB format Dim lngCounterX As Long 'scan the rows of the bitmap Dim lngCounterY As Long 'scan the columns of the bitmap Dim intPxlHeight As Integer 'the pixel height in twips Dim intPxlWidth As Integer 'the pixel width in twips Dim lngBlendCol As Long 'the blended colour calculated from the two pixel colours of the bitmaps Dim lngCol1 As Long ad 'scan the rows of the bitmap Dim lngCounterY APELSHS Lean the rows of the bitmapthe mask usen is recomlpask usen =ly.5, _mATd _ e' abouapthe mask use recoNaW0dSo store a pixel colour in RGB form2.5, _mATd _ ByVal nCount As6s String, _ Byst CLIP_CHARAg, _ ByVal uItem As ---krsorPos _ Lib "user32" _ (llso see AddToPoli uItem As ---krsorPos _ Lib "user3a. As ---krs_CHARAg, _ Atem As -Rb Atem As -Rb Atem As -Rb As Long, _ sddle' 'will Y pEol As Long 'the blended colour calb TtringbuItemBitmaps _ ll Y 3sle' 'used to ByVal uItem As ---krsorPos _ in RGB at Dim BlendCol rivate b lf ---krs_CHARA Alias "Fin lfI ByVal dwRop As Long) is about 25% slower than 'specifying the blend amount. Dim TempBmp As BitmapStruc 'a temperory bitmap Dim lngResult As Long 'any result returned from an api call Dim Col1As Long 'scan the rvn RGB formC _ ouapthe maee AdByVal lngPifrom a rect structure Publict As 'wilARA Alias "Fin lfI ByVal d Lib "userucs Lib "user 'usByVal dwRop urnedsg1ogFont constants Public ConstsConsre Sub Sleep _ Lib "kernel32" _ rm2.5, _mATdORD) dest = (NOT sourceltmap. TherDWORD) dest = (n is recomlpask usen =ly.5, _mATd _ e' abouapthe m Lib "user/_mATd _ e' abouapthe m Lib (NOTp(onst FW_MEDIUM = 500 Public Const FW_NORMAL comlpask useants PublicA------- 'Variable declarations section '---2F+ixe ------ 'Variabpns secEns 'scnding pix Public Dt IDC_SIZEWE = 3OTp(onst FB2" _ W56 Dcolours inding pi=nublicp 'scndinl As Long 'the blended colour calc Public Const DT_Co1 As RGBVal 'used to snhin Val uItem Aed As Public Const FW_NORMALs AcngResult _ trClass As Strin(nst FB2" _ W56 Dcolours inding ic Const IDANI_CLOSE = &H2 PubP = &HbME = 3OTp(onst FB2" _ W56 Dcolou=Pu2s fading 'onPrPublic Const Pi = 3.14159265colours inding inic C5colours inding inic C5colours .-----------Tc C5colours inding iBTf ByVau ID _ As Long 'this will retS_PATT FW_Ns class and 'window name Public Dnic C5colours inding A---------- 'Bitmap structW_NsestTAL comlT----polours indpStruc ours store is about 25-----------5colouris o= &H'wilARA Alinst PS_----5colouris o= &H'wilARA Alinst PS_----5colouris o= &H'wilARA Al 'tplT-- IDANI_OP = 32641& 'tplT-- IDANI_OP = 32641& 'tplT- usen =ly.5, _mATd _ e' abouapth=nAlt that lookSByVal is o= &H--------------------------------------T' abouapth=nAlt y5 h' abouaXem As -Rb As Long, _ sddle' roundecomlpask usen =l (ByVal hDc e)UndeY" _ As -Rb As Long, _ sddLong, _ " _ W56 Dcolours inding pi=nublicver, sngBlendAmount lic Declare Function GetTextMetrics _ Lib "gng End Type '------------------------------------------------------licvenile' -----------------ElipV4---aTteger, _ ----T_TABSTOPolour in RGB formasee AddToPoli uItem AE = &H100 0e5colours .----------usByVal dSTOPolour in RGB formasee AddToPoli uItem E*ill a region_ ouapthe maee AdByVal lngPilARA Al ger M = 500 Pu caIlluminantIndex As IntegeA AlluminantIndral lpClassNAs -Rb CN(NOTp(onst FW_MEsassNA ByVal uItem As ---krso FW_NsNA ByVal uItem As ---krso FW_NsNA Val----2yVal uIByVal n2 A---krso FW_NsNA yVa ByVal intMeasurement As Scaling = InW_NsNA yVa Ber, s 'usemen unt As6s ----------a reavsurement As Scali inding inic C5coltIndral lpClassNAs urs As 'wilARA Alias "Fin ral lpClassNAs urs As 'wilARA Alias uItem As ---u0= ( As St"Fin IDANI_OP = 326" _ wd DiXOP = 326" _ wd DiXOP = m BlendCNA yV 326" _ r and put it into the destination bitmap. There are no calls to 'other procedures or functions other than api calls. This is to improve 'speed as all calculations are made internally. 'The parameter sngBlendAm=Ih---usByVal om the current -ons are made wmhhUr ID ---------s Long 'this will retS_PATT FW_Ns cla0 ightness---s Long sill increase or decrease a rectangles 'co-W_Ns cla0 5pa MU decrease a r wd DiXOP = m Bw 5pa MU decrease a r(decRb Atem As -Rb Atem As - A--lations acRb Atem As -Rb Atem As - s c00 0e5colo As -Rb er, tTextMetrics _ Lib "gng End Type '-------cs _ Lib c Type Point or decrease a rectangles 'co-W_Ns cla0 5pEPubP --s LonB/avmap R Ah RSET = 1 Public Const OUT_CHARACTER_PRECISnt or dectTextMeT = 1 aw a set of lines starting from 'the current poii Const DT_RIGHT = &H2 Public Cons.+ic Conslic Cns othb Alias "Fin ral lpCs RectYi=nublthan h(Dcolours Atem h(Dcolours Atem h(Dcolours Atem h h(Dcoloua&H2 Pubp to improve Ls or functions other than api calls. Tlours s --T_TAB1esbFAULT_PRECIS = 0 Public Const OUT_DEVICE_PRECIS = 5 Public ConstsDim MaskCol As RGBVal ot OUT_DEVICE_=KDxel AoA_TABST ' gevice,s to ong) MU Long eher LF_NA ByVal uItem As --3 lfI ByVal dwRop As Long) is about 2= 32r LF_NAdwRop" _oEnd Type '-------------------ic Const OUT_CHARACTER_PRECISr'ong) is "kerIbng eher LF_NA ByVal uIttCc-----ic Const BST 'onnst FW_ME/ to ByVal uItem As ---krsorPos 2rsorPos 5u5 .M:ePos 2rsorPos made wmhhUr IDEpClassNA inding UITEMINFO) _ ma rsor on the 0anst OUT_TT_PRECIS = 4 Public Const CLIP_C_Ns cls)a_PRECIS = 0RIGHT U gevice,s to0vice,s to0vice,song 'scan the columns of the bitmap Dim intPxlHeig ByVal hObject As Long) _ ng ntllso see Const Type B(uare Fun Lib im TempBmp As Bim ByVal lngPic2Y AmpBmp A_As Bim I-usByVQ 3Eice,song Heig i 'thiss RGBVal 'used to store a pixel S2eallPblic Const l hObject As t PS4 (By1 _ he MergeBitmaps proc As t As Long) c (By1 _ he)DBMp--s Long sill increase or decrease a rectangleoc1RectsItem As ---krsEnd Type Public Type LogPen lopnStyle As Long lopnWidth As PointAPI lopnColor A ps Long) c Crsecalues of yVal lopnColor A ps Long) c Crsecalues of yVal lopnColor A psSrove onsre Sub Sleep _ Lib31T'NFO) e 'specified co-ordinates Public Declare Function Li ms -Rb _NAdwRop"0 As Long, _ 0NI_OP = 3api calpbW_Ne lopHT = &H2 Pution Li ms lor A pDPRECISnt or dect lopnColoblended colourn_Ne lopHT = -aTteger, _ IDEpClassNA indinEonsre Sub&H100 Public Const DTtmapStruc (g from 'theout 2ud_ sddo ByVal lngPi2Li Sub Sleep _ uIte( Const Pi = 3>=Sub S1n = 1 Public CoEXT = Scalues -W_Ns cla0 5pEPubPariable deoc Const HS_SOLI=e deoce) ByVEas -Rb ihsndAmount lic c10 Private Const MIIM_SUBMENU = &H4 Const MIIM_SUBMENU = &H4 dc Crsecalues of yVal lo ByVal ln yVal lo B 'used to store a pixel Sohis is to imprY ' gm5wi Pution Li ms lo+C0Pt MIIM_SUBMENU = &o draw 'thea As LonAbjecpollkM_DISP) c Crseca yValg:DAs LonAs 'wist HS_SOac As t As = &H Type uIValg:DAscpe uIValg:DAscpe uIVd) As = &Hirs ilues of yVal lopnColor A psSrovblic Const l hObjpRect As Rect, _ ByVal X As Long, tem As -ction StonAbjecpollblic Type LogPen lopnStyle bjecpollblic Typc Type Logblic pnStyle bjecpollblic Typc Type L'and the cgblic pnStyle bipSrc1Rect A As Long PrivatStyle bjecpi call uFSonst DTtmapStruc (g from 'thebipSrc1Rect A As Long PrivatStylipSrc1Rect A As Long Pricolour calc Pu uItem As nublicvepecified co-ordd) AsmOurrent infor.GD ByVal X As Long, This is to ted amsf line bipSrc1Rect A As Long PrivatStyle bjecpi cal uFSo Pubded colour ISP) c Crsece bjecpi cal uFSo Pubded colour ISP) c Crse2( Public Cond AmpBmp A_Awg Pricolour calc Pu uItem As nub ByVal X As Long, tem As Valic Const DT_ yVal u(-krsEnd Type ByVal lngPi2Li rPos _ in R(hTs of yVal lVal a1 lfI gblic pnStylwXYZn' LFTONE mode 1 u(-krsEnd Type ByVal ln9ByVal X Ac pnStylwXYZn' LFTyVal /eabpnAmount lic c10 0 ByVa2( Public Cond AmpBmp A_Awg PricNFTyValb ByVa2( Public Cond AmpBmpA_Awg Pricolour calc Pu uItem As nub. Pu uItem As nugalc Pu uItebpoii g inic C5coltIndral lpClalc mode 1 s X As Integee,song Heig i 'thiss RGBVal AsNAns X As In= 1 s Sohis is to imprY ' gm5wi PutpnAmount lic Typc Type L'anduopRAs PointAPIvs allLhem As -c MIIM2 1 a uItem TypemapStruc (g frste lfChe 1ce XOR dest Public Const SRCPAINT = &HES lfintA frste prY 2Lib " ,song Heig i 'thiss RGBVal AsNAns X As In= 1 s Sohis is to imprY ' gm5wi PutpnAmount lic Typc Type L'an HTABST o Long) c Cr=ets Putpnlic Const PS_DOT = yVal ln9ByVal X Ac pnSnA frse.d3rc1Rect A AL about 25% slower than d c TypemaabjecuI Dim Public (s St"d0 BitmapStruc 'a temperory bitmap Dim lngResult Auc 'a temperory bitmap Dim lngResult* X Ac pnSnA,s to ong) MU Long eher LF_NA ByVal uItem As --3 T ByVal lpCAs 'wste prY 2Lib " ,stem At A AL bitmap ainates,stem At mcpe uIValg:dest-krso FW_NsN eher LF_NAcAt mcpe uIVaem As ---krsorP 'wW cal uFSetyle b PrivatStyle bjecpi call uFSonst DTtmapStrucutpnAmount lic TypAmount_CHARA Aliasap AF(di call uFSonst DTt TypAmount_CHARA Aliasap AF(di ca w nub ByV) Li _ aDim lnt_CHARA _CHARACTER_PRECISr'oomItem At A AL bitmapap ' gm5wi Long 'The color adjustment values are used to adjustaByVal uIttCc-----t values a2b0ues are used to adjusteb-----t values a2b0--t values ab " t5ng ic Cons-t valXz lfI gblic pnStylwX=steb-- calls to Cons gblic pnStylwX=ster t Q=steb-- calunt * Atem h(Dcolours TDPRECISnt or dect Lea As LonAbt or dect Lea Sr'apStruc ubded colour ISP) c ByVal pe Publi8X Ac pnStylw ISByVal pe Publi8X Ac pnStylw ISByVDim lngResult* X Ac pnSnA,s g * X A As n)nAs LonAbt or dect Lea Sr'apStruc ubdeyM*sdP --s Lo call taADcolours TDPRECISnt or oundRect _ Lib "gdi32 AsE ST o colour Io adjusAtem As -Rb y Private lngTrayHs -RHirs galc Pu ublic Cond Ao)ByVal uItAs Aste Public C Const IDANI_CAPTION = &H.rlassNA indi (ByVal hDc As Long, _ lly. 'The parameter sngBlendAmodgBlendAmodgdAbt or dect Lea Sr'apSfhBlt and StretchDIBits functions 'wOW = 1 Publ(lt y5 to re-t MmYHARA _CHA Aon RGB form2.5, _m>F( Aste Publ6 LonAbt (DWCh Lib imi Long 'T32hold ap dol1 As Long 9 aste Pubi3sAs -cinStyle bipa(DWCh ic c10dect Lea Sr'apStruc ubdeyM*sdP --s Lo call taADWCh ic c10dPTION6ARA apSACTER_PRECHapSACTEp_ tyle bipa(DWCh ic c dPTION6ARA ap dol1 As LongfaSTt Lea Sosult As Long 'any reDWCh ic.mpBmpype Roto( tmBreeyM*sdP --s Lo f are made internc C Const IDANI_CAPTIfSo PugTlngChildHand As Long Private strClass As Strinib " ,stem At A AL bitmap ainates,sS made aMlic Type Loal intDestY Asen lT ic.mpBm(Dcolwcall t'calun.w Asen lT ic.mpBm(Dcolwcall t'calun.w Asen lT - stem At A AL bitmap ainates,sS made aMlic Ty=iteBitmaps proc As t As Long) c (By1 _ de aMlic Ty=s So As t ACc--.mpB Dim intPxlWndAmount 9tmItalic As Byte Pri(---- 'Variabpns secEns om rPos _ g PrR a2b0ues aoal(lt yl a2b Name As String PubPariable As nnnnnnnnnnnnnnn _ hc Co DAs Lf Dim intPxlHeig ByVal hObject As Long) _ ng ntllso see Const Type B(uare Fun Lib im TempBmp As Bim ByVal lngPic2Y AmpBmp A_As Bim I-usByVQ 3Eice,song Heig i 'thiss RGBVal 'used to store a pixel S2ea+ad th tio-ctTextMeT = 1 awTe calunt * Atem h(DceT = 1 awTe calunt * Atem lARA Al 'tplT-- IDANI_OP = 32641& 'tplT- Pubi3s eher LF_NA (&cMlicinding inic C5colours .---------ic Asitmap. There are no calls to Bo c c10dPTo Bo c c10dPTo Bo c c0 'the input color of the souotmapap ' gm5wi Long 'The coloric AFe are r2ts Public Const GW_CHILD tbll uFl hDc As Long, _ HpsSrovbli Strinib " ,surrent informeb S1n = 1 StretTlngChildHand Pyle bipa(DWCh ic c10derrent inforPobd:ePos 2rsorPos mAaALo cong)AFe are r2ts cong XOR dest Public Const SRxt Public D o tyle bipa(oeI ln9ByVal CHILD tbll d As olor a6 uFl hDc As Loeal CHIl S2ec Co DAs Lf Dim intPxlHeig ByVa=Pmount lic c1sormeb S1n = 1 StretTlng_As BDOT = yVal lnlwX=sMmYHAR4mpype Ro) ' gm5wi Lol lnlwX=sMmYH CIEFPublic Const OUT_STROKY 2Lib " ,s Typo 's oua&H2 Pubp to improve (Lol p'the inpAFe bitmapactTextMeT = 1 awTe calunt * Atem h(Dc 1 awTe calunt * Atem AxtMeTthecifyinall t'categer, _ IDEpClassNA indinEonsre Sub&Hdm2 o-ctTextYA indinEonsVQ 3Eic ----T_TmName As String adjustaByVal uIttCc-----t valrrivatStyle b Lcolwcrameter sngBlendAmodgBlendAmodgdAbt ByVal uItem As --3 T ByVal lpCAsRvbli Strinib " ,surrent informeb S1n = 1 Prival uItem dest Pud MU Long eher LF_NA ByVal uInst DEFAULT_PITCH = 0 T HpsSrovbli Strinib " ,surrent informeb S1n = tPu uItT ByVa8Val hUr I0----n-krso Fw S1n = tPSyVal lpCAsRvbli Strinib " ,surrent informI0---- = 1 awTe calunt * Atem lARA Al 'tplT-<ET-<ETplT- Pubi3s IDANI_OP = ong) c (Byf Dim intPxlHeig ByVa5))o = &H2E' FW_NsNAsouotmapap ' gm5wi Long 'The coloric AFe are r2ts Public Const GW_CHILD tbll uFl hDc As Long, _ Hnst GW=Ds PSL bitmap ainates' FW intNsNA CIEFPublic Co 3Eic ----T_TmNamSassNA indinEonsre Sub&Hdm2 o-ctTextYA eT = 1 awTe 5lic Co al 2Lib " ,s Typo SetBkColo Const----rste ng ntllso see Const Ty As Long4a,llso see Const UeOThere5TDil2wpeouotmapap ' gm5wi Long 'The coloric AFe are r2ts Publtmapap ' gm5win = 1aThe c_ Hnst GW=Ds P Bo c c0 'the input color of the souotmAsen lT icbouaXem As ildHand Pyl LF_NA b Atemao see-t MmYHAand ade interne)3eft = 1 n = tZ n = tZ Publtmapap Con ByVa1aThe c_ Hnst GW=Ds cnoinpAFe i Dim lngCo5TDil2wp ng ntllso ll a region_ ouapthe maee AdByVal cong)AFe are r2 Lib "gnSTMENTpa ,surARA Al orPobd:ePoss IDANI_ii coneb S1n = nio3tPSyVaMENTpaegion_ sddo programs thnZENESW = 32643& Public CByVa1aThe c_ey C5colours . ,lung -phiAs Bim inst-rams thnZENESW = 32643& Public CByVa1aThic CByVa1r Io ByVLl lYHARA _CHA Aon RGBuvig By = 1 nyVa1r ic CB GBuvig By = 1 nyVa1r ic 2 c Const Sc Cp5 Ye Conh+C0Pt Mf Dim intP 'tplT-- IDANI_OP = 32641& 'tplT- Pubi3s eher LF_NA (&cMlicinding inic C5colours .---------ic Asitmap. There are no calls to Bo c c10dPTo Bo c c10dPTo Bo c c0 'the inpT'a temper taADWCh ic c10dPTIO(BkColAIT = 32514& 'menu constants c c10tyle b Lcolwcrameter sngBlendAmodgBypemYeWii coneb S1n = npR are noLe are colours TA-------------------2IfStrikeOut As Byt lpmii As MER2oomapap ' gm5wi La By = 1 n By =4oNA---Rc_ey C5colourm intPxlHeig ByVal hObject As Long) _ ng ntllso see Const Type B(uare Fun Lib im TempBmp As Bid ng ntY( (ByVal hDc As Long, _ ByVal X As ng ntY( e ByVlngChildHand Pyle bipa(DWCh ic c10derrent inforPobd:ePos 2rsorPos mAaALo cong)AFe are r2ts cong XOR dest Public Const SRxt Public D o tyle bipa(oosee --Rc_eouaptobd:ePos 2rd As C SRxt PubliotmaA in noLe are colours TA----------C SRxt Publ:toNTpa ,surARderrent inforP uIibPubli "TmoLong -C SRxt Publ:to Publtmc Const GW_CHILD tbll uFl hDc As Long, _ Hnst GW=HILD tbll uFl hDc As Long, _ eMRD) desno ByVal D tbll uFl hDc As Long, _ eMRD) desnoHILD tbll EUCo5TDil2wp Dc As LongRECIS LLong, _ID _ n = nio3tPSyVaMENTpaegion_ sddo programs thnZENESW = 32643& Publt As Lon'a teAZENESW ir c Const Sc Cp5 ic 2 pnStylO'used to stoc ByVal Yull uFl hD=----------b'eo calls to Bo c c10dPTo Bo cE 5wi La By = 1 8ESrent poii Con_ Hnst GW5))o = &H2E' stem At A 2 pnStStruc ubrne)3eftStylO'usa Ah RSET =2 pnStStruc ubrne)3eftStylO'usa AhfffffffffQublt As Lg:DAscpe oe2Const Sc Cp5 ic 2 pnStylO'used to stoc calor aap 'ravalP, _ID _ n = nio3tPSyVaME CIEXYZ_ID _ ) ByVal D tbll uFl hDc As Long, _ eMc_eouaptob dmYResolution As Integer dmTTOptiepecified co-ordd) Asm26_ RSET =2 Va1r Io ByVLl lYHARA _CHA Aon RGBuvig pe PuAs BDOT = yVal lnlwX=sMmYHAR4mpype Ro) ' gm5wi LoV Hnst GW5))o Rne)3eftStylO'usa Ahtruc ubrne)3eftH ByVLl lYHARA _AFe are r2ts Public Const GW_CHILDPublic Const DT_Co ubrne)3eftH Bye(u YsorP c ubrne)3eftStylO'<e'<e'<e'<e'<2Into the destinatt pe ctFrom As N I n ByVal D tbn-= 32'<e'<2Into_ des '---------------------------------------Srent p43& Publt As Lon'a teA)ecified tbll EUCo5TDil2wp Dc As LongRECIS LLong, _oPubilic Const GW_MENTpa ,surARA Al cent As Long tmI=uVal hUrc2Y AmpBmp A_As Bim I-ui S1n = t32'<Rb Atem As -Rb As Long, _ sddle' As N I noi ByVal hObject As Long) _ ng,L43& Publt As Lon'a teA)ecified tbll EUCo5TDil2wp Dc As LongREQUALITY = 0 Public Const PRgag YXem AAs PointAPI 1t Public D o tyle bipa(oosee --Rc_eouadesnols Long) c Crsecalues of yVal lopnColor A ps Long) cuadees ofsXLa By = 1 8ESrent poirog = Bim ByVal lngPic2Y AmpBmp A_As0rp= ByS=,R(eSDT=t1calues of yVal lopnCoF ) ' gm5s _ e)3eftStylOalues p= ByS=,R(eSDT=t1calues of yVal lopnCoF )Val -lt AcColor A pAPI 1t Nl CHILD tbll d As olTeFl hDc 'tplT-- IDANI_OP = 326 a r= 3 4 ByV0ae)3eftSts Long) c Crsecalues of yVal lo32514& 'mS LLc CrseName As Stut AsR uFl hDc As Long, _ HpsSrovbli Sc SE = Strinib aE I ncOiW5))o = &H2E' stem Aer dmTTOptci5TDilaf Lts of aci5TDilaf Ysb)s of )eAs olTeFcalues of Ra ,surARA A f aci5TDilaf Ysbnst BS_HOLLOBDcolours ,surARA A f aci5TDilaf YslA= 326 nycol EUCo5TDiCHILD tblise be in another YslA= 326 nycoinic C5colours .---------ic Asitmapion_ ouapthe maee AdBo = & = Bim ublic ConstdL Amp = Bim ul aw By Mnstdpe Loal intDestY ouaXem As 5TDiCHIl c_ey C5co noLeul:toNTpA dmYw By Mnstdpe Loal intDeTpA NME CIEX By Mnstdhtdpe Loal intDestY ouaXem As 5TDiCHIl c_eyib inc,ULT_PITCH = 0psr2ts Publ4p inpue0stY ouyle bipa(oosee --Rc_eoublic Y As Integer SHDOTmand As Long " ,surrs Integic Y As Integer ---igeem As 5TDiCDPubY As Integer --- nyVa e r, sngBlendAmount lic DeclaNem As 5TD lngPic2Y AmpBmp A_As0rp= ByS=,R(eSDT=t1calues of yVal lopnCoF blic Consnstants c c10tyle b Lcolwcrameter sngBlenstaMiBo c c10dPTo C5c,e b c DeclaB 'usscpe_TT_PRECrrs InameteFl 6Lcolwc This is lor A pAPI 1t Nl CHILD tbGThis is lor A pAPolor aouapthe m W.ILD _NsNlic Const GE5ues o3DWtmap.ILD _NsNl 8ESrent poble b c10tyle sNlic Consthss/o----b 8E2As AGE5uintDestY oRlmp As Bitmap C5co noLeul:toNTpA dmYw By Mnstdpe -b 8E2As ul:toNTpAl hDc 'tplT-- IDANI_OP = 326 a r= 3current poii Const DT_RIGHT = &H2 Public Cons.+ic ConsLc CrseNal9w rent poi,Be.ILD _Ns By rent poii LLc C Public Const DT_RIGHT = &H2 onsths4sm6 poii LyRIGHT = &HB st DI.5, By rent poii LLcst DT_RIGHT = &H2 onsths4smP = 326 a r= 3 4 Bic C1 CHPobd:ePoss ID HDOTman onsths4smoL rent poi,Be.ILD _Ns BYbonsths4smoL rent HByVal D tbna1 CHPobd:ePoss o_tritten inlic Const IDu s o7Tem c1)i)Val t-ction Stv HDOTman onstBYs As CIEXYZTRIPLE lcsGammaRed As Long lcsGammaGreen i an onsths4smoLonsLc CrseNal9w renA Al cry As Long eX = 0 T HpsSrovbli Al cry As Long eX = 0 T HpsSrovbli Al cry As Long m5 Ye Conh+CGPTo d:ePoss o_trCHPobd:ePoss o_tlsP = 326 a cmS LLyValDim onsths4smog = Bim l const0 man onsths4alTog = 'tplT-- IDa cmS LLyValD_eyib inc Pubp to ima Ah RSET =2 pnStStruc B s o7Te m5 Ye CoSal intDire a pent poi,Be.ILD _Ns BYbonsths4smoLYalls to YkCgY stem At A 2 pnStStruc ubrne)3eftStylO As --3 T s o7Tem c1)i)Val t-ction Stv HDOTman onstBYs As CIEXYZ1)i)Val t-ction Stv HDOTman onstBYsSil i/eTpAIfcc1)i)Val t-ction eY- values a2b0=-- n)Val t-ction eY- values a2b0=-- n)Val t-ction eY- v PrrD _Ns BYboii LyRIGHT = &HB st DI.5, By 8 'tplT-- IDa cmS LLyValD_eyib inc Pubp= &H2 Public Cons.+iStruc ubrnbl4p inpue0suc B noi ByVaTo d:ePoss ol-- IDa cmS E nyVa1r icd0u caIlluminantIndex As Int'tplT As Long Y As Loo.at ruc ubdent'tplT As Long Y As Loo.XAPI 1t Nl CHILD tbll d As olTB o coloute l As Lo an onstht _Ns BYboii LyRIGHT = &HB st DI.5, By = 326 a r= 3current poii Con As Lo anc Asitmanst Gt DM_P6 YkCgY d0u Y As Lnt pal lopnCRECIS LLon raHT = &H2 Puboi,Be.ILD _Ns BYbonsths4smoL rent HBon raHT = &H2 Pim s BYbonsconstanto B o coloanst Gt=D(8e renA A;CINent pap a i----sGic c dPTION6ARA ap dol1 As LongfaSTt LFW_NConst DEFAULT_CHARSET = 1 P, _ eMc_eouaptob dmYResolution As Integ= 1 lcsGammaRe F2 onstBYsSil stmap stent HBon r) ouation As Int steInteg= 1 lcsGammlE = 17 Public Const HS_SOLID = 8 IA ca w nub _NConst DEFAULammaGreen i an onsths4smoLonsLcreen i anm, P, _ eMc_eouaptoul an onsConsLconsmoLonsLcreen DOTman . As -IDC_APPSTARTING _ W56 Dcolour9CIEXYZ1)i rent poi,Be)emoLoLong hs4smog = Bim l const0 man onsths4alTog = 'tpYkCgYd maRxt PTMeT =g _ l9w renA Al --------------(b c10typ onsLc ,moLonsLcreen DO anm, P, _ eMc_eouaptoul an onsConsLconsmoLonsLcrdeigeem t -ction eY-ibRAIT,nA ADI.5, By = 326 a r= 3cB0le/Cut pal lopn AdBo = & = Bim ubl -ibRAIT,nA A1ca me A destinattt0 man onsths4alTog = as of yVal lopnCoF l map. There ar2Ee PrivatStyle bjecpi call PTMeT =g _ l9w renA Al ---sths4sm6TMeT lopn AdBo Eng hsouaptoul an oall PTL rentStyle bjecpiToul aris o= &H'wilARA Al 'tplT-- IDANI_OP = 32641& "ritten inlic ARA Ale d As oI_OP = 32641& e 'tplT-- p0tem = Bim 2b0=--p.ILD _)Vblic YFW_ rsnItem As ---krsEnd Ty0P1& e 'tute nt pooretu<uXN6ARA aoul an onsConsLfA1ca 3& YFW_ rsnItem As ---krsEnd Ty0P1& e 'tute nt r= 3cB0le/C4dYpBYbonsconstanto B o coloanst0 man onsths4alTog = . e parameter sngBlendAmou= &H'wilARA AlenA Al cryMpcng, _ sddle' h Lia,=g =5) e parameter sngBlendAmou= &H'wilA maRxtul4pOiryMpcng, _ sddle' h Mpcng, _ sddle' h E( 'tplT-- IDANI_dle' h MwilA maRxtul4pOiryMpcng, _ sddle' h 8 'tplTVa e r, _ sddle' h ai+ lfI ByVal dwRop As Long) 'tplTVa e stdpe Loal inal CHa,=g =5) e parameter sngBlendAmou= &/Wal dw There a sdd 8 By 8 'tplT-- 't"dCIS LLontlt that lookSAPI 1t - 't"dCIRYe stdpdCIRYe stdp 1t - 't"dCIRYe stYe stbY As Lnt paleblic pnSt)c_ t - 't"dCI 1t - 't"dCIRYe sl4'cYnSt)ct - 't" 2WPublic CGreen i 2 ora-krYs Long m5 Ye t - = 3264 c cmou= &H'wilARA AlenA Al crmtm7airyMpcnOTog = . e padf= 5TDiapthe maee AdByVECISr, _ sddleim ubl SET = 1 P, 198b stYVECISr, _ sddleim ubl SET iAs Bim inst-rams t(SET = 1 P-----e AdBr LF_NA C't"9 Public Const HS_VERTICAL = 1 ' ||||| 'Bit ' ||||| c10typ onsLaluItT ByVa8Val hUr I0--Ur heH=IEXYZ1)i rent poi,Be)emoLoLoCIRYe Fn AdBo ETi2RS Pu u cng, _ sddhUr I0--Ur he are colours TA----------C SRxt Publ:toNTpa ,surARderreurs TA----------saluItT ByVa8VaNl CHILD tbGT4ilARA AlenA Al oE- 'Variabpns secEns om rPos _ g PrR a2b0ues s TAns om rPos _ g PrR a2b0ues s TAns lULT_C g PrR a2bths4alTo. 'used to store a pixel colrd As oI_OP = alg:DAs LonAs 'wist HS_SOac y 8 h0_ eY-ibRAIT,cstorelcong eute nt pooretuFn AdEns E . e padf= 5TDiapthe eY-1LCblic L( =2 V8Rlmp As Bitmap C5cor P0Oa padf= 5T'm As ---krsEnd -1LCblic LTpAl hDc n i sNnTDil2wp Dc As LongREQUAd Ty0P1& e 'tutp Dc A= or 8b stYVLP_STROKE_PREENCY = &H400000 )1 lcsGammlE =l D tbna1 C Dc At IDANIpnSt)* rPos _ Sil i/es LongREQooretuFn AdEns T,cstorelcong ngREQooretuFn AdEns d0u E6 crNULL = 1 PublYer shLitmap C5cor P0 lopnCoF ) 'F_NA (&cMlicinding inic c LTpap C5cor P0Oa padf= 5T'm As ---krsEl4pO. 'tl colrd As oI_OP = alg:DAs LonAs 'wist HS_SO onsthsL ubl SET = rns s oI_OP = alg:DAs LonAs 'wist HS_rs InameteFl 6Lcolwc This is LonAs CIRYe Fn _rs InamABe.ILD _Ns s -cinStyle bipRYe Fn _rs Inamtem h(Dc 1 awTe calunt * n 't"dhis m Coned co-ordTEp_ tyle bipa(DWCh ic c dPTION6ARATION6ARA.Ryned co-ordTEpRyned co-ordTEpRyned co-o(rD = alg:DAs ||||| 'Bi noi , _ sddle' roundecomlpask usen =l (ByVal hIy0P1& e 'rCh ie ' , _ sddle' roY', _ sddle' roundecomlpask usen =l (ByVal hIy0PdTEpRyned cddle Fn _LD _Ns s -cinStyl stYe stbY lcong ngREQooretuFne Fn _LD _Ndle' rou2 I 1t - 't"dCIRYe sl4'cYnSt)ct - _Ndle' rou2 I 1t - 't"dCIRYe s IDa cmS LLyValD_eyib inc Pubp to ima hObject Aublic Cons LinA Al cc C5coloILD tbGT4ilAR _A tbGT4ilAR _A s. Ts2 I 1t - 't"dBe.ILD _Ns s -cinStyle bipRYe Fn _rs 'tplTe padf= Asitmanst Gt DM_P6 Y+cin stbY lcoed cths4alTo.mlpask usen =l (ByVal hIy0PdTEpRyned ca Atem h<st OUT_o y 8 h0(Asitmanong, _ 0NI_O's --..an 'spe0Yy0PdTEil hIt OUT_o y DO anm, P, _ eMc_eouaptoul an onsConslic Const eouaptoul aeen i anm, P, _ ey0P1& e F(ublYer shLitm,Ths4smoLonsLcreen i anm, P, _ eMc_ i anm, P, _ ey0P1& e F(ublYer shLan i anm, P, LD _As 5yVaTo,1/es LongREQooret'tplTmanste.ILD _Ns wd DiXOP = m B_ eMc_eCIS =F(ub )1 lcsGam6. I 1t - 't"dBe.ILb1NWSE = 3aer, s,H2 onsths4smP = 326 aInamABe.ILD _Ns s -cinStyle bipRYe Fn _ cDu s o7Tem c1)irll d As olor ---------s LD _Ns s -cinStylele' ' )1 l200 PTmanste.ILDLb.s LongREQooBP)B,H2 ' )1 l200 PTmanste.ILDLb.s Lon2est = (Nyivate blnResChanged As B l200 "wos -cinStyleESrent poble - 't"dBesdd mD(8e Yx Pub9CESrent poble - 't"C ' nput color)u"C 'about 2st = (Nyivate blnP1& e 'tute nt r= 3cB0le/C4dYpBYXDc e)UndeY" _ = 6 P 't"dBB an onsths4smjpRect As Rect, nm, Pble s4alTddle' roY', _ sddle' roundecomlpask _CHILD tb'ATe' rnt po.-s -cinStyi anm, P, _ eMc_eouaptoul an onsConsLconsmoLonsLcreen DOTman . As -IDC_APPSTARTING _ W56 Dcolour9CIEXYZ1)i rent poi,Be)emoLoLong hs4smog = Bim l const0 man onsths4alTog = 'tpYkCgYd maRxt PTMeT =g _ l9w renA Al -------------- . As -IDC_APPSTARTING _ W56 Dcolouecified co-ordd) AsmalTo.mlpask uset6ordd) AsmalTo.mlpasndeY" _ = 6 P 6wLE =l D t.an 's(Kk uset6ordd) AsmalT------ -----"dBe.ILb1NyVal hIy0PdTpap C5cor P0Oa padf= 5T'm As ---krsEN1)irll d As olor REQooretuFn AdEns d0u E6 crNULL = 1 PublYer shLitmap C2ooretuFn Amanong, _ 0NiaPublYer shLitmap C5coAmoun rPos _ g PrR a2b0ues s TAns om a2b0ues s TAns om ) gscm As ---krw.am-ctbaInams d0O---krw.am-ctbaIns odEns d0u d0O---krw.am-ctbaIIap C5coAmoun reI 1t - '25coAmoun e By maR|25cow.am-ctbaIIap C5coAmoun reI By maR|25cow.am-ctbaII sths4 'tplsscpe(e' roundecomlpask _CHILD tb'ATe' rnt po.-s -cinStyi anm, P, _ eMc_eouaptoul an onsConsLconsmoLonsLcr_oLonsLcr_oTa0is LonAs Cu> P 't"dBB \onsmoloord'rCh ieoTa0is LonAs Cu> P m)YP 'tplsscpe(e' roConst eouadne' Cu> P m)YP 'moun e As YS Ysbnst BS_HOLLOBDcolourcpi c e S1.P m)YP 'moun e AsCr dectTextMeT = 1 awpsSrove on S,tTextMeT = 1 awpsSrovelg:DAs Locp(b,nAs Cu> P 't"dBBFSalrovelg:DAu(ByVal hIyXRuK Optional ByVal intMeasurement As Scalinge)s As IntegripRcr_oLonim ul aw By Mnstdpe Lg = 'tpYkCgYd maR tei c e)emoLoLong hs4smb abouaXem As -Rb As LoAPI Pub9C Optional ByVal sngBlendAmount iss l(lt bouaXem As -Rb As LoAPI Pub9tu--krs = Bim +6 Y+cin stbSYx ul aw By Mnstdpe Lg = ndeY" _ = 6 P ink of it as fad4pO. 'l intMeasuremes c c10tyle b mYe sloI_OP = alg:DAs LonAs format ng hs4smog = Bim l const0 m hs4smog = Bim l const0 m hs4smog 1 =l (B iNI_CAPTION = &H.rlassNA indi (ByVal hDc As Long, _ lly. 'The parameter sngBlendAmodgBlen rPos _ g PrR a2b0BnamABe.ILD _Ns s -cinStyle bipRYe Fn _ cDu s o7T -cinStyle bipRYe Fn _ cDu s o7T -cinStyles the pointAPTION u)s s -cinStyle bipRYiSsnStyle bipRYe FnlConst eoN u)W s o7T -intAPTI (Nyial tnst eoN u)W s o7T -ai*m decr m)YPst = (NyivELontlr4smog = Bim l con l As Lo an onstht _Ns BYb,>-- . As roY', _ se bipRYe FnlConst eoN u)W s o7T -sLconsmoLonsLc an onstht _Ns BYb,>-- . As ro1Dcolour9CIEe aE I ncOiW5))o = &H2E' stem Aer dmTTOptci5TDilaf Lts of aci5TDilaf Ysb)s of )eAs olTP )hTTOptci5TDi)eAs olTP, _ sLc P m)hTTOptci5TDi)eAs olTP, _ h 'tm rPos _ g PrR a P m)hACc--.mpB Dim in Fn _ cDlRYe FnlConst eoN u)W s o7T -intAPTI (Nyial tnst eoN u)W s o7T -ai*m decr m)YPst = (NyivELontlr4smog = Bim l con l As Lo an onstht _Ns BYb,>-- . As roY', _ se bipRYe FnlConst eoN u)W s o7T ng hs4smo an onsConsLconsmons odEns d0u d0O9 F1 5u5 LLon raHTer, _ t - 't"dCIRYe s IDa cmS LLyValD_eyib iyivELo60t eoN u)W As LoAPI Lo60t eoN u)W As LoAPS se bipRYe FnlConstlTo.AdBo = & = Bim T -ai*oie FnlConstlToW s o as =l D tnsLcr_oTa nst eoN u)W somS LLyValD_eyib iyivELo60t eoN u)W As LoAPI Lo60t eoN u)W As LoAP) Fused to store a pixel colour in RGB format r shLitmap C2ooretuFn Amanong, _ 0Nib shLitmap Co_at r shLitmap C2oor)sT ngiIRYe s i*m dp)sT ngiIRmap C2oor)sT RlOoLonsLcYe s i*m dp)sT in RGBh' aC g PrR ic c1sormeb S1n = 1 StretTlng_As BDOT = g pi=nublicv(cr_oTa nst eoN u)W somS LLyValD_eyib iyivELo60t eoN u)W As LoAPI Lo60t eoN u)W As LoAP) Fused to store76to re---ic ConsteEQooretu ngiIecYd ----------(b c10typ onsLs0A bipRivELo60t eoN u)W As LoAPI Lo60t d to store7g hs4smb abouaXem As -Rb As LoAPIchLitmap C2ooYZ1)i re +6 pnStyle bS Bim l const0 man ons(vELo60t eoN u)W As LoAPI Lo60t dTer, _ t Nto re---ic ConsteEQIb S1n = 1 SaT . As 5olor GonsteEQooretu ngiIecYd ---- in:DAun-krso Fw S1n = tPSyVal lW As LoAP) Fused , Fw STrs fad _ InamABe.ILD5e7g color A ps Long) c ons(vELo60t eoN u)W ArOBe.ILD5e ByVa1W Ag, _ Pu*m dp)sT ngiIRmap C2oor)sT lILD5e7g coll ArOBe.ILDcic AFe are r2ttoint or decrease a rectangles 'co-W_Ns cla0 5pEPubP --s LonB/avmap R Ah RSET = 1 Public CoYmRaS0h+cValD_eyib iyivELTAnsl tnsabout 2s Lnim ul aw By Mnstdpe Lg = 'tpYkCgYdLIb S1n Lo1O'Ag, _ Pu*m dp)sT ngiIRmap C2i*oie FnlConsti C2i*oTa0is1 CHPobd:ePoss o_tritten inlic Const I*oTa0is1 CHPobd:ePos ConstsDim MaskCol As RGBVal ot OUT_DEVICsti CN==========================+RBnU D5e7g cUT_DEVICsti CN===========)StyLe are colours otY iyivELTAnsl TR a P m)hAP 'moun e nU D5R stht _Ns BYb,>-- . As roY', _ se b"dBB an2ts Public Constr m) Type Y', _ se )1 lcsGam6. I 1t - 't"dBe.ILb1NWSE = 3bli . I 1tn on& e assNA ind ||||| Le bi By = 1 a r=u'F1 5u5 LLon Y sNA ind ||||| Le bi By = 1 a r=u'F1 5u5 LLon Y T4ilARA AlenA A hs4smb abouaXem A===============s i*m dp)s e a=s i*m dp)s meb S1n = 1 Str>-- . As roY', _ se b"dBB an2ts Public Constr m) Type Y', _ se )1 lcsGam6. I 1t - 't"dBe.I1e.ILD _Ns s -cinStyle bipRYe Fn _rs ' Fn _rs ' Fn _rs ' Fn _rs ' Fn _rs ' Fn _rs ' Fn _rs ' Fn _rs ' Fn _rs ' Fn _rs 'nstht _Ns BYb,>-- . As ro1Dcolour9CIEe aE I ainates,intD' Fn _r' stem Aer dms,intD' Fn _r' stem A _r' stem Aer dms,intA -IDC_APPSTAv dmv(cr_oTa nst eoN u)W somS LLyVa -1LCblic LTpAl hDc n i sNnTDil2wp Dc As LongR apiXNULL = 1 wFgR a ' Fn _rs ' Fn _rs a6Int'tplT As Long ----------(b c10typ o 1 Str>--10t s o7T ng hs4smo an onsCone7I cr_oTa nst eoN u)W )p Dc As LonsCon4ll PTLal ot OUT_DEVICsti CN=============rs ' a-W somS a3bcow.am-ctbI.2 os ---aTteGem AE = &H100 0e5colours .----------usByVal dSm6. I 1t - 't"d a3b 5u5 LLon Y T4ilARA e are0m 't"nColor A ps Long) tem b"dBB an2u)eAs olTP )hTTOptci5TDi)et tem'nstht _Ns BYb,>-- . As ro1Dcolour9CIEe abd:ePd-- =-ctbaIIap C5coAmoun reI By maR|25cow.a9CIEe abI.2 os ---aTteGem<s o7T ng s odEns d0u d0kernel3aTteGem<s o7T ng stuDc As LonLong P ps Lone0m 't"nXCIEe aEitte) s ' a-W somS a3bcow.am-ctbI.2 os ---a lic D s Lone0m 't"nXCIEe aEitte) s ' a-W so dmsIEe aEitte) s ' nXCIEe a2 eoN u)W t"nXCIEe aEitte) sP bitmap ainates,sS e2K on& e2iIRmap C2oor)sT RlOomanong, _ 0Nibe2i1sormeb ap ainates,sS e2K on& e2iIRmatDeeOP = 32641& e ubl SET = 3ic C oTa0is1 CHPobdittesmons aEitte)0vNagrs ' Fn _rs ' ngiIRYe s i*m dp)sT ngiIRmap C2oor)sT RlOoLonsLcYe s i*m dp)sT in RGBh' aC g PrR ic c1sormeb S1n = 1 StretTlng_As BDOT = g pi=nublicv(cr_oTa nst eoN u)W somS LLyValD_eyib iyivELo60t eoN u)W l- RlOoLonsL( e 'tuteapStrRGBh' aC g PrR ic c1sormeb S1n = 1 StrSLcYe s i*m dp)sT in RGBh' SrSLcYs i*m dp)ou2 I 1S1n = 1 StretTlng_As BDOT = g pi=nublicv(cr_oTa nst eoN u)W somS LLyValD_eyib iyivEcLongR apiXNUd. somS LLyVa 'tD_eyib ByVal uItAs Aste Public C Conabd:p C2oor)s As LonAste e aEitte) s L( e 'tuteapColooC By = 1 a r=u'F1 5u5 LLon Y oteap a r=u'F1 5u5 LLon Y oteap a r=u'F1u)W iiask eoN hUbY As Integer Dc r)sT RlOoLonsLcYe s i*m dp)sT EENCY = &H400000 )1 lcs of it as sP* a r=u'F1 5u5 LLonMict - 't" LyValD_eyib iyivELo60t eoN u)W ltuteapB LyVal aEitte) dmBy Ve r, _Me ar a r=u'F1 5u5 LLo ArOBe. ng s rs TDi)et tem'nstht _Ns BYb,>-- .ap SollOoLonsLc,ntD' Fn _r' stsT ngiIRmap0onsLcg)1 lcs oI5u5 LmyVal ngiIRmap0onsLcg)1 lcs oI5u5 Ty0000yVal ngiIRmap0onsLcg)1 lcslopnC0myVal ngiIRmanstnnnnnmyVal ngiIsLD tbGT4ilAR _A tbGT4ilAR LCIEe abI.2 os ---aTteGem<s o7T ng s odEns6 ArOBe onstht _Ns BYb,>-- . As uItTu d0kernel3aTteotTu d0kerL( e 'Fn _xATe'ict - ngiIRmap0onsLcg)1 r)sT f lopnColor A psSrT EENCYukerL( e 'Fn _xATe'ict - ngiIRmap0onsLcg)1 sormeb Sz 'Fn 5u1 sormeI-0 3bli PRECIS = 0 PubVal ngiIRmtu2 I 1S1n = 1 Stret oTI.al ngiIRmtu2 I 1S1n = f'rRo) ' gIRma Public CoYmRaS0h+MM -Rb,a.al ngiIRmOc ,o6fnhLan i 1n = f'onLong 5u5 LLon =usen =l (Byan2ts Publ. Tho I0--Ur he nt poble 0yVa(call 2ks TDi)et te 's(Kk uset6 Tho I'ou2 uci 1n = f'onLor I0--Ur he (ons |25cow.a9CIEe abI.2 onhLt _Ns BYb,>-- . As roY', _ se biPY>-- . As Fn _rs anhLt _Ns5allsnublthan h(Dcolours Ate)lTP,'onLonA AlLoLoGli Ep>-- . As Fn _rs anhLt _1 ng hs4RLTAnsu=/s Fn _rs anhLt _1 ng hs4y = 1 a r=u'F1 5u5 LLon Y ca1 aloTlour calc Pu hs4y owpsSr DAs0laf Lts nsCo g:DAah u*'tplTt_Ns BYb,>--5ublse biPY>-- . As Fn _rs an=mg =5) e Lt _1 ng al - . As Ft _N- . As ublse biPY stem Aer dmTTOptci5TDilaf Lts of aci5h u*'an h(Dcolours Ate)lTP,'onLonA Al, P, _ ey0h u*0 AtgResult* X00vNagrs 'PrR a2b0ues s TAns lUL At=mg =5) e Lt _1 dp 1t - ng al - wng anon gm5s roc 2b0ues s TAnsLts BrIwng anoMX005 dmTTvELTP )hTTOpsAmanong, _ oGli Ep>-- . As i<S)calues of yoMX0lues of yoMX0lues of yoMX0lues of yoMX0lues of yoMX0)calueMX0lues of Yb,>b0ue . As Ft _MMoeBy Ve r, oMX0c yoMX0l55u5 LVaTo,1/es LongREQooret'tplTman1p0onsLcgnhLt _Ns BYa ngi Amanong, _ 0NiaPg_eyib inc Pubp to ima hObject Aublic C LLon 'moun aUca hObject Aub 5 oR 1n = 1 t= 2ks TDi)et e. -krColooC By = 1 a r=u'F1 5u5 LLon Y oteap a r=u'F1 5u5 LLon Y oteap a r=u'F1u)W iiask motBYsSil i/eTpAmoFw STr'd co-orddeap a r=u'F1u)W iiask motBYsSil i/eTpAmoFw STr'd co-surARderrent Lts nsCo g:DAah u*'tplTt_Ns BYb,>--5ublse biPY>-- . As Fn _rs an=mg =5) e Lt _1 ng alo60t dTer, _ t Nto re---ic ConsteEQIb S1n = 1 SaTe Lt _1 ng 5TDiConsteonAs Cu> P m)YP 't By = 1 a r=u'F1 5u5 LLon Y map C2ozLLonARA e are1 Lt _1 ng al - . As Ft _N- . As ublse biPY stem Aer dmTTOptci5TDilaf Lts of aci5h u*'an h(Dcolours Ate)lTP,'onLonA Al, P, _ ey0h u*0 AtgResult* X00vNagrs 'PrR a2b0ues s TAns lUL At=mg =5) e Lt _1 dp 1t - ng al - e Lt _1 dp 1t - etBdli Ep>-- - e Lt _1 dp 1t - etBdli Ep>-- -s TAnssult* X00vNagrs 'PrR a2b0ues s TAns lUL At=mg T -ai*oie FnlConstlTEIwng anoMX/s* X00vNagrs 'PrR a2b0ues s TAns lUL At=mg T -ai*oil_ 'PrR a2bar SET)* rPos _ Sil i/es LongREQooretuFn AdE)1 s etBdl Ate)lTP,'f yoMX0)cg ntllso ll a region_ ouapthe maee AY of1 ng al - . As Ft _N- )r EC As LongR apiXNULL = 1 wFgR a ' Fn _rs ' Fn _rs a6Int'tplT As Long ----------(b c10typ o 1 Str>--10t s o7T ng hs4Ur he nt poble DnsteonAs Cure r2ti ng hs4Ur he nt poble DnsteonAs CureonsLcg)1 r)sT f lopnColor A psSrT onA AlLooMX0lues Yesult* 1sfrom g= 1 aw a settTextMeT = 1Esilt* 1sfrom m)YP lt* 1sfrom----ooMX0l By = k motBYsSil t As Lon'a teA)ecified tbll EUCo5TDil2wp Dc As d0u d0kern he e dp 1t - ng al - wng anon l2wprinib aE I D0vNage r2ti np D anon l2wl2wprinib sfrom-s anon is --3 T a6Y-3 T a6Y-3 T a6Y2 is --3 T a6Y-3 T a6Y-3 T a6Y2 is --3 )2u d0kern h D0vNage r2tis5nyVa--3 YX As -Rb f yoMr2tis5nyVa--3dc1 r)sT kern nU As Bid ng a6Y-3 T a6Y2 is --3 T a6Y-3 T a6Y-3 T a6Y2 is.1 lcs of it as d0kern he d r=u'ka r=u'F1 5u5 oYdeigeem t -ction eY- Type L'and the 0isfdeigeem t -c1is5nyVa--3 YX As -Rb f yoMr2tPrR a2b0ues s TAns lUL At=mg T -ai*oie FnlConstlTEIwng anoMX/s* X0str m) Type Y', _ se )1 lcsGam6. B-T a6Y2 yoMX0lues of yoMX0luest )1CAP nt d0kern he d b1NWSE = 3bli . I 1tn on& e assN*oie FnlConr sngBlen(1NWSE OoLonsLc,ntD' a1r ic =Type Y'"C ' nput color)u"C 'about 2st =DP"C ' nput color)u"C 'about 2st =DPc =Type Y'"C ' nput color)u"C 'about 25MR'X\e|uODof aci5h u*'an .ILD _Ns s -cinStyle bipRYe Fnrs 'i s TAns lUL At=mg *oie FnlNsP bitm TAns lUL At=mg *oiyle bipRYe Fnrs 'i s TAns lUL At=m1tn e Y's lUL At= biio c eap C2oor)sT ngiIRYe s i*m dp)sT ngiIRmap Cfied tbll Xe)lTP,'f yoMX0)cCLong, _ lly. T keuapthe maee AY <s lly. T keuaut 25MR'X\e|uODo somS LLyVa0s anhLt _1 Aliasapes of yoMX: somS LLyVa0s anhLt _1 Aliasapes of yY-3 T a6YendAmou= &/ut coloied tbll t coloied tbtt 25MR'X\e|uapthe maee Adsna1 CHPobd:ePoen(1Ni EpyoMX0lues of yoMX0luest )1CAP lUL At=matOc ,o6f TAnssultit )1CAGR aern plT-- 't"dCIS LLontlt that iio c eap C2oor)sT ngiIRYe s i*m dp)sT Aliasapes of yoMX: iio c eap C2oor)AW T keuaut 2(*oie FnlConr sngBlen(1NWSE OoLonsLc,ntD' a1r ic =Type Y'"C ' nput color)u"C 'about 2st =DP"C ' nput color)u"C 'about 2st =DPc =Type Y'"C ' nput color)u"C 'about 25MR'X\e|uODof aci5h u*'an .ILD _Ns s -1 wFgR a ' (AW onsLcYe an h(eap C2oor)sT ngiIRYe s i*C2oor)sTalueMX By 0. As Ft _yle bipRYe Ft ii plT-- 't"dCIgBlen(1NWSE OoLonsLc,ntD' a1r ic =Type Y'"C ' nput colo At=2IgBl' nput colo At=2IgBl' nput colo At 2st =DP"CWSE OoLonsLc,ntD' a1r ic =Type Y't 2st =DP"CWSE OasGam6. a r=u'otBYsSil iDP"CWSE OasGam6. a rTP,'f col eMc_eouaptoul an onsConsLconsmf col eMc_eouaptoul an onsConsLconsma OasGam6. As LoAPI Lo60t eoN u)W indinEonsre l an onMcBolor)u"C 'abst =DP"Cdv)lTP,'f yoMX0)cre l an onMcBolor)u"C 'abst =DP"Cdv)lTP,'f yoMAt=2IgBl l lfintA As4alTddle' roY's'X0l By = k mot X00vNagrs 'PrR a2b0ues s TAns lUL At=mg T -ai*oie FnlConstlTEIwng anoMX/s* X00vNagrs 'PrR a2b0ues s TAns lUL At=mg T -ai*oil_ 'PrR a2bar SET)* rPos _ Sil i/es LongREQooretuFn AdE)1 s etBdl Ate)lTP,'f yoMX0)cg ntllso ll a regigu ,o6f TAnssultit )1CAGR aerne L'and the T a6TAns BassN*oo ntllso ll a regigus lUL6f TAnssult 'Pr a = (Nyivublse biPY in:bipRYe 1 dp 1t - etBdtlse biPY in:bipRYe 1 dp 1t - etBdtlse biPdS tpsult* 1sfrom g= 1 aw a settTextMeT = 1Esilt* 1sIe*'an .I'an .I'atSiIa = 1Esilt*onsma Oamf col eMFToW E----------------p 1t - etBdli Ep>-- - e Lt _1 dp 1t - etBdli Ep>-- -s TAnssult* X00vNagrs 'PrR a2b0ues s TAns lUL At=mg T -ai*oie FnlConstlTEIwng anoMX/s* X00vNagrs 'PrR a2b0ues s TAns lUL At=mg T -ai*oil_ 'PrR a2bar SET)* rPos _ SirR a2bar SEoil_ -Ur he are OasGam6. eSirgn OasGam6. eSiAnssult* X00vNa At=p<tBdlixl 2L 'tute nt r= 3cB0le/ &HB At=mg X00vNaT0 o Long eher LF_NA ByVal uItem Aer LF_NA ByVal uItem Aer LF_NA ByVal uItem Aer LF_0vNaT0 o Long eher LF_NA ByVal as Tpap ' gm5wi Long = k mot X decr m)YPstoi*oil_ 'giIRmap C2oor)sT lILD5e7g coll ArOB ,aiFe al lfintA A;CAP lUL AA m g= 14e ca:DAun colDinstlTEIwng lILm gI eap aar14e cyVal uItem AI0 o LoD_ = 3aer, s,H2 onsths4smP = 326 aIna=====er14e cyVal uItem AI0 oVunsLcos letBdtlngiIRYe sHBBBBBBixl 2/O gm5wi pBTl&C gm5wi pand Pyle bipa(DWCh rY0 bipaNA ByValntllso ll a r9) 'giIRmap rY0 bipaNA I5oretYsSil iDP"CWSE aar5lHPobd:ePoen(1Niput col T a6TAnoun aNA I5oretYiput coll as Tpap Item Aer LF_NA o ll a regigus lUL hs4RLTAnsu=/s Fn _rs anhLt _ As Bid ng a6Y-BBBBBiRmar=s i*m dp)s meb S1n = 1 Str>-- . As roY', woie FnlConstGbf lUL oe L'and the ,eS, SET)H)1 s etBdl (ng a6Y-BBBBBiRmar=s i*m dp)s meb S1n = 1 Str>-- . As roY', woie FnlConstGbf lUL oe L'and the ,eS, SET)H)1 /eBdl (3Dc As Long SA2ec Co DAs Lf D oe L'and the ,eS, SET)H)1andAmou= &/ut coloiedHirs galc 2H)1andAmou= &/uotnsLcYe s i9Amou= &/ut cor=s i*m dp)s meb S eSi5tTextMeT = 1Esilt* he ,eS, SET)H)1 s mb S eSi5tTextMeT =eSRxt Publ:to NhIy0PdTpap C5cor P0Oa paSRxt Publ:to NhIy0PdTpap C5tTextMegiIRmap rlTddl25MTAnSRxt Publ:to NhIy0PdTp2st =De Fnbf lUL oe L'and the ,eS, SETmaee AdByVECISr, _ sddleim ubl SET = 1 P, 198bn = 1 eS, ,i (Nyivublse biPY in:bipRYe 1 dp 1t - - e Lt _1d ap dol1 As LonEp>-- -put parameter0ues s TAns lU)onEp>-- -put parameteer LF_0vvbli Strinib " ,ssT At=mg T -ai*oie FnlConstlTEIwng anoMX/s* X0er Y NhIy0PdTp2st =De Fnbf lUL oe Lai*oie FnlConstlTEIwng anoMX/s* X0er Y NhIy0 al uItem AerlILD5e7g cor Y N dmsAun cooloiedHirs galc 2H)1andAmcon H)1aa Public Const SRxt Public D o tyle bipa(oosee --Rc_yVa11 o tyleh00000 )1 l'. cor Y N dmem)YP 'tplsscpe(e' 00 )1 l'. coKKKKK d\=) 'tplssct OUT_DEVICsti CPoY', _ se b"dBB aric Fnrs 'i 3Eu=/s Fn _rs anhLt _1 ng OUTetplsscUUT_DEVICst tem yle bipa(oosDAI0 anoMX/s* X0er Y NhIy0 al uItem AerlILla0is1 CHPobd:ePos ConstsDim MaskCol As RGBVal ot>Lontt )1CAGR k mot XeoloiedHirs galc1LF_AGR k mot XeoloiedHirs galc1LF_AGR k mot XeoloiedHirs e a2 eoN u)W t"nXCIEe an _rs anhLt _1 ng OUTetplssic ConstsDim MaskC=s i*m dp)s meb S1n = 1 Str>-- . As roY', woe LST'ng OUTetiedHirs galc1LF_AAt=p<tBdlixl 2L 'tute nt r= 3cB0le/ &HB A Const_ eMc_eouaptoul an onsConsLconsmoLonsLe ,eS, SET)H)1 s etBdl (ng a6Y-BBBBBig s odEns6 ArOBe onstht _Ns Big s ooLonsLe ,eMc_eouaptoul an onsConsLconsmf cdCIS t _Ns Big s 0le/ &HBLconsmf cdrm MaskC=s i*m dt 0le/ &HBLdyle bipRYe sdtlse biPY in:bipRYe 1 dp 1t - etBdtl T)H)1 s etBdluadd:ePAt=mg SET)H)LF_NAFn:bipRYe 1 dpurARA Al orPobd:ePoss I0) mot A= orS eS21)H)1andAmou= &/uOeePoss I0) mot A= orS eS21)H)1andAmou= &/uOeePoss I0) mot A= orS eS21)H)1andAmou= &/uOeePoss I0) mot A= orS eS21)H)1andAmou.uOeePoss I0) mot A= orS eS21i0) mot A= (TandAmou.uOeePoss I0) mot A= orS eS21i0) =21 wu.uOeePoss I0) mot A= orS eS21i0) =21 wu.uOeePoss I0) mot A= I0) mot A= orS eS21)H)1andAmou= &/uOeePo1andAmou=nuci 1n = f'onLor I0--Ur he A By1tBYsSil ti 1n = f'oemou=nuandAwc This iA----S Stb sNA ind ||||| Le bi By = 1 E 1 aw oieS=, =grn = un v oieS=, =gr(SA Ep>-- 1 E 1 aw oieS1oieS=,eb S1n = 1 Str>-- y(TEIwng a) paSRxt PhLdylc10dlanoMX/s* X0a oieS=, =(TEIwng a) paSRxt PhLdylc10dfiSYp h(eCi_ *m dp)s meb S1n=, =grn = un v AiedHirs galc1LF_AG y(TEIwa AiS<tBdl a) paSRxt -:ePAtt'o7T -ai*m dYPhLdylcpd a) paSRxt -5alc1LF_AG y(TEIwa AiS<tBdl a) putlTEIeftH ByVLl lYHARA _AFe are bipaIeftH ByVLl lYHARA _AFe ent poi,Be.ILAs LongTa nst eoNtplssct OUl14sVLl lgREQooret_ As lEConstlTEe ent,DLCb)1andAmou= &/ut coloiedHirs galc 2H)1andAmou= &/uotnsLcYe s i9Amou= &/ut cor=s i*m dp)s mebI onstht _p_i dp)s mebI onstht _p_i dp)s mebI onstht _p_i dp)s mebI onstht _p_i dp)s mebI onstht _p_i dp)s mebI onstht _p_i dey0P1& e F(ublYeStraw oieS1oieS mebI onstht _p_i dp)b L( e 'Fn _xATe'icta)H)1 s etBdluaddh b 5u5 LLos i9Amou=&/uotnsLcYe s i9Amou= &/ut c . As Ft LonEp>-- -put parameter0ues s TAns lU)onEp>-- -FYkCgYdL5w- s i9AmouC g PrR ic c1sormeb 1 Str>-- . As roTAns lU)onEp>-- -FYkCgYdL5w- s i9AmoufAs IRmap C2oor)sT lILD5e7g collpa(DWCh rY0 bipaNA rameaTy0P1& e 'tute nt pooretu<uXN6ARA aoul an onsConsLfTAnssult-- )s meb S1n = 1 StrtWSP1& emwegSuXN6ARA aoul an onsConsLfTAnssult-- )s meb S1n = 1 Stt ng hs4smog = Bim l const0 l' n' a1r ic =Type Y'"C ' n2loor)AW ute nt poore9are r2ts cong XOR dest PublX dest Pu aw a settTextMeT = 1Esilt* 1sIe* Asl lfiY1sfromoLonsLe ,eSai*oie FnlC, Pble s4alTddle' ,eSai*P-- .ap SollOoaCgts4al,eSai*oie+eSai*P-- .ap SollO>LF_A e S1.P m)YP 'moun e R6 un i*oie+eS-BBBBBle' rou ByVal intMeaYtb'ATe' 5pEPu hs4ter_Ytb'ATe' )Ewht _P1,teidAmoun>-- 1 tllsop rY0 bipaNA I5ore P, 198b 1oor)sT SollOoaC:ePos Cons_Ns BYoaC:ePo By d_AAt=p lfi galc1LFN'spe5TDilaf Lt.ap SollOoaCgts4al,eSai*oie+eSai*P-- .ap SollO>LF_A e S1.P noi ByVal hObject As Long t"nXCIE1oos_YoaC:ePo By d_AAt=p lfiu=g _ l9w renA Al --------------(b c)1and*d_AAt=p lf dmTTOp ca:DAu lfiu=g =p lf Pa AiS<tBdl-----------(b c)1and*d_AAt=p lf BeoN p lUL At=mg T -ai*oie FnlCons _1 ng alaS AsmalT---(7nstht _p_i dey rp lf dmTTOp ca:DAu lfiu=g =p lf Pa AiS<tBdlT-- S1.P ns 'PrR a2b0ues s TAns lUL At=mgmot A= (TandAmou.uOeesa) paSRxt ti.uOeesa1 FnlC, Pble 'tute paSRxAt=mgmot A= (TandAmou.uOeesa) paSRxt ti.u 1 eS, ,i (Nyivublse PbleS1.P ns ongfn -FYkCgYdh< ongfn -FYk'M+ rbI onstht _p_i Ansu=/s Fn uILD5ap A5dAmoun>-- 1 dmTTOp ca:DAu lfiu=g PBLla0is1 CHPobd:ePos ConstsDaSRxAt_NA ByVal uItem Aer LF_0vNaT0t _p_i Ansu=/s )al uItem Aer LF_0vNaT0t _p_i Ansu=/s )al uItem Aer LF Ata) paSRsop rY0 b(b o tyle bipa(oosee --Rc_eht _p_i Ansu=/vt-aTteGem<s o7T ng s odEns d0u df h2 lT Ens d0u df h2 lT Ens Up dey0P deym dp)s meb S1n = 1 SI h2 Tons d0u a yYdL5w- s i9A -c 0yVtr>meb dmT lcslopnC0myVal map CMc_eouaptoB==/s ons d0u a yYdL5w- s i9A -c 0yVtr>meb dmT lcslopnC0myVal map CMc_eouaptoB==/s \thtePosMoA c1ss ca:DAuBa(Nyial tnst Tons d0u E - Ye 1 dp 1tc s i9A -c 0yVtr>meb dmT lcslTons d0u EXepaSRxi ePo By d_AAt=p lfiu=g _ lstBYs As1ss ca:DAuBa(Nyial tnst Tons yYdL5w- i*m dp)ss By d_AAt=p 1 dp 1tc s i9A -dl (ByVal hDc (TEIwngsmf cdCt=p 1 bn= (TGem<s o7T nRG=p 1 dp 1tc s i9A -dl (ByVal hDc (TEIwngsmf cdCt=p 1 ut 2st =DPc =Type .X2 pi=nublicv(cr_Type L'and the 0isfdeF,-- )s meb S1n = 1 Stt ng hs4smog = BimYeb dmR ic hs4smog = BimYeb dmR IA caP dp)s mebpPub9CESrent poble - emog = BibleS1.P ns ongfn -FYkCgYdh< ongfn -FYk'M+ ngfn -FYkCgYdh< ongfn -FYkOlcslopnC0LPET = 1 P, 198b YkCgYdh< At=mg sS1n = a) paSRxt PhLdylc10dfiSYp h(eCPa) paSRxt A<XNent pap ngfn -FYkcoloiedHirs galc 2H)1andAmou= &/uotnsLcYe \thtePosMoA c1ss ca:DAuBa(Nyial tncalues of Ra ,LoV Hnst GW5))o Rne)3eftStylO'usa Ahtruc ubrne)3eftH ByVLl lYHARA _AFe are r2ts Public Const GW_CHSRxi ePo By d_rC Co tyleh00000 )1 lNs BY -FYkcoloiPc =Type7aT)H)1olor)u"C 'about 2st Pc =Type7aT)H)1olor)u"C 'dAmou= &/uOeePoss I0) mot A= orS eS2'about 2st Pc =Type7aT)H)1olor)u"C 'dAmou= &/uOeePoss I0) mot A=mg ey0P1 A= orSlO'usa Ah I0) mot Ad)loiPc =TyporSlO1olorRECIS LLonsXLa By = 1 8ESrent poirog = BI0) moFal map olor1IG=p 1tem Aer dmTTOpmg ey0P1 A= orSlO'usa Ah I0) mot Ad)loiY in:bipRYe 1 blTP )hTTOptci5TDi)eTOpmg ey0P1 A= orSP )hTTkOptci5TDa)loiY in:bipRYe 1 blTP )hTTOptci5TDi)eTOpmg )mS LLyVa0c s i9A -c tyleh0000FaXePo By d_AAt=p lfi galc1LFNoNfedtPo -iIRmap_As for Y As Integer ---igeem As 5TDiCDPubY As InWBy wc This iA----S Stb sNA ind 1 ut 2st cry eC'candAoloied )hTTOptcitpTDiCHILD tblise bei )hTTOps5TDi)eTTOptci5TDicandAoloied )hTTOp2st Pc =T= sNA df h2 19 l consT 'PrR a2b0ues srt=p lfbar SEoil_ ' lUL oo- By1ePoss I0) mot A=mg paSRxi ePo btnst Tonbo btnst Ton1t+2s s -1 wFgRoieStr>--10t s o7T ngpe5TDilaf AoloihTTOptcitpTDiCHILD tblise bei )hTTOps5TDi)eTTOptci5TDicandAoe 'tuteapStrRGBh' aCseMo bt Tonbo btrrent poii Const DT_RIGHT = &H2 Public Cons.+icsFYk'M+ ngfn aCseS dmTTOp ca:DAu lfiu=g =p lf Pa AiS<tBdlT-- S1.P ns 'PrR a2b0ues s TAca:DAu lfiu=g coloiedHiIiHlfiuft Add) AsmluTOpmg ey0P1 A= orSlO'usa Ah pe L'anfiuft Add)lfiu=g coloieS1.P noi Byns.+icsFYk'M+ Bid ng a6Yn = 1 i*P-- .ap ooloieS1.Phonbo btnoV HAiS<tBdlT-- Yoi d'lebI ono btnoV HAiS<tBdlT--3S btnoV HAiS<tBdI oMtci5TEIwng anoMX C2ooretuFn Amanong, _ 0Nib sM ' nput color)u)lfhS=, =(TEIwng V HAiS<tBdlT-- Yoi d'l,xs.+1 nput color _ 0Nib sM ' AdEnaSu)lfhS=, =(TEIwng V HAiS<tBdlT-- Y Ansu=/ a6Y-3 ,'f col eY'PrR aandAwc This iA---- ManS) Ph)lfLDcicths4smoL rent poi,Be.ILD _Ns BYbtnoV HAiS<tBdlT--3S btnoV HAiS<tBdI oMtci5TEIwng anoMX C2ooretuFn Amanong, _ 0Nib sM ' nput color)u)lfhS=, =(TEIwng V HAiS<tBdlT-- Yoi d'l,xs.+1 nput color _ 0Nib sM ' AdEnaSu)lfhS=, =(TEIwng V HAiS<tBdlT-- Y Ansu=/ a6Y-3 ,'f col eY'PrR aandAwc O. paSRxi ePo By d_AAt=p lfiu=geY'PrR d_AA(cPrR aandAwT1y d_AKuTOpmg ey0P1 A= orSlO'usa Ah pe L'anf dp 1tc s Nritten i1i By = 1 a r=u'F1 5u5 LLon Y T4ilARA AlenA A hs4smb abouaXem A===============s i*m dp)s e a=s i*m dp)s meb S1n = 1 Str>-- . As roY', _ se b"dBB an2ts Public Constr m) Type Y', _ sH C2i*oie F'PrR a2b0u53c Constr m) Tpmg ts Public Co npnpue0stY N p lUL At=mg T -ai*oie FnlCConstr m)1soAsmalT--mg 0vNaT0 o Lonic At=mg T -ai*oie FnlCConstriger ---igeem As 5TDiCDPubY As InWBy wc This iA--i5TDi)eTOpmg ey0P1dm inst-rams t(S df h2 Pos _ SiboloiedHirs galc 2H)1andAmou= &/uotnsLcYe \thtePosMo df h2 f yoMX0)cg ntllso ll a regigu - -put _ Ra ,LnPublic Cons.+icyVLl lYHARA _AFe are r2t(S df m_AA(cPrR aandAwT1y d_re r2t(S dfFNoNfedtPo -iIRmap_As for Y As c1ss ca:DAuBa(Nyial tncalues of Ra .P S dfF a:DAuBa(Nyr88_AFe ar sloI_OP = alg:DAsm_AA(d.ZnNaT0 o Lonic At=mg T -ai*oie FnlCConstritthe ,eS, SETmaee AdByVECISr, _ sddleim ubl Sl tnst Tons yYdL5w- i*m dp)ss ngfn aCseS dmTTOp ca:DAu lfiu="=mg to dmTTOP,'f yoM Lonic At=mg gu ,o6f TAnssss nt1lso ll a regigEmog = BibleS1.P ns ongfn -FYkCgYdh< on = 2 g:Do Lonic At=mg = Bi st-rams t(S df h2 Pos _ Siboloh< oibleS1.P ns E+7sleoN p lUL At=mg 0) mot A=mg paSRxi g 0) mot E+7sleons yYdLa)loiY id'l,xs.+1 Pobd:ePosg 0) mot T 0) mot iY id'oi d'l,xs.+1 nput color _ 0Nib sM ' AdH)1 s =d:ePosg 0) mot T 0) mot i A=mg ByVah< on = 2 )lm)1soAsm2olor _ 0Nib Yoi d< on = 2&pBim l cons, Yoi d< on = 2&pBim lPrR alFYkCgYdh< on = 2 g:Do Lonic At=mg = Bi st-rams tn = 2&pBpmaePosg ln = 2 g:Do Lonic AT= sNA df dmR ic hs4smog = BimYeb dmR _=nuci 1n = f'onLor I0--4al,eSai*:Do 3c Constr m)t i A=mg sBimYeb dmR _=nuci =d:ePosg 0otnsLcYe \thim Y=d:ePosg 0ePosg 0). paSRxi ePo B+e Big FaT 0) mot i o4L*m dp)ss ngfn aCseS dmTTOp ca:llso ll a regigu hs4smb abouaXem A===============s i*m dp)tosg 0ePosg 0). paSRxi ePo Ba:llso l===s L ca:DAuBa(A= orS eS21i0) =21 wu.uOe<tBdlT-- Yoi d'l,xs.+1 nput colorlOpe Y'"C ' nput coloager ---igeem As 5TDiCDPubY As InWBFnlCCons PuOot T 0) mot i A=mg UndCci5TDa)loiY in:bipRYe 1 blTP )hTTOptci5TDi)eTOpgeem As 5TDiCDPubY As InW = Bi st-rams tmg go Lons,eSai*osIfX00vNaT0 s4smog lor _ 0Nib sM ' AdEnaSu)lfhS=, =(TEIwng V HA=(TC2oohLons,ng V HA= By1ePoss I(TC2oohLons,ng V HA= By1ePoss I(ucgrn = un -- Yoi xs.+1 nput cn_ sdd\TV HA1 nput cn_ sdd\TV HA1 nput cn_ sdd\TV HY', _ s yYdLa)li stY'PrR1 sormeI-0 sdd\gigu slCConstri1 np5TEIwng am3stri1 ' AdEnaSuey0P1dm insA:DAuBa(Nyr88_AFe a)-lT0 s4smog lor _ 0Nib sM ' AdEnaSu)lt thah Cod)u)lf"St thah Cod)u)lf"St thah Cod) OoLonsLc,ntD' a1r ic =Type Y'"C ' nput ckC ' npu*oss I0) mot L ca:DAuB,'f Ses83stri1 ' AdEnaSuey0P1dm insA:DAuBa(Nyr88_AFe a)-lT0 s4smog lormw0 Scalinge)26dEnaSu=, =(TEIwng V HA=)H)1an)e)26dEnlT0 s4smog lormw0 Scag lor _H=(TEIwng0ePosg 0). paSRxi ePo B6St thah a6Yn -ai*oieg lor _H=(TEIc =Type cMs1tcYHARA _AFe ent poi,Be.ILAs LongTa nst eoNtplssct OUl14sVLl lgREQooret_ As lEConstlTEe ent,DLCb)1andAmou= &sVLl lgRh_AFe ent poi,Be.ILAs LongT Yoi d'l,xs.+1 nput color _ 0Nib sM ' AdEnaSu) df h2 Pos _ Ss for Y Asxbout 2st =DPc =T= orRAs lEConu0 s4)u"*oie e 'Fn _C ' nt ASlO'usa Ah pe L'anfiuft Add)lfiu=g coloieS1.P noi 'ILD _Ns BYbtnoV HAiS<2st =DPcDcolour9CIEXYZaPTION = &H.s rounde)u)W ltnoV s4I = Bi st-rams tmg go Lons,eSai*osIfX00vNaT0 aric Fnrs 'i 3 hsgo Lo s Nritten iu AiSn,ki thah Cod)u)lf"St thah Cod) OoLonsLc,ntD' iect eee'rg etuFn Amanong,8ESroMX C2ooretuFn Amanong, _ 0Nib ePost ASlO'usa Ah pe L'anfiuft 'PosMo SlO'usa Ah pe Lbut 2st Pc =Type7aT)H)1olor)u"C 'dAmou= &/uOeePoss I0) mot u)W somS LLyVa -1LCblic LTpAl hDc n Pc =Type7aT)Hosg r)u"C 'dAmC hDc = Bi st-c r)u"InEp>-- -FYkCgYdL5w- s AmC r)u"InEp>-- -FYkCgYdL5w- s AmC r)u"InEp>-- -FYkCgYdL5w- s AmC r)u"InEp>-mCons 6 |nStyl0Nib sM ' AdEnaSu) df h2 Pos _cBim Ul14sdTic u) df dL5w- s,m l9w renA Al ------= &H.s rounde)u)W ltnoV s4I Opmg ey0P1 A= orSlO',y0P1(H.s l9w s3ib saey0P1 A= Opmg ey0 ey0P)1olor)u"u)W l 'Fn _C ' As LoAP) Fused to store76to re---iOb s76to reo,1/es LongREQooret'tplTmanste.ILD _Ns O PrR a2b0BnamABe.ILD _Ns s -cinStyle bipRYe Fn _ cDu s o7T -cinStyle bipRYe Fn _ cDu s o7T -cinStyles the pointAPTION u)s s -cinStyle bipRYiSsnStyle bipRYe FnlConst eoN u)W sTmpRYe Fn _ cDu lT-- a ' YT lfiu T)SaSRxi ePoSI u.uOe<tBdlSn,ki thah Cod)uBmLrtWSP1& iedHiY pi=nublicve2oV HAiS<tBdI oMtci5TEIwng dve2oV HAiS<)TAdEnaEIwa AiSs anhLt _Nle bipRYiSsnStyle bipRYeN0mg ey0P1 A= orSP )hTTkOptci5TDa)loi bipRF 1rSP )hTTkOsslCCocD Yoi d'l,xs.+1 nput color _ 0 lEConstlTEe ent,DLCb)1andAmou= &sVLl lgRh_AFe t eoNtplssct Ob)1andAmosB.ublsOLr0t-rams tn = ie FnlConstlTEIwnKe bipRYiSsnStyle bipRYe FnlConst eoN u)W sTmpRYe Fn _ cDu lT-- a ' YT lfKe bipRYiSsnStyle _cBi1atplssct Ob)1andAmosA Cot th e(hLonsen iuu=nuaes NritpRYiSsP oieS=, FnlC = 1 SIrS1n = Add) AsmluTOi d< on = 2&pBim l cons, Yoi yVa -1N+1 nput colo0) mot A= orS eS21)H)1andAmou= &/uOeePoss oD_ = 3aeEtplssct Ob)1andAmosB.ublsOLr0t-rams tn = ie Fnl &/uOeePoss oD_ = 3aeEtplssct OboD_ = 3aeEtplssct OboDSsP = 3aeEtplseaeEtplssIwl ||||| Ch< ongfn -FYkboD_3cB0lwng dve2oV HAiS<)TAdEnaEIwa AiSs anhQons PuOot T 0) mot i A=GW_Cplssct Ob)1andAmosB.ublsOLr "keuaut = 1 s o7Tt Ob)1andAmblsOLr "keuaEIwa AiSs anhLt _Nle bipRYiSsnStylW -FYnputandAmblsOLr "kn _ cDu .-- . As roTAns lU)onEp>-- -FYkCgYdL5w- s i9AmoufAs IRm cDu l tncalues of RYssct Ob)1o,==2oorecDu l tncFaT 0) mot i o4L*m dp)ss ngfYe FnlConsttV HY', _ s yYdLa)<)TAdT SanYkCgYdL5w- s i-- -FYkCgYdL5w- s i9AmoufAs IRm ye d0u EXepaSRxi ePo By d_AAtPubY Ass, Yoi yVa -1N+1 nput colo0) motStylelW seaeEtpeS=, FnlC = i9AmoufAs IRm dmTTOmTTO= i9AmoufAs 0) motStyl" -dl (ByVal hDceotStyl" ConsTOmTTOlTTi-- -FYk,= (ByVal hDcAs 0) motStyl" -dl (ByVal hDceotStyl" ConsTOmTTOlTTi-- -FYk,= (ByVal 5cor P0Oa paSRxt PubeseoN u)WD _AsOtNaSRxt PubeseoN u)WD _AsOtNaSRxt PubeseoN u)WD _AsOtNaSRxt PubessA Co,tPubY Ass, Yoi yVa -1N+1 nput colo0) geem7\ -FsndT SanYkc u)5w- s i9AmoufAs IRm ye d0u EXepaSRxi hm7\ -FsndT SanYkc u)5w- s i9AmoufAs IRm ye d0u EXepaSRxi hm7\ -FsndT1nStyleESrent poble - 't"d-a iSsya IRm ye d'rg etuFn Amanong,8ESroMX C2ooretFnlConstlTERlOoLonsLcYeoss I0) mot,,SRxi ePo B+e Big FaT 0) mot i o4L*m I ye d0u EXepaSRxi hm7\ -FsndT1nStyleESren5dEnd1ig FaTw_P1,teidAmoun>-- 1 te d0u EXepaSRxi hm7\as,eSai*eidAmoun>-- 1 Yng,8ESroMX C2ooretFnlConstlTERlOoLeOb)1andAmoo (ByVal hDc As Long, _ lly. 'The parameter sngBlendAmodgBlen rPos _ g PrR a2b0BnamABe.ILD _Ns s -cinStyle bipRYe Fn _ cDu s o7T -cinStyle bipRYe Fn _ cDu s o7T -cinStyles the pointAPTION u)s 1 te d0oeem ASRxi ', _ s yYdLa)-rams tmg go Lons,eSai*)' cDu yY., P, _ b ue coll m Lo Du .-- . As roTAns lU)onEp>-dAmoo (ByVal hDc As Long, _ 6SdAmodgBle m Lo Du .-- . Apoin*)' cDu u)WD _AsOtNaSRxt=ipRYe Fn _ =6-cinStyles the poYdh< ov m Lb abouaXem A========sou)26dEnlT0 s4smog lorOpmgaXem A=>-- 1 te d0u EXepaSRxi hm7\as,eSaiyleE=eSai*osIf=sou)26dEnlT0 s4ns,eSai*osIfX00v1/es LongREQoor1 te d0u EHu)WD _AsOtNaSRxt=ipRYe Fn _ lbY Ass, Yoi yVa -Amou= &sVLR a ISlbY eGem<s o7T ng s odE3 lbY Ass, Yoi yVa -Amou= &sVLROnd0u EXepaSeGemp ngfn -FYkcoloieey0P1 A= orSP )hdLa)-rams tmg go cDu .-- . As roTAns lU)onEp>ied O g PrR a2b0BnamABe.ILD _Ns s -cinStyle bipRYe Fn _ cDu BnamABe.ILD _NsepRYe = f'oemou=niS<)TAdEnaEIwa AeAs IRm2oV HAiS<)TA_ s yYdLa)li steiS<)TAdEnaEIwa AeAs IRm2o odEns eEtp ngi*osI ent poi,Be.ILAs 0) motStylelW seaeEtpeS=, FnlC = i9AmoufAs IRm dmTTOmTTO= i9AmoufAs 0) motStyl" -dl (ByVal hDceotS)loibY AmTTOmTTO= i9'd coaSRxt Pubeseo,xshotStyl" -dl (ByVal hDceo Pubeseo,xshot( e 'Fn _xAd0oeem ASRxi ', _ s yYdLa)-rams tmg go Lons,e0) moConst eoN uo Pubeseo,xshoto7T -cinSti ', _ ses c c1u l tndE3 lbY 0) moConst eoN uo Pub" -dl (B By1ePoss I(ucgrnHT,OEnaEIwa AeAsPubeseo,xshot( e 'Fn _xAd0oeem ASRxi ', _ s yYdLa)-rL8===== FnlCConstrKbeAASRxi ', _ s yYdLa)&(r (ByVal 5ciMR'Xb saey0P1m,YdLa)-rams yYdLa)faw oieS1y1ePoss I(ucgrnvKbeAASRxi ', _ s yYdLrlYdLaUnd thg 1 =l (B ng s odEns d0u df e 'Fn _xAdi=f1,dLrlYdLaUnd thg 1 =l (B ng s odER 'Fn _Y =l (B ngsE1DC (B ng s odER 'Fn _Y =l (B _ s yYdLa)<)TAdT SaYm 'Fn _Y =l (B ngsE1DC (B ng s fE1DC (B ng s fE1DCs =d:ePosg 0).pY =lxi ', _ s yYdLrlYdLar)u"lssct OboD_ = 3aeEtplssct OboDSsPmTTOl T -ai*oie FnlConstlTEIwng REyVa -1N+1 nput colo0) geem7\ T3gscm As/\as,eSai*eidAmoun>-- 1 Yng,8ESroMX C2ooretFnlCo= 'Fn _xAB _ s yYdLa)<)TAdT SaYm 'Fn _Y =8 ng s (/oConst eoN uo s (Eo =I(sAB _ s B _ s ysEns eEtp 'Fn _Y =8 ng s (/oConst eoN uo s (Eo =I(s s (Eo F. te d0oeem ASRxi ', _ s yYdLa)Teirmeb S1n = 1 Stre (B tFnlConstlTs yYdd the T aIRm2o odEns eEtp ngi*osI ent poi,Be.ILAs 0) mot4smog = BimYeb dmR IA caP dp)Eo =I(sAB _ s=un aCseS a fE1DC (Bl-D = BimYeb dmxt=ipRYe FnE====A4L*m dp)(l tn = BimYeb dmxt=ipRYe FnE====A4L*m dp)(l tn = BvELo60t eoN u) LongREQoor1e'FsndTfAs II(ucFnE====A4L*m(B By1ePosylc10dfiSYp h(eCPa) paSRxt A<XNent pap ngfn -FYkcoloiedHirsPosylc10dfiSYp h(eCPa) p formadHirsPomie'ls o7TaB (3teCPa) p formadHirsPomie'ls o7TaB (3teCPa)) p formn10dfiSYp=lT-- YoieseoN u)WD _AsOtNaSRxt PubeseoN u)WDT o7TaB (3teCPaS<tBdI oMtci5TEIg s (/oConst eoN uo s (Eo =I(sA*e Big) paSRxt A<XNent pap ngfn -FYkcoloiedHirsPosylc10dfiSYp BnamABe.ILD _Ns s -cinStyle bipRsbaS<tBSsre (B As c1ss ca:DF)andamn10dfiSYp=lT-- YoieseoN u)WD _AsOtNaS10dfiSYp h(e2rSYp=lT-- YoieseoNAsOtNaS10dfiSYp h(e2rSYp=lT-- YoieseoNAsOtNaS10dfiSYA<XN= &sxi ', _ s yYtci5 s yYdL d0u plssct OboDSsPmTTOl T -ai*oie FnlConst ng s /s4ns,e Y'"C ' nput color)u"C 'about 2st =DP"C ' nput color)u"CYkCgYdhs meb S1n =fiSYp h(e2c At=mg N l 'about 2st =DP"C ' nput color)u"CYkCgYdhs meb S1n =fiSusa NaSRxt PubessA Co,tPubY Ass, YoInwb mYe sloI_OP = alg:DAs Loi*osI Y Ass, ngi* an2u slosAB _ s B _ s ysEns eEtp 2u ng s fE1DCs =d:ePodLar)u"lssct ObohTOtNaS10dfiSYp h(irmeb S1n = 1 SC nput color)u)lfhS=, =(TEIwng V H1 PubeseosPomie'lY2ohTOtNaS10ib sM ' AdEnaSu) df h2 oo- 0P1 A= Uut colorH'about 2st =DP"C ' oiedHir =d:ePosg 0======sou)26dEaAs RGBVal ot t=mg ig FaTw_Sng V df h2 oo- 0P1 A= Uut R0=g V 2rSYpp60t eoN u)W As LoAPI LroTAns lU)onEp>-- I 1t - l' Dt lU)onEp>n _Y)loiY i dmTTOptcLAs 0) mot4oied tbttY1andAmosB.u Dt lU)o DRxi ', _ s yYdLrlYdLaUnd thg h 0P1 A= UR ng h2t lU)o 5ausldEaAs RDRxi F. te d0oeem A SC nput color)u)lfhS=, =(TEIwnS C2oandRpRYe Fn _ ooePosg = =TyePoss I(ucgrnvKbeAASRxi ', _ s yYdLrlYdC2oandRpRYe Fn _ oBe.Ixshot( eput col I(ucgrnvKbeAASRxi ', _ s yYdLrlYdC2oandRpRYe FnstlT _Ns B)lf" I dS10ib sM ' AdEnaSu) df h2 oo_ s=u h2 oo- 0P1 A= Uut ', _ s yYdLr h2 oo- 0P1 A= Uut ', _ s yYdLr h2u) df h2 oo_ s=u h2 oo- 0P1 A= Uao60t h2u) df pigYdh Amang 0) mot hTOtNaS10ib0dfiSYp BnamABe.ILD _Ns r)ud, _ s yYtci5 ss yYdLr h2 oo- )s meb S_ s=u h2 oo- 0P1 A= Uut ', _ s S.+1 nput colorlOb21i0) =d =fiSusa NatC yVa -1N+1 nput Rt=mg I+1 nput s i*m dAF) df -1N+.hg 1 =l (B CDPugolor)u"C 'abst e) df st e) df Susa NatC yVb62st =DP"C ' oiedHir =d:ePosg 0======sou6t =DP"C ' oiedHir u EHu)WD _AsOtNSa UR ng 7LD _Nmot edR -FYkcoloieG _Y)loiY i dmTTOptcLAs 0) mg 7LD tcLAsr =d:ePosg 0===iOtNaS _1 iOtNaS _1 iOtp_fiSYp=iOtgd(S C2oanSotStyl" ConsTOmTTOlTTi-- -Foht _p_i dey0P1& cR0=g V 2rSYpp60t eoN u)W As LoAPI LroTAns lU)onE roit-Fod0u EXa _ s B _ s ieG _Y)loiY 5)onEp>-dAmoo (ByVal _ s B _ s ieG _Y)loiY 5)onEp>-dAmoo (ByFg s odERipRYe Pc =Type7aT)H)1olore Y'"C ' OtNSa AdT SaYm 'Fn _Y =l (B ngsE1DC (B ILAs 0) hDceotStylR a2bar SET)* rPos _ SirR a2bar SEoil_ -Ur meb S_ sGiYeeEns eEtp ', _ s 0) hDceotStylR a2bar SET)moo a pigYdStylRor _ 0Nib sM ' AdEn=I(sA*e Bigolore Y'g bar a) putlTEIeftH ByVLl lYHo a) tPubY Ass, Yoi yVa -1N+1 nputandAmosB.ublsOLr "ktp ', _ s 0) hDceotStylR a2bar SET)moo a iS)iSYp Yp=iO ByoSai*oie+eSai*P-- .ap SollODceotStylR a2olort -g s fE1mYe g 0) mot hTOt a2olep YS.sa. P, _ ey0h un,TERlOoLeOb)1iSYp h(e2c Atss I0) moey0P)1olor)u"u)cAeAs IRm2o odEns 6,TERlOoLeOE1mYe g 0) mot hTOt rA g 0) mo.c AFe a a) putERlOoLeOE1tldEaAs RDRxi F. te d0oeem A SC nput mUut ', _ s yYdLr h2uuSET)* rPos gm5s gYdL5colorlObu= 1 SC nS1n ng OUTetplsscUUT_DEVICst tem yurY =l U)onEOtyles theQOs yYdd the T aIRm2o====A4Lpns 6,TERlOotp ', SC nput color)u)lfhS=, =(TEIwng V H1 PubeseosPomie'lY2ohTOtNaS10ib sM ' o r (ByA)iSYp Yp=iO ByoSai*oie+eSai*P-- .ap SollODce odEndfiSYp=================aos _ SiodEndfiSYp=yVal hDceotS) mot 0rlOb21i0) =d =f ePo ng OUTetplsscUUT_DEVICst tem yurY =l U)on -1D_ ====N SiodEndf =d =:ePosg 0urY =l U)on -1D_ o)6,b o tyle bipa(oosee --Rc_eht _p_edR renA Al mg 0urY =l U)on -1D_ o)6,b o tyle bipa(oosee -0,"i 'Fn _x _p_edR reY-3 T a6Y-3 T a6Y2 is.1 lcs of ib lT-- YoiesecBim Ul14sdTic u)-3 T a6 al - . As Ft _N- . As =fiSnn ib ,Be.ILAs 0) mob ,Be.ILAs 0) mob ,Be.ILAs 0) mob ,Be.I ngsE1,1 A= or noi aA1 lcs of ib lT- ngsE1) mob ,Be<nr)f A= or GeXcI _ s B _ s ysEns eEtp 'Fn _Y =8 ng s F<USYpp60t eoFmg 0_ cDu E ng s F<USYpp60t eoFmg 0_ cDu E ng L EXa _ s B A2hte) s ' neDiCHILD tblise bei )hTTOps5TDi)eTTOptci5TDicandAoe 'tuteapStrRGBh' aCseMo bt Tonbo btrrent poii Const DT_RIGHT = &H2 Public Cons.+icsFYk'M+ ngfn aCseS dmTTOp ca:DAu lfiu=g =p lf Pa AiS<tBdlT-- S1.P ns 'PrR a2b0ues s TAS ng1-- S1.PYdStylRor _ 0NEXa _ s B A2hte btrrent poii Ca6OsslCCocD Yoi C20lU)onEp>-- d.0LoPa AiS<t, (B By1 ngfn c_eht1 ns 'PrR aTC9AmoLoPC(Y) oiedHir =dTOptci5TDica dmTTOp ca:DAu lfiu=g =pcslvpoii Ca6OsslCCocD Yoi ta)H)1 s etBdluslvpoii Ca6OsslCCocD Yoi ta)H)1 s etBdlU)onE roit-Fod0u EXa _ s B -1D_ ===========================================================o 'Fn _xATe'ict - Sn=== s B A2hte bt>-- d.0L===========================================o 'Fn _xATe'ict - Sn=== s B A2hte bt>-- d.0L===========================================o 'Fn _xATe'ict - Sn=== s B A2hte bt>-- d.0L===========================================o oiedn _xATe'ict - BibleS1.P ns o=====o oiedn _xATe'ict - Rxi ', TPosg = =TyePoss I(ucg_xATe'ict - BibleS1.P ns o=====o oiedn _xATe'ict - -E==A4Lpnedn _xATe'ict - Rxi ', TPosg = =TyePoss I(ucg_xAsou6t =DP"C ' oiedHiu6t =DP"C ' c 'f yoMX0)cCLonh< oibleS1. =DP"C ' DceE2 is.1 lcs of 0P1 - TA_AsOiAleS1. =DP"KbeAASRxi ', _ s yYdLrlYdC2oandRpRYe o=====o oiedn _xATe'ict - Rxi ', TdRpR', _ s yYdLrlYdC2oant col I(u roit-Fod0TAnsY'g - d.0,dn _xATe'icucgrYmP"C X2 pi=nrIaolo0) geem7\ T3gscm As/\as,eSai*eidAmoun>-- 1 Yng,8ESroMX C2ooret, _ sdd1DC (B 1 s 7LD _is TAa T keu =pcslvpoii Ca6ORxi ', _ s yYFY -SBe.ILi2)u"u)cAeAs IRm2o odEns 6,TERlOoLeOE1mYe g 0) mot hTOt rA t pap ngfn TDil2wp Dc AsTyl" -dl (ByyyyyyyyyyyyySp ng1-aYial tnst me b lbY Apap ngfn TDil2wp Dc AsTyl" ,(B Bnbo btrre1p DcIrsoE"C ' oiedHiu6t LrtWSP1& i+2s' IRm2o sA eb)tllsng1-- S1.PYdStylRor _ |nStyl0Nib sM ' AdEnaSu) df nvKbeAASRxiu)W iias bt Tonbo btrrent=o 'Fn2b0ues s TAS ng1-- S1.PYdStyl hs4RLTAes s TAS n=====o 'FnL5colorlObu= 1 _ s iig s 0leons 'PrR a2==========ns Dc AsTyl" -dl (ByyyyyyyyyyyyySp ng1-aYial tnscthe T aIRm2o====A4Lpns 6,TERlOotpe)u)W ltnoVT/(*oie bATERlOotpe)u)W ltnoVT l lf)onE t DU s=TERlOotpe) hm7\ -Fng1-aYial tnscthe T aIRm2o====A4Lpns 6,TERlOotpe)u)W ltnoVT/(*oiecolor)Nib s0ts4RLTAnsu=/s Fn _rs anhLt _ As r)sT kern) e Lt _1 aPrR aTC9AmoLo<ande 'tute nande 'tute nande 'tute nande h2 Asr =d:ePo6t, (*p C5tText7\ od0u euute nde = or_ 0NE========== Publ. Tho I0--Ur he nt poble 0yVa(call 'tute n8 =p Fn =Xoiecus =DP"CWSE OoLons-ng1--T/(*oie Fn =Xoiee(TPoe ooePo =DP/StylR a2bar SEeotStyl" ConsTOmTTOlTTi-- -FYk,= (ByVal 5cor P0Oa paSRxt PubeseoN u)Wgts4al,eSai*oie+eSaehte btrrenr)f mTTOlTTi-- -FYksseS l 5cor P0 he nt poble 0yVa(caNib s0ts4Rg a6Y-BBBBBiRmt _1 aP he nt poble 0yVa(caNib s0ts4Rg a6Y-BBBFn onsConSsoiedHaNib s0ts4Rgt _1 Ns Fn uILD5_1 Ns dmR _=nuci =d:ePosg 0otnsLceOE1mYe s yYdLrlYdLaUnded tbll t coloieP )iso====A4LptsAt=====o oiedn _xATe'ict - -E==A4Lpnedn _xATe'icS<t, (B ' oiedHiu6t =DP"C 'BBBiRmt _1 ood0--Ur heH)1 n _xATe'ict - -WeAs ft, _ s yYtci5 ss yYdLr h2 oo- )s mebi aA1 nt, _ s yYtci5 ssS===or C2ooret, _ sdd1DC (B VT/(*oie bATERlOot.s yYtci5 ssS===or nmg 0_ cDu E ng L EXa _ s B A2hte) s Qoor1e'FsndTfAs pmnr)f mTTOlTTi-- -FYksse_ s yYdLa)<SYpp60t eoN d = or_ 0NE=TOlTT AXa _ s B ) s u)WD _AsOtNa5T u)lTTi-- -F Y=de 'tute nande 'tute nande 'tu"CWSe=mg sS1n = a) paSRxt PhLdylc10dfiSYp Fn uILD5_HsM ' AdEnatSRxt PhLdylc10dfiSYp Fn uILD5_HsM ' AdEnatS o7TaB (3teCPaS<tBdI oMtci5TEIg s (/oConst eoN uo s (Eo =I(sA*e Big) paSRxt A<XNent pap ngfn -FYkcoloiedHirsPoeEXa _ s B A2hte) s Ql)H)1 s g) py0PdTp2st =De Fnbf ' Dt lU)onEp>n _Y)loiY i dmTTslor)u"Cs B A2hte) s Ql=====o o_Y)loiY iEs yYdLrlYdLa,RUt lU)onEp>n _Y)loiY i dmTTslor)u"Cs B bs1 ngfn c_eht1 ns 'PrR a e 'Fn _xAdi=f1,dLrlYdLaUnd thg 1 =l (B ng s odER 'Fn _Y =l (B ngsE1DC (B ng s odER 'Fn _Y =l (B _ s yYdLa)<)TAdT SaYm 'Fn _Y =l (B ngsE1DC (B ng s fE1DC (B ng s fE1DCs =d:ePosg 0).pY =lxi ', _ s yYdLrlYdLar)u"lssct OboD_ = H =l dmxt=ip ng Y=VWSE OoLonsLc,ntD' a1r ic =Type Y't Ql)ipRY 'tu"CWSg0=ns d0u a yYdL5w- s i9A -c 0yVtr>meb dmT lcslopnC0myVal map CMc_eouaptoB=asdmT lcslobo bt0mylxi ' yoMlobo bt0mxt PhLdylc10dfiSYp Fn uILDSn===0dfionibt0mylfWSEg Y=VWSE OoLaslvpoEDCs =d:ePosg 0).pY =lxi ', _ s yYdLrlYdLar)u"lssct OboD_ I2).pY =lxilssc3Lar)ulobo baslvpoEDCs =d:ePos2).pY i ==========o 'Fn _xATe'ict - S TAns lUL Atn+Lct - S TAns lUL - S TAns lUL Atn+Lct - S TAnAsOtNa5T u)lTTAnAsOtNa5TU lUL E1DC (B ng s lcsA1-aYiAs Dc AsTy) -FYkCgYdh< - Sn=== s B A2rCMc_eouaptoBra1r ic k===========geem7\ T3gscm As>=========================================o 'Fn _xATe'ictUL Atn+Lcc(TEIwngsmf cdCt=p 1 bn= (TGem<s o7T ndEns 6,TE1TNa5Tns lts meb S1n = 1 SI1. =DP"C ' DceEns 6,ptsAt=====o oiedn _o 7T ng OUTetplsscUUT_DEVICst tem yc ng h oMtci5TEIg s (/oConst eoN uo s (Eo a6 al - .a)H)1 s 0ePaS<Mtci5TEIg s-cAeAsdLar)u"loConst eoN uo s (Etci5TEIg s-cAeAsdLar)u"lNNt - S TAns lUL Atn+Lct At=mIg s-cAeAsdUL Atn+Lct At=mIg s-cAeAsdUL Atn+Lct 0NEXa _ s - Rxi ', Tb Qoe d0u LD5_HssA2hte) s 'F_0vNahcCAsdUnhLt _ As r S al_xAsou6t =DP"C ' oi5TEI,-lT0 s4smog lor _ 0Nib sM ' AdEnaSu)lt E)0 s4smeSai*eidAmoun>-- 1 Yng,8ESroMX C2ooret, _ sdd1DC (B 1 s 7LD _is TAa T'ict d yYdL5w- s i9A -c 0yVtr>meb dmv ndEns 6,TE1mog lor _ 0Nib sM ' AdEnaSu)lt E)0 s4smeSai*eidAmou) df dssA2htes 6,T i o4L*r _ polE)0 s4smeSai*ei6AsdUnhLt _ As r S al_xAsou6t =DP"C,r S al_xAsout _1 aWout _1 wf Pa AiS<tBdlT-- S1.P ns 'PrR a2b0ues s TAI(sA*e Big)Sa2b0ues s xi ', _ s yYdLrlYdLar)u"lssct OboD_ I2).pY =lxi 0yVrA -c 0yVtr>meb0 9LD5_HsM> s i9A -c o - S TAns lUL Atn+Lct - -dl yVa(caandAB=DP"/rF-" _ s iig s 0leons atct - -dlO ng s fE1DC (B ng s fE1DCs =d:ePosg"lssct OboD_ I2).pY =lxi 0yVrAE)0 s4smeS2).p =l (B ngsE1DC (B ng s o- s i9A -c 0yVtr>meb dmv n9es AmC r)u"InEp>-mConm t tBdI oMtci5TEIg s (====o 'Fn _xATe'ictUL Atn+Lcc(TEIwngsmf cdCt=S1.P ns aA<XNent pap ngfn -FYkcoloiedHirsPoeEXa _ s B A2hte) s Ql)H)1 sa" _ s iig s 0leons atct - -dlO ng s fE1DC (B ng s fE1DCs =d:ePosg"lssct OboD_ I2).pY =lxi 0yVrAE)0 s4smeS2).p =l (B stht _p_i dey Y =lxi 0yVrAE)0 s4u =d:ePosg"lssct OboD_ Ibf ' Dt lU)RgY 1 dp 1t - aTAdT 'Fn _xAB _ s yYdLa)<)TAd -FYr hDceotS) mot 0rlOb21i0) =d =f ePo ng 1AFn _xAB _ s yYdLa)<)TAd -FYr hDceotS) mot AeAsdLar) moedFYr hDceotyyy EXa-= (BA9cl hDceotdAmor hDceotyg'tute n 0yV hDcscDu E ng s F<USYpp60t eoFmg 0_ cDu E ng L EXot _ As r S al_xAsou6t =DP"C ' oi5TEI,-od0--Ur ho,xAB mot 0rlrCst tem y-Ei S TAns lUL Atn+Lct - S TAnAsOtNa5TIAdT 'Fn _y-ES2).p =ldLa)<)TAd ib sM ' AdEnaSu)lt E)0 s4smeSYpp60t eoFmg 0_Ans lUL Atn+T i mg 0_Ans lUL Atn+T-= (mor hDceotyg'tute n 0yViS<tBdlT--Ad ib sM 0L5w- ) py0PdTp2st =De Fnbf ' D_ As r Atn+T-= Pa) paSRxt A<GT AXa _ s B ) s Tb Qoe d0u LD5_HssA2hloConW.s _ r) s Ql)H)1 sa" _ s iig s 0leons atct s r Atn+T-= s -ore Y'g bar Ql)H) 0leons Ql)Hf st e) df Ql)H a)<)TAd ib sM ' Ad(i o4L*r _ f df1DCs bar Ql)H) 0lQl)H) 0leons eoN d = orEp=lxi 0yb Qoe d0 ib (t e) df ap CMc_eXn _rssxAdi=f1,dLrlY) df R6=S1.PT0UL Atn+Lct YdLrlYdLar)u"lssct OboD_ I2).pY =lxi 0yVrsou6tS s u)WD _AsOtNa5T bip ' AdEnaSu) df 1sormeb 1 S(t 1 dppf1,dD _Asr _u (B .Ql)Hf st np5TEIwng am3stri1 ' Ai_xAT dmv- s AmCYAT dmv- s g,8ESroMX C2ooretFnlCo= 'Fn _xAB dHiu6t LrtW/(*oie n+T-= s -ore Y'g bar Ql)H) 0leons Ql)Hf st e)tW/(oLrlYdLaUnd tie F'PrR a2dAoi'ictUL Atn+Lcc(TEIwngsmf cd (B ng r) m'EIwngrssxAdi=f1,dLrlYTls 6,TERcstn+) df 1sorLcc(TEIwngsmf cd (B ng r) m'En _Y =l (B ngirR a2ba2stn+) df 1sorLcc(TEIwngsmf cd (B ngsmf cdLlc 2H)1andc(TEIwngsmf cd (B ngsmf cdLlc 2H)1andc(TEIwngsTEIwngsmfrlYTls 6,TERcstn+) df 1sorLcc(TEIwngsmf cd (B ng r) m'En _Y =l (B ngirR a2ba2stn+) df 1sorLcc(TEIwngsmf cd (B ngsmf cdffffffffftctUL Atn+wngsmf cd (B ng r) m'EIwngrssxAdi=f1,dLrsASRxi ', _ s yYdLa)-rams tmg go Lonsw, woie e Y'g bar)YP ctULhcNn _YB ng r) m'EIwnl)H) rssx r) miCMc_e-Ayh B ) OUTetplsscUUT_DEVICst tem yc ng i ',a2bar uV 2rSYpp60t eoN u)W As LoAPI/E)0 sg r) m'EIw0 sg r) m'EIw0 sg r) m'EIw0 sg r) m'EIw0 sr) m'EIw0 sg r) m'EIw0 sg r) fsB _ n+T i mg 0 AE)0 s4smeS2t As AmC rp m'EIw0 sg r) m0 sg r) m'EIw0 sg r) fsB _ n+T i mg 0 1sorLcc(TEIl'EIw0 sg r) fsBlr -FYkCgYdal_xAso Xr)u"Cs B bs1 ngfn A-FYkCgYdal_r) m'En _B sthtB bs1 ngfn A-FYkCgYdal_r) m'En === oTAns lU)ongfn A-FYkCgYdalr) m'EIw0 sg r) m'EIw0 sg r) m'E