comparison lispref/display.texi @ 71730:cd88ff0d05f5

(Attribute Functions): Move paragraph about compatibility with Emacs < 21.
author Richard M. Stallman <rms@gnu.org>
date Sun, 09 Jul 2006 02:06:34 +0000
parents fc057bd26f1f
children 5df595f18fa2
comparison
equal deleted inserted replaced
71729:9f431e2269e4 71730:cd88ff0d05f5
2104 (face-attribute 'bold :weight) 2104 (face-attribute 'bold :weight)
2105 @result{} bold 2105 @result{} bold
2106 @end example 2106 @end example
2107 @end defun 2107 @end defun
2108 2108
2109 The functions above did not exist before Emacs 21. For compatibility
2110 with older Emacs versions, you can use the following functions to set
2111 and examine the face attributes which existed in those versions.
2112
2113 @defun face-attribute-relative-p attribute value 2109 @defun face-attribute-relative-p attribute value
2114 This function returns non-@code{nil} if @var{value}, when used as the 2110 This function returns non-@code{nil} if @var{value}, when used as the
2115 value of the face attribute @var{attribute}, is relative. This means 2111 value of the face attribute @var{attribute}, is relative. This means
2116 it would modify, rather than completely override, any value that comes 2112 it would modify, rather than completely override, any value that comes
2117 from a subsequent face in the face list or that is inherited from 2113 from a subsequent face in the face list or that is inherited from
2133 If @var{value1} is a relative value for the face attribute 2129 If @var{value1} is a relative value for the face attribute
2134 @var{attribute}, returns it merged with the underlying value 2130 @var{attribute}, returns it merged with the underlying value
2135 @var{value2}; otherwise, if @var{value1} is an absolute value for the 2131 @var{value2}; otherwise, if @var{value1} is an absolute value for the
2136 face attribute @var{attribute}, returns @var{value1} unchanged. 2132 face attribute @var{attribute}, returns @var{value1} unchanged.
2137 @end defun 2133 @end defun
2134
2135 The functions above did not exist before Emacs 21. For compatibility
2136 with older Emacs versions, you can use the following functions to set
2137 and examine the face attributes which existed in those versions.
2138 2138
2139 @defun set-face-foreground face color &optional frame 2139 @defun set-face-foreground face color &optional frame
2140 @defunx set-face-background face color &optional frame 2140 @defunx set-face-background face color &optional frame
2141 These functions set the foreground (or background, respectively) color 2141 These functions set the foreground (or background, respectively) color
2142 of face @var{face} to @var{color}. The argument @var{color} should be a 2142 of face @var{face} to @var{color}. The argument @var{color} should be a