Page 1 of 1

Difference in caret style in wxRichTextCtrl and wxTextCtrl

Posted: Wed Sep 29, 2010 1:34 pm
by Marcus Frenkel
Hi,

On wxMSW the caret on wxRichTextCtrl has 2px width while on wxTextCtrl it has 1px width. I want to have the caret 1px in width on wRichTextCtrl as well so I tried:

Code: Select all

richTextCtrl->GetCaret()->SetSize(1,richTextCtrl->GetCaret()->GetSize().GetHeight() ) ;
//or
wxCaret * caret = new wxCaret(richTextCtrl,0,10);
but without success.

Posted: Wed Sep 29, 2010 2:45 pm
by evstevemd
Try

Code: Select all

richTextCtrl->GetCaret()->SetSize(1,1);

Posted: Thu Sep 30, 2010 9:09 am
by Marcus Frenkel
evstevemd wrote:code]richTextCtrl->GetCaret()->SetSize(1,1);[/code]
That causes no change in the caret style as well.

Posted: Thu Sep 30, 2010 11:57 am
by catalin
I remember trying to do the same thing once and the only thing that made it change was to change the value of wxRICHTEXT_DEFAULT_CARET_WIDTH in wxW sources. I don't remember what other things I've checked, if any..

Posted: Sun Oct 03, 2010 8:24 pm
by Marcus Frenkel
catalin wrote:I remember trying to do the same thing once and the only thing that made it change was to change the value of wxRICHTEXT_DEFAULT_CARET_WIDTH in wxW sources. I don't remember what other things I've checked, if any..
Seems like the only way.