comparison src/buffer.c @ 40108:6084dfa5f85d

Reindent DEFUNs and DEFVARs woth doc: keywords.
author Pavel Jan?k <Pavel@Janik.cz>
date Sun, 21 Oct 2001 08:49:43 +0000
parents eac4e9ae201c
children 7c28809db274
comparison
equal deleted inserted replaced
40107:d3cc7dd5d75a 40108:6084dfa5f85d
722 /* We split this away from generate-new-buffer, because rename-buffer 722 /* We split this away from generate-new-buffer, because rename-buffer
723 and set-visited-file-name ought to be able to use this to really 723 and set-visited-file-name ought to be able to use this to really
724 rename the buffer properly. */ 724 rename the buffer properly. */
725 725
726 DEFUN ("generate-new-buffer-name", Fgenerate_new_buffer_name, Sgenerate_new_buffer_name, 726 DEFUN ("generate-new-buffer-name", Fgenerate_new_buffer_name, Sgenerate_new_buffer_name,
727 1, 2, 0, 727 1, 2, 0,
728 doc: /* Return a string that is the name of no existing buffer based on NAME. 728 doc: /* Return a string that is the name of no existing buffer based on NAME.
729 If there is no live buffer named NAME, then return NAME. 729 If there is no live buffer named NAME, then return NAME.
730 Otherwise modify name by appending `<NUMBER>', incrementing NUMBER 730 Otherwise modify name by appending `<NUMBER>', incrementing NUMBER
731 until an unused name is found, and then return that name. 731 until an unused name is found, and then return that name.
732 Optional second argument IGNORE specifies a name that is okay to use 732 Optional second argument IGNORE specifies a name that is okay to use
807 XSETBUFFER (base_buffer, base); 807 XSETBUFFER (base_buffer, base);
808 return base_buffer; 808 return base_buffer;
809 } 809 }
810 810
811 DEFUN ("buffer-local-variables", Fbuffer_local_variables, 811 DEFUN ("buffer-local-variables", Fbuffer_local_variables,
812 Sbuffer_local_variables, 0, 1, 0, 812 Sbuffer_local_variables, 0, 1, 0,
813 doc: /* Return an alist of variables that are buffer-local in BUFFER. 813 doc: /* Return an alist of variables that are buffer-local in BUFFER.
814 Most elements look like (SYMBOL . VALUE), describing one variable. 814 Most elements look like (SYMBOL . VALUE), describing one variable.
815 For a symbol that is locally unbound, just the symbol appears in the value. 815 For a symbol that is locally unbound, just the symbol appears in the value.
816 Note that storing new VALUEs in these elements doesn't change the variables. 816 Note that storing new VALUEs in these elements doesn't change the variables.
817 No argument or nil as argument means use current buffer as BUFFER. */) 817 No argument or nil as argument means use current buffer as BUFFER. */)
879 return result; 879 return result;
880 } 880 }
881 881
882 882
883 DEFUN ("buffer-modified-p", Fbuffer_modified_p, Sbuffer_modified_p, 883 DEFUN ("buffer-modified-p", Fbuffer_modified_p, Sbuffer_modified_p,
884 0, 1, 0, 884 0, 1, 0,
885 doc: /* Return t if BUFFER was modified since its file was last read or saved. 885 doc: /* Return t if BUFFER was modified since its file was last read or saved.
886 No argument or nil as argument means use current buffer as BUFFER. */) 886 No argument or nil as argument means use current buffer as BUFFER. */)
887 (buffer) 887 (buffer)
888 register Lisp_Object buffer; 888 register Lisp_Object buffer;
889 { 889 {
898 898
899 return BUF_SAVE_MODIFF (buf) < BUF_MODIFF (buf) ? Qt : Qnil; 899 return BUF_SAVE_MODIFF (buf) < BUF_MODIFF (buf) ? Qt : Qnil;
900 } 900 }
901 901
902 DEFUN ("set-buffer-modified-p", Fset_buffer_modified_p, Sset_buffer_modified_p, 902 DEFUN ("set-buffer-modified-p", Fset_buffer_modified_p, Sset_buffer_modified_p,
903 1, 1, 0, 903 1, 1, 0,
904 doc: /* Mark current buffer as modified or unmodified according to FLAG. 904 doc: /* Mark current buffer as modified or unmodified according to FLAG.
905 A non-nil FLAG means mark the buffer modified. */) 905 A non-nil FLAG means mark the buffer modified. */)
906 (flag) 906 (flag)
907 register Lisp_Object flag; 907 register Lisp_Object flag;
908 { 908 {
979 SAVE_MODIFF = NILP (flag) ? MODIFF : 0; 979 SAVE_MODIFF = NILP (flag) ? MODIFF : 0;
980 return flag; 980 return flag;
981 } 981 }
982 982
983 DEFUN ("buffer-modified-tick", Fbuffer_modified_tick, Sbuffer_modified_tick, 983 DEFUN ("buffer-modified-tick", Fbuffer_modified_tick, Sbuffer_modified_tick,
984 0, 1, 0, 984 0, 1, 0,
985 doc: /* Return BUFFER's tick counter, incremented for each change in text. 985 doc: /* Return BUFFER's tick counter, incremented for each change in text.
986 Each buffer has a tick counter which is incremented each time the text in 986 Each buffer has a tick counter which is incremented each time the text in
987 that buffer is changed. It wraps around occasionally. 987 that buffer is changed. It wraps around occasionally.
988 No argument or nil as argument means use current buffer as BUFFER. */) 988 No argument or nil as argument means use current buffer as BUFFER. */)
989 (buffer) 989 (buffer)
2206 2206
2207 return flag; 2207 return flag;
2208 } 2208 }
2209 2209
2210 DEFUN ("kill-all-local-variables", Fkill_all_local_variables, Skill_all_local_variables, 2210 DEFUN ("kill-all-local-variables", Fkill_all_local_variables, Skill_all_local_variables,
2211 0, 0, 0, 2211 0, 0, 0,
2212 doc: /* Switch to Fundamental mode by killing current buffer's local variables. 2212 doc: /* Switch to Fundamental mode by killing current buffer's local variables.
2213 Most local variable bindings are eliminated so that the default values 2213 Most local variable bindings are eliminated so that the default values
2214 become effective once more. Also, the syntax table is set from 2214 become effective once more. Also, the syntax table is set from
2215 `standard-syntax-table', the local keymap is set to nil, 2215 `standard-syntax-table', the local keymap is set to nil,
2216 and the abbrev table from `fundamental-mode-abbrev-table'. 2216 and the abbrev table from `fundamental-mode-abbrev-table'.
3696 xfree (overlay_vec); 3696 xfree (overlay_vec);
3697 return result; 3697 return result;
3698 } 3698 }
3699 3699
3700 DEFUN ("next-overlay-change", Fnext_overlay_change, Snext_overlay_change, 3700 DEFUN ("next-overlay-change", Fnext_overlay_change, Snext_overlay_change,
3701 1, 1, 0, 3701 1, 1, 0,
3702 doc: /* Return the next position after POS where an overlay starts or ends. 3702 doc: /* Return the next position after POS where an overlay starts or ends.
3703 If there are no more overlay boundaries after POS, return (point-max). */) 3703 If there are no more overlay boundaries after POS, return (point-max). */)
3704 (pos) 3704 (pos)
3705 Lisp_Object pos; 3705 Lisp_Object pos;
3706 { 3706 {
5028 &buffer_defaults.extra_line_spacing, 5028 &buffer_defaults.extra_line_spacing,
5029 doc: /* Default value of `line-spacing' for buffers that don't override it. 5029 doc: /* Default value of `line-spacing' for buffers that don't override it.
5030 This is the same as (default-value 'line-spacing). */); 5030 This is the same as (default-value 'line-spacing). */);
5031 5031
5032 DEFVAR_LISP_NOPRO ("default-abbrev-mode", 5032 DEFVAR_LISP_NOPRO ("default-abbrev-mode",
5033 &buffer_defaults.abbrev_mode, 5033 &buffer_defaults.abbrev_mode,
5034 doc: /* Default value of `abbrev-mode' for buffers that do not override it. 5034 doc: /* Default value of `abbrev-mode' for buffers that do not override it.
5035 This is the same as (default-value 'abbrev-mode). */); 5035 This is the same as (default-value 'abbrev-mode). */);
5036 5036
5037 DEFVAR_LISP_NOPRO ("default-ctl-arrow", 5037 DEFVAR_LISP_NOPRO ("default-ctl-arrow",
5038 &buffer_defaults.ctl_arrow, 5038 &buffer_defaults.ctl_arrow,
5039 doc: /* Default value of `ctl-arrow' for buffers that do not override it. 5039 doc: /* Default value of `ctl-arrow' for buffers that do not override it.
5040 This is the same as (default-value 'ctl-arrow). */); 5040 This is the same as (default-value 'ctl-arrow). */);
5041 5041
5042 DEFVAR_LISP_NOPRO ("default-direction-reversed", 5042 DEFVAR_LISP_NOPRO ("default-direction-reversed",
5043 &buffer_defaults.direction_reversed, 5043 &buffer_defaults.direction_reversed,
5044 doc: /* Default value of `direction_reversed' for buffers that do not override it. 5044 doc: /* Default value of `direction_reversed' for buffers that do not override it.
5045 This is the same as (default-value 'direction-reversed). */); 5045 This is the same as (default-value 'direction-reversed). */);
5046 5046
5047 DEFVAR_LISP_NOPRO ("default-enable-multibyte-characters", 5047 DEFVAR_LISP_NOPRO ("default-enable-multibyte-characters",
5048 &buffer_defaults.enable_multibyte_characters, 5048 &buffer_defaults.enable_multibyte_characters,
5049 doc: /* *Default value of `enable-multibyte-characters' for buffers not overriding it. 5049 doc: /* *Default value of `enable-multibyte-characters' for buffers not overriding it.
5050 This is the same as (default-value 'enable-multibyte-characters). */); 5050 This is the same as (default-value 'enable-multibyte-characters). */);
5051 5051
5052 DEFVAR_LISP_NOPRO ("default-buffer-file-coding-system", 5052 DEFVAR_LISP_NOPRO ("default-buffer-file-coding-system",
5053 &buffer_defaults.buffer_file_coding_system, 5053 &buffer_defaults.buffer_file_coding_system,
5054 doc: /* Default value of `buffer-file-coding-system' for buffers not overriding it. 5054 doc: /* Default value of `buffer-file-coding-system' for buffers not overriding it.
5055 This is the same as (default-value 'buffer-file-coding-system). */); 5055 This is the same as (default-value 'buffer-file-coding-system). */);
5056 5056
5057 DEFVAR_LISP_NOPRO ("default-truncate-lines", 5057 DEFVAR_LISP_NOPRO ("default-truncate-lines",
5058 &buffer_defaults.truncate_lines, 5058 &buffer_defaults.truncate_lines,
5059 doc: /* Default value of `truncate-lines' for buffers that do not override it. 5059 doc: /* Default value of `truncate-lines' for buffers that do not override it.
5060 This is the same as (default-value 'truncate-lines). */); 5060 This is the same as (default-value 'truncate-lines). */);
5061 5061
5062 DEFVAR_LISP_NOPRO ("default-fill-column", 5062 DEFVAR_LISP_NOPRO ("default-fill-column",
5063 &buffer_defaults.fill_column, 5063 &buffer_defaults.fill_column,
5064 doc: /* Default value of `fill-column' for buffers that do not override it. 5064 doc: /* Default value of `fill-column' for buffers that do not override it.
5065 This is the same as (default-value 'fill-column). */); 5065 This is the same as (default-value 'fill-column). */);
5066 5066
5067 DEFVAR_LISP_NOPRO ("default-left-margin", 5067 DEFVAR_LISP_NOPRO ("default-left-margin",
5068 &buffer_defaults.left_margin, 5068 &buffer_defaults.left_margin,
5069 doc: /* Default value of `left-margin' for buffers that do not override it. 5069 doc: /* Default value of `left-margin' for buffers that do not override it.
5070 This is the same as (default-value 'left-margin). */); 5070 This is the same as (default-value 'left-margin). */);
5071 5071
5072 DEFVAR_LISP_NOPRO ("default-tab-width", 5072 DEFVAR_LISP_NOPRO ("default-tab-width",
5073 &buffer_defaults.tab_width, 5073 &buffer_defaults.tab_width,
5074 doc: /* Default value of `tab-width' for buffers that do not override it. 5074 doc: /* Default value of `tab-width' for buffers that do not override it.
5075 This is the same as (default-value 'tab-width). */); 5075 This is the same as (default-value 'tab-width). */);
5076 5076
5077 DEFVAR_LISP_NOPRO ("default-case-fold-search", 5077 DEFVAR_LISP_NOPRO ("default-case-fold-search",
5078 &buffer_defaults.case_fold_search, 5078 &buffer_defaults.case_fold_search,
5079 doc: /* Default value of `case-fold-search' for buffers that don't override it. 5079 doc: /* Default value of `case-fold-search' for buffers that don't override it.
5080 This is the same as (default-value 'case-fold-search). */); 5080 This is the same as (default-value 'case-fold-search). */);
5081 5081
5082 #ifdef DOS_NT 5082 #ifdef DOS_NT
5083 DEFVAR_LISP_NOPRO ("default-buffer-file-type", 5083 DEFVAR_LISP_NOPRO ("default-buffer-file-type",
5084 &buffer_defaults.buffer_file_type, 5084 &buffer_defaults.buffer_file_type,
5085 doc: /* Default file type for buffers that do not override it. 5085 doc: /* Default file type for buffers that do not override it.
5086 This is the same as (default-value 'buffer-file-type). 5086 This is the same as (default-value 'buffer-file-type).
5087 The file type is nil for text, t for binary. */); 5087 The file type is nil for text, t for binary. */);
5088 #endif 5088 #endif
5089 5089
5090 DEFVAR_LISP_NOPRO ("default-left-margin-width", 5090 DEFVAR_LISP_NOPRO ("default-left-margin-width",
5091 &buffer_defaults.left_margin_width, 5091 &buffer_defaults.left_margin_width,
5092 doc: /* Default value of `left-margin-width' for buffers that don't override it. 5092 doc: /* Default value of `left-margin-width' for buffers that don't override it.
5093 This is the same as (default-value 'left-margin-width). */); 5093 This is the same as (default-value 'left-margin-width). */);
5094 5094
5095 DEFVAR_LISP_NOPRO ("default-right-margin-width", 5095 DEFVAR_LISP_NOPRO ("default-right-margin-width",
5096 &buffer_defaults.right_margin_width, 5096 &buffer_defaults.right_margin_width,
5097 doc: /* Default value of `right_margin_width' for buffers that don't override it. 5097 doc: /* Default value of `right_margin_width' for buffers that don't override it.
5098 This is the same as (default-value 'right-margin-width). */); 5098 This is the same as (default-value 'right-margin-width). */);
5099 5099
5100 DEFVAR_LISP_NOPRO ("default-indicate-empty-lines", 5100 DEFVAR_LISP_NOPRO ("default-indicate-empty-lines",
5101 &buffer_defaults.indicate_empty_lines, 5101 &buffer_defaults.indicate_empty_lines,
5102 doc: /* Default value of `indicate-empty-lines' for buffers that don't override it. 5102 doc: /* Default value of `indicate-empty-lines' for buffers that don't override it.
5103 This is the same as (default-value 'indicate-empty-lines). */); 5103 This is the same as (default-value 'indicate-empty-lines). */);
5104 5104
5105 DEFVAR_LISP_NOPRO ("default-scroll-up-aggressively", 5105 DEFVAR_LISP_NOPRO ("default-scroll-up-aggressively",
5106 &buffer_defaults.scroll_up_aggressively, 5106 &buffer_defaults.scroll_up_aggressively,
5107 doc: /* Default value of `scroll-up-aggressively' for buffers that 5107 doc: /* Default value of `scroll-up-aggressively' for buffers that
5108 don't override it. This is the same as (default-value 5108 don't override it. This is the same as (default-value
5109 'scroll-up-aggressively). */); 5109 'scroll-up-aggressively). */);
5110 5110
5111 DEFVAR_LISP_NOPRO ("default-scroll-down-aggressively", 5111 DEFVAR_LISP_NOPRO ("default-scroll-down-aggressively",
5112 &buffer_defaults.scroll_down_aggressively, 5112 &buffer_defaults.scroll_down_aggressively,
5113 doc: /* Default value of `scroll-down-aggressively' for buffers that 5113 doc: /* Default value of `scroll-down-aggressively' for buffers that
5114 don't override it. This is the same as (default-value 5114 don't override it. This is the same as (default-value
5115 'scroll-down-aggressively). */); 5115 'scroll-down-aggressively). */);
5116 5116
5117 DEFVAR_PER_BUFFER ("header-line-format", 5117 DEFVAR_PER_BUFFER ("header-line-format",
5118 &current_buffer->header_line_format, 5118 &current_buffer->header_line_format,
5119 Qnil, 5119 Qnil,
5120 doc: /* Analogous to `mode-line-format', but for the mode line that can be 5120 doc: /* Analogous to `mode-line-format', but for the mode line that can be
5121 displayed at the top of a window. */); 5121 displayed at the top of a window. */);
5122 5122
5123 DEFVAR_PER_BUFFER ("mode-line-format", &current_buffer->mode_line_format, 5123 DEFVAR_PER_BUFFER ("mode-line-format", &current_buffer->mode_line_format,
5124 Qnil, 5124 Qnil,
5125 doc: /* Template for displaying mode line for current buffer. 5125 doc: /* Template for displaying mode line for current buffer.
5126 Each buffer has its own value of this variable. 5126 Each buffer has its own value of this variable.
5127 Value may be nil, a string, a symbol or a list or cons cell. 5127 Value may be nil, a string, a symbol or a list or cons cell.
5128 A value of nil means don't display a mode line. 5128 A value of nil means don't display a mode line.
5129 For a symbol, its value is used (but it is ignored if t or nil). 5129 For a symbol, its value is used (but it is ignored if t or nil).
5130 A string appearing directly as the value of a symbol is processed verbatim 5130 A string appearing directly as the value of a symbol is processed verbatim
5162 %[ -- print one [ for each recursive editing level. %] similar. 5162 %[ -- print one [ for each recursive editing level. %] similar.
5163 %% -- print %. %- -- print infinitely many dashes. 5163 %% -- print %. %- -- print infinitely many dashes.
5164 Decimal digits after the % specify field width to which to pad. */); 5164 Decimal digits after the % specify field width to which to pad. */);
5165 5165
5166 DEFVAR_LISP_NOPRO ("default-major-mode", &buffer_defaults.major_mode, 5166 DEFVAR_LISP_NOPRO ("default-major-mode", &buffer_defaults.major_mode,
5167 doc: /* *Major mode for new buffers. Defaults to `fundamental-mode'. 5167 doc: /* *Major mode for new buffers. Defaults to `fundamental-mode'.
5168 nil here means use current buffer's major mode. */); 5168 nil here means use current buffer's major mode. */);
5169 5169
5170 DEFVAR_PER_BUFFER ("major-mode", &current_buffer->major_mode, 5170 DEFVAR_PER_BUFFER ("major-mode", &current_buffer->major_mode,
5171 make_number (Lisp_Symbol), 5171 make_number (Lisp_Symbol),
5172 doc: /* Symbol for current buffer's major mode. */); 5172 doc: /* Symbol for current buffer's major mode. */);
5173 5173
5174 DEFVAR_PER_BUFFER ("mode-name", &current_buffer->mode_name, 5174 DEFVAR_PER_BUFFER ("mode-name", &current_buffer->mode_name,
5175 make_number (Lisp_String), 5175 make_number (Lisp_String),
5176 doc: /* Pretty name of current buffer's major mode (a string). */); 5176 doc: /* Pretty name of current buffer's major mode (a string). */);
5177 5177
5178 DEFVAR_PER_BUFFER ("abbrev-mode", &current_buffer->abbrev_mode, Qnil, 5178 DEFVAR_PER_BUFFER ("abbrev-mode", &current_buffer->abbrev_mode, Qnil,
5179 doc: /* Non-nil turns on automatic expansion of abbrevs as they are inserted. */); 5179 doc: /* Non-nil turns on automatic expansion of abbrevs as they are inserted. */);
5180 5180
5181 DEFVAR_PER_BUFFER ("case-fold-search", &current_buffer->case_fold_search, 5181 DEFVAR_PER_BUFFER ("case-fold-search", &current_buffer->case_fold_search,
5182 Qnil, 5182 Qnil,
5183 doc: /* *Non-nil if searches and matches should ignore case. */); 5183 doc: /* *Non-nil if searches and matches should ignore case. */);
5184 5184
5185 DEFVAR_PER_BUFFER ("fill-column", &current_buffer->fill_column, 5185 DEFVAR_PER_BUFFER ("fill-column", &current_buffer->fill_column,
5186 make_number (Lisp_Int), 5186 make_number (Lisp_Int),
5187 doc: /* *Column beyond which automatic line-wrapping should happen. */); 5187 doc: /* *Column beyond which automatic line-wrapping should happen. */);
5188 5188
5189 DEFVAR_PER_BUFFER ("left-margin", &current_buffer->left_margin, 5189 DEFVAR_PER_BUFFER ("left-margin", &current_buffer->left_margin,
5190 make_number (Lisp_Int), 5190 make_number (Lisp_Int),
5191 doc: /* *Column for the default indent-line-function to indent to. 5191 doc: /* *Column for the default indent-line-function to indent to.
5192 Linefeed indents to this column in Fundamental mode. */); 5192 Linefeed indents to this column in Fundamental mode. */);
5193 5193
5194 DEFVAR_PER_BUFFER ("tab-width", &current_buffer->tab_width, 5194 DEFVAR_PER_BUFFER ("tab-width", &current_buffer->tab_width,
5195 make_number (Lisp_Int), 5195 make_number (Lisp_Int),
5196 doc: /* *Distance between tab stops (for display of tab characters), in columns. */); 5196 doc: /* *Distance between tab stops (for display of tab characters), in columns. */);
5197 5197
5198 DEFVAR_PER_BUFFER ("ctl-arrow", &current_buffer->ctl_arrow, Qnil, 5198 DEFVAR_PER_BUFFER ("ctl-arrow", &current_buffer->ctl_arrow, Qnil,
5199 doc: /* *Non-nil means display control chars with uparrow. 5199 doc: /* *Non-nil means display control chars with uparrow.
5200 A value of nil means use backslash and octal digits. 5200 A value of nil means use backslash and octal digits.
5201 This variable does not apply to characters whose display is specified 5201 This variable does not apply to characters whose display is specified
5202 in the current display table (if there is one). */); 5202 in the current display table (if there is one). */);
5203 5203
5204 DEFVAR_PER_BUFFER ("enable-multibyte-characters", 5204 DEFVAR_PER_BUFFER ("enable-multibyte-characters",
5205 &current_buffer->enable_multibyte_characters, 5205 &current_buffer->enable_multibyte_characters,
5206 make_number (-1), 5206 make_number (-1),
5207 doc: /* Non-nil means the buffer contents are regarded as multi-byte characters. 5207 doc: /* Non-nil means the buffer contents are regarded as multi-byte characters.
5208 Otherwise they are regarded as unibyte. This affects the display, 5208 Otherwise they are regarded as unibyte. This affects the display,
5209 file I/O and the behavior of various editing commands. 5209 file I/O and the behavior of various editing commands.
5210 5210
5211 This variable is buffer-local but you cannot set it directly; 5211 This variable is buffer-local but you cannot set it directly;
5212 use the function `set-buffer-multibyte' to change a buffer's representation. 5212 use the function `set-buffer-multibyte' to change a buffer's representation.
5214 See also variable `default-enable-multibyte-characters' and Info node 5214 See also variable `default-enable-multibyte-characters' and Info node
5215 `(elisp)Text Representations'. */); 5215 `(elisp)Text Representations'. */);
5216 5216
5217 DEFVAR_PER_BUFFER ("buffer-file-coding-system", 5217 DEFVAR_PER_BUFFER ("buffer-file-coding-system",
5218 &current_buffer->buffer_file_coding_system, Qnil, 5218 &current_buffer->buffer_file_coding_system, Qnil,
5219 doc: /* Coding system to be used for encoding the buffer contents on saving. 5219 doc: /* Coding system to be used for encoding the buffer contents on saving.
5220 This variable applies to saving the buffer, and also to `write-region' 5220 This variable applies to saving the buffer, and also to `write-region'
5221 and other functions that use `write-region'. 5221 and other functions that use `write-region'.
5222 It does not apply to sending output to subprocesses, however. 5222 It does not apply to sending output to subprocesses, however.
5223 5223
5224 If this is nil, the buffer is saved without any code conversion 5224 If this is nil, the buffer is saved without any code conversion
5229 5229
5230 This variable is never applied to a way of decoding a file while reading it. */); 5230 This variable is never applied to a way of decoding a file while reading it. */);
5231 5231
5232 DEFVAR_PER_BUFFER ("direction-reversed", &current_buffer->direction_reversed, 5232 DEFVAR_PER_BUFFER ("direction-reversed", &current_buffer->direction_reversed,
5233 Qnil, 5233 Qnil,
5234 doc: /* *Non-nil means lines in the buffer are displayed right to left. */); 5234 doc: /* *Non-nil means lines in the buffer are displayed right to left. */);
5235 5235
5236 DEFVAR_PER_BUFFER ("truncate-lines", &current_buffer->truncate_lines, Qnil, 5236 DEFVAR_PER_BUFFER ("truncate-lines", &current_buffer->truncate_lines, Qnil,
5237 doc: /* *Non-nil means do not display continuation lines; 5237 doc: /* *Non-nil means do not display continuation lines;
5238 give each line of text one screen line. 5238 give each line of text one screen line.
5239 5239
5240 Note that this is overridden by the variable 5240 Note that this is overridden by the variable
5241 `truncate-partial-width-windows' if that variable is non-nil 5241 `truncate-partial-width-windows' if that variable is non-nil
5242 and this buffer is not full-frame width. */); 5242 and this buffer is not full-frame width. */);
5243 5243
5244 #ifdef DOS_NT 5244 #ifdef DOS_NT
5245 DEFVAR_PER_BUFFER ("buffer-file-type", &current_buffer->buffer_file_type, 5245 DEFVAR_PER_BUFFER ("buffer-file-type", &current_buffer->buffer_file_type,
5246 Qnil, 5246 Qnil,
5247 doc: /* Non-nil if the visited file is a binary file. 5247 doc: /* Non-nil if the visited file is a binary file.
5248 This variable is meaningful on MS-DOG and Windows NT. 5248 This variable is meaningful on MS-DOG and Windows NT.
5249 On those systems, it is automatically local in every buffer. 5249 On those systems, it is automatically local in every buffer.
5250 On other systems, this variable is normally always nil. */); 5250 On other systems, this variable is normally always nil. */);
5251 #endif 5251 #endif
5252 5252
5253 DEFVAR_PER_BUFFER ("default-directory", &current_buffer->directory, 5253 DEFVAR_PER_BUFFER ("default-directory", &current_buffer->directory,
5254 make_number (Lisp_String), 5254 make_number (Lisp_String),
5255 doc: /* Name of default directory of current buffer. Should end with slash. 5255 doc: /* Name of default directory of current buffer. Should end with slash.
5256 To interactively change the default directory, use command `cd'. */); 5256 To interactively change the default directory, use command `cd'. */);
5257 5257
5258 DEFVAR_PER_BUFFER ("auto-fill-function", &current_buffer->auto_fill_function, 5258 DEFVAR_PER_BUFFER ("auto-fill-function", &current_buffer->auto_fill_function,
5259 Qnil, 5259 Qnil,
5260 doc: /* Function called (if non-nil) to perform auto-fill. 5260 doc: /* Function called (if non-nil) to perform auto-fill.
5261 It is called after self-inserting any character specified in 5261 It is called after self-inserting any character specified in
5262 the `auto-fill-chars' table. 5262 the `auto-fill-chars' table.
5263 NOTE: This variable is not a hook; 5263 NOTE: This variable is not a hook;
5264 its value may not be a list of functions. */); 5264 its value may not be a list of functions. */);
5265 5265
5266 DEFVAR_PER_BUFFER ("buffer-file-name", &current_buffer->filename, 5266 DEFVAR_PER_BUFFER ("buffer-file-name", &current_buffer->filename,
5267 make_number (Lisp_String), 5267 make_number (Lisp_String),
5268 doc: /* Name of file visited in current buffer, or nil if not visiting a file. */); 5268 doc: /* Name of file visited in current buffer, or nil if not visiting a file. */);
5269 5269
5270 DEFVAR_PER_BUFFER ("buffer-file-truename", &current_buffer->file_truename, 5270 DEFVAR_PER_BUFFER ("buffer-file-truename", &current_buffer->file_truename,
5271 make_number (Lisp_String), 5271 make_number (Lisp_String),
5272 doc: /* Abbreviated truename of file visited in current buffer, or nil if none. 5272 doc: /* Abbreviated truename of file visited in current buffer, or nil if none.
5273 The truename of a file is calculated by `file-truename' 5273 The truename of a file is calculated by `file-truename'
5274 and then abbreviated with `abbreviate-file-name'. */); 5274 and then abbreviated with `abbreviate-file-name'. */);
5275 5275
5276 DEFVAR_PER_BUFFER ("buffer-auto-save-file-name", 5276 DEFVAR_PER_BUFFER ("buffer-auto-save-file-name",
5277 &current_buffer->auto_save_file_name, 5277 &current_buffer->auto_save_file_name,
5278 make_number (Lisp_String), 5278 make_number (Lisp_String),
5279 doc: /* Name of file for auto-saving current buffer, 5279 doc: /* Name of file for auto-saving current buffer,
5280 or nil if buffer should not be auto-saved. */); 5280 or nil if buffer should not be auto-saved. */);
5281 5281
5282 DEFVAR_PER_BUFFER ("buffer-read-only", &current_buffer->read_only, Qnil, 5282 DEFVAR_PER_BUFFER ("buffer-read-only", &current_buffer->read_only, Qnil,
5283 doc: /* Non-nil if this buffer is read-only. */); 5283 doc: /* Non-nil if this buffer is read-only. */);
5284 5284
5285 DEFVAR_PER_BUFFER ("buffer-backed-up", &current_buffer->backed_up, Qnil, 5285 DEFVAR_PER_BUFFER ("buffer-backed-up", &current_buffer->backed_up, Qnil,
5286 doc: /* Non-nil if this buffer's file has been backed up. 5286 doc: /* Non-nil if this buffer's file has been backed up.
5287 Backing up is done before the first time the file is saved. */); 5287 Backing up is done before the first time the file is saved. */);
5288 5288
5289 DEFVAR_PER_BUFFER ("buffer-saved-size", &current_buffer->save_length, 5289 DEFVAR_PER_BUFFER ("buffer-saved-size", &current_buffer->save_length,
5290 make_number (Lisp_Int), 5290 make_number (Lisp_Int),
5291 doc: /* Length of current buffer when last read in, saved or auto-saved. 5291 doc: /* Length of current buffer when last read in, saved or auto-saved.
5292 0 initially. */); 5292 0 initially. */);
5293 5293
5294 DEFVAR_PER_BUFFER ("selective-display", &current_buffer->selective_display, 5294 DEFVAR_PER_BUFFER ("selective-display", &current_buffer->selective_display,
5295 Qnil, 5295 Qnil,
5296 doc: /* Non-nil enables selective display: 5296 doc: /* Non-nil enables selective display:
5297 Integer N as value means display only lines 5297 Integer N as value means display only lines
5298 that start with less than n columns of space. 5298 that start with less than n columns of space.
5299 A value of t means, after a ^M, all the rest of the line is invisible. 5299 A value of t means, after a ^M, all the rest of the line is invisible.
5300 Then ^M's in the file are written into files as newlines. */); 5300 Then ^M's in the file are written into files as newlines. */);
5301 5301
5302 #ifndef old 5302 #ifndef old
5303 DEFVAR_PER_BUFFER ("selective-display-ellipses", 5303 DEFVAR_PER_BUFFER ("selective-display-ellipses",
5304 &current_buffer->selective_display_ellipses, 5304 &current_buffer->selective_display_ellipses,
5305 Qnil, 5305 Qnil,
5306 doc: /* t means display ... on previous line when a line is invisible. */); 5306 doc: /* t means display ... on previous line when a line is invisible. */);
5307 #endif 5307 #endif
5308 5308
5309 DEFVAR_PER_BUFFER ("overwrite-mode", &current_buffer->overwrite_mode, Qnil, 5309 DEFVAR_PER_BUFFER ("overwrite-mode", &current_buffer->overwrite_mode, Qnil,
5310 doc: /* Non-nil if self-insertion should replace existing text. 5310 doc: /* Non-nil if self-insertion should replace existing text.
5311 The value should be one of `overwrite-mode-textual', 5311 The value should be one of `overwrite-mode-textual',
5312 `overwrite-mode-binary', or nil. 5312 `overwrite-mode-binary', or nil.
5313 If it is `overwrite-mode-textual', self-insertion still 5313 If it is `overwrite-mode-textual', self-insertion still
5314 inserts at the end of a line, and inserts when point is before a tab, 5314 inserts at the end of a line, and inserts when point is before a tab,
5315 until the tab is filled in. 5315 until the tab is filled in.
5316 If `overwrite-mode-binary', self-insertion replaces newlines and tabs too. */); 5316 If `overwrite-mode-binary', self-insertion replaces newlines and tabs too. */);
5317 5317
5318 DEFVAR_PER_BUFFER ("buffer-display-table", &current_buffer->display_table, 5318 DEFVAR_PER_BUFFER ("buffer-display-table", &current_buffer->display_table,
5319 Qnil, 5319 Qnil,
5320 doc: /* Display table that controls display of the contents of current buffer. 5320 doc: /* Display table that controls display of the contents of current buffer.
5321 5321
5322 If this variable is nil, the value of `standard-display-table' is used. 5322 If this variable is nil, the value of `standard-display-table' is used.
5323 Each window can have its own, overriding display table, see 5323 Each window can have its own, overriding display table, see
5324 `set-window-display-table' and `window-display-table'. 5324 `set-window-display-table' and `window-display-table'.
5325 5325
5352 5352
5353 See also the functions `display-table-slot' and `set-display-table-slot'. */); 5353 See also the functions `display-table-slot' and `set-display-table-slot'. */);
5354 5354
5355 DEFVAR_PER_BUFFER ("left-margin-width", &current_buffer->left_margin_width, 5355 DEFVAR_PER_BUFFER ("left-margin-width", &current_buffer->left_margin_width,
5356 Qnil, 5356 Qnil,
5357 doc: /* *Width of left marginal area for display of a buffer. 5357 doc: /* *Width of left marginal area for display of a buffer.
5358 A value of nil means no marginal area. */); 5358 A value of nil means no marginal area. */);
5359 5359
5360 DEFVAR_PER_BUFFER ("right-margin-width", &current_buffer->right_margin_width, 5360 DEFVAR_PER_BUFFER ("right-margin-width", &current_buffer->right_margin_width,
5361 Qnil, 5361 Qnil,
5362 doc: /* *Width of right marginal area for display of a buffer. 5362 doc: /* *Width of right marginal area for display of a buffer.
5363 A value of nil means no marginal area. */); 5363 A value of nil means no marginal area. */);
5364 5364
5365 DEFVAR_PER_BUFFER ("indicate-empty-lines", 5365 DEFVAR_PER_BUFFER ("indicate-empty-lines",
5366 &current_buffer->indicate_empty_lines, Qnil, 5366 &current_buffer->indicate_empty_lines, Qnil,
5367 doc: /* *Visually indicate empty lines after the buffer end. 5367 doc: /* *Visually indicate empty lines after the buffer end.
5368 If non-nil, a bitmap is displayed in the left fringe of a window on 5368 If non-nil, a bitmap is displayed in the left fringe of a window on
5369 window-systems. */); 5369 window-systems. */);
5370 5370
5371 DEFVAR_PER_BUFFER ("scroll-up-aggressively", 5371 DEFVAR_PER_BUFFER ("scroll-up-aggressively",
5372 &current_buffer->scroll_up_aggressively, Qnil, 5372 &current_buffer->scroll_up_aggressively, Qnil,
5373 doc: /* *If a number, scroll display up aggressively. 5373 doc: /* *If a number, scroll display up aggressively.
5374 If scrolling a window because point is above the window start, choose 5374 If scrolling a window because point is above the window start, choose
5375 a new window start so that point ends up that fraction of the window's 5375 a new window start so that point ends up that fraction of the window's
5376 height from the top of the window. */); 5376 height from the top of the window. */);
5377 5377
5378 DEFVAR_PER_BUFFER ("scroll-down-aggressively", 5378 DEFVAR_PER_BUFFER ("scroll-down-aggressively",
5379 &current_buffer->scroll_down_aggressively, Qnil, 5379 &current_buffer->scroll_down_aggressively, Qnil,
5380 doc: /* *If a number, scroll display down aggressively. 5380 doc: /* *If a number, scroll display down aggressively.
5381 If scrolling a window because point is below the window end, choose 5381 If scrolling a window because point is below the window end, choose
5382 a new window start so that point ends up that fraction of the window's 5382 a new window start so that point ends up that fraction of the window's
5383 height from the bottom of the window. */); 5383 height from the bottom of the window. */);
5384 5384
5385 /*DEFVAR_LISP ("debug-check-symbol", &Vcheck_symbol, 5385 /*DEFVAR_LISP ("debug-check-symbol", &Vcheck_symbol,
5425 the variable's value remains nil. That prevents the error 5425 the variable's value remains nil. That prevents the error
5426 from happening repeatedly and making Emacs nonfunctional. */); 5426 from happening repeatedly and making Emacs nonfunctional. */);
5427 Vafter_change_functions = Qnil; 5427 Vafter_change_functions = Qnil;
5428 5428
5429 DEFVAR_LISP ("first-change-hook", &Vfirst_change_hook, 5429 DEFVAR_LISP ("first-change-hook", &Vfirst_change_hook,
5430 doc: /* A list of functions to call before changing a buffer which is unmodified. 5430 doc: /* A list of functions to call before changing a buffer which is unmodified.
5431 The functions are run using the `run-hooks' function. */); 5431 The functions are run using the `run-hooks' function. */);
5432 Vfirst_change_hook = Qnil; 5432 Vfirst_change_hook = Qnil;
5433 5433
5434 DEFVAR_PER_BUFFER ("buffer-undo-list", &current_buffer->undo_list, Qnil, 5434 DEFVAR_PER_BUFFER ("buffer-undo-list", &current_buffer->undo_list, Qnil,
5435 doc: /* List of undo entries in current buffer. 5435 doc: /* List of undo entries in current buffer.
5555 &current_buffer->extra_line_spacing, Qnil, 5555 &current_buffer->extra_line_spacing, Qnil,
5556 doc: /* Additional space to put between lines when displaying a buffer. 5556 doc: /* Additional space to put between lines when displaying a buffer.
5557 The space is measured in pixels, and put below lines on window systems. */); 5557 The space is measured in pixels, and put below lines on window systems. */);
5558 5558
5559 DEFVAR_LISP ("kill-buffer-query-functions", &Vkill_buffer_query_functions, 5559 DEFVAR_LISP ("kill-buffer-query-functions", &Vkill_buffer_query_functions,
5560 doc: /* List of functions called with no args to query before killing a buffer. */); 5560 doc: /* List of functions called with no args to query before killing a buffer. */);
5561 Vkill_buffer_query_functions = Qnil; 5561 Vkill_buffer_query_functions = Qnil;
5562 5562
5563 defsubr (&Sbuffer_live_p); 5563 defsubr (&Sbuffer_live_p);
5564 defsubr (&Sbuffer_list); 5564 defsubr (&Sbuffer_list);
5565 defsubr (&Sget_buffer); 5565 defsubr (&Sget_buffer);