05-15-2013, 02:05 PM
Replace
f.SetDialogFontColor
to
DT_SetTextColor
Function Dialog124
f.SetDialogFontColor
to
DT_SetTextColor
Function Dialog124
\Dialog_Editor
function# hDlg message wParam lParam
if(hDlg) goto messages
if(!ShowDialog("Dialog124" &Dialog124 0)) ret
;BEGIN DIALOG
;0 "" 0x90C80AC8 0x0 0 0 223 135 "Dialog"
;3 Static 0x54000000 0x0 10 14 80 38 "Text"
;4 Static 0x54000000 0x0 110 46 48 12 "Text"
;1 Button 0x54030001 0x4 120 116 48 14 "OK"
;2 Button 0x54030000 0x4 170 116 48 14 "Cancel"
;END DIALOG
;DIALOG EDITOR: "" 0x2030503 "*" "" "" ""
ret
;messages
sel message
,case WM_INITDIALOG
,__Font-- f.Create("Comic sans ms" 30 1) f2.Create("Arial" 9 2)
,f.SetDialogFont(hDlg "3")
,f2.SetDialogFont(hDlg "4")
,
,DT_SetTextColor hDlg 0xFF0000 "3"
,DT_SetTextColor hDlg 0xC0 "4"
,
,__GdiHandle- t_brush=CreateSolidBrush(0x00CCFF) ;;create brush of random color
,__GdiHandle- t_brush2=CreateSolidBrush(0x009900) ;;create brush of random color
,
,DT_SetBackgroundColor hDlg 2 0xff8080 0xf0f0f0
,
,case WM_DESTROY
,case WM_COMMAND goto messages2
,
,case WM_CTLCOLORSTATIC
,;out GetDlgCtrlID(lParam)
,sel GetDlgCtrlID(lParam)
,,case 3
,,SetBkMode wParam 1 ;;draw text transparently
,,ret t_brush
,,case 4
,,SetBkMode wParam 1 ;;draw text transparently
,,ret t_brush2
ret
;messages2
sel wParam
,case IDOK
,case IDCANCEL
ret 1