asposediagram.api

Contains the text of a shape.

Example:

var aspose = aspose || {};
aspose.diagram = require("aspose.diagram");

diagram = new aspose.diagram.Diagram("ReadDiagramFile.vsd");

// get page by name
page = diagram.getPages().getPage("Flow 1");
// Find a particular shape and update its text
for (it = page.getShapes().iterator(); it.hasNext();) {
    shape = it.next();
    if (shape.getNameU().toLowerCase() == "process") {
        shape.getText().getValue().clear();
        shape.getText().getValue().add(new aspose.diagram.Txt("New Text"));
        break;
    }
}

diagram.save("out-UpdateShapeText.vsdx", aspose.diagram.SaveFileFormat.VSDX);

Constructor Summary
Text()
Constructor.
 
Property Getters/Setters Summary
methodgetValue()
FormatTxt collection which contains the text of a shape.
 
Method Summary
methoddeepClone()
Creates deep copy of this instance.
 

    • Constructor Detail

      • Text

        Text()
        Constructor.
    • Method Detail

      • deepClone

        Object deepClone()
        Creates deep copy of this instance.
        Returns: