Table of Contents

Class vdrawObj

Namespace
vdWebLibrary
Assembly
JsPropertiesExtractor.dll

Represents the primary drawing canvas and high-level API surface used by the engine.

public class vdrawObj
Inheritance
vdrawObj
Inherited Members

Examples

// Obtain a vdrawObj from a vdmanager and create a new document:
var canvas = vdmanager.vdrawObject("canvasId");
canvas.New();
canvas.AddLine([0,0,0],[10,0,0], true);

Remarks

`vdrawObj` exposes methods, properties and events for creating and manipulating drawing

entities, managing views and layouts, handling user input and script commands, and

integrating with the rest of the engine (for example, saving/loading documents,

rendering and selection)

Instances are obtained from a vdmanager (for example, via vdmanager.vdrawObject).

Fields

AfterDrawInView

Represents a user define function of type AfterDrawInViewDelegate that will be called just after all document entities drawn.

AfterRedraw

Get/Set a method that called whenever a redraw of the vdraw canvas is finished.

OnCustomDraw

Represents a user define function of type CustomDrawDelegate that will be called just before a user custom define entity drawn.

OnCustomGetGrips

Represents a user define function of type CustomGetGripsDelegate that will be called when grips of a user custom define entity needed.

OnCustomGetOsnaps

Represents a user define function of type CustomGetOsnapsDelegate that will be called when Osnaps of a user custom define entity needed.

When implemented must return the Osnap points of the passed object, in the Object's Coordinate System

OnCustomMovegrips

Represents a user define function of type CustomMovegripsDelegate that will be called when grips of a user custom define entity is going to be moved .

OnIsCustom OnCustomDraw OnCustomGetGrips

OnCustomTransforms

Represents a user define function of type CustomTransformsDelegate that will be called when a matrix transformation is going to be applied to an entity.

When implemented geometrical properties must be transformed with passed matrix ofCustomTransformsArgs

OnIsCustom

Represents a user define function of type IsCustomDelegate that will be called by the cade when need to be checked if an entity is user custom define.

vdActionDraw

Represents a user define function of type vdActionDrawDelegate that will be called after default action draw.

vdAfterOpenDocument

Get/Set a method that called after a document is successfully opened and can be handled by a function described by the vdAfterOpenDocumentDelegate.

vdAfterSaveDocument

Get/Set a method that called after a document is successfully saved and can be handled by a function described by the vdAfterSaveDocumentDelegate.

vdDrawCursor

Represents a user define function of type vdActionDrawDelegate that will be called during the default cursor (cross) drawn.

The ovverride function returns true in order to cancel the default draw of the cursor

vdError

Get/Set a method that called whenever an error occurs and can be handled by a function described by the vdErrorDelegate.

vdFIlterActionPoint

Represents a user define function of type vdFIlterActionPointDelegate will be called just before action ends.

In order to allow the user to change the default SelectedPoint.

vdKeyDown

Get/Set a method that called whenever a key is held down and can be handled by a function described by the vdKeyDownDelegate.

vdLoadXref

Get/Set a method of vdLoadXrefDelegate type , that called when an External Reference Block need to be loaded from a file

vdPrompt

Get/Set a method that called whenever a messaged has to be showed for the completion of an action or likewise and can be handled by a function described by the vdPromptDelegate.

vdSelectionModified

Represents a user define function of type vdSelectionModifiedDelegate that will be called for every user select

vdUpdateView

Get/Set a method that called whenever the user's view is about to change (e.g. when panning).

vdXrefLoaded

Get/Set a method of vdLoadXrefDelegate type , that called when an External Reference Block is completly loaded.

vdclick

Get/Set a method that called whenever a click action is performed and can be handled by a function described by the vdclickDelegate.

vddblclick

Get/Set a method that called whenever a double click action is performed and can be handled by a function described by the vddblclickDelegate.

vdmousedown

Get/Set a method that called whenever a mouse button is held down and can be handled by a function described by the vdmousedownDelegate.

vdmousemove

Get/Set a method that called whenever the mouse moves and can be handled by a function described by the vdmousemoveDelegate.

vdmousemoveAfter

