Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Class

OfficeShapePresets

OfficeIMO.Drawing

Namespace
OfficeIMO.Drawing
Assembly
OfficeIMO.Core
Source revision
ba882f6b0d07 with working tree changes
Modifiers
static

Creates reusable OfficeShape descriptors for common DrawingML preset geometries.

Inheritance

  • object
  • OfficeShapePresets

Methods

TryCreate 2 overloads
public static bool TryCreate(string? presetName, double width, double height, bool horizontalFlip, bool verticalFlip, out OfficeShape? shape) #

Attempts to create a shared OfficeIMO shape for a DrawingML-style preset name.

Parameters

presetName string? required
Preset name such as rect, triangle, or rightArrow.
width double required
Requested shape width in the caller's layout unit.
height double required
Requested shape height in the caller's layout unit.
horizontalFlip bool required
Whether the shape geometry should be mirrored horizontally.
verticalFlip bool required
Whether the shape geometry should be mirrored vertically.
shape OfficeIMO.Drawing.OfficeShape? required
Created shape when the preset is supported.

Returns

bool true when the preset could be mapped; otherwise false.
public static bool TryCreate(string? presetName, double width, double height, out OfficeShape? shape) #

Attempts to create a shared OfficeIMO shape for a DrawingML-style preset name.

Parameters

presetName string? required
width double required
height double required
shape OfficeIMO.Drawing.OfficeShape? required

Returns

bool