diff --git a/docs/files/svgcanvas-js.html b/docs/files/svgcanvas-js.html index 4efb28b0..9ea577f0 100644 --- a/docs/files/svgcanvas-js.html +++ b/docs/files/svgcanvas-js.html @@ -11,15 +11,15 @@ if (browserType) {document.write("
");if (browserV -

SvgCanvas

The main SvgCanvas class that manages all SVG-related functions

Parameters

containerThe container HTML element that should hold the SVG root element
configAn object that contains configuration data
Summary
SvgCanvasThe main SvgCanvas class that manages all SVG-related functions
toXmlConverts characters in a string to XML-friendly entities.
fromXmlConverts XML entities in a string to single characters.
Undo/Redo history management
ChangeElementCommandHistory command to make a change to an element.
ChangeElementCommand.applyPerforms the stored change action
ChangeElementCommand.unapplyReverses the stored change action
ChangeElementCommand.elementsReturns array with element associated with this command
InsertElementCommandHistory command for an element that was added to the DOM
InsertElementCommand.applyRe-Inserts the new element
InsertElementCommand.unapplyRemoves the element
InsertElementCommand.elementsReturns array with element associated with this command
RemoveElementCommandHistory command for an element removed from the DOM
RemoveElementCommand.applyRe-removes the new element
RemoveElementCommand.unapplyRe-adds the new element
RemoveElementCommand.elementsReturns array with element associated with this command
MoveElementCommandHistory command for an element that had its DOM position changed
MoveElementCommand.unapplyRe-positions the element
MoveElementCommand.unapplyPositions the element back to its original location
InsertElementCommand.elementsReturns array with element associated with this command
Selection
clearSelectionClears the selection.
addToSelectionAdds a list of elements to the selection.
removeFromSelectionRemoves elements from the selection.
Serialization
saveSerializes the current drawing into SVG XML text and returns it to the ‘saved’ handler.
getSvgStringReturns the current drawing as raw SVG XML text.
setSvgStringThis function sets the current drawing as the input SVG XML.
importSvgStringThis function imports the input SVG XML into the current layer in the drawing
Layers
createLayerCreates a new top-level layer in the drawing with the given name, sets the current layer to it, and then clears the selection This function then calls the ‘changed’ handler.
deleteCurrentLayerDeletes the current layer from the drawing and then clears the selection.
getNumLayersReturns the number of layers in the current drawing.
getLayerReturns the name of the ith layer.
getCurrentLayerReturns the name of the currently selected layer.
setCurrentLayerSets the current layer.
renameCurrentLayerRenames the current layer.
setCurrentLayerPositionChanges the position of the current layer to the new value.
getLayerVisibilityReturns whether the layer is visible.
setLayerVisibilitySets the visibility of the layer.
moveSelectedToLayerMoves the selected elements to layername.
getLayerOpacityReturns the opacity of the given layer.
setLayerOpacitySets the opacity of the given layer.
selectAllInCurrentLayerClears the selection, then adds all elements in the current layer to the selection.
clearClears the current document.
Fill and Stroke
getVersionReturns a string which describes the revision number of SvgCanvas.
+

SvgCanvas

The main SvgCanvas class that manages all SVG-related functions

Parameters

containerThe container HTML element that should hold the SVG root element
configAn object that contains configuration data
Summary
SvgCanvasThe main SvgCanvas class that manages all SVG-related functions
toXmlConverts characters in a string to XML-friendly entities.
fromXmlConverts XML entities in a string to single characters.
Undo/Redo history management
ChangeElementCommandHistory command to make a change to an element.
ChangeElementCommand.applyPerforms the stored change action
ChangeElementCommand.unapplyReverses the stored change action
ChangeElementCommand.elementsReturns array with element associated with this command
InsertElementCommandHistory command for an element that was added to the DOM
InsertElementCommand.applyRe-Inserts the new element
InsertElementCommand.unapplyRemoves the element
InsertElementCommand.elementsReturns array with element associated with this command
RemoveElementCommandHistory command for an element removed from the DOM
RemoveElementCommand.applyRe-removes the new element
RemoveElementCommand.unapplyRe-adds the new element
RemoveElementCommand.elementsReturns array with element associated with this command
MoveElementCommandHistory command for an element that had its DOM position changed
MoveElementCommand.unapplyRe-positions the element
MoveElementCommand.unapplyPositions the element back to its original location
MoveElementCommand.elementsReturns array with element associated with this command
BatchCommandHistory command that can contain/execute multiple other commands
BatchCommand.applyRuns “apply” on all subcommands
BatchCommand.unapplyRuns “unapply” on all subcommands
BatchCommand.elementsIterate through all our subcommands and returns all the elements we are changing
BatchCommand.addSubCommandAdds a given command to the history stack
BatchCommand.isEmptyReturns a boolean indicating whether or not the batch command is empty
SelectorPrivate class for DOM element selection boxes
Functions
Selector.resetUsed to reset the id and element that the selector is attached to
Selector.showGripsShow the resize grips of this selector
Selector.updateGripCursorsUpdates cursors for corner grips on rotation so arrows point the right way
Selector.resizeUpdates the selector to match the element’s size
SelectorManagerpublic class to manage all selector objects (selection boxes)
SelectorManager.initGroupResets the parent selector group element
SelectorManager.requestSelectorReturns the selector based on the given element
SelectorManager.releaseSelectorRemoves the selector of the given element (hides selection box)
SelectorManager.getRubberBandBoxReturns the rubberBandBox DOM element.
Selection
clearSelectionClears the selection.
addToSelectionAdds a list of elements to the selection.
removeFromSelectionRemoves elements from the selection.
Serialization
saveSerializes the current drawing into SVG XML text and returns it to the ‘saved’ handler.
getSvgStringReturns the current drawing as raw SVG XML text.
setSvgStringThis function sets the current drawing as the input SVG XML.
importSvgStringThis function imports the input SVG XML into the current layer in the drawing
Layers
createLayerCreates a new top-level layer in the drawing with the given name, sets the current layer to it, and then clears the selection This function then calls the ‘changed’ handler.
deleteCurrentLayerDeletes the current layer from the drawing and then clears the selection.
getNumLayersReturns the number of layers in the current drawing.
getLayerReturns the name of the ith layer.
getCurrentLayerReturns the name of the currently selected layer.
setCurrentLayerSets the current layer.
renameCurrentLayerRenames the current layer.
setCurrentLayerPositionChanges the position of the current layer to the new value.
getLayerVisibilityReturns whether the layer is visible.
setLayerVisibilitySets the visibility of the layer.
moveSelectedToLayerMoves the selected elements to layername.
getLayerOpacityReturns the opacity of the given layer.
setLayerOpacitySets the opacity of the given layer.
selectAllInCurrentLayerClears the selection, then adds all elements in the current layer to the selection.
clearClears the current document.
Fill and Stroke
getVersionReturns a string which describes the revision number of SvgCanvas.
-

toXml

toXml = function(str)

Converts characters in a string to XML-friendly entities.

Example: “&” becomes “&” Parameters: str - The string to be converted Returns: The converted string

+

toXml

toXml = function(str)

Converts characters in a string to XML-friendly entities.

Example: “&” becomes “&”

Parameters

strThe string to be converted Returns: The converted string
-

fromXml

fromXml = function(str)

Converts XML entities in a string to single characters.  Example: “&” becomes “&” Parameters: str - The string to be converted Returns: The converted string

+

fromXml

fromXml = function(str)

Converts XML entities in a string to single characters.  Example: “&” becomes “&”

Parameters

strThe string to be converted Returns: The converted string

Undo/Redo history management

-

ChangeElementCommand

function ChangeElementCommand(elem,
attrs,
text)

History command to make a change to an element.  Usually an attribute change, but can also be textcontent.

Parameters

elemThe DOM element that was changed
attrsAn object with the attributes to be changed and the values they had before the change
textAn optional string visible to user related to this change
+

ChangeElementCommand

var ChangeElementCommand = this.undoCmd.changeElement = function(elem,
attrs,
text)

History command to make a change to an element.  Usually an attribute change, but can also be textcontent.

Parameters

elemThe DOM element that was changed
attrsAn object with the attributes to be changed and the values they had before the change
textAn optional string visible to user related to this change

ChangeElementCommand.apply

Performs the stored change action

@@ -27,7 +27,7 @@ if (browserType) {document.write("
");if (browserV

ChangeElementCommand.elements

Returns array with element associated with this command

-

InsertElementCommand

function InsertElementCommand(elem,
text)

History command for an element that was added to the DOM

Parameters

elemThe newly added DOM element
textAn optional string visible to user related to this change
+

InsertElementCommand

var InsertElementCommand = this.undoCmd.insertElement = function(elem,
text)

History command for an element that was added to the DOM

Parameters

elemThe newly added DOM element
textAn optional string visible to user related to this change

InsertElementCommand.apply

Re-Inserts the new element

@@ -35,7 +35,7 @@ if (browserType) {document.write("
");if (browserV

InsertElementCommand.elements

Returns array with element associated with this command

-

RemoveElementCommand

function RemoveElementCommand(elem,
parent,
text)

History command for an element removed from the DOM

Parameters

elemThe removed DOM element
elemThe DOM element’s parent
textAn optional string visible to user related to this change
+

RemoveElementCommand

var RemoveElementCommand = this.undoCmd.removeElement = function(elem,
parent,
text)

History command for an element removed from the DOM

Parameters

elemThe removed DOM element
parentThe DOM element’s parent
textAn optional string visible to user related to this change

RemoveElementCommand.apply

Re-removes the new element

@@ -43,67 +43,101 @@ if (browserType) {document.write("
");if (browserV

RemoveElementCommand.elements

Returns array with element associated with this command

-

MoveElementCommand

function MoveElementCommand(elem,
oldNextSibling,
oldParent,
text)

History command for an element that had its DOM position changed

Parameters

elemThe DOM element that was moved
oldNextSiblingThe element’s next sibling before it was moved
oldParentThe element’s parent before it was moved
textAn optional string visible to user related to this change
+

MoveElementCommand

var MoveElementCommand = this.undoCmd.moveElement = function(elem,
oldNextSibling,
oldParent,
text)

History command for an element that had its DOM position changed

Parameters

elemThe DOM element that was moved
oldNextSiblingThe element’s next sibling before it was moved
oldParentThe element’s parent before it was moved
textAn optional string visible to user related to this change

MoveElementCommand.unapply

Re-positions the element

MoveElementCommand.unapply

Positions the element back to its original location

-

InsertElementCommand.elements

Returns array with element associated with this command

+

MoveElementCommand.elements

Returns array with element associated with this command

-

Selection

+

BatchCommand

var BatchCommand = this.undoCmd.batch = function(text)

History command that can contain/execute multiple other commands

Parameters

textAn optional string visible to user related to this change
-

clearSelection

this.clearSelection = function(noCall)

Clears the selection.  The ‘selected’ handler is then called.

+

BatchCommand.apply

Runs “apply” on all subcommands

-

addToSelection

this.addToSelection = function(elemsToAdd,
showGrips)

Adds a list of elements to the selection.  The ‘selected’ handler is then called.

Parameters

elemsToAddan array of DOM elements to add to the selection
showGripsa boolean flag indicating whether the resize grips should be shown
+

BatchCommand.unapply

Runs “unapply” on all subcommands

-

removeFromSelection

this.removeFromSelection = function(elemsToRemove)

Removes elements from the selection.

Parameters

elemsToRemovean array of elements to remove from selection
+

BatchCommand.elements

Iterate through all our subcommands and returns all the elements we are changing

-

Serialization

+

BatchCommand.addSubCommand

Adds a given command to the history stack

-

save

this.save = function(opts)

Serializes the current drawing into SVG XML text and returns it to the ‘saved’ handler.  This function also includes the XML prolog.  Clients of the SvgCanvas bind their save function to the ‘saved’ event.

Returns

Nothing

+

BatchCommand.isEmpty

Returns a boolean indicating whether or not the batch command is empty

-

getSvgString

this.getSvgString = function()

Returns the current drawing as raw SVG XML text.

Returns

The current drawing as raw SVG XML text.

+

Selector

Private class for DOM element selection boxes

Parameters

idinteger to internally indentify the selector
elemDOM element associated with this selector
Summary
Functions
Selector.resetUsed to reset the id and element that the selector is attached to
Selector.showGripsShow the resize grips of this selector
Selector.updateGripCursorsUpdates cursors for corner grips on rotation so arrows point the right way
Selector.resizeUpdates the selector to match the element’s size
-

setSvgString

this.setSvgString = function(xmlString)

This function sets the current drawing as the input SVG XML.

Parameters

xmlStringThe SVG as XML text.

Returns

This function returns false if the set was unsuccessful, true otherwise.

+

Functions

-

importSvgString

This function imports the input SVG XML into the current layer in the drawing

Parameters

xmlStringThe SVG as XML text.

Returns

This function returns false if the import was unsuccessful, true otherwise.

+

Selector.reset

Used to reset the id and element that the selector is attached to

Parameters

eDOM element associated with this selector
-

Layers

+

Selector.showGrips

Show the resize grips of this selector

Parameters

showboolean indicating whether grips should be shown or not
-

createLayer

this.createLayer = function(name)

Creates a new top-level layer in the drawing with the given name, sets the current layer to it, and then clears the selection This function then calls the ‘changed’ handler.  This is an undoable action.

Parameters

nameThe given name
+

Selector.updateGripCursors

Updates cursors for corner grips on rotation so arrows point the right way

Parameters

angleFloat indicating current rotation angle in degrees
-

deleteCurrentLayer

this.deleteCurrentLayer = function()

Deletes the current layer from the drawing and then clears the selection.  This function then calls the ‘changed’ handler.  This is an undoable action.

+

Selector.resize

Updates the selector to match the element’s size

-

getNumLayers

this.getNumLayers = function()

Returns the number of layers in the current drawing.

Returns

The number of layers in the current drawing.

+

SelectorManager

public class to manage all selector objects (selection boxes)

Summary
SelectorManager.initGroupResets the parent selector group element
SelectorManager.requestSelectorReturns the selector based on the given element
SelectorManager.releaseSelectorRemoves the selector of the given element (hides selection box)
SelectorManager.getRubberBandBoxReturns the rubberBandBox DOM element.
Selection
clearSelectionClears the selection.
addToSelectionAdds a list of elements to the selection.
removeFromSelectionRemoves elements from the selection.
Serialization
saveSerializes the current drawing into SVG XML text and returns it to the ‘saved’ handler.
getSvgStringReturns the current drawing as raw SVG XML text.
setSvgStringThis function sets the current drawing as the input SVG XML.
importSvgStringThis function imports the input SVG XML into the current layer in the drawing
Layers
createLayerCreates a new top-level layer in the drawing with the given name, sets the current layer to it, and then clears the selection This function then calls the ‘changed’ handler.
deleteCurrentLayerDeletes the current layer from the drawing and then clears the selection.
getNumLayersReturns the number of layers in the current drawing.
getLayerReturns the name of the ith layer.
getCurrentLayerReturns the name of the currently selected layer.
setCurrentLayerSets the current layer.
renameCurrentLayerRenames the current layer.
setCurrentLayerPositionChanges the position of the current layer to the new value.
getLayerVisibilityReturns whether the layer is visible.
setLayerVisibilitySets the visibility of the layer.
moveSelectedToLayerMoves the selected elements to layername.
getLayerOpacityReturns the opacity of the given layer.
setLayerOpacitySets the opacity of the given layer.
selectAllInCurrentLayerClears the selection, then adds all elements in the current layer to the selection.
clearClears the current document.
Fill and Stroke
getVersionReturns a string which describes the revision number of SvgCanvas.
-

getLayer

this.getLayer = function(i)

Returns the name of the ith layer.  If the index is out of range, an empty string is returned.

Parameters

ithe zero-based index of the layer you are querying.

Returns

The name of the ith layer

+

SelectorManager.initGroup

Resets the parent selector group element

-

getCurrentLayer

this.getCurrentLayer = function()

Returns the name of the currently selected layer.  If an error occurs, an empty string is returned.

Returns

The name of the currently active layer.

+

SelectorManager.requestSelector

Returns the selector based on the given element

Parameters

elemDOM element to get the selector for
-

setCurrentLayer

this.setCurrentLayer = function(name)

Sets the current layer.  If the name is not a valid layer name, then this function returns false.  Otherwise it returns true.  This is not an undo-able action.

Parameters

namethe name of the layer you want to switch to.

Returns

true if the current layer was switched, otherwise false

+

SelectorManager.releaseSelector

Removes the selector of the given element (hides selection box)

Parameters

elemDOM element to remove the selector for
-

renameCurrentLayer

this.renameCurrentLayer = function(newname)

Renames the current layer.  If the layer name is not valid (i.e. unique), then this function does nothing and returns false, otherwise it returns true.  This is an undo-able action.

Parameters

newnamethe new name you want to give the current layer.  This name must be unique among all layer names.

Returns

true if the rename succeeded, false otherwise.

+

SelectorManager.getRubberBandBox

Returns the rubberBandBox DOM element.  This is the rectangle drawn by the user for selecting/zooming

-

setCurrentLayerPosition

this.setCurrentLayerPosition = function(newpos)

Changes the position of the current layer to the new value.  If the new index is not valid, this function does nothing and returns false, otherwise it returns true.  This is an undo-able action.

Parameters

newposThe zero-based index of the new position of the layer.  This should be between
0 and (number of layers1)

Returns

true if the current layer position was changed, false otherwise.

+

Selection

-

getLayerVisibility

this.getLayerVisibility = function(layername)

Returns whether the layer is visible.  If the layer name is not valid, then this function returns false.

Parameters

layernamethe name of the layer which you want to query.

Returns

The visibility state of the layer, or false if the layer name was invalid.

+

clearSelection

this.clearSelection = function(noCall)

Clears the selection.  The ‘selected’ handler is then called.

-

setLayerVisibility

this.setLayerVisibility = function(layername,
bVisible)

Sets the visibility of the layer.  If the layer name is not valid, this function return false, otherwise it returns true.  This is an undo-able action.

Parameters

layernamethe name of the layer to change the visibility
bVisibletrue/false, whether the layer should be visible

Returns

true if the layer’s visibility was set, false otherwise

+

addToSelection

this.addToSelection = function(elemsToAdd,
showGrips)

Adds a list of elements to the selection.  The ‘selected’ handler is then called.

Parameters

elemsToAddan array of DOM elements to add to the selection
showGripsa boolean flag indicating whether the resize grips should be shown
-

moveSelectedToLayer

this.moveSelectedToLayer = function(layername)

Moves the selected elements to layername.  If the name is not a valid layer name, then false is returned.  Otherwise it returns true.  This is an undo-able action.

Parameters

layernamethe name of the layer you want to which you want to move the selected elements

Returns

true if the selected elements were moved to the layer, false otherwise.

+

removeFromSelection

this.removeFromSelection = function(elemsToRemove)

Removes elements from the selection.

Parameters

elemsToRemovean array of elements to remove from selection
-

getLayerOpacity

this.getLayerOpacity = function(layername)

Returns the opacity of the given layer.  If the input name is not a layer, null is returned.

Parameters

layernamename of the layer on which to get the opacity

Returns

The opacity value of the given layer.  This will be a value between 0.0 and 1.0, or null if layername is not a valid layer

+

Serialization

-

setLayerOpacity

this.setLayerOpacity = function(layername,
opacity)

Sets the opacity of the given layer.  If the input name is not a layer, nothing happens.  This is not an undo-able action.  NOTE: this function exists solely to apply a highlighting/de-emphasis effect to a layer, when it is possible for a user to affect the opacity of a layer, we will need to allow this function to produce an undo-able action.  If opacity is not a value between 0.0 and 1.0, then nothing happens.

Parameters

layernamename of the layer on which to set the opacity
opacitya float value in the range 0.0-1.0
+

save

this.save = function(opts)

Serializes the current drawing into SVG XML text and returns it to the ‘saved’ handler.  This function also includes the XML prolog.  Clients of the SvgCanvas bind their save function to the ‘saved’ event.

Returns

Nothing

-

selectAllInCurrentLayer

this.selectAllInCurrentLayer = function()

Clears the selection, then adds all elements in the current layer to the selection.  This function then fires the selected event.

+

getSvgString

this.getSvgString = function()

Returns the current drawing as raw SVG XML text.

Returns

The current drawing as raw SVG XML text.

-

clear

this.clear = function()

Clears the current document.  This is not an undoable action.

+

setSvgString

this.setSvgString = function(xmlString)

This function sets the current drawing as the input SVG XML.

Parameters

xmlStringThe SVG as XML text.

Returns

This function returns false if the set was unsuccessful, true otherwise.

-

Fill and Stroke

+

importSvgString

This function imports the input SVG XML into the current layer in the drawing

Parameters

xmlStringThe SVG as XML text.

Returns

This function returns false if the import was unsuccessful, true otherwise.

-

getVersion

this.getVersion = function()

Returns a string which describes the revision number of SvgCanvas.

+

Layers

+ +

createLayer

this.createLayer = function(name)

Creates a new top-level layer in the drawing with the given name, sets the current layer to it, and then clears the selection This function then calls the ‘changed’ handler.  This is an undoable action.

Parameters

nameThe given name
+ +

deleteCurrentLayer

this.deleteCurrentLayer = function()

Deletes the current layer from the drawing and then clears the selection.  This function then calls the ‘changed’ handler.  This is an undoable action.

+ +

getNumLayers

this.getNumLayers = function()

Returns the number of layers in the current drawing.

Returns

The number of layers in the current drawing.

+ +

getLayer

this.getLayer = function(i)

Returns the name of the ith layer.  If the index is out of range, an empty string is returned.

Parameters

ithe zero-based index of the layer you are querying.

Returns

The name of the ith layer

+ +

getCurrentLayer

this.getCurrentLayer = function()

Returns the name of the currently selected layer.  If an error occurs, an empty string is returned.

Returns

The name of the currently active layer.

+ +

setCurrentLayer

this.setCurrentLayer = function(name)

Sets the current layer.  If the name is not a valid layer name, then this function returns false.  Otherwise it returns true.  This is not an undo-able action.

Parameters

namethe name of the layer you want to switch to.

Returns

true if the current layer was switched, otherwise false

+ +

renameCurrentLayer

this.renameCurrentLayer = function(newname)

Renames the current layer.  If the layer name is not valid (i.e. unique), then this function does nothing and returns false, otherwise it returns true.  This is an undo-able action.

Parameters

newnamethe new name you want to give the current layer.  This name must be unique among all layer names.

Returns

true if the rename succeeded, false otherwise.

+ +

setCurrentLayerPosition

this.setCurrentLayerPosition = function(newpos)

Changes the position of the current layer to the new value.  If the new index is not valid, this function does nothing and returns false, otherwise it returns true.  This is an undo-able action.

Parameters

newposThe zero-based index of the new position of the layer.  This should be between
0 and (number of layers1)

Returns

true if the current layer position was changed, false otherwise.

+ +

getLayerVisibility

this.getLayerVisibility = function(layername)

Returns whether the layer is visible.  If the layer name is not valid, then this function returns false.

Parameters

layernamethe name of the layer which you want to query.

Returns

The visibility state of the layer, or false if the layer name was invalid.

+ +

setLayerVisibility

this.setLayerVisibility = function(layername,
bVisible)

Sets the visibility of the layer.  If the layer name is not valid, this function return false, otherwise it returns true.  This is an undo-able action.

Parameters

layernamethe name of the layer to change the visibility
bVisibletrue/false, whether the layer should be visible

Returns

true if the layer’s visibility was set, false otherwise

+ +

moveSelectedToLayer

this.moveSelectedToLayer = function(layername)

Moves the selected elements to layername.  If the name is not a valid layer name, then false is returned.  Otherwise it returns true.  This is an undo-able action.

Parameters

layernamethe name of the layer you want to which you want to move the selected elements

Returns

true if the selected elements were moved to the layer, false otherwise.

+ +

getLayerOpacity

this.getLayerOpacity = function(layername)

Returns the opacity of the given layer.  If the input name is not a layer, null is returned.

Parameters

layernamename of the layer on which to get the opacity

Returns

The opacity value of the given layer.  This will be a value between 0.0 and 1.0, or null if layername is not a valid layer

+ +

setLayerOpacity

this.setLayerOpacity = function(layername,
opacity)

Sets the opacity of the given layer.  If the input name is not a layer, nothing happens.  This is not an undo-able action.  NOTE: this function exists solely to apply a highlighting/de-emphasis effect to a layer, when it is possible for a user to affect the opacity of a layer, we will need to allow this function to produce an undo-able action.  If opacity is not a value between 0.0 and 1.0, then nothing happens.

Parameters

layernamename of the layer on which to set the opacity
opacitya float value in the range 0.0-1.0
+ +

selectAllInCurrentLayer

this.selectAllInCurrentLayer = function()

Clears the selection, then adds all elements in the current layer to the selection.  This function then fires the selected event.

+ +

clear

this.clear = function()

Clears the current document.  This is not an undoable action.

+ +

Fill and Stroke

+ +

getVersion

this.getVersion = function()

Returns a string which describes the revision number of SvgCanvas.

@@ -118,7 +152,7 @@ var searchPanel = new SearchPanel("searchPanel", "HTML", "../search"); -
toXml = function(str)
Converts characters in a string to XML-friendly entities.
fromXml = function(str)
Converts XML entities in a string to single characters.
function ChangeElementCommand(elem,
attrs,
text)
History command to make a change to an element.
function InsertElementCommand(elem,
text)
History command for an element that was added to the DOM
function RemoveElementCommand(elem,
parent,
text)
History command for an element removed from the DOM
function MoveElementCommand(elem,
oldNextSibling,
oldParent,
text)
History command for an element that had its DOM position changed
this.clearSelection = function(noCall)
Clears the selection.
this.addToSelection = function(elemsToAdd,
showGrips)
Adds a list of elements to the selection.
this.removeFromSelection = function(elemsToRemove)
Removes elements from the selection.
this.save = function(opts)
Serializes the current drawing into SVG XML text and returns it to the ‘saved’ handler.
this.getSvgString = function()
Returns the current drawing as raw SVG XML text.
this.setSvgString = function(xmlString)
This function sets the current drawing as the input SVG XML.
this.createLayer = function(name)
Creates a new top-level layer in the drawing with the given name, sets the current layer to it, and then clears the selection This function then calls the ‘changed’ handler.
this.deleteCurrentLayer = function()
Deletes the current layer from the drawing and then clears the selection.
this.getNumLayers = function()
Returns the number of layers in the current drawing.
this.getLayer = function(i)
Returns the name of the ith layer.
this.getCurrentLayer = function()
Returns the name of the currently selected layer.
this.setCurrentLayer = function(name)
Sets the current layer.
this.renameCurrentLayer = function(newname)
Renames the current layer.
this.setCurrentLayerPosition = function(newpos)
Changes the position of the current layer to the new value.
this.getLayerVisibility = function(layername)
Returns whether the layer is visible.
this.setLayerVisibility = function(layername,
bVisible)
Sets the visibility of the layer.
this.moveSelectedToLayer = function(layername)
Moves the selected elements to layername.
this.getLayerOpacity = function(layername)
Returns the opacity of the given layer.
this.setLayerOpacity = function(layername,
opacity)
Sets the opacity of the given layer.
this.selectAllInCurrentLayer = function()
Clears the selection, then adds all elements in the current layer to the selection.
this.clear = function()
Clears the current document.
this.getVersion = function()
Returns a string which describes the revision number of SvgCanvas.
+
toXml = function(str)
Converts characters in a string to XML-friendly entities.
fromXml = function(str)
Converts XML entities in a string to single characters.
var ChangeElementCommand = this.undoCmd.changeElement = function(elem,
attrs,
text)
History command to make a change to an element.
var InsertElementCommand = this.undoCmd.insertElement = function(elem,
text)
History command for an element that was added to the DOM
var RemoveElementCommand = this.undoCmd.removeElement = function(elem,
parent,
text)
History command for an element removed from the DOM
var MoveElementCommand = this.undoCmd.moveElement = function(elem,
oldNextSibling,
oldParent,
text)
History command for an element that had its DOM position changed
var BatchCommand = this.undoCmd.batch = function(text)
History command that can contain/execute multiple other commands
this.clearSelection = function(noCall)
Clears the selection.
this.addToSelection = function(elemsToAdd,
showGrips)
Adds a list of elements to the selection.
this.removeFromSelection = function(elemsToRemove)
Removes elements from the selection.
this.save = function(opts)
Serializes the current drawing into SVG XML text and returns it to the ‘saved’ handler.
this.getSvgString = function()
Returns the current drawing as raw SVG XML text.
this.setSvgString = function(xmlString)
This function sets the current drawing as the input SVG XML.
this.createLayer = function(name)
Creates a new top-level layer in the drawing with the given name, sets the current layer to it, and then clears the selection This function then calls the ‘changed’ handler.
this.deleteCurrentLayer = function()
Deletes the current layer from the drawing and then clears the selection.
this.getNumLayers = function()
Returns the number of layers in the current drawing.
this.getLayer = function(i)
Returns the name of the ith layer.
this.getCurrentLayer = function()
Returns the name of the currently selected layer.
this.setCurrentLayer = function(name)
Sets the current layer.
this.renameCurrentLayer = function(newname)
Renames the current layer.
this.setCurrentLayerPosition = function(newpos)
Changes the position of the current layer to the new value.
this.getLayerVisibility = function(layername)
Returns whether the layer is visible.
this.setLayerVisibility = function(layername,
bVisible)
Sets the visibility of the layer.
this.moveSelectedToLayer = function(layername)
Moves the selected elements to layername.
this.getLayerOpacity = function(layername)
Returns the opacity of the given layer.
this.setLayerOpacity = function(layername,
opacity)
Sets the opacity of the given layer.
this.selectAllInCurrentLayer = function()
Clears the selection, then adds all elements in the current layer to the selection.
this.clear = function()
Clears the current document.
this.getVersion = function()
Returns a string which describes the revision number of SvgCanvas.
diff --git a/docs/index/Functions.html b/docs/index/Functions.html index c46e7c7f..b4d91d93 100644 --- a/docs/index/Functions.html +++ b/docs/index/Functions.html @@ -11,53 +11,57 @@ if (browserType) {document.write("
");if (browserV -
Function Index
$#! · 0-9 · A · B · C · D · E · F · G · H · I · J · K · L · M · N · O · P · Q · R · S · T · U · V · W · X · Y · Z
A
 addToSelection, SvgCanvas
 apply
C
 ChangeElementCommand, SvgCanvas
 clear, SvgCanvas
 clearSelection, SvgCanvas
 createLayer, SvgCanvas
D
 deleteCurrentLayer, SvgCanvas
E
 elements
F
 fromXml, SvgCanvas
G
 getCurrentLayer, SvgCanvas
 getLayer, SvgCanvas
 getLayerOpacity, SvgCanvas
 getLayerVisibility, SvgCanvas
 getNumLayers, SvgCanvas
 getSvgString, SvgCanvas
 getVersion, SvgCanvas
I
 importSvgString, SvgCanvas
 InsertElementCommand, SvgCanvas
M
 MoveElementCommand, SvgCanvas
 moveSelectedToLayer, SvgCanvas
R
 RemoveElementCommand, SvgCanvas
 removeFromSelection, SvgCanvas
 renameCurrentLayer, SvgCanvas
S
 save, SvgCanvas
 selectAllInCurrentLayer, SvgCanvas
 setCurrentLayer, SvgCanvas
 setCurrentLayerPosition, SvgCanvas
 setForeignString(xmlString,elt)
 setLayerOpacity, SvgCanvas
 setLayerVisibility, SvgCanvas
 setSvgString, SvgCanvas
T
 toXml, SvgCanvas
U
 unapply
+
Function Index
$#! · 0-9 · A · B · C · D · E · F · G · H · I · J · K · L · M · N · O · P · Q · R · S · T · U · V · W · X · Y · Z
A
 addSubCommand, SvgCanvas.BatchCommand
 addToSelection, SelectorManager
 apply
B
 BatchCommand, SvgCanvas
C
 ChangeElementCommand, SvgCanvas
 clear, SelectorManager
 clearSelection, SelectorManager
 createLayer, SelectorManager
D
 deleteCurrentLayer, SelectorManager
E
 elements
F
 fromXml, SvgCanvas
G
 getCurrentLayer, SelectorManager
 getLayer, SelectorManager
 getLayerOpacity, SelectorManager
 getLayerVisibility, SelectorManager
 getNumLayers, SelectorManager
 getRubberBandBox, SelectorManager.SelectorManager
 getSvgString, SelectorManager
 getVersion, SelectorManager
I
 importSvgString, SelectorManager
 initGroup, SelectorManager.SelectorManager
 InsertElementCommand, SvgCanvas
 isEmpty, SvgCanvas.BatchCommand
M
 MoveElementCommand, SvgCanvas
 moveSelectedToLayer, SelectorManager
R
 releaseSelector, SelectorManager.SelectorManager
 RemoveElementCommand, SvgCanvas
 removeFromSelection, SelectorManager
 renameCurrentLayer, SelectorManager
 requestSelector, SelectorManager.SelectorManager
 reset, Selector.Selector
 resize, Selector.Selector
S
 save, SelectorManager
 selectAllInCurrentLayer, SelectorManager
 setCurrentLayer, SelectorManager
 setCurrentLayerPosition, SelectorManager
 setForeignString(xmlString,elt)
 setLayerOpacity, SelectorManager
 setLayerVisibility, SelectorManager
 setSvgString, SelectorManager
 showGrips, Selector.Selector
T
 toXml, SvgCanvas
U
 unapply
 updateGripCursors, Selector.Selector
-
this.addToSelection = function(elemsToAdd,
showGrips)
Adds a list of elements to the selection.
Performs the stored change action
Re-Inserts the new element
Re-removes the new element
+
Adds a given command to the history stack
this.addToSelection = function(elemsToAdd,
showGrips)
Adds a list of elements to the selection.
Runs “apply” on all subcommands
Performs the stored change action
Re-Inserts the new element
Re-removes the new element
-
function ChangeElementCommand(elem,
attrs,
text)
History command to make a change to an element.
this.clear = function()
Clears the current document.
this.clearSelection = function(noCall)
Clears the selection.
this.createLayer = function(name)
Creates a new top-level layer in the drawing with the given name, sets the current layer to it, and then clears the selection This function then calls the ‘changed’ handler.
+
var BatchCommand = this.undoCmd.batch = function(text)
History command that can contain/execute multiple other commands
-
this.deleteCurrentLayer = function()
Deletes the current layer from the drawing and then clears the selection.
+
var ChangeElementCommand = this.undoCmd.changeElement = function(elem,
attrs,
text)
History command to make a change to an element.
this.clear = function()
Clears the current document.
this.clearSelection = function(noCall)
Clears the selection.
this.createLayer = function(name)
Creates a new top-level layer in the drawing with the given name, sets the current layer to it, and then clears the selection This function then calls the ‘changed’ handler.
-
Returns array with element associated with this command
Returns array with element associated with this command
Returns array with element associated with this command
+
this.deleteCurrentLayer = function()
Deletes the current layer from the drawing and then clears the selection.
-
fromXml = function(str)
Converts XML entities in a string to single characters.
+
Iterate through all our subcommands and returns all the elements we are changing
Returns array with element associated with this command
Returns array with element associated with this command
Returns array with element associated with this command
Returns array with element associated with this command
-
this.getCurrentLayer = function()
Returns the name of the currently selected layer.
this.getLayer = function(i)
Returns the name of the ith layer.
this.getLayerOpacity = function(layername)
Returns the opacity of the given layer.
this.getLayerVisibility = function(layername)
Returns whether the layer is visible.
this.getNumLayers = function()
Returns the number of layers in the current drawing.
this.getSvgString = function()
Returns the current drawing as raw SVG XML text.
this.getVersion = function()
Returns a string which describes the revision number of SvgCanvas.
+
fromXml = function(str)
Converts XML entities in a string to single characters.
-
This function imports the input SVG XML into the current layer in the drawing
function InsertElementCommand(elem,
text)
History command for an element that was added to the DOM
+
this.getCurrentLayer = function()
Returns the name of the currently selected layer.
this.getLayer = function(i)
Returns the name of the ith layer.
this.getLayerOpacity = function(layername)
Returns the opacity of the given layer.
this.getLayerVisibility = function(layername)
Returns whether the layer is visible.
this.getNumLayers = function()
Returns the number of layers in the current drawing.
Returns the rubberBandBox DOM element.
this.getSvgString = function()
Returns the current drawing as raw SVG XML text.
this.getVersion = function()
Returns a string which describes the revision number of SvgCanvas.
-
function MoveElementCommand(elem,
oldNextSibling,
oldParent,
text)
History command for an element that had its DOM position changed
this.moveSelectedToLayer = function(layername)
Moves the selected elements to layername.
+
This function imports the input SVG XML into the current layer in the drawing
Resets the parent selector group element
var InsertElementCommand = this.undoCmd.insertElement = function(elem,
text)
History command for an element that was added to the DOM
Returns a boolean indicating whether or not the batch command is empty
-
function RemoveElementCommand(elem,
parent,
text)
History command for an element removed from the DOM
this.removeFromSelection = function(elemsToRemove)
Removes elements from the selection.
this.renameCurrentLayer = function(newname)
Renames the current layer.
+
var MoveElementCommand = this.undoCmd.moveElement = function(elem,
oldNextSibling,
oldParent,
text)
History command for an element that had its DOM position changed
this.moveSelectedToLayer = function(layername)
Moves the selected elements to layername.
-
this.save = function(opts)
Serializes the current drawing into SVG XML text and returns it to the ‘saved’ handler.
this.selectAllInCurrentLayer = function()
Clears the selection, then adds all elements in the current layer to the selection.
this.setCurrentLayer = function(name)
Sets the current layer.
this.setCurrentLayerPosition = function(newpos)
Changes the position of the current layer to the new value.
function setForeignString(xmlString)
This function sets the content of element elt to the input XML.
this.setLayerOpacity = function(layername,
opacity)
Sets the opacity of the given layer.
this.setLayerVisibility = function(layername,
bVisible)
Sets the visibility of the layer.
this.setSvgString = function(xmlString)
This function sets the current drawing as the input SVG XML.
+
Removes the selector of the given element (hides selection box)
var RemoveElementCommand = this.undoCmd.removeElement = function(elem,
parent,
text)
History command for an element removed from the DOM
this.removeFromSelection = function(elemsToRemove)
Removes elements from the selection.
this.renameCurrentLayer = function(newname)
Renames the current layer.
Returns the selector based on the given element
Used to reset the id and element that the selector is attached to
Updates the selector to match the element’s size
-
toXml = function(str)
Converts characters in a string to XML-friendly entities.
+
this.save = function(opts)
Serializes the current drawing into SVG XML text and returns it to the ‘saved’ handler.
this.selectAllInCurrentLayer = function()
Clears the selection, then adds all elements in the current layer to the selection.
this.setCurrentLayer = function(name)
Sets the current layer.
this.setCurrentLayerPosition = function(newpos)
Changes the position of the current layer to the new value.
function setForeignString(xmlString)
This function sets the content of element elt to the input XML.
this.setLayerOpacity = function(layername,
opacity)
Sets the opacity of the given layer.
this.setLayerVisibility = function(layername,
bVisible)
Sets the visibility of the layer.
this.setSvgString = function(xmlString)
This function sets the current drawing as the input SVG XML.
Show the resize grips of this selector
-
Reverses the stored change action
Removes the element
Re-positions the element
Re-adds the new element
+
toXml = function(str)
Converts characters in a string to XML-friendly entities.
+ + + +
Runs “unapply” on all subcommands
Reverses the stored change action
Removes the element
Re-positions the element
Re-adds the new element
Updates cursors for corner grips on rotation so arrows point the right way
diff --git a/docs/index/General.html b/docs/index/General.html index fd553d0e..3ffb0365 100644 --- a/docs/index/General.html +++ b/docs/index/General.html @@ -11,33 +11,37 @@ if (browserType) {document.write("
");if (browserV -
Index
$#! · 0-9 · A · B · C · D · E · F · G · H · I · J · K · L · M · N · O · P · Q · R · S · T · U · V · W · X · Y · Z
A
 addToSelection, SvgCanvas
 apply
C
 ChangeElementCommand, SvgCanvas
 clear, SvgCanvas
 clearSelection, SvgCanvas
 createLayer, SvgCanvas
D
 deleteCurrentLayer, SvgCanvas
E
 elements
F
 Fill and Stroke, SvgCanvas
 fromXml, SvgCanvas
G
 getCurrentLayer, SvgCanvas
 getLayer, SvgCanvas
 getLayerOpacity, SvgCanvas
 getLayerVisibility, SvgCanvas
 getNumLayers, SvgCanvas
 getSvgString, SvgCanvas
 getVersion, SvgCanvas
I
 importSvgString, SvgCanvas
 InsertElementCommand, SvgCanvas
L
 Layers, SvgCanvas
M
 MoveElementCommand, SvgCanvas
 moveSelectedToLayer, SvgCanvas
R
 RemoveElementCommand, SvgCanvas
 removeFromSelection, SvgCanvas
 renameCurrentLayer, SvgCanvas
S
 save, SvgCanvas
 selectAllInCurrentLayer, SvgCanvas
 Selection, SvgCanvas
 Serialization, SvgCanvas
 setCurrentLayer, SvgCanvas
 setCurrentLayerPosition, SvgCanvas
 setForeignString(xmlString,elt)
 setLayerOpacity, SvgCanvas
 setLayerVisibility, SvgCanvas
 setSvgString, SvgCanvas
 SvgCanvas
T
 toXml, SvgCanvas
U
 unapply
 Undo/Redo history management, SvgCanvas
+
Index
$#! · 0-9 · A · B · C · D · E · F · G · H · I · J · K · L · M · N · O · P · Q · R · S · T · U · V · W · X · Y · Z
A
 addSubCommand, SvgCanvas.BatchCommand
 addToSelection, SelectorManager
 apply
B
 BatchCommand, SvgCanvas
C
 ChangeElementCommand, SvgCanvas
 clear, SelectorManager
 clearSelection, SelectorManager
 createLayer, SelectorManager
D
 deleteCurrentLayer, SelectorManager
E
 elements
F
 Fill and Stroke, SelectorManager
 fromXml, SvgCanvas
 Functions, Selector
G
 getCurrentLayer, SelectorManager
 getLayer, SelectorManager
 getLayerOpacity, SelectorManager
 getLayerVisibility, SelectorManager
 getNumLayers, SelectorManager
 getRubberBandBox, SelectorManager.SelectorManager
 getSvgString, SelectorManager
 getVersion, SelectorManager
I
 importSvgString, SelectorManager
 initGroup, SelectorManager.SelectorManager
 InsertElementCommand, SvgCanvas
 isEmpty, SvgCanvas.BatchCommand
L
 Layers, SelectorManager
M
 MoveElementCommand, SvgCanvas
 moveSelectedToLayer, SelectorManager
R
 releaseSelector, SelectorManager.SelectorManager
 RemoveElementCommand, SvgCanvas
 removeFromSelection, SelectorManager
 renameCurrentLayer, SelectorManager
 requestSelector, SelectorManager.SelectorManager
 reset, Selector.Selector
 resize, Selector.Selector
S
 save, SelectorManager
 selectAllInCurrentLayer, SelectorManager
 Selection, SelectorManager
 Selector
 SelectorManager
 Serialization, SelectorManager
 setCurrentLayer, SelectorManager
 setCurrentLayerPosition, SelectorManager
 setForeignString(xmlString,elt)
 setLayerOpacity, SelectorManager
 setLayerVisibility, SelectorManager
 setSvgString, SelectorManager
 showGrips, Selector.Selector
 SvgCanvas
T
 toXml, SvgCanvas
U
 unapply
 Undo/Redo history management, SvgCanvas
 updateGripCursors, Selector.Selector
-
this.addToSelection = function(elemsToAdd,
showGrips)
Adds a list of elements to the selection.
Performs the stored change action
Re-Inserts the new element
Re-removes the new element
+
Adds a given command to the history stack
this.addToSelection = function(elemsToAdd,
showGrips)
Adds a list of elements to the selection.
Runs “apply” on all subcommands
Performs the stored change action
Re-Inserts the new element
Re-removes the new element
-
function ChangeElementCommand(elem,
attrs,
text)
History command to make a change to an element.
this.clear = function()
Clears the current document.
this.clearSelection = function(noCall)
Clears the selection.
this.createLayer = function(name)
Creates a new top-level layer in the drawing with the given name, sets the current layer to it, and then clears the selection This function then calls the ‘changed’ handler.
+
var BatchCommand = this.undoCmd.batch = function(text)
History command that can contain/execute multiple other commands
-
this.deleteCurrentLayer = function()
Deletes the current layer from the drawing and then clears the selection.
+
var ChangeElementCommand = this.undoCmd.changeElement = function(elem,
attrs,
text)
History command to make a change to an element.
this.clear = function()
Clears the current document.
this.clearSelection = function(noCall)
Clears the selection.
this.createLayer = function(name)
Creates a new top-level layer in the drawing with the given name, sets the current layer to it, and then clears the selection This function then calls the ‘changed’ handler.
-
Returns array with element associated with this command
Returns array with element associated with this command
Returns array with element associated with this command
+
this.deleteCurrentLayer = function()
Deletes the current layer from the drawing and then clears the selection.
-
fromXml = function(str)
Converts XML entities in a string to single characters.
+
Iterate through all our subcommands and returns all the elements we are changing
Returns array with element associated with this command
Returns array with element associated with this command
Returns array with element associated with this command
Returns array with element associated with this command
-
this.getCurrentLayer = function()
Returns the name of the currently selected layer.
this.getLayer = function(i)
Returns the name of the ith layer.
this.getLayerOpacity = function(layername)
Returns the opacity of the given layer.
this.getLayerVisibility = function(layername)
Returns whether the layer is visible.
this.getNumLayers = function()
Returns the number of layers in the current drawing.
this.getSvgString = function()
Returns the current drawing as raw SVG XML text.
this.getVersion = function()
Returns a string which describes the revision number of SvgCanvas.
+
fromXml = function(str)
Converts XML entities in a string to single characters.
-
This function imports the input SVG XML into the current layer in the drawing
function InsertElementCommand(elem,
text)
History command for an element that was added to the DOM
+
this.getCurrentLayer = function()
Returns the name of the currently selected layer.
this.getLayer = function(i)
Returns the name of the ith layer.
this.getLayerOpacity = function(layername)
Returns the opacity of the given layer.
this.getLayerVisibility = function(layername)
Returns whether the layer is visible.
this.getNumLayers = function()
Returns the number of layers in the current drawing.
Returns the rubberBandBox DOM element.
this.getSvgString = function()
Returns the current drawing as raw SVG XML text.
this.getVersion = function()
Returns a string which describes the revision number of SvgCanvas.
+ + + +
This function imports the input SVG XML into the current layer in the drawing
Resets the parent selector group element
var InsertElementCommand = this.undoCmd.insertElement = function(elem,
text)
History command for an element that was added to the DOM
Returns a boolean indicating whether or not the batch command is empty
@@ -45,23 +49,23 @@ if (browserType) {document.write("
");if (browserV -
function MoveElementCommand(elem,
oldNextSibling,
oldParent,
text)
History command for an element that had its DOM position changed
this.moveSelectedToLayer = function(layername)
Moves the selected elements to layername.
+
var MoveElementCommand = this.undoCmd.moveElement = function(elem,
oldNextSibling,
oldParent,
text)
History command for an element that had its DOM position changed
this.moveSelectedToLayer = function(layername)
Moves the selected elements to layername.
-
function RemoveElementCommand(elem,
parent,
text)
History command for an element removed from the DOM
this.removeFromSelection = function(elemsToRemove)
Removes elements from the selection.
this.renameCurrentLayer = function(newname)
Renames the current layer.
+
Removes the selector of the given element (hides selection box)
var RemoveElementCommand = this.undoCmd.removeElement = function(elem,
parent,
text)
History command for an element removed from the DOM
this.removeFromSelection = function(elemsToRemove)
Removes elements from the selection.
this.renameCurrentLayer = function(newname)
Renames the current layer.
Returns the selector based on the given element
Used to reset the id and element that the selector is attached to
Updates the selector to match the element’s size
-
this.save = function(opts)
Serializes the current drawing into SVG XML text and returns it to the ‘saved’ handler.
this.selectAllInCurrentLayer = function()
Clears the selection, then adds all elements in the current layer to the selection.
this.setCurrentLayer = function(name)
Sets the current layer.
this.setCurrentLayerPosition = function(newpos)
Changes the position of the current layer to the new value.
function setForeignString(xmlString)
This function sets the content of element elt to the input XML.
this.setLayerOpacity = function(layername,
opacity)
Sets the opacity of the given layer.
this.setLayerVisibility = function(layername,
bVisible)
Sets the visibility of the layer.
this.setSvgString = function(xmlString)
This function sets the current drawing as the input SVG XML.
The main SvgCanvas class that manages all SVG-related functions
+
this.save = function(opts)
Serializes the current drawing into SVG XML text and returns it to the ‘saved’ handler.
this.selectAllInCurrentLayer = function()
Clears the selection, then adds all elements in the current layer to the selection.
Private class for DOM element selection boxes
public class to manage all selector objects (selection boxes)
this.setCurrentLayer = function(name)
Sets the current layer.
this.setCurrentLayerPosition = function(newpos)
Changes the position of the current layer to the new value.
function setForeignString(xmlString)
This function sets the content of element elt to the input XML.
this.setLayerOpacity = function(layername,
opacity)
Sets the opacity of the given layer.
this.setLayerVisibility = function(layername,
bVisible)
Sets the visibility of the layer.
this.setSvgString = function(xmlString)
This function sets the current drawing as the input SVG XML.
Show the resize grips of this selector
The main SvgCanvas class that manages all SVG-related functions
-
toXml = function(str)
Converts characters in a string to XML-friendly entities.
+
toXml = function(str)
Converts characters in a string to XML-friendly entities.
-
Reverses the stored change action
Removes the element
Re-positions the element
Re-adds the new element
+
Runs “unapply” on all subcommands
Reverses the stored change action
Removes the element
Re-positions the element
Re-adds the new element
Updates cursors for corner grips on rotation so arrows point the right way
diff --git a/docs/javascript/searchdata.js b/docs/javascript/searchdata.js index c9700e49..f0a3c2a6 100644 --- a/docs/javascript/searchdata.js +++ b/docs/javascript/searchdata.js @@ -33,7 +33,7 @@ var indexSectionsWithContent = { "Symbols": false, "Numbers": false, "A": true, - "B": false, + "B": true, "C": true, "D": true, "E": true, diff --git a/docs/search/FunctionsA.html b/docs/search/FunctionsA.html index be1043ae..5753b115 100644 --- a/docs/search/FunctionsA.html +++ b/docs/search/FunctionsA.html @@ -11,7 +11,7 @@ if (browserType) {document.write("
");if (browserV -
Loading...
addToSelection, SvgCanvas
Searching...
No Matches