Represents the pentagon shape.

Hierarchy

Hierarchy (view full)

Constructors

Properties

$type: Type
$t: Type
nextHashCode: number

Accessors

  • get bottomRightCornerCell(): WorksheetCell
  • Gets or sets the cell where the bottom-right corner of the shape resides.

    This anchor cell, along with the [[topLeftCornerCell]], determines where the shape will be positioned on the worksheet. In addition, the [[bottomRightCornerPosition]] and [[topLeftCornerPosition]] properties allow for finer control of the shape's position.

    The cell where the bottom-right corner of the shape resides.

    Throws

    [[ArgumentException]] The value assigned is a cell whose worksheet is not the same as this shape's worksheet.

    Throws

    [[ArgumentNullException]] The value assigned is null and this shape already exists on a worksheet or group.

    See

    • [[bottomRightCornerPosition]]
    • [[topLeftCornerCell]]
    • [[topLeftCornerPosition]]

    Returns WorksheetCell

  • set bottomRightCornerCell(a): void
  • Parameters

    Returns void

  • get bottomRightCornerPosition(): IgPoint
  • Gets or sets the position in the [[bottomRightCornerCell]] of the shape's bottom-right corner, expressed in percentages.

    These percentages are expressed as distance across the associated dimension of the cell, starting at the top-left corner of the cell. For example, (0.0, 0.0) represents the top-left corner of the cell, whereas (100.0, 100.0) represents the bottom-right corner of the cell. (50.0, 10.0) would represent the location in the cell which is centered horizontally, and a tenth of the way down from the top.

    The position in the bottom-right corner cell of the shape's bottom-right corner.

    Throws

    [[ArgumentOutOfRangeException]] Either coordinate of the value assigned is outside the range of 0.0 to 100.0.

    See

    • [[bottomRightCornerCell]]
    • [[topLeftCornerCell]]
    • [[topLeftCornerPosition]]

    Returns IgPoint

  • set bottomRightCornerPosition(a): void
  • Parameters

    • a: IgPoint

    Returns void

  • get fill(): ShapeFill
  • Gets or sets the fill to use in the background of the shape.

    Note: some shapes, such as connectors or groups, cannot have a fill set. For these shapes, the value on this property will be ignored and lost when the workbook is saved.

    A [[ShapeFill]]-derived instance describing the fill of the shape, or null for no fill.

    See

    • [[ShapeFill.fromColor]]
    • [[ShapeFillSolid]]
    • [[outline]]

    Returns ShapeFill

  • set fill(a): void
  • Parameters

    Returns void

  • get flippedHorizontally(): boolean
  • Gets or sets the value which indicates whether the shape is flipped horizontally along the vertical center line.

    Throws

    [[InvalidOperationException]] The value is set to True and this shape doesn't allow flipping or rotating, such as a [[WorksheetChart]].

    Returns boolean

  • set flippedHorizontally(a): void
  • Parameters

    • a: boolean

    Returns void

  • get flippedVertically(): boolean
  • Gets or sets the value which indicates whether the shape is flipped vertically along the horizontal center line.

    Throws

    [[InvalidOperationException]] The value is set to True and this shape doesn't allow flipping or rotating, such as a [[WorksheetChart]].

    Returns boolean

  • set flippedVertically(a): void
  • Parameters

    • a: boolean

    Returns void

  • get outline(): ShapeOutline
  • Gets or sets the outline to use for the shape.

    Note: some shapes, such as comments or groups, cannot have a outline set. For these shapes, the value on this property will be ignored and lost when the workbook is saved.

    A [[ShapeOutline]]-derived instance describing the outline of the shape, or null for no outline.

    See

    • [[ShapeOutline.fromColorInfo]]
    • [[ShapeOutlineSolid]]
    • [[fill]]

    Returns ShapeOutline

  • set outline(a): void
  • Parameters

    Returns void

  • get positioningMode(): ShapePositioningMode
  • Gets or sets the way shapes will be repositioned in excel when cells before or within the shape are resized.

    This value will not be saved for shapes contained in a [[WorksheetShapeGroup]], which inherit their positioning mode from their parent group.

    The way shapes will be repositioned in excel when cells before or within the shape are resized.

    Throws

    [[InvalidEnumArgumentException]] The value assigned is not defined in the [[ShapePositioningMode]] enumeration.

    Returns ShapePositioningMode

  • set positioningMode(a): void
  • Parameters

    Returns void

  • get sheet(): Sheet
  • Gets the worksheet on which the shape resides. The worksheet on which the shape resides.

    Returns Sheet

  • get text(): FormattedText
  • Gets or sets the formatted text of the shape. The formatted text of the shape.

    Returns FormattedText

  • set text(a): void
  • Parameters

    Returns void

  • get topLeftCornerCell(): WorksheetCell
  • Gets or sets the cell where the top-left corner of the shape resides.

    This anchor cell, along with the [[bottomRightCornerCell]], determines where the shape will be positioned on the worksheet. In addition, the [[bottomRightCornerPosition]] and [[topLeftCornerPosition]] properties allow for finer control of the shape's position.

    The cell where the top-left corner of the shape resides.

    Throws

    [[ArgumentException]] The value assigned is a cell whose worksheet is not the same as this shape's worksheet.

    Throws

    [[ArgumentNullException]] The value assigned is null and this shape already exists on a worksheet or group.

    See

    • [[bottomRightCornerCell]]
    • [[bottomRightCornerPosition]]
    • [[topLeftCornerPosition]]

    Returns WorksheetCell

  • set topLeftCornerCell(a): void
  • Parameters

    Returns void

  • get topLeftCornerPosition(): IgPoint
  • Gets or sets the position in the [[topLeftCornerCell]] of the shape's top-left corner, expressed in percentages.

    These percentages are expressed as distance across the associated dimension of the cell, starting at the top-left corner of the cell. For example, (0.0, 0.0) represents the top-left corner of the cell, whereas (100.0, 100.0) represents the bottom-right corner of the cell. (50.0, 10.0) would represent the location in the cell which is centered horizontally, and a tenth of the way down from the top.

    The position in the top-left corner cell of the shape's top-left corner.

    Throws

    [[ArgumentOutOfRangeException]] Either coordinate of the value assigned is outside the range of 0.0 to 100.0.

    See

    • [[bottomRightCornerCell]]
    • [[bottomRightCornerPosition]]
    • [[topLeftCornerCell]]

    Returns IgPoint

  • set topLeftCornerPosition(a): void
  • Parameters

    • a: IgPoint

    Returns void

  • get visible(): boolean
  • Gets or sets the value indicating whether the shape is visible on the worksheet. The value indicating whether the shape is visible on the worksheet.

    Returns boolean

  • set visible(a): void
  • Parameters

    • a: boolean

    Returns void

  • get worksheet(): Worksheet
  • Gets the worksheet on which the shape resides. The worksheet on which the shape resides.

    Returns Worksheet