Get/Set a method that called whenever the mouse moves, after default web control actions and can be handled by a function described by the vdmousemoveDelegate.

vdmouseout

Get/Set a method that called whenever the cursor goes outside the area of the component's drawing area and can be handled by a function described by the vdmouseoutDelegate.

vdmouseup

Get/Set a method that called whenever a mouse button is released and can be handled by a function described by the vdmouseupDelegate.

vdmousewheel

Get/Set a method that called whenever the mouse wheel is rotated and can be handled by a function described by the vdmousewheelDelegate.

vdprogress

Get/Set a method that called whenever progress is made during the opening of a drawing and can be handled by a function described by the vdprogressDelegate.

vdtouchMove

Get/Set a method that called whenever a touch action is performed and can be handled by a function described by the vdtouchMoveDelegate.

Properties

ActionScaleMode

Get / Set the way that user scale action is applied, when user run the CmdScale(object, object, double, CmdScriptCallback) or scale(object, double, ScriptSelectDelegate).

ApplyDrawEdges

If it is true all the edge lines of polyfaces will be shown using the active pen color of the vdpolyface object. If it is false the edge lines of polyfaces will not be drawn.

CommandSelectionMode

Get/Set a value that controls the way that the user select entities with commands move, scale, rotate, copy , mirror, and select

DrawOverallEntities

Get/Set a collection of temporary entities that will be drawn over all default drawing entities.

GetDefaultTimeOutMilliseconds

Returns the default time out in milliseconds. Default time out is the time that the component waits after a draw action in order to start redrawing the entities. This happens for usability reasons, panning and scrolling are smoother.

GripManager

Manage the grips of the active layout.Currently supported entities are:vdLine,vdPolyline,vdRect,vdText,vdCircles,vdArcs,vdEllipses,vdPoint,vdAttrib,vdAttribDef,vdInsert,vdImage,vdNote.

GroupsManager

Returns an vdgroupsManager object that manage groups of the selected document

HideActionOnMouseOut

Get / Set if the action will be hide when the mouse is out of the canvas or not. Set it to false so the action will be shown either the cursor is out of the canvas. By default value is false.

IgnoreLockLayers

If true the Lock property of layers is ignored and entities inside locked layers are selectable and can be modified. Default value is false.

MaxImageSize

Controls the maximum possible value of an image's bitmap. Default value is 552960 (a resolution of 768 * 720). If 0 is set, the default value is used.

MessagesDictionary

Returns the messagesdictionary object for this control.

MouseWheelZoomScale

Get/Set the zooming scale used when zooming with the mouse wheel.Set this value under 1.0 to inverse the mouse wheel operation.Default value is 1.2

OSnapTrack

Enable / Disable the object snap tracking.

PickSize

Gets and sets the size of the rectangle, in pixels, around the point clicked in order to select the desired entities.

PolarTrack

Enable/disable the polar track behaviour

Default value is true

PolarTrackActionFlag

Get / Set if the PolarTrackAngle begins based to previous action line segment for line(object[], ScriptEntityDelegate) and polyline(object[], bool, int, ScriptEntityDelegate)

Default value is true

PolarTrackAngle

Get/Set the polar track angle in radians.

If is true then as you move your cursor to specify points, and a user action is open

waiting a reference point, a dotted polar tracking line appears at the tracking angles you specified with

PolarTrackAngle property. Also A text tool tip display the polar coordinates, you can disable it using ToolTip ShowPolarTrackToolTipText property.

Default value is HALF_PI 90 degrees

ProgressBarColor

Get / Set the progress bar color in [Red,Green,Blue].Defualt value is [0,0,128]

SelectionSort

Get / Set if user selection will be sorted or not

It can be one of the SelectionSort_NONE for no sorted or

SelectionSort_DEFAULT in wire 2d render mode sorted depend on draworder from the last entity drawn as first in the return collection

and in 3d render mode sorted depend on the depth of the entity from the entity nearest to eye first.

ToolTip

Contains all the tooltip functionality.

canvas

Returns the HTML object that displays all of the component's entities.

licval

Get/Set a string value that can be used to set the license for page and drawing paths. This value can be requested by the library distributor. With out this value a message will be displayed in the drawing area.

