January 1, 2005

WinTask - GetSystemColors

'
' GetSystemColors
'
' Author: Joe Strazzere
'

'Declare Function GetSysColor Lib "user32" Alias "GetSysColor" (ByVal nIndex As Long) As Long
'
Dim Sysm$(100)
Sysm$(0)="Scrollbar"
Sysm$(1)="Background"
Sysm$(2)="Active Caption"
Sysm$(3)="Inactive Caption"
Sysm$(4)="Menu"
Sysm$(5)="Windows Background"
Sysm$(6)="Window Frame"
Sysm$(7)="Window Text"
Sysm$(8)="3D Dark Shadow"
Sysm$(9)="Text in Window Caption"
Sysm$(10)="Border of Active Window"
Sysm$(11)="Border of Inactive Window"
Sysm$(12)="Background of MDI Desktop"
Sysm$(13)="Selected Item Background"
Sysm$(14)="Selected Menu Item"
Sysm$(15)="Button Face"
Sysm$(16)="3D Shading of Button"
Sysm$(17)="Gray Text, or zero if dithered"
Sysm$(18)="Button Text"
Sysm$(19)="Text if Inactive Window"
Sysm$(20)="3D Highlight of Button"
Sysm$(21)="#21 ?"
Sysm$(22)="#22 ?"
Sysm$(23)="#23 ?"
Sysm$(24)="#24 ?"
Sysm$(25)="#25 ?"
Sysm$(26)="#26 ?"
Sysm$(27)="Win98: 2nd Active Window Color"
Sysm$(28)="Win98: 2nd Inactive Window Color"
i=0
while i < 28
  comment(Str$(i)+" "+SysM$(i)+": "+Str$(External("user32","GetSysColor",i)))
  i=i+1
Wend