15 мая 2023 года "Исходники.РУ" отмечают своё 23-летие!
Поздравляем всех причастных и неравнодушных с этим событием!
И огромное спасибо всем, кто был и остаётся с нами все эти годы!

Главная Форум Журнал Wiki DRKB Discuz!ML Помощь проекту


Changing text color in a CListCtrl

MICHAEL@datatree.com
Tuesday, July 30, 1996

Environment: VC++ 4.2 and Windows 95

I have a CListCtrl display that looks almost
identical to the Print Manager display. New
entries are added to the bottom of the display
and the status is displayed in one of the columns.

My question is how do I change the text color
for one column - namely my status column?

Michael Thal        michael@datatree.com                              
Data Tree Corp.     http://www.datatree.com





Mike Blaszczak -- mikeblas@msn.com
Saturday, August 03, 1996

[Mini-digest: 2 responses]

From: 	owner-mfc-l@netcom.com on behalf of michael

> Environment: VC++ 4.2 and Windows 95
> I have a CListCtrl display that looks almost

> My question is how do I change the text color
> for one column - namely my status column?

You have to make the control owner-draw and do the painting yourself.

.B ekiM
http://www.nwlink.com/~mikeblas/
I don't speak for Microsoft, unless they pay the plane ticket.


-----From: Sven Plastwich 

Hi,
make it an ownerdraw-list.
Could mail u an example

regadz




Bok Nan Lo -- lo@ia-us.com
Tuesday, August 06, 1996

On Saturday, August 03, 1996 3:56 PM, Mike Blaszczak[SMTP:mikeblas@msn.com] wrote:
> [Mini-digest: 2 responses]
> 
> From: 	owner-mfc-l@netcom.com on behalf of michael
> 
> > Environment: VC++ 4.2 and Windows 95
> > I have a CListCtrl display that looks almost
> 
> > My question is how do I change the text color
> > for one column - namely my status column?
> 
> You have to make the control owner-draw and do the painting yourself.
> 
> .B ekiM
> http://www.nwlink.com/~mikeblas/
> I don't speak for Microsoft, unless they pay the plane ticket.
> 
> 
> -----From: Sven Plastwich 
> 
> Hi,
> make it an ownerdraw-list.
> Could mail u an example
> 
> regadz
> 
> 
> 

I think xlist.ocx sample in your VC++ CD is an excellent example of what you want to achieve. It subclasses the listbox control. 


--
Bok Nan Lo
IA Corporation
Phone: 510-4506871 Fax: 510-4507099
E-Mail: lo@ia-us.com




| Вернуться в корень Архива |