From 878606dc1cbd9c03ab862fdd1102c40d2b8893cf Mon Sep 17 00:00:00 2001 From: Matthew Flatt Date: Thu, 21 Oct 2004 14:55:59 +0000 Subject: [PATCH] . original commit: 7fadca50edc426738f7fe932daa9ec7eecfabffd --- collects/mred/mred.ss | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/collects/mred/mred.ss b/collects/mred/mred.ss index 301e0010..bfb302d0 100644 --- a/collects/mred/mred.ss +++ b/collects/mred/mred.ss @@ -7659,7 +7659,11 @@ end)))) (let ([end (if (eq? end 'end) (send text last-position) end)] [snip (send text find-snip start 'after-or-none)]) - (if (and (is-a? snip wx:string-snip%) + ;; If the region is small enough, and if the editor contains + ;; only string snips, then it's probably better to move + ;; all of the text into a string port: + (if (and ((- end start) . < . 4096) + (is-a? snip wx:string-snip%) (let ([s (send text find-next-non-string-snip snip)]) (or (not s) ((send text get-snip-position s) . >= . end))))