Community
Participate
Working Groups
Separated from bug 208888. In Edit View or Display View, we can use Ctrl-Shift-I to inspect a variable or an expression, then hit Ctrl-Shift-I again to add it to "Expressions View", but the added item is in "Inspection Mode", we have to use context menu "Convert to Watch Expression" to make it changable as we step through the code. This is not convenient and not a common habit compare to other IDE. Why don't make it "Watch" as soon as the inspection expression is added into Expressions view? Who need the inspection item in Expression View? If there is a reason of needing it. Can we have an option to change the default status?
A workaround is to select the text for the expression and drag the text to the expressions view, where a new watch expression will be created. Bug 199288 will add paste functionality to the view. With copy/paste you can create watch expressions just using the keyboard. I'll leave this bug open in case we can find a good way of creating a watch expression from the inspect popup.
> A workaround is to select the text for the expression and drag the text to the expressions view, where a new watch expression will be created. Is drag&drop only supported on 3.4? I'd like wait for 3.4 stable to use it. On the other hand, can you tell me why we need the expression been added to Expressions View from Inspection keep the "Inspection" mode? Who will need the "Inspection" mode again in Expressions View? I think in the Expressions View, people only need the expressions to be watchable.
Perhaps we need to options to persist/save an object in the inspect popup - i.e. one to save the expression (to be re-evaluated), and one to save the object. Currently, the popup only has support for one key-binding/command for handling the "close" behvaior. Marking as bugday for anyone who wants to take a stab at it.
(In reply to comment #2) > On the other hand, can you tell me why we need the expression been added to > Expressions View from Inspection keep the "Inspection" mode? Who will need the > "Inspection" mode again in Expressions View? I think in the Expressions View, > people only need the expressions to be watchable. The benefit of creating an inspection entry in the expressions view (rather than a watch expression) is that the inspection is just an object, it does not have to be re-evaluated on every step. Some inspections cannot be re-evaluated while others cause performance problems. For example, the All References command collects all references to an object in an array. This array can be persisted to the expressions view as an inspection entry. Converting it to a watch expression will result in errors as it is not an expression.