UImage

IFOverGridImage, from Univer
(see Univer Docs)

public struct UImage

Remarks

Represents an image object placed over the grid in a spreadsheet, including its source, positioning, and transformation details.

Properties

Property Type Description
unitId string Workbook Id
subUnitId string Worksheet Id
drawingId string Image id on Univer
drawingType EDrawingType Image type
imageSourceType string Type of source for the image
source string Data Uri for the image (originally a string)
sheetTransform USheetTransform Position in Sheet
transform UTransform Transform state
srcRect USourceRectangle? Source Rectangle (from cropping the image)

Constructors

public UImage()

Default constructor.


Methods

public string GetBase64()

Returns the base64 data from the Data URI source.

Returns

string — The base64 part of the Data URI, or the original source string if null or empty.


public string GetImageType()

Returns the image MIME type from the Data URI source.

Returns

string — The MIME type (e.g., image/png) extracted from the Data URI, or the original source if null or empty.