ListView Grid, TreeView Node Font Color

Quote
"Jeff Walton" <jwal...@accentsol.com> wrote in message

news:3db8ccdd$1@newsgroups.borland.com...

Quote
> Question (1) - How can you make the grid in a Listview darker
> which is viewed as a report style.  I can only display a very faint
> gray color whic is barely viewable.  can you make the grid darker
> or not?  If so, How?

The short answer is that TListView doesn't provide for changing the color of
the grid lines.

The medium answer is that you'll have to owner-draw the grid and render the
lines yourself manually, then you can color them anyway you want..

The long answer is that you'll have to use the On...Draw events.  TListItem
has a DisplayRect() method that you can use to calculate the TRect for each
item.  Then you can extend that TRect an extra pixel or two on each side,
then use the Canvas's Rectangle() method to draw the grid lines surrounding
each list item.

Quote
> Question(2) - Can you make just specific text within a node
> of a treeview a different color as desired?  I can only find the
> font color properties under the Canvas class of a treeview but
> that will change the entire tree's text to that color.  If this can
> be done, then How?

Again, you'll have to owner-draw the ListView and custom-draw the text on a
per-item basis, manipulating the Canvas so that different text is drawn with
diffrerent colors as needed.

Gambit