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 » Editing + JoinFixedCells bug
Editing + JoinFixedCells bug [message #40799] Fri, 20 September 2013 07:50 Go to next message
iST1 is currently offline  iST1
Messages: 107
Registered: August 2013
Experienced Member
Wanted to illustrate JoinFixedCells bug, but editing not work:
GUI_APP_MAIN
{	
	TopWindow wnd;
	GridCtrl grid;
	
	grid.AddColumn("Col1");
	grid.AddColumn("Col2");	
	grid.Editing()
		.Sorting(false)
		.OneClickEdit();

	wnd.Add(grid.SizePos())	;
	grid.AddRow();
	grid.Set(0, 0, "Cell1");
	grid.Set(0, 1, "Cell2");
	wnd.Run();
}
Re: Editing + JoinFixedCells bug [message #40810 is a reply to message #40799] Fri, 20 September 2013 15:33 Go to previous messageGo to next message
unodgs is currently offline  unodgs
Messages: 1366
Registered: November 2005
Location: Poland
Ultimate Contributor

You forgot to add editor to the column.
EditString myEdit;
grid.AddColumn("Col 1").Edit(myEdit);

[Updated on: Fri, 20 September 2013 15:35]

Report message to a moderator

Re: Editing + JoinFixedCells bug [message #40840 is a reply to message #40810] Mon, 23 September 2013 06:07 Go to previous messageGo to next message
iST1 is currently offline  iST1
Messages: 107
Registered: August 2013
Experienced Member
Insert error (maybe) happened:

Add -> Add -> Add
#if 1
http://s005.radikal.ru/i209/1309/0a/9c9011b430e8.png

#if 0 (view artefact - gray field)
Add -> Add -> Insert(1)
http://s04.radikal.ru/i177/1309/98/1bf35f443496.png
GUI_APP_MAIN
{	
	TopWindow wnd;
	AppGrid grid;
	
	wnd.Add(grid.SizePos());
	grid.AddColumn("Col1");
	grid.AddColumn("Col2");
	
	grid.Add();
	int ir = grid.GetRowCount() - 1;
	grid.JoinCells(0, ir, 1, ir);
	grid.Set(ir, 0, "c11");
	grid.Set(ir, 1, "c12");	
#if 0
	grid.Add();
	ir = grid.GetRowCount() - 1;
	grid.Set(ir, 0, "c21");
	grid.Set(ir, 1, "c22");

	grid.Add();
	ir = grid.GetRowCount() - 1;
	grid.Set(ir, 0, "c31");
	grid.Set(ir, 1, "c32");
	grid.JoinCells(0, ir, 1, ir);
#else
	grid.Add();
	ir = grid.GetRowCount() - 1;
	grid.Set(ir, 0, "c31");
	grid.Set(ir, 1, "c32");
	grid.JoinCells(0, ir, 1, ir);

	grid.Insert(ir);
	grid.Set(ir, 0, "c21");
	grid.Set(ir, 1, "c22");
#endif
	wnd.Sizeable();
	wnd.Run();
}


if you click on the title to sort, disappeared row showing:
http://s017.radikal.ru/i440/1309/0d/25b4e2963d4f.png

[Updated on: Mon, 23 September 2013 06:23]

Report message to a moderator

Re: Editing + JoinFixedCells bug [message #40917 is a reply to message #40840] Mon, 07 October 2013 18:56 Go to previous messageGo to next message
unodgs is currently offline  unodgs
Messages: 1366
Registered: November 2005
Location: Poland
Ultimate Contributor

I have it generally fixed, but I'm still working on some other join + insert column/row scenarios. Please wait a little bit longer Wink

[Updated on: Mon, 07 October 2013 18:56]

Report message to a moderator

Re: Editing + JoinFixedCells bug [message #41008 is a reply to message #40917] Sun, 20 October 2013 09:43 Go to previous message
iST1 is currently offline  iST1
Messages: 107
Registered: August 2013
Experienced Member
Hello unodgs, the changes in r6450 works fine.

Can you give advice about replacing Collumn alignment by Row alignment?

GUI_APP_MAIN
{	
	TopWindow wnd;
	GridCtrl grid;
	
	wnd.Add(grid.SizePos());
	grid.AddColumn("C").AlignCenter();
	
	grid.Add();
	grid.Set(0, 0, "c");	
	grid.GetRow(0).AlignLeft();//not work
	wnd.Run();
}
Previous Topic: Error: ItemRect::Editable(false) + Tab
Next Topic: Getting row index from Display
Goto Forum:
  


Current Time: Thu Mar 28 14:06:29 CET 2024

Total time taken to generate the page: 0.01367 seconds