Board index » delphi » How to change the default text Color from Grey another color( clBlack ) for a disabled control
EZEKIEL BRADLEY
![]() Delphi Developer |
Mon, 14 Mar 2005 08:45:24 GMT
How to change the default text Color from Grey another color( clBlack ) for a disabled control
Does anyone know how to change the default disabled text color from grey to
black for an entire application ? In my application - when the data in a form or frame is not editable I loop through all of the wincontols in the Form/Frame and disable them with the exception of those with a read-only property. As a result, some of the components on the Form or Frame appear disabled ( with the Font Greyed ) while other components maintain their black font color. Needless to say this creates an interesting visual effect ( one to be avoided) and makes the text difficult to read. I would like to have all components to appear enabled ( without the Geyed text ) irregardless of whether they are disabled or not. I've tried several approaches to this dilemma but none has worked appropriately. I thought that intercepting the WM_PAINT message would allow me to change the components font color but it appears that I cannot ascertain which component and class I'm dealing with within the WM_PAINT message. If anyone has any experience with this I would appreciate hearing from you on how you resolved the problem. I have Delphi 6.0. Thanks, |