Represents a view on a drawing sheet.
Usually a view is a logical portion of the sheet, containing one of the literal views of the model (e.g. top view, isometric view, cutaway view). Following this idea, the view is defined by a position in the sheet and a scale (real-world model dimensions vs on-paper dimensions).
new View(
position):View
Axis2d = ...
Position of the view.
View
readonlyelements:Set<Element>
Collection of elements.
position:
Axis2d
Position of the view.
scale:
Ratio
Scale of the view.
get id():
bigint
Returns object id.
bigint
get numberOfElements():
number
Returns the number of elements in the view.
Use elements.size instead.
number
get uuid():
`${string}-${string}-${string}-${string}-${string}`|null
Returns uuid of the drawing view. null if the drawing view has no assigned uuid (by default).
`${string}-${string}-${string}-${string}-${string}` | null
set uuid(
uuid):void
Sets uuid of the drawing view.
Uuid of the drawing view.
`${string}-${string}-${string}-${string}-${string}` | null
void
accept(
visitor):void
Applies a visitor for drawing elements.
Applied drawing element visitor.
void
add(
element):void
Adds an drawing element to the view.
Added drawing element.
void
Use elements.add(`element`) instead.