Forum > Other OS
TListView CustomDrawItem not working
(1/1)
HermanR:
Hello all,
I have a TListView in vsReport and want to color some items.
I have 4 columns (= 3 SubItems)
OwnerDraw = False;
In all CustomDraw, AdvancedCustomDraw and DrawItem (7 times) I made a call to a logfile to tell the event is triggered.
It looks like only the the CustomDraw and CustomDrawItem, AdvancedCustomDraw and AdvancedCustomDrawItem are triggered
According to the doc, DrawItem should be triggered but is not, nor are CustomDrawSubItem and AdvancedCustomDrawSubItem
with OwnerDraw = true; I get the same results (except now I can see some values, which is correct)
Am I missing something here?
And how do I get the font changed in a single SubItem?
thanks in advance
Herman
jc99:
Hi,
Please tell us more about your project/problem.
Maybe put in some code, or upload a test-project or your project if it's not too big.
BTW, are you sure you are in the right part of the board ?
this is about Other OS, What other OS are you using ?
JD:
This may be able to help you with your project http://delphidabbler.com/articles?article=16. I had no problems implementing it in Lazarus.
JD
HermanR:
Thanks jc99 and JD,
I read the article and imported the project in Lazarus but didn't see any items in the list. They were lost in the conversion. After adding them the Alternating, Rainbow and Columns worked fine.
I skipped the Background Bitmap (didn't convert ok) and the Shaded had some strange effects.
In Delphi XE8 the items were not lost and all worked ok except with the background and shaded the lines were not always visible (depended on the mouse to go over it)
I compiled the Lazarus project for WinCE and none of the effects worked. All flat lists with row select.
I use Lazarus 1.4 / fpc 2.6.4 with the WinCE add-on.
In the project options I choose wince as a target, arm as the CPU family and add the LCL Widget Type wince.
I do not use a debugger because I'm a newbe and haven't worked out (yet) how to configure this.
I made a small WinCE demo to show what I'm trying to do but in the demo (build from scratch) I didn't even see any items in the list. So it's worse that in my project. I changed it with the same code that loads the items, but no change.
All I need is a list with the swipe working. (The TDBGrid doesn't do that).
Thanks again
Herman
HermanR:
Hello all,
I rebuild my screen using a TListBox with only the database key in it and in the DrawItem I draw all data, colors etc. It's simple and fast.
So for me the item is closed
Thanks for helping me
Herman
Navigation
[0] Message Index