Community
Participate
Working Groups
DS (9/7/01 2:58:38 PM) Select some code in the snippet editor that has an error and attempt to run the code Hit the backspace key to delete the error message Notice that the state of the run, inspect and display toolbar actions does not update to reflect no selection. DS (9/7/01 3:03:59 PM) Seems to just be a general problem with the selection changed mechanism of the StyledText widget. StyledText.clearSelection(boolean) is being called with sendEvent == false? This results in no selection changed being fired to the listeners therefore there is no way for the actions to update. NOTES: DW (9/17/01 11:37:32 AM) File PR with workbench. DS (9/25/01 1:31:45 PM) Email from LK I think it is by design that we only send the selection event when the user performs the selection. I think this was based on how other SWT widgets handle selection (i.e., send it only when performed by the user vs. programmatically or as a side effect). Anyway, the behavior has been like that all along. Open a PR if you want different behavior. If we are inconsistent with the other widgets, that would be an argument for your case, but if not, we probably will not change the behavior. KR (9/26/01 11:18:42 AM) This is a bug in StyledText. A selection event should be sent anytime a user action (mouse click, key stroke) has changed the selection. Presently this does not work for any key strokes that modify the text content. It does not work in the backspace/delete scenario despite the fact that clearSelection(true) is called in invokeAction. The reason is that the selection is already changed/cleared in handleTextChanged which does not send a selection event (even though it should). DS (9/26/01 12:01:58 PM) Logged 1GKO6NY: SWT:ALL - Backspacing in StyledText does not fire selection changed DS (10/4/01 10:57:55 AM) From KR I released fixes for this PR and for "1GIK7D4: SWT:ALL - StyledText - Selection cleared when deletion disallowed by verify listeners". They didn't make it into build 203 but will be in the next.
Fixed in 204
PRODUCT VERSION: 135