diff options
| author | Joakim Verona | 2011-11-09 14:05:54 +0100 |
|---|---|---|
| committer | Joakim Verona | 2011-11-09 14:05:54 +0100 |
| commit | c8d4b74cfa26762d34fd1703a07463008b32be16 (patch) | |
| tree | 6610ac356d47e328bb1094d9f5a0dcc15ed5fb6a /doc | |
| parent | 32db4845d5c433fd15c6665cbed169e5d8b94f05 (diff) | |
| parent | 2cffd68198c4d574f073ab238dc12b1221005eab (diff) | |
| download | emacs-c8d4b74cfa26762d34fd1703a07463008b32be16.tar.gz emacs-c8d4b74cfa26762d34fd1703a07463008b32be16.zip | |
upstream
Diffstat (limited to 'doc')
| -rw-r--r-- | doc/lispref/ChangeLog | 24 | ||||
| -rw-r--r-- | doc/lispref/windows.texi | 944 | ||||
| -rw-r--r-- | doc/misc/auth.texi | 18 | ||||
| -rw-r--r-- | doc/misc/gnus.texi | 30 |
4 files changed, 326 insertions, 690 deletions
diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog index d714d1b26e5..cbe016ac96d 100644 --- a/doc/lispref/ChangeLog +++ b/doc/lispref/ChangeLog | |||
| @@ -1,3 +1,27 @@ | |||
| 1 | 2011-11-09 Martin Rudalics <rudalics@gmx.at> | ||
| 2 | |||
| 3 | * windows.texi (Resizing Windows): Rewrite documentation of | ||
| 4 | window-resizable. | ||
| 5 | |||
| 6 | 2011-11-09 Chong Yidong <cyd@gnu.org> | ||
| 7 | |||
| 8 | * windows.texi (Splitting Windows): Simplify example. | ||
| 9 | |||
| 10 | 2011-11-08 Chong Yidong <cyd@gnu.org> | ||
| 11 | |||
| 12 | * windows.texi (Window Sizes): Copyedits. Document | ||
| 13 | window-text-height. Remove window-min-height and window-min-width | ||
| 14 | discussion, referring instead to Emacs manual. | ||
| 15 | (Splitting Windows, Resizing Windows): Add xref to Emacs manual. | ||
| 16 | (Resizing Windows): Simplify introduction. Don't document | ||
| 17 | enlarge-window, shrink-window, enlarge-window-horizontally, and | ||
| 18 | shrink-window-horizontally; they are no longer preferred for | ||
| 19 | calling from Lisp, and are already documented in the Emacs manual. | ||
| 20 | |||
| 21 | 2011-11-07 Glenn Morris <rgm@gnu.org> | ||
| 22 | |||
| 23 | * windows.texi (Choosing Window): Fix keybinding typo. | ||
| 24 | |||
| 1 | 2011-11-07 Martin Rudalics <rudalics@gmx.at> | 25 | 2011-11-07 Martin Rudalics <rudalics@gmx.at> |
| 2 | 26 | ||
| 3 | * windows.texi (Resizing Windows, Splitting Windows) | 27 | * windows.texi (Resizing Windows, Splitting Windows) |
diff --git a/doc/lispref/windows.texi b/doc/lispref/windows.texi index eb3c1849523..52ac5a53900 100644 --- a/doc/lispref/windows.texi +++ b/doc/lispref/windows.texi | |||
| @@ -274,7 +274,7 @@ the leftmost child window for a horizontal combination. If | |||
| 274 | @defun window-combined-p &optional window horizontal | 274 | @defun window-combined-p &optional window horizontal |
| 275 | This function returns a non-@code{nil} value if and only if | 275 | This function returns a non-@code{nil} value if and only if |
| 276 | @var{window} is part of a vertical combination. If @var{window} is | 276 | @var{window} is part of a vertical combination. If @var{window} is |
| 277 | omitted or nil, it defaults to the selected one. | 277 | omitted or @code{nil}, it defaults to the selected one. |
| 278 | 278 | ||
| 279 | If the optional argument @var{horizontal} is non-@code{nil}, this | 279 | If the optional argument @var{horizontal} is non-@code{nil}, this |
| 280 | means to return non-@code{nil} if and only if @var{window} is part of | 280 | means to return non-@code{nil} if and only if @var{window} is part of |
| @@ -340,13 +340,12 @@ internal window). The @var{edges} element is a list @code{(@var{left} | |||
| 340 | @cindex window size | 340 | @cindex window size |
| 341 | @cindex size of window | 341 | @cindex size of window |
| 342 | 342 | ||
| 343 | Emacs windows are rectangular. The structure of a live window can be | 343 | The following schematic shows the structure of a live window: |
| 344 | roughly sketched as follows: | ||
| 345 | 344 | ||
| 346 | @smallexample | 345 | @smallexample |
| 347 | @group | 346 | @group |
| 348 | _________________________________________ | 347 | _________________________________________ |
| 349 | ^ |______________ Header Line_______________| | 348 | ^ |______________ Header Line_______________| |
| 350 | | |LS|LF|LM| |RM|RF|RS| ^ | 349 | | |LS|LF|LM| |RM|RF|RS| ^ |
| 351 | | | | | | | | | | | | 350 | | | | | | | | | | | |
| 352 | Window | | | | Text Area | | | | Window | 351 | Window | | | | Text Area | | | | Window |
| @@ -362,295 +361,177 @@ roughly sketched as follows: | |||
| 362 | @end smallexample | 361 | @end smallexample |
| 363 | 362 | ||
| 364 | @cindex window body | 363 | @cindex window body |
| 364 | @cindex text area of a window | ||
| 365 | @cindex body of a window | 365 | @cindex body of a window |
| 366 | The text area constitutes the body of the window. In its most simple | 366 | At the center of the window is the @dfn{text area}, or @dfn{body}, |
| 367 | form, a window consists of its body alone. LS and RS stand for the left | 367 | where the buffer text is displayed. On each side of the text area is |
| 368 | and right scroll bar (@pxref{Scroll Bars}) respectively. Only one of | 368 | a series of vertical areas; from innermost to outermost, these are the |
| 369 | them can be present at any time. LF and RF denote the left and right | 369 | left and right margins, denoted by LM and RM in the schematic |
| 370 | fringe, see @ref{Fringes}. LM and RM, finally, stand for the left and | 370 | (@pxref{Display Margins}); the left and right fringes, denoted by LF |
| 371 | right display margin, see @ref{Display Margins}. The header line, if | 371 | and RF (@pxref{Fringes}); and the left or right scroll bar, only one of |
| 372 | present, is located above theses areas, the mode line below, see | 372 | which is present at any time, denoted by LS and RS (@pxref{Scroll |
| 373 | @ref{Mode Line Format}. | 373 | Bars}). At the top of the window is an optional header line |
| 374 | (@pxref{Header Lines}), and at the bottom of the window is the mode | ||
| 375 | line (@pxref{Mode Line Format}). | ||
| 376 | |||
| 377 | Emacs provides several functions for finding the height and width of | ||
| 378 | a window. Most of these functions report the values as integer | ||
| 379 | multiples of the default character height and width. On a graphical | ||
| 380 | display, the actual screen size of this default height and width are | ||
| 381 | those specified by the frame's default font. Hence, if the buffer | ||
| 382 | contains text that is displayed in a different size, the reported | ||
| 383 | height and width of the window may differ from the actual number of | ||
| 384 | text lines or columns displayed in it. | ||
| 374 | 385 | ||
| 375 | @cindex window height | 386 | @cindex window height |
| 376 | @cindex total window height | ||
| 377 | @cindex height of a window | 387 | @cindex height of a window |
| 378 | @cindex total height of a window | 388 | @cindex total height of a window |
| 379 | The @dfn{total height of a window} is specified as the total number of | ||
| 380 | lines occupied by the window. Any mode or header line is included in a | ||
| 381 | window's total height. For an internal window, the total height is | ||
| 382 | calculated recursively from the total heights of its child windows. | ||
| 383 | |||
| 384 | @cindex window width | 389 | @cindex window width |
| 385 | @cindex total window width | ||
| 386 | @cindex width of a window | 390 | @cindex width of a window |
| 387 | @cindex total width of a window | 391 | @cindex total width of a window |
| 388 | The @dfn{total width of a window} denotes the total number of columns of | 392 | The @dfn{total height} of a window is the distance between the top |
| 389 | the window. Any scroll bar and the column of @samp{|} characters that | 393 | and bottom of the window, including the header line (if one exists) |
| 390 | separate the window from its right sibling are included in a window's | 394 | and the mode line. The @dfn{total width} of a window is the distance |
| 391 | total width. On a window-system, fringes and display margins are | 395 | between the left and right edges of the mode line. Note that the |
| 392 | included in a window's total width too. For an internal window, the | 396 | height of a frame is not the same as the height of its windows, since |
| 393 | total width is calculated recursively from the total widths of its child | 397 | a frame may also contain an echo area, menu bar, and tool bar |
| 394 | windows. | 398 | (@pxref{Size and Position}). |
| 395 | |||
| 396 | @cindex total size of a window | ||
| 397 | @cindex total window size | ||
| 398 | The following function is the standard interface for getting the total | ||
| 399 | size of any window: | ||
| 400 | |||
| 401 | @defun window-total-size &optional window &optional horizontal | ||
| 402 | This function returns the total number of lines of @var{window}. The | ||
| 403 | argument @var{window} can denote any window and defaults to the selected | ||
| 404 | one. If @var{window} is live, the return value includes any header or | ||
| 405 | mode lines of @var{window}. If @var{window} is internal, the return | ||
| 406 | value is the sum of the total heights of @var{window}'s child windows | ||
| 407 | provided these are vertically combined and the height of @var{window}'s | ||
| 408 | first child if they are horizontally combined. | ||
| 409 | |||
| 410 | If the optional argument @var{horizontal} is non-@code{nil}, this | ||
| 411 | function returns the total number of columns of @var{window}. If | ||
| 412 | @var{window} is live, the return value includes any vertical divider | ||
| 413 | column or scroll bars of @var{window}. On a window-system, the return | ||
| 414 | value includes the space occupied by any margins and fringes of | ||
| 415 | @var{window} too. If @var{window} is internal, the return value is the | ||
| 416 | sum of the total widths of @var{window}'s child windows provided these | ||
| 417 | are horizontally combined and the width of @var{window}'s first child | ||
| 418 | otherwise. | ||
| 419 | @end defun | ||
| 420 | |||
| 421 | Alternatively, the following two functions can be used to retrieve | ||
| 422 | either the total height or the total width of a window: | ||
| 423 | 399 | ||
| 424 | @defun window-total-height &optional window | 400 | @defun window-total-height &optional window |
| 425 | This function returns the total number of lines of @var{window}. | 401 | This function returns the total height, in lines, of the window |
| 426 | @var{window} can be any window and defaults to the selected one. The | 402 | @var{window}. If @var{window} is omitted or @code{nil}, it defaults |
| 427 | return value includes @var{window}'s mode line and header line, if any. | 403 | to the selected window. If @var{window} is an internal window, the |
| 428 | If @var{window} is internal the return value is the sum of heights of | 404 | return value is the total height occupied by its descendant windows. |
| 429 | @var{window}'s child windows for a vertical combination and the height | ||
| 430 | of @var{window}'s first child otherwise. | ||
| 431 | @end defun | 405 | @end defun |
| 432 | 406 | ||
| 433 | @defun window-total-width &optional window | 407 | @defun window-total-width &optional window |
| 434 | This function returns the total number of columns of @var{window}. | 408 | This function returns the total width, in columns, of the window |
| 435 | @var{window} can be any window and defaults to the selected one. The | 409 | @var{window}. If @var{window} is omitted or @code{nil}, it defaults |
| 436 | return value includes any vertical dividers or scrollbars of | 410 | to the selected window. If @var{window} is internal, the return value |
| 437 | @var{window}. On a window-system the return value also includes the | 411 | is the total width occupied by its descendant windows. |
| 438 | space occupied by any margins and fringes of @var{window}. If | 412 | @end defun |
| 439 | @var{window} is internal, the return value is the sum of the widths of | ||
| 440 | @var{window}'s child windows for a horizontal combination and the width | ||
| 441 | of @var{window}'s first child otherwise. | ||
| 442 | @end defun | ||
| 443 | |||
| 444 | The total height of any window is usually less than the height of the | ||
| 445 | window's frame, because the latter may also include the minibuffer | ||
| 446 | window. Depending on the toolkit in use, the frame height can also | ||
| 447 | include the menu bar and the tool bar (@pxref{Size and Position}). | ||
| 448 | Therefore, in general it is not straightforward to compare window and | ||
| 449 | frame heights. The following function is useful to determine whether | ||
| 450 | there are no other windows above or below a specified window. | ||
| 451 | 413 | ||
| 452 | @cindex full-height window | 414 | @defun window-total-size &optional window horizontal |
| 453 | @defun window-full-height-p &optional window | 415 | This function returns either the total height or width of the window |
| 454 | This function returns non-@code{nil} if there is no other window above | 416 | @var{window}. If @var{horizontal} is omitted or @code{nil}, this is |
| 455 | or below @var{window} on the containing frame. More precisely, this | 417 | equivalent to calling @code{window-total-height} for @var{window}; |
| 456 | function returns @code{t} if and only if the total height of | 418 | otherwise it is equivalent to calling @code{window-total-width} for |
| 457 | @var{window} equals the total height of the root window (@pxref{Windows | 419 | @var{window}. |
| 458 | and Frames}) of @var{window}'s frame. The @var{window} argument may | ||
| 459 | denote any window and defaults to the selected one. | ||
| 460 | @end defun | 420 | @end defun |
| 461 | 421 | ||
| 462 | @cindex full-width window | 422 | @cindex full-width window |
| 463 | The following function can be used to determine whether there are no | 423 | @cindex full-height window |
| 464 | other windows on the left or right of a specified window. | 424 | The following functions can be used to determine whether a given |
| 425 | window has any adjacent windows. | ||
| 426 | |||
| 427 | @defun window-full-height-p &optional window | ||
| 428 | This function returns non-@code{nil} if @var{window} has no other | ||
| 429 | window above or below it in its frame, i.e. its total height equals | ||
| 430 | the total height of the root window on that frame. If @var{window} is | ||
| 431 | omitted or @code{nil}, it defaults to the selected window. | ||
| 432 | @end defun | ||
| 465 | 433 | ||
| 466 | @defun window-full-width-p &optional window | 434 | @defun window-full-width-p &optional window |
| 467 | This function returns non-@code{nil} if there are no other windows on | 435 | This function returns non-@code{nil} if @var{window} has no other |
| 468 | the left or right of @var{window}; @code{nil} otherwise. More | 436 | window to the left or right in its frame, i.e. its total width equals |
| 469 | precisely, this function returns @code{t} if and only if the total width | 437 | that of the root window on that frame. If @var{window} is omitted or |
| 470 | of @var{window} equals the total width of the root window | 438 | @code{nil}, it defaults to the selected window. |
| 471 | (@pxref{Windows and Frames}) of @var{window}'s frame. The @var{window} | ||
| 472 | argument may denote any window and defaults to the selected one. | ||
| 473 | @end defun | 439 | @end defun |
| 474 | 440 | ||
| 475 | @cindex top line of window | 441 | @cindex window position |
| 476 | @cindex left column of window | 442 | The following functions can be used to determine the position of a |
| 477 | The windows of a frame are unambiguously characterized by the | 443 | window relative to the window area of its frame: |
| 478 | combination of their top line and left column within that frame. | ||
| 479 | 444 | ||
| 480 | @defun window-top-line &optional window | 445 | @defun window-top-line &optional window |
| 481 | This function returns the top line of @var{window}. The argument | 446 | This function returns the distance, in lines, between the top of |
| 482 | @var{window} can denote any window and defaults to the selected one. | 447 | @var{window} and the top of the frame's window area. For instance, |
| 448 | the return value is 0 if there is no window above @var{window}. If | ||
| 449 | @var{window} is omitted or @code{nil}, it defaults to the selected | ||
| 450 | window. | ||
| 483 | @end defun | 451 | @end defun |
| 484 | 452 | ||
| 485 | @defun window-left-column &optional window | 453 | @defun window-left-column &optional window |
| 486 | This function returns the left column of @var{window}. The argument | 454 | This function returns the distance, in columns, between the left edge |
| 487 | @var{window} can denote any window and defaults to the selected one. | 455 | of @var{window} and the left edge of the frame's window area. For |
| 456 | instance, the return value is 0 if there is no window to the left of | ||
| 457 | @var{window}. If @var{window} is omitted or @code{nil}, it defaults | ||
| 458 | to the selected window. | ||
| 488 | @end defun | 459 | @end defun |
| 489 | 460 | ||
| 490 | For a frame displaying one window only, that window's top line and left | ||
| 491 | column are both zero. When a frame displays a window @var{WB} below a | ||
| 492 | window @var{WA}, the top line of @var{WB} can be calculated by adding | ||
| 493 | the total height of @var{WA} to the top line of @var{WA}. When a frame | ||
| 494 | displays a window @var{WR} on the right of a window @var{WL}, the left | ||
| 495 | column of @var{WR} can be calculated by adding the total width of | ||
| 496 | @var{WL} to the left column of @var{WL}. | ||
| 497 | |||
| 498 | @cindex window body height | 461 | @cindex window body height |
| 499 | @cindex body height of a window | 462 | @cindex body height of a window |
| 500 | The @dfn{body height of a window} is specified as the total number of | ||
| 501 | lines occupied by the window's text area. Mode or header lines are not | ||
| 502 | included in a window's body height. | ||
| 503 | |||
| 504 | @cindex window body width | 463 | @cindex window body width |
| 505 | @cindex body width of a window | 464 | @cindex body width of a window |
| 506 | The @dfn{body width of a window} denotes the total number of columns | ||
| 507 | occupied by the window's text area. Scroll bars or columns of @samp{|} | ||
| 508 | characters that separate side-by-side windows are not included in a | ||
| 509 | window's body width. | ||
| 510 | |||
| 511 | @cindex body size of a window | 465 | @cindex body size of a window |
| 512 | @cindex window body size | 466 | @cindex window body size |
| 513 | @cindex canonical units of window/frame size | 467 | The @dfn{body height} of a window is the height of its text area, |
| 514 | The following functions retrieve height and width of the body of a | 468 | which does not include the mode or header line. Similarly, the |
| 515 | live window. Note that the values these functions return are measured | 469 | @dfn{body width} is the width of the text area, which does not include |
| 516 | in @dfn{canonical units}, i.e.@: for the default frame's face. If the | 470 | the scroll bar, fringes, or margins. |
| 517 | window shows some characters with non-default face, e.g., if the font | ||
| 518 | of some characters is larger or smaller than the default font, the | ||
| 519 | values returned by these functions will not match the actual number of | ||
| 520 | lines or characters per line shown in the window. To get the actual | ||
| 521 | number of columns and lines, move to the last character in the line | ||
| 522 | (e.g., with @code{end-of-visual-line}) or to the last line of the | ||
| 523 | window (e.g., with @code{window-end}), and use @code{posn-at-point} to | ||
| 524 | find the line or column there. | ||
| 525 | |||
| 526 | @defun window-body-size &optional window horizontal | ||
| 527 | This function returns the number of lines of @var{window}'s text area. | ||
| 528 | @var{window} must be a live window and defaults to the selected one. | ||
| 529 | The return value does not count any mode or header line of @var{window}. | ||
| 530 | |||
| 531 | Optional argument @var{horizontal} non-@code{nil} means to return the | ||
| 532 | number of columns of @var{window}'s text area. In this case the return | ||
| 533 | value does not include any vertical divider or scroll bar owned by | ||
| 534 | @var{window}. On a window-system the return value does not include the | ||
| 535 | number of columns used for @var{window}'s fringes or display margins | ||
| 536 | either. | ||
| 537 | @end defun | ||
| 538 | 471 | ||
| 539 | @defun window-body-height &optional window | 472 | @defun window-body-height &optional window |
| 540 | This function returns the number of lines of @var{window}'s body. | 473 | This function returns the body height, in lines, of the window |
| 541 | @var{window} must be a live window and defaults to the selected one. | 474 | @var{window}. If @var{window} is omitted or @code{nil}, it defaults |
| 475 | to the selected window; otherwise it must be a live window. | ||
| 542 | 476 | ||
| 543 | The return value does not include @var{window}'s mode line and header | 477 | If there is a partially-visible line at the bottom of the text area, |
| 544 | line, if any. If a line at the bottom of the window is only partially | 478 | that counts as a whole line; to exclude such a partially-visible line, |
| 545 | visible, that line is included in the return value. If you do not | 479 | use @code{window-text-height}, below. |
| 546 | want to include a partially visible bottom line in the return value, | ||
| 547 | use @code{window-text-height} instead. | ||
| 548 | @end defun | 480 | @end defun |
| 549 | 481 | ||
| 550 | @defun window-body-width &optional window | 482 | @defun window-body-width &optional window |
| 551 | This function returns the number of columns of @var{window}'s body. | 483 | This function returns the body width, in columns, of the window |
| 552 | @var{window} must be a live window and defaults to the selected one. | 484 | @var{window}. If @var{window} is omitted or @code{nil}, it defaults |
| 553 | 485 | to the selected window; otherwise it must be a live window. | |
| 554 | The return value does not include any vertical dividers or scroll bars | ||
| 555 | owned by @var{window}. On a window-system the return value does not | ||
| 556 | include the number of columns used for @var{window}'s fringes or | ||
| 557 | display margins either. | ||
| 558 | @end defun | 486 | @end defun |
| 559 | 487 | ||
| 560 | The following functions have been used in earlier versions of Emacs. | 488 | @defun window-body-size &optional window horizontal |
| 561 | They are still supported but due to the confusing nomenclature they | 489 | This function returns the body height or body width of @var{window}. |
| 562 | should not be used any more in future code. | 490 | If @var{horizontal} is omitted or @code{nil}, it is equivalent to |
| 563 | 491 | calling @code{window-body-height} for @var{window}; otherwise it is | |
| 564 | @defun window-height &optional window | 492 | equivalent to calling @code{window-body-width}. |
| 565 | This function is an alias for `window-total-height', see above. | ||
| 566 | @end defun | 493 | @end defun |
| 567 | 494 | ||
| 568 | @defun window-width &optional window | 495 | @defun window-text-height &optional window |
| 569 | This function is an alias for `window-body-width', see above. | 496 | This function is like @code{window-body-height}, except that any |
| 497 | partially-visible line at the bottom of the text area is not counted. | ||
| 570 | @end defun | 498 | @end defun |
| 571 | 499 | ||
| 572 | @cindex minimum window size | 500 | For compatibility with previous versions of Emacs, |
| 573 | The following two options constrain the sizes of windows to a minimum | 501 | @code{window-height} is an alias for @code{window-body-height}, and |
| 574 | height and width. Their values are honored when windows are split | 502 | @code{window-width} is an alias for @code{window-body-width}. These |
| 575 | (@pxref{Splitting Windows}) or resized (@pxref{Resizing Windows}). Any | 503 | aliases are considered obsolete and will be removed in the future. |
| 576 | request to make a window smaller than specified here will usually result | ||
| 577 | in an error. | ||
| 578 | |||
| 579 | @defopt window-min-height | ||
| 580 | The value of this variable specifies how short a window may be. The | ||
| 581 | value is measured in line units and has to account for any header or | ||
| 582 | mode line. The default value for this option is @code{4}. Values less | ||
| 583 | than @code{1} are ignored. | ||
| 584 | @end defopt | ||
| 585 | |||
| 586 | @defopt window-min-width | ||
| 587 | The value of this variable specifies how narrow a window may be. The | ||
| 588 | value is measured in characters and includes any margins, fringes, | ||
| 589 | scroll bar and vertical divider column. The default value for this | ||
| 590 | option is @code{10}. A value less than @code{2} is ignored. | ||
| 591 | @end defopt | ||
| 592 | |||
| 593 | Applications should not rebind these variables. To shrink a specific | ||
| 594 | window to a height or width less than the one specified here, they | ||
| 595 | should rather invoke @code{window-resize} (@pxref{Resizing Windows}) | ||
| 596 | with a non-@code{nil} @var{ignore} argument. The function | ||
| 597 | @code{split-window} (@pxref{Splitting Windows}) can make a window | ||
| 598 | smaller than specified here by calling it with a non-@code{nil} | ||
| 599 | @var{size} argument. Interactively, the values specified here cannot be | ||
| 600 | overridden. | ||
| 601 | |||
| 602 | Earlier versions of Emacs could delete a window when its size dropped | ||
| 603 | below @code{window-min-height} or @code{window-min-width}. As a rule, | ||
| 604 | the current version of Emacs does no more delete windows by side-effect. | ||
| 605 | The only exception to this rule are requests to resize a frame which may | ||
| 606 | implicitly delete windows when they do not fit on the frame any more, | ||
| 607 | see @ref{Size and Position}. | ||
| 608 | |||
| 609 | The size of a window can be fixed which means that it cannot be split | ||
| 610 | (@pxref{Splitting Windows}) or resized (@pxref{Resizing Windows}). | ||
| 611 | 504 | ||
| 612 | @cindex fixed-size window | 505 | @cindex fixed-size window |
| 506 | Commands that change the size of windows (@pxref{Resizing Windows}), | ||
| 507 | or split them (@pxref{Splitting Windows}), obey the variables | ||
| 508 | @code{window-min-height} and @code{window-min-width}, which specify | ||
| 509 | the smallest allowable window height and width. @xref{Change | ||
| 510 | Window,,Deleting and Rearranging Windows, emacs, The GNU Emacs | ||
| 511 | Manual}. They also obey the variable @code{window-size-fixed}, with | ||
| 512 | which a window can be @dfn{fixed} in size: | ||
| 513 | |||
| 613 | @defvar window-size-fixed | 514 | @defvar window-size-fixed |
| 614 | If this variable is non-@code{nil}, in a given buffer, then the size of | 515 | If this buffer-local variable is non-@code{nil}, the size of any |
| 615 | any window displaying that buffer remains fixed unless you either | 516 | window displaying the buffer cannot normally be changed. Deleting a |
| 616 | explicitly change it or Emacs has no other choice. | 517 | window or changing the frame's size may still change its size, if |
| 518 | there is no choice. | ||
| 617 | 519 | ||
| 618 | If the value is @code{height}, then only the window's height is fixed; | 520 | If the value is @code{height}, then only the window's height is fixed; |
| 619 | if the value is @code{width}, then only the window's width is fixed. | 521 | if the value is @code{width}, then only the window's width is fixed. |
| 620 | Any other non-@code{nil} value fixes both the width and the height. | 522 | Any other non-@code{nil} value fixes both the width and the height. |
| 621 | |||
| 622 | This variable automatically becomes buffer-local when set. | ||
| 623 | @end defvar | 523 | @end defvar |
| 624 | 524 | ||
| 625 | Commands supposed to explicitly change the size of windows such as | ||
| 626 | @code{enlarge-window} (@pxref{Resizing Windows}) get an error if they | ||
| 627 | had to change a window size which is fixed. Other functions like | ||
| 628 | @code{window-resize} (@pxref{Resizing Windows}) have an optional | ||
| 629 | @var{ignore} argument which allows to change the size of fixed-size | ||
| 630 | windows. | ||
| 631 | |||
| 632 | Deleting a window or changing a frame's size may change the size of a | ||
| 633 | fixed-size window, if there is no other alternative. | ||
| 634 | |||
| 635 | The height of a vertical combination of windows cannot be changed | ||
| 636 | when the height of all these windows is fixed. Its width cannot be | ||
| 637 | changed if the width of at least one of these windows is fixed. | ||
| 638 | Similarly, the width of a horizontal combination of windows cannot be | ||
| 639 | changed when the width of all these windows is fixed. Its height cannot | ||
| 640 | be changed if the height of at least one of these windows is fixed. | ||
| 641 | |||
| 642 | The next function allows to check whether the size of an arbitrary | ||
| 643 | window is fixed. | ||
| 644 | |||
| 645 | @defun window-size-fixed-p &optional window horizontal | 525 | @defun window-size-fixed-p &optional window horizontal |
| 646 | This function returns non-@code{nil} if @var{window}'s height is fixed. | 526 | This function returns a non-@code{nil} value if @var{window}'s height |
| 647 | The argument @var{window} can be an arbitrary window and defaults to the | 527 | is fixed. If @var{window} is omitted or @code{nil}, it defaults to |
| 648 | selected one. Optional argument @var{horizontal} non-@code{nil} means | 528 | the selected window. If the optional argument @var{horizontal} is |
| 649 | return non-@code{nil} if @var{window}'s width is fixed. | 529 | non-@code{nil}, the return value is non-@code{nil} if @var{window}'s |
| 530 | width is fixed. | ||
| 650 | 531 | ||
| 651 | If this function returns @code{nil}, this does not necessarily mean that | 532 | A @code{nil} return value does not necessarily mean that @var{window} |
| 652 | @var{window} can be resized in the desired direction. The function | 533 | can be resized in the desired direction. To determine that, use the |
| 653 | @code{window-resizable} (@pxref{Resizing Windows}) can tell that. | 534 | function @code{window-resizable}. @xref{Resizing Windows}. |
| 654 | @end defun | 535 | @end defun |
| 655 | 536 | ||
| 656 | 537 | ||
| @@ -661,134 +542,69 @@ If this function returns @code{nil}, this does not necessarily mean that | |||
| 661 | @cindex changing window size | 542 | @cindex changing window size |
| 662 | @cindex window size, changing | 543 | @cindex window size, changing |
| 663 | 544 | ||
| 664 | Emacs does not permit overlapping windows or gaps between windows, so | 545 | This section describes functions for resizing a window without |
| 665 | changing the size of a window always affects at least one other window. | 546 | changing the size of its frame. Because live windows do not overlap, |
| 666 | When a frame contains just one window, that window can be resized only | 547 | these functions are meaningful only on frames that contain two or more |
| 667 | by resizing the window's frame. The functions described below are | 548 | windows: resizing a window also changes the size of a neighboring |
| 668 | therefore meaningful only in the context of a frame containing at least | 549 | window. If there is just one window on a frame, its size cannot be |
| 669 | two windows. The size of the corresponding frame never changes when | 550 | changed except by resizing the frame (@pxref{Size and Position}). |
| 670 | invoking a function described in this section. | 551 | |
| 671 | 552 | Except where noted, these functions also accept internal windows as | |
| 672 | The routines changing window sizes always operate in one dimension at | 553 | arguments. Resizing an internal window causes its child windows to be |
| 673 | a time. This means that windows can be resized only either vertically | 554 | resized to fit the same space. |
| 674 | or horizontally. If a window shall be resized in both dimensions, it | 555 | |
| 675 | must be resized in one dimension first and in the other dimension | 556 | @defun window-resizable window delta &optional horizontal ignore |
| 676 | afterwards. If the second resize operation fails, the frame might end | ||
| 677 | up in an unsatisfactory state. To avoid such states, it might be useful | ||
| 678 | to save the current window configuration (@pxref{Window Configurations}) | ||
| 679 | before attempting the first resize operation and restore the saved | ||
| 680 | configuration in case the second resize operation fails. | ||
| 681 | |||
| 682 | Functions that resize windows are supposed to obey restrictions | ||
| 683 | imposed by window minimum sizes and fixed-size windows, see @ref{Window | ||
| 684 | Sizes}. In order to determine whether resizing a specific window is | ||
| 685 | possible in the first place, the following function can be used: | ||
| 686 | |||
| 687 | @defun window-resizable window delta &optional horizontal ignore side noup nodown | ||
| 688 | This function returns @var{delta} if the size of @var{window} can be | 557 | This function returns @var{delta} if the size of @var{window} can be |
| 689 | changed vertically by @var{delta} lines. Optional argument | 558 | changed vertically by @var{delta} lines. If the optional argument |
| 690 | @var{horizontal} non-@code{nil} means to return @var{delta} if | 559 | @var{horizontal} is non-@code{nil}, it instead returns @var{delta} if |
| 691 | @var{window} can be resized horizontally by @var{delta} columns. A | 560 | @var{window} can be resized horizontally by @var{delta} columns. It |
| 692 | return value of zero means that @var{window} is not resizable. | 561 | does not actually change the window size. |
| 693 | 562 | ||
| 694 | If @var{delta} is a positive number, this means that @var{window} shall | 563 | If @var{window} is @code{nil}, it defaults to the selected window. |
| 695 | be enlarged by @var{delta} lines or columns. If @var{window} cannot be | 564 | |
| 696 | enlarged by @var{delta} lines or columns, this function returns the | 565 | A positive value of @var{delta} means to check whether the window can be |
| 697 | maximum value in the range from 0 to @var{delta} by which @var{window} | 566 | enlarged by that number of lines or columns; a negative value of |
| 698 | can be enlarged. | 567 | @var{delta} means to check whether the window can be shrunk by that many |
| 699 | 568 | lines or columns. If @var{delta} is non-zero, a return value of 0 means | |
| 700 | If @var{delta} is a negative number, this means that @var{window} shall | 569 | that the window cannot be resized. |
| 701 | be shrunk by -@var{delta} lines or columns. If @var{window} cannot be | 570 | |
| 702 | shrunk by -@var{delta} lines or columns, this function returns the | 571 | Normally, the variables @code{window-min-height} and |
| 703 | minimum value in the range from @var{delta} to 0 that can be used for | 572 | @code{window-min-width} specify the smallest allowable window size. |
| 704 | shrinking @var{window}. | 573 | @xref{Change Window,, Deleting and Rearranging Windows, emacs, The GNU |
| 705 | 574 | Emacs Manual}. However, if the optional argument @var{ignore} is | |
| 706 | Optional argument @var{ignore} non-@code{nil} means ignore any | 575 | non-@code{nil}, this function ignores @code{window-min-height} and |
| 707 | restrictions imposed by the variables @code{window-min-height} or | 576 | @code{window-min-width}, as well as @code{window-size-fixed}. |
| 708 | @code{window-min-width} and @code{window-size-fixed}. In this case the | 577 | Instead, it considers the minimum-height window to be one consisting |
| 709 | minimum height of a window is specified as the minimum number of lines | 578 | of a header (if any), a mode line, plus a text area one line tall; and |
| 710 | that allow viewing any header or mode line and at least one line of the | 579 | a minimum-width window as one consisting of fringes, margins, and |
| 711 | text area of window. The minimum width of a window includes any | 580 | scroll bar (if any), plus a text area two columns wide. |
| 712 | fringes, margins and the scroll bar as well as two text columns. | 581 | @end defun |
| 713 | |||
| 714 | If @var{ignore} denotes a window, this means to ignore restrictions for | ||
| 715 | that window only. If @var{ignore} equals the constant @code{safe}, this | ||
| 716 | means a live window may get as small as one line or two columns. | ||
| 717 | |||
| 718 | Optional argument @var{noup} non-@code{nil} means don't go up in the | ||
| 719 | window tree but try to steal or distribute the space needed for the | ||
| 720 | resize operation among the other windows within @var{window}'s | ||
| 721 | combination. Optional argument @var{nodown} non-@code{nil} means don't | ||
| 722 | check whether @var{window} itself and its child windows can be resized. | ||
| 723 | @end defun | ||
| 724 | |||
| 725 | The function @code{window-resizable} does not change any window sizes. | ||
| 726 | The following function does: | ||
| 727 | 582 | ||
| 728 | @defun window-resize window delta &optional horizontal ignore | 583 | @defun window-resize window delta &optional horizontal ignore |
| 729 | This function resizes @var{window} vertically by @var{delta} lines. The | 584 | This function resizes @var{window} by @var{delta} increments. If |
| 730 | argument @var{window} can denote an arbitrary window and defaults to the | 585 | @var{horizontal} is @code{nil}, it changes the height by @var{delta} |
| 731 | selected one. An attempt to resize the root window of a frame will | 586 | lines; otherwise, it changes the width by @var{delta} columns. A |
| 732 | raise an error. | 587 | positive @var{delta} means to enlarge the window, and a negative |
| 733 | 588 | @var{delta} means to shrink it. | |
| 734 | Second argument @var{delta} a positive number means @var{window} shall | ||
| 735 | be enlarged by @var{delta} lines. If @var{delta} is negative, that | ||
| 736 | means @var{window} shall be shrunk by -@var{delta} lines. | ||
| 737 | |||
| 738 | Optional argument @var{horizontal} non-@code{nil} means to resize | ||
| 739 | @var{window} horizontally by @var{delta} columns. In this case a | ||
| 740 | positive @var{delta} means enlarge @var{window} by @var{delta} columns. | ||
| 741 | A negative @var{delta} means @var{window} shall be shrunk by | ||
| 742 | -@var{delta} columns. | ||
| 743 | |||
| 744 | Optional argument @var{ignore} has the same meaning as for the function | ||
| 745 | @code{window-resizable} above. | ||
| 746 | |||
| 747 | This function can simultaneously move two edges of WINDOW. Exactly | ||
| 748 | which edges of @var{window} are moved and which other windows are | ||
| 749 | resized along with @var{window} is determined by the splits and nest | ||
| 750 | status of the involved windows (@pxref{Splitting Windows}). If only the | ||
| 751 | low (right) edge of @var{window} shall be moved, the function | ||
| 752 | @code{adjust-window-trailing-edge} described below should be used. | ||
| 753 | @end defun | ||
| 754 | |||
| 755 | The next four commands are simple interfaces to @code{window-resize}. | ||
| 756 | They always operate on the selected window, never delete any window, and | ||
| 757 | always raise an error when resizing would violate a restriction imposed | ||
| 758 | by @code{window-min-height}, @code{window-min-width}, or | ||
| 759 | @code{window-size-fixed}. | ||
| 760 | |||
| 761 | @deffn Command enlarge-window delta &optional horizontal | ||
| 762 | This function makes the selected window @var{delta} lines taller. | ||
| 763 | Interactively, if no argument is given, it makes the selected window one | ||
| 764 | line taller. If optional argument @var{horizontal} is non-@code{nil}, | ||
| 765 | it makes the selected window wider by @var{delta} columns. If | ||
| 766 | @var{delta} is negative, it shrinks the selected window by -@var{delta} | ||
| 767 | lines or columns. The return value is @code{nil}. | ||
| 768 | @end deffn | ||
| 769 | 589 | ||
| 770 | @deffn Command enlarge-window-horizontally delta | 590 | If @var{window} is @code{nil}, it defaults to the selected window. If |
| 771 | This function makes the selected window @var{delta} columns wider. | 591 | the window cannot be resized as demanded, an error is signaled. |
| 772 | Interactively, if no argument is given, it makes the selected window one | ||
| 773 | column wider. | ||
| 774 | @end deffn | ||
| 775 | 592 | ||
| 776 | @deffn Command shrink-window delta &optional horizontal | 593 | The optional argument @var{ignore} has the same meaning as for the |
| 777 | This function makes the selected window @var{delta} lines smaller. | 594 | function @code{window-resizable} above. |
| 778 | Interactively, if no argument is given, it makes the selected window one | ||
| 779 | line smaller. If optional argument @var{horizontal} is non-@code{nil}, | ||
| 780 | it makes the selected window narrower by @var{delta} columns. If | ||
| 781 | @var{delta} is negative, it enlarges the selected window by -@var{delta} | ||
| 782 | lines or columns. The return value is @code{nil}. | ||
| 783 | @end deffn | ||
| 784 | 595 | ||
| 785 | @deffn Command shrink-window-horizontally delta | 596 | The choice of which window edge this function alters depends on the |
| 786 | This function makes the selected window @var{delta} columns narrower. | 597 | splitting and nesting status of the involved windows; in some cases, |
| 787 | Interactively, if no argument is given, it makes the selected window one | 598 | it may alter both edges. @xref{Splitting Windows}. To resize by |
| 788 | column narrower. | 599 | moving only the bottom or right edge of a window, use the function |
| 789 | @end deffn | 600 | @code{adjust-window-trailing-edge}, below. |
| 601 | @end defun | ||
| 602 | |||
| 603 | @c The commands enlarge-window, enlarge-window-horizontally, | ||
| 604 | @c shrink-window, and shrink-window-horizontally are documented in the | ||
| 605 | @c Emacs manual. They are not preferred for calling from Lisp. | ||
| 790 | 606 | ||
| 791 | The following function is useful for moving the line dividing two | 607 | The following function is useful for moving the line dividing two |
| 792 | windows. | 608 | windows. |
| 793 | 609 | ||
| 794 | @defun adjust-window-trailing-edge window delta &optional horizontal | 610 | @defun adjust-window-trailing-edge window delta &optional horizontal |
| @@ -801,7 +617,7 @@ If @var{delta} is greater zero, this moves the edge downwards or to the | |||
| 801 | right. If @var{delta} is less than zero, this moves the edge upwards or | 617 | right. If @var{delta} is less than zero, this moves the edge upwards or |
| 802 | to the left. If the edge can't be moved by @var{delta} lines or columns, | 618 | to the left. If the edge can't be moved by @var{delta} lines or columns, |
| 803 | it is moved as far as possible in the desired direction but no error is | 619 | it is moved as far as possible in the desired direction but no error is |
| 804 | signalled. | 620 | signaled. |
| 805 | 621 | ||
| 806 | This function tries to resize windows adjacent to the edge that is | 622 | This function tries to resize windows adjacent to the edge that is |
| 807 | moved. Only if this is insufficient, it will also resize windows not | 623 | moved. Only if this is insufficient, it will also resize windows not |
| @@ -820,7 +636,7 @@ contents exactly. The default for @var{window} is the selected window. | |||
| 820 | The optional argument @var{max-height} specifies the maximum total | 636 | The optional argument @var{max-height} specifies the maximum total |
| 821 | height the window is allowed to be; @code{nil} means use the maximum | 637 | height the window is allowed to be; @code{nil} means use the maximum |
| 822 | permissible height of a window on @var{window}'s frame. The optional | 638 | permissible height of a window on @var{window}'s frame. The optional |
| 823 | argument @var{min-height} specifies the minimum toatl height for the | 639 | argument @var{min-height} specifies the minimum total height for the |
| 824 | window; @code{nil} means use @code{window-min-height}. All these height | 640 | window; @code{nil} means use @code{window-min-height}. All these height |
| 825 | values include the mode line and/or header line. | 641 | values include the mode line and/or header line. |
| 826 | 642 | ||
| @@ -894,222 +710,66 @@ frame. @var{window} can be any window and defaults to the selected one. | |||
| 894 | @cindex splitting windows | 710 | @cindex splitting windows |
| 895 | @cindex window splitting | 711 | @cindex window splitting |
| 896 | 712 | ||
| 897 | The functions described below are the primitives needed for creating a | 713 | This section describes functions for creating a new window by |
| 898 | new window. They do not accept a buffer as an argument. Rather, they | 714 | @dfn{splitting} an existing one. |
| 899 | ``split'' an existing window into two halves, both displaying the buffer | ||
| 900 | previously visible in the window that was split. | ||
| 901 | 715 | ||
| 902 | @deffn Command split-window &optional window size side | 716 | @deffn Command split-window &optional window size side |
| 903 | This function creates a new window adjacent to @var{window}. It returns | 717 | This function creates a new live window next to the window |
| 904 | the new window which is always a live window. The argument @var{window} | 718 | @var{window}. If @var{window} is omitted or @code{nil}, it defaults |
| 905 | can denote any window and defaults to the selected one. This function | 719 | to the selected window. That window is ``split'', and reduced in |
| 906 | does not change the selected window. | 720 | size. The space is taken up by the new window, which is returned. |
| 907 | 721 | ||
| 908 | Optional second argument @var{size} a positive number means make | 722 | The optional second argument @var{size} determines the sizes of the |
| 909 | @var{window} @var{size} lines (or columns) tall. If @var{size} is | 723 | @var{window} and/or the new window. If it is omitted or @code{nil}, |
| 910 | negative, make the new window @minus{}@var{size} lines (or columns) | 724 | both windows are given equal sizes; if there is an odd line, it is |
| 911 | tall. If @var{size} is omitted or @code{nil}, then @var{window} is | 725 | allocated to the new window. If @var{size} is a positive number, |
| 912 | divided evenly into two parts. (If there is an odd line, it is | 726 | @var{window} is given @var{size} lines (or columns, depending on the |
| 913 | allocated to the new window.) | 727 | value of @var{side}). If @var{size} is a negative number, the new |
| 914 | 728 | window is given @minus{}@var{size} lines (or columns). | |
| 915 | If splitting would result in making a window smaller than | 729 | |
| 916 | @code{window-min-height} or @code{window-min-width} (@pxref{Window | 730 | If @var{size} is @code{nil}, this function obeys the variables |
| 917 | Sizes}), this function usually signals an error. However, if @var{size} | 731 | @code{window-min-height} and @code{window-min-width}. @xref{Change |
| 918 | is non-@code{nil} and valid, a new window of the requested size is | 732 | Window,,Deleting and Rearranging Windows, emacs, The GNU Emacs |
| 919 | created. (A size value would be invalid if it assigned less than one | 733 | Manual}. Thus, it signals an error if splitting would result in |
| 920 | line or less than two columns to the new window.) | 734 | making a window smaller than those variables specify. However, a |
| 921 | 735 | non-@code{nil} value for @var{size} causes those variables to be | |
| 922 | Optional third argument @var{side} @code{nil} (or @code{below}) | 736 | ignored; in that case, the smallest allowable window is considered to |
| 923 | specifies that the new window shall be located below @var{window}. The | 737 | be one that has space for a text area one line tall and/or two columns |
| 924 | value @code{above} means the new window will be located above | 738 | wide. |
| 925 | @var{window}. In both cases @var{size} specifies the new number of | 739 | |
| 926 | lines for @var{window} (or the new window if @var{size} is negative) | 740 | The optional third argument @var{side} determines the position of the |
| 927 | including space reserved for the mode and/or header line. | 741 | new window relative to @var{window}. If it is @code{nil} or |
| 928 | 742 | @code{below}, the new window is placed below @var{window}. If it is | |
| 929 | If @var{side} is @code{t} or @code{right} the new window will be | 743 | @code{above}, the new window is placed above @var{window}. In both |
| 930 | positioned on the right side of @var{window}. The value @code{left} | 744 | these cases, @var{size} specifies a total window height, in lines. |
| 931 | means the new window will be located on the left side of @var{window}. | 745 | |
| 932 | In both cases @var{size} specifies the new number of columns for | 746 | If @var{side} is @code{t} or @code{right}, the new window is placed on |
| 933 | @var{window} (or the new window provided @var{size} is negative) | 747 | the right of @var{window}. If @var{side} is @code{left}, the new |
| 934 | including space reserved for margins, fringes and the scroll bar or a | 748 | window is placed on the left of @var{window}. In both these cases, |
| 935 | divider column. | 749 | @var{size} specifies a total window width, in columns. |
| 936 | 750 | ||
| 937 | Any other non-@code{nil} value for @var{side} is currently handled like | 751 | If @var{window} is a live window, the new window inherits various |
| 938 | @code{t} (or @code{right}). Since this might change in the future, | 752 | properties from it, including margins and scroll bars. If |
| 939 | application programs should refrain from using other values. | 753 | @var{window} is an internal window, the new window inherits the |
| 940 | 754 | properties of the window selected within @var{window}'s frame. | |
| 941 | If @var{window} is live, properties of the new window like margins and | 755 | |
| 942 | scroll bars are inherited from @var{window}. If @var{window} is an | 756 | If the variable @code{ignore-window-parameters} is non-@code{nil} |
| 943 | internal window, these properties, as well as the buffer shown in the | 757 | (@pxref{Window Parameters}), this function ignores window parameters. |
| 944 | new window, are inherited from the window selected on @var{window}'s | 758 | Otherwise, it consults the @code{split-window} parameter of |
| 945 | frame. | 759 | @var{window}; if this is @code{t}, it splits the window disregarding |
| 946 | 760 | any other window parameters. If the @code{split-window} parameter | |
| 947 | If @code{ignore-window-parameters} is non-@code{nil}, this function | 761 | specifies a function, that function is called with the arguments |
| 948 | ignores window parameters (@pxref{Window Parameters}). Otherwise, if | 762 | @var{window}, @var{size}, and @var{side} to split @var{window}, in |
| 949 | the @code{split-window} parameter of @var{window} is @code{t}, it splits | 763 | lieu of the usual action of @code{split-window}. |
| 950 | the window disregarding any other window parameters. If the | ||
| 951 | @code{split-window} parameter specifies a function, that function is | ||
| 952 | called with the arguments @var{window}, @var{size}, and @var{side} to | ||
| 953 | split @var{window}. If that function is @code{ignore}, nothing is done. | ||
| 954 | @end deffn | 764 | @end deffn |
| 955 | 765 | ||
| 956 | The following example starts with one window on a screen that is 50 | 766 | As an example, we show a combination of @code{split-window} calls |
| 957 | lines high by 80 columns wide; then it splits the window. | 767 | that yields the window configuration discussed in @ref{Windows and |
| 958 | 768 | Frames}. This example demonstrates splitting live windows as well as | |
| 959 | @smallexample | 769 | splitting internal windows. We begin with a frame containing a single |
| 960 | @group | 770 | window (a live root window), which we denote by @var{W4}. Calling |
| 961 | (setq W1 (selected-window)) | 771 | @code{(split-window W3)} yields this window configuration: |
| 962 | @result{} #<window 8 on windows.texi> | ||
| 963 | (setq W2 (split-window W1 15)) | ||
| 964 | @result{} #<window 28 on windows.texi> | ||
| 965 | @end group | ||
| 966 | @group | ||
| 967 | (window-top-line W1) | ||
| 968 | @result{} 0 | ||
| 969 | (window-total-size W1) | ||
| 970 | @result{} 15 | ||
| 971 | (window-top-line W2) | ||
| 972 | @result{} 15 | ||
| 973 | @end group | ||
| 974 | @end smallexample | ||
| 975 | |||
| 976 | The screen looks like this: | ||
| 977 | |||
| 978 | @smallexample | ||
| 979 | @group | ||
| 980 | __________ | ||
| 981 | | | line 0 | ||
| 982 | | W1 | | ||
| 983 | |__________| | ||
| 984 | | | line 15 | ||
| 985 | | W2 | | ||
| 986 | |__________| | ||
| 987 | line 50 | ||
| 988 | column 0 column 80 | ||
| 989 | @end group | ||
| 990 | @end smallexample | ||
| 991 | |||
| 992 | Next, split the top window into two side-by-side windows: | ||
| 993 | |||
| 994 | @smallexample | ||
| 995 | @group | ||
| 996 | (setq W3 (split-window W1 35 t)) | ||
| 997 | @result{} #<window 32 on windows.texi> | ||
| 998 | @end group | ||
| 999 | @group | ||
| 1000 | (window-left-column W1) | ||
| 1001 | @result{} 0 | ||
| 1002 | (window-total-size W1 t) | ||
| 1003 | @result{} 35 | ||
| 1004 | (window-left-column W3) | ||
| 1005 | @result{} 35 | ||
| 1006 | @end group | ||
| 1007 | @end smallexample | ||
| 1008 | |||
| 1009 | @need 3000 | ||
| 1010 | Now the screen looks like this: | ||
| 1011 | |||
| 1012 | @smallexample | ||
| 1013 | @group | ||
| 1014 | column 35 | ||
| 1015 | __________ | ||
| 1016 | | | | line 0 | ||
| 1017 | | W1 | W3 | | ||
| 1018 | |____|_____| | ||
| 1019 | | | line 15 | ||
| 1020 | | W2 | | ||
| 1021 | |__________| | ||
| 1022 | line 50 | ||
| 1023 | column 0 column 80 | ||
| 1024 | @end group | ||
| 1025 | @end smallexample | ||
| 1026 | |||
| 1027 | Normally, Emacs indicates the border between two side-by-side windows | ||
| 1028 | with a scroll bar (@pxref{Scroll Bars}), or with @samp{|} characters. The | ||
| 1029 | display table can specify alternative border characters; see @ref{Display | ||
| 1030 | Tables}. | ||
| 1031 | |||
| 1032 | Below we describe how @code{split-window} can be used to create the | ||
| 1033 | window configuration from our earlier example (@pxref{Windows and | ||
| 1034 | Frames}) and how internal windows are created for this purpose. We | ||
| 1035 | start with a frame containing one live window @code{W2} (in the | ||
| 1036 | following scenarios window names are assigned in an arbitrary manner in | ||
| 1037 | order to match the names of the example). Evaluating the form | ||
| 1038 | @code{(split-window W2 8 t)} creates a new internal window @code{W1} | ||
| 1039 | with two children---@code{W2} (the window we've split) and a new leaf | ||
| 1040 | window @code{W6}: | ||
| 1041 | @smallexample | ||
| 1042 | @group | ||
| 1043 | ______________________________________ | ||
| 1044 | | ______ ____________________________ | | ||
| 1045 | || || || | ||
| 1046 | || || || | ||
| 1047 | || || || | ||
| 1048 | || || || | ||
| 1049 | || || || | ||
| 1050 | || || || | ||
| 1051 | || || || | ||
| 1052 | || || || | ||
| 1053 | || || || | ||
| 1054 | || || || | ||
| 1055 | ||__W2__||_____________W6_____________ | | ||
| 1056 | |__________________W1__________________| | ||
| 1057 | |||
| 1058 | @end group | ||
| 1059 | @end smallexample | ||
| 1060 | 772 | ||
| 1061 | Evaluating now @code{(split-window W6 -3)} creates another internal | ||
| 1062 | window @code{W3} with two children---@code{W6} and a new live window | ||
| 1063 | @code{W5}. This leaves us with a vertically combined window @code{W3} | ||
| 1064 | embedded in the horizontally combined window @code{W1}: | ||
| 1065 | @smallexample | ||
| 1066 | @group | ||
| 1067 | ______________________________________ | ||
| 1068 | | ______ ____________________________ | | ||
| 1069 | || || __________________________ || | ||
| 1070 | || ||| ||| | ||
| 1071 | || ||| ||| | ||
| 1072 | || ||| ||| | ||
| 1073 | || ||| ||| | ||
| 1074 | || ||| ||| | ||
| 1075 | || |||____________W6____________||| | ||
| 1076 | || || __________________________ || | ||
| 1077 | || ||| ||| | ||
| 1078 | || |||____________W5____________||| | ||
| 1079 | ||__W2__||_____________W3_____________ | | ||
| 1080 | |__________________W1__________________| | ||
| 1081 | |||
| 1082 | @end group | ||
| 1083 | @end smallexample | ||
| 1084 | |||
| 1085 | Finally, evaluating @code{(split-window W6 nil t)} should get us the | ||
| 1086 | desired configuration as depicted below. | ||
| 1087 | @smallexample | ||
| 1088 | @group | ||
| 1089 | ______________________________________ | ||
| 1090 | | ______ ____________________________ | | ||
| 1091 | || || __________________________ || | ||
| 1092 | || ||| ___________ ___________ ||| | ||
| 1093 | || |||| || |||| | ||
| 1094 | || |||| || |||| | ||
| 1095 | || ||||_____W6____||_____W7____|||| | ||
| 1096 | || |||____________W4____________||| | ||
| 1097 | || || __________________________ || | ||
| 1098 | || ||| ||| | ||
| 1099 | || |||____________W5____________||| | ||
| 1100 | ||__W2__||_____________W3_____________ | | ||
| 1101 | |__________________W1__________________| | ||
| 1102 | |||
| 1103 | @end group | ||
| 1104 | @end smallexample | ||
| 1105 | |||
| 1106 | The scenario sketched above is the standard way to obtain the desired | ||
| 1107 | configuration. In Emacs 23 it was also the only way to do that since | ||
| 1108 | Emacs 23 did't allow splitting internal windows. | ||
| 1109 | |||
| 1110 | With Emacs 24 you can also proceed as follows: Split an initial window | ||
| 1111 | @code{W6} by evaluating @code{(split-window W6 -3)} to produce the | ||
| 1112 | following vertical combination: | ||
| 1113 | @smallexample | 773 | @smallexample |
| 1114 | @group | 774 | @group |
| 1115 | ______________________________________ | 775 | ______________________________________ |
| @@ -1117,112 +777,64 @@ following vertical combination: | |||
| 1117 | || || | 777 | || || |
| 1118 | || || | 778 | || || |
| 1119 | || || | 779 | || || |
| 780 | ||_________________W4_________________|| | ||
| 781 | | ____________________________________ | | ||
| 1120 | || || | 782 | || || |
| 1121 | || || | 783 | || || |
| 1122 | || || | 784 | || || |
| 1123 | || || | ||
| 1124 | ||_________________W6_________________|| | ||
| 1125 | | ____________________________________ | | ||
| 1126 | || || | ||
| 1127 | ||_________________W5_________________|| | 785 | ||_________________W5_________________|| |
| 1128 | |__________________W3__________________| | 786 | |__________________W3__________________| |
| 1129 | 787 | ||
| 1130 | @end group | 788 | @end group |
| 1131 | @end smallexample | 789 | @end smallexample |
| 1132 | 790 | ||
| 1133 | Evaluating now @code{(split-window (window-parent W6) -8 'left)} or, | 791 | @noindent |
| 1134 | equivalently, @code{(split-window W3 -8 'left)} should now produce the | 792 | The @code{split-window} call has created a new live window, denoted by |
| 1135 | penultimate configuration from the previous scenario from where we can | 793 | @var{W5}. It has also created a new internal window, denoted by |
| 1136 | continue as described before. | 794 | @var{W3}, which becomes the root window and the parent of both |
| 1137 | 795 | @var{W4} and @var{W5}. | |
| 1138 | Another strategy starts with splitting an initial window @code{W6} by | ||
| 1139 | evaluating @code{(split-window W6 nil nil t)} with the following result: | ||
| 1140 | @smallexample | ||
| 1141 | @group | ||
| 1142 | ______________________________________ | ||
| 1143 | | _________________ _________________ | | ||
| 1144 | || || || | ||
| 1145 | || || || | ||
| 1146 | || || || | ||
| 1147 | || || || | ||
| 1148 | || || || | ||
| 1149 | || || || | ||
| 1150 | || || || | ||
| 1151 | || || || | ||
| 1152 | || || || | ||
| 1153 | || || || | ||
| 1154 | ||________W6_______||________W7_______|| | ||
| 1155 | |__________________W4__________________| | ||
| 1156 | |||
| 1157 | @end group | ||
| 1158 | @end smallexample | ||
| 1159 | |||
| 1160 | Evaluating now @code{(split-window W4 -3)} or @code{(split-window | ||
| 1161 | (window-parent W6) -3)} should get us a configuration as shown next. | ||
| 1162 | @smallexample | ||
| 1163 | @group | ||
| 1164 | ______________________________________ | ||
| 1165 | | ____________________________________ | | ||
| 1166 | || ________________ ________________ || | ||
| 1167 | ||| || ||| | ||
| 1168 | ||| || ||| | ||
| 1169 | ||| || ||| | ||
| 1170 | ||| || ||| | ||
| 1171 | ||| || ||| | ||
| 1172 | |||_______W6_______||________W7______||| | ||
| 1173 | ||_________________W4_________________|| | ||
| 1174 | | ____________________________________ | | ||
| 1175 | || || | ||
| 1176 | ||_________________W5_________________|| | ||
| 1177 | |__________________W3__________________| | ||
| 1178 | |||
| 1179 | @end group | ||
| 1180 | @end smallexample | ||
| 1181 | 796 | ||
| 1182 | The desired configuration can be now obtained by evaluating | 797 | Next, we call @code{(split-window W3 nil 'left)}, passing the |
| 1183 | @code{(split-window W3 -8 'left)} or, equivalently, @code{(split-window | 798 | internal window @var{W3} as the argument. The result: |
| 1184 | (window-parent W5) -8 'left)}. | ||
| 1185 | 799 | ||
| 1186 | For a final approach let's start with the configuration of two live | ||
| 1187 | windows @code{W6} and @code{W7} shown above. If we now evaluate | ||
| 1188 | @code{(split-window W4 -8 'left)} or @code{(split-window (window-parent | ||
| 1189 | W6) -8 'left)} we get the following configuration. | ||
| 1190 | @smallexample | 800 | @smallexample |
| 1191 | @group | 801 | @group |
| 1192 | ______________________________________ | 802 | ______________________________________ |
| 1193 | | ______ ____________________________ | | 803 | | ______ ____________________________ | |
| 1194 | || || ____________ ____________ || | 804 | || || __________________________ || |
| 1195 | || ||| || ||| | 805 | || ||| ||| |
| 1196 | || ||| || ||| | 806 | || ||| ||| |
| 1197 | || ||| || ||| | 807 | || ||| ||| |
| 1198 | || ||| || ||| | 808 | || |||____________W4____________||| |
| 1199 | || ||| || ||| | 809 | || || __________________________ || |
| 1200 | || ||| || ||| | 810 | || ||| ||| |
| 1201 | || ||| || ||| | 811 | || ||| ||| |
| 1202 | || |||______W6____||______W7____||| | 812 | || |||____________W5____________||| |
| 1203 | ||__W2__||_____________W4_____________|| | 813 | ||__W2__||_____________W3_____________ | |
| 1204 | |__________________W1__________________| | 814 | |__________________W1__________________| |
| 1205 | |||
| 1206 | @end group | 815 | @end group |
| 1207 | @end smallexample | 816 | @end smallexample |
| 1208 | 817 | ||
| 1209 | Evaluating now @code{(split-window W4 -3)} or, for example, | 818 | @noindent |
| 1210 | @code{(split-window (window-parent W6) -3)} should produce the desired | 819 | A new live window, @var{W2}, is created to the left of @var{W3} (which |
| 1211 | configuration. | 820 | encompasses the vertical window combination of @var{W4} and @var{W5}). |
| 821 | A new internal window @var{W1} is also created, and becomes the new | ||
| 822 | root window. | ||
| 1212 | 823 | ||
| 1213 | The two options described next can be used to tune the operation of | 824 | The following two options can be used to modify the operation of |
| 1214 | @code{split-window}. | 825 | @code{split-window}. |
| 1215 | 826 | ||
| 1216 | @defopt window-splits | 827 | @defopt window-splits |
| 1217 | If this variable is nil, the function @code{split-window} can split a | 828 | If this variable is @code{nil}, @code{split-window} can only split a |
| 1218 | window if and only if that window's screen estate is sufficiently large | 829 | window (denoted by @var{window}) if @var{window}'s screen area is |
| 1219 | to accommodate both--itself and the new window. | 830 | large enough to accommodate both itself and the new window. This is |
| 831 | the default. | ||
| 1220 | 832 | ||
| 1221 | If this variable is non-@code{nil}, @code{split-window} tries to resize | 833 | If this variable is non-@code{nil}, @code{split-window} tries to |
| 1222 | all windows that are part of the same combination as the old window to | 834 | resize all windows that are part of the same combination as |
| 1223 | accommodate the new window. Hence, the new window can be also created if | 835 | @var{window}, in order to accommodate the new window. In particular, |
| 1224 | the old window is of fixed size or too small to split (@pxref{Window | 836 | this may allow @code{split-window} to succeed even if @var{window} is |
| 1225 | Sizes}). | 837 | a fixed-size window or too small to ordinarily split. |
| 1226 | 838 | ||
| 1227 | In any case, the value of this variable is assigned to the splits status | 839 | In any case, the value of this variable is assigned to the splits status |
| 1228 | of the new window and, provided old and new window form a new | 840 | of the new window and, provided old and new window form a new |
| @@ -1601,11 +1213,11 @@ function, it calls that function with @var{window} as its sole argument. | |||
| 1601 | @end deffn | 1213 | @end deffn |
| 1602 | 1214 | ||
| 1603 | @deffn Command delete-windows-on &optional buffer-or-name frame | 1215 | @deffn Command delete-windows-on &optional buffer-or-name frame |
| 1604 | This function deletes all windows showing @var{buffer-or-name} and | 1216 | This function deletes all windows showing @var{buffer-or-name}. If |
| 1605 | returns nil. If there are no windows showing @var{buffer-or-name}, it | 1217 | there are no windows showing @var{buffer-or-name}, it does nothing. |
| 1606 | does nothing. The optional argument @var{buffer-or-name} may be a | 1218 | The optional argument @var{buffer-or-name} may be a buffer or the name |
| 1607 | buffer or the name of an existing buffer and defaults to the current | 1219 | of an existing buffer and defaults to the current buffer. Invoking |
| 1608 | buffer. Invoking this command on a minibuffer signals an error. | 1220 | this command on a minibuffer signals an error. |
| 1609 | 1221 | ||
| 1610 | The function @code{delete-windows-on} operates by calling | 1222 | The function @code{delete-windows-on} operates by calling |
| 1611 | @code{delete-window} for each window showing @var{buffer-or-name}. If a | 1223 | @code{delete-window} for each window showing @var{buffer-or-name}. If a |
| @@ -1833,7 +1445,7 @@ This function does not select a window that has a non-@code{nil} | |||
| 1833 | @end deffn | 1445 | @end deffn |
| 1834 | 1446 | ||
| 1835 | The following function returns a copy of the list of windows in the | 1447 | The following function returns a copy of the list of windows in the |
| 1836 | cyclic odering. | 1448 | cyclic ordering. |
| 1837 | 1449 | ||
| 1838 | @defun window-list-1 &optional window &optional minibuf &optional all_frames | 1450 | @defun window-list-1 &optional window &optional minibuf &optional all_frames |
| 1839 | This function returns a list of live windows. The optional arguments | 1451 | This function returns a list of live windows. The optional arguments |
| @@ -1843,7 +1455,7 @@ in the list. See the description of @code{next-window} for details. | |||
| 1843 | The optional argument @var{window} specifies the first window to list | 1455 | The optional argument @var{window} specifies the first window to list |
| 1844 | and defaults to the selected window. If @var{window} is not on the list | 1456 | and defaults to the selected window. If @var{window} is not on the list |
| 1845 | of windows returned, some other window will be listed first but no error | 1457 | of windows returned, some other window will be listed first but no error |
| 1846 | is signalled. | 1458 | is signaled. |
| 1847 | @end defun | 1459 | @end defun |
| 1848 | 1460 | ||
| 1849 | The functions described below use @code{window-list-1} for generating a | 1461 | The functions described below use @code{window-list-1} for generating a |
| @@ -1956,7 +1568,7 @@ This function makes @var{window} display @var{buffer-or-name} and | |||
| 1956 | returns @code{nil}. The argument @var{window} has to denote a live | 1568 | returns @code{nil}. The argument @var{window} has to denote a live |
| 1957 | window and defaults to the selected one. The argument | 1569 | window and defaults to the selected one. The argument |
| 1958 | @var{buffer-or-name} must specify a buffer or the name of an existing | 1570 | @var{buffer-or-name} must specify a buffer or the name of an existing |
| 1959 | buffer. An error is signalled when @var{window} is @dfn{strongly} | 1571 | buffer. An error is signaled when @var{window} is @dfn{strongly} |
| 1960 | dedicated to its buffer (@pxref{Dedicated Windows}) and does not already | 1572 | dedicated to its buffer (@pxref{Dedicated Windows}) and does not already |
| 1961 | display @var{buffer-or-name}. | 1573 | display @var{buffer-or-name}. |
| 1962 | 1574 | ||
| @@ -2043,7 +1655,7 @@ If a window displaying @var{buffer-or-name} is dedicated | |||
| 2043 | (@pxref{Dedicated Windows}) and is not the only window on its frame, | 1655 | (@pxref{Dedicated Windows}) and is not the only window on its frame, |
| 2044 | that window is deleted. If that window is the only window on its frame | 1656 | that window is deleted. If that window is the only window on its frame |
| 2045 | and there are other frames on the frame's terminal, that frame is dealt | 1657 | and there are other frames on the frame's terminal, that frame is dealt |
| 2046 | with by the function spcecified by @code{frame-auto-hide-function} | 1658 | with by the function specified by @code{frame-auto-hide-function} |
| 2047 | (@pxref{Quitting Windows}). Otherwise, the buffer provided by the | 1659 | (@pxref{Quitting Windows}). Otherwise, the buffer provided by the |
| 2048 | function @code{switch-to-prev-buffer} (@pxref{Window History}) is | 1660 | function @code{switch-to-prev-buffer} (@pxref{Window History}) is |
| 2049 | displayed in the window instead. | 1661 | displayed in the window instead. |
| @@ -2163,7 +1775,7 @@ unless @var{norecord} is non-@code{nil}. | |||
| 2163 | 1775 | ||
| 2164 | The command @code{display-buffer} flexibly chooses a window for | 1776 | The command @code{display-buffer} flexibly chooses a window for |
| 2165 | display, and displays a specified buffer in that window. It can be | 1777 | display, and displays a specified buffer in that window. It can be |
| 2166 | called interactively, via the key binding @kbd{C-x 4 o}. It is also | 1778 | called interactively, via the key binding @kbd{C-x 4 C-o}. It is also |
| 2167 | used as a subroutine by many functions and commands, including | 1779 | used as a subroutine by many functions and commands, including |
| 2168 | @code{switch-to-buffer} and @code{pop-to-buffer} (@pxref{Switching | 1780 | @code{switch-to-buffer} and @code{pop-to-buffer} (@pxref{Switching |
| 2169 | Buffers}). | 1781 | Buffers}). |
| @@ -2221,7 +1833,7 @@ The constant @code{display-buffer-fallback-action}. | |||
| 2221 | @noindent | 1833 | @noindent |
| 2222 | Each action function is called in turn, passing the buffer as the | 1834 | Each action function is called in turn, passing the buffer as the |
| 2223 | first argument and the combined action alist as the second argument, | 1835 | first argument and the combined action alist as the second argument, |
| 2224 | until one of the functions returns non-nil. | 1836 | until one of the functions returns non-@code{nil}. |
| 2225 | 1837 | ||
| 2226 | The argument @var{action} can also have a non-@code{nil}, non-list | 1838 | The argument @var{action} can also have a non-@code{nil}, non-list |
| 2227 | value. This has the special meaning that the buffer should be | 1839 | value. This has the special meaning that the buffer should be |
| @@ -2272,7 +1884,7 @@ returns the window if it succeeds, and @code{nil} if it fails. | |||
| 2272 | This function tries to display @var{buffer} in the selected window. | 1884 | This function tries to display @var{buffer} in the selected window. |
| 2273 | It fails if the selected window is a minibuffer window or is dedicated | 1885 | It fails if the selected window is a minibuffer window or is dedicated |
| 2274 | to another buffer (@pxref{Dedicated Windows}). It also fails if | 1886 | to another buffer (@pxref{Dedicated Windows}). It also fails if |
| 2275 | @var{alist} has a non-nil @code{inhibit-same-window} entry. | 1887 | @var{alist} has a non-@code{nil} @code{inhibit-same-window} entry. |
| 2276 | @end defun | 1888 | @end defun |
| 2277 | 1889 | ||
| 2278 | @defun display-buffer-reuse-window buffer alist | 1890 | @defun display-buffer-reuse-window buffer alist |
| @@ -3281,7 +2893,7 @@ This function scrolls the text in the selected window so that point is | |||
| 3281 | displayed at a specified vertical position within the window. It does | 2893 | displayed at a specified vertical position within the window. It does |
| 3282 | not ``move point'' with respect to the text. | 2894 | not ``move point'' with respect to the text. |
| 3283 | 2895 | ||
| 3284 | If @var{count} is a nonnegative number, that puts the line containing | 2896 | If @var{count} is a non-negative number, that puts the line containing |
| 3285 | point @var{count} lines down from the top of the window. If | 2897 | point @var{count} lines down from the top of the window. If |
| 3286 | @var{count} is a negative number, then it counts upward from the | 2898 | @var{count} is a negative number, then it counts upward from the |
| 3287 | bottom of the window, so that @minus{}1 stands for the last usable | 2899 | bottom of the window, so that @minus{}1 stands for the last usable |
diff --git a/doc/misc/auth.texi b/doc/misc/auth.texi index a16da92343e..b64562f6875 100644 --- a/doc/misc/auth.texi +++ b/doc/misc/auth.texi | |||
| @@ -64,13 +64,13 @@ It is a way for multiple applications to share a single configuration | |||
| 64 | 64 | ||
| 65 | @menu | 65 | @menu |
| 66 | * Overview:: Overview of the auth-source library. | 66 | * Overview:: Overview of the auth-source library. |
| 67 | * Help for users:: | 67 | * Help for users:: |
| 68 | * Secret Service API:: | 68 | * Secret Service API:: |
| 69 | * Help for developers:: | 69 | * Help for developers:: |
| 70 | * GnuPG and EasyPG Assistant Configuration:: | 70 | * GnuPG and EasyPG Assistant Configuration:: |
| 71 | * Index:: | 71 | * Index:: |
| 72 | * Function Index:: | 72 | * Function Index:: |
| 73 | * Variable Index:: | 73 | * Variable Index:: |
| 74 | @end menu | 74 | @end menu |
| 75 | @end ifnottex | 75 | @end ifnottex |
| 76 | 76 | ||
| @@ -182,7 +182,7 @@ Here's a mixed example using two sources: | |||
| 182 | If you don't customize @code{auth-sources}, you'll have to live with | 182 | If you don't customize @code{auth-sources}, you'll have to live with |
| 183 | the defaults: any host and any port are looked up in the netrc | 183 | the defaults: any host and any port are looked up in the netrc |
| 184 | file @code{~/.authinfo.gpg}, which is a GnuPG encrypted file | 184 | file @code{~/.authinfo.gpg}, which is a GnuPG encrypted file |
| 185 | (@pxref{GnuPG and EasyPG Assistant Configuration}). | 185 | (@pxref{GnuPG and EasyPG Assistant Configuration}). |
| 186 | 186 | ||
| 187 | If that fails, the unencrypted netrc files @code{~/.authinfo} and | 187 | If that fails, the unencrypted netrc files @code{~/.authinfo} and |
| 188 | @code{~/.netrc} will be used. | 188 | @code{~/.netrc} will be used. |
| @@ -340,7 +340,7 @@ If you are using earlier versions of Emacs, you will need: | |||
| 340 | @end lisp | 340 | @end lisp |
| 341 | 341 | ||
| 342 | If you want your GnuPG passwords to be cached, set up @code{gpg-agent} | 342 | If you want your GnuPG passwords to be cached, set up @code{gpg-agent} |
| 343 | or EasyPG Assitant | 343 | or EasyPG Assistant |
| 344 | (@pxref{Caching Passphrases, , Caching Passphrases, epa}). | 344 | (@pxref{Caching Passphrases, , Caching Passphrases, epa}). |
| 345 | 345 | ||
| 346 | To quick start, here are some questions: | 346 | To quick start, here are some questions: |
diff --git a/doc/misc/gnus.texi b/doc/misc/gnus.texi index 70ed62ddfa9..545306e4dc7 100644 --- a/doc/misc/gnus.texi +++ b/doc/misc/gnus.texi | |||
| @@ -1001,7 +1001,7 @@ press @kbd{^} from the Group buffer to see it. In the Server buffer, | |||
| 1001 | you can press @kbd{RET} on a defined server to see all the groups it | 1001 | you can press @kbd{RET} on a defined server to see all the groups it |
| 1002 | serves (subscribed or not!). You can also add or delete servers, edit | 1002 | serves (subscribed or not!). You can also add or delete servers, edit |
| 1003 | a foreign server's definition, agentize or de-agentize a server, and | 1003 | a foreign server's definition, agentize or de-agentize a server, and |
| 1004 | do many other neat things. @xref{Server Buffer}. | 1004 | do many other neat things. @xref{Server Buffer}. |
| 1005 | @xref{Foreign Groups}. @xref{Agent Basics}. | 1005 | @xref{Foreign Groups}. @xref{Agent Basics}. |
| 1006 | 1006 | ||
| 1007 | @vindex gnus-select-method | 1007 | @vindex gnus-select-method |
| @@ -11805,7 +11805,7 @@ fit these criteria. | |||
| 11805 | 11805 | ||
| 11806 | To use this, make sure that you have @code{w3m} and @code{curl} | 11806 | To use this, make sure that you have @code{w3m} and @code{curl} |
| 11807 | installed. If you have, then Gnus should display @acronym{HTML} | 11807 | installed. If you have, then Gnus should display @acronym{HTML} |
| 11808 | automatically. | 11808 | automatically. |
| 11809 | 11809 | ||
| 11810 | 11810 | ||
| 11811 | 11811 | ||
| @@ -21078,8 +21078,8 @@ as well. | |||
| 21078 | 21078 | ||
| 21079 | This chapter describes tools for searching groups and servers for | 21079 | This chapter describes tools for searching groups and servers for |
| 21080 | articles matching a query and then retrieving those articles. Gnus | 21080 | articles matching a query and then retrieving those articles. Gnus |
| 21081 | provides a simpler mechanism for searching through articles in a summary buffer | 21081 | provides a simpler mechanism for searching through articles in a summary buffer |
| 21082 | to find those matching a pattern. @xref{Searching for Articles}. | 21082 | to find those matching a pattern. @xref{Searching for Articles}. |
| 21083 | 21083 | ||
| 21084 | @menu | 21084 | @menu |
| 21085 | * nnir:: Searching with various engines. | 21085 | * nnir:: Searching with various engines. |
| @@ -21110,7 +21110,7 @@ interface. | |||
| 21110 | 21110 | ||
| 21111 | The @code{nnimap} and @code{gmane} search engines should work with no | 21111 | The @code{nnimap} and @code{gmane} search engines should work with no |
| 21112 | configuration. Other engines require a local index that needs to be | 21112 | configuration. Other engines require a local index that needs to be |
| 21113 | created and maintained outside of Gnus. | 21113 | created and maintained outside of Gnus. |
| 21114 | 21114 | ||
| 21115 | 21115 | ||
| 21116 | @node Basic Usage | 21116 | @node Basic Usage |
| @@ -21150,7 +21150,7 @@ One more thing: individual search engines may have special search | |||
| 21150 | features. You can access these special features by giving a prefix-arg | 21150 | features. You can access these special features by giving a prefix-arg |
| 21151 | to @code{gnus-group-make-nnir-group}. If you are searching multiple | 21151 | to @code{gnus-group-make-nnir-group}. If you are searching multiple |
| 21152 | groups with different search engines you will be prompted for the | 21152 | groups with different search engines you will be prompted for the |
| 21153 | special search features for each engine separately. | 21153 | special search features for each engine separately. |
| 21154 | 21154 | ||
| 21155 | 21155 | ||
| 21156 | @node Setting up nnir | 21156 | @node Setting up nnir |
| @@ -21191,7 +21191,7 @@ named @code{home} you can use | |||
| 21191 | 21191 | ||
| 21192 | @lisp | 21192 | @lisp |
| 21193 | (setq gnus-secondary-select-methods | 21193 | (setq gnus-secondary-select-methods |
| 21194 | '((nnml "home" | 21194 | '((nnml "home" |
| 21195 | (nnimap-address "localhost") | 21195 | (nnimap-address "localhost") |
| 21196 | (nnir-search-engine namazu)))) | 21196 | (nnir-search-engine namazu)))) |
| 21197 | @end lisp | 21197 | @end lisp |
| @@ -21216,9 +21216,9 @@ could change this to | |||
| 21216 | @node The imap Engine | 21216 | @node The imap Engine |
| 21217 | @subsubsection The imap Engine | 21217 | @subsubsection The imap Engine |
| 21218 | 21218 | ||
| 21219 | The @code{imap} engine requires no configuration. | 21219 | The @code{imap} engine requires no configuration. |
| 21220 | 21220 | ||
| 21221 | Queries using the @code{imap} engine follow a simple query language. | 21221 | Queries using the @code{imap} engine follow a simple query language. |
| 21222 | The search is always case-insensitive and supports the following | 21222 | The search is always case-insensitive and supports the following |
| 21223 | features (inspired by the Google search input language): | 21223 | features (inspired by the Google search input language): |
| 21224 | 21224 | ||
| @@ -21231,7 +21231,7 @@ operators must be written with all capital letters to be | |||
| 21231 | recognised. Also preceding a term with a - sign is equivalent to NOT | 21231 | recognised. Also preceding a term with a - sign is equivalent to NOT |
| 21232 | term. | 21232 | term. |
| 21233 | 21233 | ||
| 21234 | @item Automatic AND queries | 21234 | @item Automatic AND queries |
| 21235 | If you specify multiple words then they will be treated as an AND | 21235 | If you specify multiple words then they will be treated as an AND |
| 21236 | expression intended to match all components. | 21236 | expression intended to match all components. |
| 21237 | 21237 | ||
| @@ -21264,7 +21264,7 @@ customize @code{nnir-imap-default-search-key}. For example to use | |||
| 21264 | @node The gmane Engine | 21264 | @node The gmane Engine |
| 21265 | @subsubsection The gmane Engine | 21265 | @subsubsection The gmane Engine |
| 21266 | 21266 | ||
| 21267 | The @code{gmane} engine requires no configuration. | 21267 | The @code{gmane} engine requires no configuration. |
| 21268 | 21268 | ||
| 21269 | Gmane queries follow a simple query language: | 21269 | Gmane queries follow a simple query language: |
| 21270 | 21270 | ||
| @@ -21278,11 +21278,11 @@ recognised. | |||
| 21278 | @item Required and excluded terms | 21278 | @item Required and excluded terms |
| 21279 | + and - can be used to require or exclude terms, e.g. football -american | 21279 | + and - can be used to require or exclude terms, e.g. football -american |
| 21280 | 21280 | ||
| 21281 | @item Unicode handling | 21281 | @item Unicode handling |
| 21282 | The search engine converts all text to utf-8, so searching should work | 21282 | The search engine converts all text to utf-8, so searching should work |
| 21283 | in any language. | 21283 | in any language. |
| 21284 | 21284 | ||
| 21285 | @item Stopwords | 21285 | @item Stopwords |
| 21286 | Common English words (like 'the' and 'a') are ignored by default. You | 21286 | Common English words (like 'the' and 'a') are ignored by default. You |
| 21287 | can override this by prefixing such words with a + (e.g. +the) or | 21287 | can override this by prefixing such words with a + (e.g. +the) or |
| 21288 | enclosing the word in quotes (e.g. "the"). | 21288 | enclosing the word in quotes (e.g. "the"). |
| @@ -21345,7 +21345,7 @@ to get a group name. By default this is @code{$HOME/Mail}. | |||
| 21345 | Using the namazu engine requires creating and maintaining index files. | 21345 | Using the namazu engine requires creating and maintaining index files. |
| 21346 | One directory should contain all the index files, and nnir must be told | 21346 | One directory should contain all the index files, and nnir must be told |
| 21347 | where to find them by setting the @code{nnir-namazu-index-directory} | 21347 | where to find them by setting the @code{nnir-namazu-index-directory} |
| 21348 | variable. | 21348 | variable. |
| 21349 | 21349 | ||
| 21350 | To work correctly the @code{nnir-namazu-remove-prefix} variable must | 21350 | To work correctly the @code{nnir-namazu-remove-prefix} variable must |
| 21351 | also be correct. This is the prefix to remove from each file name | 21351 | also be correct. This is the prefix to remove from each file name |
| @@ -21408,7 +21408,7 @@ this command periodically, say every four hours. | |||
| 21408 | This engine is obsolete. | 21408 | This engine is obsolete. |
| 21409 | 21409 | ||
| 21410 | @node Customizations | 21410 | @node Customizations |
| 21411 | @subsubsection Custimozations | 21411 | @subsubsection Customizations |
| 21412 | 21412 | ||
| 21413 | @table @code | 21413 | @table @code |
| 21414 | 21414 | ||