CListView owner draw
Joe Linoff -- joe.linoff@xilinx.com Tuesday, February 27, 1996 Platform: MSVC++ 4.0, NT 3.51, Window 95 I am migrating a Borland 4.52 OWL application to MSVC++ and wanted to convert my owner draw list box stuff to CListView with owner draw. The original application had a number of synchronized list boxes. Each was an owner draw LB whose entries could be text with different fonts/colors or bitmaps. I have been unable to capture the WM_DRAWITEM events successfully and don't know where to turn. I have looked at the on-line documentation, some of the examples: (DAOVIEW and CMNCTRLS) and much of the help. I did look at the bug report (PSS ID Number: Q132289) but that implied that DrawItem() was called all the time (if OnDrawItem was overridden in the parent) and I wasn't able to get to work either. Does anyone know where I can find an example of CListView or (CListCtrl) with owner draw? Thanks in advance, Joe Linoff jdl@xilinx.com
Mike Blaszczak -- mikeblas@interserv.com Friday, March 01, 1996 On Tue, 27 Feb 1996, Joe Linoffwrote: >Platform: MSVC++ 4.0, NT 3.51, Window 95 Thanks. You'd never believe how much easier this makes answering questions. >I am migrating a Borland 4.52 OWL application to MSVC++ and wanted to >convert my owner draw list box stuff to CListView with owner draw. >The original application had a number of synchronized list boxes. Each >was an owner draw LB whose entries could be text with different >fonts/colors or bitmaps. >I have been unable to capture the WM_DRAWITEM events successfully and >don't know where to turn. Use Spy++ to see what's really going on. You might also want to read up on reflected messages, since you're using a CListView. A CListView doesn't receive WM_DRAWITEM--it receives a reflected WM_DRAWITEM that you need to trap with a different bunch of macros. >Thanks in advance, How do you know my answer doesn't suck? [Moderator's note: Hope is eternal.] .B ekiM -- TCHAR szDisc[] = _T("These words are my own; I do not speak for Microsoft.");
| Вернуться в корень Архива |