diff options
| author | Juri Linkov | 2006-02-23 23:16:12 +0000 |
|---|---|---|
| committer | Juri Linkov | 2006-02-23 23:16:12 +0000 |
| commit | 9f261d3c1d29f48ca2f8f96e4809bccbe3c81e89 (patch) | |
| tree | 96e4c0644fadf6f9e54bd04a568926d06f4738fe | |
| parent | 172892e3973182349f5ce43c02281fb4358d1e13 (diff) | |
| download | emacs-9f261d3c1d29f48ca2f8f96e4809bccbe3c81e89.tar.gz emacs-9f261d3c1d29f48ca2f8f96e4809bccbe3c81e89.zip | |
(Common requests): Move `Turning on auto-fill by
default' after `Wrapping words automatically'. Move `Working with
unprintable characters' before `Searching for/replacing newlines'.
Move `Replacing highlighted text' after `Highlighting a region'.
Merge `Repeating commands' and `Repeating a command as many times
as possible' into the former.
(Packages that do not come with Emacs): Add refs to Gmane and etc/MORE.STUFF.
| -rw-r--r-- | man/ChangeLog | 11 | ||||
| -rw-r--r-- | man/faq.texi | 269 |
2 files changed, 136 insertions, 144 deletions
diff --git a/man/ChangeLog b/man/ChangeLog index 6b12f4390da..e2d948aef35 100644 --- a/man/ChangeLog +++ b/man/ChangeLog | |||
| @@ -1,5 +1,16 @@ | |||
| 1 | 2006-02-23 Juri Linkov <juri@jurta.org> | 1 | 2006-02-23 Juri Linkov <juri@jurta.org> |
| 2 | 2 | ||
| 3 | * faq.texi (Common requests): Move `Turning on auto-fill by | ||
| 4 | default' after `Wrapping words automatically'. Move `Working with | ||
| 5 | unprintable characters' before `Searching for/replacing newlines'. | ||
| 6 | Move `Replacing highlighted text' after `Highlighting a region'. | ||
| 7 | Merge `Repeating commands' and `Repeating a command as many times | ||
| 8 | as possible' into the former. | ||
| 9 | (Packages that do not come with Emacs): Add refs to Gmane and | ||
| 10 | etc/MORE.STUFF. | ||
| 11 | |||
| 12 | 2006-02-23 Juri Linkov <juri@jurta.org> | ||
| 13 | |||
| 3 | * faq.texi (Newsgroup archives): Update URLs of GNU mail archives. | 14 | * faq.texi (Newsgroup archives): Update URLs of GNU mail archives. |
| 4 | (Reporting bugs): Suggest using `M-x report-emacs-bug'. | 15 | (Reporting bugs): Suggest using `M-x report-emacs-bug'. |
| 5 | Add xref to `(emacs)Reporting Bugs'. | 16 | Add xref to `(emacs)Reporting Bugs'. |
diff --git a/man/faq.texi b/man/faq.texi index 9dc6772d7e1..0c4838d9019 100644 --- a/man/faq.texi +++ b/man/faq.texi | |||
| @@ -1185,14 +1185,15 @@ In addition, Emacs 22 now includes the Emacs Lisp Reference Manual | |||
| 1185 | * Displaying the current line or column:: | 1185 | * Displaying the current line or column:: |
| 1186 | * Displaying the current file name in the titlebar:: | 1186 | * Displaying the current file name in the titlebar:: |
| 1187 | * Turning on abbrevs by default:: | 1187 | * Turning on abbrevs by default:: |
| 1188 | * Turning on auto-fill by default:: | ||
| 1189 | * Associating modes with files:: | 1188 | * Associating modes with files:: |
| 1190 | * Working with unprintable characters:: | ||
| 1191 | * Highlighting a region:: | 1189 | * Highlighting a region:: |
| 1190 | * Replacing highlighted text:: | ||
| 1192 | * Controlling case sensitivity:: | 1191 | * Controlling case sensitivity:: |
| 1192 | * Working with unprintable characters:: | ||
| 1193 | * Searching for/replacing newlines:: | 1193 | * Searching for/replacing newlines:: |
| 1194 | * Yanking text in isearch:: | 1194 | * Yanking text in isearch:: |
| 1195 | * Wrapping words automatically:: | 1195 | * Wrapping words automatically:: |
| 1196 | * Turning on auto-fill by default:: | ||
| 1196 | * Spell-checkers:: | 1197 | * Spell-checkers:: |
| 1197 | * Checking TeX and *roff documents:: | 1198 | * Checking TeX and *roff documents:: |
| 1198 | * Changing load-path:: | 1199 | * Changing load-path:: |
| @@ -1213,7 +1214,6 @@ In addition, Emacs 22 now includes the Emacs Lisp Reference Manual | |||
| 1213 | * Changing the length of a Tab:: | 1214 | * Changing the length of a Tab:: |
| 1214 | * Inserting text at the beginning of each line:: | 1215 | * Inserting text at the beginning of each line:: |
| 1215 | * Underlining paragraphs:: | 1216 | * Underlining paragraphs:: |
| 1216 | * Repeating a command as many times as possible:: | ||
| 1217 | * Forcing the cursor to remain in the same column:: | 1217 | * Forcing the cursor to remain in the same column:: |
| 1218 | * Forcing Emacs to iconify itself:: | 1218 | * Forcing Emacs to iconify itself:: |
| 1219 | * Using regular expressions:: | 1219 | * Using regular expressions:: |
| @@ -1226,7 +1226,6 @@ In addition, Emacs 22 now includes the Emacs Lisp Reference Manual | |||
| 1226 | * Deleting menus and menu options:: | 1226 | * Deleting menus and menu options:: |
| 1227 | * Turning on syntax highlighting:: | 1227 | * Turning on syntax highlighting:: |
| 1228 | * Scrolling only one line:: | 1228 | * Scrolling only one line:: |
| 1229 | * Replacing highlighted text:: | ||
| 1230 | * Editing MS-DOS files:: | 1229 | * Editing MS-DOS files:: |
| 1231 | * Filling paragraphs with a single space:: | 1230 | * Filling paragraphs with a single space:: |
| 1232 | * Escape sequences in shell output:: | 1231 | * Escape sequences in shell output:: |
| @@ -1404,7 +1403,7 @@ in your @file{.emacs}: | |||
| 1404 | (setq frame-title-format "%b") | 1403 | (setq frame-title-format "%b") |
| 1405 | @end lisp | 1404 | @end lisp |
| 1406 | 1405 | ||
| 1407 | @node Turning on abbrevs by default, Turning on auto-fill by default, Displaying the current file name in the titlebar, Common requests | 1406 | @node Turning on abbrevs by default, Associating modes with files, Displaying the current file name in the titlebar, Common requests |
| 1408 | @section How do I turn on abbrevs by default just in mode @var{mymode}? | 1407 | @section How do I turn on abbrevs by default just in mode @var{mymode}? |
| 1409 | @cindex Abbrevs, turning on by default | 1408 | @cindex Abbrevs, turning on by default |
| 1410 | 1409 | ||
| @@ -1423,30 +1422,7 @@ Put this in your @file{.emacs} file: | |||
| 1423 | Starting with Emacs 22, the standard abbrevs file is read automatically | 1422 | Starting with Emacs 22, the standard abbrevs file is read automatically |
| 1424 | at startup, so the first of these two forms becomes unnecessary. | 1423 | at startup, so the first of these two forms becomes unnecessary. |
| 1425 | 1424 | ||
| 1426 | @node Turning on auto-fill by default, Associating modes with files, Turning on abbrevs by default, Common requests | 1425 | @node Associating modes with files, Highlighting a region, Turning on abbrevs by default, Common requests |
| 1427 | @section How do I turn on @code{auto-fill-mode} by default? | ||
| 1428 | @cindex @code{auto-fill-mode}, activating automatically | ||
| 1429 | @cindex Filling automatically | ||
| 1430 | @cindex Automatic entry to @code{auto-fill-mode} | ||
| 1431 | |||
| 1432 | To turn on @code{auto-fill-mode} just once for one buffer, use @kbd{M-x | ||
| 1433 | auto-fill-mode}. | ||
| 1434 | |||
| 1435 | To turn it on for every buffer in a certain mode, you must use the hook | ||
| 1436 | for that mode. For example, to turn on @code{auto-fill} mode for all | ||
| 1437 | text buffers, including the following in your @file{.emacs} file: | ||
| 1438 | |||
| 1439 | @lisp | ||
| 1440 | (add-hook 'text-mode-hook 'turn-on-auto-fill) | ||
| 1441 | @end lisp | ||
| 1442 | |||
| 1443 | If you want @code{auto-fill} mode on in all major modes, do this: | ||
| 1444 | |||
| 1445 | @lisp | ||
| 1446 | (setq-default auto-fill-function 'do-auto-fill) | ||
| 1447 | @end lisp | ||
| 1448 | |||
| 1449 | @node Associating modes with files, Working with unprintable characters, Turning on auto-fill by default, Common requests | ||
| 1450 | @section How do I make Emacs use a certain major mode for certain files? | 1426 | @section How do I make Emacs use a certain major mode for certain files? |
| 1451 | @cindex Associating modes with files | 1427 | @cindex Associating modes with files |
| 1452 | @cindex File extensions and modes | 1428 | @cindex File extensions and modes |
| @@ -1476,63 +1452,7 @@ the script.) This feature only applies when the file name doesn't | |||
| 1476 | indicate which mode to use. Use @kbd{C-h v} (or @kbd{M-x | 1452 | indicate which mode to use. Use @kbd{C-h v} (or @kbd{M-x |
| 1477 | describe-variable}) on @code{interpreter-mode-alist} to learn more. | 1453 | describe-variable}) on @code{interpreter-mode-alist} to learn more. |
| 1478 | 1454 | ||
| 1479 | @node Working with unprintable characters, Highlighting a region, Associating modes with files, Common requests | 1455 | @node Highlighting a region, Replacing highlighted text, Associating modes with files, Common requests |
| 1480 | @section How do I search for, delete, or replace unprintable (eight-bit or control) characters? | ||
| 1481 | @cindex Unprintable characters, working with | ||
| 1482 | @cindex Working with unprintable characters | ||
| 1483 | @cindex Control characters, working with | ||
| 1484 | @cindex Eight-bit characters, working with | ||
| 1485 | @cindex Searching for unprintable characters | ||
| 1486 | @cindex Regexps and unprintable characters | ||
| 1487 | |||
| 1488 | To search for a single character that appears in the buffer as, for | ||
| 1489 | example, @samp{\237}, you can type @kbd{C-s C-q 2 3 7}. (This assumes | ||
| 1490 | the value of @code{search-quote-char} is 17 (i.e., @kbd{C-q}).) | ||
| 1491 | Searching for @strong{all} unprintable characters is best done with a | ||
| 1492 | regular expression (@dfn{regexp}) search. The easiest regexp to use for | ||
| 1493 | the unprintable chars is the complement of the regexp for the printable | ||
| 1494 | chars. | ||
| 1495 | |||
| 1496 | @itemize @bullet | ||
| 1497 | |||
| 1498 | @item | ||
| 1499 | Regexp for the printable chars: @samp{[\t\n\r\f -~]} | ||
| 1500 | |||
| 1501 | @item | ||
| 1502 | Regexp for the unprintable chars: @samp{[^\t\n\r\f -~]} | ||
| 1503 | |||
| 1504 | @end itemize | ||
| 1505 | |||
| 1506 | To type these special characters in an interactive argument to | ||
| 1507 | @code{isearch-forward-regexp} or @code{re-search-forward}, you need to | ||
| 1508 | use @kbd{C-q}. (@samp{\t}, @samp{\n}, @samp{\r}, and @samp{\f} stand | ||
| 1509 | respectively for @key{TAB}, @key{LFD}, @key{RET}, and @kbd{C-l}.) So, | ||
| 1510 | to search for unprintable characters using @code{re-search-forward}: | ||
| 1511 | |||
| 1512 | @kbd{M-x re-search-forward @key{RET} [^ @key{TAB} C-q @key{LFD} C-q @key{RET} C-q C-l @key{SPC} -~] @key{RET}} | ||
| 1513 | |||
| 1514 | Using @code{isearch-forward-regexp}: | ||
| 1515 | |||
| 1516 | @kbd{C-M-s [^ @key{TAB} @key{LFD} C-q @key{RET} C-q C-l @key{SPC} -~]} | ||
| 1517 | |||
| 1518 | To delete all unprintable characters, simply use replace-regexp: | ||
| 1519 | |||
| 1520 | @kbd{M-x replace-regexp @key{RET} [^ @key{TAB} C-q @key{LFD} C-q @key{RET} C-q C-l @key{SPC} -~] @key{RET} @key{RET}} | ||
| 1521 | |||
| 1522 | Replacing is similar to the above. To replace all unprintable | ||
| 1523 | characters with a colon, use: | ||
| 1524 | |||
| 1525 | M-x replace-regexp @key{RET} [^ @key{TAB} C-q @key{LFD} C-q @key{RET} C-q C-l @key{SPC} -~] @key{RET} : @key{RET} | ||
| 1526 | |||
| 1527 | @itemize @bullet | ||
| 1528 | |||
| 1529 | @item | ||
| 1530 | You don't need to quote @key{TAB} with either isearch or typing | ||
| 1531 | something in the minibuffer. | ||
| 1532 | |||
| 1533 | @end itemize | ||
| 1534 | |||
| 1535 | @node Highlighting a region, Controlling case sensitivity, Working with unprintable characters, Common requests | ||
| 1536 | @section How can I highlight a region of text in Emacs? | 1456 | @section How can I highlight a region of text in Emacs? |
| 1537 | @cindex Highlighting text | 1457 | @cindex Highlighting text |
| 1538 | @cindex Text, highlighting | 1458 | @cindex Text, highlighting |
| @@ -1549,7 +1469,32 @@ including | |||
| 1549 | @noindent | 1469 | @noindent |
| 1550 | in your @file{.emacs} file. | 1470 | in your @file{.emacs} file. |
| 1551 | 1471 | ||
| 1552 | @node Controlling case sensitivity, Searching for/replacing newlines, Highlighting a region, Common requests | 1472 | @node Replacing highlighted text, Controlling case sensitivity, Highlighting a region, Common requests |
| 1473 | @section How can I replace highlighted text with what I type? | ||
| 1474 | @cindex @code{delete-selection-mode} | ||
| 1475 | @cindex Replacing highlighted text | ||
| 1476 | @cindex Highlighting and replacing text | ||
| 1477 | |||
| 1478 | Use @code{delete-selection-mode}, which you can start automatically by | ||
| 1479 | placing the following Lisp form in your @file{.emacs} file: | ||
| 1480 | |||
| 1481 | @lisp | ||
| 1482 | (delete-selection-mode 1) | ||
| 1483 | @end lisp | ||
| 1484 | |||
| 1485 | According to the documentation string for @code{delete-selection-mode} | ||
| 1486 | (which you can read using @kbd{M-x describe-function @key{RET} | ||
| 1487 | delete-selection-mode @key{RET}}): | ||
| 1488 | |||
| 1489 | @quotation | ||
| 1490 | When ON, typed text replaces the selection if the selection is active. | ||
| 1491 | When OFF, typed text is just inserted at point. | ||
| 1492 | @end quotation | ||
| 1493 | |||
| 1494 | This mode also allows you to delete (not kill) the highlighted region by | ||
| 1495 | pressing @key{DEL}. | ||
| 1496 | |||
| 1497 | @node Controlling case sensitivity, Working with unprintable characters, Replacing highlighted text, Common requests | ||
| 1553 | @section How do I control Emacs's case-sensitivity when searching/replacing? | 1498 | @section How do I control Emacs's case-sensitivity when searching/replacing? |
| 1554 | @cindex @code{case-fold-search} | 1499 | @cindex @code{case-fold-search} |
| 1555 | @cindex Case sensitivity of searches | 1500 | @cindex Case sensitivity of searches |
| @@ -1581,7 +1526,55 @@ mode's hook. For example: | |||
| 1581 | (setq case-fold-search nil))) | 1526 | (setq case-fold-search nil))) |
| 1582 | @end lisp | 1527 | @end lisp |
| 1583 | 1528 | ||
| 1584 | @node Searching for/replacing newlines, Yanking text in isearch, Controlling case sensitivity, Common requests | 1529 | @node Working with unprintable characters, Searching for/replacing newlines, Controlling case sensitivity, Common requests |
| 1530 | @section How do I search for, delete, or replace unprintable (eight-bit or control) characters? | ||
| 1531 | @cindex Unprintable characters, working with | ||
| 1532 | @cindex Working with unprintable characters | ||
| 1533 | @cindex Control characters, working with | ||
| 1534 | @cindex Eight-bit characters, working with | ||
| 1535 | @cindex Searching for unprintable characters | ||
| 1536 | @cindex Regexps and unprintable characters | ||
| 1537 | |||
| 1538 | To search for a single character that appears in the buffer as, for | ||
| 1539 | example, @samp{\237}, you can type @kbd{C-s C-q 2 3 7}. (This assumes | ||
| 1540 | the value of @code{search-quote-char} is 17 (i.e., @kbd{C-q}).) | ||
| 1541 | Searching for @strong{all} unprintable characters is best done with a | ||
| 1542 | regular expression (@dfn{regexp}) search. The easiest regexp to use for | ||
| 1543 | the unprintable chars is the complement of the regexp for the printable | ||
| 1544 | chars. | ||
| 1545 | |||
| 1546 | @itemize @bullet | ||
| 1547 | |||
| 1548 | @item | ||
| 1549 | Regexp for the printable chars: @samp{[\t\n\r\f -~]} | ||
| 1550 | |||
| 1551 | @item | ||
| 1552 | Regexp for the unprintable chars: @samp{[^\t\n\r\f -~]} | ||
| 1553 | |||
| 1554 | @end itemize | ||
| 1555 | |||
| 1556 | To type these special characters in an interactive argument to | ||
| 1557 | @code{isearch-forward-regexp} or @code{re-search-forward}, you need to | ||
| 1558 | use @kbd{C-q}. (@samp{\t}, @samp{\n}, @samp{\r}, and @samp{\f} stand | ||
| 1559 | respectively for @key{TAB}, @key{LFD}, @key{RET}, and @kbd{C-l}.) So, | ||
| 1560 | to search for unprintable characters using @code{re-search-forward}: | ||
| 1561 | |||
| 1562 | @kbd{M-x re-search-forward @key{RET} [^ @key{TAB} C-q @key{LFD} C-q @key{RET} C-q C-l @key{SPC} -~] @key{RET}} | ||
| 1563 | |||
| 1564 | Using @code{isearch-forward-regexp}: | ||
| 1565 | |||
| 1566 | @kbd{C-M-s [^ @key{TAB} @key{LFD} C-q @key{RET} C-q C-l @key{SPC} -~]} | ||
| 1567 | |||
| 1568 | To delete all unprintable characters, simply use replace-regexp: | ||
| 1569 | |||
| 1570 | @kbd{M-x replace-regexp @key{RET} [^ @key{TAB} C-q @key{LFD} C-q @key{RET} C-q C-l @key{SPC} -~] @key{RET} @key{RET}} | ||
| 1571 | |||
| 1572 | Replacing is similar to the above. To replace all unprintable | ||
| 1573 | characters with a colon, use: | ||
| 1574 | |||
| 1575 | M-x replace-regexp @key{RET} [^ @key{TAB} C-q @key{LFD} C-q @key{RET} C-q C-l @key{SPC} -~] @key{RET} : @key{RET} | ||
| 1576 | |||
| 1577 | @node Searching for/replacing newlines, Yanking text in isearch, Working with unprintable characters, Common requests | ||
| 1585 | @section How do I input a newline character in isearch or query-replace? | 1578 | @section How do I input a newline character in isearch or query-replace? |
| 1586 | @cindex Searching for newlines | 1579 | @cindex Searching for newlines |
| 1587 | @cindex Replacing newlines | 1580 | @cindex Replacing newlines |
| @@ -1597,7 +1590,7 @@ Special Input for Incremental Search, emacs}. | |||
| 1597 | 1590 | ||
| 1598 | Use @kbd{M-y}. @inforef{Isearch Yank, Isearch Yanking, emacs}. | 1591 | Use @kbd{M-y}. @inforef{Isearch Yank, Isearch Yanking, emacs}. |
| 1599 | 1592 | ||
| 1600 | @node Wrapping words automatically, Spell-checkers, Yanking text in isearch, Common requests | 1593 | @node Wrapping words automatically, Turning on auto-fill by default, Yanking text in isearch, Common requests |
| 1601 | @section How do I make Emacs wrap words for me? | 1594 | @section How do I make Emacs wrap words for me? |
| 1602 | @cindex Wrapping word automatically | 1595 | @cindex Wrapping word automatically |
| 1603 | @cindex Wrapping lines | 1596 | @cindex Wrapping lines |
| @@ -1611,7 +1604,30 @@ The default maximum line width is 70, determined by the variable | |||
| 1611 | @code{fill-column}. To learn how to turn this on automatically, see | 1604 | @code{fill-column}. To learn how to turn this on automatically, see |
| 1612 | @ref{Turning on auto-fill by default}. | 1605 | @ref{Turning on auto-fill by default}. |
| 1613 | 1606 | ||
| 1614 | @node Spell-checkers, Checking TeX and *roff documents, Wrapping words automatically, Common requests | 1607 | @node Turning on auto-fill by default, Spell-checkers, Wrapping words automatically, Common requests |
| 1608 | @section How do I turn on @code{auto-fill-mode} by default? | ||
| 1609 | @cindex @code{auto-fill-mode}, activating automatically | ||
| 1610 | @cindex Filling automatically | ||
| 1611 | @cindex Automatic entry to @code{auto-fill-mode} | ||
| 1612 | |||
| 1613 | To turn on @code{auto-fill-mode} just once for one buffer, use @kbd{M-x | ||
| 1614 | auto-fill-mode}. | ||
| 1615 | |||
| 1616 | To turn it on for every buffer in a certain mode, you must use the hook | ||
| 1617 | for that mode. For example, to turn on @code{auto-fill} mode for all | ||
| 1618 | text buffers, including the following in your @file{.emacs} file: | ||
| 1619 | |||
| 1620 | @lisp | ||
| 1621 | (add-hook 'text-mode-hook 'turn-on-auto-fill) | ||
| 1622 | @end lisp | ||
| 1623 | |||
| 1624 | If you want @code{auto-fill} mode on in all major modes, do this: | ||
| 1625 | |||
| 1626 | @lisp | ||
| 1627 | (setq-default auto-fill-function 'do-auto-fill) | ||
| 1628 | @end lisp | ||
| 1629 | |||
| 1630 | @node Spell-checkers, Checking TeX and *roff documents, Turning on auto-fill by default, Common requests | ||
| 1615 | @section Where can I get a better spelling checker for Emacs? | 1631 | @section Where can I get a better spelling checker for Emacs? |
| 1616 | @cindex Checking spelling | 1632 | @cindex Checking spelling |
| 1617 | @cindex Spelling, checking text documents | 1633 | @cindex Spelling, checking text documents |
| @@ -2055,14 +2071,11 @@ parenthesis, it simply inserts a % like normal. | |||
| 2055 | to investigate @file{cpp.el}, which is distributed with Emacs. | 2071 | to investigate @file{cpp.el}, which is distributed with Emacs. |
| 2056 | 2072 | ||
| 2057 | @node Repeating commands, Valid X resources, Hiding #ifdef lines, Common requests | 2073 | @node Repeating commands, Valid X resources, Hiding #ifdef lines, Common requests |
| 2058 | @section Is there an equivalent to the @code{.} (dot) command of vi? | 2074 | @section How do I repeat a command as many times as possible? |
| 2059 | @cindex Repeating commands as with @code{vi} | 2075 | @cindex Repeating commands many times |
| 2060 | @cindex Command, repeat last | 2076 | @cindex Commands, repeating many times |
| 2061 | @cindex @code{.}, equivalent to @code{vi} command | 2077 | @cindex @code{.}, equivalent to @code{vi} command |
| 2062 | 2078 | ||
| 2063 | (@code{.} is the redo command in @code{vi}. It redoes the last | ||
| 2064 | insertion/deletion.) | ||
| 2065 | |||
| 2066 | As of Emacs 20.3, there is indeed a @code{repeat} command (@kbd{C-x z}) | 2079 | As of Emacs 20.3, there is indeed a @code{repeat} command (@kbd{C-x z}) |
| 2067 | that repeats the last command. If you preface it with a prefix | 2080 | that repeats the last command. If you preface it with a prefix |
| 2068 | argument, the prefix arg is applied to the command. | 2081 | argument, the prefix arg is applied to the command. |
| @@ -2074,12 +2087,14 @@ type @kbd{M-p} and @kbd{M-n} (and also up-arrow and down-arrow, if your | |||
| 2074 | keyboard has these keys) to scan through all the different complex | 2087 | keyboard has these keys) to scan through all the different complex |
| 2075 | commands you've typed. | 2088 | commands you've typed. |
| 2076 | 2089 | ||
| 2077 | To repeat a set of commands, use keyboard macros. (@inforef{Keyboard | 2090 | To repeat a set of commands, use keyboard macros. Use @kbd{C-x (} and |
| 2078 | Macros, Keyboard Macros, emacs}.) | 2091 | @kbd{C-x )} to make a keyboard macro that invokes the command and then |
| 2092 | type @kbd{C-x e}. (@inforef{Keyboard Macros, Keyboard Macros, emacs}.) | ||
| 2079 | 2093 | ||
| 2080 | If you're really desperate for the @code{.} command, use VIPER, a | 2094 | If you're really desperate for the @code{.} command in @code{vi} that |
| 2081 | @code{vi} emulation mode which comes with Emacs, and which appears to | 2095 | redoes the last insertion/deletion, use VIPER, a @code{vi} emulation |
| 2082 | support it. (@xref{VIPER}.) | 2096 | mode which comes with Emacs, and which appears to support it. |
| 2097 | (@xref{VIPER}.) | ||
| 2083 | 2098 | ||
| 2084 | @node Valid X resources, Evaluating Emacs Lisp code, Repeating commands, Common requests | 2099 | @node Valid X resources, Evaluating Emacs Lisp code, Repeating commands, Common requests |
| 2085 | @section What are the valid X resource settings (i.e., stuff in .Xdefaults)? | 2100 | @section What are the valid X resource settings (i.e., stuff in .Xdefaults)? |
| @@ -2180,27 +2195,14 @@ buffers, you can even use @kbd{M-;} to cite yanked messages (@kbd{M-;} | |||
| 2180 | runs the function @code{comment-region}, it is a general-purpose | 2195 | runs the function @code{comment-region}, it is a general-purpose |
| 2181 | mechanism to comment regions) (@pxref{Changing the included text prefix}). | 2196 | mechanism to comment regions) (@pxref{Changing the included text prefix}). |
| 2182 | 2197 | ||
| 2183 | @node Underlining paragraphs, Repeating a command as many times as possible, Inserting text at the beginning of each line, Common requests | 2198 | @node Underlining paragraphs, Forcing the cursor to remain in the same column, Inserting text at the beginning of each line, Common requests |
| 2184 | @section How do I insert @samp{_^H} before each character in a region to get an underlined paragraph? | 2199 | @section How do I insert @samp{_^H} before each character in a region to get an underlined paragraph? |
| 2185 | @cindex Underlining a region of text | 2200 | @cindex Underlining a region of text |
| 2186 | @cindex @code{underline-region} | 2201 | @cindex @code{underline-region} |
| 2187 | 2202 | ||
| 2188 | Mark the region and then type @kbd{M-x underline-region @key{RET}}. | 2203 | Mark the region and then type @kbd{M-x underline-region @key{RET}}. |
| 2189 | 2204 | ||
| 2190 | @node Repeating a command as many times as possible, Forcing the cursor to remain in the same column, Underlining paragraphs, Common requests | 2205 | @node Forcing the cursor to remain in the same column, Forcing Emacs to iconify itself, Underlining paragraphs, Common requests |
| 2191 | @section How do I repeat a command as many times as possible? | ||
| 2192 | @cindex Repeating commands many times | ||
| 2193 | @cindex Commands, repeating many times | ||
| 2194 | |||
| 2195 | Use @kbd{C-x (} and @kbd{C-x )} to make a keyboard macro that invokes | ||
| 2196 | the command and then type @kbd{M-0 C-x e}. | ||
| 2197 | |||
| 2198 | Any messages your command prints in the echo area will be suppressed. | ||
| 2199 | |||
| 2200 | If you need to repeat a command a small number of times, you can use | ||
| 2201 | @kbd{C-x z} (@pxref{Repeating commands}) or @kbd{C-x e}. | ||
| 2202 | |||
| 2203 | @node Forcing the cursor to remain in the same column, Forcing Emacs to iconify itself, Repeating a command as many times as possible, Common requests | ||
| 2204 | @section How do I make Emacs behave like this: when I go up or down, the cursor should stay in the same column even if the line is too short? | 2206 | @section How do I make Emacs behave like this: when I go up or down, the cursor should stay in the same column even if the line is too short? |
| 2205 | @cindex @code{picture-mode} | 2207 | @cindex @code{picture-mode} |
| 2206 | @cindex Remaining in the same column, regardless of contents | 2208 | @cindex Remaining in the same column, regardless of contents |
| @@ -2561,7 +2563,7 @@ PostScript printer, or a PostScript interpreter such as Ghostscript; | |||
| 2561 | consult the documentation of the variables @code{ps-printer-name}, | 2563 | consult the documentation of the variables @code{ps-printer-name}, |
| 2562 | @code{ps-lpr-command}, and @code{ps-lpr-switches} for more details. | 2564 | @code{ps-lpr-command}, and @code{ps-lpr-switches} for more details. |
| 2563 | 2565 | ||
| 2564 | @node Scrolling only one line, Replacing highlighted text, Turning on syntax highlighting, Common requests | 2566 | @node Scrolling only one line, Editing MS-DOS files, Turning on syntax highlighting, Common requests |
| 2565 | @section How can I force Emacs to scroll only one line when I move past the bottom of the screen? | 2567 | @section How can I force Emacs to scroll only one line when I move past the bottom of the screen? |
| 2566 | @cindex Scrolling only one line | 2568 | @cindex Scrolling only one line |
| 2567 | @cindex Reducing the increment when scrolling | 2569 | @cindex Reducing the increment when scrolling |
| @@ -2577,32 +2579,7 @@ Alternatively, use the following Lisp form in your @file{.emacs}: | |||
| 2577 | (setq scroll-conservatively most-positive-fixnum) | 2579 | (setq scroll-conservatively most-positive-fixnum) |
| 2578 | @end lisp | 2580 | @end lisp |
| 2579 | 2581 | ||
| 2580 | @node Replacing highlighted text, Editing MS-DOS files, Scrolling only one line, Common requests | 2582 | @node Editing MS-DOS files, Filling paragraphs with a single space, Scrolling only one line, Common requests |
| 2581 | @section How can I replace highlighted text with what I type? | ||
| 2582 | @cindex @code{delete-selection-mode} | ||
| 2583 | @cindex Replacing highlighted text | ||
| 2584 | @cindex Highlighting and replacing text | ||
| 2585 | |||
| 2586 | Use @code{delete-selection-mode}, which you can start automatically by | ||
| 2587 | placing the following Lisp form in your @file{.emacs} file: | ||
| 2588 | |||
| 2589 | @lisp | ||
| 2590 | (delete-selection-mode 1) | ||
| 2591 | @end lisp | ||
| 2592 | |||
| 2593 | According to the documentation string for @code{delete-selection-mode} | ||
| 2594 | (which you can read using @kbd{M-x describe-function @key{RET} | ||
| 2595 | delete-selection-mode @key{RET}}): | ||
| 2596 | |||
| 2597 | @quotation | ||
| 2598 | When ON, typed text replaces the selection if the selection is active. | ||
| 2599 | When OFF, typed text is just inserted at point. | ||
| 2600 | @end quotation | ||
| 2601 | |||
| 2602 | This mode also allows you to delete (not kill) the highlighted region by | ||
| 2603 | pressing @key{DEL}. | ||
| 2604 | |||
| 2605 | @node Editing MS-DOS files, Filling paragraphs with a single space, Replacing highlighted text, Common requests | ||
| 2606 | @section How can I edit MS-DOS files using Emacs? | 2583 | @section How can I edit MS-DOS files using Emacs? |
| 2607 | @cindex Editing MS-DOS files | 2584 | @cindex Editing MS-DOS files |
| 2608 | @cindex MS-DOS files, editing | 2585 | @cindex MS-DOS files, editing |
| @@ -3502,7 +3479,8 @@ the @file{ell} package}. | |||
| 3502 | 3479 | ||
| 3503 | Many authors post their packages to the @uref{news:gnu.emacs.sources, | 3480 | Many authors post their packages to the @uref{news:gnu.emacs.sources, |
| 3504 | Emacs sources newsgroup}. You can search the archives of this | 3481 | Emacs sources newsgroup}. You can search the archives of this |
| 3505 | group with @uref{http://groups.google.com, Google}, for example. | 3482 | group with @uref{http://groups.google.com/group/gnu.emacs.sources, Google}, |
| 3483 | or @uref{http://dir.gmane.org/gmane.emacs.sources, Gmane}, for example. | ||
| 3506 | 3484 | ||
| 3507 | Several packages are stored in | 3485 | Several packages are stored in |
| 3508 | @uref{http://emacswiki.org/elisp/, the Lisp area of the Emacs Wiki}. | 3486 | @uref{http://emacswiki.org/elisp/, the Lisp area of the Emacs Wiki}. |
| @@ -3513,6 +3491,9 @@ although you can still access the old files at | |||
| 3513 | 3491 | ||
| 3514 | @uref{ftp://ftp.cis.ohio-state.edu/pub/emacs-lisp/WWW/index.html} | 3492 | @uref{ftp://ftp.cis.ohio-state.edu/pub/emacs-lisp/WWW/index.html} |
| 3515 | 3493 | ||
| 3494 | Read the file @file{etc/MORE.STUFF} for more information about | ||
| 3495 | external packages. | ||
| 3496 | |||
| 3516 | @node Current GNU distributions, Difference between Emacs and XEmacs, Packages that do not come with Emacs, Finding Emacs and related packages | 3497 | @node Current GNU distributions, Difference between Emacs and XEmacs, Packages that do not come with Emacs, Finding Emacs and related packages |
| 3517 | @section Where can I get other up-to-date GNU stuff? | 3498 | @section Where can I get other up-to-date GNU stuff? |
| 3518 | @cindex Current GNU distributions | 3499 | @cindex Current GNU distributions |