diff --git a/collects/mred/private/kernel.ss b/collects/mred/private/kernel.ss index e21bfd92..f448c678 100644 --- a/collects/mred/private/kernel.ss +++ b/collects/mred/private/kernel.ss @@ -240,6 +240,7 @@ can-save-file? on-new-box on-new-image-snip + size-cache-invalid invalidate-bitmap-cache on-paint write-footers-to-file @@ -921,6 +922,7 @@ can-save-file? on-new-box on-new-image-snip + size-cache-invalid invalidate-bitmap-cache on-paint write-footers-to-file @@ -1133,6 +1135,7 @@ can-save-file? on-new-box on-new-image-snip + size-cache-invalid invalidate-bitmap-cache on-paint write-footers-to-file diff --git a/collects/scribblings/gui/editor-intf.scrbl b/collects/scribblings/gui/editor-intf.scrbl index 3b4cff2d..0b4e7714 100644 --- a/collects/scribblings/gui/editor-intf.scrbl +++ b/collects/scribblings/gui/editor-intf.scrbl @@ -1015,7 +1015,7 @@ The default implementation triggers a redraw of the editor, either immediately or at the end of the current edit sequence (if any) started by @method[editor<%> begin-edit-sequence]. -} +See also @method[editor<%> size-cache-invalid].} @defmethod[(is-locked?) @@ -2322,6 +2322,20 @@ Setting the style list is disallowed when the editor is internally } +@defmethod[(size-cache-invalid) + void?]{ + +This method is called when the drawing context given to the editor by +its administrator changes in a way that makes cached size information +(such as the width of a string) invalid. + +The default implementation eventually propagates the message to snips, +and, more generally, causes @tech{location} information to be +recalculated on demand. + +See also @method[editor<%> invalidate-bitmap-cache].} + + @defmethod[(style-has-changed [style (or/c (is-a?/c style<%>) false/c)]) void?]{