I have a script I'm working on that has a dialog with some logos in it. The dialog looks great until I make illustrator's user interface preferences darker. Now, I know that I can go through each and every control and modify the colors used, but I'm hoping there is an easier way. Perhaps some way to force UIscript to use a specific brightness value for its dialogs, regardless of illustrator's preferences?
You can control the script UI background color by adding the line of code below to your script, the three numbers at the end represent RGB. Just play around with the numbers to get the color\shade you want. The link below is good reference RGB color chart.
dialog.graphics.backgroundColor = dialog.graphics.newBrush(0, [.75,.75,.75]);
I don't know how to do what you're trying to do, but i wanted to chime in and say that in my opinion, software should never be forcing different appearances or brightnesses on its users. I know that it makes me angry when i set something up the way i want it to look, and someone else comes along and says "no. the way you like it is wrong. you have to look at it the way i like it".
My suggested solution to the problem is to update the logo in a way that will look good with any background color (a very common task for any logo design.)
It is unclear to me which the OP is trying to achieve.