# LibTmux.Server.createWindow

- **Package:** libtmux-haskell
- **Language:** Haskell
- **Kind:** function
- **Source:** https://github.com/libtmux/libtmux-haskell/blob/72edb54317bf619c6dc54bff311844f062f8984c/src/LibTmux/Server.hs#L413
- **Page:** https://libtmux.org/en/haskell/latest/reference/libtmux-server-v-createwindow/

```haskell
createWindow
  :: Server
  -> WindowPlacement
  -> WindowOptions
  -> IO CreatedWindow
```

Signature types: [`Server`](/en/haskell/latest/reference/libtmux-server-t-server/), [`WindowPlacement`](/en/haskell/latest/reference/libtmux-creation-t-windowplacement/), [`WindowOptions`](/en/haskell/latest/reference/libtmux-creation-t-windowoptions/), [`IO`](https://hackage.haskell.org/package/base-4.22.0.0/docs/Prelude.html#t:IO), [`CreatedWindow`](/en/haskell/latest/reference/libtmux-creation-t-createdwindow/).

Create a window at an explicit session placement. The default options
 request no selection and refuse an occupied slot. tmux prints the actual
 session, index, window and pane before after-hooks. Capture again to observe
 geometry and liveness; hooks may already have removed the new entities.

## Referenced declarations

- [`LibTmux.Creation.CreatedWindow`](/en/haskell/latest/reference/libtmux-creation-t-createdwindow/) (typealias)
- [`LibTmux.Server.Server`](/en/haskell/latest/reference/libtmux-server-t-server/) (data type)
- [`LibTmux.Creation.WindowOptions`](/en/haskell/latest/reference/libtmux-creation-t-windowoptions/) (data type)
- [`LibTmux.Creation.WindowPlacement`](/en/haskell/latest/reference/libtmux-creation-t-windowplacement/) (data type)

## tmux command

The tmux commands behind `createWindow`.

- [`new-window`](/en/tmux/latest/manual/new-window/)

## tmux C API

The C declarations in tmux that implement these commands.

- [`cmd_new_window_entry`](/en/tmux/latest/reference/c-variable-cmd_new_window_entry/) (attribute)
- [`cmd_new_window_exec`](/en/tmux/latest/reference/c-function-cmd-new-window-c-cmd_new_window_exec/) (function)

## Guides

Pages that discuss `createWindow`.

- [Create sessions, windows and panes](/en/haskell/latest/guides/creation/)
- [Implementation status](/en/haskell/latest/guides/status/)
