Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Class

OfficeDrawingPortableExporter

OfficeIMO.Drawing

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

Projects canonical drawing elements to version 1 portable report drawing JSON.

Inheritance

  • object
  • OfficeDrawingPortableExporter

Remarks

This is a bounded projection, not a general drawing serializer. Unsupported paint, layout, fonts or resources reject the entire export; no partial drawing is returned.

Methods

public static bool TryExportJson(OfficeDrawing drawing, OfficeDrawingPortableOptions options, out string? json, out IReadOnlyList<OfficeDiagnostic> diagnostics) #

Exports an ordered drawing, returning no JSON when any source element cannot be preserved.

Parameters

drawing OfficeIMO.Drawing.OfficeDrawing required
Canonical drawing in points with a local top-left origin.
options OfficeIMO.Drawing.OfficeDrawingPortableOptions required
Explicit font family and resource budgets.
json string? required
Complete version 1 JSON, or null on unsupported content or exceeded budgets.
diagnostics System.Collections.Generic.IReadOnlyList<OfficeIMO.OfficeDiagnostic> required
A stable failure code and source location, or an empty collection on success.

Returns

bool