Methods

  • Clears the cached unknown shape data which was read in from a parsed excel file.

    This method will only be needed until all shape information is supported and customizable. After all shape data can be controlled, this method will become obsolete. Currently, all unsupported data will be stored with the shape for round-tripping purposes. For example, if an Excel file with complex and unsupported shapes is loaded into a [[Workbook]] instance, some cell values are changed, and it is saved to the same file, the complex shapes will still exist in the workbook. However, if a loaded shape needs to be modified before it is saved back, this method allows for that unsupported data to be removed while all supported data is maintained.

    Note: This method only clears unsupported data. In future versions of the product, as more shape data is supported, this method will have different effects on the shape, until eventually all data is supported and this method will have no effect on the shape.

    Throws

    [[InvalidOperationException]] This method is called on an [[UnknownShape]] instance.

    Returns void

  • Parameters

    • other: any

    Returns boolean

  • Gets the bounds of the shape in twips (1/20th of a point).

    The bounds returned by this method are only valid with the current configuration of the worksheet. If any rows or columns before or within the shape are resized, these bounds will no longer reflect the position of the shape.

    Throws

    [[InvalidOperationException]] The [[topLeftCornerCell]] or [[bottomRightCornerCell]] are null, in which case the shape has no bounds.

    See

    [[setBoundsInTwips]]

    Returns IgRect

  • Gets the bounds of the shape in twips (1/20th of a point).

    The bounds returned by this method are only valid with the current configuration of the worksheet. If any rows or columns before or within the shape are resized, these bounds will no longer reflect the position of the shape.

    Throws

    [[InvalidOperationException]] The [[topLeftCornerCell]] or [[bottomRightCornerCell]] are null, in which case the shape has no bounds.

    See

    [[setBoundsInTwips]]

    Parameters

    Returns IgRect

  • Sets the bounds of the shape in twips (1/20th of a point).

    The shape will only be positioned at the specified bounds while the worksheet remains in the current configuration. Depending on the [[positioningMode]] of the shape, it may change bounds if any rows or columns before or within the shape are resized.

    Throws

    [[ArgumentNullException]] 'sheet' is null.

    Parameters

    • sheet: Sheet

      The worksheet on which the shape should be placed.

    • bounds: IgRect

      The new bounds where the shape should be placed.

    Returns void

  • Sets the bounds of the shape in twips (1/20th of a point).

    The shape will only be positioned at the specified bounds while the worksheet remains in the current configuration. Depending on the [[positioningMode]] of the shape, it may change bounds if any rows or columns before or within the shape are resized.

    Throws

    [[ArgumentNullException]] s

    'sheet' is null.

    Parameters

    • sheet: Sheet

      The sheet on which the shape should be placed.

    • bounds: IgRect

      The new bounds where the shape should be placed.

    • options: PositioningOptions

      The options to use when setting the bounds of the shape.

    Returns void

  • Parameters

    • item1: any
    • item2: any

    Returns number

  • Parameters

    • item1: any
    • item2: any

    Returns number

  • Creates a shape which is predefined in Microsoft Excel.

    Throws

    [[InvalidEnumArgumentException]] 'shapeType' is not defined in the [[PredefinedShapeType]] enumeration.

    Parameters

    Returns WorksheetShape

  • Parameters

    • item1: any
    • item2: any

    Returns boolean

  • Parameters

    • a: any
    • b: any

    Returns boolean

  • Parameters

    • a: any
    • b: any

    Returns boolean

  • Returns void