Page 1 of 1

wxRichTextCtrl problem

Posted: Wed Apr 30, 2008 3:37 pm
by Mastersgn
I've a problem with wxRichTextCtrl because the enter key doesn't work (when i press enter key it change the control).I'm under win xp SP2 and i use wxPack (IDE: CodeBlocks).

This is the implementation:

Code: Select all

personaltextctrl=new wxRichTextCtrl(panel,wxID_ANY,wxEmptyString,wxDefaultPosition,wxDefaultSize,wxRE_MULTILINE | wxTE_RICH);
I tryed to change the Id and the control styles but nothing...

(sorry for my english)

Posted: Wed Apr 30, 2008 3:43 pm
by lester
Add wxWANTS_CHARS to style

Posted: Wed Apr 30, 2008 3:59 pm
by Mastersgn
I take this opportunity to get another question: when i add an image to the control (wxRichTextCtrl::AddImage),
it first add a newline and then add the image.
Why?..Can i remove this behavior?

Posted: Wed Apr 30, 2008 4:44 pm
by Mastersgn
Ok, i solved with:

Code: Select all

So first i add the image and then i remove the newline that the program adds...