# VisualLayoutOptions

The resolved viewport and outer padding used by every prepared visual.

 Class  

`ChartForgeX.Rendering`

**Namespace**

`ChartForgeX.Rendering`

**Assembly**

`ChartForgeX`

**Source**

[VisualRenderContext.cs:32](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Rendering/VisualRenderContext.cs#L32)

**Modifiers**

sealed

The resolved viewport and outer padding used by every prepared visual.

## Inheritance

- object
- VisualLayoutOptions

## Usage

 Explore 2 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 1

- Property [VisualRenderContext.Layout](/api/chartforgex-rendering-visualrendercontext/#property-layout)

### Accepted by parameters 1

- Constructor [VisualRenderContext.VisualRenderContext](/api/chartforgex-rendering-visualrendercontext/#constructor-ctor-chartforgex-rendering-visuallayoutoptions-chartforgex-themes-visualtheme-chartforgex-thememode-chartforgex-rendering-visualframe-chartforgex-typography-fontspec) parameter `layout`

 Filter members   

    Show inherited   

 

## Constructors

 VisualLayoutOptions 2 overloads 

 `public VisualLayoutOptions(VisualSize size, double padding = 24, bool fitHeightToContent = false)` [#](#constructor-ctor-chartforgex-rendering-visualsize-double-boolean) 

[VisualRenderContext.cs:32](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Rendering/VisualRenderContext.cs#L32)

Creates a viewport. Hosts implement fit sizing by supplying their measured viewport, or let row charts trim unused height.

Parameters

**size ChartForgeX.Rendering.VisualSize required**

**padding double = 24 optional**

**fitHeightToContent bool = false optional**

 `public VisualLayoutOptions(VisualSize size, ChartPadding padding, bool fitHeightToContent = false)` [#](#constructor-ctor-chartforgex-rendering-visualsize-chartforgex-primitives-chartpadding-boolean) 

[VisualRenderContext.cs:34](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Rendering/VisualRenderContext.cs#L34)

Creates a fixed viewport with independently configured outer edge insets.

Parameters

**size ChartForgeX.Rendering.VisualSize required**

**padding ChartForgeX.Primitives.ChartPadding required**

**fitHeightToContent bool = false optional**

## 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?` 

## Properties

 `public VisualSize Size { get; }` [#](#property-size) 

[VisualRenderContext.cs:41](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Rendering/VisualRenderContext.cs#L41)

Gets the resolved logical size.

 `public double Padding { get; }` [#](#property-padding) 

[VisualRenderContext.cs:44](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Rendering/VisualRenderContext.cs#L44)

Gets the smallest outer edge inset. Uniform layouts return their configured scalar padding.

 `public ChartPadding PaddingEdges { get; }` [#](#property-paddingedges) 

[VisualRenderContext.cs:46](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Rendering/VisualRenderContext.cs#L46)

Gets the outer edge insets in logical units.

 `public bool FitHeightToContent { get; }` [#](#property-fitheighttocontent) 

[VisualRenderContext.cs:49](https://github.com/EvotecIT/ChartForgeX/blob/main/ChartForgeX/Rendering/VisualRenderContext.cs#L49)

Gets whether row charts (schedules, progress bars, horizontal bullets, pictorial rows and horizontal linear gauges) may trim unused height within [VisualLayoutOptions.Size](/api/chartforgex-rendering-visuallayoutoptions/). False keeps a fixed host viewport with top-aligned rows.

<!-- PowerForge markdown artifact sha256:22B01AC0D17B6BF05BC9656DD1E6143E7F82315C89CFBACE28B94F4C3F846A20 -->
