I could use a little advice from anyone that has worked with making a custom listbox. I’m needing variable row heights, so I’m trying to role out my own. Everything is working very well so far, with the exception of the grid lines and column headers don’t line up correctly. I’m not sure if there is something else I need to handle in my drawing code or what’s up.
You can see in the picture, the grid lines are shifted to the right of the header divider. My drawing starts at 0, 0 in most cases. Does anyone have any ideas that might help me solve this?
The vertical indent of the first column makes me think you’re drawing those lines in CellTextPaint, because the graphics you get in that event is shifted like that. You’ll need to use CellBackgroundPaint for the whole space. I don’t see what’s misaligned about the headers, looks nice. are you going to share
If you are open to a paid solution I have a custom listbox subclass that I think does what you want.
My old website is no more as my ISP no longer provides webspace as of the end of September, but I am in the process of building a new site elsewhere. In the mean time you can download a demo with docs that ONLY runs in the IDE here: