Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Determine Contrasting/Inverse Colors
Message
From
23/05/2009 03:03:10
 
 
To
22/05/2009 19:41:12
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Environment versions
Visual FoxPro:
VFP 9 SP2
Miscellaneous
Thread ID:
01401618
Message ID:
01401627
Views:
70
>I need to be able to determine the forecolor when a user selects the backcolor. This is to be able to display the text as readable based on what the backcolor is. Just taking the inverse color works for the outer color spectrum but when it is in the middle this does not work well.
>
>Does anyone have any ideas on how to calculate the best readable forecolor based on the backcolor setting? Thanks.

Don't know how you'd code it, but you could try implementing a colour wheel.
Regards. Al

"Violence is the last refuge of the incompetent." -- Isaac Asimov
"Never let your sense of morals prevent you from doing what is right." -- Isaac Asimov

Neither a despot, nor a doormat, be

Every app wants to be a database app when it grows up
Previous
Reply
Map
View

Click here to load this message in the networking platform