Allow the user to choose their own background image colour:

  // background
  $background_color = imagecolorallocate($image, 255, 255, 255); // <-- HERE
  imagefilledrectangle($image, 0, 0, $width, $height, $background_color);

Right now the use is forced to a white background, which doesn't look that good when on a dark theme. Giving the user the ability to choose their own background colour when customizing the image captcha will allow more flexibility.

Comments

soxofaan’s picture

I was also thinking about this. The following things/problems crossed my mind:

How do you let the admin choose in the UI: textfield for hex color code, three textfield for R, B and B ints, a select box with named colors, or even a fancy javascript color picker?

How do you handle foreground colors? They should be different enough from the background. Would you let the users pick them? Would you calculate them automatically from the background?

it seemed a lot of trouble for a minor feature, that wouldn't be used a lot, I guess. White is pretty neutral .

maybe we could just offer a small set of "color themes" like "dark colors on white background", "pastel colors on black background", "primary colors on gray background" or something

robloach’s picture

Another good question to brainstorm is whether these settings should go into admin/build/themes/settings/mytheme to make them theme specific.

robloach’s picture

Status: Active » Closed (duplicate)