Get panel background color
gregorK
Is there any way to programmatically get the background color of a panel? Recently I have noticed that for example the default background color for panels in Windows XP and Windows 8 are different (well, in any case anyone can change the default colors in Windows). Since I put graphs on a panel as subwindows I would like to set the background color of the graphs to the same color the panel has. Until now I fixed the background color of the graphs to the color I found the panel has (under WinXP), but the same Panel looks terrible under Windows 8 for example.
Thanks for any hints and ideas!
Gregor
ModifyPanel cbRGB=(R,G,B)
). This way you have control over both the graph and panel colors. It could as well be the same gray the panel usually has, but then the color will (hopefully) stay the same on different OSes.September 18, 2013 at 12:02 am - Permalink
Thanks anyways!
Gregor
September 18, 2013 at 02:25 am - Permalink
--Jim Prouty
Software Engineer, WaveMetrics, Inc.
September 18, 2013 at 09:46 am - Permalink
wave rgb
string osinfo = igorinfo(3)
string ostype = // ... parse osinfo string to get OSVERSION or OS ...
switch(UpperStr(ossubtype))
case "WINDOWS XP":
rgb = ...
break
case "WINDOWS 8":
rgb = ...
break
endswitch
return 0
end
--
J. J. Weimer
Chemistry / Chemical & Materials Engineering, UAHuntsville
September 18, 2013 at 09:48 am - Permalink
Thanks Jim! I would have never looked for the answer to this "issue" in the help of ControlInfo ... This helps me a lot!
Gregor
September 19, 2013 at 03:29 am - Permalink