---
name: "wxSashLayoutWindow"
section: "3erl"
platform: "linux"
package: "erlang-manpages"
version: "1:25.2.3+dfsg-1+deb12u4"
release: "Debian 12 (Bookworm)"
platforms: ["linux"]
url: "https://new.carta.tech/wxSashLayoutWindow"
---

# wxSashLayoutWindow(3erl)

Functions for wxSashLayoutWindow class

## NAME

wxSashLayoutWindow - Functions for wxSashLayoutWindow class

## DESCRIPTION

*wxSashLayoutWindow* responds to OnCalculateLayout events generated by *wxLayoutAlgorithm*. It allows the application to use simple accessors to specify how the window should be laid out, rather than having to respond to events.

The fact that the class derives from *wxSashWindow* allows sashes to be used if required, to allow the windows to be user-resizable.

The documentation for *wxLayoutAlgorithm* explains the purpose of this class in more detail.

For the window styles see *wxSashWindow*.

This class handles the EVT\_QUERY\_LAYOUT\_INFO and EVT\_CALCULATE\_LAYOUT events for you. However, if you use sashes, see *wxSashWindow* for relevant event information. See also *wxLayoutAlgorithm* for information about the layout events.

See: *wxLayoutAlgorithm*, *wxSashWindow*, Overview events

This class is derived (and can use functions) from: *wxSashWindow* *wxWindow* *wxEvtHandler*

wxWidgets docs: wxSashLayoutWindow

## DATA TYPES

```
wxSashLayoutWindow() = wx:wx_object()
```

## EXPORTS

```
new() -> wxSashLayoutWindow()
```

Default ctor.

```
new(Parent) -> wxSashLayoutWindow()
```

Types:

Parent = wxWindow:wxWindow()\

```
new(Parent, Options :: [Option]) -> wxSashLayoutWindow()
```

Types:

Parent = wxWindow:wxWindow()\
 Option = \
\
     {id, integer()} \|\
\
     {pos, {X :: integer(), Y :: integer()}} \|\
\
     {size, {W :: integer(), H :: integer()}} \|\
\
     {style, integer()}\

Constructs a sash layout window, which can be a child of a frame, dialog or any other non-control window.

```
create(This, Parent) -> boolean()
```

Types:

This = wxSashLayoutWindow()\
 Parent = wxWindow:wxWindow()\

```
create(This, Parent, Options :: [Option]) -> boolean()
```

Types:

This = wxSashLayoutWindow()\
 Parent = wxWindow:wxWindow()\
 Option = \
\
     {id, integer()} \|\
\
     {pos, {X :: integer(), Y :: integer()}} \|\
\
     {size, {W :: integer(), H :: integer()}} \|\
\
     {style, integer()}\

Initializes a sash layout window, which can be a child of a frame, dialog or any other non-control window.

```
getAlignment(This) -> wx:wx_enum()
```

Types:

This = wxSashLayoutWindow()\

Returns the alignment of the window: one of wxLAYOUT\_TOP, wxLAYOUT\_LEFT, wxLAYOUT\_RIGHT, wxLAYOUT\_BOTTOM.

```
getOrientation(This) -> wx:wx_enum()
```

Types:

This = wxSashLayoutWindow()\

Returns the orientation of the window: one of wxLAYOUT\_HORIZONTAL, wxLAYOUT\_VERTICAL.

```
setAlignment(This, Alignment) -> ok
```

Types:

This = wxSashLayoutWindow()\
 Alignment = wx:wx\_enum()\

Sets the alignment of the window (which edge of the available parent client area the window is attached to).

*alignment* is one of wxLAYOUT\_TOP, wxLAYOUT\_LEFT, wxLAYOUT\_RIGHT, wxLAYOUT\_BOTTOM.

```
setDefaultSize(This, Size) -> ok
```

Types:

This = wxSashLayoutWindow()\
 Size = {W :: integer(), H :: integer()}\

Sets the default dimensions of the window.

The dimension other than the orientation will be fixed to this value, and the orientation dimension will be ignored and the window stretched to fit the available space.

```
setOrientation(This, Orientation) -> ok
```

Types:

This = wxSashLayoutWindow()\
 Orientation = wx:wx\_enum()\

Sets the orientation of the window (the direction the window will stretch in, to fill the available parent client area).

*orientation* is one of wxLAYOUT\_HORIZONTAL, wxLAYOUT\_VERTICAL.

```
destroy(This :: wxSashLayoutWindow()) -> ok
```

Destroys the object.
