# HG changeset patch
# User Jan Vrany <jan.vrany@fit.cvut.cz>
# Date 1467662534 -3600
# Mon Jul 04 21:02:14 2016 +0100
# Branch jv
# Node ID 9b2ebe1aa102f7b36b87396c226037e07d658f4c
# Parent 814e3fa20205a4446620f37906d68a4e69d8f8fb
Issue #99: Re-process source code upon #textChanged notification
...which is sent whenever a text changes (however done, being it by
typing or pasting).
The drawback is that this change is sent way too often and would cause
full rehighlight for large, e.g., Java, source since the notification does
not carry the information which part of the text actually changed.
diff -r 814e3fa20205 -r 9b2ebe1aa102 Tools__BackgroundSourceProcessingService.st
a
|
b
|
|
110 | 110 | ^self. |
111 | 111 | ]. |
112 | 112 | ]. |
113 | | (sender == textView and:[aspect == #sizeOfContents]) ifTrue:[ |
114 | | self sourceChanged:true. |
| 113 | sender == textView ifTrue:[ |
| 114 | (aspect == #sizeOfContents or:[aspect == #textChanged]) ifTrue:[ |
| 115 | self sourceChanged:true. |
| 116 | ]. |
115 | 117 | ^self. |
116 | 118 | ]. |
117 | 119 | ]. |
… |
… |
|
139 | 141 | "Created: / 06-03-2010 / 19:38:07 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
140 | 142 | "Modified: / 13-09-2011 / 12:00:29 / cg" |
141 | 143 | "Modified: / 22-02-2012 / 15:02:16 / jv" |
142 | | "Modified: / 15-04-2013 / 23:00:17 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
| 144 | "Modified (format): / 04-07-2016 / 15:20:17 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
143 | 145 | ! ! |
144 | 146 | |
145 | 147 | !BackgroundSourceProcessingService methodsFor:'event handling'! |
… |
… |
|
276 | 278 | |
277 | 279 | version_CVS |
278 | 280 | ^ '$Header$' |
| 281 | ! |
| 282 | |
| 283 | version_HG |
| 284 | |
| 285 | ^ '$Changeset: <not expanded> $' |
279 | 286 | ! ! |
280 | 287 | |