asposediagram.api

Class HeaderFooter

Contains elements for a document's header and footer.

Example:

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

diagram = new aspose.diagram.Diagram("ManageHeadersandFooters.vsdx");

// add page number at the right corner of header
diagram.getHeaderFooter().setHeaderRight("&p");

// set text at the center
diagram.getHeaderFooter().setHeaderCenter("Center of the header");

// set text at the left side
diagram.getHeaderFooter().setHeaderLeft("Left of the header");

// add text at the right corner of footer
diagram.getHeaderFooter().setFooterRight("Right of the footer");

// set text at the center
diagram.getHeaderFooter().setFooterCenter("Center of the footer");

// set text at the left side
diagram.getHeaderFooter().setFooterLeft("Left of the footer");

// set header & footer color
diagram.getHeaderFooter().setHeaderFooterColor(aspose.diagram.Color.getRed());

// set text font properties
diagram.getHeaderFooter().getHeaderFooterFont().setItalic(aspose.diagram.BOOL.TRUE);
diagram.getHeaderFooter().getHeaderFooterFont().setUnderline(aspose.diagram.BOOL.FALSE);

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

Property Getters/Setters Summary
methodgetFooterCenter()
method
           Contains the text string that appears in the center portion of a document's footer.
methodgetFooterLeft()
method
           Contains the text string that appears in the left portion of a document's footer.
methodgetFooterMargin()
method
           Specifies the margin of a document's footer.
methodgetFooterRight()
method
           Contains the text string that appears in the right portion of a document's footer.
methodgetHeaderCenter()
method
           Contains the text string that appears in the center portion of a document's header.
methodgetHeaderFooterColor()
method
           The RGB value of the text color for the header and footer.
methodgetHeaderFooterFont()
Specifies the font used for the header and footer text.
methodgetHeaderLeft()
method
           Contains the text string that appears in the left portion of a document's header.
methodgetHeaderMargin()
method
           Specifies the margin of a document's footer.
methodgetHeaderRight()
method
           Contains the text string that appears in the right portion of a document's header.
 

    • Property Getters/Setters Detail

      • getHeaderMargin/setHeaderMargin : Margin 

        Margin getHeaderMargin() / setHeaderMargin(value)
        
        Specifies the margin of a document's footer.
      • getFooterMargin/setFooterMargin : Margin 

        Margin getFooterMargin() / setFooterMargin(value)
        
        Specifies the margin of a document's footer.
      • getHeaderFooterColor/setHeaderFooterColor : Color 

        Color getHeaderFooterColor() / setHeaderFooterColor(value)
        
        The RGB value of the text color for the header and footer.
      • getHeaderLeft/setHeaderLeft : String 

        String getHeaderLeft() / setHeaderLeft(value)
        
        Contains the text string that appears in the left portion of a document's header.
      • getHeaderCenter/setHeaderCenter : String 

        String getHeaderCenter() / setHeaderCenter(value)
        
        Contains the text string that appears in the center portion of a document's header.
      • getHeaderRight/setHeaderRight : String 

        String getHeaderRight() / setHeaderRight(value)
        
        Contains the text string that appears in the right portion of a document's header.
      • getFooterLeft/setFooterLeft : String 

        String getFooterLeft() / setFooterLeft(value)
        
        Contains the text string that appears in the left portion of a document's footer.
      • getFooterCenter/setFooterCenter : String 

        String getFooterCenter() / setFooterCenter(value)
        
        Contains the text string that appears in the center portion of a document's footer.
      • getFooterRight/setFooterRight : String 

        String getFooterRight() / setFooterRight(value)
        
        Contains the text string that appears in the right portion of a document's footer.