i am not working with dialogbox, (i don't like it jet ) ...
i create it with CreateWindowEx ... and i want to change the font of the botton...
i create it with CreateWindowEx ... and i want to change the font of the botton...
i gonna answer my self...:grin:
i mean FONT no TEXT
i create a FONT on my aplication with Createfont
---------------------------------- code --------------------------------------
.ELSEIF uMsg==WM_CREATE <----------------------------- on the create message of the window
invoke CreateFont,16,6,0,0,500,0,0,0, \
DEFAULT_CHARSET,0,0,0,\
DEFAULT_PITCH,ADDR font1
mov hfont, eax
--------------------------------------------------------------------------------
where:
font1 db 'Arial' <----------------- the name of some FOnt installed on the machine (of course ARIAL is it! )
hfont dd ? <----------------- and with this handle we can send it a message to any objec like editbox,listbox,buttons...etc (common controls)
then we send a message to our control
invoke SendMessage,hwndEdit,WM_SETFONT,hfont,1
and that's it ...the control will have the font you like :grin:
i mean FONT no TEXT
i create a FONT on my aplication with Createfont
---------------------------------- code --------------------------------------
.ELSEIF uMsg==WM_CREATE <----------------------------- on the create message of the window
invoke CreateFont,16,6,0,0,500,0,0,0, \
DEFAULT_CHARSET,0,0,0,\
DEFAULT_PITCH,ADDR font1
mov hfont, eax
--------------------------------------------------------------------------------
where:
font1 db 'Arial' <----------------- the name of some FOnt installed on the machine (of course ARIAL is it! )
hfont dd ? <----------------- and with this handle we can send it a message to any objec like editbox,listbox,buttons...etc (common controls)
then we send a message to our control
invoke SendMessage,hwndEdit,WM_SETFONT,hfont,1
and that's it ...the control will have the font you like :grin:
o :)
I thought you meant to say front of the button :o
my bad, sorry
I thought you meant to say front of the button :o
my bad, sorry
i gonna answer my self...:grin:
i mean FONT no TEXT
i create a FONT on my aplication with Createfont
---------------------------------- code --------------------------------------
.ELSEIF uMsg==WM_CREATE <----------------------------- on the create message of the window
invoke CreateFont,16,6,0,0,500,0,0,0, \
DEFAULT_CHARSET,0,0,0,\
DEFAULT_PITCH,ADDR font1
mov hfont, eax
--------------------------------------------------------------------------------
where:
font1 db 'Arial' <----------------- the name of some FOnt installed on the machine (of course ARIAL is it! )
hfont dd ? <----------------- and with this handle we can send it a message to any objec like editbox,listbox,buttons...etc (common controls)
then we send a message to our control
invoke SendMessage,hwndEdit,WM_SETFONT,hfont,1
and that's it ...the control will have the font you like :grin:
Since that is MASM syntax, you might get a quicker answer in the
MASM32 area :-) At least if you're looking for a MASM solution.
Cheers,
Randy Hyde