LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Color of selected tab panel tab

Solved!
Go to solution

Hello all,

 

I'd like to know the orange like color of the upper part of a selected tab panel tab, see the picture below.

 

tab-color.jpg

 

Actually, these are two colors, orange and a darker, 'shaded' orange. I don't mind which color value I can obtain, but I'd like to use the same color for other controls (LED, decoration frame) as well.

 

Does this color depend on the Windows theme? If so, I'd be happy about a possibility of obtaining this property programmatically.

 

If this color is always the same, I can obtain it myself using Photoshop... Smiley Wink

 

Thanks a lot,

 

Wolfgang

0 Kudos
Message 1 of 3
(3,107 Views)
Solution
Accepted by topic author Wolfgang

When the panel has ATTR_CONFORM_TO_SYSTEM_THEME set, CVI lets Windows draw the tabs by calling DrawThemeBackground with partIDs such as TABP_TABITEM, etc. The picture that you posted is the XP theme. The Windows 7 theme is different and it looks like this...

 

Untitled.png

 

I checked out the Windows function GetSysColor, but didn't see a way to get that color. Anyway, since the tabs draw differently on XP and Vista/Windows 7, you may not want to use that color in different controls.

 

Message 2 of 3
(3,094 Views)

Hi jared,

 

You are right! I just tried it myself on a Windows 7 system - it's less colorful... Hence it appears that it's not a good idea to adjust LED color to this system color. I just wanted to have a more homogeneous color schema, but if Windows 7 is gray in gray, this is not an option Smiley Wink

 

Thanks!

0 Kudos
Message 3 of 3
(3,091 Views)