# LayoutApi

Canonical page: https://www.adaptabletools.com/docs/reference/layoutapi

Table and Pivot Layouts: the layout that is selected, its columns, sorts and row groups, and creating, cloning, editing and deleting layouts.

```ts title="TypeScript"
export interface LayoutApi 
```

## Methods

| Method | Returns | Description |
| --- | --- | --- |
| [addColumnToCurrentLayout(columnId)](https://www.adaptabletools.com/docs/reference/layoutapi.md#addcolumntocurrentlayout) | `void` | Adds a Column to Current Table or Pivot Layout |
| [addObjectToLayout(object, module, layoutName)](https://www.adaptabletools.com/docs/reference/layoutapi.md#addobjecttolayout) | `void` | Extends an object into a Layout - once extended into any Layout, it applies only in those Layouts |
| [cloneAndSetLayout(layoutToClone, layoutName)](https://www.adaptabletools.com/docs/reference/layoutapi.md#cloneandsetlayout) | [`Layout`](https://www.adaptabletools.com/docs/reference/layout.md)` \| false` | Creates new Layout by cloning a given Layout and then loads it into Grid |
| [cloneExtendedLayout(extendedLayoutToClone, layoutName)](https://www.adaptabletools.com/docs/reference/layoutapi.md#cloneextendedlayout) | [`ExtendedLayout`](https://www.adaptabletools.com/docs/reference/extendedlayout.md)` \| false` | Clones an Extended Layout - the new Layout is extended with the same objects |
| [cloneLayout(layoutToClone, layoutName)](https://www.adaptabletools.com/docs/reference/layoutapi.md#clonelayout) | [`Layout`](https://www.adaptabletools.com/docs/reference/layout.md)` \| false` | Creates new Layout by cloning a given Layout |
| [createAndSetLayout(layoutToCreate)](https://www.adaptabletools.com/docs/reference/layoutapi.md#createandsetlayout) | [`Layout`](https://www.adaptabletools.com/docs/reference/layout.md)` \| false` | Creates new Layout and loads it into Grid |
| [createLayout(layoutToCreate)](https://www.adaptabletools.com/docs/reference/layoutapi.md#createlayout) | [`Layout`](https://www.adaptabletools.com/docs/reference/layout.md)` \| false` | Creates a new Layout |
| [createOrUpdateExtendedLayout(extendedLayout)](https://www.adaptabletools.com/docs/reference/layoutapi.md#createorupdateextendedlayout) | `void` | Creates (or Updates) an Extended Layout: saves the Layout, adds any extension objects not yet in state,<br/>and makes those objects the Layout&#39;s complete Layout Extension |
| [createOrUpdateLayout(layout)](https://www.adaptabletools.com/docs/reference/layoutapi.md#createorupdatelayout) | `void` | Creates new Layout into Adaptable State or updates an existing Layout (with same name or id) |
| [deleteLayout(layout)](https://www.adaptabletools.com/docs/reference/layoutapi.md#deletelayout) | `void` | Deletes an existing Layout (if not Default or only existing Layout) |
| [deleteLayoutByName(layoutName)](https://www.adaptabletools.com/docs/reference/layoutapi.md#deletelayoutbyname) | `void` | Deletes a Layout by name. Does nothing when it is the only Layout. |
| [doesLayoutExist(layout)](https://www.adaptabletools.com/docs/reference/layoutapi.md#doeslayoutexist) | `boolean` | Whether this Layout is already in Layout State. Compared by `Uuid`. |
| [getCurrentLayout()](https://www.adaptabletools.com/docs/reference/layoutapi.md#getcurrentlayout) | [`Layout`](https://www.adaptabletools.com/docs/reference/layout.md) | Retrieves Current Layout from Layout State |
| [getCurrentLayoutColumnSort(columnId)](https://www.adaptabletools.com/docs/reference/layoutapi.md#getcurrentlayoutcolumnsort) | [`ColumnSort`](https://www.adaptabletools.com/docs/reference/columnsort.md)`['SortOrder'] \| null` | The sort direction of a column in the current Layout. |
| [getCurrentLayoutName()](https://www.adaptabletools.com/docs/reference/layoutapi.md#getcurrentlayoutname) | `string` | Name of the Layout that is selected. |
| [getCurrentRowGroupsColumnIds()](https://www.adaptabletools.com/docs/reference/layoutapi.md#getcurrentrowgroupscolumnids) | `string[]` | Columns that group rows in the current Layout. |
| [getCurrentVisibleColumnIdsForPivotLayout()](https://www.adaptabletools.com/docs/reference/layoutapi.md#getcurrentvisiblecolumnidsforpivotlayout) | `string[]` | Column ids currently displayed in a Pivot Layout. |
| [getCurrentVisibleColumnIdsForTableLayout()](https://www.adaptabletools.com/docs/reference/layoutapi.md#getcurrentvisiblecolumnidsfortablelayout) | `string[]` | Column ids currently displayed in a Table Layout. |
| [getCurrentVisibleColumnIdsMapForTableLayout()](https://www.adaptabletools.com/docs/reference/layoutapi.md#getcurrentvisiblecolumnidsmapfortablelayout) | `\{ [key: string]: boolean; \}` | Column ids in the current Table Layout. |
| [getExtendedLayoutByName(layoutName)](https://www.adaptabletools.com/docs/reference/layoutapi.md#getextendedlayoutbyname) | [`ExtendedLayout`](https://www.adaptabletools.com/docs/reference/extendedlayout.md)` \| undefined` | Retrieves the Layout with the given name, together with the objects extended into it<br/>(global objects, which apply in every Layout, are not included) |
| [getLayoutById(id)](https://www.adaptabletools.com/docs/reference/layoutapi.md#getlayoutbyid) | [`Layout`](https://www.adaptabletools.com/docs/reference/layout.md) | Retrieves Layout by by the technical ID (from `LayoutState`) |
| [getLayoutByName(layoutName)](https://www.adaptabletools.com/docs/reference/layoutapi.md#getlayoutbyname) | [`Layout`](https://www.adaptabletools.com/docs/reference/layout.md)` \| null` | Retrieves Layout with the given name |
| [getLayoutExtensions(layoutName)](https://www.adaptabletools.com/docs/reference/layoutapi.md#getlayoutextensions) | [`LayoutExtensionInfo`](https://www.adaptabletools.com/docs/reference/layoutextensioninfo.md) | Retrieves the names of the objects, per Module, extended into a Layout |
| [getLayouts()](https://www.adaptabletools.com/docs/reference/layoutapi.md#getlayouts) | [`Layout`](https://www.adaptabletools.com/docs/reference/layout.md)`[]` | Retrieves all Layouts in Adaptable State |
| [getLayoutsForObject(object, module)](https://www.adaptabletools.com/docs/reference/layoutapi.md#getlayoutsforobject) | `string[]` | Retrieves the names of the Layouts an object is extended into (empty when the object is global) |
| [getLayoutState()](https://www.adaptabletools.com/docs/reference/layoutapi.md#getlayoutstate) | [`LayoutState`](https://www.adaptabletools.com/docs/reference/layoutstate.md) | The Layout section of Adaptable State. |
| [isCurrentLayoutPivot()](https://www.adaptabletools.com/docs/reference/layoutapi.md#iscurrentlayoutpivot) | `boolean` | Whether the current Layout is a Pivot Layout. |
| [openLayoutSettingsPanel()](https://www.adaptabletools.com/docs/reference/layoutapi.md#openlayoutsettingspanel) | `void` | Opens Settings Panel with Layout section selected |
| [removeColumnFromCurrentLayout(columnId)](https://www.adaptabletools.com/docs/reference/layoutapi.md#removecolumnfromcurrentlayout) | `void` | Removes a Column from Current Table or Pivot Layout |
| [removeObjectFromLayout(object, module, layoutName)](https://www.adaptabletools.com/docs/reference/layoutapi.md#removeobjectfromlayout) | `void` | Removes an object from a Layout - when it is no longer extended into any Layout, it becomes global |
| [renameLayout(layoutName, newLayoutName)](https://www.adaptabletools.com/docs/reference/layoutapi.md#renamelayout) | `boolean` | Renames a Layout, keeping the objects extended into it |
| [saveCurrentLayout()](https://www.adaptabletools.com/docs/reference/layoutapi.md#savecurrentlayout) | `void` | Saves current Layout - using column order, visibility, sorting etc. currently in use in the grid |
| [setColumnCaption(columnId, caption)](https://www.adaptabletools.com/docs/reference/layoutapi.md#setcolumncaption) | `void` | Sets a new Caption / Header for a Column (only for current Layout) |
| [setExtendedLayout(extendedLayout)](https://www.adaptabletools.com/docs/reference/layoutapi.md#setextendedlayout) | `void` | Sets (i.e. selects) the Extended Layout |
| [setLayout(layoutName)](https://www.adaptabletools.com/docs/reference/layoutapi.md#setlayout) | `void` | Sets (i.e. selects) the Layout |
| [setLayoutExtensions(layoutName, extensionInfo)](https://www.adaptabletools.com/docs/reference/layoutapi.md#setlayoutextensions) | `void` | Replaces the objects extended into a Layout (an empty extensionInfo makes those objects global again, unless<br/>they are extended into other Layouts) |
| [setLayoutsForObject(object, module, layoutNames)](https://www.adaptabletools.com/docs/reference/layoutapi.md#setlayoutsforobject) | `void` | Extends an object into exactly the given Layouts, removing it from any others |
| [showChangeColumnCaption(column)](https://www.adaptabletools.com/docs/reference/layoutapi.md#showchangecolumncaption) | `void` | Opens Change Column Caption popup |
| [showLayoutEditor(layoutName, layoutType, action)](https://www.adaptabletools.com/docs/reference/layoutapi.md#showlayouteditor) | `void` | Opens Layout Editor - for Current or a named Layout |
| [updateCurrentLayout(updateFn)](https://www.adaptabletools.com/docs/reference/layoutapi.md#updatecurrentlayout) | `void` | Updates current Layout using the partial Layout props provided in a function |

## Method Details

### addColumnToCurrentLayout

Adds a Column to Current Table or Pivot Layout

```ts title="TypeScript"
addColumnToCurrentLayout(columnId: string): void;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| columnId | `string` | Column to add |

###### Returns

`void`

### addObjectToLayout

Extends an object into a Layout - once extended into any Layout, it applies only in those Layouts

```ts title="TypeScript"
addObjectToLayout(object: LayoutExtensionObject, module: LayoutExtensionModule, layoutName?: string): void;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| object | [`LayoutExtensionObject`](https://www.adaptabletools.com/docs/reference/layoutextensionobject.md) | Object to extend |
| module | [`LayoutExtensionModule`](https://www.adaptabletools.com/docs/reference/layoutextensionmodule.md) | Module the object belongs to |
| layoutName | `string` | Layout to extend it into; defaults to Current Layout |

###### Returns

`void`

### cloneAndSetLayout

Creates new Layout by cloning a given Layout and then loads it into Grid

```ts title="TypeScript"
cloneAndSetLayout(layoutToClone: Layout, layoutName: string): Layout | false;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| layoutToClone | [`Layout`](https://www.adaptabletools.com/docs/reference/layout.md) | Layout to clone |
| layoutName | `string` | name to use for new Layout |

###### Returns

 created Layout object or `false` if creation failed

[`Layout`](https://www.adaptabletools.com/docs/reference/layout.md)` | false`

### cloneExtendedLayout

Clones an Extended Layout - the new Layout is extended with the same objects

```ts title="TypeScript"
cloneExtendedLayout(extendedLayoutToClone: ExtendedLayout, layoutName: string): ExtendedLayout | false;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| extendedLayoutToClone | [`ExtendedLayout`](https://www.adaptabletools.com/docs/reference/extendedlayout.md) | ExtendedLayout to Clone |
| layoutName | `string` | New name for Layout being cloned |

###### Returns

 The cloned Extended Layout, or `false` when the source does not exist or the new name is already used

[`ExtendedLayout`](https://www.adaptabletools.com/docs/reference/extendedlayout.md)` | false`

### cloneLayout

Creates new Layout by cloning a given Layout

```ts title="TypeScript"
cloneLayout(layoutToClone: Layout, layoutName: string): Layout | false;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| layoutToClone | [`Layout`](https://www.adaptabletools.com/docs/reference/layout.md) | Layout to clone |
| layoutName | `string` | name of new Layout |

###### Returns

 created Layout object or `false` if creation failed

[`Layout`](https://www.adaptabletools.com/docs/reference/layout.md)` | false`

### createAndSetLayout

Creates new Layout and loads it into Grid

```ts title="TypeScript"
createAndSetLayout(layoutToCreate: Layout): Layout | false;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| layoutToCreate | [`Layout`](https://www.adaptabletools.com/docs/reference/layout.md) | Layout to create |

###### Returns

 created Layout object or `false` if creation failed

[`Layout`](https://www.adaptabletools.com/docs/reference/layout.md)` | false`

### createLayout

Creates a new Layout

```ts title="TypeScript"
createLayout(layoutToCreate: Layout): Layout | false;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| layoutToCreate | [`Layout`](https://www.adaptabletools.com/docs/reference/layout.md) | Layout to create |

###### Returns

 created Layout object or `false` if Layout with the same name/Uuid already exists

[`Layout`](https://www.adaptabletools.com/docs/reference/layout.md)` | false`

### createOrUpdateExtendedLayout

Creates (or Updates) an Extended Layout: saves the Layout, adds any extension objects not yet in state,
and makes those objects the Layout&#39;s complete Layout Extension

```ts title="TypeScript"
createOrUpdateExtendedLayout(extendedLayout: ExtendedLayout): void;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| extendedLayout | [`ExtendedLayout`](https://www.adaptabletools.com/docs/reference/extendedlayout.md) | ExtendedLayout to Create |

###### Returns

`void`

### createOrUpdateLayout

Creates new Layout into Adaptable State or updates an existing Layout (with same name or id)

```ts title="TypeScript"
createOrUpdateLayout(layout: Layout): void;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| layout | [`Layout`](https://www.adaptabletools.com/docs/reference/layout.md) | the Layout to create or update |

###### Returns

`void`

### deleteLayout

Deletes an existing Layout (if not Default or only existing Layout)

```ts title="TypeScript"
deleteLayout(layout: Layout): void;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| layout | [`Layout`](https://www.adaptabletools.com/docs/reference/layout.md) | The Layout to delete |

###### Returns

`void`

### deleteLayoutByName

Deletes a Layout by name. Does nothing when it is the only Layout.

```ts title="TypeScript"
deleteLayoutByName(layoutName: string): void;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| layoutName | `string` | Name of the Layout to delete |

###### Returns

`void`

### doesLayoutExist

Whether this Layout is already in Layout State. Compared by `Uuid`.

```ts title="TypeScript"
doesLayoutExist(layout: Layout): boolean;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| layout | [`Layout`](https://www.adaptabletools.com/docs/reference/layout.md) | Layout to check |

###### Returns

 `true` when a Layout with the same `Uuid` is in state

`boolean`

### getCurrentLayout

Retrieves Current Layout from Layout State

```ts title="TypeScript"
getCurrentLayout(): Layout;
```

###### Returns

 layout

[`Layout`](https://www.adaptabletools.com/docs/reference/layout.md)

### getCurrentLayoutColumnSort

The sort direction of a column in the current Layout.

```ts title="TypeScript"
getCurrentLayoutColumnSort(columnId: string): ColumnSort['SortOrder'] | null;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| columnId | `string` | Column to read |

###### Returns

 `'Asc'` or `'Desc'`, or `null` when the column is not sorted in this Layout

[`ColumnSort`](https://www.adaptabletools.com/docs/reference/columnsort.md)`['SortOrder'] | null`

### getCurrentLayoutName

Name of the Layout that is selected.

```ts title="TypeScript"
getCurrentLayoutName(): string;
```

###### Returns

 The current Layout name

`string`

### getCurrentRowGroupsColumnIds

Columns that group rows in the current Layout.

```ts title="TypeScript"
getCurrentRowGroupsColumnIds(): string[];
```

###### Returns

 `RowGroupedColumns` for a Table Layout, or `PivotGroupedColumns` for a Pivot Layout

`string[]`

### getCurrentVisibleColumnIdsForPivotLayout

Column ids currently displayed in a Pivot Layout.

```ts title="TypeScript"
getCurrentVisibleColumnIdsForPivotLayout(): string[];
```

###### Returns

 The displayed column ids, including pivot result columns. Empty when the current Layout is a Table Layout

`string[]`

### getCurrentVisibleColumnIdsForTableLayout

Column ids currently displayed in a Table Layout.

```ts title="TypeScript"
getCurrentVisibleColumnIdsForTableLayout(): string[];
```

###### Returns

 The displayed column ids. Empty when the current Layout is a Pivot Layout

`string[]`

### getCurrentVisibleColumnIdsMapForTableLayout

Column ids in the current Table Layout.

```ts title="TypeScript"
getCurrentVisibleColumnIdsMapForTableLayout(): {
        [key: string]: boolean;
    };
```

###### Returns

 Each Table Layout column id mapped to `true`. An empty object when the current Layout is a Pivot Layout

`\{ [key: string]: boolean; \}`

### getExtendedLayoutByName

Retrieves the Layout with the given name, together with the objects extended into it
(global objects, which apply in every Layout, are not included)

```ts title="TypeScript"
getExtendedLayoutByName(layoutName: string): ExtendedLayout | undefined;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| layoutName | `string` | Layout to retrieve |

###### Returns

 The Layout and the objects extended into it, or `undefined` when no Layout has that name. Objects that apply in every Layout are not included

[`ExtendedLayout`](https://www.adaptabletools.com/docs/reference/extendedlayout.md)` | undefined`

### getLayoutById

Retrieves Layout by by the technical ID (from `LayoutState`)

```ts title="TypeScript"
getLayoutById(id: Layout['Uuid']): Layout;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| id | [`Layout`](https://www.adaptabletools.com/docs/reference/layout.md)`['Uuid']` | Layout id |

###### Returns

 layout

[`Layout`](https://www.adaptabletools.com/docs/reference/layout.md)

### getLayoutByName

Retrieves Layout with the given name

```ts title="TypeScript"
getLayoutByName(layoutName: string): Layout | null;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| layoutName | `string` | Layout to retrieve |

###### Returns

 layout

[`Layout`](https://www.adaptabletools.com/docs/reference/layout.md)` | null`

### getLayoutExtensions

Retrieves the names of the objects, per Module, extended into a Layout

```ts title="TypeScript"
getLayoutExtensions(layoutName: string): LayoutExtensionInfo;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| layoutName | `string` | Layout to check |

###### Returns

 Object names grouped by module. Empty when the Layout has no extensions

[`LayoutExtensionInfo`](https://www.adaptabletools.com/docs/reference/layoutextensioninfo.md)

### getLayouts

Retrieves all Layouts in Adaptable State

```ts title="TypeScript"
getLayouts(): Layout[];
```

###### Returns

 layouts

[`Layout`](https://www.adaptabletools.com/docs/reference/layout.md)`[]`

### getLayoutsForObject

Retrieves the names of the Layouts an object is extended into (empty when the object is global)

```ts title="TypeScript"
getLayoutsForObject(object: LayoutExtensionObject, module: LayoutExtensionModule): string[];
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| object | [`LayoutExtensionObject`](https://www.adaptabletools.com/docs/reference/layoutextensionobject.md) | Object to check |
| module | [`LayoutExtensionModule`](https://www.adaptabletools.com/docs/reference/layoutextensionmodule.md) | Module the object belongs to |

###### Returns

 Layout names the object is extended into. Empty when the object applies in every Layout

`string[]`

### getLayoutState

The Layout section of Adaptable State.

```ts title="TypeScript"
getLayoutState(): LayoutState;
```

###### Returns

 Layouts and the name of the current Layout

[`LayoutState`](https://www.adaptabletools.com/docs/reference/layoutstate.md)

### isCurrentLayoutPivot

Whether the current Layout is a Pivot Layout.

```ts title="TypeScript"
isCurrentLayoutPivot(): boolean;
```

###### Returns

 `true` when the current Layout is a Pivot Layout

`boolean`

### openLayoutSettingsPanel

Opens Settings Panel with Layout section selected

```ts title="TypeScript"
openLayoutSettingsPanel(): void;
```

###### Returns

`void`

### removeColumnFromCurrentLayout

Removes a Column from Current Table or Pivot Layout

```ts title="TypeScript"
removeColumnFromCurrentLayout(columnId: string): void;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| columnId | `string` | Column to remove |

###### Returns

`void`

### removeObjectFromLayout

Removes an object from a Layout - when it is no longer extended into any Layout, it becomes global

```ts title="TypeScript"
removeObjectFromLayout(object: LayoutExtensionObject, module: LayoutExtensionModule, layoutName?: string): void;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| object | [`LayoutExtensionObject`](https://www.adaptabletools.com/docs/reference/layoutextensionobject.md) | Object to remove |
| module | [`LayoutExtensionModule`](https://www.adaptabletools.com/docs/reference/layoutextensionmodule.md) | Module the object belongs to |
| layoutName | `string` | Layout to remove it from; defaults to Current Layout |

###### Returns

`void`

### renameLayout

Renames a Layout, keeping the objects extended into it

```ts title="TypeScript"
renameLayout(layoutName: string, newLayoutName: string): boolean;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| layoutName | `string` | Current name of the Layout |
| newLayoutName | `string` | New name (must not be used by another Layout) |

###### Returns

 false if the Layout does not exist or the new name is taken

`boolean`

### saveCurrentLayout

Saves current Layout - using column order, visibility, sorting etc. currently in use in the grid

```ts title="TypeScript"
saveCurrentLayout(): void;
```

###### Returns

`void`

### setColumnCaption

Sets a new Caption / Header for a Column (only for current Layout)

```ts title="TypeScript"
setColumnCaption(columnId: string, caption: string): void;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| columnId | `string` | Column to Update |
| caption | `string` | New Caption to display |

###### Returns

`void`

### setExtendedLayout

Sets (i.e. selects) the Extended Layout

```ts title="TypeScript"
setExtendedLayout(extendedLayout: ExtendedLayout): void;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| extendedLayout | [`ExtendedLayout`](https://www.adaptabletools.com/docs/reference/extendedlayout.md) | Extended Layout to set |

###### Returns

`void`

### setLayout

Sets (i.e. selects) the Layout

```ts title="TypeScript"
setLayout(layoutName: string): void;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| layoutName | `string` | Layout to set (has to be name of existing Layout) |

###### Returns

`void`

### setLayoutExtensions

Replaces the objects extended into a Layout (an empty extensionInfo makes those objects global again, unless
they are extended into other Layouts)

```ts title="TypeScript"
setLayoutExtensions(layoutName: string, extensionInfo: LayoutExtensionInfo): void;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| layoutName | `string` | Layout to update |
| extensionInfo | [`LayoutExtensionInfo`](https://www.adaptabletools.com/docs/reference/layoutextensioninfo.md) | Names of the objects, per Module, to extend into the Layout |

###### Returns

`void`

### setLayoutsForObject

Extends an object into exactly the given Layouts, removing it from any others

```ts title="TypeScript"
setLayoutsForObject(object: LayoutExtensionObject, module: LayoutExtensionModule, layoutNames: string[]): void;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| object | [`LayoutExtensionObject`](https://www.adaptabletools.com/docs/reference/layoutextensionobject.md) | Object to extend (referenced by its Name) |
| module | [`LayoutExtensionModule`](https://www.adaptabletools.com/docs/reference/layoutextensionmodule.md) | Module the object belongs to |
| layoutNames | `string[]` | Layouts to extend the object into; an empty array makes the object global |

###### Returns

`void`

### showChangeColumnCaption

Opens Change Column Caption popup

```ts title="TypeScript"
showChangeColumnCaption(column: AdaptableColumn): void;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| column | [`AdaptableColumn`](https://www.adaptabletools.com/docs/reference/adaptablecolumn.md) | Column to open Popup for |

###### Returns

`void`

### showLayoutEditor

Opens Layout Editor - for Current or a named Layout

```ts title="TypeScript"
showLayoutEditor(layoutName?: string, layoutType?: 'table' | 'pivot', 
    action?: 'New' | 'Clone' | 'Edit'): void;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| layoutName | `string` | Name of the Layout to edit or clone. Omit it to use the current Layout |
| layoutType | `'table' \| 'pivot'` | `'table'` or `'pivot'`. Used when `action` is `'New'` |
| action | `'New' \| 'Clone' \| 'Edit'` | `'Edit'`, `'Clone'` or `'New'`. Defaults to `'Edit'` |

###### Returns

`void`

### updateCurrentLayout

Updates current Layout using the partial Layout props provided in a function

```ts title="TypeScript"
updateCurrentLayout(updateFn: (layout: TableLayout | PivotLayout) => TableLayout | PivotLayout): void;
```

###### Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| updateFn | `(layout: `[`TableLayout`](https://www.adaptabletools.com/docs/reference/tablelayout.md)` \| `[`PivotLayout`](https://www.adaptabletools.com/docs/reference/pivotlayout.md)`) => `[`TableLayout`](https://www.adaptabletools.com/docs/reference/tablelayout.md)` \| `[`PivotLayout`](https://www.adaptabletools.com/docs/reference/pivotlayout.md) | a function which returns a full Layout |

###### Returns

`void`
