git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@52394
c3d73ce0-8a6f-49c7-b76d-
6d57e0e08775
#if wxUSE_RICHEDIT
if ( IsRich() )
{
#if wxUSE_RICHEDIT
if ( IsRich() )
{
+ // if from and to are both -1, it means (in wxWidgets) that all text
+ // should be selected, translate this into Windows convention
+ if ( (from == -1) && (to == -1) )
+ {
+ from = 0;
+ }
+
CHARRANGE range;
range.cpMin = from;
range.cpMax = to;
CHARRANGE range;
range.cpMin = from;
range.cpMax = to;