home *** CD-ROM | disk | FTP | other *** search
- Attribute VB_Name = "dwTypes"
- ' Desaware API Class object library
- ' Copyright (c) 1996 by Desaware Inc.
- ' All rights reserved
- ' Type declarations and Global Utilities
-
- Option Explicit
-
- #If Win32 Then
- Public Type RECT
- left As Long
- Top As Long
- right As Long
- bottom As Long
- End Type
-
- #Else
- Public Type RECT
- left As Integer
- Top As Integer
- right As Integer
- bottom As Integer
- End Type
-
- #End If 'WIN32 Types
-
- #If Win32 Then
- 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
-
- #Else
- Type DEVMODE ' 68 Bytes
- 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
- End Type
-
- #End If
-
-
- #If Win32 Then
-
- Type ACL
- AclRevision As Byte
- Sbz1 As Byte
- AclSize As Integer
- AceCount As Integer
- Sbz2 As Integer
- End Type
-
- Type SECURITY_DESCRIPTOR
- Revision As Byte
- Sbz1 As Byte
- Control As Long
- Owner As Long
- Group As Long
- Sacl As ACL
- Dacl As ACL
- End Type
- #End If
-
- #If Win32 Then
- Public Type SIZE
- cx As Long
- cy As Long
- End Type
-
- #Else
-
- Public Type SIZE
- cx As Integer
- cy As Integer
- End Type
-
- #End If 'WIN32 Types
-
- #If Win32 Then
- Public Type POINTAPI
- x As Long
- y As Long
- End Type
-
- #Else
- Public Type POINTAPI
- x As Integer
- y As Integer
- End Type
-
- #End If 'WIN32 Types
-
- #If Win32 Then
- Public Type LOGPEN
- lopnStyle As Long
- lopnWidth As POINTAPI
- lopnColor As Long
- End Type
-
- #Else
- Public Type LOGPEN
- lopnStyle As Integer
- lopnWidth As POINTAPI
- lopnColor As Long
- End Type
-
- #End If 'WIN32 Types
-
- #If Win32 Then
- Public Type CPINFO
- MaxCharSize As Long
- DefaultChar(MAX_DEFAULTCHAR) As Byte
- LeadByte(MAX_LEADBYTES) As Byte
- End Type
-
- #Else
- 'TYPE CPINFO is not available in the WIN16 API.
- #End If 'WIN32 Types
-
- #If Win32 Then
- Public Type LOGBRUSH
- lbStyle As Long
- lbColor As Long
- lbHatch As Long
- End Type
-
- #Else
- Public Type LOGBRUSH
- lbStyle As Integer
- lbColor As Long
- lbHatch As Integer
- End Type
-
- #End If 'WIN32 Types
-
- #If Win32 Then
- Public Type SYSTEMTIME
- wYear As Integer
- wMonth As Integer
- wDayOfWeek As Integer
- wDay As Integer
- wHour As Integer
- wMinute As Integer
- wSecond As Integer
- wMilliseconds As Integer
- End Type
-
- #Else
- 'TYPE SYSTEMTIME is not available in the WIN16 API.
- #End If 'WIN32 Types
-
- #If Win32 Then
- Public Type SYSTEM_POWER_STATUS
- ACLineStatus As Byte
- BatteryFlag As Byte
- BatteryLifePercent As Byte
- Reserved1 As Byte
- BatteryLifeTime As Long
- BatteryFullLifeTime As Long
- End Type
-
- Public Type OSVERSIONINFO
- dwOSVersionInfoSize As Long
- dwMajorVersion As Long
- dwMinorVersion As Long
- dwBuildNumber As Long
- dwPlatformId As Long
- szCSDVersion As String * 128
- End Type
-
- #Else
- 'TYPE SYSTEM_POWER_STATUS is not available in the WIN16 API.
- 'TYPE OSVERSIONINFO is not available in the WIN16 API.
- #End If 'WIN32 Types
-
- #If Win32 Then
- Public Type LOGFONT
- 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(LF_FACESIZE) As Byte
- End Type
-
- #Else
- Public Type LOGFONT
- lfHeight As Integer
- lfWidth As Integer
- lfEscapement As Integer
- lfOrientation As Integer
- lfWeight As Integer
- lfItalic As String * 1
- lfUnderline As String * 1
- lfStrikeOut As String * 1
- lfCharSet As String * 1
- lfOutPrecision As String * 1
- lfClipPrecision As String * 1
- lfQuality As String * 1
- lfPitchAndFamily As String * 1
- lfFaceName As String * 32
- End Type
-
- #End If 'WIN32 Types
- #If Win32 Then
- Public Type BITMAP
- bmType As Long
- bmWidth As Long
- bmHeight As Long
- bmWidthBytes As Long
- bmPlanes As Integer
- bmBitsPixel As Integer
- bmBits As Long
- End Type
-
- #Else
- Public Type BITMAP
- bmType As Integer
- bmWidth As Integer
- bmHeight As Integer
- bmWidthBytes As Integer
- bmPlanes As String * 1
- bmBitsPixel As String * 1
- bmBits As Long
- End Type
-
- #End If 'WIN32 Types
-
- #If Win32 Then
- Public Type HANDLETABLE
- ObjectHandle(1) As Long
- End Type
-
- Public Type ENHMETARECORD
- iType As Long
- nSize As Long
- dParm(1) As Long
- End Type
-
- #Else
- Public Type HANDLETABLE
- ObjectHandle As String * 512
- End Type
-
- #End If 'WIN32 Types
-
- #If Win32 Then
- Public Type MEMORYSTATUS
- dwLength As Long
- dwMemoryLoad As Long
- dwTotalPhys As Long
- dwAvailPhys As Long
- dwTotalPageFile As Long
- dwAvailPageFile As Long
- dwTotalVirtual As Long
- dwAvailVirtual As Long
- End Type
-
- #Else
- #End If 'WIN32 Types
-
- ' Utility function for creating a point easily
- Public Function MakePoint(ByVal x As Long, ByVal y As Long) As dwPoint
- Dim pt As New dwPoint
- With pt
- .x = x
- .y = y
- End With
- Set MakePoint = pt
- End Function
-
-