• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 419
  • Last Modified:

Dark text on dark colors

I am developing a customized appointment scheduling system. I will allow users to select their appointment color using a color picker. However, the color of the appointment text will always be black

I will have an issue if the user selects a dark color. Please provide a solution to any ONE of the given below options:

1) Allow me to ensure the color picker displays only light colors
2) Allow me to give a white glow to the appointment text so that no matter what background it is on, it will always show clearly

Thanks
0
RTKHOT
Asked:
RTKHOT
  • 2
  • 2
1 Solution
 
RTKHOTAuthor Commented:
After reviewing my question above, i realized that I have not described it properly.

The user will select an appointment color that will be a background color. So it will appear as a square shape on the calendar. The description text of the appointment will be inside this box.

I am providing the user to choose the color of the background, but the description text will always be black

thanks,
0
 
ChristoferDutzCommented:
Well you could define the colors in your ColorPicker.
http://livedocs.adobe.com/flex/3/html/help.html?content=controls_18.html
Another option would be to use the default dataProvider of the ColorPicker and to filter it (as the ffffff is white you could set a threshold to allow only colors thats rgb values summ up to a minimum value)
0
 
RTKHOTAuthor Commented:
Could you please give a more specific answer for the RGB sum up values.

Thanks,
0
 
ChristoferDutzCommented:
Well you have your color codes in this format:

#rrggbb

All are values of 00 (0) to ff (255).
So if you simply add the color value of r, b and c you shoud get a value of 0 to 765. If for example you set the minimum to 500 you would certainly get some pretty light colors.
0

Featured Post

What Security Threats Are We Predicting for 2018?

Cryptocurrency, IoT botnets, MFA, and more! Hackers are already planning their next big attacks for 2018. Learn what you might face, and how to defend against it with our 2018 security predictions.

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now