scriptCommand

Returns the ScriptCommands object for selected document control.

viewcube

Manage the 3d cube.

Methods

ActionDrawEntities(object, bool)

Draws the passed entities on the library's drawing area without adding them to the Document. This way they are drawn rapidly even if the Document has many entities.

ActiveAction()

Returnes the active action (check BaseActionObj) of the document.

ActiveRender()

returns the active Layout vdRender object

AddArc(object, double, double, bool, object)

Adds a new vdArc in the document.

AddAttribDef(object, int, double, string, string, object)

Add a new vdAttribDef to block definition with passed tag ,set the other passed properties to it and returns the new created vdAttribDef

AddBlock(string, object)

Add a block object in the blocks collection of the document. If the blockname already exists, the already created block is returned.

AddBlockFromFile(string, string, bool, vdLoadXrefDelegate, string, int)

Creates a vdBlock object from a file and add it in the blocks collection of the document. The function is running asynchronously, so you need to wait for the passed loadedDelegate event/delegate to be fired before you can get/manage the method results

AddBlockSymbol(string, object, double, double, bool, object)

Adds a new vdInsert object in the document. The insert's block is found in the Document's collection and by using the given blockname.

AddBox(object, double, double, double, double, bool, object)

Creats a box as a vdPolyface object type and returns the created object.

AddCircle(object, double, bool, object)

Adds a new vdCircle object in the document.

AddCone(object, double, double, double, int, bool, object)

Creats a cone as a vdPolyface object type and returns the created object.

AddEllipse(object, double, double, double, double, double, bool, object)

Adds a new vdEllipse object in the document.

AddFigureToCollection(object, object)

Adds a figure to the passed collection.

AddHeatMap(object[], object[], int, bool, object)

Create a vdPolyface by triangulating the passed points and color it by interpolating the paseed elevatedcolors.

AddImage(string, string, object, double, double, bool, object)

Adds a new vdImage in the document.

AddImageDefinition(string, string, ImageLoadedDelegate)

Adds a new Image Definition in the document. The function is running asynchronously, so you need to implement imageloadedCallback event/delegate to manage the method results

AddInfinityLine(int, object, object, bool, object)

Create and add a new infinity line to active layout entities using the active common properties. It can be Ray or Xline.

AddLayer(string)

Adds a new layer to the document's layers collection.

AddLayout(string)

Adds a new empty layout to document with the passed name and returns the Layout index id.

AddLine(object, object, bool, object)

Adds a new vdLine in the document.

AddPoint(object, bool, object)

Adds a vdPoint in the document.

AddPointCloud(object, object, bool, object)

Adds a vdPointCloud in the document.

AddPolyHatch(object[], object[], bool, object)

Adds a new vdPolyhatch in the document.

AddPolyface(object[], object[], bool, object)

Adds a new vdPolyface in the document.

There is a property of the polyface DrawEdges which by default is undefined.

If it is true the edge lines are drawn using the active PenColor of the polyface.

When the render mode is Shade or Render the color of the faces is specified by the fifth element of each face of the face list and the width of edge lines

can be changed by set a bigger value of line weight.

When WebGl is active so we use RenderGl or ShadeGl note that the line width of edge lines is always one pixel by a limitation of WebGl.

Also a new propery ApplyDrawEdges of canvas has been added which by default is true so the edge lines of polyfaces will be drawn.

We can set it to false in order not to be drawn any edge line of all the polyfaces of the document.For more information see ApplyDrawEdges

NOTE also that the edge lines of the polyface have NOT compatibility with the VDF component.This feature is only for WebControl.

AddPolyline(object, bool, object)

Adds a new vdPolyline in the document.

AddRect(object, object, bool, object)

Adds a new vdRect in the document.

AddRect2(object, double, double, double, bool, object)

Adds a new vdRect in the document.

AddSphere(object, double, int, int, bool, object)

Creats a sphere as a vdPolyface object type and returns the created object.

AddText(string, double, object, int, int, double, bool, object)

Adds the given string object as vdText in the document. The vdText is defined by the height, the insertionPt wich is a 3 sized array, the horizontal and vertical justifications. Also defined by the rotation.

AddView(string)

