Mercurial > emacs
comparison man/faq.texi @ 69133:1c9e76acce59
(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.
author | Juri Linkov <juri@jurta.org> |
---|---|
date | Thu, 23 Feb 2006 23:14:58 +0000 |
parents | 23ad987a0092 |
children | 11b616eddda4 34c8b755296d |
comparison
equal
deleted
inserted
replaced
69132:e4886b403acb | 69133:1c9e76acce59 |
---|---|
1183 * Colors on a TTY:: | 1183 * Colors on a TTY:: |
1184 * Debugging a customization file:: | 1184 * Debugging a customization file:: |
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:: |
1189 * Highlighting a region:: | |
1190 * Replacing highlighted text:: | |
1191 * Controlling case sensitivity:: | |
1190 * Working with unprintable characters:: | 1192 * Working with unprintable characters:: |
1191 * Highlighting a region:: | |
1192 * Controlling case sensitivity:: | |
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:: |
1199 * Using an already running Emacs process:: | 1200 * Using an already running Emacs process:: |
1200 * Compiler error messages:: | 1201 * Compiler error messages:: |
1211 * Valid X resources:: | 1212 * Valid X resources:: |
1212 * Evaluating Emacs Lisp code:: | 1213 * Evaluating Emacs Lisp code:: |
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:: |
1220 * Replacing text across multiple files:: | 1220 * Replacing text across multiple files:: |
1221 * Documentation for etags:: | 1221 * Documentation for etags:: |
1224 * Going to a line by number:: | 1224 * Going to a line by number:: |
1225 * Modifying pull-down menus:: | 1225 * Modifying pull-down menus:: |
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:: |
1233 @end menu | 1232 @end menu |
1234 | 1233 |
1402 | 1401 |
1403 @lisp | 1402 @lisp |
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 |
1411 Put this in your @file{.emacs} file: | 1410 Put this in your @file{.emacs} file: |
1412 | 1411 |
1421 @end lisp | 1420 @end lisp |
1422 | 1421 |
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 |
1453 @cindex @code{auto-mode-alist}, modifying | 1429 @cindex @code{auto-mode-alist}, modifying |
1454 @cindex Modes, associating with file extensions | 1430 @cindex Modes, associating with file extensions |
1474 determines which interpreter you're using by examining the first line of | 1450 determines which interpreter you're using by examining the first line of |
1475 the script.) This feature only applies when the file name doesn't | 1451 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 |
1456 @section How can I highlight a region of text in Emacs? | |
1457 @cindex Highlighting text | |
1458 @cindex Text, highlighting | |
1459 @cindex @code{transient-mark-mode} | |
1460 @cindex Region, highlighting a | |
1461 | |
1462 You can cause the region to be highlighted when the mark is active by | |
1463 including | |
1464 | |
1465 @lisp | |
1466 (transient-mark-mode t) | |
1467 @end lisp | |
1468 | |
1469 @noindent | |
1470 in your @file{.emacs} file. | |
1471 | |
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 | |
1498 @section How do I control Emacs's case-sensitivity when searching/replacing? | |
1499 @cindex @code{case-fold-search} | |
1500 @cindex Case sensitivity of searches | |
1501 @cindex Searching without case sensitivity | |
1502 @cindex Ignoring case in searches | |
1503 | |
1504 For searching, the value of the variable @code{case-fold-search} | |
1505 determines whether they are case sensitive: | |
1506 | |
1507 @lisp | |
1508 (setq case-fold-search nil) ; make searches case sensitive | |
1509 (setq case-fold-search t) ; make searches case insensitive | |
1510 @end lisp | |
1511 | |
1512 @cindex Case sensitivity in replacements | |
1513 @cindex Replacing, and case sensitivity | |
1514 @cindex @code{case-replace} | |
1515 Similarly, for replacing, the variable @code{case-replace} determines | |
1516 whether replacements preserve case. | |
1517 | |
1518 You can also toggle case sensitivity at will in isearch with @kbd{M-c}. | |
1519 | |
1520 To change the case sensitivity just for one major mode, use the major | |
1521 mode's hook. For example: | |
1522 | |
1523 @lisp | |
1524 (add-hook '@var{foo}-mode-hook | |
1525 (lambda () | |
1526 (setq case-fold-search nil))) | |
1527 @end lisp | |
1528 | |
1529 @node Working with unprintable characters, Searching for/replacing newlines, Controlling case sensitivity, Common requests | |
1480 @section How do I search for, delete, or replace unprintable (eight-bit or control) characters? | 1530 @section How do I search for, delete, or replace unprintable (eight-bit or control) characters? |
1481 @cindex Unprintable characters, working with | 1531 @cindex Unprintable characters, working with |
1482 @cindex Working with unprintable characters | 1532 @cindex Working with unprintable characters |
1483 @cindex Control characters, working with | 1533 @cindex Control characters, working with |
1484 @cindex Eight-bit characters, working with | 1534 @cindex Eight-bit characters, working with |
1522 Replacing is similar to the above. To replace all unprintable | 1572 Replacing is similar to the above. To replace all unprintable |
1523 characters with a colon, use: | 1573 characters with a colon, use: |
1524 | 1574 |
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} | 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} |
1526 | 1576 |
1527 @itemize @bullet | 1577 @node Searching for/replacing newlines, Yanking text in isearch, Working with unprintable characters, Common requests |
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? | |
1537 @cindex Highlighting text | |
1538 @cindex Text, highlighting | |
1539 @cindex @code{transient-mark-mode} | |
1540 @cindex Region, highlighting a | |
1541 | |
1542 You can cause the region to be highlighted when the mark is active by | |
1543 including | |
1544 | |
1545 @lisp | |
1546 (transient-mark-mode t) | |
1547 @end lisp | |
1548 | |
1549 @noindent | |
1550 in your @file{.emacs} file. | |
1551 | |
1552 @node Controlling case sensitivity, Searching for/replacing newlines, Highlighting a region, Common requests | |
1553 @section How do I control Emacs's case-sensitivity when searching/replacing? | |
1554 @cindex @code{case-fold-search} | |
1555 @cindex Case sensitivity of searches | |
1556 @cindex Searching without case sensitivity | |
1557 @cindex Ignoring case in searches | |
1558 | |
1559 For searching, the value of the variable @code{case-fold-search} | |
1560 determines whether they are case sensitive: | |
1561 | |
1562 @lisp | |
1563 (setq case-fold-search nil) ; make searches case sensitive | |
1564 (setq case-fold-search t) ; make searches case insensitive | |
1565 @end lisp | |
1566 | |
1567 @cindex Case sensitivity in replacements | |
1568 @cindex Replacing, and case sensitivity | |
1569 @cindex @code{case-replace} | |
1570 Similarly, for replacing, the variable @code{case-replace} determines | |
1571 whether replacements preserve case. | |
1572 | |
1573 You can also toggle case sensitivity at will in isearch with @kbd{M-c}. | |
1574 | |
1575 To change the case sensitivity just for one major mode, use the major | |
1576 mode's hook. For example: | |
1577 | |
1578 @lisp | |
1579 (add-hook '@var{foo}-mode-hook | |
1580 (lambda () | |
1581 (setq case-fold-search nil))) | |
1582 @end lisp | |
1583 | |
1584 @node Searching for/replacing newlines, Yanking text in isearch, Controlling case sensitivity, 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 |
1588 | 1581 |
1589 Use @kbd{C-q C-j}. For more information, see @inforef{Special Isearch, | 1582 Use @kbd{C-q C-j}. For more information, see @inforef{Special Isearch, |
1595 @cindex Yanking text into the search string | 1588 @cindex Yanking text into the search string |
1596 @cindex isearch yanking | 1589 @cindex isearch yanking |
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 |
1604 @cindex Line wrap | 1597 @cindex Line wrap |
1605 @cindex @code{auto-fill-mode}, introduction to | 1598 @cindex @code{auto-fill-mode}, introduction to |
1609 Use @code{auto-fill-mode}, activated by typing @kbd{M-x auto-fill-mode}. | 1602 Use @code{auto-fill-mode}, activated by typing @kbd{M-x auto-fill-mode}. |
1610 The default maximum line width is 70, determined by the variable | 1603 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 |
1618 | 1634 |
1619 Use Ispell. @xref{Ispell}. | 1635 Use Ispell. @xref{Ispell}. |
2053 | 2069 |
2054 @kbd{M-x hide-ifdef-mode}. (This is a minor mode.) You might also want | 2070 @kbd{M-x hide-ifdef-mode}. (This is a minor mode.) You might also want |
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 | |
2063 (@code{.} is the redo command in @code{vi}. It redoes the last | |
2064 insertion/deletion.) | |
2065 | 2078 |
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. |
2069 | 2082 |
2072 minibuffer to get arguments. In @code{repeat-complex-command} you can | 2085 minibuffer to get arguments. In @code{repeat-complex-command} you can |
2073 type @kbd{M-p} and @kbd{M-n} (and also up-arrow and down-arrow, if your | 2086 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 |
2079 | 2092 type @kbd{C-x e}. (@inforef{Keyboard Macros, Keyboard Macros, emacs}.) |
2080 If you're really desperate for the @code{.} command, use VIPER, a | 2093 |
2081 @code{vi} emulation mode which comes with Emacs, and which appears to | 2094 If you're really desperate for the @code{.} command in @code{vi} that |
2082 support it. (@xref{VIPER}.) | 2095 redoes the last insertion/deletion, use VIPER, a @code{vi} emulation |
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)? |
2086 @cindex Resources, X | 2101 @cindex Resources, X |
2087 @cindex X resources | 2102 @cindex X resources |
2178 might want to set the variable @code{mail-yank-prefix}. In Message | 2193 might want to set the variable @code{mail-yank-prefix}. In Message |
2179 buffers, you can even use @kbd{M-;} to cite yanked messages (@kbd{M-;} | 2194 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 |
2207 @cindex Vertical movement in empty documents | 2209 @cindex Vertical movement in empty documents |
2208 | 2210 |
2559 ps-print-region-with-faces}. You will need a way to send text to a | 2561 ps-print-region-with-faces}. You will need a way to send text to a |
2560 PostScript printer, or a PostScript interpreter such as Ghostscript; | 2562 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 |
2568 | 2570 |
2569 Customize the @code{scroll-conservatively} variable with @kbd{M-x | 2571 Customize the @code{scroll-conservatively} variable with @kbd{M-x |
2575 | 2577 |
2576 @lisp | 2578 @lisp |
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 |
2609 @cindex Microsoft files, editing | 2586 @cindex Microsoft files, editing |
2610 @cindex Windows files, editing | 2587 @cindex Windows files, editing |
3500 from Emacs with @uref{http://www.anc.ed.ac.uk/~stephen/emacs/ell.el, | 3477 from Emacs with @uref{http://www.anc.ed.ac.uk/~stephen/emacs/ell.el, |
3501 the @file{ell} package}. | 3478 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}. |
3509 | 3487 |
3510 For a long time, the Emacs Lisp Archive provided a central repository | 3488 For a long time, the Emacs Lisp Archive provided a central repository |
3511 for Emacs packages. Sadly, it has not been active for some time, | 3489 for Emacs packages. Sadly, it has not been active for some time, |
3512 although you can still access the old files at | 3490 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} |
3493 | |
3494 Read the file @file{etc/MORE.STUFF} for more information about | |
3495 external packages. | |
3515 | 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 |
3519 @cindex Sources for current GNU distributions | 3500 @cindex Sources for current GNU distributions |