From e4009b63410f1c396fbfea0b6df4fb646b6b44a8 Mon Sep 17 00:00:00 2001 From: Tristian Flanagan Date: Wed, 4 Nov 2015 12:33:35 -0500 Subject: [PATCH] doc: sort tty alphabetically Reorders, with no contextual changes, the tty documentation alphabetically. PR-URL: https://github.com/nodejs/node/pull/3662 Reviewed-By: Evan Lucas Reviewed-By: James M Snell Reviewed-By: Jeremiah Senkpiel --- doc/api/tty.markdown | 41 ++++++++++++++++++----------------------- 1 file changed, 18 insertions(+), 23 deletions(-) diff --git a/doc/api/tty.markdown b/doc/api/tty.markdown index 1a99041e60..acb3bb480b 100644 --- a/doc/api/tty.markdown +++ b/doc/api/tty.markdown @@ -15,18 +15,6 @@ in a TTY context is to check `process.stdout.isTTY`: $ node -p -e "Boolean(process.stdout.isTTY)" | cat false - -## tty.isatty(fd) - -Returns `true` or `false` depending on if the `fd` is associated with a -terminal. - - -## tty.setRawMode(mode) - - Stability: 0 - Deprecated: Use [tty.ReadStream#setRawMode][] (i.e. process.stdin.setRawMode) instead. - - ## Class: ReadStream A `net.Socket` subclass that represents the readable portion of a tty. In normal @@ -44,6 +32,7 @@ of the `tty.ReadStream` instance. `tty.ReadStream` to act either as a raw device or default. `isRaw` will be set to the resulting mode. +[tty.ReadStream#setRawMode]: #tty_rs_setrawmode_mode ## Class: WriteStream @@ -51,16 +40,6 @@ A `net.Socket` subclass that represents the writable portion of a tty. In normal circumstances, `process.stdout` will be the only `tty.WriteStream` instance ever created (and only when `isatty(1)` is true). -### ws.columns - -A `Number` that gives the number of columns the TTY currently has. This property -gets updated on "resize" events. - -### ws.rows - -A `Number` that gives the number of rows the TTY currently has. This property -gets updated on "resize" events. - ### Event: 'resize' `function () {}` @@ -73,5 +52,21 @@ has changed. console.log(process.stdout.columns + 'x' + process.stdout.rows); }); +### ws.columns -[tty.ReadStream#setRawMode]: #tty_rs_setrawmode_mode +A `Number` that gives the number of columns the TTY currently has. This property +gets updated on "resize" events. + +### ws.rows + +A `Number` that gives the number of rows the TTY currently has. This property +gets updated on "resize" events. + +## tty.isatty(fd) + +Returns `true` or `false` depending on if the `fd` is associated with a +terminal. + +## tty.setRawMode(mode) + + Stability: 0 - Deprecated: Use [tty.ReadStream#setRawMode][] (i.e. process.stdin.setRawMode) instead.