Adds a new view to the document's view collection.

AddViewport(object, double, double, object, double, bool)

Adds a new viewport to the active layout and returns the viewport object

AddXProperty(object, string, object)

Adds a new XProperty to the passed entity.

ChangeOrder(object, bool, object)

Places an existing object of the collection to the beginning or the end of the passed collection.

CmdCopy(object, object, object, CmdScriptCallback)

Copies an array of vdraw entities and moves the duplicates from one point to another. Check the function finished throw the passed scriptCallBack delegate

CmdMirror(object, object, double, CmdScriptCallback, bool)

Mirror an array of vdraw entities around a 2d axis. Check the function finished throw the passed scriptCallBack delegate

CmdMove(object, object, object, CmdScriptCallback)

Moves an array of vdraw entities from one point to another. Check the function finished throw the passed scriptCallBack delegate

CmdRotate(object, object, double, CmdScriptCallback)

Rotates an array of vdraw entities around a base point. Check the function finished throw the passed scriptCallBack delegate

CmdRotate3D(object, object, double, object, CmdScriptCallback)

Rotates an array of vdraw entities around an axis. Check the function finished throw the passed scriptCallBack delegate

CmdScale(object, object, double, CmdScriptCallback)

Scales an array of vdraw entities. Check the function finished throw the passed scriptCallBack delegate

CmdSelect(CmdScriptCallback)

The function is running asynchronously.Prompts the user to select objets and when finish passed throw the scriptCallBack delegate

CopyObjects(object)

Returns an array with clone of the objects inside passed entities collection

DrawEntity(object, object, int)

Draws the passed entity on the ActiveRender Bitmap. The Refresh() need to be called in order to update the Screen view.

EnableOsnapMode(bool)

Enables or disables the osnap functionality without changing the osnap mode.

EnableRedraw(bool)

Disable / Enable the redraw() call .

EnableWebGL(bool)

Enables/disables the use of WebGL in the library. Check article 70000445 for limitations and more information.

ExplodeObjects(object)

Note supported exploded objects are vdInsert, vdRect , vdPolyline(with lines and bulges) , vd3dFace, vdPolyface and entities with Explode collection property like dimensions or vdProxyFigures.

Note also that the ExplodeObjects does not support External Reference blocks.

Returns an array of the exploded entities of the passed entities collection.

See also explode()

Fig_codeToString(int)

Returns the corresponding vdFigure's name of the code passed.The supported values are:

vdLine,vdPolyline,vdText,vdRect,vdCircle,vdEllipse,vdArc,vdImage,vdInsert,vd3DFace,vdPolyface,

vdAttrib,vdAttribDef,vdInfinityLine,vdPoint,vdPointCloud,vdViewport,vdPolyhatch,vdDimension,vdMText,vdMultiline,

vdGroundSurface,vdLeader,vdArcAlignedText.

FilterEntities(object, vdFilterEntityDelegate)

Enumerate all the entities in the selected document and calls the passed function for each entity.

FindBlock(string)

Returns the Block defined by the given name.

FindImageDefinition(string)

Returns the ImageDefinition defined by the given name.

FindLayer(string)

Returns the layer defined by the given name.

FindLayout(string)

Returns the layout index id of the given layout name.

FindLineType(string)

Returns the LineType defined by the given name.

FindTextStyle(string)

Returns the TextStyle defined by the given name.

FindView(string)

Returns the vdView object defined by the given name.

GPS_AtPoint(double, double)

Returns the Latitude , Longitude array in decimal degrees , from the passed point in Drawing World Coordinate System

Generate3dPathSection(object[], object[], object[], double, double, object[], object[], bool, bool, object)

Create a new Polyface object following a given path and drawing a given section

GetActiveHatchProperties()

Returns the active HatchProperties.

GetActiveLayout()

Returns the active layout.

GetActiveLayoutId()

Returns the active layout's id.

GetActivePenColor()

Returns the active penColor.

GetActiveThickness()

Returns the current active thickness.

GetActiveView()

Returns the active view.

GetAttribValue(string, object)

Returns the value of the first attribute matching the tag parameter. The check is no case sensitive.

GetBlocks()

Returns a collection with all block objects of the document.

GetDictItem(object, string)

Returns a table object(block,layer,textstyle,hatchpattern ,imagedefinition, linetype) from its handle string

GetDocument()

Returns the document object associated with the control, or null if no document is selected.

the return document object model has mostly the same structure of properties as the VectorDrawFramework VectorDraw.Professional.vdObjects.vdDocument object

GetEnableSelection()

Get a value that defines if the selection is enabled. SetEnableSelection(bool), GetEntityFromPoint(int, int) ,GetEntitiesFromBox(int, int, int, int) , GetEntitiesInWindowBox(int, int, int, int)

GetEntitiesFence(object, object)

Returns a collection with all entities which have been selected.

GetEntitiesFromBox(int, int, int, int)

Returns an array of vdraw entities that cross the specified box. Even if a small part of an entity lies inside the box, it is added in the array. The first two parameters define the first point of the box and the rest define the second point in pixel coordinates.

GetEntitiesFromLayer(string)

Returns all entities assigned to a specific layer and belongs to a Layout object.

GetEntitiesFromPolygon(object, object)

A crossing polygon selection Returns an array of vdraw entities that cross the specified closed polygon. Even if a small part of an entity lies inside the polygon, it is added in the array.

GetEntitiesInWindowBox(int, int, int, int)

Returns an array of vdraw entities that lie entirely inside the specified box. Even if a small part of an entity lies outside the box, the entity is ignored. The first two parameters define the first point of the box and the rest define the second point in pixel coordinates.

GetEntitiesInWindowPolygon(object, object)

A window polygon selection Returns an array of vdraw entities that lie entirely inside the specified closed polygon.

Even if a small part of an entity lies outside the polygon, the entity is ignored.

GetEntityArea(object)

Calculates the area of the given vdCurve object. The supported objects are vdPolyline, vdRect, vdCircle and vdEllipse.

GetEntityBBox(object)

Returns the passed entity or array of entities Bounding Box in world coordinate system

GetEntityECSMatrix(object)

Gets the matrix which is used to transform vectors or points from the object's coordinate system (OCS) to the World Coordinate System (WCS).

GetEntityFromPoint(int, int)

Returns the entity that resides under the given point. The point is defined by x and y coordinates in pixels relative to the upper left corner of the drawing area.

GetEntityItem(string)

Returns an entity object from a handle string

GetEntityLength(object)

Calculates the length of the passes entity.

GetEntityPosition(object, object)

Return the entity's (zero based)position inside the collection it belongs to.or -1 for no success

GetEntitySamplePoints(object)

Returns an array of points on the curve from the start to the end point of the curve in world coordinate system.

GetExtents()

Returns the extents of the visible entities of the active layout.

GetGrayScale()

get the grayscale mode

GetHatchPatterns()

Returns a collection with all hatchpattern objects of the document.

GetImageInterpolationMode()

Returns the interpolation mode used in order to smoothen the images used in vdImages and Materials.

GetImages()

Returns a collection with all image definition objects of the document.

GetLayers()

Returns a collection with all Layer objects of the document.

GetLayouts()

Returns a collection with all layout objects of the document included the Model

GetLineTypes()

Returns a collection with all linetypes objects of the document.

GetOsnapMode()

Gets the active osnap mode.

GetPixelSize()

Returns the size of one pixel.

GetTextStyles()

Returns a collection with all textstyle objects of the document.

GetUserLine(onStateChangedDelegate)

Initiates an action (check BaseActionObj) where the user will create a new line in the component's drawing area. The function is running asynchronously, so you need to implement statechangeDelegate event/delegate to manage the method results The action has the actionType == ACTION_LINE_WORLD

GetUserPoint(onStateChangedDelegate)

Initiates an action (check BaseActionObj) where the user will select a point in the component's drawing area. The function is running asynchronously, so you need to implement statechangeDelegate event/delegate to manage the method results The action has the actionType == ACTION_POINT_WORLD

GetUserRect(onStateChangedDelegate)

Initiates an action (check BaseActionObj) where the user will create a new line in the component's drawing area. The function is running asynchronously, so you need to implement statechangeDelegate event/delegate to manage the method results The action has the actionType == ACTION_RECT_VIEW

GetViewBox()

Returns an object describing the current user's view in View Coordinates.

GetXProperty(object, string)

Returns the first XProperty by the given name to be found in the passed entity. Null if none is found.

GetXREFS()

Returns all the external references of the selected document.

LookAt(object, object, double)

Changes the view of the document based on the passed parameters.

MeasureCurve(object, double)

Calculates an array of points over the entity, where each point has a distance equal to length from the previous point.

MergeDocument(string, MergeDocumentFinshedDelegate, int, string)

Merge the model entities of the passed document to this selected document The function is running asynchronously, so you need to wait for the passed finishCallback event/delegate to be fired before you can get/manage the method results

MergeEntities(object, object[])

Add the clone of passed entities belong to sourceDocument to this document's active layout entities

layers linetypes images textstyles hatchpatterns and blocks reference passed entities are also added to this document

MoveView(double, double, double)

Move the view on the x, y and z axis of View Coordinates.

New()

Opens a new empty drawing with default Model Layout using standard Linetypes,HatchPatterns,Layers,Blocks and TextStyles. The function is running asynchronously, vdAfterOpenDocument is fired when the selected file is loaded

NumLayouts()

Returns the count of the document's layouts.

PixelToView(object)

Converts and returns the given point from pixel coordinates to view coordinates.

PixelToWorld(int, int)

Converts and returns the given point from pixel (relative to the upper left corner of the drawing area) coordinates to world coordinates.

PointAt_GPS(double, double)

Returns a point in Drawing World Coordinate System from the passed (Latitude and Longitude)

Prompt(string)

Calls the vdPrompt event passing the given string as parameter.

RecalculateBlockReferencesAttribs(object)

Enumerate all vdInsert that refence to the passed block and fix the Attributes collection by adding new ones that are not exist to block reference Attributes

Refresh()

Refresh the graphics area by draw the active render bitmap on the screen Usually called after DrawEntity(object, object, int) method

RotateView(double, double)

Rotate the view horizontally and vertically.

SaveDocument(bool)

Save the active document object GetDocument to a data stream

SelectDocument(string, bool, SelectDocumentFinishedDelegate)

Opens the given filename. If reload is true the drawing will be reloaded from its source. We are also able to pass parameters in the function and an access token like: vdObj.SelectDocument("vddocument.vds?param1=param1& param2=param2&token= 123"); or vdObj.SelectDocument("vddocument.vds?token= 123"); Note: The token parameter has to be written exactly like: token= myvalue.

SelectDocumentBlob(string, string, SelectDocumentFinishedDelegate)

Selectect and load a document through a memory string data. The function is running asynchronously, vdAfterOpenDocument is fired when the selected file is loaded Also from the version 8006.0.3 we can use the ToScriptData and the FromScriptData on the VDF in order to export a document to a string array and send it to WebControl and load it. See more about this procedure here: https://vdraw.com/articles/wish/70001846-export-script-to-memory-string-data-/

SetActionCrossFillColor(object)

Sets the fill color of the new entity created (e.g through the GetUserRect(onStateChangedDelegate) action) when the rect's low point is to the right of the rect's high point. By default, the action's crossfillcolor property is the same to the fillcolor, so no collor will be used.

SetActionFillColor(object)

Sets the fill color of the new rectangle created through the GetUserRect(onStateChangedDelegate) action. By default action's fillcolor property is null, so no collor will be used.

SetActionLineColor(object)

Sets the color of the new lines created through the actions.

SetActionLineWidth(int)

Sets the width of the new lines created through the actions.

SetActionOrthoMode(bool)

Set the orthomode property of the actions that waiting for a user point referenced by an other one. If true Constrains cursor movement to the perpendicular.

SetActionOsnapColor(object)

Sets the passed 4 sized array (R,G,B,A) as the osnaps' mark color.

SetActionOsnapSize(int)

Sets the passed number as the osnaps' mark size in pixels.

SetActiveHatchProperties(object)

Sets the active HatchProperties to the specified object.

SetActiveLayer(object)

Sets the given Layer as the document's active Layer. After setting the SetActiveLayer all of the new entities will be added as reference in the layer.

SetActiveLayout(object)

Set the passed layout object as active.If it is null or undefined the Model is activated. This method also post a redraw action.

SetActiveLayoutId(int)

Sets as active layout the one that has the given id.

SetActiveLineType(object)

Sets the given LineType as the document's active LineType.

SetActiveLineWeight(int)

Sets the given LineWeight as the document's active LineWeight.

SetActivePenColor(object)

Sets the given PenColor as the document's active color.

SetActivePenWidth(double)

Sets the given PenWidth as the document's active PenWidth.

SetActiveTextStyle(object)

Sets the given TextStyle as the document's active TextStyle.

SetActiveThickness(double)

Sets the active thickness value. This property gives all imported curves a stretch on Z axis.

SetActiveView(object)

change the active layout and the zoom properties according to the passed view

SetAttribValue(string, string, object)

Sets the defined value string to the attribute matching the tag parameter. The check is no case sensitive.

SetBlockSize(int)

Sets the number of primitives to be drawn as a block when using WebGL. The higher value the quicker the render will be.

SetDefaultTimeOutMilliseconds(int)

Sets the default time out in milliseconds. Default time out is the time that the component waits after a draw action in order to start redrawing the entities. This happens for usability reasons, panning and scrolling are smoother.

SetDocument(object)

Select a document object that previous was store into a variable by the GetDocument()

SetEnableSelection(bool)

Enable / Disable the Selection buffer that keeps information of entities drawn in each pixel. If this value is false, no entities can be detected under a pixel (no selection). GetEntityFromPoint(int, int) ,GetEntitiesFromBox(int, int, int, int) , GetEntitiesInWindowBox(int, int, int, int)

SetEntityPosition(object, int, object)

change the entity position inside the passed collection

SetGrayScale(bool)

Sets the grayscale mode

SetImageInterpolationMode(int)

Sets the interpolation mode used in order to smoothen the images used in vdImages and Materials.

SetOsnapMode(int)

Sets the desired osnap mode, e.g for endpoint osnaps check the OsnapMode_END.

SetRenderMode(int)

Change the Render mode of the active layout and post a redraw command

SetSize(int, int)

Sets the size of the selected canvas to the given parameters and updates the rendering context acoording the the selected canvas size.

SetStdView(int)

Positions the user's view to a prefixed position. Check StdView_TOP.

SetViewAngles(double, double, double, object)

Modify the current World to View Matrix using azimouth, tilt and twist angles that specify the view direction relative to World Coordinate System.

TriangulatePolyface(object, int)

Triangulates the VertexList of an existing vdPolyface using Delaunay algorithm and change the FaceList of the object according to calculated triangles.

UndoHistory()

return the ModificationHistory. of the selected document object.

UpdateFig(object)

Sets all property values of the given figure to null, in order for all these to be recalculated at the next redraw.

UpdateLayout(object, bool)

Update Bounding box extends of the passed layout.

ViewToPixel(object)

Converts and returns the given point from view coordinates to pixel coordinates relative to the upper left corner of the drawing area.

ViewToWorld(object)

Converts and returns the given point from view coordinates to world coordinates.

WebGLisActive()

Returns true if webGl is intialized or false if it's not.

WorldToPixel(object)

Converts and returns the given point from world coordinates to pixel coordinates relative to the upper left corner of the drawing area.

WorldToView(object)

Converts and returns the given point from view coordinates to world coordinates.

createNewHatchProperties(object, object, object, double, double)

Creates a new vdHatchProperties object.

printToImageData(int, int, object, object, object, int, int)

Returns an array of data that can be used in an image in order to help the user print the drawing using the given parameters.

redraw()

Causes the component to redraw all the entities right away.

scroll(object, int, int, int)

Moves the user's view on the x and y axis according to the given values.

zoomExtents()

Zooms the view appropriately in order to show all entities in the document.

zoomScale(int, int, double, int)

Scales the user's view in the component. The positive or negative scale is defined by the Delta value. X and y define the center point of the scaling in pixels.

zoomwindow(object, object)

Zooms the view to the window specified by the two points. The two points are in the view coordination system and are defined by two 3 sized arrays.

See Also