psychopy.org | Reference | Downloads | Github

Background color

URL of experiment:

Description of the problem: not changing background color

using this code
Bcolor = [0.882352941176471, 0.803921568627451, 0.0980392156862746]
win.setColor(Bcolor)

not working

tried this
white = new util.Color([1, 1, 1]);
win.setFillColor(white);

added this code in the begining of experiment giving an error as function does not exist.

Any suggestion

Thanks

Hi!

You can set the background colour in the builder view by clicking on this icon at the top of the builder window:

Screenshot 2020-07-10 at 12.48.39

That’ll open up a pop-up window:

Screenshot 2020-07-10 at 12.48.48

Using the ‘Color’ option, you can set the background colour.

In the coder view, the background colour is set here:

You can see where it says color=[-1,-1,-1] when the window (win) is set up.

Does this help? Or do you need to change the background colour during the experiment?

thanks for your help/suggestion.

it is working perfectly.

Thank You

Great! Glad to hear it :slight_smile: