iF YOU LOOK THIS UP THERE ARE ALL KINDS OF FLAGS AND STYLES AND YOU CAN ENTER OR USE IT MANY TIMES
IN MY DRAWITEM I PLACED IT SEVERAL PLACES SO IT WOULD BE THERE ON MOUSE OVER AND MOUSE CLICK'
Code:
DrawEdge @lpDis.hDC, @lpDis.rcItem, %BDR_RAISEDINNER OR %BDR_RAISEDOUTER OR %EDGE_RAISED, %BF_RECT DrawEdge @lpDis.hDC, @lpDis.rcItem, %BDR_RAISEDINNER OR %BDR_RAISEDOUTER OR %EDGE_RAISED, %BF_RECT
WINDOWS NT WIN32API SUPERBIBLE by Richard J Simon SAYS.
Draw one or more edges of a rectangle. The edges are drawn using 3d effects'
use before edge draw
B = button
M = menu
P = popup - aka submenu
[/code]
IF BMP = "B" THEN
DrawFrameControl @lpDis.hDC, @lpDis.rcItem, %DFC_BUTTON, %DFCS_BUTTONPUSH Or %DFCS_PUSHED OR %DFCS_MONO ' on click
ELSEIF BMP = "M" THEN
DrawFrameControl @lpDis.hDC, @lpDis.rcItem, %DFC_MENU, %DFCS_MONO ' on click
ELSEIF BMP = "P" THEN
DrawFrameControl @lpDis.hDC, @lpDis.rcItem, %DFC_popupmenu, %DFCS_MONO
END IF
control handle cb.hndl, %BUT_File to hButton
control handle cb.hndl, %BUT_Help to lButton
HMENU = colorsubmenu(CBLPARAM)
Control Handle CB.Hndl, %BUT_FILE To mButton
' CONTROL HANDLE CB.HNDL, %BUT_HELP TO NBUTTON
case %wm_drawitem
if cb.wparam = %BUT_File then
DrawButton2 "B", hButton, cb.lparam, FC, BC, bg, Txtt, brd
end if
if cb.wparam = %BUT_Help then
DrawButton2 "B", lButton, cb.lparam, FC, BC, bg, Txtt, brd
end if
' if cb.wparam = %IDM_FILE_NEW then
' DrawButton lButton, cb.lparam, FC, BC, bg, Txtt, brd
' end if
' DRAWMENU(CBWPARAM, CBLPARAM)
if cb.wparam = 0 then
DrawButton2 "M", MBUTTON, cb.lparam, FC, BC, bg, Txtt, brd
' DrawButton2 "P", MBUTTON, cb.lparam, FC, BC, bg, Txtt, brd
end if
if cb.wparam = 0 then
' ' DrawButton2 MBUTTON, cb.lparam, FC, BC, bg, Txtt, brd
' DrawButton2 NBUTTON, cb.lparam, FC, BC, bg, Txtt, brd
' end if
[code]
it colors the menu bar all submenu items
Thanks
Leave a comment: