# OfficeSvgDrawingReader

Reads a bounded subset of SVG into the shared dependency-free drawing scene.

Class 

`OfficeIMO.Drawing`

**Namespace**

`OfficeIMO.Drawing`

**Assembly**

`OfficeIMO.Core`

**Source revision**

`ba882f6b0d07` with working tree changes

**Source**

[OfficeSvgDrawingReader.cs:19](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeSvgDrawingReader.cs#L19)

**Modifiers**

static

Reads a bounded subset of SVG into the shared dependency-free drawing scene.

## Inheritance

- object
- OfficeSvgDrawingReader

Filter members 

Show inherited

## Methods

InspectContentSafety 2 overloads

`public static OfficeContentSafetyReport InspectContentSafety(byte[] svgBytes, OfficeContentSafetyOptions? options = null, OfficeSvgDrawingReaderOptions? readerOptions = null)` [#](#method-inspectcontentsafety-byte-officeimo-contentsafety-officecontentsafetyoptions-officeimo-drawing-officesvgdrawingreaderoptions)

[OfficeSvgDrawingReader.ContentSafety.cs:16](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeSvgDrawingReader.ContentSafety.cs#L16)

Inspects bounded SVG text for native, computed, geometric, clipping, compositing, and contrast concealment.

Parameters

**svgBytes byte[] required**

**options OfficeIMO.ContentSafety.OfficeContentSafetyOptions? = null optional**

**readerOptions OfficeIMO.Drawing.OfficeSvgDrawingReaderOptions? = null optional**

Returns

`OfficeContentSafetyReport`

`public static OfficeContentSafetyReport InspectContentSafety(string filePath, OfficeContentSafetyOptions? options = null, OfficeSvgDrawingReaderOptions? readerOptions = null)` [#](#method-inspectcontentsafety-string-officeimo-contentsafety-officecontentsafetyoptions-officeimo-drawing-officesvgdrawingreaderoptions)

[OfficeSvgDrawingReader.ContentSafety.cs:27](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeSvgDrawingReader.ContentSafety.cs#L27)

Inspects a bounded SVG file without treating concealment as evidence of AI authorship.

Parameters

**filePath string required**

**options OfficeIMO.ContentSafety.OfficeContentSafetyOptions? = null optional**

**readerOptions OfficeIMO.Drawing.OfficeSvgDrawingReaderOptions? = null optional**

Returns

`OfficeContentSafetyReport`

`public static bool IsWithinSafetyLimits(byte[]? bytes, OfficeSvgDrawingReaderOptions? options = null)` [#](#method-iswithinsafetylimits-byte-officeimo-drawing-officesvgdrawingreaderoptions)

[OfficeSvgDrawingReader.cs:189](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeSvgDrawingReader.cs#L189)

Returns whether an SVG payload is well formed and stays within the supplied parser and viewport safety limits, regardless of whether every valid SVG shape can be imported into an [OfficeDrawing](/api/core/officeimo-drawing-officedrawing/).

Parameters

**bytes byte[]? required**

**options OfficeIMO.Drawing.OfficeSvgDrawingReaderOptions? = null optional**

Returns

`bool`

RemoveSelectedContent 2 overloads

`public static OfficeContentCleanupResult RemoveSelectedContent(byte[] svgBytes, OfficeContentCleanupSelection selection, OfficeContentCleanupOptions? options = null, OfficeSvgDrawingReaderOptions? readerOptions = null)` [#](#method-removeselectedcontent-byte-officeimo-contentsafety-officecontentcleanupselection-officeimo-contentsafety-officecontentcleanupoptions-officeimo-drawing-officesvgdrawingreaderoptions)

[OfficeSvgDrawingReader.ContentSafety.cs:38](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeSvgDrawingReader.ContentSafety.cs#L38)

Removes only exact current SVG findings selected by the caller and then reopens and reinspects the result.

Parameters

**svgBytes byte[] required**

**selection OfficeIMO.ContentSafety.OfficeContentCleanupSelection required**

**options OfficeIMO.ContentSafety.OfficeContentCleanupOptions? = null optional**

**readerOptions OfficeIMO.Drawing.OfficeSvgDrawingReaderOptions? = null optional**

Returns

`OfficeContentCleanupResult`

`public static OfficeContentCleanupResult RemoveSelectedContent(string inputPath, string outputPath, OfficeContentCleanupSelection selection, OfficeContentCleanupOptions? options = null, OfficeSvgDrawingReaderOptions? readerOptions = null)` [#](#method-removeselectedcontent-string-string-officeimo-contentsafety-officecontentcleanupselection-officeimo-contentsafety-officecontentcleanupoptions-officeimo-drawing-officesvgdrawingreaderoptions)

[OfficeSvgDrawingReader.ContentSafety.cs:96](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeSvgDrawingReader.ContentSafety.cs#L96)

Atomically writes an explicitly cleaned SVG artifact.

Parameters

**inputPath string required**

**outputPath string required**

**selection OfficeIMO.ContentSafety.OfficeContentCleanupSelection required**

**options OfficeIMO.ContentSafety.OfficeContentCleanupOptions? = null optional**

**readerOptions OfficeIMO.Drawing.OfficeSvgDrawingReaderOptions? = null optional**

Returns

`OfficeContentCleanupResult`

TryRead 4 overloads

`public static bool TryRead(byte[]? bytes, out OfficeDrawing? drawing)` [#](#method-tryread-byte-officeimo-drawing-officedrawing)

[OfficeSvgDrawingReader.cs:19](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeSvgDrawingReader.cs#L19)

Attempts to interpret supported SVG vector primitives as a shared drawing.

Parameters

**bytes byte[]? required**

**drawing OfficeIMO.Drawing.OfficeDrawing? required**

Returns

`bool`

`public static bool TryRead(byte[]? bytes, out OfficeDrawing? drawing, out int unsupportedFeatureCount)` [#](#method-tryread-byte-officeimo-drawing-officedrawing-int32)

[OfficeSvgDrawingReader.cs:26](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeSvgDrawingReader.cs#L26)

Attempts to interpret supported SVG vector primitives as a shared drawing and reports the number of elements or declarations that required omission or fallback.

Parameters

**bytes byte[]? required**

**drawing OfficeIMO.Drawing.OfficeDrawing? required**

**unsupportedFeatureCount int required**

Returns

`bool`

`public static bool TryRead(byte[]? bytes, OfficeSvgDrawingReaderOptions? options, out OfficeDrawing? drawing)` [#](#method-tryread-byte-officeimo-drawing-officesvgdrawingreaderoptions-officeimo-drawing-officedrawing)

[OfficeSvgDrawingReader.cs:30](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeSvgDrawingReader.cs#L30)

Attempts to interpret supported SVG vector primitives using explicit bounded import options.

Parameters

**bytes byte[]? required**

**options OfficeIMO.Drawing.OfficeSvgDrawingReaderOptions? required**

**drawing OfficeIMO.Drawing.OfficeDrawing? required**

Returns

`bool`

`public static bool TryRead(byte[]? bytes, OfficeSvgDrawingReaderOptions? options, out OfficeDrawing? drawing, out int unsupportedFeatureCount)` [#](#method-tryread-byte-officeimo-drawing-officesvgdrawingreaderoptions-officeimo-drawing-officedrawing-int32)

[OfficeSvgDrawingReader.cs:41](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeSvgDrawingReader.cs#L41)

Attempts to interpret supported SVG vector primitives using explicit bounded import options and reports the number of elements or declarations that required omission or fallback.

Parameters

**bytes byte[]? required**

**options OfficeIMO.Drawing.OfficeSvgDrawingReaderOptions? required**

**drawing OfficeIMO.Drawing.OfficeDrawing? required**

**unsupportedFeatureCount int required**

Returns

`bool`

## Inherited Methods

`public virtual bool Equals(object? obj)` [#](#method-equals-object)

Inherited from object

Parameters

**obj object? required**

Returns

`bool`

`public virtual int GetHashCode()` [#](#method-gethashcode)

Inherited from object

Returns

`int`

`public Type GetType()` [#](#method-gettype)

Inherited from object

Returns

`Type`

`public virtual string? ToString()` [#](#method-tostring)

Inherited from object

Returns

`string?`

<!-- PowerForge markdown artifact sha256:8DDCDC759DC7D8FBB1A6E0A1CCAABC7312EF20789A63D744E1226DB9D4209B2E -->
