# OfficeTextPadding

Text insets applied inside an Office drawing text frame before layout.

Struct 

`OfficeIMO.Drawing`

**Namespace**

`OfficeIMO.Drawing`

**Assembly**

`OfficeIMO.Core`

**Source revision**

`ba882f6b0d07` with working tree changes

**Source**

[OfficeTextPadding.cs:9](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeTextPadding.cs#L9)

**Base**

`ValueType`

**Modifiers**

sealed

Text insets applied inside an Office drawing text frame before layout.

## Inheritance

- ValueType
- OfficeTextPadding

## Usage

Explore 15 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

### Returned or exposed by 5

- Property [OfficeDrawingRichText.Padding](/api/core/officeimo-drawing-officedrawingrichtext/#property-padding)
- Property [OfficeDrawingText.Padding](/api/core/officeimo-drawing-officedrawingtext/#property-padding)
- Property [OfficeRichTextParagraph.Margins](/api/core/officeimo-drawing-officerichtextparagraph/#property-margins)
- Method [OfficeTextPadding.Scale](/api/core/officeimo-drawing-officetextpadding/#method-scale-double)
- Property [OfficeTextPadding.Empty](/api/core/officeimo-drawing-officetextpadding/#property-empty)

### Accepted by parameters 10

- Method [OfficeDrawing.AddClippedText](/api/core/officeimo-drawing-officedrawing/#method-addclippedtext-string-double-double-double-double-double-double-officeimo-drawing-officeclippath-nullable-officeimo-drawing-officefontinfo-nullable-officeimo-officecolor-officeimo-drawing-officetextalignment-nullable-system-double-officeimo-drawing-officetextverticalalignment-double-nullable-system-double-nullable-system-double-boolean-boolean-boolean-boolean-boolean-nullable-officeimo-drawing-officetextpadding-nullable-officeimo-drawing-officetextparagraphindent) parameter `padding`
- Method [OfficeDrawing.AddRichText](/api/core/officeimo-drawing-officedrawing/#method-addrichtext-collections-generic-ireadonlylist-officeimo-drawing-officerichtextrun-double-double-double-double-officeimo-drawing-officetextalignment-nullable-system-double-officeimo-drawing-officetextverticalalignment-double-nullable-system-double-nullable-system-double-boolean-boolean-boolean-boolean-nullable-officeimo-drawing-officetextpadding-nullable-officeimo-drawing-officetextparagraphindent) parameter `padding`
- Method [OfficeDrawing.AddRichTextBehindContent](/api/core/officeimo-drawing-officedrawing/#method-addrichtextbehindcontent-collections-generic-ireadonlylist-officeimo-drawing-officerichtextrun-double-double-double-double-officeimo-drawing-officetextalignment-nullable-system-double-officeimo-drawing-officetextverticalalignment-double-nullable-system-double-nullable-system-double-boolean-boolean-boolean-boolean-nullable-officeimo-drawing-officetextpadding-nullable-officeimo-drawing-officetextparagraphindent) parameter `padding`
- Method [OfficeDrawing.AddRichTextParagraphs](/api/core/officeimo-drawing-officedrawing/#method-addrichtextparagraphs-collections-generic-ireadonlylist-officeimo-drawing-officerichtextparagraph-double-double-double-double-officeimo-drawing-officetextverticalalignment-boolean-nullable-officeimo-drawing-officetextpadding) parameter `padding`
- Method [OfficeDrawing.AddStyledText](/api/core/officeimo-drawing-officedrawing/#method-addstyledtext-string-double-double-double-double-nullable-officeimo-drawing-officefontinfo-nullable-officeimo-officecolor-officeimo-drawing-officetextalignment-nullable-system-double-officeimo-drawing-officetextverticalalignment-double-nullable-system-double-nullable-system-double-boolean-boolean-boolean-boolean-boolean-nullable-officeimo-drawing-officetextpadding-nullable-officeimo-drawing-officetextparagraphindent-officeimo-drawing-officetextdecorationstyle-officeimo-drawing-officetextdecorationstyle-officeimo-drawing-officetextbaseline) parameter `padding`
- Method [OfficeDrawing.AddText](/api/core/officeimo-drawing-officedrawing/#method-addtext-string-double-double-double-double-nullable-officeimo-drawing-officefontinfo-nullable-officeimo-officecolor-officeimo-drawing-officetextalignment-nullable-system-double-officeimo-drawing-officetextverticalalignment-double-nullable-system-double-nullable-system-double-boolean-boolean-boolean-boolean-boolean-nullable-officeimo-drawing-officetextpadding-nullable-officeimo-drawing-officetextparagraphindent) parameter `padding`
- Method [OfficeDrawing.AddTextBehindContent](/api/core/officeimo-drawing-officedrawing/#method-addtextbehindcontent-string-double-double-double-double-nullable-officeimo-drawing-officefontinfo-nullable-officeimo-officecolor-officeimo-drawing-officetextalignment-nullable-system-double-officeimo-drawing-officetextverticalalignment-double-nullable-system-double-nullable-system-double-boolean-boolean-boolean-boolean-boolean-nullable-officeimo-drawing-officetextpadding-nullable-officeimo-drawing-officetextparagraphindent) parameter `padding`
- Constructor [OfficeDrawingRichText.OfficeDrawingRichText](/api/core/officeimo-drawing-officedrawingrichtext/#constructor-ctor-collections-generic-ireadonlylist-officeimo-drawing-officerichtextrun-double-double-double-double-officeimo-drawing-officetextalignment-nullable-system-double-officeimo-drawing-officetextverticalalignment-double-nullable-system-double-nullable-system-double-boolean-boolean-boolean-boolean-nullable-officeimo-drawing-officetextpadding-nullable-officeimo-drawing-officetextparagraphindent) parameter `padding`
- Constructor [OfficeDrawingText.OfficeDrawingText](/api/core/officeimo-drawing-officedrawingtext/#constructor-ctor-string-double-double-double-double-nullable-officeimo-drawing-officefontinfo-nullable-officeimo-officecolor-officeimo-drawing-officetextalignment-nullable-system-double-officeimo-drawing-officetextverticalalignment-double-nullable-system-double-nullable-system-double-boolean-boolean-boolean-boolean-boolean-nullable-officeimo-drawing-officetextpadding-nullable-officeimo-drawing-officetextparagraphindent) parameter `padding`
- Constructor [OfficeRichTextParagraph.OfficeRichTextParagraph](/api/core/officeimo-drawing-officerichtextparagraph/#constructor-ctor-collections-generic-ireadonlylist-officeimo-drawing-officerichtextrun-officeimo-drawing-officetextalignment-nullable-system-double-nullable-officeimo-drawing-officetextpadding-nullable-officeimo-drawing-officetextparagraphindent-nullable-system-double) parameter `margins`

Filter members 

Show inherited

## Constructors

`public OfficeTextPadding(double left, double top, double right, double bottom)` [#](#constructor-ctor-double-double-double-double)

[OfficeTextPadding.cs:9](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeTextPadding.cs#L9)

Creates text-frame padding in drawing units.

Parameters

**left double required**

**top double required**

**right double required**

**bottom double required**

## Methods

`public OfficeTextPadding Scale(double scale)` [#](#method-scale-double)

[OfficeTextPadding.cs:46](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeTextPadding.cs#L46)

Returns the same padding scaled by a rendering factor.

Parameters

**scale double required**

Returns

`OfficeTextPadding`

## Inherited Methods

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

Inherited from ValueType

Parameters

**obj object? required**

Returns

`bool`

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

Inherited from ValueType

Returns

`int`

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

Inherited from object

Returns

`Type`

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

Inherited from ValueType

Returns

`string?`

## Properties

`public static OfficeTextPadding Empty { get; }` [#](#property-empty)

[OfficeTextPadding.cs:21](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeTextPadding.cs#L21)

No text padding.

`public double Left { get; }` [#](#property-left)

[OfficeTextPadding.cs:24](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeTextPadding.cs#L24)

Left inset.

`public double Top { get; }` [#](#property-top)

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

Top inset.

`public double Right { get; }` [#](#property-right)

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

Right inset.

`public double Bottom { get; }` [#](#property-bottom)

[OfficeTextPadding.cs:33](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeTextPadding.cs#L33)

Bottom inset.

`public double Horizontal { get; }` [#](#property-horizontal)

[OfficeTextPadding.cs:36](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeTextPadding.cs#L36)

Total horizontal inset.

`public double Vertical { get; }` [#](#property-vertical)

[OfficeTextPadding.cs:39](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeTextPadding.cs#L39)

Total vertical inset.

`public bool IsEmpty { get; }` [#](#property-isempty)

[OfficeTextPadding.cs:42](https://github.com/EvotecIT/OfficeIMO/blob/ba882f6b0d07acddd884b5e7d3086b0cfff0a05a/OfficeIMO.Core/OfficeTextPadding.cs#L42)

Whether all insets are zero.

<!-- PowerForge markdown artifact sha256:2F9A15A629562B16B40901B03247706CF7D0D8A796ED074A3CC555BFDFEF7A43 -->
