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 » How does one hide a row in an ArrayCtrl?
How does one hide a row in an ArrayCtrl? [message #44167] Tue, 13 January 2015 11:53 Go to next message
rxantos is currently offline  rxantos
Messages: 71
Registered: October 2011
Member
How does one hide a row in an ArrayCtrl?
Re: How does one hide a row in an ArrayCtrl? [message #45495 is a reply to message #44167] Mon, 23 November 2015 22:42 Go to previous messageGo to next message
Alboni is currently offline  Alboni
Messages: 182
Registered: January 2012
Location: Deventer, Netherlands
Experienced Member
to create it hidden: (I often use this to store information)
headerctrl.AddColumn(some_identifier or just "").HeaderTab().Fixed(0);


To hide a visible Column later (0 is the number, can also be an identifier assigned during creation)
headerctrl.ColumnAt(0).HeaderTab().Fixed(0);



Edit: Oh, a row.... how did that turn into a column in my head...? hmmm Rolling Eyes

[Updated on: Mon, 23 November 2015 22:49]

Report message to a moderator

Re: How does one hide a row in an ArrayCtrl? [message #45496 is a reply to message #44167] Tue, 24 November 2015 05:10 Go to previous messageGo to next message
Novo is currently offline  Novo
Messages: 890
Registered: December 2006
Experienced Contributor
rxantos wrote on Tue, 13 January 2015 05:53
How does one hide a row in an ArrayCtrl?

AFAIK, there is no easy way to do that unlike with GridCtrl. I'm personally doing this by using virtual ArrayCtrl. I implemented a tree-like grid on top of the ArrayCtrl this way.


Regards,
Novo

[Updated on: Wed, 25 November 2015 04:26]

Report message to a moderator

Re: How does one hide a row in an ArrayCtrl? [message #45500 is a reply to message #45496] Tue, 24 November 2015 14:59 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 12096
Registered: November 2005
Ultimate Member
Sneaky way is to SetLineCy(row_i, 0)...


Re: How does one hide a row in an ArrayCtrl? [message #45501 is a reply to message #45500] Tue, 24 November 2015 15:29 Go to previous message
mirek is currently offline  mirek
Messages: 12096
Registered: November 2005
Ultimate Member
OK, it really was missing, so:

class ArrayCtrl {
....
	Callback2<int, bool&> WhenLineVisible;
	void       ShowLine(int i, bool e);
	void       HideLine(int i)                                  { ShowLine(i, false); }
	bool       IsLineVisible(int i) const;
....
};
Previous Topic: GridCtrl: resize only one column
Next Topic: Setting the text Color of the Headercontrol
Goto Forum:
  


Current Time: Tue Nov 12 14:22:36 CET 2019

Total time taken to generate the page: 0.01030 seconds