# libtmux::Pane::send_line

- **Module:** libtmux::Pane
- **Package:** libtmux-cxx
- **Language:** C++
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-cxx/blob/393d4b0ad666f18a6581f1eb281741a75a7503f0/include/libtmux/entities.hpp#L773
- **Page:** https://libtmux.org/en/cxx/latest/reference/libtmux-pane-send_line/

```
libtmux::Pane::send_line(text: std::string_view) -> expected< void, CommandFailure >
```

The text and then Enter, as one tmux invocation.

Running a command in a pane is two commands to tmux, and sending them separately costs two round trips and leaves a window where the line is typed and not submitted. This sends both in one batch, which tmux runs fail-fast, so a refused line is not followed by an Enter.

Empty text sends Enter alone, which is what submitting a blank line means. `send_text` refuses it instead: there, nothing would be sent.
