Mercurial > emacs
comparison lispref/text.texi @ 31079:ace4a0e50572
*** empty log message ***
author | Dave Love <fx@gnu.org> |
---|---|
date | Tue, 22 Aug 2000 18:49:28 +0000 |
parents | ba9cfbfc601e |
children | 3004c92de7b0 |
comparison
equal
deleted
inserted
replaced
31078:540143cd8527 | 31079:ace4a0e50572 |
---|---|
1 @c -*-texinfo-*- | 1 @c -*-texinfo-*- |
2 @c This is part of the GNU Emacs Lisp Reference Manual. | 2 @c This is part of the GNU Emacs Lisp Reference Manual. |
3 @c Copyright (C) 1990, 1991, 1992, 1993, 1994, 1995, 1998, 1999 | 3 @c Copyright (C) 1990, 1991, 1992, 1993, 1994, 1995, 1998, 1999, 2000 |
4 @c Free Software Foundation, Inc. | 4 @c Free Software Foundation, Inc. |
5 @c See the file elisp.texi for copying conditions. | 5 @c See the file elisp.texi for copying conditions. |
6 @setfilename ../info/text | 6 @setfilename ../info/text |
7 @node Text, Non-ASCII Characters, Markers, Top | 7 @node Text, Non-ASCII Characters, Markers, Top |
8 @chapter Text | 8 @chapter Text |
2652 or shorter, higher or lower, wider or narrow, or replaced with an image. | 2652 or shorter, higher or lower, wider or narrow, or replaced with an image. |
2653 @xref{Display Property}. | 2653 @xref{Display Property}. |
2654 | 2654 |
2655 @item help-echo | 2655 @item help-echo |
2656 @kindex help-echo @r{(text property)} | 2656 @kindex help-echo @r{(text property)} |
2657 @anchor{Text help-echo} | |
2657 If text has a string as its @code{help-echo} property, then when you | 2658 If text has a string as its @code{help-echo} property, then when you |
2658 move the mouse onto that text, Emacs displays that string in the echo | 2659 move the mouse onto that text, Emacs displays that string in the echo |
2659 area, or in the tooltip window. This feature is used in the mode line. | 2660 area, or in the tooltip window. |
2660 It is available starting in Emacs 21. | 2661 |
2662 If the value of the @code{help-echo property} is a function, that | |
2663 function is called with three arguments, @var{window}, @var{object} and | |
2664 @var{position} and should return a help string or nil for | |
2665 none. The first argument, @var{window} is the window in which | |
2666 the help was found. The second, @var{object}, is the buffer, overlay or | |
2667 string which had the @code{help-echo} property. The @var{position} | |
2668 argument is as follows: | |
2669 | |
2670 @itemize @bullet{} | |
2671 @item | |
2672 If @var{object} is a buffer, @var{pos} is the position in the buffer | |
2673 where the @code{help-echo} text property was found. | |
2674 @item | |
2675 If @var{object} is an overlay, that overlay has a @code{help-echo} | |
2676 property, and @var{pos} is the position in the overlay's buffer under | |
2677 the mouse. | |
2678 @item | |
2679 If @var{object} is a string (an overlay string or a string displayed | |
2680 with the @code{display} property) @var{pos} is the position in that | |
2681 string under the mouse. | |
2682 @end itemize | |
2683 | |
2684 If the value of the @code{help-echo} property is neither a function nor | |
2685 a string, it is evaluated to obtain a help string. | |
2686 | |
2687 Variable @code{show-help-function} (@pxref{Help display}) provides a | |
2688 hook to alter the way help text is displayed. | |
2689 | |
2690 This feature is used in the mode line and for other active text. It is | |
2691 available starting in Emacs 21. | |
2661 | 2692 |
2662 @item local-map | 2693 @item local-map |
2663 @cindex keymap of character | 2694 @cindex keymap of character |
2664 @kindex local-map @r{(text property)} | 2695 @kindex local-map @r{(text property)} |
2665 You can specify a different keymap for some of the text in a buffer by | 2696 You can specify a different keymap for some of the text in a buffer by |
2776 @defvar inhibit-point-motion-hooks | 2807 @defvar inhibit-point-motion-hooks |
2777 When this variable is non-@code{nil}, @code{point-left} and | 2808 When this variable is non-@code{nil}, @code{point-left} and |
2778 @code{point-entered} hooks are not run, and the @code{intangible} | 2809 @code{point-entered} hooks are not run, and the @code{intangible} |
2779 property has no effect. Do not set this variable globally; bind it with | 2810 property has no effect. Do not set this variable globally; bind it with |
2780 @code{let}. | 2811 @code{let}. |
2812 @end defvar | |
2813 | |
2814 @defvar show-help-function | |
2815 @tindex show-help-function | |
2816 @anchor{Help display} | |
2817 If this variable is non-@code{nil} it specifies a function called to | |
2818 display help strings. These may be @code{help-echo} properties or menu | |
2819 (@pxref{Simple Menu Items}, @pxref{Extended Menu Items}) or tool bar | |
2820 (@pxref{Tool Bar}) help strings. The specified function is called with | |
2821 one argument, the help string to display. Tooltip mode | |
2822 (@pxref{(emacs)Tooltips}) provides an example. | |
2781 @end defvar | 2823 @end defvar |
2782 | 2824 |
2783 @node Format Properties | 2825 @node Format Properties |
2784 @subsection Formatted Text Properties | 2826 @subsection Formatted Text Properties |
2785 | 2827 |
3558 are in use. When the after-change hooks are ultimately called, the | 3600 are in use. When the after-change hooks are ultimately called, the |
3559 arguments specify a portion of the buffer including all of the changes | 3601 arguments specify a portion of the buffer including all of the changes |
3560 made within the @code{combine-after-change-calls} body. | 3602 made within the @code{combine-after-change-calls} body. |
3561 | 3603 |
3562 @strong{Warning:} You must not alter the values of | 3604 @strong{Warning:} You must not alter the values of |
3563 @code{after-change-functions} and @code{after-change-function} within | 3605 @code{after-change-functions} within |
3564 the body of a @code{combine-after-change-calls} form. | 3606 the body of a @code{combine-after-change-calls} form. |
3565 | 3607 |
3566 @strong{Note:} If the changes you combine occur in widely scattered | 3608 @strong{Note:} If the changes you combine occur in widely scattered |
3567 parts of the buffer, this will still work, but it is not advisable, | 3609 parts of the buffer, this will still work, but it is not advisable, |
3568 because it may lead to inefficient behavior for some change hook | 3610 because it may lead to inefficient behavior for some change hook |
3569 functions. | 3611 functions. |
3570 @end defmac | 3612 @end defmac |
3571 | 3613 |
3572 @defvar before-change-function | 3614 The two variables above are temporarily bound to @code{nil} during the |
3573 This obsolete variable holds one function to call before any buffer | |
3574 modification (or @code{nil} for no function). It is called just like | |
3575 the functions in @code{before-change-functions}. | |
3576 @end defvar | |
3577 | |
3578 @defvar after-change-function | |
3579 This obsolete variable holds one function to call after any buffer modification | |
3580 (or @code{nil} for no function). It is called just like the functions in | |
3581 @code{after-change-functions}. | |
3582 @end defvar | |
3583 | |
3584 The four variables above are temporarily bound to @code{nil} during the | |
3585 time that any of these functions is running. This means that if one of | 3615 time that any of these functions is running. This means that if one of |
3586 these functions changes the buffer, that change won't run these | 3616 these functions changes the buffer, that change won't run these |
3587 functions. If you do want a hook function to make changes that run | 3617 functions. If you do want a hook function to make changes that run |
3588 these functions, make it bind these variables back to their usual | 3618 these functions, make it bind these variables back to their usual |
3589 values. | 3619 values. |