Scope
Description
Scope objects are used to store the states of Command, in a tree model.
Content Editor is a very context-driven application. The user interface is updated depending on the cursor location. The UI framework relies on Scope as well as Command in order to achieve this.
Scope is an implementation of Functional Reactive Programming. It provides a tree model to store the current state of objects. The main point is to realize that scope variables contain the state information, and that the scope objects are subject to prototype inheritance. While you need to declare most of scope variables that you wish to use, there are also built-in scope variables such as showCustomPanelwhich you can use to your advantage for handling the display of panels.
For examples, see the object Editor.addCommand or tcheck the topics for the Command methods