-This is ../info/term.info, produced by makeinfo version 4.0 from
+This is ../info/term.info, produced by makeinfo version 4.8 from
term.texi.
INFO-DIR-SECTION XEmacs Editor
\1f
File: term.info, Node: term mode, Prev: Top, Up: Top
-Term Mode
-*********
+1 Term Mode
+***********
* Menu:
\1f
File: term.info, Node: Overview, Next: Connecting to remote computers, Up: term mode
-Overview
-========
+1.1 Overview
+============
- The `term' mode is used to control a program (an "inferior process").
+The `term' mode is used to control a program (an "inferior process").
It sends most keyboard input characters to the program, and displays
output from the program in the buffer. This is similar to the
traditional comint mode, and modes derived from it (such as shell and
\1f
File: term.info, Node: Output from the inferior, Next: subbuffer, Up: Overview
-Output from the inferior
-------------------------
+1.1.1 Output from the inferior
+------------------------------
- In typical usage, output from the inferior is added to the end of
-the buffer. If needed, the window will be scrolled, just like a
-regular terminal. (Only one line at a time will be scrolled, just like
-regular terminals, and in contrast to the old shell mode.) Thus the
-buffer becomes a log of your interaction with the inferior, just like
-the old shell mode.
+In typical usage, output from the inferior is added to the end of the
+buffer. If needed, the window will be scrolled, just like a regular
+terminal. (Only one line at a time will be scrolled, just like regular
+terminals, and in contrast to the old shell mode.) Thus the buffer
+becomes a log of your interaction with the inferior, just like the old
+shell mode.
Like a real terminal, term maintains a "cursor position." This is
the `process-mark' of the inferior process. If the process-mark is not
\1f
File: term.info, Node: subbuffer, Next: altsubbuffer, Prev: Output from the inferior, Up: Overview
-The sub-buffer
---------------
+1.1.2 The sub-buffer
+--------------------
- A program that talks to terminal expects the terminal to have a
-fixed size. If the program is talking a terminal emulator program such
-as `xterm', that size can be changed (if the xterm window is re-sized),
+A program that talks to terminal expects the terminal to have a fixed
+size. If the program is talking a terminal emulator program such as
+`xterm', that size can be changed (if the xterm window is re-sized),
but programs still assume a logical terminal that has a fixed size
independent of the amount of output transmitted by the programs.
The sub-buffer is defined in terms of three buffer-local-variable:
- - Variable: term-height
+ -- Variable: term-height
The height of the sub-buffer, in screen lines.
- - Variable: term-width
+ -- Variable: term-width
The width of the sub-buffer, in screen columns.
- - Variable: term-home-marker
+ -- Variable: term-home-marker
The "home" position, that is the top left corner of the sub-buffer.
The sub-buffer is assumed to be the end part of the buffer; the
\1f
File: term.info, Node: altsubbuffer, Next: Input to the inferior, Prev: subbuffer, Up: Overview
-The alternate sub-buffer
-------------------------
+1.1.3 The alternate sub-buffer
+------------------------------
- When a "graphical" program finishes, it is nice to restore the
-screen state to what it was before the program started. Many people
-are used to this behavior from `xterm', and its also offered by the
-`term' emulator.
+When a "graphical" program finishes, it is nice to restore the screen
+state to what it was before the program started. Many people are used
+to this behavior from `xterm', and its also offered by the `term'
+emulator.
- - Function: term-switch-to-alternate-sub-buffer set
+ -- Function: term-switch-to-alternate-sub-buffer set
If SET is true, and we're not already using the alternate
sub-buffer, switch to it. What this means is that the
`term-home-marker' is saved (in the variable
\1f
File: term.info, Node: Input to the inferior, Prev: altsubbuffer, Up: Overview
-Input to the inferior
----------------------
+1.1.4 Input to the inferior
+---------------------------
- Characters typed by the user are sent to the inferior. How this is
+Characters typed by the user are sent to the inferior. How this is
done depends on whether the `term' buffer is in "character" mode or
"line" mode. (A `term' buffer can also be in "pager" mode. This is
discussed <later>.) Which of these is currently active is specified in
prompt) is sent to the inferior process. Line mode is basically the
original shell mode from earlier Emacs versions.
- To switch from line mode to character mode type `C-c c'. To switch
-from character mode to line mode type `C-c l'.
+ To switch from line mode to character mode type `C-c C-k'. To
+switch from character mode to line mode type `C-c C-j'.
In either mode, "echoing" of user input is handled by the inferior.
Therefor, in line mode after an input line at the end of the buffer is
\1f
File: term.info, Node: Connecting to remote computers, Next: Paging, Prev: Overview, Up: term mode
-Connecting to remote computers
-==============================
+1.2 Connecting to remote computers
+==================================
- If you want to login to a remove computer, you can do that just as
-you would expect, using whatever commands you would normally use.
+If you want to login to a remove computer, you can do that just as you
+would expect, using whatever commands you would normally use.
(This is worth emphasizing, because earlier versions of `shell' mode
would not work properly if you tried to log in to some other computer,
\1f
File: term.info, Node: Paging, Next: Terminal escapes, Prev: Connecting to remote computers, Up: term mode
-Paging
-======
+1.3 Paging
+==========
- When the pager is enabled, Emacs will "pause" after each screenful
-of output (since the last input sent to the inferior). It will enter
+When the pager is enabled, Emacs will "pause" after each screenful of
+output (since the last input sent to the inferior). It will enter
"pager" mode, which feels a lot like the "more" program: Typing a
space requests another screenful of output. Other commands request
more or less output, or scroll backwards in the `term' buffer. In
\1f
File: term.info, Node: Terminal escapes, Prev: Paging, Up: term mode
-Terminal Escape sequences
-=========================
+1.4 Terminal Escape sequences
+=============================
- A program that does "graphics" on a terminal controls the terminal
-by sending strings called "terminal escape sequences" that the terminal
+A program that does "graphics" on a terminal controls the terminal by
+sending strings called "terminal escape sequences" that the terminal
(or terminal emulator) interprets as special commands. The `term' mode
includes a terminal emulator that understands standard ANSI escape
sequences, originally popularized by VT100 terminals, and now used by
\1f
File: term.info, Node: Cursor motion, Next: Erasing, Up: Terminal escapes
-Escape sequences to move the cursor
------------------------------------
+1.4.1 Escape sequences to move the cursor
+-----------------------------------------
`RETURN'
Moves to the beginning of the current screen line.
\1f
File: term.info, Node: Erasing, Next: Inserting and deleting, Prev: Cursor motion, Up: Terminal escapes
-Escape commands for erasing text
---------------------------------
+1.4.2 Escape commands for erasing text
+--------------------------------------
- These commands "erase" part of the sub-buffer. Erasing means
-replacing by white space; it is not the same as deleting. The relative
-screen positions of things that are not erased remain unchanged with
-each other, as does the relative cursor position.
+These commands "erase" part of the sub-buffer. Erasing means replacing
+by white space; it is not the same as deleting. The relative screen
+positions of things that are not erased remain unchanged with each
+other, as does the relative cursor position.
`E [ J'
Erase from cursor to end of screen.
\1f
File: term.info, Node: Inserting and deleting, Next: Scrolling, Prev: Erasing, Up: Terminal escapes
-Escape sequences to insert and delete text
-------------------------------------------
+1.4.3 Escape sequences to insert and delete text
+------------------------------------------------
`Esc [ N L'
Insert N (default 1) blank lines.
\1f
File: term.info, Node: Scrolling, Next: Command hook, Prev: Inserting and deleting, Up: Terminal escapes
-Escape sequences to scroll part of the visible window
------------------------------------------------------
+1.4.4 Escape sequences to scroll part of the visible window
+-----------------------------------------------------------
`Esc D'
Scroll forward one screen line.
\1f
File: term.info, Node: Command hook, Next: Miscellaneous escapes, Prev: Scrolling, Up: Terminal escapes
-Command hook
-------------
+1.4.5 Command hook
+------------------
- If `C-z' is seen, any text up to a following <LF> is scanned. The
-text in between (not counting the initial C-z or the final LF) is
-passed to the function that is the value of `term-command-hook'.
+If `C-z' is seen, any text up to a following <LF> is scanned. The text
+in between (not counting the initial C-z or the final LF) is passed to
+the function that is the value of `term-command-hook'.
The default value of the `term-command-hook' variable is the
function `term-command-hook', which handles the following:
\1f
File: term.info, Node: Miscellaneous escapes, Prev: Command hook, Up: Terminal escapes
-Miscellaneous escapes
----------------------
+1.4.6 Miscellaneous escapes
+---------------------------
`C-g (Bell)'
Calls `(beep t)'.
Tag Table:
Node: Top\7f201
Node: term mode\7f367
-Node: Overview\7f1190
-Node: Output from the inferior\7f1940
-Node: subbuffer\7f3520
-Node: altsubbuffer\7f4843
-Node: Input to the inferior\7f5868
-Node: Connecting to remote computers\7f7388
-Node: Paging\7f9293
-Node: Terminal escapes\7f9962
-Node: Cursor motion\7f10830
-Node: Erasing\7f11490
-Node: Inserting and deleting\7f12285
-Node: Scrolling\7f12675
-Node: Command hook\7f13121
-Node: Miscellaneous escapes\7f14157
+Node: Overview\7f1194
+Node: Output from the inferior\7f1949
+Node: subbuffer\7f3538
+Node: altsubbuffer\7f4873
+Node: Input to the inferior\7f5908
+Node: Connecting to remote computers\7f7441
+Node: Paging\7f9351
+Node: Terminal escapes\7f10025
+Node: Cursor motion\7f10898
+Node: Erasing\7f11570
+Node: Inserting and deleting\7f12374
+Node: Scrolling\7f12776
+Node: Command hook\7f13234
+Node: Miscellaneous escapes\7f14279
\1f
End Tag Table