Hack S4 League
Welcome To HS4L-en
*-*-*-*-*-*-*-*-*-*-*
If you Still new Register please And if you already registred Login Thank you !

Forum Staff !

How to put color to a checkbox.

View previous topic View next topic Go down

How to put color to a checkbox.

Post by ZzcarloszZ on Sun Aug 14, 2011 4:41 am

First we need these codes:
background:
Code:

Func GUICHECKBOXSETCOLOR(ByRef $CTRLID, $ICOLOR, $IBKCOLOR = "0xF1EDED")
   $CTRLHWND = $CTRLID
   If Not IsHWnd($CTRLHWND) Then $CTRLHWND = GUICtrlGetHandle($CTRLID)
   $APARENT = DllCall("user32.dll", "hwnd", "GetParent", "hwnd", $CTRLHWND)
   $ACPOS = ControlGetPos($APARENT[0], "", $CTRLID)
   $SOLDT = GUICtrlRead($CTRLID, 1)
   GUICtrlDelete($CTRLID)
   DllCall("uxtheme.dll", "none", "SetThemeAppProperties", "int", 0)
   $CTRLID = GUICtrlCreateCheckbox($SOLDT, $ACPOS[0], $ACPOS[1], $ACPOS[2], $ACPOS[3])
   GUICtrlSetColor(-1, $ICOLOR)
   GUICtrlSetBkColor(-1, $IBKCOLOR)
   DllCall("uxtheme.dll", "none", "SetThemeAppProperties", "int", 7)
EndFunc
and in our script we can put this:
Code:
$Checkbox1 = GUICtrlCreateCheckbox("Speed x15", 168, 112, 105, 17)
GUICHECKBOXSETCOLOR($CHECKBOX1, 0, -2)
Font Color:
Code:
Func Guichecboxcolor($ID)
DllCall("UxTheme.dll", "int", "SetWindowTheme", "hwnd", GUICtrlGetHandle($ID), "wstr", 0, "wstr", 0)
GUICtrlSetColor($ID, 0xFCEC2E)
EndFunc
Ejpm:
Code:
$Checkbox1 = GUICtrlCreateCheckbox("Beta Spawn", 248, 304, 89, 17)
Guichecboxcolor($CHECKBOX1)
By ZzcarloszZ

ZzcarloszZ
Admin
Admin

Posts : 11
Join date : 2011-08-02
Location : Perú

View user profile

Back to top Go down

View previous topic View next topic Back to top

- Similar topics

 
Permissions in this forum:
You cannot reply to topics in this forum