1. Win32Lib: change thumb color on Scroll control?

I put a HScroll in a window (not attached to the window, but in it), and I would like to change the color of its thumb and up/down buttons to match the window's integral scroll. I find that "setWindowBackColor" will actually change the color of the inside of the scroll control (the white area the thumb slides in), but I don't want to change that, but rather the thumb & up/down buttons. Any way to do that???

Dan

new topic     » topic index » view message » categorize

2. Re: Win32Lib: change thumb color on Scroll control?

DanM said...

I put a HScroll in a window (not attached to the window, but in it), and I would like to change the color of its thumb and up/down buttons to match the window's integral scroll. I find that "setWindowBackColor" will actually change the color of the inside of the scroll control (the white area the thumb slides in), but I don't want to change that, but rather the thumb & up/down buttons. Any way to do that???

Dan

Short answer is: none, even using the more flexible FlatScrollBar control, which Vista is reported not to support nativekly.

Long answer is: create a custom control, the likes of GroupAdv.

A friend of mine called Google brought me this, which amoubnts to creating such a control. The code is VB, but sems to translate in a straightforward way to Eu+win32lib:

http://www.eggheadcafe.com/community/aspnet/2/10060475/change-windows-default-sc.aspx

I don't think GDI+ is a requirement.

Another route would be to wrap the JScrollBar control, but I'm not aware of any attempts to wrap JScript related controls.

CChris

new topic     » goto parent     » topic index » view message » categorize

3. Re: Win32Lib: change thumb color on Scroll control?

ok, it wasn't very important anyway, so I'll forget about it for now, thanks. Turns out I needed to make BOTH scroll bars be not attached to the main window, so they both match now anyway.

Dan

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu