wxresizeablecontrol component problem

Talk here about issues with one of the components hosted at wxCode, or suggest features for it.
Post Reply
lollisoft
Earned some good credits
Earned some good credits
Posts: 115
Joined: Sat Jul 23, 2005 3:52 pm
Location: Germany
Contact:

wxresizeablecontrol component problem

Post by lollisoft »

Hi,

I tried to add support for a resizeable wxTextCtrl with the wxresizeablecontrol classes. But I have no success.

Here is the code I use to create a text control:

Code: Select all

	s = "Some text";
	if (!m_resizecanvas) m_resizecanvas = new wxResizeableControlCanvas(this,-1);

	
        ParentControl *parent = new ParentControl((wxResizeableControlCanvas *)m_resizecanvas,0,wxDefaultPosition,wxDefaultSize,wxCLIP_SIBLINGS);
	wxResizeableChildTextCtrl *text = new wxResizeableChildTextCtrl(parent, -1, s->charrep(), wxDefaultPosition, wxDefaultSize);
    parent->SetManagedChild(text);

	text->SetName(name);
	
	addLabel(name, sizerLabel, hideThisColumn);
	
	
	sizerControl->Add(parent, 1, wxALL, GAP);
	sizerMain->Add(sizerControl, 0, wxEXPAND | wxALL, GAP);
	
}
The text control is not visible in my panel but as in my remaining code I have access to the control as I had without the resizing stuff.

Then I haven't added the text control to the sizer to see if it has to do with the sizer, but that doesn't help.
It seems that the control didn't get drawn, also the OnPaint handler in wxResizeableControl didn't get called I think.

Does anyone has experience with this component?

Thanks

Lothar
OS: Windows 7, Mac OS X (Panther/Leopard/Snow Leopard), SuSE Linux, Debian (PPC), OpenMoko FreeRunner
Compiler: OpenWatcom, GCC
wxWidgets 2.8.x
IDE Makefile based.
RAD My own brewed, Code generation with XSLT and DialogBlocks
Post Reply