How to set the LabelBackgroundColour of a wxSheet Topic is solved

Are you writing your own components and need help with how to set them up or have questions about the components you are deriving from ? Ask them here.
Post Reply
kea_
Experienced Solver
Experienced Solver
Posts: 59
Joined: Wed Oct 17, 2007 7:32 am

How to set the LabelBackgroundColour of a wxSheet

Post by kea_ » Mon Sep 15, 2008 6:05 am

Hello together,

does any body know how to set the label background colour of the column of a wxSheet. The wxSheet does it in default as gray and I like to have it in blue.
I tried it with override the function wxSheet::DrawColLabels(wxDC& dc, const wxArrayInt& cols) but then the labels where not correct drawn by the wxSheet if I moved the label size.
Attachments
Grid.jpg
Grid.jpg (26.21 KiB) Viewed 1327 times

Auria
Site Admin
Site Admin
Posts: 6695
Joined: Thu Sep 28, 2006 12:23 am
Contact:

Post by Auria » Mon Sep 15, 2008 1:38 pm

I think wxSheet comes from wxCode? If so, you have its sourcecode so you could just modify its source code, even if it does not have an interface for that.

EDIT: see code at : http://wxcode.cvs.sourceforge.net/wxcod ... iew=markup

"wxSheet::SetAttrBackgroundColour" at line 1828 sounds interesting

kea_
Experienced Solver
Experienced Solver
Posts: 59
Joined: Wed Oct 17, 2007 7:32 am

Post by kea_ » Tue Sep 23, 2008 6:48 am

thank you for your help.

Ok, I have to have a look in the source of the wxSheet.
Sorry that I give you a thank so late. I was very bussy the last time.

Greetings kea_

Post Reply