# TerminalMode
<span class="source-link">[[Source]](src/term/terminal_mode.md#L-0-4)</span>

Controls the terminal mode for stdin.

In raw mode, input characters are delivered one at a time without echo
or line editing. ISIG remains on, so Ctrl-C still generates SIGINT.


```pony
primitive val TerminalMode
```

## Constructors

### create
<span class="source-link">[[Source]](src/term/terminal_mode.md#L-0-4)</span>


```pony
new val create()
: TerminalMode val^
```

#### Returns

* [TerminalMode](term-TerminalMode.md) val^

---

## Public Functions

### set_raw
<span class="source-link">[[Source]](src/term/terminal_mode.md#L-0-11)</span>


Put stdin into pseudo-raw mode. Returns true if the terminal was
changed, false if stdin is not a terminal or the call failed.


```pony
fun box set_raw(
  auth: TerminalAuth val)
: Bool val
```
#### Parameters

*   auth: [TerminalAuth](term-TerminalAuth.md) val

#### Returns

* [Bool](builtin-Bool.md) val

---

### restore
<span class="source-link">[[Source]](src/term/terminal_mode.md#L-0-18)</span>


Restore stdin to its original terminal mode.


```pony
fun box restore(
  auth: TerminalAuth val)
: None val
```
#### Parameters

*   auth: [TerminalAuth](term-TerminalAuth.md) val

#### Returns

* [None](builtin-None.md) val

---

### eq
<span class="source-link">[[Source]](src/term/terminal_mode.md#L-0-11)</span>


```pony
fun box eq(
  that: TerminalMode val)
: Bool val
```
#### Parameters

*   that: [TerminalMode](term-TerminalMode.md) val

#### Returns

* [Bool](builtin-Bool.md) val

---

### ne
<span class="source-link">[[Source]](src/term/terminal_mode.md#L-0-11)</span>


```pony
fun box ne(
  that: TerminalMode val)
: Bool val
```
#### Parameters

*   that: [TerminalMode](term-TerminalMode.md) val

#### Returns

* [Bool](builtin-Bool.md) val

---

