Link to home
Start Free TrialLog in
Avatar of ajax052397
ajax052397

asked on

highlighting

How do you change the background color of highlighted text in an Edit Box?  Something like Edit1.HIGHLIGHT_Color := clWhite.  It must be easy, but I can't find the answer.
Thanks.
ASKER CERTIFIED SOLUTION
Avatar of slp
slp

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of ajax052397
ajax052397

ASKER

So the direct answer is you can't do it thru Delphi without creating a descendant to the EditBox, and then use an API call
whenever it's selected?  Any idea how the routine would look with the API call?  Sorry, but I'm trying to get the hang of Delphi.

Basically you'd have to do your own custom selection drawing to get colors other than the ones set in the system, which is doable but not especially easy.  Perhaps we're going about this the wrong way; what is the need for having selection colors other than the default?  Maybe there's some other way of going about this.
You are right, especially since it's not all that easy.  I had hoped there was a hidden Delphi routine that would be pretty
straightforward.  Thanks for responding, and I appreciate your helpful advice.  (I hope this experts-exchange thing works out.)