Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » ArrayCtrl, HeaderCtrl & GridCtrl » Cursor row color/headers color in ArrayCtrl and SQLCtrl (How to change those colors or create derived controls ?)
Cursor row color/headers color in ArrayCtrl and SQLCtrl [message #48199] Thu, 01 June 2017 15:53 Go to next message
jibe is currently offline  jibe
Messages: 294
Registered: February 2007
Location: France
Experienced Member
Hi,

It's nice that we can change some colors in ArrayCtrl and SQLCtrl. But seems that there is no way to change the Cursor row color when the focus is lost : it's always gray, and not very visible when the cursor row is the first under the headers... I need to have it more visible, either by changing the unfocused cursor row color, either by changing the headers color (The 2 possibilities would be great ! But at least one...).

I'm not very sure that it's possible with GridCtrl, anyway I need this more especially for SQLCtrl, so it's difficult to replace it by GridCtrl...

It seems difficult to do that just by overriding the paint method... So, what is the best way to do that ?

Re: Cursor row color/headers color in ArrayCtrl and SQLCtrl [message #48266 is a reply to message #48199] Tue, 13 June 2017 11:35 Go to previous messageGo to next message
jibe is currently offline  jibe
Messages: 294
Registered: February 2007
Location: France
Experienced Member
Hi,

I just (re)discoverd Chameleon : I never payed attention to that (seems a little complicated and not well documented). Could it be a solution ? I'll try to study that and make some tries...

If somebody has some experience to share or advices about using chameleon in such a case, he will be welcome !
Re: Cursor row color/headers color in ArrayCtrl and SQLCtrl [message #48343 is a reply to message #48199] Sat, 24 June 2017 16:27 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 12096
Registered: November 2005
Ultimate Member
jibe wrote on Thu, 01 June 2017 15:53
Hi

It seems difficult to do that just by overriding the paint method... So, what is the best way to do that ?



SetDisplay (with your custom Display derived instance)
Re: Cursor row color/headers color in ArrayCtrl and SQLCtrl [message #48358 is a reply to message #48199] Mon, 26 June 2017 08:57 Go to previous message
jibe is currently offline  jibe
Messages: 294
Registered: February 2007
Location: France
Experienced Member
Hi Mirek,

Thanks, I did not thought about a Display derived instance... I'll see that next time.

For this case, I finally used successfully Chameleon. Not very easy because there is few documentation and not always very clear, but in fact it is not very difficult and does very well the job for me.

If I can find some time, I'll try to explain how I did and complete the doc : I think that it is worth to better know Chameleon !
Previous Topic: Option error in GridCtrl
Next Topic: Change row appearance based on column value in that row
Goto Forum:
  


Current Time: Tue Nov 12 14:21:12 CET 2019

Total time taken to generate the page: 0.01164 seconds