# tmux.Pane.Writer

- **Module:** tmux.Pane
- **Package:** github.com/libtmux/libtmux-go/tmux
- **Language:** Go
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-go/blob/52968a3181c1c9e6d1b26c565d4b170968ae61c0/tmux/pane_input.go#L260
- **Page:** https://libtmux.org/en/go/latest/reference/tmux-pane-writer/

```
tmux.Pane.Writer(ctx: context.Context) -> io.Writer
```

Writer returns the pane's keyboard as an [io.Writer]. Bytes written to it are typed into the pane literally, and each newline is the Enter key, so [fmt.Fprintln] submits a line as a person at the keyboard would. Text with no trailing newline is typed and left on the line.

A write returns once tmux has taken the keys, before the pane's program has
read them; the program interprets what arrives. A line with a trailing
newline costs two tmux commands, the text and a separate Enter; buffering
whole lines still costs far less than writing bytes one at a time.
