Link to home
Start Free TrialLog in
Avatar of mahtieubrault
mahtieubrault

asked on

Subclassing scrollbars in list and tree controls

How can I subclass the scrollbar inside a CListCtrl or a CTreeCtrl.  The method GetScrollBarCtrl returns NULL. My lists and tree are very nice but I'm stuck with ugly gray scrollbars. I only I could get a hold on it...
Avatar of antoinebf
antoinebf

From my limited experience (it's also been a while...), you have to implement your own... and draw them on top of those grey ones... It's a nice hack, but then again, what isn't in windows...

"That custom scroll bar would then relay the scroll messages directly to treectrl. We also had to implement all the displays of the scrollbar (thumb, buttons, etc.)"
  - cyberbum

I'll try to find my old stuff and mail some useful info from it to you...

A.
Avatar of mahtieubrault

ASKER

Thanks Tony,

Do I have to paint after the WN_NCPAINT ?
From my limited experience (it's also been a while...), you have to implement your own... and draw them on top of those grey ones... It's a nice hack, but then again, what isn't in windows...

"That custom scroll bar would then relay the scroll messages directly to treectrl. We also had to implement all the displays of the scrollbar (thumb, buttons, etc.)"
  - cyberbum

I'll try to find my old stuff and mail some useful info from it to you...

A.
From my limited experience (it's also been a while...), you have to implement your own... and draw them on top of those grey ones... It's a nice hack, but then again, what isn't in windows...

"That custom scroll bar would then relay the scroll messages directly to treectrl. We also had to implement all the displays of the scrollbar (thumb, buttons, etc.)"
  - cyberbum

I'll try to find my old stuff and mail some useful info from it to you...

A.
ASKER CERTIFIED SOLUTION
Avatar of antoinebf
antoinebf

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial