%%PageItemTitle%% $$Members$$

VectorDraw Web Library

JsPropertiesExtractor Send comments on this topic.
vdrawObj Class Members
See Also  Fields  Properties  Methods 
vdWebLibrary Namespace : vdrawObj Class

The following tables list the members exposed by vdrawObj.

Public Fields

 NameDescription
Public FieldvdActionDraw Represents a user define function of type vdActionDrawDelegate that will be called after default action draw.  
Public FieldvdAfterOpenDocument Get/Set a method that called after a document is successfully opened and can be handled by a function described by the vdAfterOpenDocumentDelegate.  
Public FieldvdAfterSaveDocument Get/Set a method that called after a document is successfully saved and can be handled by a function described by the vdAfterSaveDocumentDelegate.  
Public Fieldvdclick Get/Set a method that called whenever a click action is performed and can be handled by a function described by the vdclickDelegate.  
Public Fieldvddblclick Get/Set a method that called whenever a double click action is performed and can be handled by a function described by the vddblclickDelegate.  
Public FieldvdError Get/Set a method that called whenever an error occurs and can be handled by a function described by the vdErrorDelegate.  
Public FieldvdKeyDown Get/Set a method that called whenever a key is held down and can be handled by a function described by the vdKeyDownDelegate.  
Public FieldvdLoadXref Get/Set a method of vdLoadXrefDelegate type , that called when an External Reference Block need to be loaded from a file  
Public Fieldvdmousedown Get/Set a method that called whenever a mouse button is held down and can be handled by a function described by the vdmousedownDelegate.  
Public Fieldvdmousemove Get/Set a method that called whenever the mouse moves and can be handled by a function described by the vdmousemoveDelegate.  
Public FieldvdmousemoveAfter 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.  
Public Fieldvdmouseout 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.  
Public Fieldvdmouseup Get/Set a method that called whenever a mouse button is released and can be handled by a function described by the vdmouseupDelegate.  
Public Fieldvdmousewheel Get/Set a method that called whenever the mouse wheel is rotated and can be handled by a function described by the vdmousewheelDelegate.  
Public Fieldvdprogress 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.  
Public FieldvdPrompt 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.  
Public FieldvdSelectionModified Represents a user define function of type vdSelectionModifiedDelegate that will be called for every user select  
Public FieldvdtouchMove Get/Set a method that called whenever a touch action is performed and can be handled by a function described by the vdtouchMoveDelegate.  
Public FieldvdUpdateView Get/Set a method that called whenever the user's view is about to change (e.g. when panning).  
Public FieldvdXrefLoaded Get/Set a method of vdLoadXrefDelegate type , that called when an External Reference Block is completly loaded.  
Top

Public Properties

 NameDescription
Public PropertyActionScaleMode Get / Set the way that user scale action is applied, when user run the CmdScale or scale.  
Public Propertycanvas Returns the HTML object that displays all of the component's entities.  
Public PropertyDrawOverallEntities Get/Set a collection of temporary entities that will be drawn over all default drawing entities.  
Public PropertyGetDefaultTimeOutMilliseconds 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.  
Public PropertyGripManager Manage the grips of the active layout.Currently supported entities are:vdLine,vdPolyline,vdRect,vdText,vdCircles,vdArcs,vdEllipses,vdPoint,vdAttrib,vdAttribDef,vdInsert,vdImage.  
Public PropertyGroupsManager Returns an vdgroupsManager object that manage groups of the selected document  
Public PropertyIgnoreLockLayers If true the Lock property of layers is ignored and entities inside locked layers are selectable and can be modified. Default value is false.  
Public PropertyMaxImageSize 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.  
Public PropertyMessagesDictionary Returns the messagesdictionary object for this control.  
Public PropertyMouseWheelZoomScale 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  
Public PropertyPickSize Gets and sets the size of the rectangle, in pixels, around the point clicked in order to select the desired entities.  
Public PropertyscriptCommand Returns the ScriptCommands object for selected document control.  
Public PropertyToolTip Contains all the tooltip functionality. Check it here ToolTip.  
Top

Public Methods

 NameDescription
Public MethodActionDrawEntities 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.  
Public MethodActiveAction Returnes the active action (check BaseActionObj) of the document.  
Public MethodAddArc Adds a new vdArc in the document.  
Public MethodAddAttribDef Adds a new vdAttribDef object to the passed block.  
Public MethodAddBlock Add a block object in the blocks collection of the document. If the blockname already exists, the already created block is returned.  
Public MethodAddBlockFromFile Creates a vdBlock object from a file and add it in the blocks collection of the document.  
Public MethodAddBlockSymbol 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.  
Public MethodAddBox Creats a box as a vdPolyface object type and returns the created object.  
Public MethodAddCircle Adds a new vdCircle object in the document.  
Public MethodAddCone Creats a cone as a vdPolyface object type and returns the created object.  
Public MethodAddEllipse Adds a new vdEllipse object in the document.  
Public MethodAddHeatMap Create a vdPolyface by triangulating the passed points and color it by interpolating the paseed elevatedcolors.  
Public MethodAddImage Adds a new vdImage in the document.  
Public MethodAddLayer Adds a new layer to the document's layers collection.  
Public MethodAddLayout Adds a new empty layout to document with name "test" and return the Layout index id  
Public MethodAddLine Adds a new vdLine in the document.  
Public MethodAddPolyface Adds a new vdPolyface in the document.  
Public MethodAddPolyline Adds a new vdPolyline in the document.  
Public MethodAddRect Adds a new vdRect in the document.  
Public MethodAddRect2 Adds a new vdRect in the document.  
Public MethodAddSphere Creats a sphere as a vdPolyface object type and returns the created object.  
Public MethodAddText 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.  
Public MethodAddView Adds a new view to the document's view collection.  
Public MethodAddViewport Adds a new viewport to the active layout and returns the viewport object  
Public MethodAddXProperty Adds a new XProperty to the passed entity.  
Public MethodChangeOrder Places an existing object of the collection to the beginning or the end of the passed collection.  
Public MethodCmdCopy Copies an array of vdraw entities and moves the duplicates from one point to another.  
Public MethodCmdMove Moves an array of vdraw entities from one point to another.  
Public MethodCmdRotate Rotates an array of vdraw around a base point.  
Public MethodCmdScale Scales an array of vdraw entities.  
Public MethodCmdSelect Prompts the user to select objets and when finish passed throw the scriptCallBack delegate  
Public MethodCopyObjects Returns an array with clone of the objects inside passed entities collection  
Public MethodcreateNewHatchProperties Creates a new vdHatchProperties object.  
Public MethodDrawEntity Draws the passed entity on the ActiveRender Bitmap. The Refresh need to be called in order to update the Screen view.  
Public MethodEnableOsnapMode Enables or disables the osnap functionality without changing the osnap mode.  
Public MethodEnableRedraw Disable / Enable the redraw call .  
Public MethodEnableWebGL Enables/disables the use of WebGL in the library. Check article 70000445 for limitations and more information.  
Public MethodFig_codeToStringReturns 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,vdViewport,vdPolyhatch,vdDimension,vdMText,vdMultiline,

vdGroundSurface,vdLeader,vdArcAlignedText.  

Public MethodFindBlock Returns the Block defined by the given name.  
Public MethodFindLayer Returns the layer defined by the given name.  
Public MethodFindLayout Returns the layout index id of the given layout name.  
Public MethodFindLineType Returns the LineType defined by the given name.  
Public MethodFindTextStyle Returns the TextStyle defined by the given name.  
Public MethodFindView Returns the vdView object defined by the given name.  
Public MethodGetActiveHatchProperties Returns the active HatchProperties.  
Public MethodGetActiveLayout Returns the active layout.  
Public MethodGetActiveLayoutId Returns the active layout's id.  
Public MethodGetActivePenColor Returns the active penColor.  
Public MethodGetActiveThickness Returns the current active thickness.  
Public MethodGetActiveView Returns the active view.  
Public MethodGetAttribValue Returns the value of the first attribute matching the tag parameter. The check is no case sensitive.  
Public MethodGetBlocks Returns a collection with all block objects of the document.  
Public MethodGetDictItem Returns a table object(block,layer,textstyle,hatchpattern ,imagedefinition, linetype) from its handle string  
Public MethodGetDocument Returns the vdObject's document.  
Public MethodGetEnableSelection Get a value that defines if the selection is enabled. SetEnableSelection, GetEntityFromPoint ,GetEntitiesFromBox , GetEntitiesInWindowBox  
Public MethodGetEntitiesFromBox 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.  
Public MethodGetEntitiesFromLayer Returns all entities assigned to a specific layer and belongs to a Layout object.  
Public MethodGetEntitiesInWindowBox 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.  
Public MethodGetEntityArea Calculates the area of the given vdCurve object. The supported objects are vdPolyline, vdRect, vdCircle and vdEllipse.  
Public MethodGetEntityFromPoint 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.  
Public MethodGetEntityItem Returns an entity object from a handle string  
Public MethodGetEntityLength Calculates the length of the passes entity.  
Public MethodGetExtents Returns the extents of the visible entities of the active layout.  
Public MethodGetGrayScale get the grayscale mode  
Public MethodGetHatchPatterns Returns a collection with all hatchpattern objects of the document.  
Public MethodGetImageInterpolationMode Returns the interpolation mode used in order to smoothen the images used in vdImages and Materials.  
Public MethodGetImages Returns a collection with all image definition objects of the document.  
Public MethodGetLayers Returns a collection with all Layer objects of the document.  
Public MethodGetLayouts Returns a collection with all layout objects of the document included the Model  
Public MethodGetLineTypes Returns a collection with all linetypes objects of the document.  
Public MethodGetOsnapMode Gets the active osnap mode.  
Public MethodGetPixelSize Returns the size of one pixel.  
Public MethodGetTextStyles Returns a collection with all textstyle objects of the document.  
Public MethodGetUserLine Initiates an action (check BaseActionObj) where the user will create a new line in the component's drawing area.  
Public MethodGetUserPoint Initiates an action (check BaseActionObj) where the user will select a point in the component's drawing area.  
Public MethodGetUserRect Initiates an action (check BaseActionObj) where the user will create a new line in the component's drawing area.  
Public MethodGetViewBox Returns an object describing the current user's view in View Coordinates.  
Public MethodGetXProperty Returns the first XProperty by the given name to be found in the passed entity. Null if none is found.  
Public MethodGetXREFS Returns all the external references of the selected document.  
Public MethodGPS_AtPoint Returns the Latitude , Longitude array in decimal degrees , from the passed point in Drawing World Coordinate System  
Public MethodLookAt Changes the view of the document based on the passed parameters.  
Public MethodMeasureCurve Calculates an array of points over the entity, where each point has a distance equal to length from the previous point.  
Public MethodMergeDocument Merge the model entities of the passed document to this selected document  
Public MethodMoveView Move the view on the x, y and z axis of View Coordinates.  
Public MethodNumLayouts Returns the count of the document's layouts.  
Public MethodPixelToView Converts and returns the given point from pixel coordinates to view coordinates.  
Public MethodPixelToWorld Converts and returns the given point from pixel (relative to the upper left corner of the drawing area) coordinates to world coordinates.  
Public MethodPointAt_GPS Returns a point in Drawing World Coordinate System from the passed (Latitude and Longitude)  
Public MethodprintToImageData 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.  
Public MethodPrompt Calls the vdPrompt event passing the given string as parameter.  
Public Methodredraw Causes the component to redraw all the entities right away.  
Public MethodRefresh Refresh the graphics area by draw the active render bitmap on the screen Usually called after DrawEntity method  
Public MethodRotateView Rotate the view horizontally and vertically.  
Public MethodSaveDocument Save the active document object GetDocument to a data steam  
Public Methodscroll Moves the user's view on the x and y axis according to the given values.  
Public MethodSelectDocument Opens the given filename. If reload is true the drawing will be reloaded from its source.  
Public MethodSetActionCrossFillColor Sets the fill color of the new entity created (e.g through the GetUserRect 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.  
Public MethodSetActionFillColor Sets the fill color of the new rectangle created through the GetUserRect action. By default action's fillcolor property is null, so no collor will be used.  
Public MethodSetActionLineColor Sets the color of the new lines created through the actions.  
Public MethodSetActionLineWidth Sets the width of the new lines created through the actions.  
Public MethodSetActionOrthoMode 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.  
Public MethodSetActionOsnapColor Sets the passed 4 sized array (R,G,B,A) as the osnaps' mark color.  
Public MethodSetActionOsnapSize Sets the passed number as the osnaps' mark size in pixels.  
Public MethodSetActiveHatchProperties Sets the active HatchProperties to the specified object.  
Public MethodSetActiveLayer 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.  
Public MethodSetActiveLayout Set the passed layout object as active.If it is null or undefined the Model is activated. This method also post a redraw action.  
Public MethodSetActiveLayoutId Sets as active layout the one that has the given id.  
Public MethodSetActiveLineType Sets the given LineType as the document's active LineType.  
Public MethodSetActiveLineWeight Sets the given LineWeight as the document's active LineWeight.  
Public MethodSetActivePenColor Sets the given PenColor as the document's active color.  
Public MethodSetActivePenWidth Sets the given PenWidth as the document's active PenWidth.  
Public MethodSetActiveTextStyle Sets the given TextStyle as the document's active TextStyle.  
Public MethodSetActiveThickness Sets the active thickness value. This property gives all imported curves a stretch on Z axis.  
Public MethodSetActiveView change the active layout and the zoom properties according to the passed view  
Public MethodSetAttribValue Sets the defined value string to the attribute matching the tag parameter. The check is no case sensitive.  
Public MethodSetBlockSize Sets the number of triangles to be drawn as a block when using WebGL. The higher value the quicker the render will be. Caution! some devices may fail after a specific limit. Used with EnableWebGL.  
Public MethodSetDefaultTimeOutMilliseconds 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.  
Public MethodSetDocument Select a document object that previous was store into a variable by the GetDocument  
Public MethodSetEnableSelection 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 ,GetEntitiesFromBox , GetEntitiesInWindowBox  
Public MethodSetGrayScale Sets the grayscale mode  
Public MethodSetImageInterpolationMode Sets the interpolation mode used in order to smoothen the images used in vdImages and Materials.  
Public MethodSetOsnapMode Sets the desired osnap mode, e.g for endpoint osnaps check the OsnapMode_END.  
Public MethodSetRenderMode Change the Render mode of the active layout and post a redraw command  
Public MethodSetSize Sets the size of the selected canvas to the given parameters and updates the rendering context acoording the the selected canvas size.  
Public MethodSetStdView Positions the user's view to a prefixed position. Check StdView_TOP.  
Public MethodSetViewAngles Modify the current World to View Matrix using azimouth, tilt and twist angles that specify the view direction relative to World Coordinate System.  
Public MethodTriangulatePolyface Triangulates the VertexList of an existing vdPolyface using Delaunay algorithm and change the FaceList of the object according to calculated triangles.  
Public MethodUndoHistory return the ModificationHistory. of the selected document object.  
Public MethodUpdateFig Sets all property values of the given figure to null, in order for all these to be recalculated at the next redraw.  
Public MethodUpdateLayout Update Bounding box extends of the passed layout.  
Public MethodViewToPixel Converts and returns the given point from view coordinates to pixel coordinates relative to the upper left corner of the drawing area.  
Public MethodViewToWorld Converts and returns the given point from world coordinates to view coordinates.  
Public MethodWebGLisActive Returns true if webGl is intialized or false if it's not.  
Public MethodWorldToPixel Converts and returns the given point from world coordinates to pixel coordinates relative to the upper left corner of the drawing area.  
Public MethodWorldToView Converts and returns the given point from view coordinates to world coordinates.  
Public MethodzoomExtents Zooms the view appropriately in order to show all entities in the document.  
Public MethodzoomScale 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.  
Public Methodzoomwindow 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.  
Top

See Also