|
GLG Toolkit, JavaScript Library
Version 4.6
|
This group contains supporting methods for the drawing editing functionality. More...
This group contains supporting methods for the drawing editing functionality.
See Object Configuration methods of the Intermediate API and Editing Objects methods of the Extended API for more object editing functionality.
Functions | |
| static boolean | SetEditMode (GlgObject viewport, String resource_name, boolean edit_mode) |
| Sets the viewport's edit mode to disable input objects in the viewport while the drawing is being edited. More... | |
|
static |
Sets the viewport's edit mode to disable input objects in the viewport while the drawing is being edited.
| viewport | A viewport object (either a Viewport or a Light Viewport) to set the editing mode of, or its parent. |
| resource_name | A resource path to access the viewport from the parent supplied by the viewport parameter, or null to set the editing mode of the viewport specified by the viewport parameter. |
| edit_mode |
|
If the viewport's edit mode is turned on, input objects in the viewport will not react to the mouse and keyboard events. The rest of the input objects outside of the viewport will still be active. The edit mode is inherited by all child viewports.
The edit mode is usually set for viewports that serve as a drawing area; the edit mode ensures that the input objects do not react to mouse clicks when they are dragged with the mouse to a new position. This is similar to the behavior of the Graphics Builder's Drawing Area.
The edit mode is global and may be set only for one viewport used as a drawing area. Setting the edit mode of a new viewport resets the edit mode of the previous viewport. A viewport's edit mode is inherited by all its child viewports.