Search found 232 matches

by kcvinu
Mar 15, 2021 9:56
Forum: Beginners
Topic: How to change the back color of a control at runtime ?
Replies: 43
Views: 6575

Re: How to change the back color of a control at runtime ?

Here is the three types of button i have created.
1 - flat color button
2 - gradient button
3 - normal button.
Image here - https://drive.google.com/file/d/1sJmWZH ... sp=sharing
by kcvinu
Mar 15, 2021 9:43
Forum: Beginners
Topic: How to change the back color of a control at runtime ?
Replies: 43
Views: 6575

Re: How to change the back color of a control at runtime ?

@jj2007, The NMCUSTOMDRAW structure is defined in commctrl.h header file. typedef struct tagNMCUSTOMDRAWINFO { NMHDR hdr; // HWND, id, etc. DWORD dwDrawStage; HDC hdc; RECT rc; // We don't need to call GetClientRect DWORD_PTR dwItemSpec; UINT uItemState; // btn mouse hover, click, normal state LPARA...
by kcvinu
Mar 15, 2021 0:50
Forum: Beginners
Topic: How to change the back color of a control at runtime ?
Replies: 43
Views: 6575

Re: How to change the back color of a control at runtime ?

@Josep Roca,
After 3 years of this post, I finally found the answer to my question.NM_CUSTOMDRAW is the answer. It comes with WM_NOTIFY message. All we need to do is get the LPNMCUSTOMDRAW struct from Lparam and change the button back color. This is far easy from owner draw buttons.
by kcvinu
Feb 23, 2021 18:35
Forum: Windows
Topic: Ho to show a normal window as modal window ?
Replies: 1
Views: 961

Ho to show a normal window as modal window ?

Hi all, I am trying to mimic the dot net method "Form.ShowDialog()" in my gui library hobby project. After a few hours of google search, i came to know that i need to use EnableWindow function to achieve this. Means, disable all other windows when my ShowDialog is called and enable all tho...
by kcvinu
Jan 12, 2021 13:43
Forum: Beginners
Topic: What is the FB equivalent to Vector in C++ ?
Replies: 4
Views: 931

Re: What is the FB equivalent to Vector in C++ ?

@VANYA, Thanks. Let me check.
@ adeyblue, Thanks, Let me check. Yeah, syntax looks weird.
@caseih, Thanks.
by kcvinu
Jan 11, 2021 19:11
Forum: Beginners
Topic: What is the FB equivalent to Vector in C++ ?
Replies: 4
Views: 931

What is the FB equivalent to Vector in C++ ?

Hi all,
I just went through FB Wiki pages and found "C/C++ vs. FreeBASIC syntax comparison". But i couldn't find anything related to vector. What is the FB equivalent to Vector in C++ ? Thanks in advance. :)
by kcvinu
Jun 07, 2020 21:53
Forum: Projects
Topic: FreeBasic IDE-poseidonFB(Update 2024.03.03)
Replies: 1283
Views: 361815

Re: FreeBasic IDE-poseidonFB(Update 2020.06.05)

@Kuan Hsu,
Thanks for the reply. I will check it. :)
by kcvinu
Jun 07, 2020 15:05
Forum: Projects
Topic: FreeBasic IDE-poseidonFB(Update 2024.03.03)
Replies: 1283
Views: 361815

Re: FreeBasic IDE-poseidonFB(Update 2020.06.05)

Hi @Kuan Hsu,
Any activities in PoseidonD ? Is there any updates ?
by kcvinu
Dec 13, 2019 13:17
Forum: Windows
Topic: How to get the message time from message structure ?
Replies: 9
Views: 2570

Re: How to get the message time from message structure ?

Thank you everyone for the replys. :) Sorry for the late reply.
by kcvinu
Nov 28, 2019 8:21
Forum: Windows
Topic: How to get the message time from message structure ?
Replies: 9
Views: 2570

Re: How to get the message time from message structure ?

@SARG ,
Thanks for this reply. Let me try. :)
by kcvinu
Nov 27, 2019 15:55
Forum: Windows
Topic: How to get the message time from message structure ?
Replies: 9
Views: 2570

How to get the message time from message structure ?

Hi all, Forgive me if this question is already asked. I would like to know how to get the message time from the MSG structure in win32 Gui programming ? I just tried this in the " GetMessage" function. But since, it's a DWORD, i only get big number. TranslateMessage(imsg) DispatchMessage(i...
by kcvinu
Nov 23, 2019 15:52
Forum: Windows
Topic: How to implement mouse single click & double click events
Replies: 2
Views: 1363

How to implement mouse single click & double click events

Hi all, I am playing with some win32 api gui code. Now, i would like to create a mouse click & double click event for my gui library. I've read that one would need to deal with four type of mouse messages to implement this feature. For a single click - WM_LBUTTONDOWN WM_LBUTTONUP And for a doubl...
by kcvinu
Oct 19, 2019 22:33
Forum: Documentation
Topic: How and Why to make Abstraction by Object Encapsulation, with FB Syntax in UDTs (basics)
Replies: 19
Views: 7392

Re: How and Why to make Abstraction by Object Encapsulation, with FB Syntax in UDTs (basics)

I quit freebasic coding for about two years. But when i came back, what i can see is such great posts and comments. I feel sad that it's too late to read this. Thanks for this post.
by kcvinu
Oct 22, 2018 20:44
Forum: Windows
Topic: OWNER DRAW Button painting problem
Replies: 3
Views: 1150

Re: OWNER DRAW Button painting problem

@jj2007, At last, I found the problem !! It was the second parameter of the InvalidateRect() function. In wm_mousemove and wm_mouseleave msgs, i call this IvalidateRect with second parameter as "NULL". After a long time virtual debugging, i found that it accepts the rect of the control. No...