In a GridView, it occurs that I need two different entries with two different background colors in a few of the cells. So I thought about different solutions for this.

1. Using RichText doesn't produce any entries here on my system, don't know why, but it might have been an easy way to use it with a <table> with two columns. But even .Data.RichText = "Hello" doesn't show anything in the cell...

2. Once upon a time, I used TextLabels created dynamically at runtime to show calendar entries. This means, however, they are hovering above the GridView, not alowing direct mouse-click access to the cell below. On my calendar it doesn't matter, but it would screw up things unnecessarily in my current project.

3. It is possible to add a picture to a cell, the picture being shown on the left-hand side of the cell with the text at its right. Now, I thought it might be possible to create a little Picture with the second color and second entry virtually in the background and simply send it to the cell. Do you think this is possible, and how?

This is what I came about:

- DrawingArea, Not Visible, Cached
- its size = cell height, but cell width / 2
- Background for the second entry
- Font as in the cell
- write text for the second entry

Then I would have to send this as a Picture to the GridView cell - but how?

Thank you for reading up to here and for any ideas!

Regards
Rolf

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Gambas-user mailing list
Gambas-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/gambas-user

Reply via email to