aspose.diagram

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
functiongetValue()
FormatTxt collection which contains the text of a shape.
 
Method Summary
functiondeepClone()
Creates deep copy of this instance.
 

    • Constructor Detail

      • Text

        function Text()
        Constructor.
    • Property Getters/Setters Detail

      • getValue : FormatTxtCollection 

        function getValue()
        
        FormatTxt collection which contains the text of a shape.
    • Method Detail

      • deepClone

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